Преглед изворни кода

Merge branch 'master' of http://47.107.53.207:3000/ymy/oms

ymy пре 2 година
родитељ
комит
054bfe5f2d

+ 0 - 0
src/api/material.ts → src/api/other.ts


+ 0 - 17
src/benyun/components/Assembly/order.vue

@@ -1,17 +0,0 @@
-<template>
-	<div>
-		<el-tag size='mini' :type="propValue.status===0?'info':'primary'"
-			disable-transitions>{{propValue.status===0?'未接单':'已接单'}}</el-tag>
-	</div>
-</template>
-<script lang="ts">
-	import { Component, Prop, Vue, Watch, Mixins } from "vue-property-decorator";
-	@Component
-	export default class Order extends Vue {
-		@Prop()
-		propValue : any
-	}
-</script>
-
-<style>
-</style>

+ 1 - 0
src/benyun/components/byBill/byBill.vue

@@ -184,6 +184,7 @@ export default class ByBill extends VueViews {
   //左侧tab切换
   tabChange(t:string){
     this.showTab = t;
+		this.$emit('clickTab',t)
   }
 
   //工具栏

+ 4 - 1
src/benyun/components/byTool/byTool.vue

@@ -47,9 +47,12 @@ export default class GmTools extends Vue {
   }
 
   tools:Array<any>=[
+		{ name: '返回', icon: 'el-icon-arrow-left', clickName: 'onReturn', _class: 'return' },
     { name: '新增', icon: 'el-icon-plus', clickName: 'onAdd', _class: 'add' },
+		{ name: '保存', icon: 'el-icon-plus', clickName: 'onSave', _class: 'save' },
     { name: '提交', icon: 'el-icon-finished', clickName: 'onSmt', _class: 'smt' },
-    { name: '接单', icon: 'el-icon-finished', clickName: 'onOrder', _class: 'order' },
+    { name: '接单', icon: 'el-icon-sold-out', clickName: 'onOrder', _class: 'order' },
+    { name: '派单', icon: 'el-icon-sell', clickName: 'onDispatch', _class: 'dispatch' },
     { name: '修改', icon: 'el-icon-edit', clickName: 'onUpdate', _class: 'edit' },
     { name: '取消提交', icon: 'el-icon-refresh-left', clickName: 'onReSmt', _class: 'reSmt' },
     { name: '删除', icon: 'el-icon-delete', clickName: 'onDelete', _class: 'delete' },

+ 2 - 2
src/benyun/components/Assembly/material.vue → src/components/Assembly/material.vue

@@ -1,7 +1,7 @@
 <template>
 	<div>
-		<el-tag size='mini' :type="propValue.status===0?'primary':'danger'"
-			disable-transitions>{{propValue.status===0?'正常':'禁用'}}</el-tag>
+		<el-tag size='mini' :type="propValue===0?'primary':'danger'"
+			disable-transitions>{{propValue===0?'正常':'禁用'}}</el-tag>
 	</div>
 </template>
 <script lang="ts">

+ 1 - 1
src/benyun/components/Assembly/nature.vue → src/components/Assembly/nature.vue

@@ -1,7 +1,7 @@
 <template>
 	<div>
 		<el-tag size='mini' type="primary"
-			disable-transitions>{{propValue.attributeType===0?'销售属性':'基本属性'}}</el-tag>
+			disable-transitions>{{propValue===0?'销售属性':'基本属性'}}</el-tag>
 	</div>
 </template>
 <script lang="ts">

+ 22 - 0
src/components/Assembly/order.vue

@@ -0,0 +1,22 @@
+<template>
+	<div>
+		<el-tag size='mini' :type="propValue==0?'info':'primary'"
+			disable-transitions>{{propValue==0?'未接单':'已接单'}}</el-tag>
+	</div>
+</template>
+<script lang="ts">
+	// import { create } from "lodash";
+import { Component, Prop, Vue, Watch, Mixins } from "vue-property-decorator";
+	@Component
+	export default class Order extends Vue {
+		@Prop()
+		propValue : any
+		// created(){
+		// 	console.log(this.propValue===);
+		// }
+	}
+
+</script>
+
+<style>
+</style>

+ 27 - 4
src/views/audit/agencyGoods/index.vue

@@ -35,7 +35,7 @@
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 	import api from "@/api/currency";
-	import Assembly from "@/benyun/components/Assembly/material.vue";
+	import Assembly from "@/components/Assembly/material.vue";
 	@Component
 	export default class AgencyGoods extends Vue {
 		// 左边
@@ -109,7 +109,6 @@
 			tool: {
 				tools: {
 					add: true,
-					export: true,
 					delete: true,
 					search: true,
 					refresh: true
@@ -141,6 +140,7 @@
 					title: '备注',
 					field: 'remark',
 				}, {
+					width: 120,
 					title: '操作',
 					action: true,
 					plugins: [{
@@ -172,6 +172,25 @@
 			},
 			columns: [
 				[
+					{
+						span: 23,
+						label: '父级',
+						labelWidth: '70px',
+						prop: 'parentId',
+						component: 'select-tree',
+						compConfig: {
+							attr: {
+								label: 'name',
+								clearable: true,
+								retConfig: {
+									parentId: 'id',
+								}
+							},
+							request: {
+								url: '/maindata/maindataMaterialOrganizationCategory/treeList'
+							}
+						}
+					},
 					{
 						labelWidth: '70px',
 						span: 23,
@@ -232,6 +251,7 @@
 								type: 'success',
 								message: this.popTitle + '成功!'
 							});
+							this.getTreeList();
 							this.getDataList();
 						} else this.failHandle(res)
 					})
@@ -242,6 +262,7 @@
 								type: 'success',
 								message: this.popTitle + '成功!'
 							});
+							this.getTreeList();
 							this.getDataList();
 						} else this.failHandle(res)
 					})
@@ -307,7 +328,7 @@
 				})
 			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
 			ids = ids.slice(0, ids.length - 1);
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -315,6 +336,7 @@
 			}).then(() => {
 				api.deleteList({ ids: ids }, 'maindataMaterialOrganizationCategory').then((res : any) => {
 					if (res.code === 200) {
+						this.getTreeList();
 						this.getDataList();
 						this.$message({
 							type: 'success',
@@ -331,7 +353,7 @@
 		}
 		// 操作删除
 		doDelete2(item : any) {
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -339,6 +361,7 @@
 			}).then(() => {
 				api.deleteList({ ids: item.id }, 'maindataMaterialOrganizationCategory').then((res : any) => {
 					if (res.code === 200) {
+						this.getTreeList();
 						this.getDataList();
 						this.$message({
 							type: 'success',

+ 4 - 6
src/views/audit/attribute/index.vue

@@ -23,9 +23,8 @@
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 	import api from "@/api/currency";
-	// import materialClass from "@/api/materialClass";
-	import Assembly from "@/benyun/components/Assembly/material.vue";
-	import AssemblyNature from "@/benyun/components/Assembly/nature.vue";
+	import Assembly from "@/components/Assembly/material.vue";
+	import AssemblyNature from "@/components/Assembly/nature.vue";
 	@Component
 	export default class Attribute extends Vue {
 		// 右边
@@ -101,7 +100,6 @@
 			tool: {
 				tools: {
 					add: true,
-					export: true,
 					delete: true,
 					search: true,
 					refresh: true
@@ -317,7 +315,7 @@
 				})
 			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
 			ids = ids.slice(0, ids.length - 1);
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -341,7 +339,7 @@
 		}
 		// 操作删除
 		doDelete2(item : any) {
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',

+ 2 - 2
src/views/audit/binTable/index.vue

@@ -323,7 +323,7 @@
 				})
 			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
 			ids = ids.slice(0, ids.length - 1);
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -347,7 +347,7 @@
 		}
 		// 操作删除
 		doDelete2(item : any) {
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',

+ 4 - 4
src/views/audit/brand/index.vue

@@ -23,7 +23,7 @@
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 	import api from "@/api/currency";
-	import Assembly from "@/benyun/components/Assembly/material.vue";
+	import Assembly from "@/components/Assembly/material.vue";
 	@Component
 	export default class Brand extends Vue {
 		baseURL : any = process.env.VUE_APP_BASE_API
@@ -89,7 +89,6 @@
 			tool: {
 				tools: {
 					add: true,
-					export: true,
 					delete: true,
 					search: true,
 					refresh: true
@@ -122,6 +121,7 @@
 					title: '备注',
 					field: 'remark'
 				}, {
+					width: 120,
 					title: '操作',
 					action: true,
 					plugins: [{
@@ -282,7 +282,7 @@
 				})
 			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
 			ids = ids.slice(0, ids.length - 1);
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -306,7 +306,7 @@
 		}
 		// 操作删除
 		doDelete2(item : any) {
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',

+ 337 - 126
src/views/audit/depots/index.vue

@@ -1,42 +1,48 @@
 <template>
 	<div class="my-container">
-		<div class="bill-main">
-			<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
-				@resert="getDataList" @clickHandle="clickHandle" @detail="openEdit">
-			</module-view>
-		</div>
-		<!-- 新增/编辑弹窗 -->
-		<el-dialog :title="popTitle+'仓库'" :visible.sync="dialogFormVisible" width="30%">
-			<by-form :propConfig="addConfig" ref="addFormId">
-				<template v-slot:logo>
-					<el-upload :limit='1' :action="baseURL+'/file/upload'" list-type="picture-card"
-						:on-preview="handlePictureCardPreview" :on-remove="handleRemove">
-						<i class="el-icon-plus"></i>
-					</el-upload>
-				</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 slot="footer" class="dialog-footer">
-				<el-button @click="dialogFormVisible = false">取 消</el-button>
-				<el-button type="primary" @click="confirm">确 定</el-button>
+		<transition-group name="fade" style="position: relative;width: 100%;display: flex;">
+			<div class="bill-main" v-show="isShow==='ckb'" key="item">
+				<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
+					@resert="getDataList" @clickHandle="clickHandle" @detail="changeTab">
+				</module-view>
+				<!-- 新增/编辑弹窗 -->
+				<el-dialog :title="popTitle+'仓库'" :visible.sync="dialogFormVisible" width="30%">
+					<by-form :propConfig="addConfig" ref="addFormId"></by-form>
+					<div slot="footer" class="dialog-footer">
+						<el-button @click="dialogFormVisible = false">取 消</el-button>
+						<el-button type="primary" @click="confirm">确 定</el-button>
+					</div>
+				</el-dialog>
 			</div>
-		</el-dialog>
+			<div class="bill-main" v-show="isShow==='cwb'" key="item2">
+				<module-view :propConfig="config2" ref="moduleView2" @pagination="getDataList2" @search="getDataList2"
+					@resert="getDataList2" @clickHandle="clickHandle2" @detail="openEdit2">
+				</module-view>
+				<!-- 新增/编辑弹窗 -->
+				<el-dialog :title="popTitle+'仓位'" :visible.sync="dialogFormVisible2" width="30%">
+					<by-form :propConfig="addConfig2" ref="addFormId2"></by-form>
+					<div slot="footer" class="dialog-footer">
+						<el-button @click="dialogFormVisible2 = false">取 消</el-button>
+						<el-button type="primary" @click="confirm2">确 定</el-button>
+					</div>
+				</el-dialog>
+			</div>
+		</transition-group>
 	</div>
 </template>
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 	import api from "@/api/currency";
 	@Component
-	export default class Brand extends Vue {
-		baseURL : any = process.env.VUE_APP_BASE_API
+	export default class Depots extends Vue {
+		isShow : any = 'ckb'
 		timeNum = 0;
 		timer : any = null
+		timeNum2 = 0;
+		timer2 : any = null
 		popTitle : any = ''
-		radio : any = 0
 		dialogFormVisible : boolean = false
+		dialogFormVisible2 : boolean = false
 		config : any = {
 			search: {
 				attr: {
@@ -74,7 +80,7 @@
 			tool: {
 				tools: {
 					add: true,
-					export: true,
+					// export: true,
 					delete: true,
 					search: true,
 					refresh: true
@@ -86,10 +92,9 @@
 					seq: true,
 					align: 'center',
 					checkbox: true,
-					height: 600
+					height: 630
 				},
 				columns: [{
-					width: 300,
 					title: '名称',
 					field: 'name',
 					isDetail: true,
@@ -97,9 +102,21 @@
 					title: '地址',
 					field: 'address',
 				}, {
-					title: '坐标',
-					field: 'coordinate'
+					width: 100,
+					title: '仓位',
+					action: true,
+					plugins: [{
+						icon: 'el-icon-edit',
+						name: '查看',
+						audit: '',
+						event: {
+							click: (item : any) => {
+								(this as any).changeTab()
+							}
+						}
+					}]
 				}, {
+					width: 120,
 					title: '操作',
 					action: true,
 					plugins: [{
@@ -114,7 +131,155 @@
 					}, {
 						name: '删除',
 						event: {
-							click: (item : any) => (this as any).doDelete2(item)
+							click: (item : any) => (this as any).doDelete2(item, 'maindataStorehouse')
+						}
+					}]
+				}]
+			},
+		}
+		config2 : any = {
+			search: {
+				attr: {
+					size: 'mini'
+				},
+				columns: [
+					[
+						{
+							span: 6,
+							label: '名称',
+							prop: 'name',
+							component: 'by-input',
+							compConfig: {
+								attr: {
+									placeholder: '请输入名称',
+									clearable: true
+								},
+							},
+						},
+						{
+							span: 6,
+							label: '所属机构名称',
+							prop: 'organizationName',
+							component: 'by-input',
+							compConfig: {
+								attr: {
+									placeholder: '请输入所属机构名称',
+									clearable: true
+								}
+							}
+						},
+						{
+							span: 6,
+							label: '库存',
+							prop: 'stock',
+							component: 'by-input',
+							compConfig: {
+								attr: {
+									placeholder: '请输入库存',
+									clearable: true
+								}
+							}
+						},
+						{
+							span: 6,
+							label: '库存体积',
+							prop: 'stockVolume',
+							component: 'by-input',
+							compConfig: {
+								attr: {
+									placeholder: '请输入库存体积',
+									clearable: true
+								},
+							},
+						},
+					],
+					[
+						{
+							span: 6,
+							label: '库存上限数量',
+							prop: 'maxStockNumber',
+							component: 'by-input',
+							compConfig: {
+								attr: {
+									placeholder: '请输入库存上限数量',
+									clearable: true
+								}
+							}
+						},
+						{
+							span: 6,
+							label: '库存体积上限',
+							prop: 'maxStockVolume',
+							component: 'by-input',
+							compConfig: {
+								attr: {
+									placeholder: '请输入库存体积上限',
+									clearable: true
+								}
+							}
+						},
+					]
+				]
+			},
+			tool: {
+				tools: {
+					return: true,
+					add: true,
+					// export: true,
+					delete: true,
+					search: true,
+					refresh: true
+				}
+			},
+			table: {
+				attr: {
+					size: 'mini',
+					seq: true,
+					align: 'center',
+					checkbox: true,
+					height: 590
+				},
+				columns: [{
+					width: 300,
+					title: '名称',
+					field: 'name',
+					isDetail: true,
+				}, {
+					title: '所属机构名称',
+					field: 'organizationName',
+				},
+				{
+					title: '库存',
+					field: 'stock'
+				},
+				{
+					title: '库存体积',
+					field: 'stockVolume'
+				},
+				{
+					title: '库存数量上限',
+					field: 'maxStockNumber'
+				},
+				{
+					title: '库存体积上限',
+					field: 'maxStockVolume'
+				}, {
+					width: 120,
+					title: '操作',
+					action: true,
+					plugins: [{
+						icon: 'el-icon-edit',
+						name: '编辑',
+						audit: '',
+						event: {
+							click: (item : any) => {
+								(this as any).openEdit2(item)
+							}
+						}
+					}, {
+						name: '删除',
+						event: {
+							click: (item : any) => (this as any).doDelete2(item, 'maindataStoringLocation')
 						}
 					}]
 				}]
@@ -148,11 +313,54 @@
 						prop: 'address',
 						component: 'by-input',
 					},
+				]
+			]
+		}
+		addConfig2 = {
+			attr: {
+				size: 'small',
+				rules: {
+					name: [{
+						required: true, message: '请输入名称', trigger: 'blur'
+					}]
+				}
+			},
+			columns: [
+				[
+					{
+						span: 23,
+						label: '名称',
+						prop: 'name',
+						component: 'by-input',
+					},
 					{
 						span: 23,
-						labelWidth: '70px',
-						label: '坐标',
-						prop: 'coordinate',
+						label: '所属机构名称',
+						prop: 'organizationName',
+						component: 'by-input',
+					},
+					{
+						span: 23,
+						label: '库存',
+						prop: 'stock',
+						component: 'by-input',
+					},
+					{
+						span: 23,
+						label: '库存体积',
+						prop: 'stockVolume',
+						component: 'by-input',
+					},
+					{
+						span: 23,
+						label: '库存数量上限',
+						prop: 'maxStockNumber',
+						component: 'by-input',
+					},
+					{
+						span: 23,
+						label: '库存体积上限',
+						prop: 'maxStockVolume',
 						component: 'by-input',
 					},
 				]
@@ -163,11 +371,16 @@
 				this.getDataList()
 			}, 500)
 		}
+		changeTab() {
+			this.isShow = 'cwb';
+			this.timer2 = setInterval(() => {
+				this.getDataList2()
+			}, 500)
+		}
 		// 确认新增/编辑
 		confirm() {
 			(this as any).$refs.addFormId.validate().then(() => {
 				let query = (this as any).$refs.addFormId.getValue();
-				query.status = this.radio;
 				this.dialogFormVisible = false;
 				if (this.popTitle === '新增') {
 					api.saveList(query, 'maindataStorehouse').then((res : any) => {
@@ -192,7 +405,34 @@
 				}
 			})
 		}
-		// 获取列表数据
+		confirm2() {
+			(this as any).$refs.addFormId2.validate().then(() => {
+				let query = (this as any).$refs.addFormId2.getValue();
+				this.dialogFormVisible2 = false;
+				if (this.popTitle === '新增') {
+					api.saveList(query, 'maindataStoringLocation').then((res : any) => {
+						if (res.code === 200) {
+							this.$message({
+								type: 'success',
+								message: this.popTitle + '成功!'
+							});
+							this.getDataList2();
+						} else this.failHandle(res)
+					})
+				} else if (this.popTitle === '编辑') {
+					api.updateList(query, 'maindataStoringLocation').then((res : any) => {
+						if (res.code === 200) {
+							this.$message({
+								type: 'success',
+								message: this.popTitle + '成功!'
+							});
+							this.getDataList2();
+						} else this.failHandle(res)
+					})
+				}
+			})
+		}
+		// 获取仓库列表数据
 		getDataList() {
 			if (!this.$refs.moduleView) {
 				if (this.timeNum > 5) {
@@ -215,12 +455,44 @@
 				} else this.failHandle(res)
 			})
 		}
+		// 获取仓位列表数据
+		getDataList2() {
+			if (!this.$refs.moduleView2) {
+				if (this.timeNum2 > 5) {
+					clearInterval(this.timer2)
+				}
+				this.timeNum2++;
+				return
+			}
+			clearInterval(this.timer2)
+			let query = (this.$refs.moduleView2 as any).getQuery();
+			api.pageList(query, 'maindataStoringLocation').then((res : any) => {
+				if (res.code === 200) {
+					(this.$refs.moduleView2 as any).setTableValue(res.data.records);
+					let page = {
+						pageNo: res.data.current, //当前页
+						pageSize: res.data.size, //每页条数
+						total: res.data.total //总条数
+					};
+					(this.$refs.moduleView2 as any).setPage(page)
+				} else this.failHandle(res)
+			})
+		}
 		// 工具栏方法
 		clickHandle(e : any) {
+			console.log(e);
 			if (e === 'onRefresh') (this.$refs.moduleView as any).resert();
 			if (e === 'onAdd') this.onAdd();
-			if (e === 'onDelete') this.onDelete();
+			if (e === 'onDelete') this.onDelete('moduleView', 'maindataStorehouse');
+			if (e === 'onExport') this.onExport();
+		}
+		clickHandle2(e : any) {
+			console.log(e);
+			if (e === 'onRefresh') (this.$refs.moduleView2 as any).resert();
+			if (e === 'onAdd') this.onAdd2();
+			if (e === 'onDelete') this.onDelete('moduleView2', 'maindataStoringLocation');
 			if (e === 'onExport') this.onExport();
+			if (e === 'onReturn') this.isShow = 'ckb';
 		}
 		// 打开新增
 		onAdd() {
@@ -230,6 +502,13 @@
 				if ((this as any).$refs.addFormId) (this as any).$refs.addFormId.setValue({});
 			}, 0)
 		}
+		onAdd2() {
+			this.popTitle = '新增'
+			this.dialogFormVisible2 = true;
+			setTimeout(() => {
+				if ((this as any).$refs.addFormId2) (this as any).$refs.addFormId2.setValue({});
+			}, 0)
+		}
 		// 打开编辑
 		openEdit(e : any) {
 			this.popTitle = '编辑'
@@ -238,9 +517,17 @@
 				if ((this as any).$refs.addFormId) (this as any).$refs.addFormId.setValue(e);
 			}, 0)
 		}
+		// 打开编辑
+		openEdit2(e : any) {
+			this.popTitle = '编辑'
+			this.dialogFormVisible2 = true;
+			setTimeout(() => {
+				if ((this as any).$refs.addFormId2) (this as any).$refs.addFormId2.setValue(e);
+			}, 0)
+		}
 		// 工具栏删除
-		onDelete() {
-			let selectData = (this.$refs.moduleView as any).getSelectData()
+		onDelete(moduleView : any, url : any) {
+			let selectData = (this.$refs[moduleView] as any).getSelectData()
 			let ids = '';
 			if (selectData.length > 0) {
 				selectData.map((v : any) => {
@@ -248,13 +535,13 @@
 				})
 			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
 			ids = ids.slice(0, ids.length - 1);
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
 				center: true
 			}).then(() => {
-				api.deleteList({ ids: ids }, 'maindataStorehouse').then((res : any) => {
+				api.deleteList({ ids: ids }, url).then((res : any) => {
 					if (res.code === 200) {
 						this.getDataList();
 						this.$message({
@@ -271,14 +558,14 @@
 			});
 		}
 		// 操作删除
-		doDelete2(item : any) {
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+		doDelete2(item : any, url : any) {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
 				center: true
 			}).then(() => {
-				api.deleteList({ ids: item.id }, 'maindataStorehouse').then((res : any) => {
+				api.deleteList({ ids: item.id }, url).then((res : any) => {
 					if (res.code === 200) {
 						this.getDataList();
 						this.$message({
@@ -315,7 +602,7 @@
 		width: 100%;
 		box-sizing: border-box;
 		display: flex;
-		padding: 16px;
+		padding: 0 16px;
 
 		.search-btn {
 			width: 100%;
@@ -324,91 +611,15 @@
 			margin-bottom: 20px;
 		}
 
-		.bill-left {
-			position: relative;
-			border-right: solid #EEE 1px;
-			padding-right: 16px;
-			flex-shrink: 0;
-
-			// box-sizing: border-box;
-			.bill-tab {
-				width: 150px;
-				height: 100%;
-				transition: all .5s;
-				overflow: hidden;
-			}
-
-			.title {
-				font-size: 16px;
-				padding-bottom: 16px;
-				width: 200px;
-			}
-
-			.bill-nav {
-				font-size: 14px;
-				height: 30px;
-				line-height: 30px;
-				width: 200px;
-				box-sizing: border-box;
-				padding: 0 8px;
-				cursor: pointer;
-				margin-bottom: 2px;
-				border-radius: 5px;
-			}
-
-			.onBill {
-				background-color: #bde3f7;
-			}
-
-			.bill-nav:hover {
-				background-color: #bde3f7;
-			}
-
-			.close {
-				height: 22px;
-				width: 22px;
-				border-radius: 50%;
-				border: solid #EEE 1px;
-				position: absolute;
-				top: 30px;
-				right: -11px;
-				background-color: #FFF;
-				display: flex;
-				justify-content: center;
-				align-items: center;
-				cursor: pointer;
-			}
-		}
-
 		.bill-main {
 			width: calc(100% - 16px);
 			box-sizing: border-box;
 			margin-left: 16px;
-			position: relative;
-
-			.bill-box {
-				width: 100%;
-				position: absolute;
-				left: 0;
-				top: 0;
-				opacity: 0;
-				z-index: -1;
-				transition: all .5s;
-
-				.bill-tool,
-				.table-tool {
-					width: 100%;
-					padding-bottom: 16px;
-				}
-
-				.form {
-					margin-bottom: 8px;
-				}
-			}
+		}
 
-			.on-show {
-				opacity: 1;
-				z-index: 1;
+		@media screen and (min-width: 1500px) {
+			.bill-main {
+				min-width: 1610px;
 			}
 		}
 	}

+ 2 - 2
src/views/audit/materialAdd/index.vue

@@ -32,7 +32,7 @@
 
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
-	import api from '@/api/material'
+	import api from '@/api/currency'
 	@Component
 	export default class DemoForm extends Vue {
 		baseURL : any = process.env.VUE_APP_BASE_API
@@ -354,7 +354,7 @@
 				data.status = this.radioStatus;
 				data.ismakeup = this.ismakeup;
 				data.issued = this.issued;
-				api.save(data).then((res : any) => {
+				api.saveList(data,'maindataMaterial').then((res : any) => {
 					if (res.code === 200) {
 						(this as any).$tab.closeOpenPage('/materialFile/productManagement')
 						this.$message({ type: 'success', message: res.msg })

+ 2 - 2
src/views/audit/materialEdit/index.vue

@@ -31,7 +31,7 @@
 
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
-	import api from "@/api/material";
+	import api from '@/api/currency'
 	@Component
 	export default class MaterialEdit extends Vue {
 		baseURL : any = process.env.VUE_APP_BASE_API
@@ -348,7 +348,7 @@
 		getFormData() {
 			(this as any).$refs.form.validate().then(() => {
 				let data = (this as any).$refs.form.getValue();
-				api.update(data).then((res : any) => {
+				api.updateList(data,'maindataMaterial').then((res : any) => {
 					if (res.code === 200) {
 						(this as any).$tab.closeOpenPage('/materialFile/productManagement')
 						this.$message({ type: 'success', message: res.msg })

+ 9 - 46
src/views/audit/order/index.vue

@@ -1,6 +1,6 @@
 <template>
 	<div>
-		<by-bill :propConfig="config" @search="search" @onSmt="doSave" ref="bill" @onAdd="onAdd" @onOrder="onOrder"
+		<by-bill ref="bill" :propConfig="config" @search="search" @onSmt="doSave" @onAdd="onAdd" @onOrder="onOrder"
 			@resert="resert" @clickHandle="clickHandle" @detail="openEdit">
 		</by-bill>
 	</div>
@@ -9,9 +9,9 @@
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 	import api from "@/api/order";
-	import Assembly from "@/benyun/components/Assembly/order.vue";
+	import Assembly from "@/components/Assembly/order.vue";
 	@Component
-	export default class OrderTask extends Vue {
+	export default class Order extends Vue {
 		// 右边
 		baseURL : any = process.env.VUE_APP_BASE_API
 		setStatusData : any = ''
@@ -23,20 +23,10 @@
 			},
 			// 单据
 			bill: {
-				tool: {
-					customTools: [
-						{
-							name: '接单', icon: 'el-icon-plus', audit: [''], event: {
-								click: () => {
-									// (this as any).getOrder()
-								}
-							}
-						}
-					]
-				},
 				form: {
 					attr: {
 						size: 'small',
+						readonly: false,
 					},
 					columns: [
 						[
@@ -46,25 +36,6 @@
 								prop: 'organizationName',
 								component: 'by-input',
 							},
-							{
-								span: 8,
-								label: '状态',
-								prop: 'status',
-								component: 'by-select',
-								compConfig: {
-									attr: {
-										placeholder: '请选择状态',
-										clearable: true,
-										data: [{
-											value: 0,
-											label: '未接单'
-										}, {
-											value: 1,
-											label: '已接单'
-										}]
-									}
-								}
-							},
 							{
 								span: 8,
 								label: '单据编号',
@@ -72,13 +43,6 @@
 								prop: 'orderNumber',
 								component: 'by-input',
 							},
-							{
-								span: 8,
-								label: '机构',
-								slot: true,
-								prop: 'organizationId',
-								component: 'by-input',
-							},
 							{
 								span: 8,
 								label: '交货地点',
@@ -93,7 +57,7 @@
 								prop: 'deliveryData',
 								component: 'by-date-picker',
 								compConfig: {
-									format: 'yyyy-MM-dd',
+									format: 'yyyy-MM-dd hh:ss:mm',
 									type: 'datetime'
 								}
 							},
@@ -295,7 +259,10 @@
 							}, {
 								name: '接单',
 								event: {
-									click: (item : any) => (this as any).getOrder(item)
+									click: (item : any) => {
+										// console.log(Assembly);
+										(this as any).getOrder(item)
+									}
 								}
 							}]
 						}
@@ -318,7 +285,6 @@
 			(this as any).$refs.bill.$refs.billForm.validate().then(() => {
 				let query = (this as any).$refs.bill.$refs.billForm.getValue();
 				// query.suborderList = [] // 子表单数据
-				query.status = 0; // 默认未接单
 				api.saveList(query, 'supplyTaskOrder').then((res : any) => {
 					if (res.code === 200) {
 						this.$message({
@@ -358,9 +324,6 @@
 			clearInterval(this.timer)
 			// submitState: 提交状态
 			this.getPageList({}, 'all'); // 综合数据
-			// recycleBin
-			this.getPageList({ submitState: 0 }, 'draftsBox'); // 草稿箱数据
-			this.getPageList({ submitState: 1 }, 'smt'); // 已提交数据
 		}
 		// 获取分页数据
 		getPageList(query : any, type : any) {

+ 48 - 71
src/views/audit/orderTask/index.vue

@@ -1,7 +1,7 @@
 <template>
 	<div>
 		<by-bill :propConfig="config" @search="search" @onSmt="doSave" ref="bill" @onAdd="onAdd" @onOrder="onOrder"
-			@resert="resert" @clickHandle="clickHandle" @detail="openEdit">
+			@resert="resert" @clickHandle="clickHandle" @detail="openEdit" @clickTab="clickTab">
 		</by-bill>
 	</div>
 </template>
@@ -9,7 +9,7 @@
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 	import api from "@/api/order";
-	import Assembly from "@/benyun/components/Assembly/order.vue";
+	import Assembly from "@/components/Assembly/order.vue";
 	@Component
 	export default class OrderTask extends Vue {
 		// 右边
@@ -25,21 +25,22 @@
 			bill: {
 				tool: {
 					tools: {
+						save: true,
 						smt: true,
-					},
-					customTools: [
-						{
-							name: '保存', icon: 'el-icon-plus', audit: [''], event: {
-								click: () => {
-									(this as any).orderTaking()
-								}
-							}
-						}
-					]
+					}
 				},
 				form: {
 					attr: {
 						size: 'small',
+						readonly: false,
+						rules: {
+							organizationName: [{
+								required: true, message: '请输入机构名称', trigger: 'blur'
+							}],
+							orderNumber: [{
+								required: true, message: '请输入单据编号', trigger: 'blur'
+							}]
+						}
 					},
 					columns: [
 						[
@@ -49,25 +50,6 @@
 								prop: 'organizationName',
 								component: 'by-input',
 							},
-							{
-								span: 8,
-								label: '状态',
-								prop: 'status',
-								component: 'by-select',
-								compConfig: {
-									attr: {
-										placeholder: '请选择状态',
-										clearable: true,
-										data: [{
-											value: 0,
-											label: '未接单'
-										}, {
-											value: 1,
-											label: '已接单'
-										}]
-									}
-								}
-							},
 							{
 								span: 8,
 								label: '单据编号',
@@ -75,13 +57,6 @@
 								prop: 'orderNumber',
 								component: 'by-input',
 							},
-							{
-								span: 8,
-								label: '机构',
-								slot: true,
-								prop: 'organizationId',
-								component: 'by-input',
-							},
 							{
 								span: 8,
 								label: '交货地点',
@@ -363,25 +338,6 @@
 									}
 								}
 							},
-							{
-								span: 6,
-								label: '状态',
-								prop: 'status',
-								component: 'by-select',
-								compConfig: {
-									attr: {
-										placeholder: '请选择状态',
-										clearable: true,
-										data: [{
-											value: 0,
-											label: '未接单'
-										}, {
-											value: 1,
-											label: '已接单'
-										}]
-									}
-								}
-							},
 							{
 								span: 6,
 								label: '交货时间',
@@ -424,12 +380,6 @@
 							field: 'organizationName',
 							isDetail: true,
 						},
-						{
-							width: 80,
-							title: '状态',
-							field: 'status',
-							component: Assembly,
-						},
 						{
 							width: 200,
 							title: '交货地点',
@@ -572,7 +522,7 @@
 				tool: {
 					tools: {
 						add: true,
-						order: true,
+						dispatch: true,
 						export: true,
 						delete: true,
 						search: true,
@@ -762,6 +712,7 @@
 							width: 200,
 							title: '机构名称',
 							field: 'organizationName',
+							isDetail: true,
 						},
 						{
 							width: 80,
@@ -795,6 +746,21 @@
 							title: '备注',
 							field: 'remark',
 						},
+						{
+							width: 110,
+							title: '操作',
+							action: true,
+							plugins: [{
+								// icon: 'el-icon-edit',
+								name: '查看',
+								audit: '',
+								event: {
+									click: (item : any) => {
+										(this as any).openEdit(item)
+									}
+								}
+							}]
+						}
 					]
 				}
 
@@ -809,6 +775,21 @@
 		clickHandle(e : any) {
 			console.log(e);
 		}
+		// 切换tab栏
+		clickTab(e : any) {
+			console.log(e);
+			if (e === 'draftsBox') this.getPageList({ submitState: 0 }, 'draftsBox'); // 草稿箱数据
+			if (e === 'smt') this.getPageList({ submitState: 1 }, 'smt'); // 已提交数据
+			if (e === 'recycleBin') { // 回收站数据
+				// let data = (this as any).$lodash.cloneDeep(this.config.bill);
+				// data.form.attr.readonly = true;
+				// for (const item of data.tableConfig) {
+				// 	delete item.tool
+				// }
+				// (this.$refs.bill as any).setBillConfig(data)
+				this.getSelectDeleteList('supplyTaskOrder')
+			}
+		}
 		// 保存新增
 		doSave() {
 			// (this.$refs.product as any).setShow(true)
@@ -855,10 +836,6 @@
 			clearInterval(this.timer)
 			// submitState: 提交状态
 			this.getPageList({}, 'all'); // 综合数据
-			// recycleBin
-			this.getPageList({ submitState: 0 }, 'draftsBox'); // 草稿箱数据
-			this.getPageList({ submitState: 1 }, 'smt'); // 已提交数据
-			this.getSelectDeleteList('supplyTaskOrder') // 回收站数据
 		}
 		// 获取分页数据
 		getPageList(query : any, type : any) {
@@ -875,7 +852,7 @@
 			})
 		}
 		// 回收站数据
-		getSelectDeleteList(url:any){
+		getSelectDeleteList(url : any) {
 			api.selectDeleteList(url).then((res : any) => {
 				if (res.code === 200) {
 					(this.$refs.bill as any).setTabTableValue('recycleBin', res.data);
@@ -920,7 +897,7 @@
 				})
 			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
 			ids = ids.slice(0, ids.length - 1);
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -944,7 +921,7 @@
 		}
 		// 操作删除
 		doDelete2(item : any) {
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',

+ 8 - 0
src/views/audit/outbound/index.vue

@@ -0,0 +1,8 @@
+<template>
+</template>
+
+<script>
+</script>
+
+<style>
+</style>

+ 34 - 7
src/views/audit/productClassification/index.vue

@@ -29,7 +29,8 @@
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 	import api from "@/api/currency";
-	import Assembly from "@/benyun/components/Assembly/material.vue";
+	// import other from '@/api/other'
+	import Assembly from "@/components/Assembly/material.vue";
 	@Component
 	export default class ProductClassification extends Vue {
 		// 左边
@@ -103,7 +104,6 @@
 			tool: {
 				tools: {
 					add: true,
-					export: true,
 					delete: true,
 					search: true,
 					refresh: true
@@ -135,6 +135,7 @@
 					title: '备注',
 					field: 'remark',
 				}, {
+					width: 120,
 					title: '操作',
 					action: true,
 					plugins: [{
@@ -166,6 +167,25 @@
 			},
 			columns: [
 				[
+					{
+						span: 23,
+						label: '父级',
+						labelWidth: '70px',
+						prop: 'parentId',
+						component: 'select-tree',
+						compConfig: {
+							attr: {
+								label: 'name',
+								clearable: true,
+								retConfig: {
+									parentId: 'id',
+								}
+							},
+							request: {
+								url: '/maindata/maindataMaterialCategory/treeList'
+							}
+						}
+					},
 					{
 						span: 23,
 						labelWidth: '70px',
@@ -210,7 +230,7 @@
 			api.treeList('maindataMaterialCategory').then((res : any) => {
 				// console.log(res.data[0]);
 				if (res.code === 200) {
-					this.data = res.data[0].children;
+					this.data = res.data;
 				} else this.failHandle(res)
 			})
 		}
@@ -218,6 +238,8 @@
 		confirm() {
 			(this as any).$refs.addFormId.validate().then(() => {
 				let query = (this as any).$refs.addFormId.getValue();
+				console.log('确认新增/编辑 ==> ', query);
+				if (!query.parentId) query.parentId = 0;
 				query.status = this.radio;
 				this.dialogFormVisible = false;
 				if (this.popTitle === '新增') {
@@ -227,6 +249,7 @@
 								type: 'success',
 								message: this.popTitle + '成功!'
 							});
+							this.getTreeList();
 							this.getDataList();
 						} else this.failHandle(res)
 					})
@@ -237,6 +260,7 @@
 								type: 'success',
 								message: this.popTitle + '成功!'
 							});
+							this.getTreeList();
 							this.getDataList();
 						} else this.failHandle(res)
 					})
@@ -254,7 +278,7 @@
 			}
 			clearInterval(this.timer)
 			let query = (this.$refs.moduleView as any).getQuery();
-			console.log('表单字段 ==> ', query);
+			// console.log('表单字段 ==> ', query);
 			api.pageList(query, 'maindataMaterialCategory').then((res : any) => {
 				if (res.code === 200) {
 					(this.$refs.moduleView as any).setTableValue(res.data.records);
@@ -285,6 +309,7 @@
 		}
 		// 打开编辑
 		openEdit(e : any) {
+			console.log('打开编辑 ==> ', e);
 			this.popTitle = '编辑'
 			this.dialogFormVisible = true;
 			this.radio = e.status
@@ -302,7 +327,7 @@
 				})
 			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
 			ids = ids.slice(0, ids.length - 1);
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -310,6 +335,7 @@
 			}).then(() => {
 				api.deleteList({ ids: ids }, 'maindataMaterialCategory').then((res : any) => {
 					if (res.code === 200) {
+						this.getTreeList();
 						this.getDataList();
 						this.$message({
 							type: 'success',
@@ -326,7 +352,7 @@
 		}
 		// 操作删除
 		doDelete2(item : any) {
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -334,6 +360,7 @@
 			}).then(() => {
 				api.deleteList({ ids: item.id }, 'maindataMaterialCategory').then((res : any) => {
 					if (res.code === 200) {
+						this.getTreeList();
 						this.getDataList();
 						this.$message({
 							type: 'success',
@@ -350,7 +377,7 @@
 		}
 		// 导航切换
 		handleNodeClick(e : any) {
-			api.childrenTreeList({ id: e.id },'maindataMaterialCategory').then((res : any) => {
+			api.childrenTreeList({ id: e.id }, 'maindataMaterialCategory').then((res : any) => {
 				if (res.code === 200) {
 					(this.$refs.moduleView as any).setTableValue(res.data);
 					let page = {

+ 433 - 39
src/views/audit/productManagement/index.vue

@@ -1,29 +1,361 @@
 <template>
 	<div class="my-container">
-		<div class="bill-left">
-			<div class="bill-tab">
-				<div class="title">导航</div>
-				<el-tree :data="data" :props="props" @node-click="handleNodeClick"></el-tree>
+		<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="title">导航</div>
+					<el-tree :data="data" :props="props" @node-click="handleNodeClick"></el-tree>
+				</div>
 			</div>
-		</div>
-		<div class="bill-main">
-			<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
-				@resert="getDataList" @clickHandle="clickHandle" @detail="getDetail" />
-		</div>
+			<div class="bill-main" v-show="isShow==='home'" key="item2">
+				<module-view :propConfig="config" ref="moduleView" @pagination="getDataList" @search="getDataList"
+					@resert="getDataList" @clickHandle="clickHandle" @detail="getDetail" />
+			</div>
+			<div class="detil" v-show="isShow==='add'" key="item3">
+				<by-tool :propConfig="toolConfig" @clickHandle="insideTools" />
+				<div class="box-shadow">
+					<by-form :propConfig="formConfig" ref="form">
+						<template v-slot:description>
+							<el-input type="textarea" :rows="5" placeholder="请输入内容" v-model="textarea">
+							</el-input>
+						</template>
+						<template v-slot:radio>
+							<el-radio v-model="radio" :label="1">单规格</el-radio>
+							<el-radio v-model="radio" :label="2">多规格</el-radio>
+						</template>
+
+						<template v-slot:status>
+							<el-radio v-model="radioStatus" :label="1">启用</el-radio>
+							<el-radio v-model="radioStatus" :label="2">备用</el-radio>
+							<el-radio v-model="radioStatus" :label="3">禁用</el-radio>
+						</template>
+						<template v-slot:ismakeup>
+							<el-radio v-model="ismakeup" :label="1">是</el-radio>
+							<el-radio v-model="ismakeup" :label="2">否</el-radio>
+						</template>
+						<template v-slot:issued>
+							<el-radio v-model="issued" :label="1">是</el-radio>
+							<el-radio v-model="issued" :label="2">否</el-radio>
+						</template>
+					</by-form>
+				</div>
+			</div>
+		</transition-group>
 	</div>
 </template>
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
-	import api from "@/api/material";
+	import api from '@/api/currency'
+	import other from '@/api/other'
 	@Component({})
 	export default class productManagement extends Vue {
+		isShow = 'home'
+		isClick = false
 		timeNum = 0;
 		timer : any = null
 		data : any = []
+		radio : any = 1
+		radioStatus : any = 1
+		ismakeup : any = 1
+		issued : any = 1
+		textarea : any = ''
 		props = {
 			label: 'name',
 			children: 'children'
 		}
+		toolConfig = {
+			tools: {
+				return: true,
+				save: true,
+			}
+		}
+		formConfig = {
+			attr: {
+				size: 'small',
+				rules: {
+					name: [{
+						required: true, message: '请输入名称', trigger: 'blur'
+					}],
+					shortName: [{
+						required: true, message: '请输入简称', trigger: 'blur'
+					}]
+				}
+			},
+			columns: [
+				[
+					{
+						span: 6,
+						label: '名称',
+						prop: 'name',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入名称',
+								clearable: true
+							}
+						}
+					},
+					{
+						span: 6,
+						label: '简称',
+						prop: 'shortName',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入简称',
+								clearable: true
+							}
+						}
+					},
+					{
+						span: 6,
+						label: '财务编号',
+						prop: 'accountingCode',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入财务编号',
+								clearable: true
+							}
+						}
+					},
+					{
+						span: 6,
+						label: '国际码',
+						prop: 'nsCode',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入国际码',
+								clearable: true
+							}
+						}
+					},
+				],
+				[
+					{
+						span: 6,
+						label: '基本售价',
+						prop: 'basePrice',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入基本售价',
+								clearable: true
+							}
+						}
+					}, {
+						span: 6,
+						label: '市场价格',
+						prop: 'markPrice',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入市场价格',
+								clearable: true
+							}
+						}
+					},
+					{
+						span: 6,
+						label: '价格',
+						prop: 'price',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入价格(成交、成本价)',
+								clearable: true
+							}
+						}
+					},
+					{
+						span: 6,
+						label: '单位',
+						prop: 'unit',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入单位',
+								clearable: true
+							}
+						}
+					},
+				],
+
+				[
+					{
+						span: 6,
+						label: '重量',
+						prop: 'weight',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入重量',
+								clearable: true
+							}
+						}
+					},
+					{
+						span: 6,
+						label: '保质期(天)',
+						prop: 'shelfLife',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入保质期(天)',
+								clearable: true
+							}
+						}
+					},
+					{
+						span: 6,
+						label: '库存',
+						prop: 'stock',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入库存',
+								clearable: true
+							}
+						}
+					},
+					{
+						span: 6,
+						label: '安全库存',
+						prop: 'warningStock',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入安全库存',
+								clearable: true
+							}
+						}
+					}
+				],
+				[
+					{
+						span: 6,
+						label: '货号',
+						prop: 'itemNumber',
+						component: 'by-input',
+						compConfig: {
+							attr: {
+								placeholder: '请输入货号',
+								clearable: true
+							}
+						}
+					},
+					{
+						span: 6,
+						label: '物料分类',
+						prop: 'select',
+						component: 'by-select',
+						compConfig: {
+							attr: {
+								placeholder: '请选择数据',
+								clearable: true,
+							},
+							request: '/maindata/maindataMaterialCategory/treeList'
+						},
+					},
+					{
+						span: 6,
+						label: '虚拟分类',
+						prop: 'select',
+						component: 'by-select',
+						compConfig: {
+							attr: {
+								placeholder: '请选择数据',
+								clearable: true,
+							},
+							request: '/maindata/maindataMaterialCategory/treeList'
+						},
+					},
+					{
+						span: 6,
+						label: '厂家物料',
+						prop: 'factoryId',
+						component: 'by-select',
+						compConfig: {
+							attr: {
+								placeholder: '请选择数据',
+								clearable: true,
+							},
+							request: '/maindata/maindataMaterialCategory/treeList'
+						},
+					}
+				],
+				[
+					{
+						span: 6,
+						label: '机构商品分类',
+						prop: 'select',
+						component: 'by-select',
+						compConfig: {
+							attr: {
+								placeholder: '请选择数据',
+								clearable: true,
+							},
+							request: '/maindata/maindataMaterialCategory/treeList'
+						},
+					},
+					{
+						span: 6,
+						label: '物料属性表',
+						prop: 'select',
+						component: 'by-select',
+						compConfig: {
+							attr: {
+								placeholder: '请选择数据',
+								clearable: true,
+							},
+							request: '/maindata/maindataMaterialCategory/treeList'
+						},
+					}
+				],
+				[
+					{
+						span: 30,
+						label: '描述',
+						slot: true,
+						prop: 'description',
+					}
+				],
+				[
+					{
+						span: 20,
+						label: '商品规格',
+						slot: true,
+						prop: 'radio',
+					}
+				],
+				[
+					{
+						span: 20,
+						label: '物料状态',
+						slot: true,
+						prop: 'status',
+					}
+				],
+				[
+					{
+						span: 20,
+						label: '是否组合商品',
+						slot: true,
+						prop: 'ismakeup',
+					}
+				],
+				[
+					{
+						span: 20,
+						label: '是否公布',
+						slot: true,
+						prop: 'issued',
+					}
+				],
+			],
+
+		}
 		config : any = {
 			search: {
 				attr: {
@@ -137,7 +469,12 @@
 				]
 			},
 			tool: {
-				tools: this.getTools()
+				tools: {
+					add: true,
+					delete: true,
+					search: true,
+					refresh: true
+				}
 			},
 			table: {
 				attr: {
@@ -195,8 +532,7 @@
 						audit: '',
 						event: {
 							click: (item : any) => {
-								(this as any).$router.push({ name: 'MaterialEdit', params: { baseInfo: item } });
-								// console.log('该行数据:', item)
+								(this as any).getDetail(item)
 							}
 						}
 					}, {
@@ -208,30 +544,18 @@
 				}]
 			},
 		}
-		getTools() {
-			return {
-				add: true,
-				export: true,
-				delete: true,
-				search: true,
-				refresh: true
-			}
-		}
 		created() {
 			this.getTreeList()
 			this.timer = setInterval(() => {
 				this.getDataList()
 			}, 500)
 		}
-		getDetail(e : any) {
-			(this as any).$router.push({ name: 'MaterialEdit', params: { baseInfo: e } });
-		}
 		// 获取树型导航数据
 		getTreeList() {
-			api.treeList({}).then((res : any) => {
+			api.treeList('maindataMaterialCategory').then((res : any) => {
 				// console.log(res.data[0]);
 				if (res.code === 200) {
-					this.data = res.data[0].children;
+					this.data = res.data;
 				} else this.failHandle(res)
 			})
 		}
@@ -247,7 +571,7 @@
 			clearInterval(this.timer)
 			let query = (this.$refs.moduleView as any).getQuery();
 			// console.log(query);
-			api.page(query).then((res : any) => {
+			api.pageList(query, 'maindataMaterial').then((res : any) => {
 				// console.log(res.data);
 				if (res.code === 200) {
 					(this.$refs.moduleView as any).setTableValue(res.data.records);
@@ -260,17 +584,57 @@
 				} else this.failHandle(res)
 			})
 		}
+		// 保存编辑/新增
+		doFormData() {
+			(this as any).$refs.form.validate().then(() => {
+				let data = (this as any).$refs.form.getValue();
+				if (this.isClick) { // 编辑
+					api.updateList(data, 'maindataMaterial').then((res : any) => {
+						if (res.code === 200) {
+							this.isShow = 'home';
+							this.getDataList();
+							this.$message({ type: 'success', message: res.msg })
+						}
+					})
+				} else { // 新增
+					data.description = this.textarea;
+					data.status = this.radioStatus;
+					data.ismakeup = this.ismakeup;
+					data.issued = this.issued;
+					api.saveList(data, 'maindataMaterial').then((res : any) => {
+						if (res.code === 200) {
+							this.isShow = 'home';
+							this.getDataList();
+							this.$message({ type: 'success', message: res.msg })
+						}
+					})
+				}
+			});
+		}
 		// 工具栏方法
 		clickHandle(e : any) {
-			// console.log(e);
 			if (e === 'onRefresh') (this.$refs.moduleView as any).resert();
 			if (e === 'onAdd') this.onAdd();
 			if (e === 'onDelete') this.doDelete();
 			if (e === 'onExport') this.onExport();
 		}
+		// 内页工具栏方法
+		insideTools(e : any) {
+			console.log(e);
+			if (e === 'onReturn') this.isShow = 'home';
+			if (e === 'onSave') this.doFormData();
+		}
 		// 新增
 		onAdd() {
-			(this as any).$router.push('/materialFile/materialAdd')
+			if (this.isClick) (this as any).$refs.form.setValue({})
+			this.isShow = 'add';
+			this.isClick = false;
+		}
+		// 编辑
+		getDetail(e : any) {
+			this.isClick = true;
+			this.isShow = 'add';
+			(this as any).$refs.form.setValue(e)
 		}
 		// 工具栏删除
 		doDelete() {
@@ -282,15 +646,13 @@
 				})
 			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
 			ids = ids.slice(0, ids.length - 1);
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
 				center: true
 			}).then(() => {
-				api.materialDelete({
-					ids: ids
-				}).then((res : any) => {
+				api.deleteList({ ids: ids }, 'maindataMaterial').then((res : any) => {
 					if (res.code === 200) {
 						this.getDataList();
 						this.$message({
@@ -308,15 +670,13 @@
 		}
 		// 操作删除
 		doDelete2(item : any) {
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
 				center: true
 			}).then(() => {
-				api.materialDelete({
-					ids: item.id
-				}).then((res : any) => {
+				api.deleteList({ ids: item.id }, 'maindataMaterial').then((res : any) => {
 					if (res.code === 200) {
 						this.getDataList();
 						this.$message({
@@ -334,7 +694,7 @@
 		}
 		// 导航切换
 		handleNodeClick(e : any) {
-			api.single({ categoryId: e.id }).then((res : any) => {
+			other.single({ categoryId: e.id }).then((res : any) => {
 				if (res.code === 200) {
 					(this.$refs.moduleView as any).setTableValue(res.data.records);
 					let page = {
@@ -363,6 +723,16 @@
 	}
 </script>
 <style lang="scss" scoped>
+	.fade-leave,
+	.fade-enter-to {
+		opacity: 1;
+	}
+
+	.fade-leave-to,
+	.fade-enter {
+		opacity: 0;
+	}
+
 	.my-container {
 		width: 100%;
 		box-sizing: border-box;
@@ -463,5 +833,29 @@
 				z-index: 1;
 			}
 		}
+
+		.detil {
+			width: 100%;
+			padding: 20px;
+
+			.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>

+ 8 - 0
src/views/audit/returnGoods/index.vue

@@ -0,0 +1,8 @@
+<template>
+</template>
+
+<script>
+</script>
+
+<style>
+</style>

+ 19 - 155
src/views/audit/saleOrder/index.vue

@@ -9,12 +9,8 @@
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 	import api from "@/api/order";
-	import Assembly from "@/benyun/components/Assembly/order.vue";
 	@Component
 	export default class OrderTask extends Vue {
-		// 右边
-		baseURL : any = process.env.VUE_APP_BASE_API
-		setStatusData : any = ''
 		timeNum = 0;
 		timer : any = null
 		config : any = {
@@ -24,14 +20,11 @@
 			// 单据
 			bill: {
 				tool: {
-					// tools: {
-					// 	smt: true,
-					// },
 					customTools: [
 						{
 							name: '拆单', icon: 'el-icon-plus', audit: [''], event: {
 								click: () => {
-									// (this as any).orderTaking()
+									(this as any).orderTaking()
 								}
 							}
 						}
@@ -147,18 +140,16 @@
 							},
 							{
 								span: 6,
-								label: '交货地点',
-								prop: 'deliveryAddress',
+								label: '退单编号',
+								prop: 'chargebackNo',
 								component: 'by-input',
 								compConfig: {
 									attr: {
-										placeholder: '请输入交货地点',
+										placeholder: '请输入退单编号',
 										clearable: true
 									}
 								}
 							},
-						],
-						[
 							{
 								span: 6,
 								label: '交货人',
@@ -171,6 +162,8 @@
 									}
 								}
 							},
+						],
+						[
 							{
 								span: 6,
 								label: '交货时间',
@@ -190,15 +183,6 @@
 						search: true,
 						refresh: true
 					},
-					customTools: [
-						{
-							name: '拆单', icon: 'el-icon-plus', audit: [''], event: {
-								click: () => {
-									// (this as any).orderTaking()
-								}
-							}
-						}
-					]
 				},
 				table: {
 					attr: {
@@ -270,126 +254,6 @@
 					]
 				}
 			},
-			// 回收站
-			// recycleBin: {
-			// 	search: {
-			// 		attr: {
-			// 			size: 'mini',
-			// 		},
-			// 		columns: [
-			// 			[
-			// 				{
-			// 					span: 6,
-			// 					label: '机构名称',
-			// 					prop: 'organizationName',
-			// 					component: 'by-input',
-			// 					compConfig: {
-			// 						attr: {
-			// 							placeholder: '请输入机构名称',
-			// 							clearable: true
-			// 						},
-			// 					},
-			// 				},
-			// 				{
-			// 					span: 6,
-			// 					label: '单据编号',
-			// 					prop: 'orderNumber',
-			// 					component: 'by-input',
-			// 					compConfig: {
-			// 						attr: {
-			// 							placeholder: '请输入单据编号',
-			// 							clearable: true
-			// 						}
-			// 					}
-			// 				},
-			// 				{
-			// 					span: 6,
-			// 					label: '交货地点',
-			// 					prop: 'deliveryAddress',
-			// 					component: 'by-input',
-			// 					compConfig: {
-			// 						attr: {
-			// 							placeholder: '请输入交货地点',
-			// 							clearable: true
-			// 						}
-			// 					}
-			// 				},
-			// 			],
-			// 			[
-			// 				{
-			// 					span: 6,
-			// 					label: '交货人',
-			// 					prop: 'delivery',
-			// 					component: 'by-input',
-			// 					compConfig: {
-			// 						attr: {
-			// 							placeholder: '请输入交货人',
-			// 							clearable: true
-			// 						}
-			// 					}
-			// 				},
-			// 				{
-			// 					span: 6,
-			// 					label: '交货时间',
-			// 					prop: 'deliveryData',
-			// 					component: 'by-date-picker',
-			// 					compConfig: {
-			// 						format: 'yyyy-MM-dd hh:ss:mm',
-			// 						type: 'datetime'
-			// 					}
-			// 				},
-			// 			]
-			// 		]
-			// 	},
-			// 	table: {
-			// 		attr: {
-			// 			height: 600,
-			// 			size: 'mini',
-			// 			seq: true,
-			// 			align: 'center',
-			// 			checkbox: true
-			// 		},
-			// 		columns: [
-			// 			{
-			// 				width: 70,
-			// 				title: '单据编号',
-			// 				field: 'orderNumber',
-			// 			},
-			// 			{
-			// 				width: 200,
-			// 				title: '机构名称',
-			// 				field: 'organizationName',
-			// 			},
-			// 			{
-			// 				width: 200,
-			// 				title: '交货地点',
-			// 				field: 'deliveryAddress',
-			// 			},
-			// 			{
-			// 				width: 150,
-			// 				title: '交货时间',
-			// 				field: 'deliveryData',
-			// 			},
-			// 			{
-			// 				title: '交货人',
-			// 				field: 'delivery',
-			// 			},
-			// 			{
-			// 				title: '交货人联系方式',
-			// 				field: 'deliveryPhone',
-			// 			},
-			// 			{
-			// 				title: '交货方式',
-			// 				field: 'deliveryWay',
-			// 			},
-			// 			{
-			// 				title: '备注',
-			// 				field: 'remark',
-			// 			},
-			// 		]
-			// 	}
-			
-			// }
 		}
 		created() {
 			this.timer = setInterval(() => {
@@ -420,20 +284,20 @@
 				})
 			})
 		}
-		// 保存修改
+		// 拆单
 		orderTaking() {
-			let query : any = (this as any).$refs.bill.$refs.billForm.getValue();
-			api.updateList(query, 'supplyPurchaseOrder').then((res : any) => {
-				if (res.code === 200) {
-					this.$message({
-						type: 'success',
-						message: '保存成功!'
-					});
-					this.getDataList();
-					(this.$refs.bill as any).showTab = 'all';
-					(this.$refs.bill as any).setBillFormValue({});
-				} else this.failHandle(res)
-			})
+			// let query : any = (this as any).$refs.bill.$refs.billForm.getValue();
+			// api.updateList(query, 'supplyPurchaseOrder').then((res : any) => {
+			// 	if (res.code === 200) {
+			// 		this.$message({
+			// 			type: 'success',
+			// 			message: '保存成功!'
+			// 		});
+			// 		this.getDataList();
+			// 		(this.$refs.bill as any).showTab = 'all';
+			// 		(this.$refs.bill as any).setBillFormValue({});
+			// 	} else this.failHandle(res)
+			// })
 		}
 		getDataList() {
 			if (!this.$refs.bill) {

+ 29 - 5
src/views/audit/virtually/index.vue

@@ -29,7 +29,7 @@
 <script lang="ts">
 	import { Component, Prop, Vue, Watch } from "vue-property-decorator";
 	import api from "@/api/currency";
-	import Assembly from "@/benyun/components/Assembly/material.vue";
+	import Assembly from "@/components/Assembly/material.vue";
 	@Component
 	export default class Virtually extends Vue {
 		// 左边
@@ -103,7 +103,6 @@
 			tool: {
 				tools: {
 					add: true,
-					export: true,
 					delete: true,
 					search: true,
 					refresh: true
@@ -135,6 +134,7 @@
 					title: '备注',
 					field: 'remark',
 				}, {
+					width: 120,
 					title: '操作',
 					action: true,
 					plugins: [{
@@ -166,6 +166,25 @@
 			},
 			columns: [
 				[
+					{
+						span:23,
+						label:'父级',
+						labelWidth: '70px',
+						prop:'parentId',
+						component:'select-tree',
+						compConfig:{
+						  attr:{
+						    label:'name',
+						    clearable:true,
+						    retConfig:{
+						      parentId:'id',
+						    }
+						  },
+						  request:{
+						    url:'/maindata/maindataMaterialVmcategory/treeList'
+						  }
+						}
+					},
 					{
 						span: 23,
 						labelWidth: '70px',
@@ -210,7 +229,7 @@
 			api.treeList('maindataMaterialVmcategory').then((res : any) => {
 				// console.log(res.data[0]);
 				if (res.code === 200) {
-					this.data = res.data[0].children;
+					this.data = res.data;
 				} else this.failHandle(res)
 			})
 		}
@@ -218,6 +237,7 @@
 		confirm() {
 			(this as any).$refs.addFormId.validate().then(() => {
 				let query = (this as any).$refs.addFormId.getValue();
+				console.log(query);
 				query.status = this.radio;
 				this.dialogFormVisible = false;
 				if (this.popTitle === '新增') {
@@ -227,6 +247,7 @@
 								type: 'success',
 								message: this.popTitle + '成功!'
 							});
+							this.getTreeList();
 							this.getDataList();
 						} else this.failHandle(res)
 					})
@@ -237,6 +258,7 @@
 								type: 'success',
 								message: this.popTitle + '成功!'
 							});
+							this.getTreeList();
 							this.getDataList();
 						} else this.failHandle(res)
 					})
@@ -302,7 +324,7 @@
 				})
 			} else return this.$message({ type: 'warning', message: '请选择删除数据' })
 			ids = ids.slice(0, ids.length - 1);
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -310,6 +332,7 @@
 			}).then(() => {
 				api.deleteList({ ids: ids }, 'maindataMaterialVmcategory').then((res : any) => {
 					if (res.code === 200) {
+						this.getTreeList();
 						this.getDataList();
 						this.$message({
 							type: 'success',
@@ -326,7 +349,7 @@
 		}
 		// 操作删除
 		doDelete2(item : any) {
-			this.$confirm('确定删除吗,此操作不能撤销!', '提示', {
+			this.$confirm('确定删除吗,此操作不能撤销!', '注意', {
 				confirmButtonText: '确定',
 				cancelButtonText: '取消',
 				type: 'warning',
@@ -334,6 +357,7 @@
 			}).then(() => {
 				api.deleteList({ ids: item.id }, 'maindataMaterialVmcategory').then((res : any) => {
 					if (res.code === 200) {
+						this.getTreeList();
 						this.getDataList();
 						this.$message({
 							type: 'success',

+ 8 - 0
src/views/audit/warehousing/index.vue

@@ -0,0 +1,8 @@
+<template>
+</template>
+
+<script>
+</script>
+
+<style>
+</style>

+ 1 - 1
src/views/demo/form.vue

@@ -20,7 +20,7 @@ export default class DemoForm extends Vue {
     attr:{
       size:'small',
       height:500,
-      readonly:true,
+      // readonly:true,
       rules:{
         name:[{
           required: true, message: '请输入名称', trigger: 'blur'

+ 3 - 3
src/views/demo/index.vue

@@ -45,7 +45,7 @@ export default class DemoIndex extends Vue {
     {
       title:'尺寸',
       field:'a',
-      data:['a1','a2','a3']
+      data:['a1','a2']
     },
     {
       title:'颜色',
@@ -67,7 +67,7 @@ export default class DemoIndex extends Vue {
     if(data.data){
       let d:Array<any>=[];
       data.data.forEach((item:any) => {
-        if(i == 0){ //第一次循环
+        if(i == 0){ // 第一次循环
           let obj:any={}
           obj[data.field] = item
           d.push(obj);
@@ -88,8 +88,8 @@ export default class DemoIndex extends Vue {
         console.log('最后结果:',d)
       }
     }
-    
   }
+	
 }
 </script>
 

+ 41 - 0
src/views/test.vue

@@ -0,0 +1,41 @@
+<template>
+	<div></div>
+</template>
+
+<script lang="ts">
+	import { Component, Vue } from "vue-property-decorator";
+	@Component
+	export default class Test extends Vue {
+		data : Array<any> = []
+		arr = [
+			[{
+				title: '尺寸',
+				field: 'a1',
+				data: [1, 2, 3]
+			}],
+			[{
+				title: '颜色',
+				field: 'a2',
+				data: [1, 2, 3]
+			}]
+		]
+
+
+		created() {
+			this.forFun(this.arr[0], 0)
+		}
+		forFun(data:any, i:any) {
+			i++;
+			for (const item of data) {
+				// if ()
+					if (this.arr[i]) {
+						this.forFun(this.arr[i], i)
+					}
+			}
+		}
+	}
+</script>
+
+<style lang="scss" scoped>
+
+</style>