whx 3 mesi fa
parent
commit
f99364c395
39 ha cambiato i file con 1815 aggiunte e 972 eliminazioni
  1. 759 78
      virgo.wzfrontend/console/package-lock.json
  2. 1 0
      virgo.wzfrontend/console/package.json
  3. 2 1
      virgo.wzfrontend/console/public/index.html
  4. 582 585
      virgo.wzfrontend/console/src/components/work/bim/operationModels.vue
  5. 164 7
      virgo.wzfrontend/console/src/views/common/ui.vue
  6. 1 1
      virgo.wzfrontend/console/src/views/work/crm/agent.vue
  7. 1 1
      virgo.wzfrontend/console/src/views/work/crm/customer.vue
  8. 1 1
      virgo.wzfrontend/console/src/views/work/crm/organization.vue
  9. 288 283
      virgo.wzfrontend/console/src/views/work/property/register.vue
  10. 1 1
      virgo.wzfrontend/src/main/resources/static/console/index.html
  11. 0 0
      virgo.wzfrontend/src/main/resources/static/console/static/css/175.aa0edd61.css
  12. 0 0
      virgo.wzfrontend/src/main/resources/static/console/static/css/2739.aa0edd61.css
  13. 0 0
      virgo.wzfrontend/src/main/resources/static/console/static/css/3443.f275a232.css
  14. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/css/4245.b5f242d6.css
  15. 0 0
      virgo.wzfrontend/src/main/resources/static/console/static/css/5959.f275a232.css
  16. 0 0
      virgo.wzfrontend/src/main/resources/static/console/static/css/7907.32d3f99b.css
  17. 0 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/1168-legacy.92ed4670.js
  18. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/js/1168.3086b2ea.js
  19. 0 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/1168.9fb62f6d.js
  20. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/js/175-legacy.342d3bdf.js
  21. 0 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/2319.717368bd.js
  22. 0 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/2435-legacy.18e1241a.js
  23. 0 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/2435.18e1241a.js
  24. 1 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/3296.eabcb0eb.js
  25. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/js/2906-legacy.404f87ef.js
  26. 1 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/8356.1ade2981.js
  27. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/js/4245-legacy.3be10257.js
  28. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/js/4245.0a47b7b5.js
  29. 0 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/4296-legacy.e7cf4cc4.js
  30. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/js/4818-legacy.e9997881.js
  31. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/js/4818.9e871de7.js
  32. 1 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/4909-legacy.9fcf80d0.js
  33. 1 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/6957-legacy.7fa27b61.js
  34. 1 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/6957.19e23725.js
  35. 0 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/9178-legacy.687be6fa.js
  36. 0 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/app-legacy.35eafe53.js
  37. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/js/app-legacy.4f7b3f6f.js
  38. 1 0
      virgo.wzfrontend/src/main/resources/static/console/static/js/app.c9362092.js
  39. 0 1
      virgo.wzfrontend/src/main/resources/static/console/static/js/app.e48d2340.js

File diff suppressed because it is too large
+ 759 - 78
virgo.wzfrontend/console/package-lock.json


+ 1 - 0
virgo.wzfrontend/console/package.json

@@ -14,6 +14,7 @@
 		"dayjs": "^1.11.11",
 		"element-ui": "^2.15.13",
 		"ezuikit-js": "^7.7.0",
+		"fabric": "^6.6.1",
 		"js-md5": "^0.8.3",
 		"luckyexcel": "^1.0.1",
 		"path-browserify": "^1.0.1",

+ 2 - 1
virgo.wzfrontend/console/public/index.html

@@ -31,7 +31,8 @@
 		<link rel="stylesheet" type="text/css" href="<%= BASE_URL %>icon/font.css" />
 		<script src="https://cdnjs.cloudflare.com/ajax/libs/echarts/5.4.3/echarts.min.js"></script>
 		<script src="https://cdnjs.cloudflare.com/ajax/libs/echarts-gl/2.0.8/echarts-gl.min.js"></script>
-		<script src="https://static.bimface.com/api/BimfaceSDKLoader/BimfaceSDKLoader@latest-release.js"></script>
+		<script src="https://static.bimface.com/api/BimfaceSDKLoader/BimfaceSDKLoader@latest-release.js"></script>
+		<script src="https://cdnjs.cloudflare.com/ajax/libs/fabric.js/5.2.4/fabric.min.js"></script>
 	</head>
 	<body id="body">
 		<noscript>

File diff suppressed because it is too large
+ 582 - 585
virgo.wzfrontend/console/src/components/work/bim/operationModels.vue


+ 164 - 7
virgo.wzfrontend/console/src/views/common/ui.vue

@@ -1,8 +1,165 @@
-<template>
-</template>
-
-<script>
-</script>
-
-<style>
+<template>
+	<div id="fabricContainer" class="fabric-container">
+		<div id="canvas-container">
+			<canvas id="myCanvas"></canvas>
+		</div>
+	</div>
+</template>
+
+<script>
+	export default {
+		data() {
+			return {
+				boxWidth: 100,
+				boxHeight: 100,
+				canvas: null,
+				position: []
+			}
+		},
+		beforeDestroy() {
+			let _self = this;
+			window.removeEventListener('resize', function() {
+				_self.init();
+			});
+		},
+		mounted() {
+			let _self = this;
+
+			_self.init();
+			// 监听窗口大小变化
+			window.addEventListener('resize', function() {
+				_self.init();
+			});
+		},
+		methods: {
+			init() {
+				let box = document.getElementById('fabricContainer');
+				if (!box) return;
+				let boxWidth = box.offsetWidth;
+				let boxHeight = box.offsetHeight;
+				if (!this.canvas) {
+					this.canvas = new fabric.Canvas('myCanvas', {
+						width: boxWidth, // 设置画布宽度
+						height: boxHeight, // 设置画布高度
+						backgroundColor: '#fff' // 可选:设置背景颜色
+					});
+					// this.clickFunction()
+					this.initBackgroundImage();
+				} else {
+					this.canvas.setWidth(boxWidth);
+					this.canvas.setHeight(boxHeight);
+					const canvasWidth = this.canvas.getWidth();
+					const canvasHeight = this.canvas.getHeight();
+					// 调整画布内容的大小
+					const objects = this.canvas.getObjects();
+					objects.forEach(obj => {
+						console.log(obj);
+						if (!obj.stroke) {
+							const scaleX = canvasWidth / obj.width;
+							const scaleY = canvasHeight / obj.height;
+							const scale = scaleX < scaleY ? scaleX : scaleY;
+							obj.scale(scale);
+							obj.set({
+								left: (canvasWidth - obj.width * scale) / 2,
+								top: (canvasHeight - obj.height * scale) / 2
+							});
+						}
+					});
+					this.canvas.renderAll(); // 重新渲染画布
+				}
+			},
+			clickFunction() {
+				let _self = this;
+				// 监听点击事件
+				_self.canvas.on('mouse:down', function(options) {
+					// 获取点击位置的坐标
+					const pointer = _self.canvas.getPointer(options.e);
+					const x = pointer.x;
+					const y = pointer.y;
+					_self.position.push({
+						x: x,
+						y: y
+					})
+					console.log(_self.position);
+
+					// 在点击位置添加一个圆形标记
+					const circle = new fabric.Circle({
+						radius: 5,
+						fill: 'red',
+						left: x,
+						top: y,
+						selectable: false // 禁止选中
+					});
+					_self.canvas.add(circle);
+					_self.canvas.renderAll();
+				});
+			},
+			initBackgroundImage() {
+				let _self = this;
+				let bg = 'https://file-node.oss-cn-shanghai.aliyuncs.com/youji/01a0120395b249ecbae565600f2fb3ce'
+				fabric.Image.fromURL(bg, function(img) {
+					// 获取画布的宽度和高度
+					const canvasWidth = _self.canvas.getWidth();
+					const canvasHeight = _self.canvas.getHeight();
+					// 计算图片的缩放比例
+					const scaleX = canvasWidth / img.width;
+					const scaleY = canvasHeight / img.height;
+					const scale = scaleX < scaleY ? scaleX : scaleY;
+					// 设置图片的缩放比例
+					img.scale(scale);
+					img.set({
+						left: (canvasWidth - img.width * scale) / 2,
+						top: (canvasHeight - img.height * scale) / 2,
+						selectable: false
+					})
+					_self.canvas.add(img);
+					_self.addPolygon();
+				});
+			},
+			addPolygon() {
+				const starPoints = [{
+						"x": 127,
+						"y": 210
+					},
+					{
+						"x": 192,
+						"y": 208
+					},
+					{
+						"x": 193,
+						"y": 179
+					},
+					{
+						"x": 337,
+						"y": 179
+					},
+					{
+						"x": 335,
+						"y": 0
+					},
+					{
+						"x": 127,
+						"y": 1
+					}
+				];
+				const star = new fabric.Polygon(starPoints, {
+					left: 300,
+					top: 100,
+					fill: 'yellow',
+					stroke: 'orange',
+					strokeWidth: 2
+				});
+				this.canvas.add(star);
+				this.canvas.renderAll();
+			}
+		}
+	}
+</script>
+
+<style lang="scss">
+	.fabric-container {
+		width: 100%;
+		height: 100%;
+		overflow: hidden;
+	}
 </style>

+ 1 - 1
virgo.wzfrontend/console/src/views/work/crm/agent.vue

@@ -1,7 +1,7 @@
 <template>
 	<div class="hui-flex hui-content">
 		<div class="hui-content-title">
-			<div class="hui-title-item active">经纪人列表</div>
+			<div class="hui-title-item active">经纪客户</div>
 		</div>
 		<div class="hui-flex-box hui-flex hui-table">
 			<list-filter type="agent" @filter="filterInit"></list-filter>

+ 1 - 1
virgo.wzfrontend/console/src/views/work/crm/customer.vue

@@ -8,7 +8,7 @@
 		</div>
 		<div class="customer-line"></div>
 		<div class="hui-content-title">
-			<div class="hui-title-item active">客户列表</div>
+			<div class="hui-title-item active">个人客户</div>
 		</div>
 		<div class="hui-flex-box hui-flex hui-table">
 			<list-filter type="customer" @filter="filterInit"></list-filter>

+ 1 - 1
virgo.wzfrontend/console/src/views/work/crm/organization.vue

@@ -1,7 +1,7 @@
 <template>
 	<div class="hui-flex hui-content">
 		<div class="hui-content-title">
-			<div class="hui-title-item active">企业管理</div>
+			<div class="hui-title-item active">企业客户</div>
 		</div>
 		<div class="hui-flex-box hui-flex hui-table">
 			<list-filter type="organization" @filter="filterInit"></list-filter>

+ 288 - 283
virgo.wzfrontend/console/src/views/work/property/register.vue

@@ -1,285 +1,290 @@
-<template>
-	<div class="hui-flex">
-		<div class="hui-flex-box yui-tree-box">
-			<div class="hui-left-tree">
-				<div class="hui-left-tree-title">
-					<svg-icon name="zhuangshi" width="16" height="20"></svg-icon>
-					<span class="hui-left-tree-sub">资产列表</span>
-				</div>
-				<div class="hui-left-tree-content">
-					<el-collapse>
-						<el-collapse-item v-for="item in treeData" :key="item.id">
-							<template slot="title">
-								<i class="iconfont huifont-shuzhuangcaidantubiao"></i>
-								<span class="el-collapse-name">{{item.name}}</span>
-							</template>
-							<div>
-								<el-tree :data="item.children" :props="defaultProps">
-									<div class="custom-tree-node" slot-scope="{ node, data }">
-										<div class="label">{{node.label}}</div>
-										<div :class="nowData.id === data.id ? 'active':''"
-											@click.stop="filterDevice(data)">
-											<i
-												:class="'iconfont ' + (data.deviceId ? 'huifont-shebeiguanli' : 'huifont-xiangmuguanli')">
-											</i>
-										</div>
-									</div>
-								</el-tree>
-							</div>
-						</el-collapse-item>
-					</el-collapse>
-				</div>
-			</div>
-			<div class="hui-tree-content">
-				<div class="hui-flex hui-content box-background">
-					<div class="hui-content-title">
-						<div class="hui-title-item active">资产登记</div>
-					</div>
-					<div class="hui-flex-box hui-flex hui-table">
-						<div class="hui-content-insert">
-							<el-button v-permission="'/work/property/register/add'" type="primary" size="medium"
-								@click="insert">
-								新增登记
-							</el-button>
-						</div>
-						<div class="hui-flex-box">
-							<el-table :data="tableData" row-key="id" border height="100%">
-								<el-table-column label="序号" width="50">
-									<template slot-scope="scope">
-										<div style="text-align: center;">{{scope.$index + 1}}</div>
-									</template>
-								</el-table-column>
-								<el-table-column label="资产名称" prop="name"></el-table-column>
-								<el-table-column label="资产类型">
-									<template slot-scope="scope">
-										<span>{{scope.row.type === 0?'普通设备':'物联网设备'}}</span>
-									</template>
-								</el-table-column>
-								<el-table-column label="资产编码" prop="assetNumber"></el-table-column>
-								<el-table-column label="单位建筑" prop="projectItemName"></el-table-column>
-								<el-table-column label="具体位置" prop="projectItemTargetName"></el-table-column>
-								<el-table-column label="型号" prop="deviceModel"></el-table-column>
-								<el-table-column label="创建者" prop="createdByUserName"></el-table-column>
-								<el-table-column label="状态">
-									<template slot-scope="scope">
-										<div v-if="!scope.row.state" class="hui-state">
-											<span class="hui-state-bage hui-state-primary"></span>
-											<span class="hui-state-label">待生成</span>
-										</div>
-										<div v-if="scope.row.state == -1 || scope.row.state == 1" class="hui-state">
-											<span class="hui-state-bage hui-state-primary"></span>
-											<span class="hui-state-label">待审核</span>
-										</div>
-										<div v-if="scope.row.state == 2" class="hui-state">
-											<span class="hui-state-bage hui-state-info"></span>
-											<span class="hui-state-label">审核中</span>
-										</div>
-										<div v-if="scope.row.state == 3" class="hui-state">
-											<span class="hui-state-bage hui-state-success"></span>
-											<span class="hui-state-label">通过</span>
-										</div>
-										<div v-if="scope.row.state == 4" class="hui-state">
-											<span class="hui-state-bage hui-state-error"></span>
-											<span class="hui-state-label">未通过</span>
-										</div>
-									</template>
-								</el-table-column>
-								<el-table-column label="操作" width="150">
-									<template slot-scope="scope">
-										<div class="hui-table-operation">
-											<span class="table-operation"
-												v-permission="'/work/property/register/detail'"
-												@click="lookFlow(scope.row)">
-												详情
-											</span>
-											<span class="table-operation"
-												v-permission="'/work/property/register/update'"
-												v-if="!scope.row.projectFlowId" @click="updateFlow(scope.row)">
-												编辑
-											</span>
-											<span class="table-operation"
-												v-permission="'/work/property/register/delete'"
-												v-if="!scope.row.projectFlowId" @click="deleteFlow(scope.row)">
-												删除
-											</span>
-										</div>
-									</template>
-								</el-table-column>
-								<template slot="empty">
-									<empty description="暂无数据"></empty>
-								</template>
-							</el-table>
-						</div>
-						<div class="hui-content-pagination">
-							<el-pagination :pager-count="9" layout="prev, pager, next" :total="totalCount"
-								@current-change="currentChange">
-							</el-pagination>
-						</div>
-					</div>
-				</div>
-			</div>
-		</div>
-		<el-dialog :close-on-click-modal="false" :title="isUpdate?'编辑':'新增'" :visible.sync="visible" width="1200px"
-			:append-to-body="true">
-			<flow-form v-if="visible" :isUpdate="isUpdate" @callback="callback" :detailId="detailId"
-				:flowType="flowType">
-			</flow-form>
-		</el-dialog>
-		<el-drawer title="流程详情" :visible.sync="drawer" :size="400" :append-to-body="true">
-			<flow-detail v-if="drawer" @callback="callback" :detailId="detailId"></flow-detail>
-		</el-drawer>
-	</div>
-</template>
-
-<script>
-	import {
-		initDevicePartList,
-		getDevicePartList,
-		getFlowList,
-		deleteFlow
-	} from '@/httpApi/property'
-	import flowForm from '@/components/flow/flowForm'
+<template>
+	<div class="hui-flex">
+		<div class="hui-flex-box yui-tree-box">
+			<div class="hui-left-tree">
+				<div class="hui-left-tree-title">
+					<svg-icon name="zhuangshi" width="16" height="20"></svg-icon>
+					<span class="hui-left-tree-sub">资产列表</span>
+				</div>
+				<div class="hui-left-tree-content">
+					<el-collapse>
+						<el-collapse-item v-for="item in treeData" :key="item.id">
+							<template slot="title">
+								<i class="iconfont huifont-shuzhuangcaidantubiao"></i>
+								<span class="el-collapse-name">{{item.name}}</span>
+							</template>
+							<div>
+								<el-tree :data="item.children" :props="defaultProps">
+									<div class="custom-tree-node" slot-scope="{ node, data }">
+										<div class="label">{{node.label}}</div>
+										<div :class="nowData.id === data.id ? 'active':''"
+											@click.stop="filterDevice(data)">
+											<i
+												:class="'iconfont ' + (data.deviceId ? 'huifont-shebeiguanli' : 'huifont-xiangmuguanli')">
+											</i>
+										</div>
+									</div>
+								</el-tree>
+							</div>
+						</el-collapse-item>
+					</el-collapse>
+				</div>
+			</div>
+			<div class="hui-tree-content">
+				<div class="hui-flex hui-content box-background">
+					<div class="hui-content-title">
+						<div class="hui-title-item active">资产登记</div>
+					</div>
+					<div class="hui-flex-box hui-flex hui-table">
+						<div class="hui-content-insert">
+							<el-button v-permission="'/work/property/register/add'" type="primary" size="medium"
+								@click="insert">
+								新增登记
+							</el-button>
+							<el-button type="info" size="medium" @click="downloadFile">标准模板下载</el-button>
+						</div>
+						<div class="hui-flex-box">
+							<el-table :data="tableData" row-key="id" border height="100%">
+								<el-table-column label="序号" width="50">
+									<template slot-scope="scope">
+										<div style="text-align: center;">{{scope.$index + 1}}</div>
+									</template>
+								</el-table-column>
+								<el-table-column label="资产名称" prop="name"></el-table-column>
+								<el-table-column label="资产类型">
+									<template slot-scope="scope">
+										<span>{{scope.row.type === 0?'普通设备':'物联网设备'}}</span>
+									</template>
+								</el-table-column>
+								<el-table-column label="资产编码" prop="assetNumber"></el-table-column>
+								<el-table-column label="单位建筑" prop="projectItemName"></el-table-column>
+								<el-table-column label="具体位置" prop="projectItemTargetName"></el-table-column>
+								<el-table-column label="型号" prop="deviceModel"></el-table-column>
+								<el-table-column label="创建者" prop="createdByUserName"></el-table-column>
+								<el-table-column label="状态">
+									<template slot-scope="scope">
+										<div v-if="!scope.row.state" class="hui-state">
+											<span class="hui-state-bage hui-state-primary"></span>
+											<span class="hui-state-label">待生成</span>
+										</div>
+										<div v-if="scope.row.state == -1 || scope.row.state == 1" class="hui-state">
+											<span class="hui-state-bage hui-state-primary"></span>
+											<span class="hui-state-label">待审核</span>
+										</div>
+										<div v-if="scope.row.state == 2" class="hui-state">
+											<span class="hui-state-bage hui-state-info"></span>
+											<span class="hui-state-label">审核中</span>
+										</div>
+										<div v-if="scope.row.state == 3" class="hui-state">
+											<span class="hui-state-bage hui-state-success"></span>
+											<span class="hui-state-label">通过</span>
+										</div>
+										<div v-if="scope.row.state == 4" class="hui-state">
+											<span class="hui-state-bage hui-state-error"></span>
+											<span class="hui-state-label">未通过</span>
+										</div>
+									</template>
+								</el-table-column>
+								<el-table-column label="操作" width="150">
+									<template slot-scope="scope">
+										<div class="hui-table-operation">
+											<span class="table-operation"
+												v-permission="'/work/property/register/detail'"
+												@click="lookFlow(scope.row)">
+												详情
+											</span>
+											<span class="table-operation"
+												v-permission="'/work/property/register/update'"
+												v-if="!scope.row.projectFlowId" @click="updateFlow(scope.row)">
+												编辑
+											</span>
+											<span class="table-operation"
+												v-permission="'/work/property/register/delete'"
+												v-if="!scope.row.projectFlowId" @click="deleteFlow(scope.row)">
+												删除
+											</span>
+										</div>
+									</template>
+								</el-table-column>
+								<template slot="empty">
+									<empty description="暂无数据"></empty>
+								</template>
+							</el-table>
+						</div>
+						<div class="hui-content-pagination">
+							<el-pagination :pager-count="9" layout="prev, pager, next" :total="totalCount"
+								@current-change="currentChange">
+							</el-pagination>
+						</div>
+					</div>
+				</div>
+			</div>
+		</div>
+		<el-dialog :close-on-click-modal="false" :title="isUpdate?'编辑':'新增'" :visible.sync="visible" width="1200px"
+			:append-to-body="true">
+			<flow-form v-if="visible" :isUpdate="isUpdate" @callback="callback" :detailId="detailId"
+				:flowType="flowType">
+			</flow-form>
+		</el-dialog>
+		<el-drawer title="流程详情" :visible.sync="drawer" :size="400" :append-to-body="true">
+			<flow-detail v-if="drawer" @callback="callback" :detailId="detailId"></flow-detail>
+		</el-drawer>
+	</div>
+</template>
+
+<script>
+	import {
+		initDevicePartList,
+		getDevicePartList,
+		getFlowList,
+		deleteFlow
+	} from '@/httpApi/property'
+	import flowForm from '@/components/flow/flowForm'
 	import flowDetail from '@/components/flow/flowDetail'
-	export default {
-		data() {
-			return {
-				flowType: 1,
-				tableData: [],
-				currPage: 1,
-				pageSize: 10,
-				totalCount: 0,
-				treeData: [],
-				defaultProps: {
-					children: 'children',
-					label: 'name'
-				},
-				visible: false,
-				isUpdate: false,
-				detailId: '',
-				drawer: false,
-				nowData: {},
-				filterOption: {}
-			}
-		},
-		mounted() {
-			this.initDeviceList();
-			this.init();
-		},
-		methods: {
-			init() {
-				if (!this.auth('/work/property/register/list')) return;
-				let filterOption = {
-					projectId: this.$store.getters.project.id,
-					flowType: this.flowType
-				};
-				filterOption = Object.assign(filterOption, this.filterOption);
-				getFlowList(this.currPage, this.pageSize, filterOption).then(res => {
-					if (res.state) {
-						this.tableData = res.data.dataList.map(node => {
-							node = Object.assign(node, JSON.parse(node.flowData));
-							return node;
-						});;
-						this.totalCount = res.data.totalCount;
-					}
-				})
-			},
-			initDeviceList() {
-				getDevicePartList(this.$store.getters.organization.id, this.$store.getters.project.id).then(res => {
-					if (res.state) {
-						if (res.data.length === 0) {
-							initDevicePartList(this.$store.getters.organization.id, this.$store.getters.project.id)
-								.then(res => {
-									if (res.state) this.initDeviceList();
-								})
-						} else {
-							this.treeData = res.data;
-							this.returnChildren(this.treeData);
-						}
-					}
-				})
-			},
-			returnChildren(data) {
-				data.forEach(item => {
-					if (item.children && item.children.length > 0) this.returnChildren(item.children);
-				});
-			},
-			filterDevice(data) {
-				this.filterOption = {};
-				if (this.nowData.id === data.id) {
-					this.nowData = {};
-				} else {
-					this.nowData = data;
-					if (this.nowData.deviceId) {
-						this.filterOption['deviceId'] = this.nowData.deviceId;
-					} else {
-						this.filterOption['deviceLevelIds'] = this.getStorageIds([data]);
-					}
-				}
-				this.currPage = 1;
-				this.init();
-			},
-			getStorageIds(array) {
-				//获取档案库id
-				let ids = [];
-
-				function getIds(array, ids) {
-					array.forEach(item => {
-						if (item.id) {
-							ids.push(item.id);
-						}
-						if (item.children) {
-							ids = getIds(item.children, ids);
-						}
-					})
-					return ids;
-				}
-				if (Array.isArray(array)) {
-					if (array.length == 0) {
-						return [];
-					}
-				} else {
-					return [];
-				}
-				ids = getIds(array, ids);
-				return ids;
-			},
-			currentChange(currPage) {
-				this.currPage = currPage;
-				this.init();
-			},
-			insert() {
-				this.visible = true;
-				this.isUpdate = false;
-			},
-			lookFlow(val) {
-				this.detailId = val.id;
-				this.drawer = true;
-			},
-			updateFlow(val) {
-				this.detailId = val.id;
-				this.isUpdate = true;
-				this.visible = true;
-			},
-			deleteFlow(val) {
-				this.$confirm('确定要删除该流程?', () => {
-					deleteFlow(val.id).then(res => {
-						if (res.state) {
-							this.$message.success('操作成功');
-							this.init();
-						}
-					})
-				});
-			},
-			callback(type) {
-				this.visible = false;
-				if (type === 'init') this.init();
-			}
-		},
-		components: {
-			flowForm,
-			flowDetail
-		},
-	}
-</script>
-
+	import config from '@/config'
+	export default {
+		data() {
+			return {
+				flowType: 1,
+				tableData: [],
+				currPage: 1,
+				pageSize: 10,
+				totalCount: 0,
+				treeData: [],
+				defaultProps: {
+					children: 'children',
+					label: 'name'
+				},
+				visible: false,
+				isUpdate: false,
+				detailId: '',
+				drawer: false,
+				nowData: {},
+				filterOption: {}
+			}
+		},
+		mounted() {
+			this.initDeviceList();
+			this.init();
+		},
+		methods: {
+			init() {
+				if (!this.auth('/work/property/register/list')) return;
+				let filterOption = {
+					projectId: this.$store.getters.project.id,
+					flowType: this.flowType
+				};
+				filterOption = Object.assign(filterOption, this.filterOption);
+				getFlowList(this.currPage, this.pageSize, filterOption).then(res => {
+					if (res.state) {
+						this.tableData = res.data.dataList.map(node => {
+							node = Object.assign(node, JSON.parse(node.flowData));
+							return node;
+						});;
+						this.totalCount = res.data.totalCount;
+					}
+				})
+			},
+			initDeviceList() {
+				getDevicePartList(this.$store.getters.organization.id, this.$store.getters.project.id).then(res => {
+					if (res.state) {
+						if (res.data.length === 0) {
+							initDevicePartList(this.$store.getters.organization.id, this.$store.getters.project.id)
+								.then(res => {
+									if (res.state) this.initDeviceList();
+								})
+						} else {
+							this.treeData = res.data;
+							this.returnChildren(this.treeData);
+						}
+					}
+				})
+			},
+			returnChildren(data) {
+				data.forEach(item => {
+					if (item.children && item.children.length > 0) this.returnChildren(item.children);
+				});
+			},
+			filterDevice(data) {
+				this.filterOption = {};
+				if (this.nowData.id === data.id) {
+					this.nowData = {};
+				} else {
+					this.nowData = data;
+					if (this.nowData.deviceId) {
+						this.filterOption['deviceId'] = this.nowData.deviceId;
+					} else {
+						this.filterOption['deviceLevelIds'] = this.getStorageIds([data]);
+					}
+				}
+				this.currPage = 1;
+				this.init();
+			},
+			downloadFile() {
+				window.location.href = config.baseURL + '/api/operateDevice/exportTemplate';
+			},
+			getStorageIds(array) {
+				//获取档案库id
+				let ids = [];
+
+				function getIds(array, ids) {
+					array.forEach(item => {
+						if (item.id) {
+							ids.push(item.id);
+						}
+						if (item.children) {
+							ids = getIds(item.children, ids);
+						}
+					})
+					return ids;
+				}
+				if (Array.isArray(array)) {
+					if (array.length == 0) {
+						return [];
+					}
+				} else {
+					return [];
+				}
+				ids = getIds(array, ids);
+				return ids;
+			},
+			currentChange(currPage) {
+				this.currPage = currPage;
+				this.init();
+			},
+			insert() {
+				this.visible = true;
+				this.isUpdate = false;
+			},
+			lookFlow(val) {
+				this.detailId = val.id;
+				this.drawer = true;
+			},
+			updateFlow(val) {
+				this.detailId = val.id;
+				this.isUpdate = true;
+				this.visible = true;
+			},
+			deleteFlow(val) {
+				this.$confirm('确定要删除该流程?', () => {
+					deleteFlow(val.id).then(res => {
+						if (res.state) {
+							this.$message.success('操作成功');
+							this.init();
+						}
+					})
+				});
+			},
+			callback(type) {
+				this.visible = false;
+				if (type === 'init') this.init();
+			}
+		},
+		components: {
+			flowForm,
+			flowDetail
+		},
+	}
+</script>
+
 <style lang="scss"></style>

File diff suppressed because it is too large
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/console/index.html


virgo.wzfrontend/src/main/resources/static/console/static/css/3296.aa0edd61.css → virgo.wzfrontend/src/main/resources/static/console/static/css/175.aa0edd61.css


virgo.wzfrontend/src/main/resources/static/console/static/css/9178.aa0edd61.css → virgo.wzfrontend/src/main/resources/static/console/static/css/2739.aa0edd61.css


virgo.wzfrontend/src/main/resources/static/console/static/css/4909.f275a232.css → virgo.wzfrontend/src/main/resources/static/console/static/css/3443.f275a232.css


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/css/4245.b5f242d6.css


virgo.wzfrontend/src/main/resources/static/console/static/css/8356.f275a232.css → virgo.wzfrontend/src/main/resources/static/console/static/css/5959.f275a232.css


virgo.wzfrontend/src/main/resources/static/console/static/css/6957.32d3f99b.css → virgo.wzfrontend/src/main/resources/static/console/static/css/7907.32d3f99b.css


File diff suppressed because it is too large
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/1168-legacy.92ed4670.js


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/js/1168.3086b2ea.js


File diff suppressed because it is too large
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/1168.9fb62f6d.js


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/js/175-legacy.342d3bdf.js


File diff suppressed because it is too large
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/2319.717368bd.js


File diff suppressed because it is too large
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/2435-legacy.18e1241a.js


File diff suppressed because it is too large
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/2435.18e1241a.js


File diff suppressed because it is too large
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/3296.eabcb0eb.js


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/js/2906-legacy.404f87ef.js


File diff suppressed because it is too large
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/8356.1ade2981.js


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/js/4245-legacy.3be10257.js


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/js/4245.0a47b7b5.js


File diff suppressed because it is too large
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/4296-legacy.e7cf4cc4.js


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/js/4818-legacy.e9997881.js


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/js/4818.9e871de7.js


File diff suppressed because it is too large
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/4909-legacy.9fcf80d0.js


File diff suppressed because it is too large
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/6957-legacy.7fa27b61.js


File diff suppressed because it is too large
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/6957.19e23725.js


File diff suppressed because it is too large
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/9178-legacy.687be6fa.js


File diff suppressed because it is too large
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/app-legacy.35eafe53.js


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/js/app-legacy.4f7b3f6f.js


File diff suppressed because it is too large
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/console/static/js/app.c9362092.js


File diff suppressed because it is too large
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/console/static/js/app.e48d2340.js