Browse Source

Merge branch 'master' of git.echepei.com:zhujiawei/Warehouse_management_ui

wengyuwen 4 years ago
parent
commit
c4823ddea6
3 changed files with 98 additions and 30 deletions
  1. 9 0
      src/api/index.js
  2. 74 23
      src/views/index.vue
  3. 15 7
      src/views/warehouseBusiness/goodsTransfer/index.vue

+ 9 - 0
src/api/index.js

@@ -22,3 +22,12 @@ export function warehouse(){
     method:'get'
   })
 }
+
+//查询待办事宜
+export function inquiry(data){
+  return request({
+    url:'/warehouse/paths/selectAllAuditItems',
+    method:'post',
+    data:data
+  })
+}

+ 74 - 23
src/views/index.vue

@@ -79,19 +79,39 @@
       <el-table :data="tableData" :header-cell-style="{borderBottom:'1px dashed #dfe6ec'}" :cell-style="cellStyle"
                 style="width: 67.5%;float: left;"
       >
-        <el-table-column prop="name" label="待办事宜">
+        <el-table-column prop="refno1" :show-overflow-tooltip="true" label="委托方"></el-table-column>
+        <el-table-column prop="auditItem" :show-overflow-tooltip="true" label="日期">
+          <template slot-scope="scope">
+            <span>{{ scope.row.auditItem.slice(0,10) }}</span>
+          </template>
+        </el-table-column>
+        <el-table-column prop="refno3" :show-overflow-tooltip="true" label="提单号"></el-table-column>
+        <el-table-column prop="refno2" :show-overflow-tooltip="true" label="业务类型">
+          <template slot-scope="scope">
+            <span v-if="scope.row.refno2 === 'SJRK'">入库</span>
+            <span v-else-if="scope.row.refno2 === 'SJCK'">出库</span>
+            <span v-else-if="scope.row.refno2 === 'HQZY'">货转</span>
+            <span v-else-if="scope.row.refno2 === 'CKDB'">调拨</span>
+            <span v-else-if="scope.row.refno2 === 'CCF'">仓储费</span>
+            <span v-else-if="scope.row.refno2 === 'ZYF'">作业费</span>
+            <span v-else-if="scope.row.refno2 === 'SF'">收费</span>
+            <span v-else-if="scope.row.refno2 === 'DZ'">对账</span>
+            <span v-else-if="scope.row.refno2 === 'FF'">付费</span>
+          </template>
+        </el-table-column>
+        <el-table-column prop="address" label="操作" width="80">
+          <template slot-scope="scope">
+            <span style="cursor:pointer" @click="approval(scope.row)">查看详情</span>
+          </template>
         </el-table-column>
-        <el-table-column prop="date" label="时间"></el-table-column>
-        <el-table-column prop="address" label="操作" width="80"></el-table-column>
       </el-table>
       <el-table :data="tableDataTwo" :header-cell-style="{borderBottom:'1px dashed #dfe6ec'}" :cell-style="cellStyle"
                 style="width: 30%;float: right;margin-left: 20px;"
       >
         <el-table-column prop="noticeTitle" :show-overflow-tooltip="true" label="消息中心"/>
         <el-table-column prop="address" label="操作" width="80">
-          <span @click="bug()" style="cursor:pointer">查看详情</span>
           <template slot-scope="scope">
-            <span @click="bug(scope.row.noticeContent)" style="cursor:pointer">查看详情</span>
+            <span @click="querytoDo(scope.row.noticeContent)" style="cursor:pointer">查看详情</span>
           </template>
         </el-table-column>
       </el-table>
@@ -124,7 +144,7 @@
 </template>
 
 <script>
-import { listCorps, information, warehouse } from '../../src/api/index'
+import { listCorps, information, warehouse ,inquiry} from '../../src/api/index'
 import AddOrUpdate from '@/views/viewApproval'
 import ApprovalComments from '@/views/startApproval'
 export default {
@@ -139,19 +159,7 @@ export default {
       dialogVisible: false,
       addOrUpdateVisible: false,
       addOrUpdateVisib: false,
-      tableData: [{
-        date: '2020-11-20 12:00',
-        name: '某客户账单审核',
-        address: '查看详情'
-      }, {
-        date: '2020-11-20 12:00',
-        name: '某客户账单审核',
-        address: '查看详情'
-      }, {
-        date: '2020-11-20 12:00',
-        name: '仓储费审核结算审核',
-        address: '查看详情'
-      }],
+      tableData: [],
       chart: [],
       warehouse: [],
       master: [],
@@ -165,15 +173,58 @@ export default {
     AddOrUpdate,
     ApprovalComments
   },
-  mounted() {
-
-  },
   created() {
     this.getList()
     this.warehouses()
     this.firstinventory()
+    this.inquiry()
   },
   methods: {
+    //跳转审批页面
+    approval(row){
+      switch (row.refno2){
+        case 'SJRK':{
+          this.$router.push({ path: '/finance/contrast',query:{data:row}})
+          break
+        }
+        case 'SJCK':{
+          break
+        }
+        case 'HQZY':{
+          break
+        }
+        case 'CKDB':{
+          break
+        }
+        case 'CCF':{
+          break
+        }
+        case 'ZYF':{
+          break
+        }
+        case 'SF':{
+          break
+        }
+        case 'DZ':{
+          break
+        }
+        case 'FF':{
+          break
+        }
+        default:{
+          return this.$message.error('未知错误,无状态')
+        }
+      }
+    },
+    inquiry(){
+      let data = {
+        actId: ''
+      }
+      inquiry(data).then( res =>{
+        console.log(res)
+        this.tableData = res.data
+      })
+    },
     getDataList(){
       this.addOrUpdateVisible = false
     },
@@ -196,7 +247,7 @@ export default {
         this.$refs.ApprovalComments.init(id,actId)
       })
     },
-    bug(res) {
+    querytoDo(res) {
       this.dialogVisible = true
       this.text = res
     },

+ 15 - 7
src/views/warehouseBusiness/goodsTransfer/index.vue

@@ -294,10 +294,10 @@
             size="mini"
             type="text"
             icon="el-icon-edit"
-            v-if="scope.row.fBillstatus > 3 && scope.row.fBillstatus < 6"
+            v-if="scope.row.fBillstatus === 4 || scope.row.fBillstatus === 5"
             @click="handleUpdate(scope.row, false)"
             v-hasPermi="['warehouseBusiness:goodsTransfer:edit']"
-          >查看审批
+          >审批进度
           </el-button>
           <el-button
             size="mini"
@@ -356,6 +356,7 @@
                 remote
                 :disabled="browseStatus || formBrowseStatus"
                 style="width: 80%"
+                @change="changefCorpid(form)"
                 :remote-method="corpsRemoteMethod"
                 placeholder="请选择新货权方"
               >
@@ -1019,7 +1020,7 @@
               v-model="scope.row.fQty"
               placeholder="数量"
               :disabled="browseStatus"
-              @change="changeEstmateAmt(scope.row)"
+              @change="changeContractAmt(scope.row)"
               show-word-limit
             />
           </template>
@@ -2112,9 +2113,9 @@
           }
         })
       },
-      // 撤回入账
+      // 撤回货转
       withdrawClick() {
-        // 撤回入库
+        // 撤回货转
         let formData = new window.FormData()
         let withdrawList = JSON.parse(JSON.stringify(this.dataWithdrawList))
         formData.append('warehousebillsitems', JSON.stringify(withdrawList))
@@ -2408,12 +2409,19 @@
         }else if (row.fFeeunitid === 5) {
           this.$set(row, 'fQty', fixed)
         }
-
-        console.log(fQty+',,,' + fGrossweight+',,,' + fNetweight+',,,' + volumn+',,,' + fixed)
         if (row.fUnitprice) {
           this.$set(row, 'fAmount', parseFloat(Number(row.fUnitprice) * Number(row.fQty)).toFixed(2))
         }
       },
+      // 选择新货权方自动带出结算方式
+      changefCorpid(row) {
+        this.$set(row, "fSbu", row.fCorpid);
+        for (let corp in this.fMblnoOptions) {
+          if (row.fTocorpid === this.fMblnoOptions[corp].fId) {
+            this.$set(this.form, "fStltypeid", this.fMblnoOptions[corp].fStltypeid + '');
+          }
+        }
+      },
       /* 远程模糊查询用户 */
       corpsRemoteMethod(name) {
         if (name == null || name === '') {