Browse Source

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

caojunjie 4 years ago
parent
commit
5201472e45
2 changed files with 26 additions and 177 deletions
  1. 10 1
      src/api/finance/contrast.js
  2. 16 176
      src/views/finance/contrast/index.vue

+ 10 - 1
src/api/finance/contrast.js

@@ -8,7 +8,7 @@ export function listFee(query) {
     params: query
   })
 }
- 
+
 // 查询财务数据主详细
 export function getFee(fId) {
   return request({
@@ -90,3 +90,12 @@ export function backFee(TWareHouseFees) {
     data: TWareHouseFees
   })
 }
+
+//撤销审批
+export function RevocationApproval(data){
+  return request({
+    url:'/warehouse/paths/revoke',
+    method:'post',
+    data:data
+  })
+}

+ 16 - 176
src/views/finance/contrast/index.vue

@@ -19,13 +19,6 @@
           :remote-method="corpsRemoteMethod"
           />
 
-          <!-- <el-option
-            v-for="(dict, index) in fMblnoOptions"
-            :key="index.fId"
-            :label="dict.fName"
-            :value="dict.fId"
-          ></el-option>
-        </el-select> -->
       </el-form-item>
 
       <el-form-item label="结算单位" prop="fCorpid">
@@ -48,46 +41,6 @@
         </el-select>
       </el-form-item>
 
-<!--      <el-form-item label="录入人" prop="createBy">-->
-<!--        <el-input-->
-<!--          v-model="queryParams_s.createBy"-->
-<!--          size="small"-->
-<!--          disabled-->
-<!--        />-->
-<!--      </el-form-item>-->
-
-      <!-- <el-form-item label="提单号" prop="tMblno">
-        <el-input
-          v-model="queryParams.tMblno"
-          placeholder="请输入提单号"
-          clearable
-          size="small"
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>-->
-      <!-- <el-form-item label="应收合计" prop="fAmtdr">
-        <el-input
-          v-model="queryParams.fAmtdr"
-          placeholder="请输入应收合计"
-          clearable
-          size="small"
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item> -->
-      <!-- <el-form-item label="应付合计" prop="fAmtcr">
-        <el-input
-          v-model="queryParams.fAmtcr"
-          placeholder="请输入应付合计"
-          clearable
-          size="small"
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item> -->
-      <!-- <el-form-item label="单据类型" prop="fBilltype">
-        <el-select v-model="queryParams.fBilltype" placeholder="请选择单据类型" clearable size="small">
-          <el-option label="请选择字典生成" value="" />
-        </el-select>
-      </el-form-item> -->
 
       <el-form-item label="对账日期" prop="dateRange">
         <el-date-picker
@@ -102,27 +55,6 @@
         ></el-date-picker>
       </el-form-item>
 
-<!--      <el-form-item label="状态" prop="fBillstatus">-->
-<!--        <el-select v-model="queryParams_s.fBillstatus" placeholder="请选择">-->
-<!--          <el-option-->
-<!--            -->
-<!--            v-for="item in options"-->
-<!--            :key="item.value"-->
-<!--            :label="item.dictLabel"-->
-<!--            :value="item.dictValue"-->
-<!--          >-->
-<!--          </el-option>-->
-<!--        </el-select>-->
-<!--      </el-form-item>-->
-      <!-- <el-form-item label="备注" prop="fRemarks">
-        <el-input
-          v-model="queryParams.fRemarks"
-          placeholder="请输入备注"
-          clearable
-          size="small"
-          @keyup.enter.native="handleQuery"
-        />
-      </el-form-item>-->
       <el-form-item label="系统编号" prop="fBillno">
         <el-input
           v-model="tablefilter.fBillno"
@@ -133,9 +65,6 @@
         />
       </el-form-item>
 
-      <!-- <el-form-item label="制单部门" prop="fDeptid">
-        <el-input label="请选择字典生成" value="" v-model="queryParams.fDeptid" placeholder="请选择制单部门" clearable size="small"/>
-      </el-form-item> -->
       <el-form-item>
         <el-button
           type="cyan"
@@ -349,15 +278,6 @@
           </el-date-picker>
         </el-form-item>
 
-        <!-- <el-form-item label="单据日期">
-        <el-date-picker
-          v-model="value4"
-          size="small"
-          style="width: 240px"
-          value-format="yyyy-MM-dd"
-          type="date">
-        </el-date-picker>
-      </el-form-item> -->
 
         <el-form-item label="系统编号" prop="fBillno">
           <el-input
@@ -395,8 +315,6 @@
         :data="DzfeeList"
         @selection-change="handleSelectionChange_s"
       >
-        <!-- <el-table-column type="selection" width="55" align="center" /> -->
-        <!-- <el-table-column label="制单部门" align="center" prop="fId" /> -->
         <el-table-column label="行号" align="center" type="index" />
         <el-table-column label="提单号" align="center" prop="fMblno" />
         <el-table-column label="业务日期" align="center" prop="fBsdate">
@@ -462,9 +380,6 @@
           label-width="80px"
           :inline="true"
         >
-          <!-- <el-form-item label="业务编号" prop="fBillno">
-          <el-input v-model="form.fBillno" placeholder="请输入业务编号" />
-        </el-form-item> -->
 
           <el-form-item
             label="货权方"
@@ -658,41 +573,6 @@
             </el-table-column>
           </el-table>
 
-          <!-- <el-form-item label="应收合计" prop="fAmtdr">
-          <el-input v-model="form.fAmtdr" placeholder="请输入应收合计" />
-        </el-form-item>
-        <el-form-item label="应付合计" prop="fAmtcr">
-          <el-input v-model="form.fAmtcr" placeholder="请输入应付合计" />
-        </el-form-item>
-        <el-form-item label="单据类型" prop="fBilltype">
-          <el-select v-model="form.fBilltype" placeholder="请选择单据类型">
-            <el-option label="请选择字典生成" value="" />
-          </el-select>
-        </el-form-item>
-        <el-form-item label="状态">
-          <el-radio-group v-model="form.fBillstatus">
-            <el-radio label="1">请选择字典生成</el-radio>
-          </el-radio-group>
-        </el-form-item>
-        <el-form-item label="备注" prop="fRemarks">
-          <el-input v-model="form.fRemarks" placeholder="请输入备注" />
-        </el-form-item>
-        <el-form-item label="账单日期" prop="fAccbilldate">
-          <el-date-picker clearable size="small" style="width: 200px"
-                          v-model="form.fAccbilldate"
-                          type="date"
-                          value-format="yyyy-MM-dd"
-                          placeholder="选择账单日期">
-          </el-date-picker>
-        </el-form-item>
-        <el-form-item label="删除状态" prop="delFlag">
-          <el-input v-model="form.delFlag" placeholder="请输入删除状态" />
-        </el-form-item>
-        <el-form-item label="制单部门" prop="fDeptid">
-          <el-select v-model="form.fDeptid" placeholder="请选择制单部门">
-            <el-option label="请选择字典生成" value="" />
-          </el-select>
-        </el-form-item> -->
         </el-form>
         <div slot="footer" class="dialog-footer">
           <el-button type="primary" @click="confirmImport">确 定</el-button>
@@ -751,7 +631,7 @@
 </template>
 
 <script>
-import { backFee, detailFee, Cfee, listFee, getFee, delFee, addFee, updateFee, exportFee, importFee} from "@/api/finance/contrast";
+import { RevocationApproval, backFee, detailFee, Cfee, listFee, getFee, delFee, addFee, updateFee, exportFee, importFee} from "@/api/finance/contrast";
 import { listCorps } from '@/api/basicdata/corps'
 import { listFees } from '@/api/basicdata/fees'
 import AddOrUpdate from '@/views/viewApproval'
@@ -781,10 +661,6 @@ export default {
       notChange:false,
       browseStatus:false,
       options:'',
-      value1:"",
-      value2:"",
-      value3:"",
-      value4:"",
       dateRange:"",
       // 遮罩层
       loading: true,
@@ -811,7 +687,7 @@ export default {
       selection: '',
       // 弹出层标题
       title: "",
-      //  操作人
+      // 操作人
       Operator:'',
       // 是否显示弹出层
       open: false,
@@ -920,8 +796,20 @@ export default {
     this.register()
   },
   methods: {
+    // 撤销审批
     backApproval(){
-
+      let data = {
+        id:this.queryParams.fId,
+        actId:this.contrastId,
+        billId:this.queryParams.fId
+      }
+      RevocationApproval(data).then(response => {
+        console.log(response)
+        this.msgSuccess("撤销审批成功")
+        this.disappear = true
+        this.open = false
+        this.getList()
+      })
     },
     returnData(){
       this.addOrUpdateVisib = false
@@ -936,8 +824,6 @@ export default {
       let id = '448'
       let actId = '110'
       this.$nextTick(() => {
-        console.log(this.queryParams.fId)
-        console.log(this.contrastId)
         this.$refs.ApprovalComments.init(this.queryParams.fId,this.contrastId)
       })
     },
@@ -947,7 +833,6 @@ export default {
       this.addOrUpdateVisib = false
       let id = '448'
       let actId = '110'
-      console.log(this.queryParams.fId)
       this.$nextTick(() => {
         this.$refs.addOrUpdate.init(this.queryParams.fId,this.contrastId)
       })
@@ -960,7 +845,6 @@ export default {
         formDate.append("tFeeDo", JSON.stringify(this.DzfeeList))
 
         backFee(formDate).then(response=>{
-          console.log(response)
           this.msgSuccess("撤回成功")
 
         })
@@ -979,11 +863,9 @@ export default {
     },
     // 确认打印
     printSomething() {
-      console.log("22222");
       // 此处的style即为打印时的样式
       const style ='table tr td,th { border-collapse: collapse;padding:15px;border:.5px #000 solid;text-align:center;}'
         // "@media print {} }";
-
       print({
         printable: "print_area2",
         type: "html",
@@ -1004,7 +886,6 @@ export default {
             formDate.append("tFeeDo", JSON.stringify(this.DzfeeList))
 
             Cfee(formDate).then(response=>{
-            console.log(response)
             this.open = false
             this.msgSuccess("操作成功")
             this.getList()
@@ -1018,8 +899,6 @@ export default {
     // 对账按钮功能
     reconciliation(){
       this.TWareHouseFees.fToCorpid = this.queryParams.fCorpid
-      console.log(this.TWareHouseFees)
-      console.log(this.queryParams.fCorpid)
       this.innerVisible = true
     },
     // 默认录入人
@@ -1077,13 +956,10 @@ export default {
     // },
     // 导入搜索
     searchFee() {
-      console.log(this.TWareHouseFees)
       // this.feeList = []
       this.$refs['feeListRules'].validate(valid => {
-        console.log(valid)
         if (valid){
           importFee(this.TWareHouseFees).then(response =>{
-          console.log(response)
           this.feeList = response.rows
          })
         }
@@ -1102,7 +978,6 @@ export default {
         this.options = response.data
       });
       listFee(this.tableFilter).then(response => {
-        console.log(response)
         this.contrastList = response.rows
         this.total = response.total
         this.loading = false
@@ -1141,10 +1016,8 @@ export default {
     },
     /** 搜索按钮操作 */
     handleQuery() {
-      console.log(this.queryParams_s)
       this.queryParams.pageNum = 1;
       this.getList();
-      console.log(this.contrastList)
       // this.searchFee()
     },
     /** 重置按钮操作 */
@@ -1166,7 +1039,6 @@ export default {
           fAccbilldate: null,
           fDeptid: null,
       }
-      console.log(this.queryParams_s)
       this.queryParams_s = {
         pageNum: 1,
         pageSize: 10,
@@ -1183,7 +1055,6 @@ export default {
         fAccbilldate: null,
         fDeptid: null
       }
-      console.log(this.queryParams_s)
       this.handleQuery();
       this.TWareHouseFees={
         fCorpid:'',
@@ -1301,14 +1172,10 @@ export default {
         this.open = true;
         this.disappear = true
         this.title = "修改财务数据主";
-        console.log(this.Operator)
-        console.log(this.Lander)
         if (res == 1) {
           this.notChange = true
-          console.log(this.notChange)
           if (this.Operator == this.Lander) {
             this.disappear = false
-            console.log(res)
             this.reset()
             this.pass = {
               fAmtdr: '',    //应收合计
@@ -1319,7 +1186,6 @@ export default {
               fCorpid: ''     //结算单位ID
             }
             const fId = row.fId || this.ids
-            console.log(fId)
             getFee(fId).then(response => {
               this.DzfeeList = response.data.feeDoList
               this.fWbuOptions = response.data.feesList
@@ -1343,7 +1209,6 @@ export default {
             fCorpid: ''     //结算单位ID
           }
           const fId = row.fId || this.ids
-          console.log(fId)
           getFee(fId).then(response => {
             this.DzfeeList = response.data.feeDoList
             this.fWbuOptions = response.data.feesList
@@ -1369,22 +1234,15 @@ export default {
         fCorpid:''     //结算单位ID
       }
       const fId = row.fId || this.ids
-      console.log(fId)
       getFee(fId).then(response => {
-        console.log(this.DzfeeList)
-        console.log(response)
-        console.log(response.data.tFee.createBy)
         this.Operator = response.data.tFee.createBy
-        console.log(this.Operator)
         this.DzfeeList = response.data.feeDoList
         this.fWbuOptions = response.data.feesList
         this.queryParams = response.data.tFee
-        console.log(this.queryParams)
         this.fMblnoOptions = response.data.corps
         this.open = true;
         this.title = "修改财务数据主";
       });
-      console.log(this.queryParams)
     },
     /** 远程模糊查询用户 */
     corpsRemoteMethod(name) {
@@ -1400,13 +1258,9 @@ export default {
 
     /** 提交按钮 */
     submitForm() {
-      console.log(this.queryParams)
-      console.log(this.DzfeeList)
-      // console.log(this.feeList)
       this.$refs["ruless"].validate(valid => {
         if (valid) {
           if (!this.queryParams.fId) {
-            console.log(this.queryParams)
             this.queryParams.fBillstatus = '1'
             let formDate = new window.FormData()
             formDate.append('tFee',JSON.stringify(this.queryParams))
@@ -1414,7 +1268,6 @@ export default {
 
 
             updateFee(formDate).then(response => {
-              console.log(response)
               this.queryParams = response.data.tFee
               this.msgSuccess("新增成功");
               // this.DzfeeList = []
@@ -1427,7 +1280,6 @@ export default {
             let formDate = new window.FormData()
             formDate.append('tFee',JSON.stringify(this.queryParams))
             formDate.append("tFeeDo", JSON.stringify(this.DzfeeList))
-            console.log(this.queryParams)
             addFee(formDate).then(response => {
               this.msgSuccess("修改成功");
               // this.DzfeeList = []
@@ -1453,21 +1305,14 @@ export default {
         this.pass.fAmtdr = Number(this.pass.fAmtdr)
         this.pass.fAmtcr += Number(this.selection[item].fAmt)
         this.pass.fAmtdr += Number(this.selection[item].fAmtdr)
-        // console.log(Number(this.pass.fAmtcr))
-        // console.log(this.pass)
-        // console.log(this.pass.fAmtcr)
-        // console.log(this.pass.fAmtdr)
       }
-      console.log(this.pass)
+
       if(this.state_s == true) {
         if (this.selection.length == '0') {
           console.log('未选择')//写入提示
           this.$message.error('未选择导入行');
         } else {
-          console.log(this.selection[0].fMblno)
           for (let item in this.selection){
-            console.log(this.selection[item])
-            console.log(this.selection[item].fMblno)
             this.empty.push(this.selection[item].fMblno)
             this.nothing.push(this.selection[item].fName)
           }
@@ -1477,21 +1322,16 @@ export default {
           //去重货权方
           this.nothing = new Set(this.nothing)
           this.nothing = Array.from(this.nothing)
-          console.log(this.nothing)
 
           if(this.empty.length <= 1){
             this.pass.fMblno = this.empty[0]
-            console.log(this.pass.fMblno)
           }else {
             this.pass.fMblno = this.empty[0] + "..."
-            console.log(this.pass.fMblno)
           }
           if (this.nothing.length <= 1){
             this.pass.fName = this.nothing[0]
-            console.log(this.nothing)
           }else {
             this.pass.fName = this.nothing[0] + "..."
-            console.log(this.nothing)
           }
           // if (this.nothing.length <= 1){
           //   this.pass.fCorpid = this.nothing[0]