lilei %!s(int64=2) %!d(string=hai) anos
pai
achega
a23790c2a9

+ 1 - 1
src/api/financeBook.js

@@ -174,7 +174,7 @@ export const updateDetailInvoiceDate = (params) => {
 }
 
 //修改备注信息
-export const updateNoteInfo = (params) => {
+export const updateFinanceBookDetail = (params) => {
   const url = `/financeBook/detail/update`
   return axios({
     url: url,

+ 2 - 2
src/views/financialManagement/collectionDetailStatic/noteModal.vue

@@ -27,7 +27,7 @@
 
 <script>
   import {
-    updateNoteInfo
+    updateFinanceBookDetail
   } from '@/api/financeBook.js'
   export default {
     name: 'NoteModal',
@@ -73,7 +73,7 @@
        }
        _this.spinning = true
        _this.confirmLoading = true
-       updateNoteInfo(ajax_form).then(res => {
+       updateFinanceBookDetail(ajax_form).then(res => {
          if (res.status == 200) {
            _this.$message.success(res.message)
            _this.cancel()

+ 2 - 2
src/views/financialManagement/collectionDetailStatic/printModal.vue

@@ -29,7 +29,7 @@
 
 <script>
   import {
-    updateNoteInfo
+    updateFinanceBookDetail
   } from '@/api/financeBook.js'
   export default {
     name: 'PrintModal',
@@ -76,7 +76,7 @@
        }
        _this.spinning = true
        _this.confirmLoading = true
-       updateNoteInfo(ajax_form).then(res => {
+       updateFinanceBookDetail(ajax_form).then(res => {
          if (res.status == 200) {
            _this.$message.success(res.message)
            _this.cancel()

+ 81 - 62
src/views/salesManagement/receiptPrint/list.vue

@@ -32,10 +32,10 @@
               <a-col :md="8" :sm="24" v-if="currentTab == 1">
                 <a-form-item label="收款打印状态">
                   <v-select
-                    v-model="queryParam.printState"
-                    ref="printState"
-                    id="salesCollectionList-printState"
-                    code="RECEIPT_PRINT"
+                    v-model="queryParam.printStatus"
+                    ref="printStatus"
+                    id="salesCollectionList-printStatus"
+                    code="PRINT_STATUS"
                     placeholder="请选择打印状态"
                     allowClear
                   ></v-select>
@@ -49,12 +49,21 @@
               </a-col>
             </a-row>
           </a-form>
+          <!-- 操作按钮 -->
+          <div class="table-operator">
+            <a-button type="primary" @click="handlePlPrint()" class="button-error">批量打印</a-button>
+            <span style="margin-left: 8px">
+              <template v-if="rowSelectionInfo && rowSelectionInfo.selectedRowKeys.length>0">{{ `已选 ${rowSelectionInfo.selectedRowKeys.length} 项` }}</template>
+            </span>
+          </div>
         </div>
         <!-- 列表 -->
         <s-table
           class="sTable fixPagination"
           ref="table"
           :style="{ height: tableHeight+80.5+'px' }"
+          :row-selection="{ columnWidth: 40, getCheckboxProps: record => ({ props: { disabled: (record.printStatus !== 'NO_PRINT'&&record.printStatus !== 'PRINT') } })}"
+          @rowSelection="rowSelectionFun"
           size="small"
           :rowKey="(record) => record.id"
           :columns="columns"
@@ -62,28 +71,29 @@
           :scroll="{ y:tableHeight }"
           :defaultLoadData="false"
           bordered>
-          <!-- 单号 -->
-          <template slot="bizNo" slot-scope="text, record">
-            <span v-if="$hasPermissions('B_salesDetail')" class="link-bule" @click="handleDetail(record,0)">{{ record.bizNo }}</span>
-            <span v-else>{{ record.bizNo }}</span>
+          <!-- 打印状态 -->
+          <template slot="printStatus" slot-scope="text, record">
+            <span v-if="record.printStatus=='NO_PRINT'" class="link-bule" @click="handlePrintStatus(record)">{{ record.printStatusDictValue }}</span>
+            <span v-else>{{ record.printStatusDictValue }}</span>
           </template>
           <!-- 操作 -->
           <template slot="action" slot-scope="text, record">
-            <a-button
-              size="small"
-              type="link"
-              v-if="record.voidFlag == 0 && record.printState == 'NO_PRINT'&&$hasPermissions('B_SkPrint')"
-              class="button-warning"
-              @click="handlePrint(record)"
-            >收款打印</a-button>
-            <a-button
-              size="small"
-              type="link"
-              class="button-warning"
-              v-else-if="record.printState == 'PRINT'&&$hasPermissions('B_SKPrintRecord')"
-              @click="viewPrint(record)"
-            >打印记录</a-button>
-            <span v-else>--</span>
+            <div>
+              <a-button
+                size="small"
+                type="link"
+                v-if="(record.printStatus == 'NO_PRINT'||record.printStatus == 'PRINT')&&$hasPermissions('B_SkPrint')"
+                class="button-warning"
+                @click="handlePrint(record)"
+              >收款打印</a-button>
+              <a-button
+                size="small"
+                type="link"
+                class="button-warning"
+                v-if="record.printStatus == 'PRINT'&&$hasPermissions('B_SKPrintRecord')"
+                @click="viewPrint(record)"
+              >打印记录</a-button>
+            </div>
           </template>
         </s-table>
 
@@ -99,16 +109,15 @@
         </commonModal>
         <!-- 打印记录 -->
         <recordModal v-drag ref="recordModal" modalTit="打印记录" :openModal="showRecordModal" @cancel="showRecordModal=false"></recordModal>
-        <!-- 查看销售单或备货单详情 -->
-        <commonModal
-          :modalTit="detailType?'备货单详情':'销售单详情'"
-          bodyPadding="10px"
-          width="70%"
-          :showFooter="false"
-          :openModal="showDetailModal"
-          @cancel="cancelDetail">
-          <salesDetail v-if="detailType==0" ref="salesDetail" :bizSn="bizSn"></salesDetail>
-          <dispatchDetail v-if="detailType==1" ref="dispatchDetail" :bizSn="bizSn"></dispatchDetail>
+        <!-- 操作提示 -->
+        <commonModal modalTit="操作提示" okText="暂不打印" :openModal="showPrintModal" @cancel="canselModal" @ok="updatePrintStatus">
+          <div style="text-align: center;">
+            <div style="margin-bottom: 15px;font-size: 14px;">如需将打印状态回退至<strong>【暂不打印】</strong>,请点击下方按钮</div>
+            <div style="line-height: 24px;">
+              <div>收款单号:{{ tipData&&tipData.bookNo }}</div>
+              <div>客户名称:{{ tipData&&tipData.payerName }}</div>
+            </div>
+          </div>
         </commonModal>
       </a-spin>
     </a-card>
@@ -119,27 +128,20 @@
 import { commonMixin } from '@/utils/mixin'
 import rangeDate from '@/views/common/rangeDate.vue'
 import { STable, VSelect } from '@/components'
-import subarea from '@/views/common/subarea.js'
-import Area from '@/views/common/area.js'
 import dealerSubareaScopeList from '@/views/common/dealerSubareaScopeList.vue'
 import commonModal from '@/views/common/commonModal.vue'
-import salesDetail from '@/views/salesManagement/salesQuery/detail.vue'
-import dispatchDetail from '@/views/salesManagement/pushOrderManagement/detail.vue'
 import recordModal from './recordModal.vue'
 import printModel from './printModel.vue'
-import { financeBookDetailList } from '@/api/financeBook'
+import { financeBookDetailList, updateFinanceBookDetail } from '@/api/financeBook'
 export default {
   name: 'ReceiptPrintList',
   mixins: [commonMixin],
-  components: { STable, VSelect, dealerSubareaScopeList, rangeDate, subarea, commonModal, recordModal, Area, printModel, salesDetail, dispatchDetail },
+  components: { STable, VSelect, dealerSubareaScopeList, rangeDate, commonModal, recordModal, printModel },
   data () {
     return {
       spinning: false,
       advanced: true, // 高级搜索 展开/关闭
       disabled: false, //  查询、重置按钮是否可操作
-      showDetailModal: false,
-      detailType: 2,
-      bizSn: null,
       tableHeight: 0,
       time: [],
       currentTab: 2,
@@ -147,15 +149,12 @@ export default {
       queryParam: {
         beginDate: '',
         endDate: '',
-        beginDateSettle: '',
-        endDateSettle: '',
         bookNo: '',
         payerName: '',
         subareaSn: undefined,
         billStatus: undefined,
-        voidFlag: 0,
         dealerProvinceSn: undefined,
-        printState: 'NO_PRINT'
+        printStatus: 'NO_PRINT'
       },
       totalData: {
         totalAmount: 0,
@@ -164,6 +163,8 @@ export default {
       },
       showTipModal: false,
       showRecordModal: false,
+      showPrintModal: false,
+      tipData: null,
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
         this.disabled = true
@@ -181,18 +182,19 @@ export default {
           this.spinning = false
           return data
         })
-      }
+      },
+      rowSelectionInfo: null // 批量选择的数据
     }
   },
   computed: {
     columns () {
       const arr = [
         { title: '序号', dataIndex: 'no', width: '4%', align: 'center' },
-        { title: '允许打印时间', dataIndex: 'auditDate', width: '9%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '允许打印时间', dataIndex: 'allowPrintTime', width: '9%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '收款单号', dataIndex: 'bookNo', width: '9%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '收款日期', dataIndex: 'receiptDate', width: '9%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '客户名称', dataIndex: 'payerName', align: 'left', width: '10%', customRender: function (text) { return text || '--' }, ellipsis: true },
-        { title: '财务编码', dataIndex: 'kdMidCustomerFnumber', align: 'left', width: '10%', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '财务编码', dataIndex: 'dealerEntity.kdMidCustomerFnumber', align: 'left', width: '10%', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '订单金额', dataIndex: 'orderAmount', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '收款金额', dataIndex: 'receiptAmount', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '使用授信', dataIndex: 'useCreditAmount', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
@@ -201,8 +203,8 @@ export default {
         { title: '汇入银行', dataIndex: 'bankName', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '足额打款', dataIndex: 'fullPaymentFlagDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '说明', dataIndex: 'remarks', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '收款打印状态', dataIndex: 'printStateDictValue', width: '6%', align: 'center' },
-        { title: '打印次数', dataIndex: 'printCount', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '收款打印状态', dataIndex: 'printStatusDictValue', width: '6%', align: 'center', scopedSlots: { customRender: 'printStatus' } },
+        { title: '打印次数', dataIndex: 'printNum', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '7%', align: 'center' }
       ]
       return arr
@@ -214,6 +216,17 @@ export default {
       this.pageInit()
       this.resetSearchForm()
     },
+    // 表格选中项
+    rowSelectionFun (obj) {
+      this.rowSelectionInfo = obj || null
+    },
+    handlePlPrint () {
+      const _this = this
+      const slen = _this.rowSelectionInfo.selectedRowKeys.length
+      if (!_this.rowSelectionInfo || (_this.rowSelectionInfo && slen < 1)) {
+        _this.$message.warning('请在列表勾选后再进行批量操作!')
+      }
+    },
     //  时间  change
     dateChange (date) {
       this.queryParam.beginDate = date[0] ? date[0] : ''
@@ -222,15 +235,22 @@ export default {
     custChange (val) {
       this.queryParam.payerName = val.name
     },
-    handleDetail (row, type) {
-      this.detailType = type
-      this.bizSn = type == 0 ? row.bizSn : row.dispatchBillSn
-      this.showDetailModal = true
+    handlePrintStatus (row) {
+      this.tipData = row
+      this.showPrintModal = true
     },
-    cancelDetail () {
-      this.showDetailModal = false
-      this.detailType = 2
-      this.bizSn = null
+    canselModal () {
+      this.tipData = null
+      this.showPrintModal = false
+    },
+    updatePrintStatus () {
+      updateFinanceBookDetail({ id: this.tipData.id, printStatus: 'UNABLE_PRINT' }).then(res => {
+        if (res.status == 200) {
+          this.canselModal()
+          this.$message.info(res.message)
+          this.$refs.table.refresh()
+        }
+      })
     },
     // 收款打印
     handlePrint (row) {
@@ -251,7 +271,7 @@ export default {
       this.showRecordModal = true
       this.$refs.recordModal.setData(row, {
         billType: 'SETTLE_RECEIPT',
-        billSn: row.accountReceiptSn
+        billSn: row.bookSn
       })
     },
     // 重置
@@ -266,9 +286,8 @@ export default {
         payerName: '',
         subareaSn: undefined,
         billStatus: undefined,
-        voidFlag: this.currentTab == 2 ? '0' : undefined,
         dealerProvinceSn: undefined,
-        printState: this.currentTab == 2 ? 'NO_PRINT' : 'AUDIT_PASS'
+        printStatus: this.currentTab == 2 ? 'NO_PRINT' : undefined
       }
       this.$refs.table.refresh(true)
     },

+ 3 - 9
src/views/salesManagement/receiptPrint/recordModal.vue

@@ -11,17 +11,11 @@
     <a-spin :spinning="spinning" tip="Loading...">
       <div class="common-main">
         <a-descriptions :column="2">
-          <a-descriptions-item label="销售单号">
-            {{ tipData&&tipData.bizNo }}
-          </a-descriptions-item>
-          <a-descriptions-item label="备货单号">
-            {{ tipData&&tipData.dispatchBillNo }}
+          <a-descriptions-item label="收款单号">
+            {{ tipData&&tipData.bookNo }}
           </a-descriptions-item>
           <a-descriptions-item label="客户名称">
-            {{ tipData&&tipData.settleClientName }}
-          </a-descriptions-item>
-          <a-descriptions-item label="收货客户名称">
-            {{ tipData&&tipData.receiverName||'--' }}
+            {{ tipData&&tipData.payerName }}
           </a-descriptions-item>
         </a-descriptions>
         <div>

+ 3 - 3
vue.config.js

@@ -92,7 +92,7 @@ const vueConfig = {
         modifyVars: {
           // less vars,customize ant design theme
           'primary-color': process.env.VUE_APP_THEME_COLOR,
-          'link-color': process.env.VUE_APP_THEME_COLOR,
+          'link-color': process.env.VUE_APP_THEME_COLOR
           // 'border-radius-base': '4px'
         },
         // do not remove this line
@@ -107,9 +107,9 @@ const vueConfig = {
     // If you want to turn on the proxy, please remove the mockjs /src/main.jsL11
     proxy: {
       '/api': {
-        // target: 'http://520f1184.nat123.fun:45432/ocs-admin',
+        target: 'http://160f12de.nat123.fun:53612/ocs-admin',
         // target: 'https://t.ocs.360arrow.com/ocs-admin', //  Á·Ï°
-        target: 'http://p.ocs.360arrow.com/ocs-admin', //  Ô¤·¢²¼
+        // target: 'http://p.ocs.360arrow.com/ocs-admin', //  Ô¤·¢²¼
         ws: false,
         changeOrigin: true,
         pathRewrite: {