mirror of
https://github.com/kerwincui/FastBee.git
synced 2025-10-06 00:27:32 +08:00
界面调整
This commit is contained in:
@@ -99,26 +99,26 @@
|
|||||||
<el-col :span="12" class="card-panel-col">
|
<el-col :span="12" class="card-panel-col">
|
||||||
<div class="card-panel">
|
<div class="card-panel">
|
||||||
<div class="card-panel-icon-wrapper icon-red">
|
<div class="card-panel-icon-wrapper icon-red">
|
||||||
<svg-icon icon-class="log-a" class-name="card-panel-icon" />
|
|
||||||
</div>
|
|
||||||
<div class="card-panel-description">
|
|
||||||
<div class="card-panel-text">
|
|
||||||
功能操作
|
|
||||||
</div>
|
|
||||||
<count-to :start-val="0" :end-val="deviceStatistic.functionCount" :duration="1000" class="card-panel-num" />
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</el-col>
|
|
||||||
<el-col :span="12" class="card-panel-col">
|
|
||||||
<div class="card-panel">
|
|
||||||
<div class="card-panel-icon-wrapper icon-blue">
|
|
||||||
<svg-icon icon-class="alert" class-name="card-panel-icon" />
|
<svg-icon icon-class="alert" class-name="card-panel-icon" />
|
||||||
</div>
|
</div>
|
||||||
<div class="card-panel-description">
|
<div class="card-panel-description">
|
||||||
<div class="card-panel-text">
|
<div class="card-panel-text">
|
||||||
告警数量
|
告警数量
|
||||||
</div>
|
</div>
|
||||||
<count-to :start-val="0" :end-val="deviceStatistic.alertCount" :duration="2000" class="card-panel-num" />
|
<count-to :start-val="0" :end-val="deviceStatistic.alertCount" :duration="1000" class="card-panel-num" />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-col>
|
||||||
|
<el-col :span="12" class="card-panel-col">
|
||||||
|
<div class="card-panel">
|
||||||
|
<div class="card-panel-icon-wrapper icon-blue">
|
||||||
|
<svg-icon icon-class="log-a" class-name="card-panel-icon" />
|
||||||
|
</div>
|
||||||
|
<div class="card-panel-description">
|
||||||
|
<div class="card-panel-text">
|
||||||
|
操作记录
|
||||||
|
</div>
|
||||||
|
<count-to :start-val="0" :end-val="deviceStatistic.functionCount" :duration="2000" class="card-panel-num" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
|
@@ -70,7 +70,7 @@
|
|||||||
<el-button-group style="margin-top:15px;">
|
<el-button-group style="margin-top:15px;">
|
||||||
<el-button size="mini" type="primary" icon="el-icon-edit" @click="handleEditProduct(item)" v-hasPermi="['iot:product:edit']">详情</el-button>
|
<el-button size="mini" type="primary" icon="el-icon-edit" @click="handleEditProduct(item)" v-hasPermi="['iot:product:edit']">详情</el-button>
|
||||||
<el-button size="mini" type="danger" icon="el-icon-delete" @click="handleDelete(item)" v-hasPermi="['iot:product:remove']" v-if="item.status==1">删除</el-button>
|
<el-button size="mini" type="danger" icon="el-icon-delete" @click="handleDelete(item)" v-hasPermi="['iot:product:remove']" v-if="item.status==1">删除</el-button>
|
||||||
<el-button size="mini" type="info" icon="el-icon-download" @click="handleGeneratorSDK(item)" v-hasPermi="['iot:product:edit']" v-if="item.status==2">下载SDK</el-button>
|
<el-button size="mini" type="success" icon="el-icon-s-check" @click="handleDeviceAuthorize(item)" v-hasPermi="['iot:product:edit']" v-if="item.status==2" :disabled="item.isAuthorize!=1">设备授权</el-button>
|
||||||
<el-button size="mini" type="warning" icon="el-icon-search" @click="handleViewDevice(item.productId)" v-hasPermi="['iot:device:query']">查看设备</el-button>
|
<el-button size="mini" type="warning" icon="el-icon-search" @click="handleViewDevice(item.productId)" v-hasPermi="['iot:device:query']">查看设备</el-button>
|
||||||
</el-button-group>
|
</el-button-group>
|
||||||
</el-card>
|
</el-card>
|
||||||
@@ -246,6 +246,18 @@ export default {
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
/** 设备授权操作 */
|
||||||
|
handleDeviceAuthorize(row) {
|
||||||
|
let productId = row.productId
|
||||||
|
this.$router.push({
|
||||||
|
path: '/iot/product-edit',
|
||||||
|
query: {
|
||||||
|
productId: productId,
|
||||||
|
tabPanelName:'productAuthorize',
|
||||||
|
pageNum: this.queryParams.pageNum
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
@@ -192,9 +192,14 @@ export default {
|
|||||||
// 获取产品信息
|
// 获取产品信息
|
||||||
const productId = this.$route.query && this.$route.query.productId;
|
const productId = this.$route.query && this.$route.query.productId;
|
||||||
this.form.productId = productId;
|
this.form.productId = productId;
|
||||||
if (this.form.productId != 0) {
|
if (this.form.productId != 0 && this.form.productId != null) {
|
||||||
this.getProduct();
|
this.getProduct();
|
||||||
}
|
}
|
||||||
|
// 切换选项卡
|
||||||
|
const tabPanelName = this.$route.query && this.$route.query.tabPanelName;
|
||||||
|
if (tabPanelName != null && tabPanelName != '') {
|
||||||
|
this.activeName = tabPanelName;
|
||||||
|
}
|
||||||
// 获取分类信息
|
// 获取分类信息
|
||||||
this.getShortCategory();
|
this.getShortCategory();
|
||||||
},
|
},
|
||||||
@@ -209,6 +214,11 @@ export default {
|
|||||||
this.getProduct();
|
this.getProduct();
|
||||||
this.getShortCategory();
|
this.getShortCategory();
|
||||||
}
|
}
|
||||||
|
// 切换选项卡
|
||||||
|
const tabPanelName = this.$route.query && this.$route.query.tabPanelName;
|
||||||
|
if (tabPanelName != null && tabPanelName != '') {
|
||||||
|
this.activeName = tabPanelName;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
|
Reference in New Issue
Block a user