whx 3 месяцев назад
Родитель
Сommit
7ed66bedc8
39 измененных файлов с 479 добавлено и 440 удалено
  1. 1 1
      virgo.wzfrontend/src/main/resources/static/workark/index.html
  2. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/css/5409.ec0de6e9.css
  3. 1 1
      virgo.wzfrontend/src/main/resources/static/workark/static/css/555.0b84fbed.css
  4. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/css/9242.f9edad1a.css
  5. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/1274.69e59d63.js
  6. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/1291.9cadc43a.js
  7. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/1316.b3c139fa.js
  8. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/2352.09e4ebd9.js
  9. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/2891.087e881d.js
  10. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/2891.8cf9e544.js
  11. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/2925.1eb8beab.js
  12. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/2925.9a9abb7a.js
  13. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/348.06a4464f.js
  14. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/4136.3b5b9d0a.js
  15. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/5306.d1aa294b.js
  16. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/5306.f86ad041.js
  17. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/5409.62ae6d33.js
  18. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/555.01db3032.js
  19. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/5996.cbf91676.js
  20. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/6072.69b874c3.js
  21. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/6523.c3e0be7e.js
  22. 1 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/7218.53947a9f.js
  23. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/7390.45b02198.js
  24. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/8018.626d4926.js
  25. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/8018.be328368.js
  26. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/9242.2cd499b2.js
  27. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/9666.45a426d4.js
  28. 0 1
      virgo.wzfrontend/src/main/resources/static/workark/static/js/app.53e26e6c.js
  29. 1 0
      virgo.wzfrontend/src/main/resources/static/workark/static/js/app.b8eea074.js
  30. 1 1
      virgo.wzfrontend/workark/src/components/flow/flow.vue
  31. 22 1
      virgo.wzfrontend/workark/src/layout/components/topNav.vue
  32. 2 1
      virgo.wzfrontend/workark/src/store/getters.js
  33. 11 1
      virgo.wzfrontend/workark/src/store/modules/app.js
  34. 19 26
      virgo.wzfrontend/workark/src/uitls/message.js
  35. 14 0
      virgo.wzfrontend/workark/src/views/message/list.vue
  36. 191 191
      virgo.wzfrontend/workark/src/views/work/property/change.vue
  37. 194 194
      virgo.wzfrontend/workark/src/views/work/property/depreciation.vue
  38. 7 7
      virgo.wzfrontend/workark/src/views/work/property/inventory.vue
  39. 2 2
      virgo.wzfrontend/workark/src/views/work/property/register.vue

Разница между файлами не показана из-за своего большого размера
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/workark/index.html


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/css/5409.ec0de6e9.css


Разница между файлами не показана из-за своего большого размера
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/css/555.0b84fbed.css


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/css/9242.f9edad1a.css


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/1274.69e59d63.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/1291.9cadc43a.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/1316.b3c139fa.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/2352.09e4ebd9.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/2891.087e881d.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/2891.8cf9e544.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/2925.1eb8beab.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/2925.9a9abb7a.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/348.06a4464f.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/4136.3b5b9d0a.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/5306.d1aa294b.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/5306.f86ad041.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/5409.62ae6d33.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/555.01db3032.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/5996.cbf91676.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/6072.69b874c3.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/6523.c3e0be7e.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/7218.53947a9f.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/7390.45b02198.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/8018.626d4926.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/8018.be328368.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/9242.2cd499b2.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/9666.45a426d4.js


Разница между файлами не показана из-за своего большого размера
+ 0 - 1
virgo.wzfrontend/src/main/resources/static/workark/static/js/app.53e26e6c.js


Разница между файлами не показана из-за своего большого размера
+ 1 - 0
virgo.wzfrontend/src/main/resources/static/workark/static/js/app.b8eea074.js


+ 1 - 1
virgo.wzfrontend/workark/src/components/flow/flow.vue

@@ -203,7 +203,7 @@
 					}
 
 					.user-content {
-						background: rgba(50, 56, 68, 0.2);
+						background: $--background-color-base;
 						border-radius: 8px;
 						padding: 13px;
 

+ 22 - 1
virgo.wzfrontend/workark/src/layout/components/topNav.vue

@@ -53,6 +53,9 @@
 	import {
 		removeToken
 	} from '@/uitls/auth';
+	import {
+		getMessageTest
+	} from '@/api/message'
 	import {
 		mapGetters
 	} from 'vuex';
@@ -68,11 +71,23 @@
 		},
 		mounted() {
 			this.init();
+			this.initMessage();
 		},
 		methods: {
 			init() {
 				this.users = this.$store.getters.user;
 			},
+			initMessage() {
+				getMessageTest(this.$store.getters.user.userId).then(res => {
+					if (res.state) {
+						let num = 0;
+						for (var i = 0; i < res.data.length; i++) {
+							num += res.data[i].count
+						}
+						this.systemCountStatus = num > 0;
+					}
+				})
+			},
 			userCommand(command) {
 				switch (command) {
 					case 'detail':
@@ -100,10 +115,16 @@
 		watch: {
 			user() {
 				this.init();
+			},
+			chatList() {
+				this.initMessage();
+			},
+			reloadMessage() {
+				this.initMessage();
 			}
 		},
 		computed: {
-			...mapGetters(['user'])
+			...mapGetters(['user', 'chatList', 'reloadMessage'])
 		},
 		components: {
 			userDetail

+ 2 - 1
virgo.wzfrontend/workark/src/store/getters.js

@@ -7,6 +7,7 @@ const getters = {
 	processSet: state => state.app.processSet, //过程状态管理
 	loginVisible: state => state.app.loginVisible, //登录弹窗
 	chatList: state => state.app.chatList, //消息列表
-	chatToken: state => state.app.chatToken //消息token
+	chatToken: state => state.app.chatToken ,//消息token
+	reloadMessage: state => state.app.reloadMessage //消息刷新
 }
 export default getters;

+ 11 - 1
virgo.wzfrontend/workark/src/store/modules/app.js

@@ -13,7 +13,8 @@ const getDefaultState = () => ({
 	processSet: {},
 	loginVisible: 1,
 	chatList: [],
-	chatToken: ''
+	chatToken: '',
+	reloadMessage: false
 })
 
 const mutations = {
@@ -46,6 +47,9 @@ const mutations = {
 	},
 	CHANGE_CHAT_TOKEN: (state, chatToken) => {
 		state.chatToken = chatToken;
+	},
+	RELOAD_MESSAGE: (state, reloadMessage) => {
+		state.reloadMessage = reloadMessage;
 	}
 }
 
@@ -99,7 +103,13 @@ const actions = {
 		commit
 	}, chatToken) {
 		commit('CHANGE_CHAT_TOKEN', chatToken);
+	},
+	changeReloadMessage({
+		commit
+	}, reloadMessage) {
+		commit('RELOAD_MESSAGE', reloadMessage);
 	}
+
 }
 
 export default {

+ 19 - 26
virgo.wzfrontend/workark/src/uitls/message.js

@@ -134,28 +134,6 @@ const messageType = [{
 }];
 
 export default {
-	send(sendData = {}, params = {}) {
-		let date = dayjs(new Date()).format('YYYY-MM-DD HH:mm:ss');
-		let obj = {
-			projectId: store.getters.project.id,
-			organizationId: store.getters.organization.id,
-			date: date
-		}
-		params['time'] = date;
-		obj = Object.assign(obj, sendData);
-		let postData = {
-			sender: store.getters.user.userId,
-			messageType: params.messageType,
-			message: this.messageContent(params),
-			json: JSON.stringify(obj),
-			viewed: 0
-		}
-		return request({
-			url: `/manager/message/${params.userIds}`,
-			method: 'post',
-			data: postData
-		})
-	},
 	viewed(messageId, callback) {
 		if (!messageId) return;
 		return request({
@@ -168,8 +146,6 @@ export default {
 	sendFlowMessage(data = {}, params = {}) {
 		let date = dayjs(new Date()).format('YYYY-MM-DD HH:mm:ss');
 		let obj = {
-			projectId: store.getters.project.id,
-			organizationId: store.getters.organization.id,
 			date: date,
 			dataId: params.dataId,
 			dataType: params.dataType
@@ -182,12 +158,29 @@ export default {
 			message: newData.message,
 			json: JSON.stringify(obj),
 			viewed: 0,
-			isCC: params.isCC
+			isCC: params.isCC,
+			projectId: store.getters.project.id,
+			organizationId: store.getters.organization.id
 		}
-		return request({
+		request({
 			url: `/manager/message/${params.receiver}`,
 			method: 'post',
 			data: postData
+		}).then(res => {
+			if (res.state) {
+				//消息通知Type9
+				let userList = params.isCC ? (params.receiver + ',' + params.isCC) : (params.receiver + '');
+				console.log(userList.split(',').map(node => 'workark' + node).join(','));
+				request({
+					url: `/api/reminder/send`,
+					method: 'post',
+					data: {
+						userId: userList.split(',').map(node => 'workark' + node).join(','),
+						data: {},
+						type: 9
+					}
+				})
+			}
 		})
 	},
 	messageContent(params) {

+ 14 - 0
virgo.wzfrontend/workark/src/views/message/list.vue

@@ -68,6 +68,9 @@
 		getMessagePageListByQuery
 	} from '@/api/message'
 	const detail = () => import('@/components/message/detail');
+	import {
+		mapGetters
+	} from 'vuex';
 	export default {
 		data() {
 			return {
@@ -84,6 +87,9 @@
 		},
 		methods: {
 			init() {
+				let reloadMessage = this.$store.getters.reloadMessage;
+				this.$store.dispatch('app/changeReloadMessage', !reloadMessage);
+				console.log(reloadMessage);
 				let data = {
 					projectId: this.$store.getters.project.id,
 					organizationId: this.$store.getters.organization.id,
@@ -111,6 +117,14 @@
 				this.init();
 			}
 		},
+		watch: {
+			chatList() {
+				this.init();
+			}
+		},
+		computed: {
+			...mapGetters(['chatList'])
+		},
 		components: {
 			detail
 		},

+ 191 - 191
virgo.wzfrontend/workark/src/views/work/property/change.vue

@@ -1,192 +1,192 @@
-<template>
-	<div class="hui-flex">
-		<div class="hui-flex-box yui-tree-box">
-			<level-tree class="border-box" @filterDevice="filterDevice" :type="1"></level-tree>
-			<div class="hui-tree-content">
-				<div class="hui-flex hui-content border-box">
-					<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 type="primary" v-permission="'/work/property/change/add'" size="small"
-								@click="insert">
-								新增变更
-							</el-button>
-						</div>
-						<div class="part-parent-node" style="margin-bottom: 10px;">资产层级:{{parentData.join('-')}}</div>
-						<div class="hui-flex-box">
-							<el-table :data="tableData" row-key="id" 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="变更类型" prop="type"></el-table-column>
-								<el-table-column label="资产编码" prop="assetNumber"></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/change/detail'"
-												@click="lookFlow(scope.row)">
-												详情
-											</span>
-											<span class="table-operation" v-permission="'/work/property/change/update'"
-												v-if="!scope.row.projectFlowId" @click="updateFlow(scope.row)">
-												编辑
-											</span>
-											<span class="table-operation" v-permission="'/work/property/change/delete'"
-												v-if="!scope.row.projectFlowId" @click="deleteFlow(scope.row)">
-												删除
-											</span>
-										</div>
-									</template>
-								</el-table-column>
-								<template slot="empty">
-									<el-empty description="暂无数据"></el-empty>
-								</template>
-							</el-table>
-						</div>
-						<div class="hui-content-pagination">
-							<el-pagination :pager-count="9" layout="prev, pager, next" :total="totalCount"
-								@current-change="currentChange" background>
-							</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 {
-		getFlowList,
-		deleteFlow
-	} from '@/api/property'
-	const flowForm = () => import('@/components/flow/flowForm');
-	const flowDetail = () => import('@/components/flow/flowDetail');
-	const levelTree = () => import('@/components/work/property/levelTree');
-
-	export default {
-		data() {
-			return {
-				flowType: 2,
-				tableData: [],
-				currPage: 1,
-				pageSize: 10,
-				totalCount: 0,
-				visible: false,
-				isUpdate: false,
-				detailId: '',
-				drawer: false,
-				nowData: {},
-				filterOption: {},
-				parentData: []
-			}
-		},
-		mounted() {
-			this.init();
-		},
-		methods: {
-			init() {
-				if (!this.auth('/work/property/change/list')) return;
-				let filterOption = {
-					projectId: this.$store.getters.project.id,
-					organizationId: this.$store.getters.organization.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));
-							if (node.operateDevice) node['assetNumber'] = node.operateDevice.assetNumber;
-							return node;
-						});
-						this.totalCount = res.data.totalCount;
-					}
-				})
-			},
-			filterDevice(option, parentData) {
-				this.parentData = parentData;
-				this.filterOption = option;
-				this.currPage = 1;
-				this.init();
-			},
-			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,
-			levelTree
-		},
-	}
-</script>
-
+<template>
+	<div class="hui-flex">
+		<div class="hui-flex-box yui-tree-box">
+			<level-tree class="border-box" @filterDevice="filterDevice" :type="1"></level-tree>
+			<div class="hui-tree-content">
+				<div class="hui-flex hui-content border-box">
+					<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 type="primary" v-permission="'/work/property/change/add'" size="small"
+								@click="insert">
+								新增变更
+							</el-button>
+						</div>
+						<div class="part-parent-node" style="margin-bottom: 10px;">资产层级:{{parentData.join('-')}}</div>
+						<div class="hui-flex-box">
+							<el-table :data="tableData" row-key="id" 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="变更类型" prop="type"></el-table-column>
+								<el-table-column label="资产编码" prop="assetNumber"></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-waiting"></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-danger"></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/change/detail'"
+												@click="lookFlow(scope.row)">
+												详情
+											</span>
+											<span class="table-operation" v-permission="'/work/property/change/update'"
+												v-if="!scope.row.projectFlowId" @click="updateFlow(scope.row)">
+												编辑
+											</span>
+											<span class="table-operation" v-permission="'/work/property/change/delete'"
+												v-if="!scope.row.projectFlowId" @click="deleteFlow(scope.row)">
+												删除
+											</span>
+										</div>
+									</template>
+								</el-table-column>
+								<template slot="empty">
+									<el-empty description="暂无数据"></el-empty>
+								</template>
+							</el-table>
+						</div>
+						<div class="hui-content-pagination">
+							<el-pagination :pager-count="9" layout="prev, pager, next" :total="totalCount"
+								@current-change="currentChange" background>
+							</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 {
+		getFlowList,
+		deleteFlow
+	} from '@/api/property'
+	const flowForm = () => import('@/components/flow/flowForm');
+	const flowDetail = () => import('@/components/flow/flowDetail');
+	const levelTree = () => import('@/components/work/property/levelTree');
+
+	export default {
+		data() {
+			return {
+				flowType: 2,
+				tableData: [],
+				currPage: 1,
+				pageSize: 10,
+				totalCount: 0,
+				visible: false,
+				isUpdate: false,
+				detailId: '',
+				drawer: false,
+				nowData: {},
+				filterOption: {},
+				parentData: []
+			}
+		},
+		mounted() {
+			this.init();
+		},
+		methods: {
+			init() {
+				if (!this.auth('/work/property/change/list')) return;
+				let filterOption = {
+					projectId: this.$store.getters.project.id,
+					organizationId: this.$store.getters.organization.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));
+							if (node.operateDevice) node['assetNumber'] = node.operateDevice.assetNumber;
+							return node;
+						});
+						this.totalCount = res.data.totalCount;
+					}
+				})
+			},
+			filterDevice(option, parentData) {
+				this.parentData = parentData;
+				this.filterOption = option;
+				this.currPage = 1;
+				this.init();
+			},
+			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,
+			levelTree
+		},
+	}
+</script>
+
 <style lang="scss"></style>

+ 194 - 194
virgo.wzfrontend/workark/src/views/work/property/depreciation.vue

@@ -1,195 +1,195 @@
-<template>
-	<div class="hui-flex">
-		<div class="hui-flex-box yui-tree-box">
-			<level-tree class="border-box" @filterDevice="filterDevice" :type="1"></level-tree>
-			<div class="hui-tree-content">
-				<div class="hui-flex hui-content border-box">
-					<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 type="primary" v-permission="'/work/property/depreciation/add'" size="small"
-								@click="insert">
-								新增折旧
-							</el-button>
-						</div>
-						<div class="part-parent-node" style="margin-bottom: 10px;">资产层级:{{parentData.join('-')}}</div>
-						<div class="hui-flex-box">
-							<el-table :data="tableData" row-key="id" 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="资产编码" prop="assetNumber"></el-table-column>
-								<el-table-column label="折旧内容" prop="depreciationContent"></el-table-column>
-								<el-table-column label="折旧描述" prop="remark"></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/depreciation/detail'"
-												@click="lookFlow(scope.row)">
-												详情
-											</span>
-											<span class="table-operation"
-												v-permission="'/work/property/depreciation/update'"
-												v-if="!scope.row.projectFlowId" @click="updateFlow(scope.row)">
-												编辑
-											</span>
-											<span class="table-operation"
-												v-permission="'/work/property/depreciation/delete'"
-												v-if="!scope.row.projectFlowId" @click="deleteFlow(scope.row)">
-												删除
-											</span>
-										</div>
-									</template>
-								</el-table-column>
-								<template slot="empty">
-									<el-empty description="暂无数据"></el-empty>
-								</template>
-							</el-table>
-						</div>
-						<div class="hui-content-pagination">
-							<el-pagination :pager-count="9" layout="prev, pager, next" :total="totalCount"
-								@current-change="currentChange" background>
-							</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 {
-		getFlowList,
-		deleteFlow
-	} from '@/api/property'
-	const flowForm = () => import('@/components/flow/flowForm');
-	const flowDetail = () => import('@/components/flow/flowDetail');
-	const levelTree = () => import('@/components/work/property/levelTree');
-	export default {
-		data() {
-			return {
-				flowType: 3,
-				tableData: [],
-				currPage: 1,
-				pageSize: 10,
-				totalCount: 0,
-				visible: false,
-				isUpdate: false,
-				detailId: '',
-				drawer: false,
-				nowData: {},
-				filterOption: {},
-				parentData: []
-			}
-		},
-		mounted() {
-			this.init();
-		},
-		methods: {
-			init() {
-				if (!this.auth('/work/property/depreciation/list')) return;
-				let filterOption = {
-					projectId: this.$store.getters.project.id,
-					organizationId: this.$store.getters.organization.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));
-							if (node.operateDevice) node['assetNumber'] = node.operateDevice.assetNumber;
-							return node;
-						});
-						this.totalCount = res.data.totalCount;
-					}
-				})
-			},
-			filterDevice(data, parentData) {
-				this.parentData = parentData;
-				this.filterOption = data;
-				this.currPage = 1;
-				this.init();
-			},
-			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,
-			levelTree
-		},
-	}
-</script>
-
+<template>
+	<div class="hui-flex">
+		<div class="hui-flex-box yui-tree-box">
+			<level-tree class="border-box" @filterDevice="filterDevice" :type="1"></level-tree>
+			<div class="hui-tree-content">
+				<div class="hui-flex hui-content border-box">
+					<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 type="primary" v-permission="'/work/property/depreciation/add'" size="small"
+								@click="insert">
+								新增折旧
+							</el-button>
+						</div>
+						<div class="part-parent-node" style="margin-bottom: 10px;">资产层级:{{parentData.join('-')}}</div>
+						<div class="hui-flex-box">
+							<el-table :data="tableData" row-key="id" 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="资产编码" prop="assetNumber"></el-table-column>
+								<el-table-column label="折旧内容" prop="depreciationContent"></el-table-column>
+								<el-table-column label="折旧描述" prop="remark"></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-waiting"></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-danger"></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/depreciation/detail'"
+												@click="lookFlow(scope.row)">
+												详情
+											</span>
+											<span class="table-operation"
+												v-permission="'/work/property/depreciation/update'"
+												v-if="!scope.row.projectFlowId" @click="updateFlow(scope.row)">
+												编辑
+											</span>
+											<span class="table-operation"
+												v-permission="'/work/property/depreciation/delete'"
+												v-if="!scope.row.projectFlowId" @click="deleteFlow(scope.row)">
+												删除
+											</span>
+										</div>
+									</template>
+								</el-table-column>
+								<template slot="empty">
+									<el-empty description="暂无数据"></el-empty>
+								</template>
+							</el-table>
+						</div>
+						<div class="hui-content-pagination">
+							<el-pagination :pager-count="9" layout="prev, pager, next" :total="totalCount"
+								@current-change="currentChange" background>
+							</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 {
+		getFlowList,
+		deleteFlow
+	} from '@/api/property'
+	const flowForm = () => import('@/components/flow/flowForm');
+	const flowDetail = () => import('@/components/flow/flowDetail');
+	const levelTree = () => import('@/components/work/property/levelTree');
+	export default {
+		data() {
+			return {
+				flowType: 3,
+				tableData: [],
+				currPage: 1,
+				pageSize: 10,
+				totalCount: 0,
+				visible: false,
+				isUpdate: false,
+				detailId: '',
+				drawer: false,
+				nowData: {},
+				filterOption: {},
+				parentData: []
+			}
+		},
+		mounted() {
+			this.init();
+		},
+		methods: {
+			init() {
+				if (!this.auth('/work/property/depreciation/list')) return;
+				let filterOption = {
+					projectId: this.$store.getters.project.id,
+					organizationId: this.$store.getters.organization.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));
+							if (node.operateDevice) node['assetNumber'] = node.operateDevice.assetNumber;
+							return node;
+						});
+						this.totalCount = res.data.totalCount;
+					}
+				})
+			},
+			filterDevice(data, parentData) {
+				this.parentData = parentData;
+				this.filterOption = data;
+				this.currPage = 1;
+				this.init();
+			},
+			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,
+			levelTree
+		},
+	}
+</script>
+
 <style lang="scss"></style>

+ 7 - 7
virgo.wzfrontend/workark/src/views/work/property/inventory.vue

@@ -39,7 +39,7 @@
 											<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-bage hui-state-waiting"></span>
 											<span class="hui-state-label">审核中</span>
 										</div>
 										<div v-if="scope.row.state == 3" class="hui-state">
@@ -47,7 +47,7 @@
 											<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-bage hui-state-danger"></span>
 											<span class="hui-state-label">未通过</span>
 										</div>
 									</template>
@@ -104,8 +104,8 @@
 		getFlowList,
 		deleteFlow
 	} from '@/api/property'
-	const flowForm = () => import('@/components/flow/flowForm');
-	const flowDetail = () => import('@/components/flow/flowDetail');
+	const flowForm = () => import('@/components/flow/flowForm');
+	const flowDetail = () => import('@/components/flow/flowDetail');
 	const levelTree = () => import('@/components/work/property/levelTree');
 	import config from '@/config'
 	export default {
@@ -130,10 +130,10 @@
 		methods: {
 			init() {
 				if (!this.auth('/work/property/inventory/list')) return;
-				let filterOption = {
+				let filterOption = {
 					projectId: this.$store.getters.project.id,
-					organizationId: this.$store.getters.organization.id,
-					flowType: this.flowType
+					organizationId: this.$store.getters.organization.id,
+					flowType: this.flowType
 				};
 				filterOption = Object.assign(filterOption, this.filterOption);
 				getFlowList(this.currPage, this.pageSize, filterOption).then(res => {

+ 2 - 2
virgo.wzfrontend/workark/src/views/work/property/register.vue

@@ -52,7 +52,7 @@
 											<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-bage hui-state-waiting"></span>
 											<span class="hui-state-label">审核中</span>
 										</div>
 										<div v-if="scope.row.state == 3" class="hui-state">
@@ -60,7 +60,7 @@
 											<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-bage hui-state-danger"></span>
 											<span class="hui-state-label">未通过</span>
 										</div>
 									</template>