Procházet zdrojové kódy

提交嘉通库存总账

caojunjie před 2 roky
rodič
revize
bbd8d42e74

+ 10 - 0
src/api/generalLedger.js

@@ -0,0 +1,10 @@
+import request from '@/router/axios';
+
+// 查询
+export function getList(params) {
+    return request({
+        url: '/api/trade-finance/acc/accBillList',
+        method: 'get',
+        params
+    })
+}

+ 6 - 0
src/enums/column-name.js

@@ -843,6 +843,12 @@ const columnName = [{
 }, {
   code: 201.3,
   name: '投标对比-列表'
+}, {
+  code: 202.1,
+  name: '库存总账-应收'
+}, {
+  code: 202.2,
+  name: '库存总账-应付'
 }
 ]
 export const getColumnName = (key) => {

+ 190 - 0
src/views/generalLedger/accountsReceivable/index.vue

@@ -0,0 +1,190 @@
+<template>
+<basic-container>
+  <avue-crud
+      :option="option"
+      :data="dataList"
+      :page.sync="page"
+      :search.sync="search"
+      ref="crud"
+      @on-load="onLoad"
+      @resetColumn="resetColumn"
+      @saveColumn="saveColumn"
+      @search-change="searchChange"
+      @refresh-change="refreshChange">
+    <template slot="corpNameSearch">
+      <crop-select
+          v-model="search.corpId"
+          :name.sync="search.corpName"
+          :refresh="false"
+          corp-type="KH"
+      />
+    </template>
+    <template slot="corpName" slot-scope="{row,index}">
+      <span class="el-button--text" style="cursor: pointer" @click.stop="jump(row)">{{row.corpName}}</span>
+    </template>
+  </avue-crud>
+</basic-container>
+</template>
+
+<script>
+import {getList} from "@/api/generalLedger";
+
+export default {
+  name: "index",
+  data(){
+    return{
+      search:{},
+      dataList:[],
+      page: {
+        pageSize: 20,
+        currentPage: 1,
+        total: 0,
+        pageSizes: [10, 20, 30, 40, 50, 100, 200, 300, 400, 500]
+      },
+      option:{},
+      optionList:{
+        align: "center",
+        border: true,
+        index: true,
+        addBtn: false,
+        menu: false,
+        searchIndex: 2,
+        searchIcon: true,
+        searchMenuSpan: 6,
+        searchSpan: 8,
+        height: "auto",
+        searchMenuPosition: "right",
+        showSummary: true,
+        summaryText: "合计",
+        sumColumnList: [{
+          name: 'lastAmount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'lastSettlementAmount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'lastOutstandingAmount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'amount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'settlementAmount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'outstandingAmount',
+          type: 'sum',
+          decimals: 2
+        }],
+        column:[{
+          label: "客户名称",
+          prop: "corpName",
+          search: true,
+          overHidden: true,
+        },{
+          label: "日期",
+          prop: "createTime",
+          type: "month",
+          valueFormat: "yyyy-MM-dd HH:mm:ss",
+          search: true,
+          overHidden: true,
+        },{
+          label: "上期账单金额",
+          prop: "lastAmount",
+          overHidden: true,
+        },{
+          label: "上期结算金额",
+          prop: "lastSettlementAmount",
+          overHidden: true,
+        },{
+          label: "上期未收金额",
+          prop: "lastOutstandingAmount",
+          overHidden: true,
+        },{
+          label: "本期账单金额",
+          prop: "amount",
+          overHidden: true,
+        },{
+          label: "本期结算金额",
+          prop: "settlementAmount",
+          overHidden: true,
+        },{
+          label: "本期未收金额",
+          prop: "outstandingAmount",
+          overHidden: true,
+        }]
+      }
+    }
+  },
+  async created() {
+    this.option = await this.getColumnData(this.getColumnName(202.1), this.optionList);
+  },
+  methods:{
+    //跳转
+    jump(){
+      this.$router.push({
+        path: '/financialManagement/billDetails/billDetails'
+      });
+    },
+    //刷新
+    refreshChange() {
+      this.onLoad(this.page, this.search);
+    },
+    //点击搜索按钮触发
+    searchChange(params, done) {
+      this.page.currentPage = 1;
+      this.onLoad(this.page, params);
+      done();
+    },
+    onLoad(page, params = {}) {
+      let queryParams = {
+        size: page.pageSize,
+        current: page.currentPage,
+        // itemStatus: this.activeName,
+        statusIds: this.activeName,
+        ...Object.assign(params, this.search)
+      }
+      getList({
+        ...queryParams,
+        dc:"d"
+      }).then(res=>{
+        this.dataList = res.data.data.records || [];
+        this.page.total = res.data.data.total;
+      })
+    },
+
+    //自定义列保存
+    async saveColumn() {
+      /**
+       * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
+       * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
+       * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
+       */
+      const inSave = await this.saveColumnData(this.getColumnName(202.1), this.option);
+      if (inSave) {
+        this.$message.success("保存成功");
+        //关闭窗口
+        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+      }
+    },
+    //自定义列重置
+    async resetColumn() {
+      this.option = this.optionList;
+      const inSave = await this.delColumnData(this.getColumnName(202.1), this.optionList);
+      if (inSave) {
+        this.$message.success("重置成功");
+        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+      }
+    },
+  }
+}
+</script>
+
+<style scoped>
+
+</style>

+ 190 - 0
src/views/generalLedger/ledgerPayable/index.vue

@@ -0,0 +1,190 @@
+<template>
+<basic-container>
+  <avue-crud
+      :option="option"
+      :data="dataList"
+      :page.sync="page"
+      :search.sync="search"
+      ref="crud"
+      @on-load="onLoad"
+      @resetColumn="resetColumn"
+      @saveColumn="saveColumn"
+      @search-change="searchChange"
+      @refresh-change="refreshChange">
+    <template slot="corpNameSearch">
+      <crop-select
+          v-model="search.corpId"
+          :name.sync="search.corpName"
+          :refresh="false"
+          corp-type="KH"
+      />
+    </template>
+    <template slot="corpName" slot-scope="{row,index}">
+      <span class="el-button--text" style="cursor: pointer" @click.stop="jump(row)">{{row.corpName}}</span>
+    </template>
+  </avue-crud>
+</basic-container>
+</template>
+
+<script>
+import {getList} from "@/api/generalLedger";
+
+export default {
+  name: "index",
+  data(){
+    return{
+      search:{},
+      dataList:[],
+      page: {
+        pageSize: 20,
+        currentPage: 1,
+        total: 0,
+        pageSizes: [10, 20, 30, 40, 50, 100, 200, 300, 400, 500]
+      },
+      option:{},
+      optionList:{
+        align: "center",
+        border: true,
+        index: true,
+        addBtn: false,
+        menu: false,
+        searchIndex: 2,
+        searchIcon: true,
+        searchMenuSpan: 6,
+        searchSpan: 8,
+        height: "auto",
+        searchMenuPosition: "right",
+        showSummary: true,
+        summaryText: "合计",
+        sumColumnList: [{
+          name: 'lastAmount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'lastSettlementAmount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'lastOutstandingAmount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'amount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'settlementAmount',
+          type: 'sum',
+          decimals: 2
+        }, {
+          name: 'outstandingAmount',
+          type: 'sum',
+          decimals: 2
+        }],
+        column:[{
+          label: "客户名称",
+          prop: "corpName",
+          search: true,
+          overHidden: true,
+        },{
+          label: "日期",
+          prop: "createTime",
+          type: "month",
+          valueFormat: "yyyy-MM-dd HH:mm:ss",
+          search: true,
+          overHidden: true,
+        },{
+          label: "上期账单金额",
+          prop: "lastAmount",
+          overHidden: true,
+        },{
+          label: "上期结算金额",
+          prop: "lastSettlementAmount",
+          overHidden: true,
+        },{
+          label: "上期未付金额",
+          prop: "lastOutstandingAmount",
+          overHidden: true,
+        },{
+          label: "本期账单金额",
+          prop: "amount",
+          overHidden: true,
+        },{
+          label: "本期结算金额",
+          prop: "settlementAmount",
+          overHidden: true,
+        },{
+          label: "本期未付金额",
+          prop: "outstandingAmount",
+          overHidden: true,
+        }]
+      }
+    }
+  },
+  async created() {
+    this.option = await this.getColumnData(this.getColumnName(202.2), this.optionList);
+  },
+  methods:{
+    //跳转
+    jump(){
+      this.$router.push({
+        path: '/financialManagement/billDetails/billDetails'
+      });
+    },
+    //刷新
+    refreshChange() {
+      this.onLoad(this.page, this.search);
+    },
+    //点击搜索按钮触发
+    searchChange(params, done) {
+      this.page.currentPage = 1;
+      this.onLoad(this.page, params);
+      done();
+    },
+    onLoad(page, params = {}) {
+      let queryParams = {
+        size: page.pageSize,
+        current: page.currentPage,
+        // itemStatus: this.activeName,
+        statusIds: this.activeName,
+        ...Object.assign(params, this.search)
+      }
+      getList({
+        ...queryParams,
+        dc:"c"
+      }).then(res=>{
+        this.dataList = res.data.data.records || [];
+        this.page.total = res.data.data.total;
+      })
+    },
+
+    //自定义列保存
+    async saveColumn() {
+      /**
+       * 已定义全局方法,直接使用,saveColumnData保存列数据方法,参数传值(表格名称,当前表格的option数据)
+       * 已定义全局方法,直接使用,getColumnName方法用来获取枚举值,参数根据自己定义的code值获取中文名
+       * 一定要执行异步操作,要等接口成功返回,才能执行下一行代码
+       */
+      const inSave = await this.saveColumnData(this.getColumnName(202.2), this.option);
+      if (inSave) {
+        this.$message.success("保存成功");
+        //关闭窗口
+        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+      }
+    },
+    //自定义列重置
+    async resetColumn() {
+      this.option = this.optionList;
+      const inSave = await this.delColumnData(this.getColumnName(202.2), this.optionList);
+      if (inSave) {
+        this.$message.success("重置成功");
+        this.$refs.crud.$refs.dialogColumn.columnBox = false;
+      }
+    },
+  }
+}
+</script>
+
+<style scoped>
+
+</style>

+ 0 - 10
src/views/landTransportation/bulkCargo/detailPage.vue

@@ -2718,16 +2718,6 @@ export default {
     },
     //返回主列表
     backToList(value) {
-      console.log(JSON.stringify(this.goodsForm))
-      console.log(JSON.stringify(this.oldgoodsForm))
-      console.log(
-          contrastObj(this.goodsForm, this.oldgoodsForm)
-          , contrastList(this.tableData, this.oldtableData)
-          , contrastList(this.tableDataTwo, this.oldtableDataTwo)
-          , contrastList(this.entrustList, this.oldentrustList)
-          , contrastList(this.vehicleList, this.oldvehicleList)
-          , contrastList(this.orderFilesList, this.oldorderFilesList)
-      )
       if (contrastObj(this.goodsForm, this.oldgoodsForm)
           || contrastList(this.tableData, this.oldtableData)
           || contrastList(this.tableDataTwo, this.oldtableDataTwo)