浏览代码

线上支付订单

chenrui 6 月之前
父节点
当前提交
1450829225

+ 32 - 23
src/api/sales.js

@@ -9,8 +9,8 @@ export const salesList = (params) => {
     url: url,
     url: url,
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
-      'module': encodeURIComponent(params.buyerSn ? '按客户查询列表':'列表查询')
+    headers: {
+      'module': encodeURIComponent(params.buyerSn ? '按客户查询列表' : '列表查询')
     }
     }
   })
   })
 }
 }
@@ -20,7 +20,7 @@ export const salesDetail = (params) => {
     url: `/sales/findById/${params.id}`,
     url: `/sales/findById/${params.id}`,
     data: params,
     data: params,
     method: 'get',
     method: 'get',
-    headers:{
+    headers: {
       'module': encodeURIComponent('销售单详情')
       'module': encodeURIComponent('销售单详情')
     }
     }
   })
   })
@@ -31,7 +31,7 @@ export const salesDetailBySn = (params) => {
     url: `/sales/findBySn`,
     url: `/sales/findBySn`,
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
+    headers: {
       'module': encodeURIComponent('销售单详情')
       'module': encodeURIComponent('销售单详情')
     }
     }
   })
   })
@@ -42,7 +42,7 @@ export const salesPrint = (params) => {
     url: '/sales/print',
     url: '/sales/print',
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
+    headers: {
       'module': encodeURIComponent('打印')
       'module': encodeURIComponent('打印')
     }
     }
   })
   })
@@ -53,7 +53,7 @@ export const salesPrintPreview = (params) => {
     url: '/sales/printPreview',
     url: '/sales/printPreview',
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
+    headers: {
       'module': encodeURIComponent('打印预览')
       'module': encodeURIComponent('打印预览')
     }
     }
   })
   })
@@ -64,7 +64,7 @@ export const salesWriteDown = (params) => {
     url: '/sales/writeDown',
     url: '/sales/writeDown',
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
+    headers: {
       'module': encodeURIComponent('销售冲减')
       'module': encodeURIComponent('销售冲减')
     }
     }
   })
   })
@@ -75,7 +75,7 @@ export const salesWriteAudit = (params) => {
     url: '/sales/audit',
     url: '/sales/audit',
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
+    headers: {
       'module': encodeURIComponent('审核')
       'module': encodeURIComponent('审核')
     }
     }
   })
   })
@@ -86,7 +86,7 @@ export const salesWriteDiscount = (params) => {
     url: '/sales/discount',
     url: '/sales/discount',
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
+    headers: {
       'module': encodeURIComponent('打折')
       'module': encodeURIComponent('打折')
     }
     }
   })
   })
@@ -97,7 +97,7 @@ export const salesWritePrepareAudit = (params) => {
     url: '/sales/prepareAudit',
     url: '/sales/prepareAudit',
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
+    headers: {
       'module': encodeURIComponent('备货审核')
       'module': encodeURIComponent('备货审核')
     }
     }
   })
   })
@@ -108,7 +108,7 @@ export const salesWriteReceipt = (params) => {
     url: '/sales/receipt',
     url: '/sales/receipt',
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
+    headers: {
       'module': encodeURIComponent('收款')
       'module': encodeURIComponent('收款')
     }
     }
   })
   })
@@ -118,7 +118,7 @@ export const salesWriteStockOut = (params) => {
   return axios({
   return axios({
     url: `/sales/stockOut/${params.salesBillSn}`,
     url: `/sales/stockOut/${params.salesBillSn}`,
     method: 'get',
     method: 'get',
-    headers:{
+    headers: {
       'module': encodeURIComponent('出库')
       'module': encodeURIComponent('出库')
     }
     }
   })
   })
@@ -129,7 +129,7 @@ export const salesWriteSubmit = (params) => {
     url: '/sales/submit',
     url: '/sales/submit',
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
+    headers: {
       'module': encodeURIComponent('提交')
       'module': encodeURIComponent('提交')
     }
     }
   })
   })
@@ -140,8 +140,8 @@ export const salesSave = (params) => {
     url: '/sales/save',
     url: '/sales/save',
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
-      'module': encodeURIComponent(params.id?'编辑基本信息':params.distributionFlag == 0 ? '新增(零售)' : '新增(铺货)')
+    headers: {
+      'module': encodeURIComponent(params.id ? '编辑基本信息' : params.distributionFlag == 0 ? '新增(零售)' : '新增(铺货)')
     }
     }
   })
   })
 }
 }
@@ -152,8 +152,8 @@ export const salesDel = (params) => {
     url: `/sales/delete`,
     url: `/sales/delete`,
     data: params,
     data: params,
     method: 'post',
     method: 'post',
-    headers:{
-      'module': encodeURIComponent(params.mainFlag==1?'删除/取消':'清空列表')
+    headers: {
+      'module': encodeURIComponent(params.mainFlag == 1 ? '删除/取消' : '清空列表')
     }
     }
   })
   })
 }
 }
@@ -171,7 +171,7 @@ export const supperCodeByVin = (params) => {
   return axios({
   return axios({
     url: `/vinIdentify/queryPartCodeByVin/${params.vin}`,
     url: `/vinIdentify/queryPartCodeByVin/${params.vin}`,
     method: 'get',
     method: 'get',
-    headers:{
+    headers: {
       'module': encodeURIComponent('车架号查询')
       'module': encodeURIComponent('车架号查询')
     }
     }
   })
   })
@@ -181,8 +181,8 @@ export const salesDetailPrint = params => {
   const data = {
   const data = {
     url: `/sales/print/${params.sn}/${params.type}/${params.printOrgCode}/${params.printAllName}/${params.remarksShowFlag}/${params.priceFlag}`,
     url: `/sales/print/${params.sn}/${params.type}/${params.printOrgCode}/${params.printAllName}/${params.remarksShowFlag}/${params.priceFlag}`,
     method: 'get',
     method: 'get',
-    headers:{
-      'module': encodeURIComponent(params.type=='INK' ? '喷墨打印':'针式打印')
+    headers: {
+      'module': encodeURIComponent(params.type == 'INK' ? '喷墨打印' : '针式打印')
     }
     }
   }
   }
   // 喷墨打印
   // 喷墨打印
@@ -197,7 +197,7 @@ export const salesDetailExport = params => {
     url: `/sales/excel/${params.sn}`,
     url: `/sales/excel/${params.sn}`,
     method: 'get',
     method: 'get',
     responseType: 'blob',
     responseType: 'blob',
-    headers:{
+    headers: {
       'module': encodeURIComponent('导出Excel')
       'module': encodeURIComponent('导出Excel')
     }
     }
   })
   })
@@ -209,7 +209,7 @@ export const salesExport = params => {
     data: params,
     data: params,
     method: 'post',
     method: 'post',
     responseType: 'blob',
     responseType: 'blob',
-    headers:{
+    headers: {
       'module': encodeURIComponent('导出')
       'module': encodeURIComponent('导出')
     }
     }
   })
   })
@@ -221,8 +221,17 @@ export const vinCodeParse = params => {
     method: 'post',
     method: 'post',
     data: params,
     data: params,
     responseType: 'blob',
     responseType: 'blob',
-    headers:{
+    headers: {
       'module': encodeURIComponent('车架号图片ocr识别')
       'module': encodeURIComponent('车架号图片ocr识别')
     }
     }
   })
   })
 }
 }
+
+// 线上支付订单  备注修改
+export const onlinePayUpdateRemark = (params) => {
+  return axios({
+    url: `/sales/updateRemark`,
+    data: params,
+    method: 'post'
+  })
+}

+ 20 - 0
src/views/common/stateIcon.vue

@@ -1,5 +1,25 @@
 <template>
 <template>
   <div>
   <div>
+    <svg
+      v-if="state==4"
+      t="1734341582867"
+      class="icon"
+      viewBox="0 0 1160 1024"
+      version="1.1"
+      xmlns="http://www.w3.org/2000/svg"
+      p-id="5003"
+      :width="width"
+      :height="width"><path d="M531.319467 2.048a478.071467 478.071467 0 0 1 461.960533 355.054933l29.559467 77.960534a40.96 40.96 0 0 0 34.816 26.282666l19.933866 1.706667a23.893333 23.893333 0 0 1 16.247467 39.1168l-111.957333 134.280533-2.525867 2.6624c-9.557333 11.537067-23.893333 14.9504-43.008 10.308267-23.278933-5.666133-33.109333-20.2752-29.354667-43.8272a395.946667 395.946667 0 1 0-375.6032 270.336c21.026133 4.642133 31.607467 18.090667 31.607467 40.277333 0 22.254933-10.581333 36.113067-31.675733 41.5744a477.866667 477.866667 0 1 1 0-955.733333zM419.0208 235.042133a38.638933 38.638933 0 0 1 51.4048 11.605334l1.6384 2.594133 78.506667 146.090667L634.88 249.309867a38.638933 38.638933 0 0 1 52.974933-14.199467 38.638933 38.638933 0 0 1 14.199467 52.974933l-67.584 106.973867H730.453333c21.640533 0 38.843733 17.271467 38.843734 38.775467a38.638933 38.638933 0 0 1-36.0448 38.7072l-2.730667 0.136533-138.24-3.413333v67.447466L730.453333 536.576c21.640533 0 38.843733 17.271467 38.843734 38.775467a38.638933 38.638933 0 0 1-36.0448 38.7072l-2.730667 0.136533H592.213333v120.4224a38.638933 38.638933 0 0 1-36.0448 38.775467l-2.730666 0.068266a38.638933 38.638933 0 0 1-38.7072-36.0448l-0.136534-2.730666 0.136534-118.101334-138.308267-2.389333a38.638933 38.638933 0 0 1-38.775467-38.843733 38.638933 38.638933 0 0 1 35.976534-38.7072l2.798933-0.068267H514.730667l0.136533-64.1024-138.308267 0.136533a38.638933 38.638933 0 0 1-38.775466-38.843733 38.638933 38.638933 0 0 1 35.976533-38.7072l2.798933-0.068267 91.272534 0.4096L404.821333 288.085333a38.638933 38.638933 0 0 1 14.199467-53.0432z" :fill="color[2]" p-id="5004"></path></svg>
+    <svg
+      v-if="state==3"
+      t="1734341582867"
+      class="icon"
+      viewBox="0 0 1160 1024"
+      version="1.1"
+      xmlns="http://www.w3.org/2000/svg"
+      p-id="5003"
+      :width="width"
+      :height="width"><path d="M531.319467 2.048a478.071467 478.071467 0 0 1 461.960533 355.054933l29.559467 77.960534a40.96 40.96 0 0 0 34.816 26.282666l19.933866 1.706667a23.893333 23.893333 0 0 1 16.247467 39.1168l-111.957333 134.280533-2.525867 2.6624c-9.557333 11.537067-23.893333 14.9504-43.008 10.308267-23.278933-5.666133-33.109333-20.2752-29.354667-43.8272a395.946667 395.946667 0 1 0-375.6032 270.336c21.026133 4.642133 31.607467 18.090667 31.607467 40.277333 0 22.254933-10.581333 36.113067-31.675733 41.5744a477.866667 477.866667 0 1 1 0-955.733333zM419.0208 235.042133a38.638933 38.638933 0 0 1 51.4048 11.605334l1.6384 2.594133 78.506667 146.090667L634.88 249.309867a38.638933 38.638933 0 0 1 52.974933-14.199467 38.638933 38.638933 0 0 1 14.199467 52.974933l-67.584 106.973867H730.453333c21.640533 0 38.843733 17.271467 38.843734 38.775467a38.638933 38.638933 0 0 1-36.0448 38.7072l-2.730667 0.136533-138.24-3.413333v67.447466L730.453333 536.576c21.640533 0 38.843733 17.271467 38.843734 38.775467a38.638933 38.638933 0 0 1-36.0448 38.7072l-2.730667 0.136533H592.213333v120.4224a38.638933 38.638933 0 0 1-36.0448 38.775467l-2.730666 0.068266a38.638933 38.638933 0 0 1-38.7072-36.0448l-0.136534-2.730666 0.136534-118.101334-138.308267-2.389333a38.638933 38.638933 0 0 1-38.775467-38.843733 38.638933 38.638933 0 0 1 35.976534-38.7072l2.798933-0.068267H514.730667l0.136533-64.1024-138.308267 0.136533a38.638933 38.638933 0 0 1-38.775466-38.843733 38.638933 38.638933 0 0 1 35.976533-38.7072l2.798933-0.068267 91.272534 0.4096L404.821333 288.085333a38.638933 38.638933 0 0 1 14.199467-53.0432z" :fill="color[1]" p-id="5004"></path></svg>
     <svg
     <svg
       v-if="state==2"
       v-if="state==2"
       t="1647850921214"
       t="1647850921214"

+ 5 - 3
src/views/financialManagement/financialCollection/detailModal.vue

@@ -20,9 +20,11 @@
         <a-descriptions-item label="收款方式">{{ detailsData.settleStyleSnDictValue || '--' }}</a-descriptions-item>
         <a-descriptions-item label="收款方式">{{ detailsData.settleStyleSnDictValue || '--' }}</a-descriptions-item>
         <a-descriptions-item label="收款时间">{{ detailsData.settleTime || '--' }}</a-descriptions-item>
         <a-descriptions-item label="收款时间">{{ detailsData.settleTime || '--' }}</a-descriptions-item>
         <a-descriptions-item label="审核时间">{{ detailsData.auditTime || '--' }}</a-descriptions-item>
         <a-descriptions-item label="审核时间">{{ detailsData.auditTime || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="退款金额">{{ detailsData.auditTime || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="退款时间">{{ detailsData.auditTime || '--' }}</a-descriptions-item>
-        <a-descriptions-item label="退款方式">{{ detailsData.auditTime || '--' }}</a-descriptions-item>
+        <template v-if="detailsData.billState=='REFUNDING'||detailsData.billState=='REFUNDED'">
+          <a-descriptions-item label="退款金额">{{ detailsData.refundAmount || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="退款时间">{{ detailsData.refundData || '--' }}</a-descriptions-item>
+          <a-descriptions-item label="退款方式">{{ detailsData.refundTypeDictValue || '--' }}{{ detailsData.refundTypeDictValue?'(1-3个工作日到账)':'' }}</a-descriptions-item>
+        </template>
       </a-descriptions>
       </a-descriptions>
       <div class="btn-cont"><a-button id="financialPaymentDetail-modal-back" @click="isShow = false">关闭</a-button></div>
       <div class="btn-cont"><a-button id="financialPaymentDetail-modal-back" @click="isShow = false">关闭</a-button></div>
     </div>
     </div>

+ 16 - 6
src/views/financialManagement/financialCollection/list.vue

@@ -77,11 +77,12 @@
           ,待收金额
           ,待收金额
           <strong>{{ totalData&&(totalData.unsettleAmount || totalData.unsettleAmount==0) ? toThousands(totalData.unsettleAmount) : '--' }}</strong>
           <strong>{{ totalData&&(totalData.unsettleAmount || totalData.unsettleAmount==0) ? toThousands(totalData.unsettleAmount) : '--' }}</strong>
           ,退款中金额
           ,退款中金额
-          <strong>{{ totalData&&(totalData.unsettleAmount || totalData.unsettleAmount==0) ? toThousands(totalData.unsettleAmount) : '--' }}</strong>
+          <strong>{{ totalData&&(totalData.refundingAmount || totalData.refundingAmount==0) ? toThousands(totalData.refundingAmount) : '--' }}</strong>
           ,已退金额
           ,已退金额
-          <strong>{{ totalData&&(totalData.unsettleAmount || totalData.unsettleAmount==0) ? toThousands(totalData.unsettleAmount) : '--' }}</strong>
-          <a-tooltip placement="bottom" title="实收金额=已收金额-退款中金额-已退金额">,实收金额<a-icon type="question-circle" style="margin:0 10px 0 5px;"/></a-tooltip>
-          <strong>{{ totalData&&(totalData.unsettleAmount || totalData.unsettleAmount==0) ? toThousands(totalData.unsettleAmount) : '--' }}</strong>
+          <strong>{{ totalData&&(totalData.refundedAmount || totalData.refundedAmount==0) ? toThousands(totalData.refundedAmount) : '--' }}</strong>
+          <a-tooltip placement="bottom" title="实收金额=已收金额-退款中金额-已退金额">,<span style="color:#ED1c24;">实收金额</span><a-icon type="question-circle" style="margin:0 10px 0 5px;color:#ED1c24;"/></a-tooltip>
+          <strong style="color:#ED1c24;" v-if="receivedPriceFlag">{{ receivedPrice }}</strong>
+          <span style="color:#ED1c24;" v-else>--</span>
         </div>
         </div>
       </a-alert>
       </a-alert>
       <div v-if="$hasPermissions('B_financialCollectionPl')" style="margin-bottom: 10px">
       <div v-if="$hasPermissions('B_financialCollectionPl')" style="margin-bottom: 10px">
@@ -98,7 +99,7 @@
         :style="{ height: tableHeight+84.5+'px' }"
         :style="{ height: tableHeight+84.5+'px' }"
         size="small"
         size="small"
         :rowKey="record => record.id"
         :rowKey="record => record.id"
-        :row-selection="$hasPermissions('B_financialCollectionPl') ? { columnWidth: 40, getCheckboxProps: record => ({ props: { disabled: record.settleState == 'SETTLED' } }) } : null"
+        :row-selection="$hasPermissions('B_financialCollectionPl') ? { columnWidth: 40, getCheckboxProps: record => ({ props: { disabled: (record.settleState == 'SETTLED' ||record.billState=='REFUNDING' ||record.billState=='REFUNDED')} }) } : null"
         @rowSelection="rowSelectionFun"
         @rowSelection="rowSelectionFun"
         :columns="columns"
         :columns="columns"
         :data="loadData"
         :data="loadData"
@@ -239,7 +240,7 @@ export default {
         { title: '创建时间', dataIndex: 'createDate', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '创建时间', dataIndex: 'createDate', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '审核时间', dataIndex: 'auditTime', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '审核时间', dataIndex: 'auditTime', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '收款时间', dataIndex: 'settleTime', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '收款时间', dataIndex: 'settleTime', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '退款时间', dataIndex: 'settleTime', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '退款时间', dataIndex: 'refundData', width: '10%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '5%', align: 'center' }
         { title: '操作', scopedSlots: { customRender: 'action' }, width: '5%', align: 'center' }
       ],
       ],
       loading: false,
       loading: false,
@@ -278,6 +279,15 @@ export default {
         })
         })
       }
       }
       return ret ? Number(ret).toFixed(2) : 0
       return ret ? Number(ret).toFixed(2) : 0
+    },
+    // 实收金额判断
+    receivedPriceFlag () {
+      const isShow = this.totalData && (this.totalData.settledAmount || this.totalData.settledAmount == 0) && (this.totalData.refundingAmount || this.totalData.refundingAmount == 0) && (this.totalData.refundedAmount || this.totalData.refundedAmount == 0)
+      return isShow
+    },
+    // 实收金额
+    receivedPrice () {
+      return this.totalData.settledAmount - this.totalData.refundingAmount - this.totalData.refundedAmount
     }
     }
   },
   },
   methods: {
   methods: {

+ 32 - 26
src/views/salesManagement/onlinePayOrder/detail.vue

@@ -1,7 +1,7 @@
 <template>
 <template>
-  <div v-if="showPage" class="jg-page-wrap salesDetail-wrap">
+  <div v-if="showPage" class="jg-page-wrap onlinePayDetail-wrap">
     <a-spin :spinning="spinning" tip="Loading...">
     <a-spin :spinning="spinning" tip="Loading...">
-      <a-page-header :ghost="false" :backIcon="false" class="salesDetail-cont" :style="{ padding: !outBizSn ? '16px 24px' : '0px 24px' }">
+      <a-page-header :ghost="false" :backIcon="false" class="onlinePayDetail-cont" :style="{ padding: !outBizSn ? '16px 24px' : '0px 24px' }">
         <!-- 自定义的二级文字标题 -->
         <!-- 自定义的二级文字标题 -->
         <template slot="subTitle" v-if="!outBizSn && detailData">
         <template slot="subTitle" v-if="!outBizSn && detailData">
           <span class="billno">单号:{{ detailData.salesBillNo ||'--' }}</span>
           <span class="billno">单号:{{ detailData.salesBillNo ||'--' }}</span>
@@ -31,17 +31,10 @@
       </a-page-header>
       </a-page-header>
       <div class="sales-detail-body">
       <div class="sales-detail-body">
         <!-- 基础信息 -->
         <!-- 基础信息 -->
-        <a-card size="small" :bordered="false" class="salesDetail-cont" v-show="isShowBisiceInfo">
+        <a-card size="small" :bordered="false" class="onlinePayDetail-cont" v-show="isShowBisiceInfo">
           <a-descriptions size="small" :column="3">
           <a-descriptions size="small" :column="3">
-            <div slot="title" style="display:flex;justify-content:space-between;align-items:center;">
+            <div slot="title">
               <span>基础信息</span>
               <span>基础信息</span>
-              <a-button
-                type="link"
-                id="salesReturnGrabEdit-editDesc-btn"
-                size="small"
-                @click="openEditModal=true"
-                class="button-info"
-                key="0"> <a-icon type="edit"></a-icon> 编辑</a-button>
             </div>
             </div>
             <a-descriptions-item label="客户名称">{{ detailData&&detailData.buyerNameCurrent?detailData.buyerName?detailData.buyerName==detailData.buyerNameCurrent?detailData.buyerNameCurrent:detailData.buyerNameCurrent+'('+detailData.buyerName+')':detailData.buyerNameCurrent:'--' }}</a-descriptions-item>
             <a-descriptions-item label="客户名称">{{ detailData&&detailData.buyerNameCurrent?detailData.buyerName?detailData.buyerName==detailData.buyerNameCurrent?detailData.buyerNameCurrent:detailData.buyerNameCurrent+'('+detailData.buyerName+')':detailData.buyerNameCurrent:'--' }}</a-descriptions-item>
             <a-descriptions-item label="客户地址" :span="2">
             <a-descriptions-item label="客户地址" :span="2">
@@ -55,16 +48,23 @@
             </a-descriptions-item>
             </a-descriptions-item>
             <a-descriptions-item label="收款方式">{{ detailData&&detailData.settleStyleSnDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="收款方式">{{ detailData&&detailData.settleStyleSnDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="联系电话">{{ detailData&&detailData.consigneeTel || '--' }}</a-descriptions-item>
             <a-descriptions-item label="联系电话">{{ detailData&&detailData.consigneeTel || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="备注">{{ detailData&&detailData.remarks || '--' }}</a-descriptions-item>
             <a-descriptions-item label="销售单号">{{ detailData&&detailData.salesBillNo || '--' }}</a-descriptions-item>
             <a-descriptions-item label="销售单号">{{ detailData&&detailData.salesBillNo || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="备注" :span="3">{{ detailData&&detailData.remarks || '--' }} <a-button
+              v-if="detailData&&detailData.billStatus=='WAIT_AUDIT'"
+              type="link"
+              id="salesReturnGrabEdit-editDesc-btn"
+              size="small"
+              @click="openEditModal=true"
+              class="button-info"
+              key="0"> <a-icon type="edit"></a-icon> 编辑</a-button></a-descriptions-item>
             <a-descriptions-item label="制单人">{{ detailData&&detailData.operatorName || '--' }}</a-descriptions-item>
             <a-descriptions-item label="制单人">{{ detailData&&detailData.operatorName || '--' }}</a-descriptions-item>
             <a-descriptions-item label="业务员">{{ detailData&&detailData.salesManName || '--' }}</a-descriptions-item>
             <a-descriptions-item label="业务员">{{ detailData&&detailData.salesManName || '--' }}</a-descriptions-item>
             <a-descriptions-item label="来源">{{ detailData&&detailData.sourceTypeDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="来源">{{ detailData&&detailData.sourceTypeDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="下级采购单号" v-if="detailData&&detailData.sourceType=='PURCHASE'">{{ detailData&&detailData.purchaseBillNo || '--' }}</a-descriptions-item>
             <a-descriptions-item label="下级采购单号" v-if="detailData&&detailData.sourceType=='PURCHASE'">{{ detailData&&detailData.purchaseBillNo || '--' }}</a-descriptions-item>
             <a-descriptions-item label="业务状态">{{ detailData&&detailData.billStatusDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="业务状态">{{ detailData&&detailData.billStatusDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="财务状态">{{ detailData&&detailData.financialStatusDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="财务状态">{{ detailData&&detailData.financialStatusDictValue || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="采购单号" v-if="detailData&&detailData.sourceType!='SALES'&&detailData.sourceType!='TRANSFER_ORDER'">{{ detailData.purchaseBillNo || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="收货状态" v-if="detailData&&detailData.sourceType=='XPRH_PURCHASE'&&detailData.billStatus=='FINISH'">{{ detailData.purchaseBillNo || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="采购单号" v-if="detailData&&detailData.sourceType!='SALES'">{{ detailData.purchaseBillNo || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="收货状态" v-if="detailData&&detailData.sourceType!='XPRH_PURCHASE'&&detailData.sourceType!='SALES'&&detailData.billStatus=='FINISH'">{{ detailData.receiptStatusDictValue || '--' }}</a-descriptions-item>
           </a-descriptions>
           </a-descriptions>
         </a-card>
         </a-card>
         <a-card size="small" :bordered="false" class="pages-wrap">
         <a-card size="small" :bordered="false" class="pages-wrap">
@@ -141,7 +141,12 @@
     <!-- 出入库明细 -->
     <!-- 出入库明细 -->
     <outInDetialModal ref="outInDetialModal" outBizType="SALES" :openModal="showOutInModal" @close="showOutInModal=false"></outInDetialModal>
     <outInDetialModal ref="outInDetialModal" outBizType="SALES" :openModal="showOutInModal" @close="showOutInModal=false"></outInDetialModal>
     <!-- 编辑备注 -->
     <!-- 编辑备注 -->
-    <editRemarkModal :openModal="openEditModal" @close="openEditModal=false" @ok="handleEditOk"></editRemarkModal>
+    <editRemarkModal
+      :openModal="openEditModal"
+      :itemSn="$route.params.sn"
+      :mainContent="detailData&&detailData.remarks"
+      @close="openEditModal=false"
+      @ok="handleEditOk"></editRemarkModal>
   </div>
   </div>
 </template>
 </template>
 
 
@@ -153,12 +158,13 @@ import { hdPrint } from '@/libs/JGPrint'
 import { STable, VSelect } from '@/components'
 import { STable, VSelect } from '@/components'
 import editRemarkModal from './editRemarkModal.vue'
 import editRemarkModal from './editRemarkModal.vue'
 import PrintPanel from '@/views/common/printPanel.vue'
 import PrintPanel from '@/views/common/printPanel.vue'
+import outInDetialModal from '../salesQueryNew/outInDetialModal.vue'
 // 接口
 // 接口
 import { salesDetailBySn, salesDetailPrint, salesDetailExport } from '@/api/sales'
 import { salesDetailBySn, salesDetailPrint, salesDetailExport } from '@/api/sales'
 import { salesDetailList } from '@/api/salesDetail'
 import { salesDetailList } from '@/api/salesDetail'
 export default {
 export default {
-  name: 'SalesDetail',
-  components: { STable, VSelect, PrintPanel, editRemarkModal },
+  name: 'OnlinePayOrderDetail',
+  components: { STable, VSelect, PrintPanel, editRemarkModal, outInDetialModal },
   mixins: [commonMixin],
   mixins: [commonMixin],
   props: {
   props: {
     outBizSn: { //  有值则为弹框,无值则为页面
     outBizSn: { //  有值则为弹框,无值则为页面
@@ -233,28 +239,28 @@ export default {
         { title: '售价', dataIndex: 'price', width: '5%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
         { title: '售价', dataIndex: 'price', width: '5%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
         { title: '销售数量', dataIndex: 'qty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '销售数量', dataIndex: 'qty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '单位', dataIndex: 'productOrigUnit', width: '4%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '单位', dataIndex: 'productOrigUnit', width: '4%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '售价小计', dataIndex: 'totalAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
-        { title: '是否急件', dataIndex: 'oosFlagDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '操作', scopedSlots: { customRender: 'action' }, width: '7%', align: 'center' }
+        { title: '售价小计', dataIndex: 'totalAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } }
       ]
       ]
       if (this.detailData && this.detailData.sourceType && this.detailData.sourceType === 'XPRH_PURCHASE') {
       if (this.detailData && this.detailData.sourceType && this.detailData.sourceType === 'XPRH_PURCHASE') {
-        arr.splice(8, 0, { title: <a-tooltip placement="bottom" title='返券金额以销售单完结时的活动规则为准'>返券金额&nbsp;<a-icon type="question-circle" /></a-tooltip>, dataIndex: 'giveAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
+        arr.push({ title: <a-tooltip placement="bottom" title='返券金额以销售单完结时的活动规则为准'>返券金额&nbsp;<a-icon type="question-circle" /></a-tooltip>, dataIndex: 'giveAmount', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
       }
       }
       // 实际总成本
       // 实际总成本
       if (this.showCost) {
       if (this.showCost) {
-        arr.splice(9, 0, { slots: { title: 'costTitle' }, dataIndex: 'totalCost', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
+        arr.push({ slots: { title: 'costTitle' }, dataIndex: 'totalCost', width: '6%', align: 'right', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
       }
       }
       // 下级创建,不显示仓库仓位
       // 下级创建,不显示仓库仓位
       if (!this.isOwerEdit) {
       if (!this.isOwerEdit) {
-        arr.splice(10, 0, { title: '库存数量', dataIndex: 'currentStockQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
+        arr.push({ title: '库存数量', dataIndex: 'currentStockQty', width: '6%', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } })
       }
       }
-
+      arr.push({ title: '是否急件', dataIndex: 'oosFlagDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } })
+      arr.push({ title: '操作', scopedSlots: { customRender: 'action' }, width: '7%', align: 'center' })
       return arr
       return arr
     }
     }
   },
   },
   methods: {
   methods: {
     handleEditOk () {
     handleEditOk () {
       this.openEditModal = false
       this.openEditModal = false
+      this.getDetail()
     },
     },
     // 打印预览/快捷打印
     // 打印预览/快捷打印
     handlePrint (type, printerType) {
     handlePrint (type, printerType) {
@@ -353,7 +359,7 @@ export default {
 </script>
 </script>
 
 
 <style lang="less" scoped>
 <style lang="less" scoped>
-  .salesDetail-wrap{
+  .onlinePayDetail-wrap{
     position: relative;
     position: relative;
     height: 100%;
     height: 100%;
     .billno{
     .billno{
@@ -367,7 +373,7 @@ export default {
     .ant-tag-green,.ant-tag-orange{
     .ant-tag-green,.ant-tag-orange{
       vertical-align: middle;
       vertical-align: middle;
     }
     }
-    .salesDetail-cont{
+    .onlinePayDetail-cont{
       margin-bottom: 10px;
       margin-bottom: 10px;
       /deep/ .ant-descriptions-title{
       /deep/ .ant-descriptions-title{
           margin-bottom: 10px;
           margin-bottom: 10px;

+ 29 - 23
src/views/salesManagement/onlinePayOrder/editRemarkModal.vue

@@ -1,7 +1,7 @@
 <template>
 <template>
   <a-modal
   <a-modal
     centered
     centered
-    class="chainTransferOut-basicInfo-modal"
+    class="edit-remark-modal"
     :footer="null"
     :footer="null"
     :maskClosable="false"
     :maskClosable="false"
     title="编辑备注"
     title="编辑备注"
@@ -10,26 +10,26 @@
     :width="450">
     :width="450">
     <a-spin :spinning="spinning" tip="Loading...">
     <a-spin :spinning="spinning" tip="Loading...">
       <a-form-model
       <a-form-model
-        id="chainTransferOut-basicInfo-form"
+        id="edit-remark-form"
         ref="ruleForm"
         ref="ruleForm"
         :model="form"
         :model="form"
         :rules="rules"
         :rules="rules"
         :label-col="formItemLayout.labelCol"
         :label-col="formItemLayout.labelCol"
         :wrapper-col="formItemLayout.wrapperCol"
         :wrapper-col="formItemLayout.wrapperCol"
       >
       >
-        <a-form-model-item label="备注" prop="remark">
+        <a-form-model-item label="备注" prop="remarks">
           <a-textarea
           <a-textarea
             :autosize="{minRows: 5, maxRows: 5}"
             :autosize="{minRows: 5, maxRows: 5}"
-            id="chainTransferOut-basicInfo-remark"
+            id="edit-remark-remarks"
             :maxLength="100"
             :maxLength="100"
-            v-model="form.remark"
+            v-model="form.remarks"
             placeholder="请输入备注(最多100个字符)"
             placeholder="请输入备注(最多100个字符)"
             allowClear />
             allowClear />
         </a-form-model-item>
         </a-form-model-item>
       </a-form-model>
       </a-form-model>
       <div class="btn-cont">
       <div class="btn-cont">
-        <a-button id="chainTransferOut-basicInfo-modal-back" @click="isShow = false" style="margin-right: 15px;">取消</a-button>
-        <a-button type="primary" id="chainTransferOut-basicInfo-modal-save" @click="handleSave">保存</a-button>
+        <a-button id="edit-remark-modal-back" @click="isShow = false" style="margin-right: 15px;">取消</a-button>
+        <a-button type="primary" id="edit-remark-modal-save" @click="handleSave">保存</a-button>
       </div>
       </div>
     </a-spin>
     </a-spin>
   </a-modal>
   </a-modal>
@@ -37,18 +37,24 @@
 
 
 <script>
 <script>
 import { commonMixin } from '@/utils/mixin'
 import { commonMixin } from '@/utils/mixin'
-import { VSelect } from '@/components'
-import outTenant from '@/views/common/outTenant.js'
-import { allocLinkageOutSave } from '@/api/allocLinkageOut'
+// 接口
+import { onlinePayUpdateRemark } from '@/api/sales'
 export default {
 export default {
-  name: 'ChainTransferOutBasicInfoModal',
-  components: { VSelect, outTenant },
+  name: 'EditRemarkModal',
   mixins: [commonMixin],
   mixins: [commonMixin],
   props: {
   props: {
     openModal: {
     openModal: {
       //  弹框显示状态
       //  弹框显示状态
       type: Boolean,
       type: Boolean,
       default: false
       default: false
+    },
+    itemSn: {
+      type: String,
+      default: ''
+    },
+    mainContent: {
+      type: String,
+      default: ''
     }
     }
   },
   },
   data () {
   data () {
@@ -60,13 +66,10 @@ export default {
         wrapperCol: { span: 20 }
         wrapperCol: { span: 20 }
       },
       },
       form: {
       form: {
-        allocationType: '', // 调出产品类型
-        putTenantSn: undefined, //  调往对象
-        remark: ''// 备注
+        remarks: ''// 备注
       },
       },
       rules: {
       rules: {
-        allocationType: [{ required: true, message: '请选择调出产品类型', trigger: 'change' }],
-        putTenantSn: [{ required: true, message: '请选择调往对象', trigger: 'change' }]
+        remarks: [{ required: true, message: '请输入备注', trigger: 'blur' }]
       }
       }
     }
     }
   },
   },
@@ -77,18 +80,17 @@ export default {
       this.$refs.ruleForm.validate(valid => {
       this.$refs.ruleForm.validate(valid => {
         if (valid) {
         if (valid) {
           const form = JSON.parse(JSON.stringify(_this.form))
           const form = JSON.parse(JSON.stringify(_this.form))
+          form.salesBillSn = _this.itemSn
           _this.spinning = true
           _this.spinning = true
-          allocLinkageOutSave(form).then(res => {
+          onlinePayUpdateRemark(form).then(res => {
             if (res.status == 200) {
             if (res.status == 200) {
               _this.$message.success(res.message)
               _this.$message.success(res.message)
               setTimeout(() => {
               setTimeout(() => {
-                _this.isShow = false
                 _this.$emit('ok', res.data)
                 _this.$emit('ok', res.data)
-                _this.spinning = false
               }, 1000)
               }, 1000)
-            } else {
-              _this.spinning = false
+              _this.isShow = false
             }
             }
+            _this.spinning = false
           })
           })
         } else {
         } else {
           return false
           return false
@@ -106,6 +108,10 @@ export default {
       if (!newValue) {
       if (!newValue) {
         this.$emit('close')
         this.$emit('close')
         this.$refs.ruleForm.resetFields()
         this.$refs.ruleForm.resetFields()
+      } else {
+        if (this.mainContent && this.mainContent.length) {
+          this.form.remarks = this.mainContent
+        }
       }
       }
     }
     }
   }
   }
@@ -113,7 +119,7 @@ export default {
 </script>
 </script>
 
 
 <style lang="less">
 <style lang="less">
-.chainTransferOut-basicInfo-modal {
+.edit-remark-modal {
 	.ant-modal-body {
 	.ant-modal-body {
 		padding: 40px 40px 24px;
 		padding: 40px 40px 24px;
 	}
 	}

+ 109 - 160
src/views/salesManagement/onlinePayOrder/list.vue

@@ -1,14 +1,14 @@
 <template>
 <template>
-  <div class="jg-page-wrap onlinePayOrderList-wrap">
+  <div class="jg-page-wrap salesManagementList-wrap">
     <a-card size="small" :bordered="false" class="table-page-search-wrapper">
     <a-card size="small" :bordered="false" class="table-page-search-wrapper">
       <!-- 搜索条件 -->
       <!-- 搜索条件 -->
       <div ref="tableSearch">
       <div ref="tableSearch">
         <a-form layout="inline" @keyup.enter.native="searchForm">
         <a-form layout="inline" @keyup.enter.native="searchForm">
           <a-row type="flex" justify="start" :gutter="15">
           <a-row type="flex" justify="start" :gutter="15">
-            <a-col :md="6" :sm="24">
+            <a-col :span="6">
               <a-form-item label="创建时间">
               <a-form-item label="创建时间">
                 <rangeDate
                 <rangeDate
-                  id="onlinePayOrderList-creatdate"
+                  id="salesManagementList-creatdate"
                   :allowClear="isByCustQuery"
                   :allowClear="isByCustQuery"
                   :hasDisabledAreaTime="false"
                   :hasDisabledAreaTime="false"
                   ref="rangeDate"
                   ref="rangeDate"
@@ -16,32 +16,33 @@
                   @change="dateChange" />
                   @change="dateChange" />
               </a-form-item>
               </a-form-item>
             </a-col>
             </a-col>
-            <a-col :md="6" :sm="24">
+            <a-col :span="6">
               <a-form-item label="客户名称" :label-col="{ span:7 }" :wrapper-col="{ span:17}" :required="isByCustQuery">
               <a-form-item label="客户名称" :label-col="{ span:7 }" :wrapper-col="{ span:17}" :required="isByCustQuery">
-                <custList id="onlinePayOrderList-custList" ref="custList" @change="custChange"></custList>
+                <custList id="salesManagementList-custList" ref="custList" @change="custChange"></custList>
               </a-form-item>
               </a-form-item>
             </a-col>
             </a-col>
             <a-col :md="6" :sm="24">
             <a-col :md="6" :sm="24">
               <a-form-item label="销售单号">
               <a-form-item label="销售单号">
-                <a-input id="onlinePayOrderList-salesBillNo" v-model.trim="queryParam.salesBillNo" allowClear placeholder="请输入销售单号"/>
-              </a-form-item>
-            </a-col>
-            <a-col :md="6" :sm="24">
-              <a-form-item label="单据来源">
-                <v-select
-                  style="width: 100%;"
-                  v-model="queryParam.sourceType"
-                  ref="sourceType"
-                  id="onlinePayOrderList-sourceType"
-                  code="SALES_SOURCE"
-                  placeholder="请选择单据来源"
-                  allowClear></v-select>
+                <a-input id="salesManagementList-salesBillNo" v-model.trim="queryParam.salesBillNo" allowClear placeholder="请输入销售单号"/>
               </a-form-item>
               </a-form-item>
             </a-col>
             </a-col>
             <template v-if="advanced">
             <template v-if="advanced">
+              <a-col :md="6" :sm="24">
+                <a-form-item label="业务状态">
+                  <v-select
+                    v-model="queryParam.billStatus"
+                    @change="setIsHomeNav($route.name, null)"
+                    ref="billStatus"
+                    id="salesManagementList-billStatus"
+                    code="SALES_BILL_STATUS"
+                    :notIn="['WAIT_SUBMIT','SUPERIOR_CHANGE']"
+                    placeholder="请选择业务状态"
+                    allowClear></v-select>
+                </a-form-item>
+              </a-col>
               <a-col :md="6" :sm="24">
               <a-col :md="6" :sm="24">
                 <a-form-item label="出库时间">
                 <a-form-item label="出库时间">
-                  <rangeDate id="onlinePayOrderList-outWareTime" ref="outWareRangeDate" v-model="outWareTime" @change="outWareDateChange" />
+                  <rangeDate id="salesManagementList-outWareTime" ref="outWareRangeDate" v-model="outWareTime" @change="outWareDateChange" />
                 </a-form-item>
                 </a-form-item>
               </a-col>
               </a-col>
               <a-col :md="6" :sm="24">
               <a-col :md="6" :sm="24">
@@ -51,54 +52,58 @@
               </a-col>
               </a-col>
               <a-col :md="6" :sm="24">
               <a-col :md="6" :sm="24">
                 <a-form-item label="采购单号">
                 <a-form-item label="采购单号">
-                  <a-input id="onlinePayOrderList-purchaseBillNo" v-model.trim="queryParam.purchaseBillNo" allowClear placeholder="请输入采购单号"/>
+                  <a-input id="salesManagementList-purchaseBillNo" v-model.trim="queryParam.purchaseBillNo" allowClear placeholder="请输入采购单号"/>
                 </a-form-item>
                 </a-form-item>
               </a-col>
               </a-col>
               <a-col :md="6" :sm="24">
               <a-col :md="6" :sm="24">
-                <a-form-item label="务状态">
+                <a-form-item label="务状态">
                   <v-select
                   <v-select
-                    v-model="queryParam.billStatus"
-                    @change="setIsHomeNav($route.name, null)"
-                    ref="billStatus"
-                    id="onlinePayOrderList-billStatus"
-                    code="SALES_BILL_STATUS"
-                    placeholder="请选择业务状态"
-                    allowClear></v-select>
+                    v-model="queryParam.financialStatus"
+                    ref="financialStatus"
+                    id="salesManagementList-financialStatus"
+                    code="FINANCIAL_ONLINE_RECEIVE_STATUS"
+                    placeholder="请选择财务状态"
+                    allowClear></v-select>s
                 </a-form-item>
                 </a-form-item>
               </a-col>
               </a-col>
               <a-col :md="6" :sm="24">
               <a-col :md="6" :sm="24">
                 <a-form-item label="审核时间">
                 <a-form-item label="审核时间">
-                  <rangeDate id="onlinePayOrderList-auditTime" ref="auditRangeDate" v-model="auditTime" @change="auditDateChange" />
+                  <rangeDate id="salesManagementList-auditTime" ref="auditRangeDate" v-model="auditTime" @change="auditDateChange" />
+                </a-form-item>
+              </a-col>
+              <a-col :md="6" :sm="24">
+                <a-form-item label="取消时间">
+                  <rangeDate id="salesManagementList-cancelTime" ref="cancelRangeDate" v-model="cancelTime" @change="cancelDateChange" />
                 </a-form-item>
                 </a-form-item>
               </a-col>
               </a-col>
               <a-col :md="6" :sm="24">
               <a-col :md="6" :sm="24">
                 <a-form-item label="收款方式">
                 <a-form-item label="收款方式">
                   <v-select
                   <v-select
                     code="SETTLE_STYLE"
                     code="SETTLE_STYLE"
-                    id="onlinePayOrderList-settleStyleSn"
+                    id="salesManagementList-settleStyleSn"
                     v-model="queryParam.settleStyleSn"
                     v-model="queryParam.settleStyleSn"
                     allowClear
                     allowClear
                     placeholder="请选择收款方式"
                     placeholder="请选择收款方式"
                   ></v-select>
                   ></v-select>
                 </a-form-item>
                 </a-form-item>
               </a-col>
               </a-col>
-              <a-col :span="6">
-                <a-form-model-item label="铺货出库">
-                  <v-select code="FLAG" id="onlinePayOrderList-distributionFlag" v-model="queryParam.distributionFlag" allowClear placeholder="请选择是否铺货出库"></v-select>
-                </a-form-model-item>
-              </a-col>
-              <a-col :md="6" :sm="24">
-                <a-form-item label="财务状态">
-                  <v-select
-                    v-model="queryParam.financialStatus"
-                    ref="financialStatus"
-                    id="onlinePayOrderList-financialStatus"
-                    code="FINANCIAL_RECEIVE_STATUS"
-                    placeholder="请选择财务状态"
-                    allowClear></v-select>
-                </a-form-item>
-              </a-col>
             </template>
             </template>
+            <a-col :md="6" :sm="24">
+              <a-button id="salesManagementList-search" type="primary" :disabled="disabled" @click="searchForm">查询</a-button>
+              <a-button id="salesManagementList-reset" style="margin-left: 5px" :disabled="disabled" @click="resetSearchForm()">重置</a-button>
+              <a-button
+                type="primary"
+                v-if="$hasPermissions('B_salesExport')"
+                class="button-warning"
+                @click="handleExport"
+                :disabled="disabled"
+                :loading="exportLoading"
+                id="salesManagementList-export">导出</a-button>
+              <a @click="advanced=!advanced" style="margin-left: 5px" id="salesManagementList-advanced">
+                {{ advanced ? '收起' : '展开' }}
+                <a-icon :type="advanced ? 'up' : 'down'"/>
+              </a>
+            </a-col>
             <a-col :span="24" style="display:flex;align-items: center;">
             <a-col :span="24" style="display:flex;align-items: center;">
               <div style="text-align:left;width:50%;">
               <div style="text-align:left;width:50%;">
                 <a-checkbox v-model="isByCustQuery" id="sales-byCustQuery">按客户查询</a-checkbox>
                 <a-checkbox v-model="isByCustQuery" id="sales-byCustQuery">按客户查询</a-checkbox>
@@ -108,7 +113,7 @@
                   </template>
                   </template>
                   <a-icon type="question-circle" />
                   <a-icon type="question-circle" />
                 </a-popover>
                 </a-popover>
-                <a-checkbox id="sales-custQuery" style="margin-left:10px;" v-model="isByCustQuery">包括废弃单</a-checkbox>
+                <a-checkbox id="sales-custQuery" style="margin-left:10px;" v-model="isAbandonOrder" @change="handleAbandonOrder">包括废弃单</a-checkbox>
                 <a-popover placement="right">
                 <a-popover placement="right">
                   <template slot="content">
                   <template slot="content">
                     废弃单:指【已取消】和【审核不通过】状态的订单
                     废弃单:指【已取消】和【审核不通过】状态的订单
@@ -116,22 +121,6 @@
                   <a-icon type="question-circle" />
                   <a-icon type="question-circle" />
                 </a-popover>
                 </a-popover>
               </div>
               </div>
-              <div style="text-align:left;margin-left: -120px;width:50%;">
-                <a-button id="onlinePayOrderList-search" type="primary" :disabled="disabled" @click="searchForm">查询</a-button>
-                <a-button id="onlinePayOrderList-reset" style="margin-left: 5px" :disabled="disabled" @click="resetSearchForm()">重置</a-button>
-                <a-button
-                  type="primary"
-                  v-if="$hasPermissions('B_salesExport')"
-                  class="button-warning"
-                  @click="handleExport"
-                  :disabled="disabled"
-                  :loading="exportLoading"
-                  id="onlinePayOrderList-export">导出</a-button>
-                <a @click="advanced=!advanced" style="margin-left: 5px" id="onlinePayOrderList-advanced">
-                  {{ advanced ? '收起' : '展开' }}
-                  <a-icon :type="advanced ? 'up' : 'down'"/>
-                </a>
-              </div>
             </a-col>
             </a-col>
           </a-row>
           </a-row>
         </a-form>
         </a-form>
@@ -148,13 +137,11 @@
             总款数:<strong>{{ totalData&&(totalData.totalCategory || totalData.totalCategory==0) ? totalData.totalCategory : '--' }}</strong>;
             总款数:<strong>{{ totalData&&(totalData.totalCategory || totalData.totalCategory==0) ? totalData.totalCategory : '--' }}</strong>;
             总数量:<strong>{{ totalData&&(totalData.totalQty || totalData.totalQty==0) ? totalData.totalQty : '--' }}</strong>;
             总数量:<strong>{{ totalData&&(totalData.totalQty || totalData.totalQty==0) ? totalData.totalQty : '--' }}</strong>;
             总售价:<strong>{{ totalData&&(totalData.totalAmount || totalData.totalAmount==0) ? toThousands(totalData.totalAmount) : '--' }}</strong>;
             总售价:<strong>{{ totalData&&(totalData.totalAmount || totalData.totalAmount==0) ? toThousands(totalData.totalAmount) : '--' }}</strong>;
-            已收款金额:<strong>{{ totalData&&(totalData.discountAmount || totalData.discountAmount==0) ? toThousands(totalData.discountAmount) : '--' }}</strong>;
-            退款中金额:<strong>{{ totalData&&(totalData.discountedAmount || totalData.discountedAmount==0) ? toThousands(totalData.discountedAmount) : '--' }}</strong>;
-            已退款金额:<strong>{{ totalData&&(totalData.discountedAmount || totalData.discountedAmount==0) ? toThousands(totalData.discountedAmount) : '--' }}</strong>;
+            已收款金额:<strong>{{ totalData&&(totalData.paymentAmount || totalData.paymentAmount==0) ? toThousands(totalData.paymentAmount) : '--' }}</strong>;
+            退款中金额:<strong>{{ totalData&&(totalData.refundingAmount || totalData.refundingAmount==0) ? toThousands(totalData.refundingAmount) : '--' }}</strong>;
+            已退款金额:<strong>{{ totalData&&(totalData.refundedAmount || totalData.refundedAmount==0) ? toThousands(totalData.refundedAmount) : '--' }}</strong>;
           </div>
           </div>
           <div class="action-buttons">
           <div class="action-buttons">
-            <a-button id="onlinePayOrderList-add0" type="primary" class="button-error" v-if="$hasPermissions('B_salesNews')" @click="handleAdd(0)"><a-icon type="plus" /> 新增(零售)</a-button>
-            <a-button id="onlinePayOrderList-add1" type="primary" class="button-error" v-if="$hasPermissions('B_salesNews')" @click="handleAdd(1)"><a-icon type="plus" /> 新增(铺货)</a-button>
             <hideCellMenus placeholder="显示" :defHiddenKes="colsArr" v-model="showCell"></hideCellMenus>
             <hideCellMenus placeholder="显示" :defHiddenKes="colsArr" v-model="showCell"></hideCellMenus>
           </div>
           </div>
         </div>
         </div>
@@ -173,10 +160,15 @@
           bordered>
           bordered>
           <!-- 销售单号 -->
           <!-- 销售单号 -->
           <template slot="salesBillNo" slot-scope="text, record">
           <template slot="salesBillNo" slot-scope="text, record">
-            <span class="table-td-link" :id="'onlinePayOrderList-detail-'+record.id" v-if="$hasPermissions('B_salesDetail')" @click="handleDetail(record)">{{ record.salesBillNo }}</span>
+            <span class="table-td-link" :id="'salesManagementList-detail-'+record.id" v-if="$hasPermissions('B_salesDetail')" @click="handleDetail(record)">{{ record.salesBillNo }}</span>
             <span v-else>{{ record.salesBillNo }}</span>
             <span v-else>{{ record.salesBillNo }}</span>
             <a-badge count="改" :number-style="{ zoom:'80%',marginLeft:'5px' }" v-if="record.billStatus=='SUPERIOR_CHANGE'"></a-badge>
             <a-badge count="改" :number-style="{ zoom:'80%',marginLeft:'5px' }" v-if="record.billStatus=='SUPERIOR_CHANGE'"></a-badge>
           </template>
           </template>
+          <!-- 取消时间 -->
+          <template slot="cancelTime" slot-scope="text, record">
+            <span v-if="record.billStatus==='AUDIT_REJECT'">{{ record.auditDate }}</span>
+            <span v-else>--</span>
+          </template>
           <!-- 审核icon -->
           <!-- 审核icon -->
           <template slot="audit" slot-scope="text, record">
           <template slot="audit" slot-scope="text, record">
             <stateIcon :title="record.billStatusDictValue" v-if="record.billStatus!='AUDIT_REJECT'" :state="record.billStatus == 'WAIT_OUT_WAREHOUSE'||record.billStatus == 'FINISH'?'1':'2'"></stateIcon>
             <stateIcon :title="record.billStatusDictValue" v-if="record.billStatus!='AUDIT_REJECT'" :state="record.billStatus == 'WAIT_OUT_WAREHOUSE'||record.billStatus == 'FINISH'?'1':'2'"></stateIcon>
@@ -192,14 +184,13 @@
           </template>
           </template>
           <!-- 收款icon -->
           <!-- 收款icon -->
           <template slot="financial" slot-scope="text, record">
           <template slot="financial" slot-scope="text, record">
-            <stateIcon :title="record.financialStatusDictValue" :state="record.financialStatus == 'FINISH'?'1':'2'"></stateIcon>
+            <stateIcon :title="record.financialStatusDictValue" :state="record.financialStatus == 'REFUNDING'?'3':'4'"></stateIcon>
           </template>
           </template>
           <!-- 操作按钮 -->
           <!-- 操作按钮 -->
-          <!-- sourceType SALES自建   CHILD_PURCHASE下级创建  DEALER_PURCHASE省仓订单  XPRH_PURCHASE货架促销  TEMPORARY_DISPATCHING数字货架 -->
           <!-- billStatus  WAIT_SUBMIT待提交   WAIT_AUDIT待审核    AUDIT_REJECT审核不通过  WAIT_OUT_WAREHOUSE待出库   FINISH已完结  SUPERIOR_CHANGE上级改单  CANCEL已取消 -->
           <!-- billStatus  WAIT_SUBMIT待提交   WAIT_AUDIT待审核    AUDIT_REJECT审核不通过  WAIT_OUT_WAREHOUSE待出库   FINISH已完结  SUPERIOR_CHANGE上级改单  CANCEL已取消 -->
           <template slot="action" slot-scope="text, record">
           <template slot="action" slot-scope="text, record">
             <a-button
             <a-button
-              :id="'onlinePayOrderList-audit-'+record.id"
+              :id="'salesManagementList-audit-'+record.id"
               size="small"
               size="small"
               type="link"
               type="link"
               class="button-primary"
               class="button-primary"
@@ -207,19 +198,17 @@
               @click="handleEexamine(record)"
               @click="handleEexamine(record)"
             >审核</a-button>
             >审核</a-button>
             <a-button
             <a-button
-              :id="'onlinePayOrderList-outStock-'+record.id"
+              :id="'salesManagementList-outStock-'+record.id"
               size="small"
               size="small"
               type="link"
               type="link"
               v-if="record.billStatus == 'WAIT_OUT_WAREHOUSE' && $hasPermissions('B_salesStockOut')"
               v-if="record.billStatus == 'WAIT_OUT_WAREHOUSE' && $hasPermissions('B_salesStockOut')"
               class="button-primary"
               class="button-primary"
               @click="handleSend(record)"
               @click="handleSend(record)"
             >出库</a-button>
             >出库</a-button>
-            <span v-if="false">--</span>
+            <span v-if="record.billStatus != 'WAIT_AUDIT' && record.billStatus != 'WAIT_OUT_WAREHOUSE'">--</span>
           </template>
           </template>
         </s-table>
         </s-table>
       </a-spin>
       </a-spin>
-      <!-- 选择客户弹框 -->
-      <choose-custom-modal :show="openModal" :distributionFlag="distributionFlag" @ok="chooseCustomOk" @cancel="openModal=false"></choose-custom-modal>
       <!-- 审核 -->
       <!-- 审核 -->
       <auditModal :openModal="visibleAudit" :spinning="spinningAudit" @close="visibleAudit=false" @ok="auditOrder('WAIT_OUT_WAREHOUSE')" @fail="auditOrder('AUDIT_REJECT')" />
       <auditModal :openModal="visibleAudit" :spinning="spinningAudit" @close="visibleAudit=false" @ok="auditOrder('WAIT_OUT_WAREHOUSE')" @fail="auditOrder('AUDIT_REJECT')" />
     </a-card>
     </a-card>
@@ -229,19 +218,19 @@
 <script>
 <script>
 import { commonMixin } from '@/utils/mixin'
 import { commonMixin } from '@/utils/mixin'
 import getDate from '@/libs/getDate.js'
 import getDate from '@/libs/getDate.js'
+import { downloadExcel } from '@/libs/JGPrint.js'
+// 组件
 import { STable, VSelect } from '@/components'
 import { STable, VSelect } from '@/components'
-// import chooseCustomModal from './chooseCustomModal.vue'
 import auditModal from '@/views/common/auditModal.vue'
 import auditModal from '@/views/common/auditModal.vue'
 import rangeDate from '@/views/common/rangeDate.vue'
 import rangeDate from '@/views/common/rangeDate.vue'
 import custList from '@/views/common/custList.vue'
 import custList from '@/views/common/custList.vue'
-import { downloadExcel } from '@/libs/JGPrint.js'
 import stateIcon from '@/views/common/stateIcon'
 import stateIcon from '@/views/common/stateIcon'
 import hideCellMenus from '@/views/common/hideCellMenus'
 import hideCellMenus from '@/views/common/hideCellMenus'
 // 接口
 // 接口
-import { salesList, salesDel, salesWriteAudit, salesWriteStockOut, salesCount, salesExport } from '@/api/sales'
+import { salesList, salesWriteAudit, salesWriteStockOut, salesCount, salesExport } from '@/api/sales'
 import moment from 'moment'
 import moment from 'moment'
 export default {
 export default {
-  name: 'OnlinePayOrder',
+  name: 'SalesList',
   components: { STable, VSelect, rangeDate, auditModal, custList, stateIcon, hideCellMenus },
   components: { STable, VSelect, rangeDate, auditModal, custList, stateIcon, hideCellMenus },
   mixins: [commonMixin],
   mixins: [commonMixin],
   data () {
   data () {
@@ -251,17 +240,14 @@ export default {
       advanced: true, // 高级搜索 展开/关闭
       advanced: true, // 高级搜索 展开/关闭
       disabled: false, //  查询、重置按钮是否可操作
       disabled: false, //  查询、重置按钮是否可操作
       exportLoading: false, // 导出loading
       exportLoading: false, // 导出loading
-      openModal: false, // 选择客户弹框是否显示
       isByCustQuery: false, // 是否按客户查询
       isByCustQuery: false, // 是否按客户查询
-      showKhgx: false, // 显示客户关系
-      showDiscount: false, // 显示折后总售价
-      showCell: false, // 显示下拉选项
       time: [ // 创建时间
       time: [ // 创建时间
         getDate.getMonthDays(3).starttime,
         getDate.getMonthDays(3).starttime,
         getDate.getMonthDays(3).endtime
         getDate.getMonthDays(3).endtime
       ],
       ],
       auditTime: [], // 审核时间
       auditTime: [], // 审核时间
       outWareTime: [], // 出库时间
       outWareTime: [], // 出库时间
+      cancelTime: [], // 取消时间
       // 查询参数
       // 查询参数
       queryParam: {
       queryParam: {
         beginDate: getDate.getMonthDays(3).starttime, // 开始创建时间
         beginDate: getDate.getMonthDays(3).starttime, // 开始创建时间
@@ -278,9 +264,10 @@ export default {
         settleStyleSn: undefined, //  收款方式
         settleStyleSn: undefined, //  收款方式
         billStatus: undefined, //  业务状态
         billStatus: undefined, //  业务状态
         financialStatus: undefined, //  财务状态
         financialStatus: undefined, //  财务状态
-        sourceType: undefined, // 单据来源
-        distributionFlag: undefined, // 铺货出库
-        buyerRelationType: undefined // 客户关系
+        buyerRelationType: undefined, // 客户关系
+        onlinePayFlag: 1, // 线上订单
+        cancelStartDate: undefined,
+        cancelEndDate: undefined
       },
       },
       totalData: { // 统计数据
       totalData: { // 统计数据
         totalAmount: 0, // 总销价
         totalAmount: 0, // 总销价
@@ -288,11 +275,12 @@ export default {
         totalQty: 0, // 总数量
         totalQty: 0, // 总数量
         totalRecord: 0 // 总条数
         totalRecord: 0 // 总条数
       },
       },
-      selType: '0', // 0零售 1铺货
       // 加载数据方法 必须为 Promise 对象
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
       loadData: parameter => {
         this.disabled = true
         this.disabled = true
         this.spinning = true
         this.spinning = true
+        // 是否包含废弃单
+        this.queryParam.disuseStateList = this.isAbandonOrder ? ['CANCEL', 'AUDIT_REJECT '] : undefined
         // 查询总计
         // 查询总计
         salesCount(Object.assign(parameter, this.queryParam)).then(res => {
         salesCount(Object.assign(parameter, this.queryParam)).then(res => {
           this.totalData = res.data
           this.totalData = res.data
@@ -315,8 +303,8 @@ export default {
       visibleAudit: false, // 审核弹框
       visibleAudit: false, // 审核弹框
       auditInfo: null, // 审核信息
       auditInfo: null, // 审核信息
       spinningAudit: false, // 审核操作loading
       spinningAudit: false, // 审核操作loading
-      distributionFlag: '0', // 是否铺货
-      colsArr: [
+      isAbandonOrder: false, // 包含废弃单
+      colsArr: [// 需要显示的列
         {
         {
           title: '客户关系',
           title: '客户关系',
           key: 'buyerRelationTypeDictValue',
           key: 'buyerRelationTypeDictValue',
@@ -325,17 +313,18 @@ export default {
         },
         },
         {
         {
           title: '取消时间',
           title: '取消时间',
-          key: 'totalUnpushedQty',
+          key: 'cancelTime',
           disabled: false,
           disabled: false,
           checked: false
           checked: false
         },
         },
         {
         {
           title: '退款时间',
           title: '退款时间',
-          key: 'totalUnpushedAmount',
+          key: 'refundData',
           disabled: false,
           disabled: false,
           checked: false
           checked: false
         }
         }
-      ]
+      ],
+      showCell: []// 已选要显示的列
     }
     }
   },
   },
   computed: {
   computed: {
@@ -344,40 +333,32 @@ export default {
       const arr = [
       const arr = [
         { title: '序号', dataIndex: 'no', align: 'center', width: '4%' },
         { title: '序号', dataIndex: 'no', align: 'center', width: '4%' },
         { title: '来源', dataIndex: 'sourceTypeDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '来源', dataIndex: 'sourceTypeDictValue', width: '6%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '销售单号', scopedSlots: { customRender: 'salesBillNo' }, width: this.showDiscount ? '6%' : '9%', align: 'center' },
-        { title: '客户名称', dataIndex: 'buyerNameCurrent', align: 'center', width: this.showDiscount ? '12%' : '15%', customRender: function (text) { return text || '--' } },
-        // { title: '客户关系', dataIndex: 'buyerRelationTypeDictValue', align: 'center', width: '9%', customRender: function (text) { return text || '--' } },
+        { title: '销售单号', scopedSlots: { customRender: 'salesBillNo' }, width: '6%', align: 'center' },
+        { title: '客户名称', dataIndex: 'buyerNameCurrent', align: 'center', width: '10%', customRender: function (text) { return text || '--' }, ellipsis: true },
+        { title: '客户关系', dataIndex: 'buyerRelationTypeDictValue', align: 'center', width: '8%', customRender: function (text) { return text || '--' } },
         { title: '总款数', dataIndex: 'totalCategory', align: 'center', width: '5%', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '总款数', dataIndex: 'totalCategory', align: 'center', width: '5%', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '总数量', dataIndex: 'totalQty', align: 'center', width: '5%', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '总数量', dataIndex: 'totalQty', align: 'center', width: '5%', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '总售价', dataIndex: 'totalAmount', align: 'right', width: '5%', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
         { title: '总售价', dataIndex: 'totalAmount', align: 'right', width: '5%', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
-        // { title: '折扣金额', dataIndex: 'discountAmount', align: 'right', width: '5%', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
-        // { title: '折后总售价', dataIndex: 'discountedAmount', align: 'right', width: '5%', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } },
         { title: '收款方式', dataIndex: 'settleStyleSnDictValue', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '收款方式', dataIndex: 'settleStyleSnDictValue', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '创建时间', dataIndex: 'createDate', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '创建时间', dataIndex: 'createDate', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '审核时间', dataIndex: 'auditDate', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '审核时间', dataIndex: 'auditDate', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '取消时间', dataIndex: 'auditDate1', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '退款时间', dataIndex: 'auditDate2', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '取消时间', dataIndex: 'cancelTime', width: '8%', align: 'center', scopedSlots: { customRender: 'cancelTime' } },
+        { title: '退款时间', dataIndex: 'refundData', width: '8%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '业务状态', dataIndex: 'billStatusDictValue', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
         { title: '业务状态', dataIndex: 'billStatusDictValue', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '审核', scopedSlots: { customRender: 'audit' }, width: '2%', align: 'center' },
-        { title: '急件', scopedSlots: { customRender: 'oosFlag' }, width: '2%', align: 'center' },
-        { title: '出库', scopedSlots: { customRender: 'waitOut' }, width: '2%', align: 'center' },
-        { title: '收款', scopedSlots: { customRender: 'financial' }, width: '2%', align: 'center' },
-        // { title: '财务状态', dataIndex: 'financialStatusDictValue', width: '5%', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '操作', scopedSlots: { customRender: 'action' }, width: '8%', align: 'center' }
+        { title: '审核', scopedSlots: { customRender: 'audit' }, width: '3%', align: 'center' },
+        { title: '急件', scopedSlots: { customRender: 'oosFlag' }, width: '3%', align: 'center' },
+        { title: '出库', scopedSlots: { customRender: 'waitOut' }, width: '3%', align: 'center' },
+        { title: '收款', scopedSlots: { customRender: 'financial' }, width: '3%', align: 'center' },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: '6%', align: 'center' }
       ]
       ]
-      if (this.showKhgx) {
-        arr.splice(4, 0, { title: '客户关系', dataIndex: 'buyerRelationTypeDictValue', align: 'center', width: '6%', customRender: function (text) { return text || '--' } })
-      }
-      // 显示折扣
-      if (this.showDiscount) {
-        const dx = this.showKhgx ? 1 : 0
-        arr.splice(7 + dx, 0, { title: '折扣金额', dataIndex: 'discountAmount', align: 'right', width: '5%', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
-        arr.splice(8 + dx, 0, { title: '折后总售价', dataIndex: 'discountedAmount', align: 'right', width: '5%', customRender: function (text) { return ((text || text == 0) ? _this.toThousands(text) : '--') } })
-      }
-      return arr
+      return arr.filter(item => !this.showCell.includes(item.dataIndex))
     }
     }
   },
   },
   methods: {
   methods: {
+    // 包含废弃单
+    handleAbandonOrder () {
+      this.$refs.table.refresh()
+    },
     // 选择创建时间
     // 选择创建时间
     dateChange (date) {
     dateChange (date) {
       this.queryParam.beginDate = date[0]
       this.queryParam.beginDate = date[0]
@@ -395,6 +376,12 @@ export default {
       this.queryParam.outWarehouseBeginDate = date[0]
       this.queryParam.outWarehouseBeginDate = date[0]
       this.queryParam.outWarehouseEndDate = date[1]
       this.queryParam.outWarehouseEndDate = date[1]
     },
     },
+    // 取消时间
+    cancelDateChange (date) {
+      this.cancelTime = date
+      this.queryParam.cancelStartDate = date[0]
+      this.queryParam.cancelEndDate = date[1]
+    },
     // 选择客户
     // 选择客户
     custChange (v, row) {
     custChange (v, row) {
       console.log(v, row)
       console.log(v, row)
@@ -406,11 +393,6 @@ export default {
         this.queryParam.buyerSn = undefined
         this.queryParam.buyerSn = undefined
       }
       }
     },
     },
-    // 打开新增弹框
-    handleAdd (flag) {
-      this.openModal = true
-      this.distributionFlag = flag
-    },
     //  打开审核弹框
     //  打开审核弹框
     handleEexamine (row) {
     handleEexamine (row) {
       this.auditInfo = row
       this.auditInfo = row
@@ -462,40 +444,10 @@ export default {
     handleDetail (row) {
     handleDetail (row) {
       this.$router.push({ name: 'onlinePayOrderDetail', params: { sn: row.salesBillSn } })
       this.$router.push({ name: 'onlinePayOrderDetail', params: { sn: row.salesBillSn } })
     },
     },
-    // 编辑
-    handleEdit (row) {
-      this.$router.push({ name: 'salesNewEdit', params: { id: row.id, sn: row.salesBillSn, priceType: row.priceType } })
-    },
     // 选择客户成功
     // 选择客户成功
     chooseCustomOk (data) {
     chooseCustomOk (data) {
       this.$router.push({ name: 'salesNewAdd', params: { id: data.id, sn: data.salesBillSn, priceType: data.priceType } })
       this.$router.push({ name: 'salesNewAdd', params: { id: data.id, sn: data.salesBillSn, priceType: data.priceType } })
     },
     },
-    // 删除
-    handleDel (row, type) {
-      const _this = this
-      let content = '确认要删除吗?'
-      if (type == 'cancel') {
-        content = '确认要取消吗?'
-      }
-      this.$confirm({
-        title: '提示',
-        content: <div><div style='font-size:16px;margin-bottom:10px;'>{content}</div><div>销售单号:{row.salesBillNo}</div><div>客户名称:{row.buyerNameCurrent}</div></div>,
-        centered: true,
-        closable: true,
-        onOk () {
-          _this.spinning = true
-          salesDel({ id: row.id, mainFlag: 1 }).then(res => {
-            if (res.status == 200) {
-              _this.$message.success(res.message)
-              _this.$refs.table.refresh()
-              _this.spinning = false
-            } else {
-              _this.spinning = false
-            }
-          })
-        }
-      })
-    },
     // 查询列表
     // 查询列表
     searchForm (flag) {
     searchForm (flag) {
       // 是否按客户查询
       // 是否按客户查询
@@ -534,9 +486,11 @@ export default {
       this.queryParam.outWarehouseEndDate = ''
       this.queryParam.outWarehouseEndDate = ''
       this.auditTime = []
       this.auditTime = []
       this.outWareTime = []
       this.outWareTime = []
+      this.cancelTime = []
       if (this.advanced) {
       if (this.advanced) {
         this.$refs.auditRangeDate.resetDate('')
         this.$refs.auditRangeDate.resetDate('')
         this.$refs.outWareRangeDate.resetDate('')
         this.$refs.outWareRangeDate.resetDate('')
+        this.$refs.cancelRangeDate.resetDate('')
       }
       }
       this.queryParam.buyerNameCurrent = undefined
       this.queryParam.buyerNameCurrent = undefined
       this.queryParam.buyerSn = undefined
       this.queryParam.buyerSn = undefined
@@ -546,9 +500,10 @@ export default {
       this.queryParam.settleStyleSn = undefined
       this.queryParam.settleStyleSn = undefined
       this.queryParam.billStatus = undefined
       this.queryParam.billStatus = undefined
       this.queryParam.financialStatus = undefined
       this.queryParam.financialStatus = undefined
-      this.queryParam.sourceType = undefined
-      this.queryParam.distributionFlag = undefined
       this.queryParam.buyerRelationType = undefined
       this.queryParam.buyerRelationType = undefined
+      this.queryParam.cancelStartDate = undefined
+      this.queryParam.cancelEndDate = undefined
+      this.queryParam.onlinePayFlag = 1
 
 
       this.$refs.custList.resetForm()
       this.$refs.custList.resetForm()
       if (!flag) {
       if (!flag) {
@@ -560,7 +515,6 @@ export default {
     handleExport () {
     handleExport () {
       const _this = this
       const _this = this
       const params = this.queryParam
       const params = this.queryParam
-      params.showDiscountAmountFlag = this.showDiscount ? 1 : 0
       this.exportLoading = true
       this.exportLoading = true
       _this.spinning = true
       _this.spinning = true
       salesExport(params).then(res => {
       salesExport(params).then(res => {
@@ -577,7 +531,7 @@ export default {
           })
           })
           reader.readAsText(res)
           reader.readAsText(res)
         } else {
         } else {
-          downloadExcel(res, '销售线上订单')
+          downloadExcel(res, '销售列表')
         }
         }
       })
       })
     },
     },
@@ -601,11 +555,6 @@ export default {
 
 
       // 从首页进入,判断式新建还式待办查询
       // 从首页进入,判断式新建还式待办查询
       if (isHomeNav) {
       if (isHomeNav) {
-        // 新增
-        if (isHomeNav.type == 'new') {
-          this.resetSearchForm()
-          this.openModal = true
-        }
         // 待办
         // 待办
         if (isHomeNav.type == 'todo') {
         if (isHomeNav.type == 'todo') {
           this.resetData(true)
           this.resetData(true)

+ 2 - 2
src/views/salesManagement/salesQuery/detail.vue

@@ -44,8 +44,8 @@
               <a-descriptions-item label="下级采购单号" v-if="detailData&&detailData.sourceType=='PURCHASE'">{{ detailData&&detailData.purchaseBillNo || '--' }}</a-descriptions-item>
               <a-descriptions-item label="下级采购单号" v-if="detailData&&detailData.sourceType=='PURCHASE'">{{ detailData&&detailData.purchaseBillNo || '--' }}</a-descriptions-item>
               <a-descriptions-item label="业务状态">{{ detailData&&detailData.billStatusDictValue || '--' }}</a-descriptions-item>
               <a-descriptions-item label="业务状态">{{ detailData&&detailData.billStatusDictValue || '--' }}</a-descriptions-item>
               <a-descriptions-item label="财务状态">{{ detailData&&detailData.financialStatusDictValue || '--' }}</a-descriptions-item>
               <a-descriptions-item label="财务状态">{{ detailData&&detailData.financialStatusDictValue || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="采购单号" v-if="detailData&&detailData.sourceType!='SALES'&&detailData.sourceType!='TRANSFER_ORDER'">{{ detailData.purchaseBillNo || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="收货状态" v-if="detailData&&detailData.sourceType=='XPRH_PURCHASE'&&detailData.billStatus=='FINISH'">{{ detailData.purchaseBillNo || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="采购单号" v-if="detailData&&detailData.sourceType!='SALES'">{{ detailData.purchaseBillNo || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="收货状态" v-if="detailData&&detailData.sourceType!='XPRH_PURCHASE'&&detailData.sourceType!='SALES'&&detailData.billStatus=='FINISH'">{{ detailData.receiptStatusDictValue || '--' }}</a-descriptions-item>
             </a-descriptions>
             </a-descriptions>
           </a-collapse-panel>
           </a-collapse-panel>
         </a-collapse>
         </a-collapse>

+ 8 - 2
src/views/salesManagement/salesQuery/list.vue

@@ -132,7 +132,7 @@
             </template>
             </template>
             <a-icon type="question-circle" />
             <a-icon type="question-circle" />
           </a-popover>
           </a-popover>
-          <a-checkbox id="salesManagementList-custQuery" style="margin-left:10px;" v-model="isByCustQuery">包括废弃单</a-checkbox>
+          <a-checkbox id="salesManagementList-custQuery" style="margin-left:10px;" v-model="isAbandonOrder" >包括废弃单</a-checkbox>
           <a-popover placement="right">
           <a-popover placement="right">
             <template slot="content">
             <template slot="content">
               废弃单:指【已取消】状态的订单
               废弃单:指【已取消】状态的订单
@@ -341,6 +341,8 @@ export default {
       loadData: parameter => {
       loadData: parameter => {
         this.disabled = true
         this.disabled = true
         this.spinning = true
         this.spinning = true
+        // 是否包含废弃单
+        this.queryParam.disuseStateList = this.isAbandonOrder ? ['CANCEL'] : undefined
         // 查询总计
         // 查询总计
         salesCount(Object.assign(parameter, this.queryParam)).then(res => {
         salesCount(Object.assign(parameter, this.queryParam)).then(res => {
           this.totalData = res.data
           this.totalData = res.data
@@ -363,7 +365,8 @@ export default {
       visibleAudit: false, // 审核弹框
       visibleAudit: false, // 审核弹框
       auditInfo: null, // 当前审核的数据
       auditInfo: null, // 当前审核的数据
       spinningAudit: false, // 审核loading
       spinningAudit: false, // 审核loading
-      distributionFlag: '0' //  是否铺货出库
+      distributionFlag: '0', //  是否铺货出库
+      isAbandonOrder: false// 包含废弃单
     }
     }
   },
   },
   computed: {
   computed: {
@@ -659,6 +662,9 @@ export default {
       if (!newValue) {
       if (!newValue) {
         this.resetSearchForm()
         this.resetSearchForm()
       }
       }
+    },
+    isAbandonOrder (newVal, oldVal) {
+      this.resetSearchForm()
     }
     }
   },
   },
   activated () {
   activated () {

+ 2 - 2
src/views/salesManagement/salesQueryNew/detail.vue

@@ -54,8 +54,8 @@
             <a-descriptions-item label="下级采购单号" v-if="detailData&&detailData.sourceType=='PURCHASE'">{{ detailData&&detailData.purchaseBillNo || '--' }}</a-descriptions-item>
             <a-descriptions-item label="下级采购单号" v-if="detailData&&detailData.sourceType=='PURCHASE'">{{ detailData&&detailData.purchaseBillNo || '--' }}</a-descriptions-item>
             <a-descriptions-item label="业务状态">{{ detailData&&detailData.billStatusDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="业务状态">{{ detailData&&detailData.billStatusDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="财务状态">{{ detailData&&detailData.financialStatusDictValue || '--' }}</a-descriptions-item>
             <a-descriptions-item label="财务状态">{{ detailData&&detailData.financialStatusDictValue || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="采购单号" v-if="detailData&&detailData.sourceType!='SALES'&&detailData.sourceType!='TRANSFER_ORDER'">{{ detailData.purchaseBillNo || '--' }}</a-descriptions-item>
-            <a-descriptions-item label="收货状态" v-if="detailData&&detailData.sourceType=='XPRH_PURCHASE'&&detailData.billStatus=='FINISH'">{{ detailData.purchaseBillNo || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="采购单号" v-if="detailData&&detailData.sourceType!='SALES'">{{ detailData.purchaseBillNo || '--' }}</a-descriptions-item>
+            <a-descriptions-item label="收货状态" v-if="detailData&&detailData.sourceType!='XPRH_PURCHASE'&&detailData.sourceType!='SALES'&&detailData.billStatus=='FINISH'">{{ detailData.receiptStatusDictValue || '--' }}</a-descriptions-item>
           </a-descriptions>
           </a-descriptions>
         </a-card>
         </a-card>
         <a-card size="small" :bordered="false" class="pages-wrap">
         <a-card size="small" :bordered="false" class="pages-wrap">

+ 9 - 2
src/views/salesManagement/salesQueryNew/list.vue

@@ -108,7 +108,7 @@
                   </template>
                   </template>
                   <a-icon type="question-circle" />
                   <a-icon type="question-circle" />
                 </a-popover>
                 </a-popover>
-                <a-checkbox id="sales-custQuery" style="margin-left:10px;" v-model="isByCustQuery">包括废弃单</a-checkbox>
+                <a-checkbox id="sales-custQuery" style="margin-left:10px;" v-model="isAbandonOrder" @change="handleAbandonOrder">包括废弃单</a-checkbox>
                 <a-popover placement="right">
                 <a-popover placement="right">
                   <template slot="content">
                   <template slot="content">
                     废弃单:指【已取消】状态的订单
                     废弃单:指【已取消】状态的订单
@@ -345,6 +345,8 @@ export default {
       loadData: parameter => {
       loadData: parameter => {
         this.disabled = true
         this.disabled = true
         this.spinning = true
         this.spinning = true
+        // 是否包含废弃单
+        this.queryParam.disuseStateList = this.isAbandonOrder ? ['CANCEL'] : undefined
         // 查询总计
         // 查询总计
         salesCount(Object.assign(parameter, this.queryParam)).then(res => {
         salesCount(Object.assign(parameter, this.queryParam)).then(res => {
           this.totalData = res.data
           this.totalData = res.data
@@ -367,7 +369,8 @@ export default {
       visibleAudit: false, // 审核弹框
       visibleAudit: false, // 审核弹框
       auditInfo: null, // 审核信息
       auditInfo: null, // 审核信息
       spinningAudit: false, // 审核操作loading
       spinningAudit: false, // 审核操作loading
-      distributionFlag: '0' // 是否铺货
+      distributionFlag: '0', // 是否铺货
+      isAbandonOrder: false// 包含废弃单
     }
     }
   },
   },
   computed: {
   computed: {
@@ -408,6 +411,10 @@ export default {
     }
     }
   },
   },
   methods: {
   methods: {
+    // 包含废弃单
+    handleAbandonOrder () {
+      this.$refs.table.refresh()
+    },
     // 选择创建时间
     // 选择创建时间
     dateChange (date) {
     dateChange (date) {
       this.queryParam.beginDate = date[0]
       this.queryParam.beginDate = date[0]