瀏覽代碼

修改一些已知问题

AlanWong 2 年之前
父節點
當前提交
b08684b426

+ 5 - 5
src/views/audit/agencyGoods/index.vue

@@ -342,12 +342,12 @@
 				if (res.code === 200) {
 					let data = res.data;
 					this.radio = data.status;
-					api.single({ id: data.parentId }, 'maindataMaterialOrganizationCategory').then((res : any) => {
-						if (res.code === 200) {
+					api.single({ id: data.parentId }, 'maindataMaterialOrganizationCategory').then((v : any) => {
+						if (v.code === 200) {
 							loading.close();
-							data.parentName = res.data.name;
+							data.parentName = v.data.name;
 							this.dialogFormVisible = true;
-							this.$nextTick(() => (this as any).$refs.addFormId.setValue(data));
+							setTimeout(() => {(this as any).$refs.addFormId.setValue(data)},0);
 						}
 					})
 				}
@@ -361,7 +361,7 @@
 				type: 'warning',
 				center: true
 			}).then(() => {
-				api.delCategoryId({ id: item.id }, 'maindataMaterialOrganizationCategory').then((res : any) => {
+				api.deleteList({ id: item.id }, 'maindataMaterialOrganizationCategory').then((res : any) => {
 					if (res.code === 200) {
 						(this as any).$refs.sideTree.request();
 						this.getDataList();

+ 34 - 20
src/views/audit/attribute/index.vue

@@ -12,30 +12,32 @@
 					<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>
 				</template>
-				<template v-slot:attributeValue="{value}">
+				<template v-slot:attributeValue>
 					<div style="margin-bottom: 20px;" v-if="tableConfig.length>0">
-						<div v-for="(item,index) of tableConfig" :key="index">
-							<div class="tab-title">{{item.title}} <i class="el-icon-circle-close" @click="closeGroup(index)"></i>
+						<div v-for="(item,index) of tableConfig" :key="index" style="position: relative;">
+							<div>{{item.title}} <i class="el-icon-circle-close" @click="closeGroup(index)"></i>
+							</div>
+							<div class="clearfix">
+								<el-tag class="item-tab fl" :disable-transitions="true" :key="i" v-for="(tag,i) of item.list" closable
+									@close="handleClose(tag,index)">
+									{{tag}}
+								</el-tag>
+								<by-input class="input-new-tag fl" :ref="'getValue_'+index" maxlength="20"></by-input>
+								<el-button class="button-new-tag fl" @click="showInput(index)">添加</el-button>
 							</div>
-							<el-tag class="item-tab" :disable-transitions="true" :key="i" v-for="(tag,i) of item.list" closable
-								@close="handleClose(tag,index)">
-								{{tag}}
-							</el-tag>
-							<by-input class="input-new-tag" :ref="'getValue_'+index"></by-input>
-							<el-button class="button-new-tag" @click="showInput(index)">添加</el-button>
 						</div>
 					</div>
 					<div style="display: flex;">
 						<div style="margin-right: 20px;">
 							<label>规格:</label>
 							<div class="el-input el-input--small" style="width: 250px;">
-								<input type="text" v-model="norms" placeholder="请输入规格" class="el-input__inner">
+								<input type="text" v-model="norms" placeholder="请输入规格" class="el-input__inner" maxlength="20">
 							</div>
 						</div>
 						<div style="margin-right: 20px;">
 							<label>规格值:</label>
 							<div class="el-input el-input--small" style="width: 250px;">
-								<input type="text" v-model="normsValue" placeholder="请输入规格值" class="el-input__inner">
+								<input type="text" v-model="normsValue" placeholder="请输入规格值" class="el-input__inner" maxlength="20">
 							</div>
 						</div>
 						<div @click="doComfirm" class="el-button el-button--primary el-button--small">确定</div>
@@ -264,12 +266,25 @@
 		}
 		// 删除标签
 		handleClose(tag : any, index : any) {
-			// console.log(tag);
-			this.tableConfig[index].list.splice(this.tableConfig[index].list.indexOf(tag), 1);
+			this.$confirm('确定删除吗', '注意', {
+				confirmButtonText: '确定',
+				cancelButtonText: '取消',
+				type: 'warning',
+				center: true
+			}).then(() => {
+				this.tableConfig[index].list.splice(this.tableConfig[index].list.indexOf(tag), 1);
+			}).catch(() => this.$message.info('已取消删除'));
 		}
 		// 删除数组
 		closeGroup(index : any) {
-			this.tableConfig.splice(index, 1)
+			this.$confirm('确定删除吗', '注意', {
+				confirmButtonText: '确定',
+				cancelButtonText: '取消',
+				type: 'warning',
+				center: true
+			}).then(() => {
+				this.tableConfig.splice(index, 1)
+			}).catch(() => this.$message.info('已取消删除'));
 		}
 		// 添加新规格
 		doComfirm() {
@@ -366,8 +381,11 @@
 					let data = res.data;
 					this.dialogFormVisible = true;
 					this.radio = data.status;
+					if (data.attributeValue) this.tableConfig = JSON.parse(data.attributeValue);
+					// console.log(this.tableConfig);
 					loading.close();
-					this.$nextTick(() => (this as any).$refs.addFormId.setValue(data));
+					setTimeout(() => {(this as any).$refs.addFormId.setValue(data)},0);
+					// this.$nextTick(() => (this as any).$refs.addFormId.setValue(data));
 				}
 			})
 		}
@@ -425,13 +443,9 @@
 		display: flex;
 		padding: 16px;
 
-
-		.tab-title {
-			// padding: 10px 0 0;
-		}
-
 		.item-tab {
 			margin-right: 16px;
+			margin-top: 3px;
 		}
 
 		.input-new-tag {

+ 15 - 14
src/views/audit/brand/index.vue

@@ -213,20 +213,20 @@
 				let loading = this.$loading({ target: '.main-container' });
 				if (this.popTitle === '新增') {
 					api.saveList(query, 'maindataMaterialBrand').then((res : any) => {
+						loading.close();
 						if (res.code === 200) {
-							loading.close();
 							this.$message.success('新增成功');
 							this.getDataList();
 						} else this.$message.error(res.msg);
-					})
+					}).catch(() => loading.close());
 				} else if (this.popTitle === '编辑') {
 					api.updateList(query, 'maindataMaterialBrand').then((res : any) => {
+						loading.close();
 						if (res.code === 200) {
-							loading.close();
 							this.$message.success('编辑成功');
 							this.getDataList();
 						} else this.$message.error(res.msg);
-					})
+					}).catch(() => loading.close());
 				}
 			})
 		}
@@ -246,6 +246,7 @@
 		getPageList(query : any) {
 			let loading = this.$loading({ target: '.main-container' });
 			api.pageList(query, 'maindataMaterialBrand').then((res : any) => {
+				loading.close();
 				if (res.code === 200) {
 					(this.$refs.moduleView as any).setTableValue(res.data.records);
 					let page = {
@@ -254,12 +255,8 @@
 						total: res.data.total //总条数
 					};
 					(this.$refs.moduleView as any).setPage(page);
-					loading.close();
-				} else {
-					loading.close();0
-					this.$message.error(res.msg);
-				}
-			})
+				} else this.$message.error(res.msg);
+			}).catch(() => loading.close());
 		}
 		// 工具栏方法
 		clickHandle(e : any) {
@@ -278,14 +275,14 @@
 			this.popTitle = '编辑';
 			let loading = this.$loading({ target: '.main-container' });
 			api.single({ id: e.id }, 'maindataMaterialBrand').then((res : any) => {
+				loading.close();
 				if (res.code === 200) {
 					let data = res.data;
 					this.dialogFormVisible = true;
 					this.radio = data.status;
-					loading.close();
 					this.$nextTick(() => (this as any).$refs.addFormId.setValue(data));
 				}
-			})
+			}).catch(() => loading.close());
 		}
 		// 工具栏删除
 		onDelete() {
@@ -303,12 +300,14 @@
 				type: 'warning',
 				center: true
 			}).then(() => {
+				let loading = this.$loading({ target: '.main-container' });
 				api.deleteList({ ids: ids }, 'maindataMaterialBrand').then((res : any) => {
+					loading.close();
 					if (res.code === 200) {
 						this.getDataList();
 						this.$message.success('删除成功');
 					} else this.$message.error(res.msg);
-				})
+				}).catch(() => loading.close());
 			}).catch(() => this.$message.info('已取消删除'));
 		}
 		// 操作删除
@@ -319,12 +318,14 @@
 				type: 'warning',
 				center: true
 			}).then(() => {
+				let loading = this.$loading({ target: '.main-container' });
 				api.deleteList({ ids: item.id }, 'maindataMaterialBrand').then((res : any) => {
+					loading.close();
 					if (res.code === 200) {
 						this.getDataList();
 						this.$message.success('删除成功');
 					} else this.$message.error(res.msg);
-				})
+				}).catch(() => loading.close());
 			}).catch(() => this.$message.info('已取消删除'));
 		}
 		// 刷新/重置

+ 135 - 52
src/views/audit/distributor/index.vue

@@ -1,29 +1,34 @@
 <template>
 	<div class="my-container">
-		<div class="bill-left">
-			<div class="bill-tab">
-				<div class="tab-title">导航</div>
-				<side-tree :propConfig="treeConfig" @onChange="onChangeTree" ref="sideTree" />
+		<transition-group name="fade" style="position: relative;width: 100%;display: flex;">
+			<div class="bill-left" v-show="isShow==='home'" key="item">
+				<div class="bill-tab">
+					<div class="bill-title">导航</div>
+					<side-tree :propConfig="treeConfig" @onChange="onChangeTree" ref="sideTree" />
+				</div>
 			</div>
-		</div>
-		<div class="bill-main">
-			<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
-				@resert="onRefresh" @clickHandle="clickHandle" @detail="openEdit" @onRefresh="onRefresh">
-			</module-view>
-		</div>
-		<!-- 新增/编辑弹窗 -->
-		<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>
-				</template>
-			</by-form>
-			<div slot="footer" class="dialog-footer">
-				<el-button @click="dialogFormVisible = false">取 消</el-button>
-				<el-button type="primary" @click="confirm">确 定</el-button>
+			<div class="bill-main" v-show="isShow==='home'" key="item2">
+				<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
+					@resert="onRefresh" @clickHandle="clickHandle" @detail="openEdit" @onRefresh="onRefresh">
+				</module-view>
 			</div>
-		</el-dialog>
+			<!-- 新增/编辑弹窗 -->
+			<div class="detil" v-show="isShow==='add'" key="item3">
+				<by-tool :propConfig="toolConfig" @clickHandle="insideTools" ref="byTool" />
+				<div class="box-shadow">
+					<by-form :propConfig="addConfig" ref="addFormId">
+						<template v-slot:k3ServerUrl="{value}" class="clearfix">
+							<i class="el-icon-question" title="私有云必须配置金蝶云星空产品地址,K3Cloud/结尾,若为公有云则必须置空"></i>
+							<vxe-input v-model="value.k3ServerUrl" style="width:calc(100% - 25px);margin-left: 10px;"></vxe-input>
+						</template>
+						<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>
+						</template>
+					</by-form>
+				</div>
+			</div>
+		</transition-group>
 	</div>
 </template>
 <script lang="ts">
@@ -32,12 +37,19 @@
 	import Assembly from "@/components/Assembly/material.vue";
 	@Component
 	export default class Supplier extends Vue {
+		isShow = 'home'
 		timeNum = 0;
 		timer : any = null
 		popTitle : any = ''
 		radio : any = 0
 		dialogFormVisible : boolean = false
 		categoryIds : any = '';
+		toolConfig = {
+			tools: {
+				return: true,
+				save: true,
+			}
+		}
 		treeConfig = {
 			attr: {
 				retConfig: {
@@ -174,7 +186,7 @@
 		}
 		addConfig = {
 			attr: {
-				size: 'small',
+				size: 'medium',
 				rules: {
 					categoryName: [{
 						required: true, message: '请输入父级', trigger: 'change'
@@ -193,9 +205,8 @@
 			columns: [
 				[
 					{
-						span: 23,
+						span: 6,
 						label: '父级',
-						labelWidth: '70px',
 						prop: 'categoryName',
 						component: 'select-tree',
 						compConfig: {
@@ -214,42 +225,33 @@
 						}
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '名称',
 						prop: 'name',
 						component: 'by-input',
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '负责人',
 						prop: 'contacts',
 						component: 'by-input',
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '手机号码',
 						prop: 'telephone',
 						component: 'by-input',
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '联系电话',
 						prop: 'phonenum',
 						component: 'by-input',
 					},
+				],
+				[
 					{
-						span: 23,
-						labelWidth: '70px',
-						label: '状态',
-						slot: true,
-						prop: 'status',
-					},
-					{
-						span: 23,
+						span: 6,
 						labelWidth: '110px',
 						label: '财务系统类型',
 						prop: 'financeType',
@@ -262,15 +264,60 @@
 									{
 										value: '金蝶K3',
 										label: '金蝶K3'
-									}, {
-										value: '用友U8',
-										label: '用友U8'
 									},
+									// {
+									// 	value: '用友U8',
+									// 	label: '用友U8'
+									// },
 								]
 							}
 						}
 					},
 				],
+				[
+					{
+						span: 6,
+						label: '登录授权ID',
+						slot: true,
+						prop: 'k3AppId',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: '用户名称',
+						slot: true,
+						prop: 'k3UserName',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: '数据中心ID',
+						slot: true,
+						prop: 'k3AcctId',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: '应用秘钥',
+						slot: true,
+						prop: 'k3AppSec',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: 'URL地址',
+						slot: true,
+						prop: 'k3ServerUrl',
+					},
+				],
+				[
+					{
+						span: 6,
+						label: '状态',
+						slot: true,
+						prop: 'status',
+					},
+				]
 			]
 		}
 		mounted() {
@@ -295,37 +342,49 @@
 				}
 			})
 		}
-		// 确认新增/编辑
+		// 内页工具栏方法
+		insideTools(e : any) {
+			console.log(e);
+			if (e === 'onReturn') this.isShow = 'home';
+			if (e === 'onSave') this.confirm();
+		}
+		// 保存新增/编辑
 		confirm() {
 			(this as any).$refs.addFormId.validate().then(() => {
 				let query = (this as any).$refs.addFormId.getValue();
-				console.log(query);
 				query.status = this.radio;
 				// 手机验证
 				let reg = /^1[3456789]\d{9}$/;
 				let reg2 = /^0\d{2,3}-\d{7,8}$/;
 				if (query.telephone && !reg.test(query.telephone)) return this.$message.warning('请输入正确手机号码');
 				if (query.phonenum && !reg2.test(query.phonenum)) return this.$message.warning('请输入正确联系电话');
+				if (!query.telephone) query.telephone = null;
+				if (!query.phonenum) query.phonenum = null;
 				this.dialogFormVisible = false;
-
+				console.log(query);
+				let loading = this.$loading({ target: '.main-container' });
 				if (this.popTitle === '新增') {
 					api.saveList(query, 'maindataMaterialDistributor').then((res : any) => {
 						if (res.code === 200) {
-							this.$message.success(this.popTitle + '成功!');
+							loading.close();
+							this.$message.success('保存成功');
 							(this as any).$refs.sideTree.request();
+							this.isShow = 'home'; // 展示类型
 							this.getDataList();
 						} else this.$message.error(res.msg);
 					})
 				} else if (this.popTitle === '编辑') {
 					api.updateList(query, 'maindataMaterialDistributor').then((res : any) => {
 						if (res.code === 200) {
-							this.$message.success(this.popTitle + '成功!');
+							loading.close();
+							this.$message.success('编辑成功');
 							(this as any).$refs.sideTree.request();
+							this.isShow = 'home'; // 展示类型
 							this.getDataList();
 						} else this.$message.error(res.msg);
 					})
 				}
-
+				
 			})
 		}
 		// 获取列表数据
@@ -364,6 +423,7 @@
 		}
 		// 打开新增
 		onAdd() {
+			this.isShow = 'add'; // 展示类型
 			this.popTitle = '新增'
 			this.dialogFormVisible = true;
 			this.radio = 0
@@ -374,6 +434,7 @@
 		// 打开编辑
 		openEdit(e : any) {
 			console.log('打开编辑 ==> ', e);
+			this.isShow = 'add'; // 展示类型
 			this.popTitle = '编辑'
 			let loading = this.$loading({ target: '.main-container' });
 			api.single({ id: e.id }, 'maindataMaterialDistributor').then((res : any) => {
@@ -400,7 +461,7 @@
 					if (res.code === 200) {
 						(this as any).$refs.sideTree.request();
 						this.getDataList();
-						this.$message.success('删除成功!');
+						this.$message.success('删除成功');
 					} else this.$message.error(res.msg);
 				})
 			}).catch(() => this.$message.info('已取消删除'));
@@ -420,7 +481,6 @@
 		box-sizing: border-box;
 		display: flex;
 		padding: 16px;
-
 		.search-btn {
 			width: 100%;
 			display: flex;
@@ -515,5 +575,28 @@
 				z-index: 1;
 			}
 		}
+
+		.detil {
+			width: 100%;
+
+			.box-shadow {
+				box-shadow: 0 2px 12px 0 rgb(0 0 0 / 10%);
+				padding: 20px;
+				border-radius: 4px;
+				border: 1px solid #e6ebf5;
+				background-color: #fff;
+				overflow: hidden;
+				color: #303133;
+				-webkit-transition: .3s;
+				transition: .3s;
+				margin-top: 20px;
+			}
+		}
+
+		@media screen and (min-width: 1700px) {
+			.bill-main {
+				min-width: 1450px;
+			}
+		}
 	}
 </style>

+ 136 - 52
src/views/audit/manufacturer/index.vue

@@ -1,29 +1,34 @@
 <template>
 	<div class="my-container">
-		<div class="bill-left">
-			<div class="bill-tab">
-				<div class="tab-title">导航</div>
-				<side-tree :propConfig="treeConfig" @onChange="onChangeTree" ref="sideTree" />
+		<transition-group name="fade" style="position: relative;width: 100%;display: flex;">
+			<div class="bill-left" v-show="isShow==='home'" key="item">
+				<div class="bill-tab">
+					<div class="bill-title">导航</div>
+					<side-tree :propConfig="treeConfig" @onChange="onChangeTree" ref="sideTree" />
+				</div>
 			</div>
-		</div>
-		<div class="bill-main">
-			<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
-				@resert="onRefresh" @clickHandle="clickHandle" @detail="openEdit" @onRefresh="onRefresh">
-			</module-view>
-		</div>
-		<!-- 新增/编辑弹窗 -->
-		<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>
-				</template>
-			</by-form>
-			<div slot="footer" class="dialog-footer">
-				<el-button @click="dialogFormVisible = false">取 消</el-button>
-				<el-button type="primary" @click="confirm">确 定</el-button>
+			<div class="bill-main" v-show="isShow==='home'" key="item2">
+				<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
+					@resert="onRefresh" @clickHandle="clickHandle" @detail="openEdit" @onRefresh="onRefresh">
+				</module-view>
 			</div>
-		</el-dialog>
+			<!-- 新增/编辑弹窗 -->
+			<div class="detil" v-show="isShow==='add'" key="item3">
+				<by-tool :propConfig="toolConfig" @clickHandle="insideTools" ref="byTool" />
+				<div class="box-shadow">
+					<by-form :propConfig="addConfig" ref="addFormId">
+						<template v-slot:k3ServerUrl="{value}" class="clearfix">
+							<i class="el-icon-question" title="私有云必须配置金蝶云星空产品地址,K3Cloud/结尾,若为公有云则必须置空"></i>
+							<vxe-input v-model="value.k3ServerUrl" style="width:calc(100% - 25px);margin-left: 10px;"></vxe-input>
+						</template>
+						<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>
+						</template>
+					</by-form>
+				</div>
+			</div>
+		</transition-group>
 	</div>
 </template>
 <script lang="ts">
@@ -32,12 +37,19 @@
 	import Assembly from "@/components/Assembly/material.vue";
 	@Component
 	export default class Supplier extends Vue {
+		isShow = 'home'
 		timeNum = 0;
 		timer : any = null
 		popTitle : any = ''
 		radio : any = 0
 		dialogFormVisible : boolean = false
 		categoryIds : any = '';
+		toolConfig = {
+			tools: {
+				return: true,
+				save: true,
+			}
+		}
 		treeConfig = {
 			attr: {
 				retConfig: {
@@ -174,7 +186,7 @@
 		}
 		addConfig = {
 			attr: {
-				size: 'small',
+				size: 'medium',
 				rules: {
 					categoryName: [{
 						required: true, message: '请输入父级', trigger: 'change'
@@ -193,9 +205,8 @@
 			columns: [
 				[
 					{
-						span: 23,
+						span: 6,
 						label: '父级',
-						labelWidth: '70px',
 						prop: 'categoryName',
 						component: 'select-tree',
 						compConfig: {
@@ -214,42 +225,33 @@
 						}
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '名称',
 						prop: 'name',
 						component: 'by-input',
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '负责人',
 						prop: 'contacts',
 						component: 'by-input',
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '手机号码',
 						prop: 'telephone',
 						component: 'by-input',
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '联系电话',
 						prop: 'phonenum',
 						component: 'by-input',
 					},
+				],
+				[
 					{
-						span: 23,
-						labelWidth: '70px',
-						label: '状态',
-						slot: true,
-						prop: 'status',
-					},
-					{
-						span: 23,
+						span: 6,
 						labelWidth: '110px',
 						label: '财务系统类型',
 						prop: 'financeType',
@@ -262,15 +264,61 @@
 									{
 										value: '金蝶K3',
 										label: '金蝶K3'
-									}, {
-										value: '用友U8',
-										label: '用友U8'
 									},
+									// {
+									// 	value: '用友U8',
+									// 	label: '用友U8'
+									// },
 								]
 							}
 						}
 					},
 				],
+				[
+					{
+						span: 6,
+						label: '登录授权ID',
+						slot: true,
+						prop: 'k3AppId',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: '用户名称',
+						slot: true,
+						prop: 'k3UserName',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: '数据中心ID',
+						slot: true,
+						prop: 'k3AcctId',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: '应用秘钥',
+						slot: true,
+						prop: 'k3AppSec',
+						component: 'by-input',
+					},
+					{
+						labelWidth: '90px',
+						span: 6,
+						label: 'URL地址',
+						slot: true,
+						prop: 'k3ServerUrl',
+					},
+				],
+				[
+					{
+						span: 6,
+						label: '状态',
+						slot: true,
+						prop: 'status',
+					},
+				]
 			]
 		}
 		mounted() {
@@ -295,37 +343,49 @@
 				}
 			})
 		}
-		// 确认新增/编辑
+		// 内页工具栏方法
+		insideTools(e : any) {
+			console.log(e);
+			if (e === 'onReturn') this.isShow = 'home';
+			if (e === 'onSave') this.confirm();
+		}
+		// 保存新增/编辑
 		confirm() {
 			(this as any).$refs.addFormId.validate().then(() => {
 				let query = (this as any).$refs.addFormId.getValue();
-				console.log(query);
 				query.status = this.radio;
 				// 手机验证
 				let reg = /^1[3456789]\d{9}$/;
 				let reg2 = /^0\d{2,3}-\d{7,8}$/;
 				if (query.telephone && !reg.test(query.telephone)) return this.$message.warning('请输入正确手机号码');
 				if (query.phonenum && !reg2.test(query.phonenum)) return this.$message.warning('请输入正确联系电话');
+				if (!query.telephone) query.telephone = null;
+				if (!query.phonenum) query.phonenum = null;
 				this.dialogFormVisible = false;
-
+				console.log(query);
+				let loading = this.$loading({ target: '.main-container' });
 				if (this.popTitle === '新增') {
 					api.saveList(query, 'maindataMaterialManufacturer').then((res : any) => {
 						if (res.code === 200) {
-							this.$message.success(this.popTitle + '成功!');
+							loading.close();
+							this.$message.success('保存成功');
 							(this as any).$refs.sideTree.request();
+							this.isShow = 'home'; // 展示类型
 							this.getDataList();
 						} else this.$message.error(res.msg);
 					})
 				} else if (this.popTitle === '编辑') {
 					api.updateList(query, 'maindataMaterialManufacturer').then((res : any) => {
 						if (res.code === 200) {
-							this.$message.success(this.popTitle + '成功!');
+							loading.close();
+							this.$message.success('编辑成功');
 							(this as any).$refs.sideTree.request();
+							this.isShow = 'home'; // 展示类型
 							this.getDataList();
 						} else this.$message.error(res.msg);
 					})
 				}
-
+				
 			})
 		}
 		// 获取列表数据
@@ -364,6 +424,7 @@
 		}
 		// 打开新增
 		onAdd() {
+			this.isShow = 'add'; // 展示类型
 			this.popTitle = '新增'
 			this.dialogFormVisible = true;
 			this.radio = 0
@@ -374,6 +435,7 @@
 		// 打开编辑
 		openEdit(e : any) {
 			console.log('打开编辑 ==> ', e);
+			this.isShow = 'add'; // 展示类型
 			this.popTitle = '编辑'
 			let loading = this.$loading({ target: '.main-container' });
 			api.single({ id: e.id }, 'maindataMaterialManufacturer').then((res : any) => {
@@ -400,7 +462,7 @@
 					if (res.code === 200) {
 						(this as any).$refs.sideTree.request();
 						this.getDataList();
-						this.$message.success('删除成功!');
+						this.$message.success('删除成功');
 					} else this.$message.error(res.msg);
 				})
 			}).catch(() => this.$message.info('已取消删除'));
@@ -420,7 +482,6 @@
 		box-sizing: border-box;
 		display: flex;
 		padding: 16px;
-
 		.search-btn {
 			width: 100%;
 			display: flex;
@@ -515,5 +576,28 @@
 				z-index: 1;
 			}
 		}
+
+		.detil {
+			width: 100%;
+
+			.box-shadow {
+				box-shadow: 0 2px 12px 0 rgb(0 0 0 / 10%);
+				padding: 20px;
+				border-radius: 4px;
+				border: 1px solid #e6ebf5;
+				background-color: #fff;
+				overflow: hidden;
+				color: #303133;
+				-webkit-transition: .3s;
+				transition: .3s;
+				margin-top: 20px;
+			}
+		}
+
+		@media screen and (min-width: 1700px) {
+			.bill-main {
+				min-width: 1450px;
+			}
+		}
 	}
 </style>

+ 47 - 41
src/views/audit/orderTask/index.vue

@@ -880,25 +880,27 @@
 				});
 				if (query.deliveryData) query.deliveryData = query.deliveryData + ' 00:00:00';
 				console.log('保存参数query ==> ', query);
-
+				let loading = this.$loading({ target: '.main-container' });
 				if (this.isAdd) {
 					api.saveList(query, 'supplyTaskOrder').then((res : any) => {
 						if (res.code === 200) {
+							loading.close();
 							this.isAdd = false;
 							this.isChange = false;
 							this.isSubmit = true;
 							this.$message.success('保存成功');
 							this.dataId = res.data;
 						} else this.$message.error(res.msg);
-					})
+					}).catch(() => loading.close());
 				} else if (this.tabType === 'all' || this.tabType === 'draftsBox') {
 					api.updateList(query, 'supplyTaskOrder').then((res : any) => {
 						if (res.code === 200) {
+							loading.close();
 							this.$message.success('保存成功');
 							this.isChange = false;
 							this.isSubmit = true;
 						} else this.$message.error(res.msg);
-					})
+					}).catch(() => loading.close());
 				};
 
 			})
@@ -928,11 +930,11 @@
 		openEdit(e : any) {
 			e = e.row ? e.row : e;
 			// console.log('编辑tabType ==>', this.tabType);
-			// console.log('编辑 ==>', e);
 			let loading = this.$loading({ target: '.main-container' });
 			api.single({ id: e.id }, 'supplyTaskOrder').then((res : any) => {
 				if (res.code === 200) {
 					let parentData = res.data ? res.data : e;
+					console.log('编辑 ==>', parentData);
 					this.baseInfo = parentData;
 					if (parentData.sourceType === '手工输入') {
 						// 已提交
@@ -1081,7 +1083,7 @@
 									(this.$refs.bill as any).showTab = this.tabType;
 									loading.close();
 								} else this.$message.error(res.msg)
-							})
+							}).catch(() => loading.close());
 						}).catch(() => this.$message.info('已取消提交'));
 					}
 				}
@@ -1097,15 +1099,13 @@
 				type: 'warning',
 				center: true
 			}).then(() => {
-				if (this.tabType === 'smt') {
-					api.cancelSubmission({ id: e.id }, 'supplyTaskOrder').then((res : any) => {
-						if (res.code === 200) {
-							this.$message.success('反提交成功');
-							this.clickTab(this.tabType);
-							loading.close();
-						} else this.$message.error(res.msg)
-					})
-				}
+				api.cancelSubmission({ id: e.id }, 'supplyTaskOrder').then((res : any) => {
+					if (res.code === 200) {
+						this.$message.success('反提交成功');
+						this.clickTab(this.tabType);
+						loading.close();
+					} else this.$message.error(res.msg)
+				}).catch(() => loading.close());
 			}).catch(() => this.$message.info('已取消反提交'));
 		}
 		// 工具栏反提交
@@ -1117,17 +1117,15 @@
 				type: 'warning',
 				center: true
 			}).then(() => {
-				if (this.tabType === 'smt') {
-					let loading = this.$loading({ target: '.main-container' });
-					api.cancelSubmission({ id: this.baseInfo.id }, 'supplyTaskOrder').then((res : any) => {
-						if (res.code === 200) {
-							this.$message.success('反提交成功');
-							this.clickTab(this.tabType);
-							(this.$refs.bill as any).showTab = 'smt';
-							loading.close();
-						} else this.$message.error(res.msg)
-					})
-				}
+				let loading = this.$loading({ target: '.main-container' });
+				api.cancelSubmission({ id: this.baseInfo.id }, 'supplyTaskOrder').then((res : any) => {
+					if (res.code === 200) {
+						this.$message.success('反提交成功');
+						this.clickTab(this.tabType);
+						(this.$refs.bill as any).showTab = 'smt';
+						loading.close();
+					} else this.$message.error(res.msg)
+				}).catch(() => loading.close());
 			}).catch(() => this.$message.info('已取消反提交'));
 		}
 		// 获取机构数据
@@ -1143,21 +1141,27 @@
 			e.totalPrice = e.realityPrice - e.prePrice;
 		}
 		// 派单
-		onDispatch(e : any) {
-			console.log('派单 ==>', e);
-			this.supplierSelectData = (this.$refs.bill as any).getTableSelectData(this.tabType); // 获取表格选中数据
-			if (this.supplierSelectData.length <= 0) return this.$message.warning('请选择派单数据');
-			if (this.supplierSelectData.length > 1) return this.$message.warning('只能派单一条数据');
-			(this.$refs.supplierModal as any).setShow(true);
+		onDispatch() {
+			let query = (this.$refs.bill as any).getTableSelectData(this.tabType); // 获取表格选中数据
+			console.log('派单 ==>', query);
+			if (query.length <= 0) return this.$message.warning('请选择派单数据');
+			if (query.length > 1) return this.$message.warning('只能派单一条数据');
+			let loading = this.$loading({ target: '.main-container' });
+			api.single({ id: query[0].id }, 'supplyTaskOrder').then((res : any) => {
+				if (res.code === 200) {
+					loading.close();
+					this.supplierSelectData = res.data;
+					(this.$refs.supplierModal as any).setShow(true);
+				}
+			}).catch(() => loading.close());
 		}
 		// 派单确认
 		confirmSupplier(e : any) {
 			if (e.length > 0) {
-				console.log(e);
-				console.log(this.supplierSelectData);
-				let query : any = (this as any).$lodash.cloneDeep(this.supplierSelectData)[0];
+				let query : any = (this as any).$lodash.cloneDeep(this.supplierSelectData);
 				query.organizationName = e[0].name;
 				query.organizationId = e[0].id;
+				console.log(query);
 				let loading = this.$loading({ target: '.main-container' });
 				api.updateList(query, 'supplyTaskOrder').then((res : any) => {
 					if (res.code === 200) {
@@ -1166,7 +1170,7 @@
 						(this.$refs.bill as any).showTab = 'all';
 						loading.close();
 					} else this.$message.error(res.msg);
-				})
+				}).catch(() => loading.close());
 			}
 		}
 		// 切换tab栏
@@ -1198,6 +1202,7 @@
 		}
 		// 获取分页数据
 		getPageList(query : any, type : any) {
+			let loading = this.$loading({ target: '.main-container' });
 			api.pageList(query, 'supplyTaskOrder').then((res : any) => {
 				if (res.code === 200) {
 					(this.$refs.bill as any).setTabTableValue(type, res.data.records);
@@ -1206,9 +1211,10 @@
 						pageSize: res.data.size, //每页条数
 						total: res.data.total //总条数
 					};
-					(this.$refs.bill as any).setTablePage(type, page)
+					(this.$refs.bill as any).setTablePage(type, page);
+					loading.close();
 				} else this.$message.error(res.msg)
-			})
+			}).catch(() => loading.close());
 		}
 		// 分页
 		pagination(e : any) {
@@ -1222,7 +1228,7 @@
 						(this.$refs.bill as any).setTabTableValue('recycleBin', res.data.records);
 						loading.close();
 					} else this.$message.error(res.msg)
-				});
+				}).catch(() => loading.close());
 			} else {
 				console.log(e.type);
 				if (e.type == 'draftsBox') query.submitState = 0; // 草稿箱数据
@@ -1232,7 +1238,7 @@
 						(this.$refs.bill as any).setTabTableValue(e.type, res.data.records);
 						loading.close();
 					} else this.$message.error(res.msg)
-				})
+				}).catch(() => loading.close());
 			}
 		}
 		// 回收站数据
@@ -1367,7 +1373,7 @@
 						this.$message.success('删除成功!');
 						loading.close();
 					} else this.$message.error(res.msg)
-				})
+				}).catch(() => loading.close());
 			}).catch(() => this.$message.info('已取消删除'));
 		}
 		// 操作删除
@@ -1385,7 +1391,7 @@
 						this.$message.success('删除成功!');
 						loading.close();
 					} else this.$message.error(res.msg)
-				})
+				}).catch(() => loading.close());
 			}).catch(() => this.$message.info('已取消删除'));
 		}
 	}

+ 1 - 1
src/views/audit/productClassification/index.vue

@@ -343,7 +343,7 @@
 							loading.close();
 							data.parentName = res.data.name;
 							this.dialogFormVisible = true;
-							this.$nextTick(() => (this as any).$refs.addFormId.setValue(data));
+							setTimeout(() => {(this as any).$refs.addFormId.setValue(data)},0);
 						}
 					})
 				}

+ 1 - 1
src/views/audit/productManagement/index.vue

@@ -474,7 +474,7 @@
 		}
 		formConfig = {
 			attr: {
-				size: 'small',
+				size: 'medium',
 				rules: {
 					name: [{
 						required: true, message: '请输入名称', trigger: 'blur'

+ 9 - 10
src/views/audit/saleOrder/index.vue

@@ -3,19 +3,18 @@
 		<by-bill :propConfig="config" @search="search" ref="bill" @resert="resert" @detail="openEdit" @onRefresh="resert"
 			@pagination="pagination" @clickTab="clickTab" @onOrder="onOrder">
 		</by-bill>
-		<vxe-modal v-model="vxeValue" width="70%" height="70%" min-width="800" min-height="600" show-zoom resize transfer
-			show-footer>
+		<vxe-modal v-model="vxeValue" width="90%" height="90%" show-zoom resize transfer show-footer>
 			<template #title>
 				<!-- <span>拆单</span> -->
 			</template>
 			<template #default>
-				<div class="fl" style="width: 40%;">
+				<div class="fl" style="width: 45%;margin-right: 10%;">
 					<div style="margin-bottom: 20px;">主单销售数据</div>
 					<by-table ref="leftTable" :propConfig="leftTableConfig"></by-table>
 				</div>
-				<div class="fl" style="font-size: 80px;margin: 200px 6% 0 6%;transform: rotate(90deg);"><i
-						class="el-icon-sort"></i></div>
-				<div class="fl" style="width: 40%;">
+				<!-- <div class="fl" style="font-size: 80px;margin: 10% 6% 0 6%;transform: rotate(90deg);"><i
+						class="el-icon-sort"></i></div> -->
+				<div class="fl" style="width: 45%;">
 					<div style="margin-bottom: 20px;">拆单销售数据</div>
 					<by-table ref="rightTable" :propConfig="rightTableConfig" @onChangeRow="rightChange"></by-table>
 				</div>
@@ -81,12 +80,12 @@
 			columns:
 				[
 					{
-						width: 258,
+						width: 128,
 						title: '物料名称',
 						field: 'materialName',
 					},
 					{
-						width: 258,
+						width: 128,
 						title: '数量',
 						field: 'number',
 						component: 'by-input',
@@ -658,7 +657,6 @@
 		}
 		// 右拆单数据变化
 		rightChange(e : any) {
-			console.log(e.number);
 			if (0 <= e.number && e.number <= this.regularData[e.dataIndex].splitNumber) {
 				let leftTableData = (this.$refs.leftTable as any).getValue();
 				leftTableData[e.dataIndex].splitNumber = leftTableData[e.dataIndex].number - e.number;
@@ -851,6 +849,7 @@
 					ids.push(v.id);
 				})
 			} else return this.$message({ type: 'warning', message: '请选择终止订单数据' })
+			// console.log(ids);
 			this.$confirm('确定终止订单吗!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
@@ -874,7 +873,7 @@
 				type: 'warning',
 				center: true
 			}).then(() => {
-				api.stoporder([e.id], 'supplyPurchaseOrder').then((res : any) => {
+				api.stoporder({ ids: e.id }, 'supplyPurchaseOrder').then((res : any) => {
 					if (res.code === 200) {
 						this.$message.success('终止订单成功!');
 						this.getDataList();

+ 136 - 56
src/views/audit/supplier/index.vue

@@ -1,29 +1,34 @@
 <template>
 	<div class="my-container">
-		<div class="bill-left">
-			<div class="bill-tab">
-				<div class="tab-title">导航</div>
-				<side-tree :propConfig="treeConfig" @onChange="onChangeTree" ref="sideTree" />
+		<transition-group name="fade" style="position: relative;width: 100%;display: flex;">
+			<div class="bill-left" v-show="isShow==='home'" key="item">
+				<div class="bill-tab">
+					<div class="bill-title">导航</div>
+					<side-tree :propConfig="treeConfig" @onChange="onChangeTree" ref="sideTree" />
+				</div>
 			</div>
-		</div>
-		<div class="bill-main">
-			<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
-				@resert="onRefresh" @clickHandle="clickHandle" @detail="openEdit" @onRefresh="onRefresh">
-			</module-view>
-		</div>
-		<!-- 新增/编辑弹窗 -->
-		<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>
-				</template>
-			</by-form>
-			<div slot="footer" class="dialog-footer">
-				<el-button @click="dialogFormVisible = false">取 消</el-button>
-				<el-button type="primary" @click="confirm">确 定</el-button>
+			<div class="bill-main" v-show="isShow==='home'" key="item2">
+				<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
+					@resert="onRefresh" @clickHandle="clickHandle" @detail="openEdit" @onRefresh="onRefresh">
+				</module-view>
 			</div>
-		</el-dialog>
+			<!-- 新增/编辑弹窗 -->
+			<div class="detil" v-show="isShow==='add'" key="item3">
+				<by-tool :propConfig="toolConfig" @clickHandle="insideTools" ref="byTool" />
+				<div class="box-shadow">
+					<by-form :propConfig="addConfig" ref="addFormId">
+						<template v-slot:k3ServerUrl="{value}" class="clearfix">
+							<i class="el-icon-question" title="私有云必须配置金蝶云星空产品地址,K3Cloud/结尾,若为公有云则必须置空"></i>
+							<vxe-input v-model="value.k3ServerUrl" style="width:calc(100% - 25px);margin-left: 10px;"></vxe-input>
+						</template>
+						<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>
+						</template>
+					</by-form>
+				</div>
+			</div>
+		</transition-group>
 	</div>
 </template>
 <script lang="ts">
@@ -32,12 +37,19 @@
 	import Assembly from "@/components/Assembly/material.vue";
 	@Component
 	export default class Supplier extends Vue {
+		isShow = 'home'
 		timeNum = 0;
 		timer : any = null
 		popTitle : any = ''
 		radio : any = 0
 		dialogFormVisible : boolean = false
 		categoryIds : any = '';
+		toolConfig = {
+			tools: {
+				return: true,
+				save: true,
+			}
+		}
 		treeConfig = {
 			attr: {
 				retConfig: {
@@ -174,7 +186,7 @@
 		}
 		addConfig = {
 			attr: {
-				size: 'small',
+				size: 'medium',
 				rules: {
 					categoryName: [{
 						required: true, message: '请输入父级', trigger: 'change'
@@ -193,9 +205,8 @@
 			columns: [
 				[
 					{
-						span: 23,
+						span: 6,
 						label: '父级',
-						labelWidth: '70px',
 						prop: 'categoryName',
 						component: 'select-tree',
 						compConfig: {
@@ -214,42 +225,33 @@
 						}
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '名称',
 						prop: 'name',
 						component: 'by-input',
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '负责人',
 						prop: 'contacts',
 						component: 'by-input',
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '手机号码',
 						prop: 'telephone',
 						component: 'by-input',
 					},
 					{
-						span: 23,
-						labelWidth: '70px',
+						span: 6,
 						label: '联系电话',
 						prop: 'phonenum',
 						component: 'by-input',
 					},
+				],
+				[
 					{
-						span: 23,
-						labelWidth: '70px',
-						label: '状态',
-						slot: true,
-						prop: 'status',
-					},
-					{
-						span: 23,
+						span: 6,
 						labelWidth: '110px',
 						label: '财务系统类型',
 						prop: 'financeType',
@@ -262,15 +264,60 @@
 									{
 										value: '金蝶K3',
 										label: '金蝶K3'
-									}, {
-										value: '用友U8',
-										label: '用友U8'
 									},
+									// {
+									// 	value: '用友U8',
+									// 	label: '用友U8'
+									// },
 								]
 							}
 						}
 					},
 				],
+				[
+					{
+						span: 6,
+						label: '登录授权ID',
+						slot: true,
+						prop: 'k3AppId',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: '用户名称',
+						slot: true,
+						prop: 'k3UserName',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: '数据中心ID',
+						slot: true,
+						prop: 'k3AcctId',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: '应用秘钥',
+						slot: true,
+						prop: 'k3AppSec',
+						component: 'by-input',
+					},
+					{
+						span: 6,
+						label: 'URL地址',
+						slot: true,
+						prop: 'k3ServerUrl',
+					},
+				],
+				[
+					{
+						span: 6,
+						label: '状态',
+						slot: true,
+						prop: 'status',
+					},
+				]
 			]
 		}
 		mounted() {
@@ -295,32 +342,44 @@
 				}
 			})
 		}
-		// 确认新增/编辑
+		// 内页工具栏方法
+		insideTools(e : any) {
+			console.log(e);
+			if (e === 'onReturn') this.isShow = 'home';
+			if (e === 'onSave') this.confirm();
+		}
+		// 保存新增/编辑
 		confirm() {
 			(this as any).$refs.addFormId.validate().then(() => {
 				let query = (this as any).$refs.addFormId.getValue();
-				console.log(query);
 				query.status = this.radio;
 				// 手机验证
 				let reg = /^1[3456789]\d{9}$/;
 				let reg2 = /^0\d{2,3}-\d{7,8}$/;
 				if (query.telephone && !reg.test(query.telephone)) return this.$message.warning('请输入正确手机号码');
 				if (query.phonenum && !reg2.test(query.phonenum)) return this.$message.warning('请输入正确联系电话');
+				if (!query.telephone) query.telephone = null;
+				if (!query.phonenum) query.phonenum = null;
 				this.dialogFormVisible = false;
-
+				console.log(query);
+				let loading = this.$loading({ target: '.main-container' });
 				if (this.popTitle === '新增') {
 					api.saveList(query, 'maindataMaterialSupplier').then((res : any) => {
 						if (res.code === 200) {
-							this.$message.success(this.popTitle + '成功!');
+							loading.close();
+							this.$message.success('保存成功');
 							(this as any).$refs.sideTree.request();
+							this.isShow = 'home'; // 展示类型
 							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.success(this.popTitle + '成功!');
+							loading.close();
+							this.$message.success('编辑成功');
 							(this as any).$refs.sideTree.request();
+							this.isShow = 'home'; // 展示类型
 							this.getDataList();
 						} else this.$message.error(res.msg);
 					})
@@ -364,16 +423,16 @@
 		}
 		// 打开新增
 		onAdd() {
+			this.isShow = 'add'; // 展示类型
 			this.popTitle = '新增'
 			this.dialogFormVisible = true;
 			this.radio = 0
-			this.$nextTick(() => {
-				(this as any).$refs.addFormId.setValue();
-			});
+			this.$nextTick(() => (this as any).$refs.addFormId.setValue());
 		}
 		// 打开编辑
 		openEdit(e : any) {
 			console.log('打开编辑 ==> ', e);
+			this.isShow = 'add'; // 展示类型
 			this.popTitle = '编辑'
 			let loading = this.$loading({ target: '.main-container' });
 			api.single({ id: e.id }, 'maindataMaterialSupplier').then((res : any) => {
@@ -382,9 +441,7 @@
 					this.radio = data.status;
 					loading.close();
 					this.dialogFormVisible = true;
-					this.$nextTick(() => {
-						(this as any).$refs.addFormId.setValue(data);
-					});
+					this.$nextTick(() => (this as any).$refs.addFormId.setValue(data));
 				}
 			})
 		}
@@ -400,7 +457,7 @@
 					if (res.code === 200) {
 						(this as any).$refs.sideTree.request();
 						this.getDataList();
-						this.$message.success('删除成功!');
+						this.$message.success('删除成功');
 					} else this.$message.error(res.msg);
 				})
 			}).catch(() => this.$message.info('已取消删除'));
@@ -515,5 +572,28 @@
 				z-index: 1;
 			}
 		}
+
+		.detil {
+			width: 100%;
+
+			.box-shadow {
+				box-shadow: 0 2px 12px 0 rgb(0 0 0 / 10%);
+				padding: 20px;
+				border-radius: 4px;
+				border: 1px solid #e6ebf5;
+				background-color: #fff;
+				overflow: hidden;
+				color: #303133;
+				-webkit-transition: .3s;
+				transition: .3s;
+				margin-top: 20px;
+			}
+		}
+
+		@media screen and (min-width: 1700px) {
+			.bill-main {
+				min-width: 1450px;
+			}
+		}
 	}
 </style>

+ 1 - 1
src/views/audit/virtually/index.vue

@@ -344,7 +344,7 @@
 							loading.close();
 							data.parentName = res.data.name;
 							this.dialogFormVisible = true;
-							this.$nextTick(() => (this as any).$refs.addFormId.setValue(data));
+							setTimeout(() => {(this as any).$refs.addFormId.setValue(data)},0);
 						}
 					})
 				}