Browse Source

Merge branch 'feat-two' into feature/two-bug

chenqilong 2 năm trước cách đây
mục cha
commit
8f4e2e5697

+ 7 - 0
src/api/sales.js

@@ -147,6 +147,13 @@ export function setSendRevoke(params) {
     params
   })
 }
+export function sendRefundRevoke(params) {
+  return request({
+    url: '/customer/frontOrder/sendRefundRevoke',
+    method: 'post',
+    params
+  })
+}
 
 
 

+ 16 - 0
src/api/transferOrder.js

@@ -55,3 +55,19 @@ export function invoiceCustomerTransfer(data) {
   })
 }
 
+export function setNeExamine(data) {
+  return request({
+    url: '/customer/transfer/NeExamine',
+    method: 'post',
+    params: data
+  })
+}
+
+export function dletransferDelete(data) {
+  return request({
+    url: '/customer/transfer/delete',
+    method: 'post',
+    params: data
+  })
+}
+

+ 6 - 2
src/components/LogisticsTabs/index.vue

@@ -3,11 +3,11 @@
     <div style="margin: 20px 0">
       <el-radio-group v-model="curTarget" size="small" @change="handleChange">
         <template v-for="(item, index) in tabsList">
-          <el-radio-button v-if="item.show" :key="index" :label="item.value">{{ item.label }}</el-radio-button>
+          <el-radio-button v-if="item.show && returnShow" :key="index" :label="item.value">{{ item.label }}</el-radio-button>
         </template>
       </el-radio-group>
     </div>
-    <el-card v-if="curTarget === 1 && tabsList[curTarget - 1].show">
+    <el-card v-if="curTarget === 1 && tabsList[curTarget - 1].show && returnShow">
       <div slot="header">
         <span>物流信息</span>
       </div>
@@ -72,6 +72,10 @@ export default {
     detailsId: {
       type: String,
       default: null
+    },
+    returnShow: {
+      type: Boolean,
+      default: true
     }
   },
   data() {

+ 2 - 2
src/components/ReturnSalesHeader/ReturnSalesHeader.vue

@@ -46,7 +46,7 @@
         </el-col>
         <el-col :span="details.id?8:24" class="item">
           <div class="label">发货仓库名称</div>
-          <div class="value">{{ storeObj[details.stockType] || '' }}</div>
+          <div class="value">{{storeObj[details.stockType]}}</div>
         </el-col>
         <el-col :span="24" class="item">
           <div class="label">退货备注</div>
@@ -71,7 +71,7 @@ export default {
   data() {
     return {
       storeObj: {
-        1: '前置仓', 2: '商家仓'
+        1: '嘉贤前置仓', 2: '商家自提仓'
       }
     }
   },

+ 1 - 0
src/components/SalesDialog/SalesDialog.vue

@@ -7,6 +7,7 @@
         :get-list="getList"
         :table-attributes="tableAttributes"
         :table-events="tableEvents"
+        :replace-or-not-map="false"
       />
       <span slot="footer" class="dialog-footer">
         <el-button size="mini" @click="$parent.dialogVisible = false">取 消</el-button>

+ 117 - 0
src/views/delayRecord/delayRecordForm.vue

@@ -0,0 +1,117 @@
+<template>
+  <div>
+    <div>
+      <h4>政策延期</h4>
+      <el-divider />
+      <el-row :gutter="20">
+        <el-col :span="2">延期方式</el-col>
+        <el-col :span="3">  <el-radio v-model="value" :label="1">按政策延期</el-radio>
+        </el-col>
+      </el-row>
+    </div>
+    <div>
+      <h4>政策</h4>
+      <el-divider />
+      <zj-table
+        :table-attributes="tableAttributes"
+        :is-drop="true"
+        :columns="columns"
+        :table-data="policyData"
+      />
+    </div>
+    <div style="margin: 20px 0;">
+      <el-button type="primary" size="mini" @click="">提交</el-button>
+      <el-button type="primary" size="mini" @click="">审核</el-button>
+    </div>
+  </div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      value: 1,
+      policyData: [],
+      tableAttributes: {}
+    }
+  },
+  computed: {
+    columns() {
+      return [
+        {
+          columnAttributes: {
+            label: '销售政策编码',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '销售政策名称',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '销售政策类型',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '生效日期',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '失效日期',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '延期日期',
+            prop: 'materialName'
+          },
+          render: (h, { column, row, index }) => {
+            return <el-date-picker
+              value={row.date}
+              onInput={e => { row.date = e }}
+              type='datetime'
+              default-time='00:00:00'
+              value-format='yyyy-MM-dd HH:mm:ss'
+              placeholder='选择日期'>
+            </el-date-picker>
+          }
+        },
+        {
+          columnAttributes: {
+            label: '操作',
+            prop: ''
+          },
+          render: (h, { column, row, index }) => {
+            return (
+              <div>
+                <el-button
+                  type='text'
+                  size='default'
+                  onClick={() => {
+
+                  }}
+                >
+                      删除
+                </el-button>
+              </div>
+            )
+          }
+        }
+      ]
+    }
+  }
+}
+</script>
+
+  <style lang="scss" scoped>
+
+  </style>
+

+ 103 - 0
src/views/delayRecord/delayRecordList.vue

@@ -0,0 +1,103 @@
+<template>
+  <template-page
+    ref="pageRef"
+    :get-list="getList"
+    :export-list="exportList"
+    :operation="operation()"
+    :options-evens-group="optionsEvensGroup"
+    :column-parsing="columnParsing"
+  >
+    <popu v-if="visible">
+      <el-page-header slot="head" content="政策延期" @back="handleClose" />
+      <delay-record-form />
+    </popu>
+  </template-page>
+</template>
+
+<script>
+import TemplatePage from '@/components/template/template-page-1.vue'
+import import_mixin from '@/components/template/import_mixin.js'
+import add_callback_mixin from '@/components/template/add_callback_mixin.js'
+import DelayRecordForm from './delayRecordForm.vue';
+import Popu from '@/components/template/popu.vue'
+import { getDealerListV2, exportDealerListV2 } from '@/api/basic_data/dealer'
+export default {
+  components: { TemplatePage, Popu, DelayRecordForm },
+  mixins: [import_mixin, add_callback_mixin],
+  data() {
+    return {
+      visible: false,
+      // 事件组合
+      optionsEvensGroup: [
+        [
+          [
+            {
+              name: '新增',
+              click: this.addOn(() => {
+                this.visible = true
+              })
+              // isRole: this.$checkBtnRole('add', this.$route.meta.roles)
+            }
+          ]
+        ]
+      ],
+      // 表格属性
+      tableAttributes: {
+        // 启用勾选列
+        selectColumn: true
+      }, // 关闭新增弹窗
+
+      // 表格事件
+      tableEvents: {
+        'selection-change': this.selectionChange
+      },
+      recordSelected: [],
+
+      detailsId: ''
+    }
+  },
+  methods: {
+    // 列表请求函数
+    getList(...p) {
+      this.recordSelected = []
+      return getDealerListV2(...p)
+    },
+    // 列表导出函数
+    exportList: exportDealerListV2,
+    // 表格列解析渲染数据更改
+    columnParsing(item, defaultData) {
+      return defaultData
+    },
+    // 监听勾选变化
+    selectionChange(data) {
+      this.recordSelected = data
+    },
+    operation() {
+      return (h, { row, index, column }) => {
+        return (
+          <div class='operation-btns'>
+            <el-button
+              size='mini'
+              type='text'
+              onClick={ () => {
+                this.visible = true
+                this.detailsId = row.id
+              }}
+            >
+                    查看
+            </el-button>
+          </div>
+        )
+      }
+    },
+    handleClose() {
+      this.addOff(() => {
+        this.visible = false
+      })()
+    }
+  }
+}
+</script>
+
+      <style lang="scss" scoped></style>
+

+ 156 - 0
src/views/replaceRecord/replaceRecordForm.vue

@@ -0,0 +1,156 @@
+<template>
+  <div>
+    <div>
+      <h4>新机型</h4>
+      <el-divider />
+      <zj-table
+        :table-attributes="tableAttributes"
+        :is-drop="true"
+        :columns="ovalColumns"
+        :table-data="ovalData"
+      />
+    </div>
+    <div>
+      <h4>旧机型</h4>
+      <el-divider />
+      <zj-table
+        :table-attributes="tableAttributes"
+        :is-drop="true"
+        :columns="newColumns"
+        :table-data="newData"
+      />
+    </div>
+    <div style="margin: 20px 0;">
+      <el-button type="primary" size="mini" @click="">提交</el-button>
+      <el-button type="primary" size="mini" @click="">审核</el-button>
+    </div>
+  </div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      ovalData: [],
+      newData: [],
+      tableAttributes: {}
+    }
+  },
+  computed: {
+    ovalColumns() {
+      return [
+        {
+          columnAttributes: {
+            label: '货品编码',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '货品名称',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '规格型号',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '操作',
+            prop: ''
+          },
+          render: (h, { column, row, index }) => {
+            return (
+              <div>
+                <el-button
+                  type='text'
+                  size='default'
+                  onClick={() => {
+
+                  }}
+                >
+                    删除
+                </el-button>
+              </div>
+            )
+          }
+        }
+      ]
+    },
+    newColumns() {
+      return [
+        {
+          columnAttributes: {
+            label: '政策编码',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '政策名称',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '物流编码',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '产品名称',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '规格型号',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '单位',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '单价',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '操作',
+            prop: ''
+          },
+          render: (h, { column, row, index }) => {
+            return (
+              <div>
+                <el-button
+                  type='text'
+                  size='default'
+                  onClick={() => {
+
+                  }}
+                >
+                    删除
+                </el-button>
+              </div>
+            )
+          }
+        }
+      ]
+    }
+  }
+}
+</script>
+
+<style lang="scss" scoped>
+
+</style>

+ 103 - 0
src/views/replaceRecord/replaceRecordList.vue

@@ -0,0 +1,103 @@
+<template>
+  <template-page
+    ref="pageRef"
+    :get-list="getList"
+    :export-list="exportList"
+    :operation="operation()"
+    :options-evens-group="optionsEvensGroup"
+    :column-parsing="columnParsing"
+  >
+    <popu v-if="visible">
+      <el-page-header slot="head" content="替换机型" @back="handleClose" />
+      <replace-record-form />
+    </popu>
+  </template-page>
+</template>
+
+<script>
+import TemplatePage from '@/components/template/template-page-1.vue'
+import import_mixin from '@/components/template/import_mixin.js'
+import add_callback_mixin from '@/components/template/add_callback_mixin.js'
+import ReplaceRecordForm from './replaceRecordForm.vue';
+import Popu from '@/components/template/popu.vue'
+import { getDealerListV2, exportDealerListV2 } from '@/api/basic_data/dealer'
+export default {
+  components: { TemplatePage, Popu, ReplaceRecordForm },
+  mixins: [import_mixin, add_callback_mixin],
+  data() {
+    return {
+      visible: false,
+      // 事件组合
+      optionsEvensGroup: [
+        [
+          [
+            {
+              name: '新增',
+              click: this.addOn(() => {
+                this.visible = true
+              })
+              // isRole: this.$checkBtnRole('add', this.$route.meta.roles)
+            }
+          ]
+        ]
+      ],
+      // 表格属性
+      tableAttributes: {
+        // 启用勾选列
+        selectColumn: true
+      }, // 关闭新增弹窗
+
+      // 表格事件
+      tableEvents: {
+        'selection-change': this.selectionChange
+      },
+      recordSelected: [],
+
+      detailsId: ''
+    }
+  },
+  methods: {
+    // 列表请求函数
+    getList(...p) {
+      this.recordSelected = []
+      return getDealerListV2(...p)
+    },
+    // 列表导出函数
+    exportList: exportDealerListV2,
+    // 表格列解析渲染数据更改
+    columnParsing(item, defaultData) {
+      return defaultData
+    },
+    // 监听勾选变化
+    selectionChange(data) {
+      this.recordSelected = data
+    },
+    operation() {
+      return (h, { row, index, column }) => {
+        return (
+          <div class='operation-btns'>
+            <el-button
+              size='mini'
+              type='text'
+              onClick={ () => {
+                this.visible = true
+                this.detailsId = row.id
+              }}
+            >
+                    查看
+            </el-button>
+          </div>
+        )
+      }
+    },
+    handleClose() {
+      this.addOff(() => {
+        this.visible = false
+      })()
+    }
+  }
+}
+</script>
+
+      <style lang="scss" scoped></style>
+

+ 1 - 1
src/views/sales_control/sales_management/components/customer_sales_details.vue

@@ -16,7 +16,7 @@
         </el-button>
       </template>
     </sales-table>
-    <LogisticsTabs v-if="details.status == 2 " style="margin:20px;" :details-id="detailsId" />
+    <LogisticsTabs v-if="details.status == 2 && details.stockType == 1 " style="margin:20px;" :details-id="detailsId" />
     <sales-dialog
       :dialog-visible="dialogVisible"
       :customer-number="customerNumber"

+ 5 - 0
src/views/sales_control/sales_management/components/customer_sales_form.vue

@@ -278,6 +278,10 @@ export default {
       this.dialogVisible = true
     },
     handelSubmit(type, status = 1) {
+      if (!this.$refs.header.screenForm.stockType) {
+        this.$errorMsg('请选择仓库')
+        return
+      }
       if (!this.dataList.length) {
         this.$errorMsg('请添加产品')
         return
@@ -295,6 +299,7 @@ export default {
         ...this.$refs.header.screenForm,
         orders: this.dataList,
         status: status
+
       }
       this.$refs.header.$refs.form.validate(valid => {
         if (valid) {

+ 16 - 5
src/views/sales_control/sales_management/components/return_sales_details.vue

@@ -23,11 +23,10 @@
         <div v-if="!detailsId">
           <el-button type="primary" :disabled="!dis" size="mini" @click="handelSubmit(1)">提交</el-button>
           <el-button v-if="dis" size="mini" @click="onReset">重置</el-button>
-          <el-button v-if="details.stockType ===1" size="mini" :disabled="dis" @click="handleInform(2)">退货通知</el-button>
+          <el-button v-if="details.stockType ===1 && details.status == 1" size="mini" :disabled="dis" @click="handleInform(2)">退货通知</el-button>
         </div>
         <div v-else>
-          <el-button type="primary" size="mini" @click="handelSubmit(2)">保存</el-button>
-          <el-button v-if="!detailsId" size="mini" @click="onReset">重置</el-button>
+          <el-button v-if="(details.status == 2 && details.stockType == 1)" size="mini" @click="handleSendRevoke(1)">撤销退货</el-button>
         </div>
       </template>
       <template v-slot:custom="{ item: { row, $index } }">
@@ -43,6 +42,8 @@
         </el-popconfirm>
       </template>
     </sales-table>
+    <LogisticsTabs v-if="details.stockType == 1 " style="margin:20px;" :details-id="detailsId" :return-show="false" />
+
     <sales-dialog
       ref="dia"
       :data-list="dataList"
@@ -59,12 +60,15 @@
 import SalesDialog from '@/components/SalesDialog/SalesDialog'
 import ReturnSalesHeader from '@/components/ReturnSalesHeader/ReturnSalesHeader'
 import SalesTable from '@/components/SalesTable/SalesTable'
+import LogisticsTabs from '@/components/LogisticsTabs'
+
 import {
   detailRefund,
   addRefund,
   sendRefund,
   updateRefund,
-  listOrder
+  listOrder,
+  sendRefundRevoke
 } from '@/api/sales'
 
 export default {
@@ -72,7 +76,8 @@ export default {
   components: {
     ReturnSalesHeader,
     SalesTable,
-    SalesDialog
+    SalesDialog,
+    LogisticsTabs
   },
   props: ['detailsId', 'pageType'],
   data() {
@@ -243,6 +248,12 @@ export default {
     resArr(arr1, arr2) {
       return arr1.filter(v => arr2.every(val => val.id != v.id))
     },
+    handleSendRevoke(status) {
+      sendRefundRevoke({ id: this.detailsId, status }).then(res => {
+        this.$successMsg('撤销退货')
+        this.handleBack()
+      })
+    },
     delChange() {
       if (this.dataList.length) {
         for (let i = 0; i < this.$refs.dia.$refs.pageRef.$refs.zjpage.$refs.tableEl.tableData.length; i++) {

+ 5 - 15
src/views/sales_control/sales_management/components/return_sales_form.vue

@@ -24,14 +24,9 @@
           <el-button v-if="!detailsId" type="primary" :disabled="!dis" size="mini" @click="handelSubmit(1)">提交</el-button>
           <el-button v-else type="primary" size="mini" @click="handelSubmit(2)">提交</el-button>
           <el-button v-if="dis" size="mini" @click="onReset">重置</el-button>
-          <el-button v-if="details.stockType ==1 && !detailsId" size="mini" :disabled="dis" @click="handleInform(2)">退货通知</el-button>
-          <el-button v-if="details.stockType ==2 && detailsId" size="mini" @click="handleInform(2)">退货通知</el-button>
-
+          <el-button v-if="$refs.header.details.stockType ==1" size="mini" :disabled="dis" @click="handleInform(2)">退货通知</el-button>
         </div>
-        <!-- <div v-else>
-          <el-button type="primary" size="mini" @click="handelSubmit(2)">保存</el-button>
-          <el-button v-if="!detailsId" size="mini" @click="onReset">重置</el-button>
-        </div> -->
+
       </template>
       <template v-slot:custom="{ item: { row, $index } }">
         <div>{{ diffQty(row) }}</div>
@@ -144,6 +139,7 @@ export default {
   },
   created() {
     if (this.detailsId) {
+      this.dis = false
       detailRefund({ id: this.detailsId }).then(res => {
         this.dataList = res.data.orders
         this.details = res.data
@@ -163,13 +159,6 @@ export default {
 
   methods: {
     getDialogList(p) {
-      // let func = getcustomerFrontList
-      // if (this.isFront===true){
-      //   func = getcustomerFrontList
-      // }
-      // if (this.isFront===false){
-      //   func = getFrontListCustomer
-      // }
       return listOrder(...p)
     },
     confirm(selected) {
@@ -201,7 +190,6 @@ export default {
           }
         }
       }
-      console.log(this.$refs.dia.$refs.pageRef.$refs.zjpage.$refs.tableEl.tableData)
       selected.forEach(k => {
         k.diffQty = Number(k.qty) - Number(k.refundQty)
         k.qty = k.refundQty
@@ -212,6 +200,7 @@ export default {
       if (!this.detailsId) {
         this.details = this.dataList[0]
         this.details.customerOrderNo = obj.id
+        this.details.stockType = this.details.stockType == '嘉贤前置仓' ? 1 : 2
       }
 
       this.returnId = obj.id
@@ -299,6 +288,7 @@ export default {
         orders: list,
         customerOrderNo: this.details.customerOrderNo,
         status
+
       }
       if (type === 1) {
         params.id = ''

+ 338 - 0
src/views/supply/salesReturnOrder/salesReturnOrderDetail.vue

@@ -0,0 +1,338 @@
+<template>
+  <div>
+    <h4>订单信息</h4>
+    <el-divider />
+    <div class="diy-table-1">
+      <el-row>
+        <el-col :span="8" class="item">
+          <div class="label">销售退货单</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">订单日期</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">销售订单</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">经销商编号</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="16" class="item">
+          <div class="label">经销商名称</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">销售政策编码</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="16" class="item">
+          <div class="label">销售政策</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+      </el-row>
+      <!-- 政策订单 -->
+      <el-row v-if="moduleType === 1">
+        <el-col :span="8" class="item">
+          <div class="label">销售政策编码</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="16" class="item">
+          <div class="label">销售政策</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="24" class="item">
+          <div class="label">格力回复</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+      </el-row>
+      <!-- 零售订单 -->
+      <el-row v-if="moduleType === 2">
+        <el-col :span="8" class="item">
+          <div class="label">产品大类</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="16" class="item">
+          <div class="label">销售订单类型</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+      </el-row>
+      <!-- 商用工程订单 -->
+      <el-row v-if="moduleType === 3">
+        <el-col :span="8" class="item">
+          <div class="label">工程信息编码</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">工程项目名称</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">工程信息单类型</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">厂工程编码</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">使用单位</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label" />
+          <div class="value" />
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">联系人</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">固定电话</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">移动电话</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">不扣押金</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">文件编码</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="8" class="item">
+          <div class="label">业务员</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="24" class="item">
+          <div class="label">格力回复</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="24" class="item">
+          <div class="label">格力内部备注</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+      </el-row>
+      <el-row>
+        <el-col :span="24" class="item">
+          <div class="label">备注</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="6" class="item">
+          <div class="label">制单人</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="6" class="item">
+          <div class="label">制单日期</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="6" class="item">
+          <div class="label">审核人</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="6" class="item">
+          <div class="label">审核日期</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="6" class="item">
+          <div class="label">最后更新人</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="6" class="item">
+          <div class="label">最后更新日期</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="6" class="item">
+          <div class="label">关闭人</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="6" class="item">
+          <div class="label">关闭日期</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+        <el-col :span="24" class="item">
+          <div class="label">审核说明</div>
+          <div class="value">{{ detailData.id }}</div>
+        </el-col>
+      </el-row>
+    </div>
+    <h4>货品信息</h4>
+    <el-divider />
+    <zj-table
+      :table-attributes="tableAttributes"
+      :is-drop="true"
+      :columns="columns"
+      :table-data="policyData"
+    />
+  </div>
+</template>
+
+<script>
+export default {
+  data() {
+    return {
+      moduleType: 1,
+      detailData: {},
+      policyData: [],
+      tableAttributes: {
+        border: true,
+        headerCellClassName: 'headerRowColor',
+        size: 'mini',
+        'summary-method': this.$getSummaries,
+        'show-summary': true
+      }
+    }
+  },
+  computed: {
+    columns() {
+      return [
+        {
+          columnAttributes: {
+            label: '序号',
+            prop: '',
+            type: 'index'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '销售类型',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '存货编码',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '物料代码',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '产品名称',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '规格型号',
+            prop: 'materialName',
+            width: 300
+          }
+        },
+        {
+          columnAttributes: {
+            label: '单位',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '单价',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '工程信息数量',
+            prop: 'materialName',
+            width: 120
+
+          }
+        },
+        {
+          columnAttributes: {
+            label: '已订数量',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '本次订货数量',
+            prop: 'materialName',
+            width: 120
+          }
+        },
+        {
+          columnAttributes: {
+            label: '订单金额',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '返利类型',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '使用返利金额',
+            prop: 'materialName',
+            width: 120
+          }
+        },
+        {
+          columnAttributes: {
+            label: '格力折扣',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '现金钱包',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '实付金额',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '直调',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '直调数量',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '原订单数量',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '备注',
+            prop: 'materialName'
+          }
+        },
+        {
+          columnAttributes: {
+            label: '税率',
+            prop: 'materialName'
+          }
+        }
+      ]
+    }
+  }
+}
+</script>
+
+<style lang="scss" scoped></style>

+ 1 - 1
src/views/supply/salesReturnOrder/salesReturnOrderList.vue

@@ -8,7 +8,7 @@
     :column-parsing="columnParsing"
   >
     <popu v-if="visible">
-      <el-page-header slot="head" content="新增" @back="handleClose" />
+      <el-page-header slot="head" content="订单信息" @back="handleClose" />
       <sales-return-order-detail />
     </popu>
   </template-page>

+ 52 - 35
src/views/supply/transferOrder/transferOrderForm.vue

@@ -48,7 +48,7 @@
     <!-- 审核 /详情-->
     <div v-if="moduleType === 3 || moduleType === 2">
       <el-button v-if="moduleType === 3" type="primary" size="mini" @click="onExamine('OK')">同意</el-button>
-      <el-button v-if="formData.status === 'OK'" size="mini" @click="onInvoice('SAVE')">撤回</el-button>
+      <el-button v-if="formData.status === 'OK'" size="mini" @click="onInvoice('WAIT')">反审</el-button>
     </div>
   </div>
 </template>
@@ -66,7 +66,7 @@ import {
   updateCustomerTransfer,
   getCustomerTransferDetail,
   examineCustomerTransfer,
-  invoiceCustomerTransfer
+  setNeExamine
 } from '@/api/transferOrder'
 import { mapGetters } from 'vuex'
 
@@ -305,9 +305,9 @@ export default {
           },
           render: (h, { column, row, index }) => {
             return (
-              <div style="margin:0 20px">
+              <div style='margin:0 20px'>
                 <el-input
-                  type="number"
+                  type='number'
                   disabled={this.comDisabled}
                   value={row.qty}
                   // onInput={e => (row.qty = e)}
@@ -315,8 +315,8 @@ export default {
                     row.qty = value
                     this.debounceChange(value, index)
                   }}
-                  placeholder="调拨数量"
-                  size="mini"
+                  placeholder='调拨数量'
+                  size='mini'
                 ></el-input>
               </div>
             )
@@ -330,12 +330,12 @@ export default {
           render: (h, { column, row, index }) => {
             return (
               <el-input
-                type="text"
+                type='text'
                 value={row.notes}
                 disabled={this.comDisabled}
                 onInput={e => (row.notes = e)}
-                placeholder="备注"
-                size="mini"
+                placeholder='备注'
+                size='mini'
               ></el-input>
             )
           }
@@ -356,8 +356,8 @@ export default {
               <div>
                 {!this.comDisabled ? (
                   <el-button
-                    type="text"
-                    size="default"
+                    type='text'
+                    size='default'
                     onClick={() => {
                       this.handleDel(index)
                     }}
@@ -376,29 +376,29 @@ export default {
         ...[
           !this.comDisabled
             ? {
-                name: 'slot-component',
-                md: 24,
-                attributes: { disabled: false },
-                formItemAttributes: { label: '', prop: '' },
-                render: (h, { props, onInput }) => {
-                  return (
-                    <div>
-                      <el-button
-                        size="mini"
-                        onClick={() => {
-                          this.visible = true
-                          this.recordSelected = []
-                        }}
-                      >
+              name: 'slot-component',
+              md: 24,
+              attributes: { disabled: false },
+              formItemAttributes: { label: '', prop: '' },
+              render: (h, { props, onInput }) => {
+                return (
+                  <div>
+                    <el-button
+                      size='mini'
+                      onClick={() => {
+                        this.visible = true
+                        this.recordSelected = []
+                      }}
+                    >
                         添加
-                      </el-button>
-                      <el-button size="mini" onClick={() => this.handleAllDel()}>
+                    </el-button>
+                    <el-button size='mini' onClick={() => this.handleAllDel()}>
                         删除
-                      </el-button>
-                    </div>
-                  )
-                }
+                    </el-button>
+                  </div>
+                )
               }
+            }
             : {}
         ],
         {
@@ -858,7 +858,7 @@ export default {
     }
   },
   methods: {
-    debounceChange: debounce(function (val, index) {
+    debounceChange: debounce(function(val, index) {
       if (val <= 0) {
         this.selectData[index].qty = 1
       } else {
@@ -910,6 +910,7 @@ export default {
         ]
       }).then(res => {
         this.sonCustomerList = res.data.records
+
         this.sonCustomerNameList = res.data.records.map(k => {
           return {
             label: k.name,
@@ -922,6 +923,11 @@ export default {
             value: k.id
           }
         })
+        if (this.detailsId && this.sonCustomerList.length) {
+          const transfer = this.sonCustomerList.find(k => k.number === this.formData.transferCustomerNumber)
+          this.formData.transferCustomerNumber = transfer.id
+          this.formData.transferCustomerName = transfer.id
+        }
       })
     },
     handleAddData() {
@@ -1017,10 +1023,21 @@ export default {
     },
     onSubmit(type = null) {
       this.$refs.formRef.validate(valid => {
+        for (let i = 0; i < this.selectData.length; i++) {
+          if (this.selectData[i].qty <= 0) {
+            this.$errorMsg('调拨数量不能小于1')
+            return
+          }
+        }
+        const transfer = this.sonCustomerList.find(k => k.id === this.formData.transferCustomerNumber)
+
         if (valid) {
           const params = {
             ...this.formData,
-            orders: this.selectData
+            orders: this.selectData,
+            transferCustomerNumber: transfer.number,
+            transferCustomerName: transfer.name
+
           }
           if (this.moduleType === 1) {
             params.status = type
@@ -1050,11 +1067,11 @@ export default {
       })
     },
     onInvoice(type = null) {
-      invoiceCustomerTransfer({
+      setNeExamine({
         id: this.detailsId,
         status: type
       }).then(res => {
-        this.$successMsg('撤回成功')
+        this.$successMsg('反审成功')
         this.handlerefreshList()
       })
     }

+ 19 - 4
src/views/supply/transferOrder/transferOrderList.vue

@@ -21,7 +21,7 @@ import import_mixin from '@/components/template/import_mixin.js'
 import add_callback_mixin from '@/components/template/add_callback_mixin.js'
 import Popu from '@/components/template/popu.vue'
 import TransferOrderForm from './transferOrderForm.vue'
-import { getListTransferV2, exportListTransferV2, invoiceCustomerTransfer } from '@/api/transferOrder'
+import { getListTransferV2, exportListTransferV2, invoiceCustomerTransfer, dletransferDelete } from '@/api/transferOrder'
 import { mapGetters } from 'vuex'
 export default {
   components: { TemplatePage, Popu, TransferOrderForm },
@@ -115,7 +115,7 @@ export default {
                 审核
               </el-button>
             ) : null}
-            {row.status === 'SAVE' || row.status === 'WAIT'  ? (
+            {row.status === 'SAVE' || row.status === 'WAIT' ? (
               <el-button
                 size='mini'
                 type='text'
@@ -146,8 +146,23 @@ export default {
                 </el-button>
               </el-popconfirm>
             ) : null}
-          </div>
-        )
+            {row.status === 'SAVE' || row.status === 'WAIT' ? <el-popconfirm
+              onOnConfirm={ () => {
+                dletransferDelete({
+                  id: row.id
+                }).then(res => {
+                  this.$successMsg('删除成功')
+                  this.$refs.pageRef.refreshList()
+                })
+              }}
+              title='是否确定需要删除该项内容?'
+            >
+              <el-button slot='reference' size='mini' type='text'>
+                删除
+              </el-button>
+            </el-popconfirm> : null
+            }
+          </div>)
       }
     },
     handleClose() {