Explorar o código

Merge branch 'feature/Feature-basic_data' of https://gogs.zfire.top/zfire-front/supply-front into feature/Feature-basic_data

chen %!s(int64=3) %!d(string=hai) anos
pai
achega
8103acfd60

+ 1 - 1
src/components/Common/print-foshan.vue

@@ -52,7 +52,7 @@
               <el-col :span="3">{{ item.refundableQty || 0 }}</el-col>
             </el-row>
             <el-row :gutter="20">
-              <el-col :span="4">{{ item.invoiceId || '' }}</el-col>
+              <el-col :span="4">{{ item.mainOrderId || '' }}</el-col>
               <el-col :span="2">发货日期</el-col>
               <el-col :span="4">{{ item.theTime || '' }}</el-col>
               <el-col :span="2">工程编号</el-col>

+ 338 - 0
src/components/Common/print-guangzhou.vue

@@ -0,0 +1,338 @@
+<template>
+  <div class="detail-container">
+    <div class="print-page" v-for="(item, index) in showData" :key="index">
+      <div class="print-title">
+        <div class="title1">广州盛世欣兴格力贸易有限公司销售发货单</div>
+        <div class="title2">{{ item.informationKey }}</div>
+      </div>
+      <div class="print-form-2">
+        <el-row :gutter="0">
+          <el-col :span="16" class="item">
+            <div class="label">客户名称</div>
+            <div class="value">
+              <el-input v-model="item.customerName" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="8" class="item">
+            <div class="label">发货日期</div>
+            <div class="value">
+              <el-input v-model="nowDate" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="16" class="item">
+            <div class="label">发货单号</div>
+            <div class="value">
+              <el-input v-model="item.id" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="8" class="item">
+            <div class="label">订单号</div>
+            <div class="value">
+              <el-input v-model="item.aaa" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="16" class="item">
+            <div class="label">使用单位</div>
+            <div class="value">
+              <el-input v-model="item.aaa" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="8" class="item">
+            <div class="label">合同号</div>
+            <div class="value">
+              <el-input v-model="item.aaa" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="24" class="item">
+            <div class="label">提货人资料</div>
+            <div class="value">
+              <el-input v-model="item.takerName" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="24" class="item">
+            <div class="label">备注</div>
+            <div class="value">
+              <el-input v-model="item.remark" readonly></el-input>
+            </div>
+          </el-col>
+        </el-row>
+      </div>
+
+      <div class="print-table-1">
+        <div class="head">
+          <el-row :gutter="20">
+            <el-col :span="2">仓库名称</el-col>
+            <el-col :span="2">销售类型</el-col>
+            <el-col :span="3">存货名称</el-col>
+            <el-col :span="6">规格型号</el-col>
+            <el-col :span="2">数量</el-col>
+            <el-col :span="2">含税单价</el-col>
+            <el-col :span="2">价税合计</el-col>
+            <el-col :span="2">折扣价</el-col>
+            <el-col :span="3">说明</el-col>
+          </el-row>
+        </div>
+        <div class="body">
+          <div v-for="(item, index) in item.invoicePickBeans" :key="index">
+            <el-row :gutter="20">
+              <el-col :span="2">{{ item.correspondName }}</el-col>
+              <el-col :span="2">{{ item.saleTypeName }}</el-col>
+              <el-col :span="3">{{ item.materialName }}</el-col>
+              <el-col :span="6">{{ item.specification }}</el-col>
+              <el-col :span="2">{{ item.refundableQty }}</el-col>
+              <el-col :span="2">{{ item.price }}</el-col>
+              <el-col :span="2">{{ item.payAmount }}</el-col>
+              <el-col :span="2">{{ item.totalDiscAmount }}</el-col>
+              <el-col :span="3">{{ item.remark }}</el-col>
+            </el-row>
+          </div>
+        </div>
+        <div class="foot">
+          <el-row :gutter="20">
+            <el-col :span="2">合计</el-col>
+            <el-col :span="2"></el-col>
+            <el-col :span="3"></el-col>
+            <el-col :span="6"></el-col>
+            <el-col :span="2">{{ item.total_num }}</el-col>
+            <el-col :span="2"></el-col>
+            <el-col :span="2">{{ item.total_amount }}</el-col>
+            <el-col :span="2">{{ item.total_discount }}</el-col>
+            <el-col :span="3"></el-col>
+          </el-row>
+        </div>
+      </div>
+
+      <div class="print-form-2">
+        <el-row :gutter="30">
+          <el-col :span="5" class="item">
+            <div class="label">制表</div>
+            <div class="value">
+              <el-input v-model="item.createBy" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="5" class="item">
+            <div class="label">审核</div>
+            <div class="value">
+              <el-input v-model="item.createBy" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="5" class="item">
+            <div class="label">珠海格力办</div>
+            <div class="value">
+              <el-input value="赵玲玲" readonly></el-input>
+            </div>
+          </el-col>
+          <el-col :span="5" class="item">
+            <div class="label">仓库签章</div>
+            <div class="value">
+              <el-input v-model="item.userName" readonly></el-input>
+            </div>
+          </el-col>
+        </el-row>
+      </div>
+
+      <div class="print-text">
+        <div>仓租费:自开单日起5天内免费,逾期15天内收取0.3%/天,超过15天及以上按0.4%/天。</div>
+        <div>
+          <span style="width: 58px"></span>
+          <span>此单过期</span>
+          <el-input readonly></el-input>
+          <span>天,在后期费用中扣除</span>
+          <el-input readonly></el-input>
+          <span>元。</span>
+        </div>
+      </div>
+
+    </div>
+
+  </div>
+</template>
+
+<script>
+
+export default {
+  name: 'PrintFoshan',
+  props: {
+    detailData: {
+      type: Object,
+      default: null
+    }
+  },
+
+  computed: {
+    showData() {
+      var showData = [];
+      if(this.detailData && this.detailData.invoicePickBeans) {
+        for(var i=0; i<this.detailData.invoicePickBeans.length; i+=5){
+          let obj = JSON.parse(JSON.stringify(this.detailData));
+          obj.userName = JSON.parse(localStorage.getItem("supply_user")).nickName;
+          obj.invoicePickBeans = this.detailData.invoicePickBeans.slice(i, i+5);
+          obj.total_num = 0;
+          obj.total_price = 0;
+          obj.total_amount = 0;
+          obj.total_discount = 0;
+          obj.invoicePickBeans.forEach(item => {
+            obj.total_num = obj.total_num + item.refundableQty;
+            obj.total_price = obj.total_price + item.price;
+            obj.total_amount = obj.total_amount + item.payAmount;
+            obj.total_discount = obj.total_discount + item.totalDiscAmount;
+          });
+          for(var j=0; j<5; j++){
+            if(!obj.invoicePickBeans[j]) {
+              obj.invoicePickBeans[j] = {};
+            }
+          }
+          showData.push(obj);
+        }
+      }
+      console.log(showData);
+      return showData;
+    },
+    
+    nowDate() {
+      var date = new Date();
+      var seperator1 = "-";
+      var year = date.getFullYear();
+      var month = date.getMonth() + 1;
+      var strDate = date.getDate();
+      if (month >= 1 && month <= 9) {
+          month = "0" + month;
+      }
+      if (strDate >= 0 && strDate <= 9) {
+          strDate = "0" + strDate;
+      }
+      var currentdate = year + seperator1 + month + seperator1 + strDate;
+      return currentdate;
+    },
+  },
+
+  methods: {
+
+  }
+}
+</script>
+
+<style scoped lang="scss">
+  .detail-container {
+    width: 100%;
+    height: 100%;
+  }
+  .print-page {
+    margin-bottom: 50px;
+    // min-height: 1020px;
+    page-break-after: always;
+  }
+  .print-title {
+    .title1 {
+      font-size: 24px;
+      margin-bottom: 10px;
+      text-align: center;
+    }
+    .title2 {
+      font-size: 18px;
+      margin-bottom: 20px;
+      text-align: right;
+      margin-right: 100px;
+    }
+  }
+  .print-table-1 {
+    font-size: 14px;
+    margin-top: 10px;
+    margin-bottom: 10px;
+    .el-row {
+      margin-left: 0 !important;
+      margin-right: 0 !important;
+      border: 1px solid #EBEEF5;
+      border-right: none;
+    }
+    .el-col {
+      padding-top: 14px;
+      padding-bottom: 14px;
+      border-right: 1px solid #EBEEF5;
+    }
+    .head {
+      color: #909399;
+      font-weight: bold;
+      .el-col {
+        padding: 0;
+        display: flex;
+        height: 40px;
+        align-items: center;
+      }
+    }
+    .body {
+      color: #333333;
+      .el-row {
+        border-top: none;
+      }
+      .el-col {
+        padding: 0;
+        display: flex;
+        height: 40px;
+        align-items: center;
+        word-break: break-all;
+      }
+    }
+    .foot {
+      color: #333333;
+      .el-row {
+        border-top: none;
+      }
+      .el-col {
+        padding: 0;
+        display: flex;
+        height: 40px;
+        align-items: center;
+        word-break: break-all;
+      }
+    }
+  }
+
+  .print-form-2 {
+    .item {
+      display: flex;
+      padding-right: 10px;
+      .label {
+        height: 32px;
+        display: flex;
+        align-items: center;
+        box-sizing: border-box;
+        font-size: 14px;
+        color: #333333;
+        flex-shrink: 0;
+      }
+      .value {
+        flex: 1;
+        height: 32px;
+        display: flex;
+        align-items: center;
+        box-sizing: border-box;
+        font-size: 14px;
+        color: #333333;
+        ::v-deep .el-input input {
+          height: 30px;
+          border: none;
+          border-bottom: 1px solid #EBEEF5;
+          padding: 0 10px;
+        }
+      }
+    }
+  }
+
+  .print-text {
+    font-size: 14px;
+    &>div {
+      display: flex;
+      margin-top: 10px;
+    }
+    ::v-deep .el-input {
+      width: 50px;
+      input {
+        height: 30px;
+        border: none;
+        padding: 0 10px;
+      }
+    } 
+  }
+
+</style>

+ 9 - 20
src/layout/components/Sidebar/SidebarItem.vue

@@ -1,23 +1,8 @@
 <template>
   <div v-if="!item.hidden">
     <!-- <template v-if="hasOneShowingChild(item.children,item) && (!onlyOneChild.children||onlyOneChild.noShowingChildren) && !item.alwaysShow"> -->
-    <template 
-      v-if="hasOneShowingChild(item.children,item) && 
-        (
-          !onlyOneChild.children ||
-          onlyOneChild.noShowingChildren || 
-          (
-            onlyOneChild.children && 
-            onlyOneChild.children.length < 1 && 
-            (
-              onlyOneChild.name == 'issue_index' || 
-              onlyOneChild.name == 'notice_index' || 
-              onlyOneChild.name == 'dashboard'
-            )
-          )
-        ) && 
-        !item.alwaysShow">
-      <app-link v-if="onlyOneChild.meta" :to="resolvePath(onlyOneChild.path)">
+    <template v-if="hasOneShowingChild(item.children,item) && (!onlyOneChild.children||onlyOneChild.noShowingChildren || (onlyOneChild.children && onlyOneChild.children.length < 1 && (onlyOneChild.name == 'issue_index' || onlyOneChild.name == 'notice_index' || onlyOneChild.name == 'dashboard'))) && !item.alwaysShow">
+      <app-link v-if="onlyOneChild.meta" :to="resolvePath(onlyOneChild.path ,onlyOneChild)">
         <el-menu-item :index="resolvePath(onlyOneChild.path)" :class="{'submenu-title-noDropdown':!isNest}">
           <item :icon="onlyOneChild.meta.icon||(item.meta&&item.meta.icon)" :title="onlyOneChild.meta.title" />
         </el-menu-item>
@@ -28,6 +13,7 @@
       <template slot="title">
         <item v-if="item.meta" :icon="item.meta && item.meta.icon" :title="item.meta.title" />
       </template>
+
       <sidebar-item
         v-for="child in item.children"
         :key="child.path"
@@ -36,6 +22,7 @@
         :base-path="resolvePath(child.path)"
         class="nest-menu"
       />
+
     </el-submenu>
   </div>
 </template>
@@ -79,12 +66,12 @@ export default {
           return false
         } else {
           // Temp set(will be used if only has one showing child)
-          
+
           // 删除空的children
           if(item.children.length < 1) {
             // delete item['children']
           }
-          
+
           this.onlyOneChild = item
 
           // console.log(item);
@@ -102,16 +89,18 @@ export default {
         this.onlyOneChild = { ... parent, path: '', noShowingChildren: true }
         return true
       }
-
       return false
     },
     resolvePath(routePath) {
+
       if (isExternal(routePath)) {
         return routePath
       }
       if (isExternal(this.basePath)) {
         return this.basePath
       }
+
+
       return path.resolve(this.basePath, routePath)
     }
   }

+ 2 - 2
src/layout/components/Sidebar/index.vue

@@ -38,12 +38,12 @@ export default {
     activeMenu() {
       const route = this.$route
       console.log(route);
-      const { meta, path } = route
+      const { meta, path ,fullUrl} = route
       // if set path, the sidebar will highlight the path you set
       if (meta.activeMenu) {
         return meta.activeMenu
       }
-      return path
+      return fullUrl
     },
     showLogo() {
       return this.$store.state.settings.sidebarLogo

+ 42 - 21
src/permission.js

@@ -45,7 +45,9 @@ router.beforeEach(async (to, from, next) => {
 
           // 设置路由
           var newRoutes = [];
+
           for (var route of store.getters.menus) {
+
             const item = buildRootRoute(route);
             newRoutes.push(item);
           }
@@ -111,25 +113,26 @@ router.afterEach(() => {
 });
 
 // 遍历后台传来的路由字符串,转换为组件对象
-function filterAsyncRouter(asyncRouterMap) {
-  const accessedRouters = asyncRouterMap.filter((route) => {
-    console.log(route);
-    if (route.component) {
-      if (route.component === "Layout") {
-        route.component = Layout;
-      } else {
-        route.component = _import(route.component); // 导入组件
-      }
-    }
-    if (route.children && route.children.length) {
-      route.children = filterAsyncRouter(route.children);
-    }
-    return true;
-  });
-  return accessedRouters;
-}
+// function filterAsyncRouter(asyncRouterMap) {
+//   const accessedRouters = asyncRouterMap.filter((route) => {
+//     console.log(route);
+//     if (route.component) {
+//       if (route.component === "Layout") {
+//         route.component = Layout;
+//       } else {
+//         route.component = _import(route.component); // 导入组件
+//       }
+//     }
+//     if (route.children && route.children.length) {
+//       route.children = filterAsyncRouter(route.children);
+//     }
+//     return true;
+//   });
+//   return accessedRouters;
+// }
 
 function buildRootRoute(route) {
+  // console.log(route,1111);
   const { url, icon, moduleName, moduleId, code, type } = route;
   var item = {};
   item.path = url;
@@ -183,7 +186,9 @@ function buildRootRoute(route) {
     code == "notice" ||
     code == "index"
   ) {
+
     for (var child of route.children) {
+
       item.children.push(buildRoute(child, url));
     }
   }
@@ -191,7 +196,8 @@ function buildRootRoute(route) {
 }
 
 function buildRoute(route, p_url) {
-  const { url, moduleName, icon, moduleId, code, type, hidden } = route;
+  // console.log(route,2222);
+  const { url, moduleName, icon, moduleId, code, type, hidden,fullUrl } = route;
   var item = {};
   if (url.substr(0, 1) == "/") {
     item.path = url.substr(1);
@@ -204,7 +210,14 @@ function buildRoute(route, p_url) {
       item.component = (resolve) =>
         require(["@/views" + `${url}/index`], resolve);
     } else {
-      item.component = _import(`${p_url}${url}`);
+
+      if (fullUrl) {
+        item.component = _import(`${fullUrl}`);
+      }else{
+        item.component = _import(`${p_url}${url}`);
+
+      }
+
     }
   } catch (e) {
     console.log(e);
@@ -232,15 +245,23 @@ function buildRoute(route, p_url) {
 }
 
 function buildThirdRoute(route, p_url) {
-  const { url, moduleName, icon, moduleId, code, hidden, type } = route;
+
+  const { url, moduleName, icon, moduleId, code, hidden, type ,fullUrl } = route;
+  // console.log(fullUrl,'7878');
   var item = {};
   if (url.substr(0, 1) == "/") {
+    // console.log(url.substr(1),p_url,url);
     item.path = url.substr(1);
   } else {
     tem.path = url;
   }
   try {
-    item.component = _import(`${p_url}${url}`);
+    if (fullUrl) {
+      item.component = _import(`${fullUrl}`);
+    }else{
+      item.component = _import(`${p_url}${url}`);
+    }
+
   } catch (e) {
     console.log(e);
   }

+ 5 - 0
src/views/basic_data/stock.vue

@@ -0,0 +1,5 @@
+<template>
+  <div>
+    <router-view />
+  </div>
+</template>

+ 0 - 0
src/views/basic_data/stock/index.vue


+ 5 - 0
src/views/finance/cash.vue

@@ -0,0 +1,5 @@
+<template>
+  <div>
+    <router-view />
+  </div>
+</template>

+ 0 - 0
src/views/finance/cash/index.vue


+ 5 - 0
src/views/finance/details.vue

@@ -0,0 +1,5 @@
+<template>
+  <div>
+    <router-view />
+  </div>
+</template>

+ 0 - 0
src/views/finance/details/index.vue


+ 5 - 0
src/views/finance/rebate.vue

@@ -0,0 +1,5 @@
+<template>
+  <div>
+    <router-view />
+  </div>
+</template>

+ 0 - 0
src/views/finance/rebate/index.vue


+ 5 - 0
src/views/sales/price.vue

@@ -0,0 +1,5 @@
+<template>
+  <div>
+    <router-view />
+  </div>
+</template>

+ 0 - 0
src/views/sales/price/index.vue


+ 5 - 0
src/views/sales/sales_policy.vue

@@ -0,0 +1,5 @@
+<template>
+  <div>
+    <router-view />
+  </div>
+</template>

+ 0 - 0
src/views/sales/sales_policy/index.vue


+ 5 - 0
src/views/sales/sales_rebate.vue

@@ -0,0 +1,5 @@
+<template>
+  <div>
+    <router-view />
+  </div>
+</template>

+ 0 - 0
src/views/sales/sales_rebate/index.vue


+ 20 - 4
src/views/setting/menu.vue

@@ -49,6 +49,9 @@
         <el-form-item label="URL" prop="url">
           <el-input placeholder="请输入URL" v-model="addParentForm.url"></el-input>
         </el-form-item>
+        <el-form-item label="全URL" prop="fullUrl">
+          <el-input placeholder="请输入全URL" v-model="addParentForm.fullUrl" :disabled="!isAdmin"></el-input>
+        </el-form-item>
         <el-form-item label="图标" prop="icon">
           <div class="iconInput">
             <div class="icon" v-if="addParentForm.icon"><i :class="addParentForm.icon"></i></div>
@@ -91,6 +94,9 @@
         <el-form-item label="URL" prop="url">
           <el-input placeholder="请输入URL" v-model="addChildForm.url"></el-input>
         </el-form-item>
+        <el-form-item label="全URL" prop="fullUrl">
+          <el-input placeholder="请输入全URL" v-model="addChildForm.fullUrl" :disabled="!isAdmin"></el-input>
+        </el-form-item>
         <el-form-item label="图标" prop="icon">
           <div class="iconInput">
             <div class="icon" v-if="addChildForm.icon"><i :class="addChildForm.icon"></i></div>
@@ -124,7 +130,6 @@
 import { mapGetters } from 'vuex'
 import { getToken } from '@/utils/auth'
 import { getMenuList, addMenu, editMenu, deleteMenu, getMenuDetail } from '@/api/setting'
-import { findElem } from '@/utils/util.js';
 
 export default {
   data() {
@@ -145,6 +150,7 @@ export default {
         oneMenu: '',
         code: '',
         url: '',
+        fullUrl: '',
         icon: '',
         sort: 0,
       },
@@ -171,6 +177,7 @@ export default {
         twoMenu: '',
         code: '',
         url: '',
+        fullUrl: '',
         icon: '',
         sort: 0,
       },
@@ -508,7 +515,11 @@ export default {
     ...mapGetters([
       'userid', 
       'name'
-    ])
+    ]),
+    isAdmin() {
+      let type = JSON.parse(localStorage.getItem("supply_user")).type;
+      return type === 2;
+    }
   },
   created() {
     this.getList();
@@ -542,6 +553,7 @@ export default {
             oneMenu: res.data.moduleName,
             code: res.data.code,
             url: res.data.url,
+            fullUrl: res.data.fullUrl,
             icon: res.data.icon,
             sort: res.data.sortNum
           }
@@ -563,6 +575,7 @@ export default {
             moduleName: this.addParentForm.oneMenu,
             code: this.addParentForm.code,
             url: this.addParentForm.url,
+            fullUrl: this.addParentForm.fullUrl,
             icon: this.addParentForm.icon,
             sortNum: this.addParentForm.sort,
             parentId: 0,
@@ -575,7 +588,7 @@ export default {
               this.$successMsg('编辑成功');
             })
           }else {
-            params.type = 2;
+            // params.type = 2;
             addMenu(params).then(res => {
               this.cancelAddParentForm();
               this.getList();
@@ -603,6 +616,7 @@ export default {
             twoMenu: res.data.moduleName,
             code: res.data.code,
             url: res.data.url,
+            fullUrl: res.data.fullUrl,
             icon: res.data.icon,
             sort: res.data.sortNum
           }
@@ -634,6 +648,7 @@ export default {
               moduleName: this.addChildForm.twoMenu,
               code: this.addChildForm.code,
               url: this.addChildForm.url,
+              fullUrl: this.addChildForm.fullUrl,
               icon: this.addChildForm.icon,
               sortNum: this.addChildForm.sort
             }
@@ -648,9 +663,10 @@ export default {
               moduleName: this.addChildForm.twoMenu,
               code: this.addChildForm.code,
               url: this.addChildForm.url,
+              fullUrl: this.addChildForm.fullUrl,
               icon: this.addChildForm.icon,
               sortNum: this.addChildForm.sort,
-              type: 2
+              // type: 2
             }
             addMenu(params).then(res => {
               this.cancelAddChildForm();

+ 7 - 2
src/views/supply/apply/components/apply_form.vue

@@ -128,6 +128,11 @@
               <el-input v-model="screenForm.orderNum" placeholder="请输入订单号"></el-input>
             </el-form-item>
           </el-col>
+          <el-col :xs="12" :sm="6" :lg="6">
+            <el-form-item prop="type" label="存货类别">
+              <el-input v-model="screenForm.type" placeholder="请输入存货类别"></el-input>
+            </el-form-item>
+          </el-col>
           <el-col :xs="12" :sm="6" :lg="6" class="tr">
             <el-form-item label="">
               <el-button size="small" @click="resetScreenForm">清空</el-button>
@@ -222,7 +227,7 @@ export default {
       isShowDialog: false,
       screenForm: {
         warehouse: [],
-        // type: '',
+        type: '',
         orderNum: '',
       },
       currentPage: 1,
@@ -324,7 +329,7 @@ export default {
         pageNum: this.currentPage,
         pageSize: 10,
         correspondId: this.screenForm.warehouse,
-        // mainId: this.screenForm.type,
+        categoryName: this.screenForm.type,
         id: this.screenForm.orderNum,
       }).then(res => {
         let oldGoodsList = this.goodsList;

+ 10 - 3
src/views/supply/apply/components/engin_form.vue

@@ -199,12 +199,17 @@
           </el-col>
           <el-col :xs="12" :sm="12" :lg="6">
             <el-form-item prop="warehouse" label="选择仓库">
-              <el-select v-model="screenForm.warehouse" placeholder="请选择仓库" size="small" filterable clearable :disabled="goodsList.length > 0 || tableSelection.length > 0">
+              <el-select v-model="screenForm.warehouse" placeholder="请选择仓库" size="small" filterable clearable :disabled="goodsList.length > 0 || tableSelection.length > 0" style="width: 100%">
                 <el-option :label="item.name" :value="item.id" v-for="(item, index) in warehouseList" :key="index"></el-option>
               </el-select>
             </el-form-item>
           </el-col>
-          <el-col :xs="12" :sm="12" :lg="18" class="tr">
+          <el-col :xs="12" :sm="6" :lg="6">
+            <el-form-item prop="type" label="存货类别">
+              <el-input v-model="screenForm.type" placeholder="请输入存货类别"></el-input>
+            </el-form-item>
+          </el-col>
+          <el-col :xs="12" :sm="12" :lg="12" class="tr">
             <el-form-item label="">
               <el-button size="small" @click="resetScreenForm">清空</el-button>
               <el-button size="small" type="primary" @click="submitScreenForm">搜索</el-button>
@@ -244,7 +249,7 @@
           </el-table-column>
           <el-table-column align="center" label="对应库存数量" prop="stockCorrespond" min-width="110" show-overflow-tooltip>
             <template slot-scope="scope">
-              {{stockFilter(scope.row, 1)}}
+              {{stockFilter(scope.row, 2)}}
             </template>
           </el-table-column>
         </el-table>
@@ -334,6 +339,7 @@ export default {
         model: '',
         date: '',
         warehouse: '',
+        type: '',
       },
       currentPage: 1,
       listTotal: 0,
@@ -478,6 +484,7 @@ export default {
         startTime: this.screenForm.date ? this.screenForm.date[0] : '',
         endTime: this.screenForm.date ? this.screenForm.date[1] : '',
         correspondId: this.screenForm.warehouse,
+        categoryName: this.screenForm.type,
       }).then(res => {
         let oldGoodsList = this.goodsList;
         let newGoodsList = res.data.records;

+ 1 - 19
src/views/supply/deliver/commerce_list.vue

@@ -92,7 +92,7 @@
             <el-table-column align="center" label="发货单号" prop="id" min-width="180" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="发货日期" prop="orderTime" min-width="160" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="仓库" prop="correspondName" min-width="160" show-overflow-tooltip></el-table-column>
-            <el-table-column align="center" label="工程登录编码" prop="enginOrderNo" min-width="160" show-overflow-tooltip></el-table-column>
+            <el-table-column align="center" label="工程登录编码" prop="enginOrderNo" min-width="200" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="工程名称" prop="refProjectName" min-width="160" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="使用单位" prop="refUseUnit" min-width="160" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="经销商编码" prop="customerNumber" min-width="100" show-overflow-tooltip></el-table-column>
@@ -111,11 +111,6 @@
             <el-table-column align="center" label="制单日期" prop="createTime" min-width="160" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="审单人" prop="approvalName" min-width="100" show-overflow-tooltip></el-table-column>
             <el-table-column align="center" label="审单日期" prop="approvalTime" min-width="160" show-overflow-tooltip></el-table-column>
-            <el-table-column align="center" label="状态" prop="examineStatus" min-width="100" show-overflow-tooltip>
-              <template slot-scope="scope">
-                {{scope.row.examineStatus | statusFilter}}
-              </template>
-            </el-table-column>
             <el-table-column align="center" label="操作" width="200" fixed="right">
               <template slot-scope="scope">
                 <el-button type="text" @click="toDetail(scope.row)">详情</el-button>
@@ -188,12 +183,6 @@ export default {
   components: {
     CommerceDetail,
   },
-  filters: {
-    statusFilter(val) {
-      let obj = that.statusList.find(o => o.value == val);
-      return obj ? obj.label : ''
-    },
-  },
   data() {
     return {
       currentPage: 1, // 当前页码
@@ -213,13 +202,6 @@ export default {
         jxsNum: '',
         status: '',
       },
-      statusList: [
-        { label: '已保存', value: 'SAVE' },
-        { label: '待审核', value: 'WAIT' },
-        { label: '审核通过', value: 'OK' },
-        { label: '审核驳回', value: 'FAIL' },
-        { label: '已关闭', value: 'CLOSE' },
-      ],
 
       isShowDialog: false, // 密码记录 - 弹窗
       dialogTable_dataList: null, // 密码记录 - 列表数据

+ 0 - 18
src/views/supply/deliver/home_list.vue

@@ -102,11 +102,6 @@
               </template>
             </el-table-column>
             <el-table-column align="center" label="备注信息" prop="remark" min-width="160" show-overflow-tooltip></el-table-column>
-            <el-table-column align="center" label="状态" prop="examineStatus" min-width="100" show-overflow-tooltip>
-              <template slot-scope="scope">
-                {{scope.row.examineStatus | statusFilter}}
-              </template>
-            </el-table-column>
             <el-table-column align="center" label="操作" width="200" fixed="right">
               <template slot-scope="scope">
                 <el-button type="text" @click="toDetail(scope.row)">详情</el-button>
@@ -179,12 +174,6 @@ export default {
   components: {
     HomeDetail,
   },
-  filters: {
-    statusFilter(val) {
-      let obj = that.statusList.find(o => o.value == val);
-      return obj ? obj.label : ''
-    },
-  },
   data() {
     return {
       currentPage: 1, // 当前页码
@@ -203,13 +192,6 @@ export default {
         jxsNum: '',
         status: '',
       },
-      statusList: [
-        { label: '已保存', value: 'SAVE' },
-        { label: '待审核', value: 'WAIT' },
-        { label: '审核通过', value: 'OK' },
-        { label: '审核驳回', value: 'FAIL' },
-        { label: '已关闭', value: 'CLOSE' },
-      ],
 
       isShowDialog: false, // 密码记录 - 弹窗
       dialogTable_dataList: null, // 密码记录 - 列表数据

+ 8 - 0
src/views/supply/engin/components/commerce_form.vue

@@ -664,6 +664,14 @@ export default {
               this.$errorMsg('请选择现金钱包');
               return;
             }
+            if(!this.goodsList[i].qty) {
+              this.$errorMsg('请输入数量');
+              return;
+            }
+            if(this.goodsList[i].qty > this.goodsList[i].enginNum) {
+              this.$errorMsg('数量不能大于工程信息数量');
+              return;
+            }
           }
 
           let goodsList = JSON.parse(JSON.stringify(this.goodsList));

+ 4 - 0
src/views/supply/pickup/check.vue

@@ -276,6 +276,10 @@ export default {
 
     // 查询列表
     getList() {
+      if(!this.screenForm.manId) {
+        return this.$errorMsg('请先查询提货人信息');
+      }
+
       this.listLoading = true;
 
       let params = {

+ 4 - 1
src/views/supply/pickup/components/pickup_print.vue

@@ -9,6 +9,7 @@
     <div id="printMe">
       
       <PrintFoshan :detailData="detailData" v-if="currentType === 1" />
+      <PrintGuangzhou :detailData="detailData" v-if="currentType === 2" />
 
     </div>
     
@@ -26,13 +27,15 @@
 import print from 'vue-print-nb'
 import { getDetail, addPrint } from "@/api/supply/pickup";
 import PrintFoshan from "@/components/Common/print-foshan";
+import PrintGuangzhou from "@/components/Common/print-guangzhou";
 
 export default {
   name: 'ReturnDetail',
   componentName: 'ReturnDetail',
   props: ['listItem'],
   components: {
-    PrintFoshan
+    PrintFoshan,
+    PrintGuangzhou,
   },
   directives: {
     print

+ 17 - 11
src/views/supply/policy/components/retail_form2.vue

@@ -354,7 +354,7 @@
               @click="(dialogVisible = true), (cid = scope.row.id)"
               >修改</el-button
             > -->
-            <el-button type="text" @click="deleteItem(scope.$index)"
+            <el-button type="text" @click="deleteItem(scope.$index,scope.row.id)"
               >删除</el-button
             >
           </template>
@@ -1092,10 +1092,7 @@ export default {
       }).then((res) => {
         for (let i = 0; i < res.data.records.length; i++) {
           res.data.records[i].qty = 1;
-
-
             for (let j = 0; j < this.newDataList.length; j++) {
-
                 if (this.newDataList[j].id == res.data.records[i].id) {
                      res.data.records[i].disabled = false;
                 }
@@ -1110,7 +1107,10 @@ export default {
 
     handleShow() {
       this.isShowDialog = true;
-      this.getPolicyList();
+      if (!this.goodsList.length) {
+          this.getPolicyList();
+      }
+
     },
     // 获取钱包列表
     getWalletList() {
@@ -1284,13 +1284,20 @@ export default {
       this.radio = "";
       this.dataList = [];
       this.popDataArr = [];
-      this.screenForm.policyId = "";
-      this.screenForm.saleTypeCode = "";
+      // this.screenForm.policyId = "";
+      // this.screenForm.saleTypeCode = "";
     },
     // 删除产品
-    deleteItem(index) {
+    deleteItem(index,id) {
       this.goodsList.splice(index, 1);
-      console.log(this.multipleData);
+      // this.dataList
+      if (this.newDataList.length) {
+         this.newDataList.splice(index, 1);
+      }
+      if (!this.goodsList.length) {
+          this.disabled = false
+      }
+
       // this.popDataArr.splice(index,1)
     },
     // 修改返利钱包
@@ -1350,8 +1357,7 @@ export default {
           //   ].dictValue;
           let params = {
             theTime: this.mainForm.date,
-            mainId: this.mainForm.type,
-            mainName: "",
+
             remark: this.mainForm.remark,
             type: 2, // 1:普通零售单,2:政策零售单
             retailOrderItemList: this.goodsList,

+ 1 - 1
src/views/supply/sales/sales_list.vue

@@ -75,7 +75,7 @@
       <div class="mymain-container">
         <div class="btn-group clearfix">
           <div class="fl">
-            <el-button size="small" type="warning" icon="el-icon-finished" @click="batchExamine" :disabled="multipleSelection.length < 1">批量审批</el-button>
+            <el-button size="small" type="warning" icon="el-icon-finished" @click="batchExamine" :disabled="multipleSelection.length < 1" v-if="$checkBtnRole('examine', $route.meta.roles)">批量审批</el-button>
           </div>
           <div class="fr">
             <ExportButton :exUrl="'sale/order/export'" :exParams="exParams" />