e 4 年之前
父節點
當前提交
1bd2f3bd57

+ 1 - 1
.eslintrc.js

@@ -5,7 +5,7 @@ module.exports = {
   },
   extends: ['plugin:vue/essential'],
   rules: {
-    'no-console': process.env.NODE_ENV === 'production' ? 'error' : 'off',
+    'no-console': process.env.NODE_ENV === 'production'  ? 'error' : 'off',
     'no-debugger': process.env.NODE_ENV === 'production' ? 'error' : 'off'
   },
   parserOptions: {

+ 2 - 2
src/sdk/config.js

@@ -1,4 +1,4 @@
 export default {
-  serverAddress: 'http://115.238.57.190:8010'
-  // serverAddress: 'http://121.37.169.186:8010',
+  // serverAddress: 'http://115.238.57.190:8010'
+  serverAddress: 'http://121.37.169.186:8010',
 }

+ 8 - 8
src/views/Home/Home.vue

@@ -54,7 +54,7 @@
                         text-color="#fff"
                         active-text-color="#ffd04b"
                     >
-                        <div v-for="(item, index1) in menu " :key="index1">
+                        <div v-for="(item, index1) in menuData " :key="index1">
                             <el-submenu
                                 v-if="item.children && item.children.length > 0"
                                 :index="`${index1}`"
@@ -97,16 +97,16 @@
 </template>
 
 <script>
-// import { menuData } from "./mencCofig.js";
+import { menuData } from "./mencCofig.js";
 import { mapState } from 'vuex';
 
 export default {
     data() {
         return {
             // 菜单配置
-            menuData: [],
+            menuData: menuData,
             menuCollapse: false, //是否水平折叠收起菜单
-            defaultUnfoldedMenu: '', // 默认展开第一项
+            defaultUnfoldedMenu: [menuData[0], 1], // 默认展开第一项
             mainTitle: ''
         };
     },
@@ -130,9 +130,9 @@ export default {
     },
     computed: {
         ...mapState(['typeCode',]),
-        menu() {
-            return this.menuData;
-        }
+        // menu() {
+        //     return this.menuData;
+        // }
     },
     methods: {
         // 收取菜单按钮
@@ -177,7 +177,7 @@ export default {
         }
     },
     mounted() {
-        this.init();
+        // this.init();
     }
 };
 </script>

+ 289 - 77
src/views/Home/mencCofig.js

@@ -1,151 +1,151 @@
 
 export const menuData = [
     // {
-    //     optionName: "首页",
+    //     menuName: "首页",
     //     iconClassName: "el-icon-s-home",
-    //     routerName: "Index",
+    //     url: "Index",
     //     disabled: false
     // },
     {
-        optionName: "定点屠宰智能管控",
+        menuName: "定点屠宰智能管控",
         iconClassName: "el-icon-s-flag",
         disabled: false, // 是否禁用
-        childList: [
+        children: [
             {
-                optionName: '企业采购',
-                routerName: "firmBuy"
+                menuName: '企业采购',
+                url: "firmBuy"
             },
             {
-                optionName: '入待宰栏',
-                routerName: "inButcherHurdle"
+                menuName: '入待宰栏',
+                url: "inButcherHurdle"
             },
             {
-                optionName: '屠宰批次',
-                routerName: "slaughterBatch"
+                menuName: '屠宰批次',
+                url: "slaughterBatch"
             },
             {
-                optionName: '品控检疫',
-                routerName: "reportQuarantine"
+                menuName: '品控检疫',
+                url: "reportQuarantine"
             },
             {
-                optionName: '入宰登记',
-                routerName: "regisSlaughter"
+                menuName: '入宰登记',
+                url: "regisSlaughter"
             },
             {
-                optionName: '屠宰分割', // 宰后称重
-                routerName: "slaughterWeight"
+                menuName: '屠宰分割', // 宰后称重
+                url: "slaughterWeight"
             },
             {
-                optionName: '入库管理',
-                routerName: "inStore"
+                menuName: '入库管理',
+                url: "inStore"
             },
             {
-                optionName: '出仓管理',
-                routerName: "outStore"
+                menuName: '出仓管理',
+                url: "outStore"
+            },
+            {
+                menuName: '分割批次',
+                url: "splitBatch"
             },
 
             {
-                optionName: '分割加工',
-                routerName: "segmentation"
+                menuName: '分割加工',
+                url: "segmentation"
             },
             // {
-            //     optionName: '排酸损耗',
-            //     routerName: "drainageAcid"
+            //     menuName: '排酸损耗',
+            //     url: "drainageAcid"
             // },
-            {
-                optionName: '分割批次',
-                routerName: "splitBatch"
-            },
             // {
-            //     optionName: '成本核算',
-            //     routerName: "costAccounting"
+            //     menuName: '成本核算',
+            //     url: "costAccounting"
             // }
         ]
     },
     {
-        optionName: "销售管理",
+        menuName: "销售管理",
         iconClassName: "el-icon-s-custom",
         disabled: false,
-        childList: [
+        children: [
             {
-                optionName: '客户管理',
-                routerName: "client"
+                menuName: '客户管理',
+                url: "client"
             },
             {
-                optionName: '价格管理',
-                routerName: "price"
+                menuName: '价格管理',
+                url: "price"
             },
             {
-                optionName: '销售统计',
-                routerName: "sellRegister"
+                menuName: '销售统计',
+                url: "sellRegister"
             },
             {
-                    optionName: '屠宰直销',
-                routerName: "directSell"
+                    menuName: '屠宰直销',
+                url: "directSell"
             },
             {
-                optionName: '胴体销售',
-                routerName: "carcassSell"
+                menuName: '胴体销售',
+                url: "carcassSell"
             },
             {
-                optionName: '分割销售',
-                    routerName: "splitSell"
+                menuName: '分割销售',
+                    url: "splitSell"
             },
             {
-                optionName: '其他销售',
-                routerName: "elseSell"
+                menuName: '其他销售',
+                url: "elseSell"
             },
         ]
     },
     {
-        optionName: "产品制作智能监控",
+        menuName: "产品制作智能监控",
         iconClassName: "el-icon-ice-cream-square",
         disabled: false,
-        childList: [
+        children: [
             {
-                optionName: '产品档案',
-                routerName: "productInfo"
+                menuName: '产品档案',
+                url: "productInfo"
             },
             {
-                optionName: '分割登记',
-                routerName: "splitLog"
+                menuName: '分割登记',
+                url: "splitLog"
             },
             {
-                optionName: '羊皮登记',
-                routerName: "sheepskinLog"
+                menuName: '羊皮登记',
+                url: "sheepskinLog"
             },
             {
-                optionName: '羊血登记',
-                routerName: "goatBloodLog"
+                menuName: '羊血登记',
+                url: "goatBloodLog"
             },
             {
-                optionName: '羊杂登记',
-                routerName: "goatHasletLog"
+                menuName: '羊杂登记',
+                url: "goatHasletLog"
             },
 
         ]
     },
 
     {
-        optionName: "鲜肉储运智能管控",
+        menuName: "鲜肉储运智能管控",
         iconClassName: "el-icon-shopping-cart-1",
         disabled: false,
-        childList: [
+        children: [
             {
-                optionName: '配送管理',
-                routerName: "dispatching"
+                menuName: '配送管理',
+                url: "dispatching"
             },
             // {
-            //     optionName: '运输管理',
-            //     routerName: "transportation"
+            //     menuName: '运输管理',
+            //     url: "transportation"
             // },
             // {
-            //     optionName: '门店管理',
-            //     routerName: "shopStore"
+            //     menuName: '门店管理',
+            //     url: "shopStore"
             // },
             {
-                optionName: '产品追溯',
-                routerName: "productQuery"
+                menuName: '产品追溯',
+                url: "productQuery"
             },
         ]
     }
@@ -157,18 +157,230 @@ export const menuData = [
 
 
 /* 菜单配置 描述 */
+// const menuData描述 = [
+//     // 有子菜单 并且字菜单分组的
+//     {
+//         oneMenuName: "导航一", // 一级菜单名
+//         iconClassName: "aaa", // element-ui图标名
+//         children: [ // 分组的
+//             {
+//                 groupName: '组名一',
+//                 list: [
+//                     {
+//                         menuName: '选项1',
+//                         url: "home"
+//                     },
+//                     {}
+//                 ],
+//             },
+//             {
+//                 groupName: '组名二',
+//                 list: [
+//                     {
+//                         menuName: '选项1',
+//                         url: "home"
+//                     },
+//                     {}
+//                 ],
+//             }
+//         ],
+//     },
+//     // 有子菜单 字菜单不分组的
+//     {
+//         oneMenuName: "导航二",
+//         iconClassName: "el-icon-menu",
+//         disabled: false, // 是否禁用
+//         children: [ // 不分组的
+//             {
+//                 menuName: '选项1',
+//                 url: "home"
+//             },
+//             {}
+//         ]
+//     },
+//     // 无子菜单的
+//     {
+//         oneMenuName: "导航三",
+//         iconClassName: "el-icon-document",
+//         url: "home",
+//         disabled: false
+//     },
+//
+//     "导航四"
+// ]
+
+
+
+// export const menuData = [
+//     // {
+//     //     menuName: "首页",
+//     //     iconClassName: "el-icon-s-home",
+//     //     url: "Index",
+//     //     disabled: false
+//     // },
+//     {
+//         menuName: "定点屠宰智能管控",
+//         iconClassName: "el-icon-s-flag",
+//         disabled: false, // 是否禁用
+//         children: [
+//             {
+//                 menuName: '企业采购',
+//                 url: "firmBuy"
+//             },
+//             {
+//                 menuName: '入待宰栏',
+//                 url: "inButcherHurdle"
+//             },
+//             {
+//                 menuName: '屠宰批次',
+//                 url: "slaughterBatch"
+//             },
+//             {
+//                 menuName: '品控检疫',
+//                 url: "reportQuarantine"
+//             },
+//             {
+//                 menuName: '入宰登记',
+//                 url: "regisSlaughter"
+//             },
+//             {
+//                 menuName: '屠宰分割', // 宰后称重
+//                 url: "slaughterWeight"
+//             },
+//             {
+//                 menuName: '入库管理',
+//                 url: "inStore"
+//             },
+//             {
+//                 menuName: '出仓管理',
+//                 url: "outStore"
+//             },
+//
+//             {
+//                 menuName: '分割加工',
+//                 url: "segmentation"
+//             },
+//             // {
+//             //     menuName: '排酸损耗',
+//             //     url: "drainageAcid"
+//             // },
+//             {
+//                 menuName: '分割批次',
+//                 url: "splitBatch"
+//             },
+//             // {
+//             //     menuName: '成本核算',
+//             //     url: "costAccounting"
+//             // }
+//         ]
+//     },
+//     {
+//         menuName: "销售管理",
+//         iconClassName: "el-icon-s-custom",
+//         disabled: false,
+//         children: [
+//             {
+//                 menuName: '客户管理',
+//                 url: "client"
+//             },
+//             {
+//                 menuName: '价格管理',
+//                 url: "price"
+//             },
+//             {
+//                 menuName: '销售统计',
+//                 url: "sellRegister"
+//             },
+//             {
+//                     menuName: '屠宰直销',
+//                 url: "directSell"
+//             },
+//             {
+//                 menuName: '胴体销售',
+//                 url: "carcassSell"
+//             },
+//             {
+//                 menuName: '分割销售',
+//                     url: "splitSell"
+//             },
+//             {
+//                 menuName: '其他销售',
+//                 url: "elseSell"
+//             },
+//         ]
+//     },
+//     {
+//         menuName: "产品制作智能监控",
+//         iconClassName: "el-icon-ice-cream-square",
+//         disabled: false,
+//         children: [
+//             {
+//                 menuName: '产品档案',
+//                 url: "productInfo"
+//             },
+//             {
+//                 menuName: '分割登记',
+//                 url: "splitLog"
+//             },
+//             {
+//                 menuName: '羊皮登记',
+//                 url: "sheepskinLog"
+//             },
+//             {
+//                 menuName: '羊血登记',
+//                 url: "goatBloodLog"
+//             },
+//             {
+//                 menuName: '羊杂登记',
+//                 url: "goatHasletLog"
+//             },
+//
+//         ]
+//     },
+//
+//     {
+//         menuName: "鲜肉储运智能管控",
+//         iconClassName: "el-icon-shopping-cart-1",
+//         disabled: false,
+//         children: [
+//             {
+//                 menuName: '配送管理',
+//                 url: "dispatching"
+//             },
+//             // {
+//             //     menuName: '运输管理',
+//             //     url: "transportation"
+//             // },
+//             // {
+//             //     menuName: '门店管理',
+//             //     url: "shopStore"
+//             // },
+//             {
+//                 menuName: '产品追溯',
+//                 url: "productQuery"
+//             },
+//         ]
+//     }
+// ]
+
+// export default {menuData}
+
+
+
+
+/* 菜单配置 描述 */
 const menuData描述 = [
     // 有子菜单 并且字菜单分组的
     {
         oneMenuName: "导航一", // 一级菜单名
         iconClassName: "aaa", // element-ui图标名
-        childList: [ // 分组的
+        children: [ // 分组的
             {
                 groupName: '组名一',
                 list: [
                     {
-                        optionName: '选项1',
-                        routerName: "home"
+                        menuName: '选项1',
+                        url: "home"
                     },
                     {}
                 ],
@@ -177,8 +389,8 @@ const menuData描述 = [
                 groupName: '组名二',
                 list: [
                     {
-                        optionName: '选项1',
-                        routerName: "home"
+                        menuName: '选项1',
+                        url: "home"
                     },
                     {}
                 ],
@@ -190,10 +402,10 @@ const menuData描述 = [
         oneMenuName: "导航二",
         iconClassName: "el-icon-menu",
         disabled: false, // 是否禁用
-        childList: [ // 不分组的
+        children: [ // 不分组的
             {
-                optionName: '选项1',
-                routerName: "home"
+                menuName: '选项1',
+                url: "home"
             },
             {}
         ]
@@ -202,7 +414,7 @@ const menuData描述 = [
     {
         oneMenuName: "导航三",
         iconClassName: "el-icon-document",
-        routerName: "home",
+        url: "home",
         disabled: false
     },
 

+ 11 - 10
src/views/Login/Login.vue

@@ -68,20 +68,21 @@ export default {
                 .then(res => {
                     loading.close();
                     localStorage.setItem("token", res.token);
-                    this.doOrganizationChoose();
+                    this.$router.replace ("/home/dashboard");
+                    // this.doOrganizationChoose();
                 })
                 .catch(err => {
                     console.log("登录失败", err);
                 });
-            this.$axios.post(`http://121.37.169.186:8081/my/login?accountName=${this.form.userName}&password=${this.form.userPwd}`)
-                    .then(res => {
-                        loading.close();
-                        if(res.data.code === 10000) {
-                            localStorage.setItem('accountName', res.data.accountName);
-                        } else {
-                            this.$message.error(res.data.message);
-                        }
-                    })
+            // this.$axios.post(`http://121.37.169.186:8081/my/login?accountName=${this.form.userName}&password=${this.form.userPwd}`)
+            //         .then(res => {
+            //             loading.close();
+            //             if(res.data.code === 10000) {
+            //                 localStorage.setItem('accountName', res.data.accountName);
+            //             } else {
+            //                 this.$message.error(res.data.message);
+            //             }
+            //         })
         },
         handleSet: function() {
             if (!this.orgSelected) {

+ 30 - 7
src/views/productManagement/goatBloodLog.vue

@@ -31,8 +31,8 @@
                     <el-table-column prop="storageLocation" label="存放位置"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -145,7 +145,14 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData = {
+                                        sheepId: "",
+                                        bleedingTime: this.$moment().format("YYYY-MM-DD"),
+                                        slaughterBatch: "",
+                                        weight: null,
+                                        shelfLife: "",
+                                        storageLocation: ""
+                                    };
                                     this.isShow = false
                                 }
                             })
@@ -159,7 +166,15 @@ export default {
                                 // 羊血登记列表
                                 this.getGoatBloodLogList();
                                 this.$message.success("编辑成功!");
-                                this.formData = {}
+                                this.formData = {
+                                    sheepId: "",
+                                    bleedingTime: this.$moment().format("YYYY-MM-DD"),
+                                    slaughterBatch: "",
+                                    weight: null,
+                                    shelfLife: "",
+                                    storageLocation: ""
+                                };
+                                this.formData.id = '';
                                 this.isShow = false
                             })
                             .catch(err => {
@@ -191,8 +206,16 @@ export default {
             this.isShow = true;
             this.isAdd = true;
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.sheepId = row.sheepId;
+            this.formData.bleedingTime = row.bleedingTime;
+            this.formData.slaughterBatch = row.slaughterBatch;
+            this.formData.weight = row.weight;
+            this.formData.shelfLife = row.shelfLife;
+            this.formData.storageLocation = row.storageLocation;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false;
         },
@@ -232,4 +255,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 31 - 8
src/views/productManagement/goatHasletLog.vue

@@ -31,8 +31,8 @@
                     <el-table-column prop="storageLocation" label="存放位置"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -140,7 +140,14 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData = {
+                                        sheepId: "",
+                                        slaughterTime: this.$moment().format("YYYY-MM-DD"),
+                                        slaughterBatch: "",
+                                        weight: null,
+                                        shelfLife: '',
+                                        storageLocation: ""
+                                    };
                                     this.isShow = false
                                 }
                             })
@@ -157,7 +164,15 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData = {
+                                        sheepId: "",
+                                        slaughterTime: this.$moment().format("YYYY-MM-DD"),
+                                        slaughterBatch: "",
+                                        weight: null,
+                                        shelfLife: '',
+                                        storageLocation: ""
+                                    };
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                                 // this.$message.success("编辑成功!");
@@ -172,7 +187,7 @@ export default {
                 }
             });
         },
-        // 羊杂登记列表 
+        // 羊杂登记列表
         getGoatHasletLogList() {
             reqGoatHasletLogList({
                 searchStr: this.search,
@@ -191,8 +206,16 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.sheepId = row.sheepId;
+            this.formData.slaughterTime = row.slaughterTime;
+            this.formData.slaughterBatch = row.slaughterBatch;
+            this.formData.weight = row.weight;
+            this.formData.shelfLife = row.shelfLife;
+            this.formData.storageLocation = row.storageLocation;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -232,4 +255,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 28 - 8
src/views/productManagement/productInfo.vue

@@ -30,8 +30,8 @@
                     <el-table-column prop="shelfLife" label="保质期(天)"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -130,7 +130,13 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData = {
+                                        code: "",
+                                        productName: "",
+                                        specificModel: "",
+                                        productPrice: null,
+                                        shelfLife: ''
+                                    }
                                     this.isShow = false
                                 }
                             })
@@ -148,7 +154,14 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData = {
+                                        code: "",
+                                        productName: "",
+                                        specificModel: "",
+                                        productPrice: null,
+                                        shelfLife: ''
+                                    };
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -162,7 +175,7 @@ export default {
                 }
             });
         },
-        // 产品档案列表 
+        // 产品档案列表
         getProductInfoList() {
             reqProductInfoList({
                 searchStr: this.search,
@@ -181,8 +194,15 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.code = row.code;
+            this.formData.productName = row.productName;
+            this.formData.specificModel = row.specificModel;
+            this.formData.productPrice = row.productPrice;
+            this.formData.shelfLife = row.shelfLife;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -222,4 +242,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 27 - 7
src/views/productManagement/sheepskinLog.vue

@@ -30,8 +30,8 @@
                     <el-table-column prop="location" label="位置"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -140,7 +140,13 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData = {
+                                        sheepId: "",
+                                        strippingTime: this.$moment().format("YYYY-MM-DD"),
+                                        slaughterBatch: "",
+                                        weight: null,
+                                        location: ""
+                                    };
                                     this.isShow = false
                                 }
                             })
@@ -154,7 +160,14 @@ export default {
                                 // 羊皮登记列表
                                 this.getSheepskinLogList();
                                 this.$message.success("编辑成功!");
-                                this.formData = {}
+                                this.formData = {
+                                    sheepId: "",
+                                    strippingTime: this.$moment().format("YYYY-MM-DD"),
+                                    slaughterBatch: "",
+                                    weight: null,
+                                    location: ""
+                                };
+                                this.formData.id = '';
                                 this.isShow = false
                             })
                             .catch(err => {
@@ -186,8 +199,15 @@ export default {
             this.isShow = true;
             this.isAdd = true;
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.sheepId = row.sheepId;
+            this.formData.strippingTime = row.strippingTime;
+            this.formData.slaughterBatch = row.slaughterBatch;
+            this.formData.weight = row.weight;
+            this.formData.location = row.location;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false;
         },
@@ -227,4 +247,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 30 - 8
src/views/sellManagement/carcassSell.vue

@@ -35,8 +35,8 @@
                     <el-table-column prop="transportNo" label="运输单号"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -155,7 +155,13 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.salesNo = '';
+                                    this.formData.sellingTime = '';
+                                    this.formData.carcassWeight = '';
+                                    this.formData.saleAmount = '';
+                                    this.formData.buyer = '';
+                                    this.formData.seller = '';
+                                    this.formData.transportNo = '';
                                     this.isShow = false
                                 }
                             })
@@ -173,7 +179,14 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.salesNo = '';
+                                    this.formData.sellingTime = '';
+                                    this.formData.carcassWeight = '';
+                                    this.formData.saleAmount = '';
+                                    this.formData.buyer = '';
+                                    this.formData.seller = '';
+                                    this.formData.transportNo = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -187,7 +200,7 @@ export default {
                 }
             });
         },
-        // 胴体销售列表 
+        // 胴体销售列表
         getCarcassList() {
             reqCarcassList({
                 searchStr: this.search,
@@ -206,8 +219,17 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.salesNo = row.salesNo;
+            this.formData.sellingTime = row.sellingTime;
+            this.formData.carcassWeight = row.carcassWeight;
+            this.formData.saleAmount = row.saleAmount;
+            this.formData.buyer = row.buyer;
+            this.formData.seller = row.seller;
+            this.formData.transportNo = row.transportNo;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -247,4 +269,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 24 - 8
src/views/sellManagement/client.vue

@@ -30,8 +30,8 @@
                     <el-table-column prop="remarks" label="备注"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -135,7 +135,11 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.company = '';
+                                    this.formData.customerName = '';
+                                    this.formData.contactInformation = '';
+                                    this.formData.address = '';
+                                    this.formData.remarks = '';
                                     this.isShow = false
                                 }
                             })
@@ -153,7 +157,12 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.company = '';
+                                    this.formData.customerName = '';
+                                    this.formData.contactInformation = '';
+                                    this.formData.address = '';
+                                    this.formData.remarks = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -167,7 +176,7 @@ export default {
                 }
             });
         },
-        // 客户管理列表 
+        // 客户管理列表
         getClientList() {
             reqClientList({
                 searchStr: this.search,
@@ -186,8 +195,15 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.company = row.company;
+            this.formData.customerName = row.customerName;
+            this.formData.contactInformation = row.contactInformation;
+            this.formData.address = row.address;
+            this.formData.remarks = row.remarks;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -227,4 +243,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 33 - 8
src/views/sellManagement/directSell.vue

@@ -32,8 +32,8 @@
                     <el-table-column prop="transportNo" label="运输单号"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -153,7 +153,14 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.saleTime = '';
+                                    this.formData.buyer = '';
+                                    this.formData.seller = '';
+                                    this.formData.weight = '';
+                                    this.formData.remarks = '';
+                                    this.formData.saleAmount = '';
+                                    this.formData.salesNo = '';
+                                    this.formData.transportNo = '';
                                     this.isShow = false
                                 }
                             })
@@ -171,7 +178,15 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.saleTime = '';
+                                    this.formData.buyer = '';
+                                    this.formData.seller = '';
+                                    this.formData.weight = '';
+                                    this.formData.remarks = '';
+                                    this.formData.saleAmount = '';
+                                    this.formData.salesNo = '';
+                                    this.formData.transportNo = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -185,7 +200,7 @@ export default {
                 }
             });
         },
-        // 屠宰直销列表 
+        // 屠宰直销列表
         getDirectSellList() {
             reqDirectSellList({
                 searchStr: this.search,
@@ -204,8 +219,18 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.saleTime = row.saleTime;
+            this.formData.buyer = row.buyer;
+            this.formData.seller = row.seller;
+            this.formData.weight = row.weight;
+            this.formData.remarks = row.remarks;
+            this.formData.saleAmount = row.saleAmount;
+            this.formData.salesNo = row.salesNo;
+            this.formData.transportNo = row.transportNo;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -245,4 +270,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 36 - 8
src/views/sellManagement/elseSell.vue

@@ -34,8 +34,8 @@
                     <el-table-column prop="seller" label="销售人(企业)"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -164,7 +164,15 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.productName = '';
+                                    this.formData.weight = '';
+                                    this.formData.slaughterBatch = '';
+                                    this.formData.saleAmount = '';
+                                    this.formData.salesTime = '';
+                                    this.formData.salesNo = '';
+                                    this.formData.buyer = '';
+                                    this.formData.seller = '';
+                                    this.formData.transportNo = '';
                                     this.isShow = false
                                 }
                             })
@@ -182,7 +190,16 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.productName = '';
+                                    this.formData.weight = '';
+                                    this.formData.slaughterBatch = '';
+                                    this.formData.saleAmount = '';
+                                    this.formData.salesTime = '';
+                                    this.formData.salesNo = '';
+                                    this.formData.buyer = '';
+                                    this.formData.seller = '';
+                                    this.formData.transportNo = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -196,7 +213,7 @@ export default {
                 }
             });
         },
-        // 其他销售列表 
+        // 其他销售列表
         getElseSellList() {
             reqElseSellList({
                 searchStr: this.search,
@@ -215,8 +232,19 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.productName = row.productName;
+            this.formData.weight = row.weight;
+            this.formData.slaughterBatch = row.slaughterBatch;
+            this.formData.saleAmount = row.saleAmount;
+            this.formData.salesTime = row.salesTime;
+            this.formData.salesNo = row.salesNo;
+            this.formData.buyer = row.buyer;
+            this.formData.seller = row.seller;
+            this.formData.transportNo = row.transportNo;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -256,4 +284,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 24 - 8
src/views/sellManagement/price.vue

@@ -30,8 +30,8 @@
                     <!-- <el-table-column prop="operation" label="操作"></el-table-column> -->
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -135,7 +135,11 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.productName = '';
+                                    this.formData.specificModel = '';
+                                    this.formData.category = '';
+                                    this.formData.price = '';
+                                    this.formData.operation = '';
                                     this.isShow = false
                                 }
                             })
@@ -153,7 +157,12 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.productName = '';
+                                    this.formData.specificModel = '';
+                                    this.formData.category = '';
+                                    this.formData.price = '';
+                                    this.formData.operation = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -167,7 +176,7 @@ export default {
                 }
             });
         },
-        // 价格管理列表 
+        // 价格管理列表
         getPriceList() {
             reqPriceList({
                 searchStr: this.search,
@@ -186,8 +195,15 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.productName = row.productName;
+            this.formData.specificModel = row.specificModel;
+            this.formData.category = row.category;
+            this.formData.price = row.price;
+            this.formData.operation = row.operation;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -227,4 +243,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 33 - 8
src/views/sellManagement/splitSell.vue

@@ -33,8 +33,8 @@
                     <el-table-column prop="transportNo" label="运输单号"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -163,7 +163,14 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.salesNo = '';
+                                    this.formData.productNames = '';
+                                    this.formData.productQuantities = '';
+                                    this.formData.salesTime = '';
+                                    this.formData.totalAmount = '';
+                                    this.formData.buyer = '';
+                                    this.formData.seller = '';
+                                    this.formData.transportNo = '';
                                     this.isShow = false
                                 }
                             })
@@ -181,8 +188,16 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
-                                    this.isShow = false
+                                    this.formData.salesNo = '';
+                                    this.formData.productNames = '';
+                                    this.formData.productQuantities = '';
+                                    this.formData.salesTime = '';
+                                    this.formData.totalAmount = '';
+                                    this.formData.buyer = '';
+                                    this.formData.seller = '';
+                                    this.formData.transportNo = '';
+                                    this.formData.id = '';
+                                    this.isShow = false;
                                 }
                             })
                             .catch(err => {
@@ -214,8 +229,18 @@ export default {
             this.isShow = true;
             this.isAdd = true;
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.salesNo = row.salesNo;
+            this.formData.productNames = row.productNames;
+            this.formData.productQuantities = row.productQuantities;
+            this.formData.salesTime = row.salesTime;
+            this.formData.totalAmount = row.totalAmount;
+            this.formData.buyer = row.buyer;
+            this.formData.seller = row.seller;
+            this.formData.transportNo = row.transportNo;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false;
         },
@@ -255,4 +280,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 2 - 2
src/views/slaughterManagment/drainageAcid.vue

@@ -33,7 +33,7 @@
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
                             <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -265,4 +265,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 27 - 8
src/views/slaughterManagment/firmBuy.vue

@@ -30,8 +30,8 @@
                     <el-table-column prop="transportVehicles" label="运输车辆"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -143,7 +143,12 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.acquisitionPerson = '';
+                                    this.formData.acquisitionTime = '';
+                                    this.formData.acquisitionWeight = '';
+                                    this.formData.origin = '';
+                                    this.formData.sheepId = '';
+                                    this.formData.transportVehicles = '';
                                     this.isShow = false
                                 }
                             })
@@ -160,7 +165,13 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.acquisitionPerson = '';
+                                    this.formData.acquisitionTime = '';
+                                    this.formData.acquisitionWeight = '';
+                                    this.formData.origin = '';
+                                    this.formData.sheepId = '';
+                                    this.formData.transportVehicles = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -189,13 +200,21 @@ export default {
                     console.log(err);
                 });
         },
-        
+
         add() {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.acquisitionPerson = row.acquisitionPerson;
+            this.formData.acquisitionTime = row.acquisitionTime;
+            this.formData.acquisitionWeight = row.acquisitionWeight;
+            this.formData.origin = row.origin;
+            this.formData.sheepId = row.sheepId;
+            this.formData.transportVehicles = row.transportVehicles;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -231,4 +250,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 20 - 7
src/views/slaughterManagment/inButcherHurdle.vue

@@ -29,8 +29,8 @@
                     <el-table-column prop="operator" label="操作人员"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -133,7 +133,10 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.currentPosition = '';
+                                    this.formData.entryTime = '';
+                                    this.formData.operation = '';
+                                    this.formData.sheepId = '';
                                     this.isShow = false
                                 }
                             })
@@ -150,7 +153,11 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.currentPosition = '';
+                                    this.formData.entryTime = '';
+                                    this.formData.operation = '';
+                                    this.formData.sheepId = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -184,8 +191,14 @@ export default {
             this.isShow = true;
             this.isAdd = true;
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.currentPosition = row.currentPosition;
+            this.formData.entryTime = row.entryTime;
+            this.formData.operator = row.operator;
+            this.formData.sheepId = row.sheepId;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false;
         },
@@ -225,4 +238,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 31 - 8
src/views/slaughterManagment/inStore.vue

@@ -32,8 +32,8 @@
                     <el-table-column prop="slaughterBatch" label="屠宰批次"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -158,7 +158,13 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.carcassCode = '';
+                                    this.formData.storageTime = '';
+                                    this.formData.storageLocation = '';
+                                    this.formData.slaughterTime = '';
+                                    this.formData.storageWeight = '';
+                                    this.formData.operator = '';
+                                    this.formData.slaughterBatch = '';
                                     this.isShow = false
                                 }
                             })
@@ -176,7 +182,15 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.$message.success("成功");
+                                    this.formData.carcassCode = '';
+                                    this.formData.storageTime = '';
+                                    this.formData.storageLocation = '';
+                                    this.formData.slaughterTime = '';
+                                    this.formData.storageWeight = '';
+                                    this.formData.operator = '';
+                                    this.formData.slaughterBatch = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -190,7 +204,7 @@ export default {
                 }
             });
         },
-        // 入库管理列表 
+        // 入库管理列表
         getInStoreList() {
             reqInStoreList({
                 searchStr: this.search,
@@ -209,8 +223,17 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.carcassCode = row.carcassCode;
+            this.formData.storageTime = row.storageTime;
+            this.formData.storageLocation = row.storageLocation;
+            this.formData.slaughterTime = row.slaughterTime;
+            this.formData.storageWeight = row.storageWeight;
+            this.formData.operator = row.operator;
+            this.formData.slaughterBatch = row.slaughterBatch;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -250,4 +273,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 26 - 7
src/views/slaughterManagment/outStore.vue

@@ -40,8 +40,8 @@
                     <el-table-column prop="slaughterBatch" label="屠宰批次"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -161,7 +161,12 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.carcassCode = '';
+                                    this.formData.deliveryTime = '';
+                                    this.formData.flowTo = '';
+                                    this.formData.deliveryWeight = '';
+                                    this.formData.operator = '';
+                                    this.formData.slaughterBatch = '';
                                     this.isShow = false
                                 }
                             })
@@ -179,7 +184,13 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.carcassCode = '';
+                                    this.formData.deliveryTime = '';
+                                    this.formData.flowTo = '';
+                                    this.formData.deliveryWeight = '';
+                                    this.formData.operator = '';
+                                    this.formData.slaughterBatch = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -212,8 +223,16 @@ export default {
             this.isShow = true;
             this.isAdd = true;
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.carcassCode = row.carcassCode;
+            this.formData.deliveryTime = row.deliveryTime;
+            this.formData.flowTo = row.flowTo;
+            this.formData.deliveryWeight = row.deliveryWeight;
+            this.formData.operator = row.operator;
+            this.formData.slaughterBatch = row.slaughterBatch;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false;
         },
@@ -253,4 +272,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 3 - 3
src/views/slaughterManagment/packinghouse.vue

@@ -31,7 +31,7 @@
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
                             <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -172,7 +172,7 @@ export default {
                 }
             });
         },
-        // 入宰登记列表 
+        // 入宰登记列表
         getWaitList() {
             reqWaitList({
                 searchStr: this.search,
@@ -232,4 +232,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 26 - 7
src/views/slaughterManagment/regisSlaughter.vue

@@ -31,8 +31,8 @@
                     <el-table-column prop="quarantineNo" label="检疫单编号"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -145,7 +145,12 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.sheepId = '';
+                                    this.formData.registrationTime = '';
+                                    this.formData.slaughterBatch = '';
+                                    this.formData.entryWeight = '';
+                                    this.formData.operator = '';
+                                    this.formData.quarantineNo = '';
                                     this.isShow = false
                                 }
                             })
@@ -162,7 +167,13 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.sheepId = '';
+                                    this.formData.registrationTime = '';
+                                    this.formData.slaughterBatch = '';
+                                    this.formData.entryWeight = '';
+                                    this.formData.operator = '';
+                                    this.formData.quarantineNo = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -195,8 +206,16 @@ export default {
             this.isShow = true;
             this.isAdd = true;
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.sheepId = row.sheepId;
+            this.formData.registrationTime = row.registrationTime;
+            this.formData.slaughterBatch = row.slaughterBatch;
+            this.formData.entryWeight = row.entryWeight;
+            this.formData.operator = row.operator;
+            this.formData.quarantineNo = row.quarantineNo;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false;
         },
@@ -235,4 +254,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 24 - 8
src/views/slaughterManagment/reportQuarantine.vue

@@ -34,8 +34,8 @@
                     <el-table-column prop="slaughterBatch" label="屠宰批次"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -153,7 +153,11 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.inspectionDate = '';
+                                    this.formData.inspectionPerson = '';
+                                    this.formData.status = '';
+                                    this.formData.quarantineNo = '';
+                                    this.formData.slaughterBatch = '';
                                     this.isShow = false
                                 }
                             })
@@ -170,7 +174,12 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.inspectionDate = '';
+                                    this.formData.inspectionPerson = '';
+                                    this.formData.status = '';
+                                    this.formData.quarantineNo = '';
+                                    this.formData.slaughterBatch = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -184,7 +193,7 @@ export default {
                 }
             });
         },
-        // 上报检疫列表 
+        // 上报检疫列表
         getReportList() {
             reqReportList({
                 searchStr: this.search,
@@ -203,8 +212,15 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.inspectionDate = row.inspectionDate;
+            this.formData.inspectionPerson = row.inspectionPerson;
+            this.formData.status = row.status;
+            this.formData.quarantineNo = row.quarantineNo;
+            this.formData.slaughterBatch = row.slaughterBatch;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -244,4 +260,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 24 - 8
src/views/slaughterManagment/segmentation.vue

@@ -30,8 +30,8 @@
                     <el-table-column prop="operator" label="确认人"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -140,7 +140,11 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.carcassCode = '';
+                                    this.formData.splitBatch = '';
+                                    this.formData.processingTime = '';
+                                    this.formData.weight = '';
+                                    this.formData.operator = '';
                                     this.isShow = false
                                 }
                             })
@@ -158,7 +162,12 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.carcassCode = '';
+                                    this.formData.splitBatch = '';
+                                    this.formData.processingTime = '';
+                                    this.formData.weight = '';
+                                    this.formData.operator = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -172,7 +181,7 @@ export default {
                 }
             });
         },
-        // 分割加工列表 
+        // 分割加工列表
         getSegmentationList() {
             reqSegmentationList({
                 searchStr: this.search,
@@ -191,8 +200,15 @@ export default {
             this.isShow = true;
             this.isAdd = true
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.carcassCode = row.carcassCode;
+            this.formData.splitBatch = row.splitBatch;
+            this.formData.processingTime = row.processingTime;
+            this.formData.weight = row.weight;
+            this.formData.operator = row.operator;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false
         },
@@ -232,4 +248,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 29 - 7
src/views/slaughterManagment/slaughterWeight.vue

@@ -41,8 +41,8 @@
                     </el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -172,7 +172,13 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.carcassCode = '';
+                                    this.formData.slaughterBatch = '';
+                                    this.formData.slaughterTime = '';
+                                    this.formData.weighingTime = '';
+                                    this.formData.flowTo = '';
+                                    this.formData.carcassWeight = '';
+                                    this.formData.operator = '';
                                     this.isShow = false
                                 }
                             })
@@ -190,7 +196,14 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.carcassCode = '';
+                                    this.formData.slaughterBatch = '';
+                                    this.formData.slaughterTime = '';
+                                    this.formData.weighingTime = '';
+                                    this.formData.flowTo = '';
+                                    this.formData.carcassWeight = '';
+                                    this.formData.operator = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -223,8 +236,17 @@ export default {
             this.isShow = true;
             this.isAdd = true;
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.carcassCode = row.carcassCode;
+            this.formData.slaughterBatch = row.slaughterBatch;
+            this.formData.slaughterTime = row.slaughterTime;
+            this.formData.weighingTime = row.weighingTime;
+            this.formData.flowTo = row.flowTo;
+            this.formData.carcassWeight = row.carcassWeight;
+            this.formData.operator = row.operator;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false;
         },
@@ -264,4 +286,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 17 - 10
src/views/slaughterManagment/splitBatch.vue

@@ -30,8 +30,8 @@
                     <el-table-column prop="weight" label="重量(kg)"></el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -68,7 +68,7 @@
                         label-width="140px"
                     >
                         <el-form-item label="胴体编码">
-                            <el-input v-model="formData.carcassCode"></el-input>
+                            <el-input v-model="formData.carcassCode" :disabled="!isAdd"></el-input>
                         </el-form-item>
 
                         <el-form-item label="重量">
@@ -124,8 +124,8 @@ export default {
             totalPages: 0,
             isShow: false,
             formData: {
-                carcassCode: "1006",
-                weight: "32"
+                carcassCode: "",
+                weight: ""
             },
             getRowKeys(row) {
                 return row.id;
@@ -155,7 +155,8 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.carcassCode = '';
+                                    this.formData.weight = '';
                                     this.isShow = false
                                 }
                             })
@@ -173,7 +174,9 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData.carcassCode = '';
+                                    this.formData.weight = '';
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -219,8 +222,12 @@ export default {
             this.isShow = true;
             this.isAdd = true;
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.carcassCode = row.carcassCode;
+            this.formData.weight = row.weight;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false;
         },
@@ -281,4 +288,4 @@ export default {
 #header {
     margin-bottom: 15px;
 }
-</style>
+</style>

+ 45 - 8
src/views/storeTransportation/dispatching.vue

@@ -40,8 +40,8 @@
                     </el-table-column>
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
-                            <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-button @click="edit(scope.row, true)" type="text" size="small">编辑</el-button>
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -97,6 +97,13 @@
                             <el-input v-model="formData.tel"></el-input>
                         </el-form-item>
 
+                        <el-form-item label="配送状态">
+                            <el-radio-group v-model="formData.status">
+                                <el-radio :label="0">配送中</el-radio>
+                                <el-radio :label="1">配送完成</el-radio>
+                            </el-radio-group>
+                        </el-form-item>
+
                         <el-form-item>
                             <el-button @click="isShow=false">取 消</el-button>
                             <el-button type="primary" @click="submitForm('addDispatch')">保 存</el-button>
@@ -136,7 +143,8 @@ export default {
                 weight: null,
                 distributor: '',
                 transportVehicles: '',
-                tel: ''
+                tel: '',
+                status: 0
             },
             isAdd: false,
             rules
@@ -160,7 +168,16 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData = {
+                                        salesNo: "",
+                                        deliveryCustomer: "",
+                                        deliveryAddress: "",
+                                        transportNo: '',
+                                        weight: null,
+                                        distributor: '',
+                                        transportVehicles: '',
+                                        tel: ''
+                                    };
                                     this.isShow = false
                                 }
                             })
@@ -178,7 +195,17 @@ export default {
                                     this.$message.error(res.errMsg);
                                 } else {
                                     this.$message.success("成功");
-                                    this.formData = {}
+                                    this.formData = {
+                                        salesNo: "",
+                                        deliveryCustomer: "",
+                                        deliveryAddress: "",
+                                        transportNo: '',
+                                        weight: null,
+                                        distributor: '',
+                                        transportVehicles: '',
+                                        tel: ''
+                                    };
+                                    this.formData.id = '';
                                     this.isShow = false
                                 }
                             })
@@ -211,8 +238,18 @@ export default {
             this.isShow = true;
             this.isAdd = true;
         },
-        edit(row) {
-            this.formData = row;
+        edit(row, bool) {
+            this.formData.salesNo = row.salesNo;
+            this.formData.deliveryCustomer = row.deliveryCustomer;
+            this.formData.deliveryAddress = row.deliveryAddress;
+            this.formData.transportNo = row.transportNo;
+            this.formData.weight = row.weight;
+            this.formData.transportVehicles = row.transportVehicles;
+            this.formData.distributor = row.distributor;
+            this.formData.tel = row.tel;
+            if(bool) {
+                this.formData.id = row.id;
+            }
             this.isShow = true;
             this.isAdd = false;
         },
@@ -252,4 +289,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>

+ 2 - 2
src/views/storeTransportation/shopStore.vue

@@ -31,7 +31,7 @@
                     <el-table-column label="操作" width="150">
                         <template slot-scope="scope">
                             <el-button @click="edit(scope.row)" type="text" size="small">编辑</el-button>
-                            <el-popconfirm title="是否删除此设备的信息?" @onConfirm="del(scope.row)">
+                            <el-popconfirm title="是否删除此设备的信息?" @confirm="del(scope.row)">
                                 <el-button slot="reference" type="text" size="small">删除</el-button>
                             </el-popconfirm>
                         </template>
@@ -227,4 +227,4 @@ export default {
         margin-top: 20px;
     }
 }
-</style>
+</style>