AlanWong 2 år sedan
förälder
incheckning
2b0aba2055

+ 7 - 5
src/api/menu.ts

@@ -1,9 +1,11 @@
 import request from '@/benyun/utils/request'
-
+import store from '@/store/index'
 // 获取路由
 export const getRouters = () => {
-  return request({
-    url: '/system/menu/getRouters',
-    method: 'get'
-  })
+	return request({
+		url: '/system/menu/getRouters',
+		method: 'get',
+		// params: { tenantId: store.getters.userInfo.tenantId }
+		params: { tenantId: '000000' }
+	})
 }

+ 1 - 1
src/components/Assembly/order.vue

@@ -12,7 +12,7 @@ import { Component, Prop, Vue, Watch, Mixins } from "vue-property-decorator";
 		propValue : any
 		
 		created(){
-			console.log(this.propValue);
+			// console.log(this.propValue);
 		}
 	}
 

+ 3 - 3
src/views/audit/orderTask/index.vue

@@ -575,12 +575,12 @@
 									attr: {
 										placeholder: '请选择状态',
 										clearable: true,
-										valueType:'number',
+										// valueType:'number',
 										data: [{
-											value: '0',
+											value: 0,
 											label: '未接单'
 										}, {
-											value: '1',
+											value: 1,
 											label: '已接单'
 										}]
 									}

+ 16 - 26
src/views/audit/supplier/index.vue

@@ -3,7 +3,7 @@
 		<div class="bill-left">
 			<div class="bill-tab">
 				<div class="tab-title">导航</div>
-				<side-tree :propConfig="treeConfig" @onChange="onChangeTree" />
+				<side-tree :propConfig="treeConfig" @onChange="onChangeTree" ref="sideTree" />
 			</div>
 		</div>
 		<div class="bill-main">
@@ -15,8 +15,8 @@
 		<el-dialog :title="popTitle+'供应商'" :visible.sync="dialogFormVisible" width="30%">
 			<by-form :propConfig="addConfig" ref="addFormId">
 				<template v-slot:status class="clearfix">
-					<el-radio class="fl" style="margin-top: 8px;" v-model="radio" :label="0">正常</el-radio>
-					<el-radio class="fl" style="margin-top: 8px;" v-model="radio" :label="1">禁用</el-radio>
+					<el-radio class="fl" style="margin-top: 8px;" v-model="radio" :label="1">正常</el-radio>
+					<el-radio class="fl" style="margin-top: 8px;" v-model="radio" :label="2">禁用</el-radio>
 				</template>
 			</by-form>
 			<div slot="footer" class="dialog-footer">
@@ -37,7 +37,7 @@
 		timeNum = 0;
 		timer : any = null
 		popTitle : any = ''
-		radio : any = 0
+		radio : any = 1
 		dialogFormVisible : boolean = false
 		parentId: any = '';
 		treeConfig = {
@@ -97,10 +97,10 @@
 								placeholder: '请选择状态',
 								clearable: true,
 								data: [{
-									value: 0,
+									value: 1,
 									label: '正常'
 								}, {
-									value: 1,
+									value: 2,
 									label: '禁用'
 								}]
 							}
@@ -253,16 +253,15 @@
 					api.saveList(query, 'maindataMaterialSupplier').then((res : any) => {
 						if (res.code === 200) {
 							this.$message.success(this.popTitle + '成功!');
+							(this as any).$refs.sideTree.request();
 							this.getDataList();
 						} else this.$message.error(res.msg);
 					})
 				} else if (this.popTitle === '编辑') {
 					api.updateList(query, 'maindataMaterialSupplier').then((res : any) => {
 						if (res.code === 200) {
-							this.$message({
-								type: 'success',
-								message: this.popTitle + '成功!'
-							});
+							this.$message.success(this.popTitle + '成功!');
+							(this as any).$refs.sideTree.request();
 							this.getDataList();
 						} else this.$message.error(res.msg);
 					})
@@ -302,7 +301,7 @@
 		onAdd() {
 			this.popTitle = '新增'
 			this.dialogFormVisible = true;
-			this.radio = 0
+			this.radio = 1
 			setTimeout(() => {
 				if ((this as any).$refs.addFormId) (this as any).$refs.addFormId.setValue('');
 			}, 0)
@@ -324,7 +323,7 @@
 				selectData.map((v : any) => {
 					ids += v.id + ','
 				})
-			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
+			} else return this.$message.warning('请选择删除数据');
 			ids = ids.slice(0, ids.length - 1);
 			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
@@ -334,19 +333,12 @@
 			}).then(() => {
 				api.deleteList({ ids: ids }, 'maindataMaterialSupplier').then((res : any) => {
 					if (res.code === 200) {
+						(this as any).$refs.sideTree.request();
 						this.getDataList();
-						this.$message({
-							type: 'success',
-							message: '删除成功!'
-						});
+						this.$message.success('删除成功!');
 					} else this.$message.error(res.msg);
 				})
-			}).catch(() => {
-				this.$message({
-					type: 'info',
-					message: '已取消删除'
-				});
-			});
+			}).catch(() => this.$message.info('已取消删除'));
 		}
 		// 操作删除
 		doDelete2(item : any) {
@@ -358,11 +350,9 @@
 			}).then(() => {
 				api.deleteList({ ids: item.id }, 'maindataMaterialSupplier').then((res : any) => {
 					if (res.code === 200) {
+						(this as any).$refs.sideTree.request();
 						this.getDataList();
-						this.$message({
-							type: 'success',
-							message: '删除成功!'
-						});
+						this.$message.success('删除成功!');
 					} else this.$message.error(res.msg);
 				})
 			}).catch(() => {