Просмотр исходного кода

Merge branch 'deploy' of http://git.chelingzhu.com/jianguan-web/qpls-md-html into deploy

1004749546@qq.com 4 лет назад
Родитель
Сommit
980c907ff8

+ 16 - 3
src/views/purchasingManagement/purchaseOrder/edit.vue

@@ -240,7 +240,7 @@ export default {
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '产品编码', dataIndex: 'code', width: 220, align: 'center', sorter: true },
-        { title: '产品名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '产品名称', dataIndex: 'name', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '原厂编码', dataIndex: 'origCode', width: 220, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '箱/单位', dataIndex: 'unit', width: 100, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '采购单价', dataIndex: 'purchasePrice', width: 100, align: 'center', customRender: function (text) { return '¥' + (text || 0) }, fixed: 'right' },
@@ -286,6 +286,7 @@ export default {
           const no = (data.pageNo - 1) * data.pageSize
           for (var i = 0; i < data.list.length; i++) {
             data.list[i].no = no + i + 1
+            data.list[i].qtyBackups = data.list[i].qty
           }
           this.localDataSource = data.list
           this.disabled = false
@@ -354,7 +355,10 @@ export default {
     },
     // 修改数量后
     qtyBlur (val, record) {
-      this.handleAdd(record, 1)
+      //  光标移出,值发生改变再调用编辑接口
+      if (val != record.qtyBackups) {
+        this.handleAdd(record, 1)
+      }
     },
     //  导入明细
     handleImport () {
@@ -387,6 +391,10 @@ export default {
     //  添加或修改
     handleAdd (row, type) {
       let params = {}
+      if (type == 0 && !row.qty) {
+        this.$message.warning('请输入数量后再添加!')
+        return
+      }
       // 添加
       if (type == 0) {
         params.productSn = row.productSn
@@ -394,7 +402,12 @@ export default {
         params.purchaseBillNo = this.detail.purchaseBillNo
         params.price = row.purchasePrice
         params.qty = row.qty
-      } else {
+      } else { //  编辑
+        // 清空成本价或数量时,值应保持未清空前的值,因成本价和数量都不可为空
+        if (!row.qty) {
+          row.qty = row.qtyBackups
+          return
+        }
         params = row
       }
       this.addLoading = true

+ 2 - 3
src/views/purchasingManagement/purchaseOrder/list.vue

@@ -67,8 +67,7 @@
       </div>
       <!-- 操作按钮 -->
       <div class="table-operator">
-        <!-- <a-button id="purchaseOrderList-add" type="primary" v-if="$hasPermissions('B_purchaseNew')" class="button-error" @click="handleAdd">新增</a-button> -->
-        <a-button id="purchaseOrderList-add" type="primary" class="button-error" @click="handleAdd">新增</a-button>
+        <a-button id="purchaseOrderList-add" type="primary" v-if="$hasPermissions('B_purchaseNew')" class="button-error" @click="handleAdd">新增</a-button>
       </div>
       <!-- alert -->
       <a-alert type="info" showIcon style="margin-bottom:15px">
@@ -165,7 +164,7 @@ export default {
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '采购单号', scopedSlots: { customRender: 'purchaseBillNo' }, width: 220, align: 'center' },
         { title: '创建时间', dataIndex: 'createDate', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '供应商', dataIndex: 'purchaseTargetName', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '供应商', dataIndex: 'purchaseTargetName', align: 'center', customRender: function (text) { return text || '--' }, ellipsis: true },
         { title: '产品款数', dataIndex: 'totalCategory', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '采购数量', dataIndex: 'totalQty', width: 100, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
         { title: '采购金额(¥)', dataIndex: 'discountedAmount', width: 115, align: 'center', customRender: function (text) { return '¥' + (text || 0) } },

+ 3 - 3
src/views/purchasingManagement/purchaseOrder/receivingAddress/chooseAddressModal.vue

@@ -7,7 +7,7 @@
     title="收货地址"
     v-model="isShow"
     @cancel="isShow=false"
-    :width="900">
+    :width="960">
     <a-spin :spinning="spinning" tip="Loading...">
       <!-- 操作按钮 -->
       <div class="table-operator">
@@ -21,7 +21,7 @@
         :rowKey="(record) => record.id"
         :columns="columns"
         :data="loadData"
-        :scroll="{ x: 1050 }"
+        :scroll="{ x: 1250 }"
         :showPagination="false"
         bordered>
         <!-- 收货人 -->
@@ -98,7 +98,7 @@ export default {
       columns: [
         { title: '序号', dataIndex: 'no', width: 80, align: 'center' },
         { title: '收货人', scopedSlots: { customRender: 'consignee' }, align: 'center', ellipsis: true },
-        { title: '手机号码', dataIndex: 'consigneeTel', width: 120, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '手机号码', dataIndex: 'consigneeTel', width: 230, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '收货地址', dataIndex: 'address', width: 400, align: 'center', ellipsis: true },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 220, align: 'center', fixed: 'right' },
         { title: '选择', scopedSlots: { customRender: 'choose' }, width: 100, align: 'center', fixed: 'right' }

+ 154 - 136
src/views/reportData/stockExpenditureReport/list.vue

@@ -1,70 +1,92 @@
 <template>
-  <a-card size="small" :bordered="false" class="noticeList-wrap">
-    <!-- 搜索条件 -->
-    <div class="table-page-search-wrapper">
-      <a-form layout="inline" @keyup.enter.native="handelSearch(1)">
-        <a-row :gutter="15">
-          <a-col :md="6" :sm="24">
-            <a-form-item label="出库完成时间">
-              <rangeDate ref="rangeDate" @change="dateChange" />
-            </a-form-item>
-          </a-col>
-          <a-col :md="6" :sm="24">
-            <a-button type="primary" @click="handelSearch(1)" id="noticeList-refresh">查询</a-button>
-            <a-button style="margin-left: 8px" @click="resetSearchForm" id="noticeList-reset">重置</a-button>
-          </a-col>
-        </a-row>
-      </a-form>
-    </div>
-    <!-- 列表 -->
-    <a-row :gutter="15">
-      <a-col :md="12" :sm="24">
-        <div class="chart-box">
-          <div class="chart-hj">库存总出数量:372,总成本:¥4315.50</div>
-          <div id="con1" class="chart"></div>
-        </div>
-      </a-col>
-      <a-col :md="12" :sm="24">
-        <a-table
-          class="sTable"
-          ref="table"
-          size="default"
-          :rowKey="(record) => record.id"
-          :columns="columns"
-          :dataSource="loadData"
-          :loading="listLoading"
-          :pagination="false"
-          bordered>
-        </a-table>
-      </a-col>
-    </a-row>
+  <a-card size="small" :bordered="false" class="stockExpenditureReportList-wrap">
+    <a-spin :spinning="spinning" tip="Loading...">
+      <!-- 搜索条件 -->
+      <div class="table-page-search-wrapper">
+        <a-form-model
+          id="chainStockReportList-form"
+          ref="ruleForm"
+          :model="queryParam"
+          :rules="rules"
+          :labelCol="labelCol"
+          :wrapperCol="wrapperCol"
+          @keyup.enter.native="handelSearch" >
+          <a-row :gutter="15">
+            <a-col :md="8" :sm="24">
+              <a-form-model-item label="出库完成时间" prop="time">
+                <rangeDate ref="rangeDate" @change="dateChange" />
+              </a-form-model-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-button type="primary" @click="handelSearch" id="stockExpenditureReportList-refresh">查询</a-button>
+              <a-button style="margin-left: 8px" @click="resetSearchForm" id="stockExpenditureReportList-reset">重置</a-button>
+            </a-col>
+          </a-row>
+        </a-form-model>
+      </div>
+      <!-- 列表 -->
+      <a-row :gutter="15" style="margin-top: 50px;">
+        <a-col :md="12" :sm="24">
+          <div class="chart-box">
+            <div class="chart-hj">
+              库存总出数量:{{ (totalData&&totalData.totalQty) ? totalData.totalQty : '--' }},
+              总成本:¥{{ (totalData&&totalData.totalCost) ? totalData.totalCost : '--' }}
+            </div>
+            <div id="con1" class="chart"></div>
+          </div>
+        </a-col>
+        <a-col :md="12" :sm="24" style="margin-top: 30px;">
+          <a-table
+            class="sTable"
+            ref="table"
+            size="default"
+            :rowKey="(record) => record.dataBizTypeDictValue"
+            :columns="columns"
+            :dataSource="tableData"
+            :loading="listLoading"
+            :pagination="false"
+            bordered>
+          </a-table>
+        </a-col>
+      </a-row>
+    </a-spin>
   </a-card>
 </template>
 
 <script>
 import rangeDate from '@/views/common/rangeDate.vue'
 import echarts from 'echarts'
+import { reportStockOutList } from '@/api/reportStock'
 export default {
   components: { rangeDate },
   data () {
     return {
+      spinning: false,
       queryParam: { //  查询条件
+        time: [],
         beginDate: '',
         endDate: ''
       },
+      labelCol: { span: 8 },
+      wrapperCol: { span: 16 },
+      rules: {
+        'time': [{ required: true, message: '请选择出库完成时间', trigger: 'change' }]
+      },
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
-        { title: '明细项', dataIndex: 'itemName', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '数量(件)', dataIndex: 'qty', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '成本(元)', dataIndex: 'cost', align: 'center', customRender: function (text) { return text || '--' } },
-        { title: '售价(元)', dataIndex: 'price', align: 'center', customRender: function (text) { return text || '--' } }
+        { title: '明细项', dataIndex: 'dataBizTypeDictValue', align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '数量(件)', dataIndex: 'productQty', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '成本(元)', dataIndex: 'productCost', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '售价(元)', dataIndex: 'productPrice', align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } }
       ],
       // 统计图
       pieData: [],
       pieColor: ['#00aaff', '#ffaa00', '#00aa00', '#ff55ff', '#1dc5d4', '#8465c7', '#00ffff'],
-      loadData: [],
+      tableData: [], //  含总计数据
+      loadData: [], //  不含总计数据
       listLoading: false,
-      chart1: null
+      chart1: null,
+      totalData: null
     }
   },
 
@@ -94,25 +116,25 @@ export default {
           formatter: `{b} : {d}%`
         },
         legend: {
-    		  orient: 'horizontal',
-    		  left: 'center',
-    		  bottom: '5',
-    		  padding: 5,
-    		  textStyle: {
-    		    color: '#abd7ff',
+          orient: 'horizontal',
+          left: 'center',
+          bottom: '5',
+          padding: 5,
+          textStyle: {
+            color: '#abd7ff',
             fontSize: 10
-    		  },
-    		  show: !!bit,
-    		  formatter: function (name) {
-    			  if (bit) {
+          },
+          show: !!bit,
+          formatter: function (name) {
+            if (bit) {
               const p = data.find(item => item.name == name)
               return name + (p ? (':' + p.value + bit) : '')
-    			  }
-    		  }
+            }
+          }
         },
         series: [{
           type: 'pie',
-          radius: ['30%', '50%'],
+          radius: ['50%', '70%'],
           startAngle: 75,
           top: 50,
           avoidLabelOverlap: true, // 在标签拥挤重叠的情况下会挪动各个标签的位置,防止标签间的重叠
@@ -120,8 +142,7 @@ export default {
             normal: {
               formatter: params => {
                 return (
-                  '{name|' + params.name + '}{value|' +
-    										params.percent + '%' + '}'
+                  '{name|' + params.name + '}{value|' + params.percent + '%' + '}'
                 )
               },
               padding: [0, -70, 25, -70],
@@ -157,82 +178,70 @@ export default {
     },
     //  时间  change
     dateChange (date) {
-      this.queryParam.beginDate = date[0] ? date[0] + ' 00:00:00' : ''
-      this.queryParam.endDate = date[1] ? date[1] + ' 23:59:59' : ''
+      this.queryParam.time = date
+      this.queryParam.beginDate = date[0]
+      this.queryParam.endDate = date[1]
     },
-    // 查询列表
     handelSearch () {
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          this.getList()
+        } else {
+          console.log('error submit!!')
+          return false
+        }
+      })
+    },
+    // 查询列表
+    getList () {
       const params = {
         beginDate: this.queryParam.beginDate,
         endDate: this.queryParam.endDate
       }
       // 开始查询
       this.listLoading = true
-      setTimeout(() => {
+      this.spinning = true
+      reportStockOutList(params).then(res => {
         this.listLoading = false
-        this.loadData = [
-          {
-            itemName: '采购退货',
-            qty: '14',
-            cost: '84.50',
-            price: ''
-          },
-          {
-            itemName: '散件退货',
-            qty: '3',
-            cost: '28.00',
-            price: ''
-          },
-          {
-            itemName: '销售(含急件)',
-            qty: '77',
-            cost: '837.50',
-            price: '2672.55'
-          },
-          {
-            itemName: '急件冲减',
-            qty: '9',
-            cost: '109.50',
-            price: ''
-          },
-          {
-            itemName: '店内调出',
-            qty: '6',
-            cost: '55.00',
-            price: ''
-          },
-          {
-            itemName: '盘亏出库',
-            qty: '190',
-            cost: '2725.00',
-            price: ''
-          },
-          {
-            itemName: '连锁调出',
-            qty: '73',
-            cost: '476.00',
-            price: ''
-          },
-          {
-            itemName: '总出',
-            qty: '372',
-            cost: '4315.50',
-            price: '2672.55'
+        if (res.status == 200) {
+          const reportStockOutVOList = (res.data && res.data.reportStockOutVOList) ? res.data.reportStockOutVOList : []
+          const totalQty = (res.data && (res.data.totalQty || res.data.totalQty == 0)) ? res.data.totalQty : '--'
+          const totalPrice = (res.data && (res.data.totalPrice || res.data.totalPrice == 0)) ? res.data.totalPrice : '--'
+          const totalCost = (res.data && (res.data.totalCost || res.data.totalCost == 0)) ? res.data.totalCost : '--'
+          this.totalData = {
+            totalQty: totalQty,
+            totalPrice: totalPrice,
+            totalCost: totalCost
           }
-        ]
-        this.chartInit()
-      }, 600)
-    },
-    chartInit () {
-      this.loadData.map((item, index) => {
-        if (index != this.loadData.length - 1) {
-          this.pieData.push({
-            name: item.itemName + '总成本',
-            value: item.cost
-          })
+          if (reportStockOutVOList) {
+            this.loadData = res.data.reportStockOutVOList
+            this.tableData = res.data.reportStockOutVOList
+            const total = [{ dataBizTypeDictValue: '总出', productQty: totalQty, productCost: totalCost, productPrice: totalPrice }]
+            this.tableData = [...this.tableData, ...total]
+          } else {
+            this.loadData = []
+            this.tableData = []
+          }
+          this.chartInit()
         }
+        this.spinning = false
       })
-      const con5 = document.getElementById('con1')
+    },
+    chartInit () {
+      this.pieData = []
+      if (this.loadData.length < 1) {
+        this.pieData = [{ name: '总成本', value: 0 }]
+      } else {
+        this.loadData.map((item, index) => {
+          if (index != this.loadData.length) {
+            this.pieData.push({
+              name: item.dataBizTypeDictValue + '总成本',
+              value: item.productCost
+            })
+          }
+        })
+      }
+      const con1 = document.getElementById('con1')
       const chart1 = echarts.init(con1)
       const option = this.initPie(chart1, '', this.pieData)
       chart1.setOption(option)
@@ -242,7 +251,13 @@ export default {
     //  重置
     resetSearchForm () {
       this.$refs.rangeDate.resetDate()
-      this.handelSearch()
+      this.queryParam.time = []
+      this.queryParam.beginDate = ''
+      this.queryParam.endDate = ''
+      this.loadData = []
+      this.tableData = []
+      this.totalData = null
+      this.chartInit()
     }
   },
   mounted () {
@@ -254,22 +269,25 @@ export default {
   },
   beforeRouteEnter (to, from, next) {
     next(vm => {
-      vm.handelSearch()
+      vm.chartInit()
     })
   }
 }
 </script>
 <style lang="less">
-  .chart-box{
-    height: 400px;
-    .chart-hj{
-      font-size: 22px;
-      text-align: center;
-    }
-    .chart{
-      width: 100%;
-      height: 450px;
-      overflow: auto;
+  .stockExpenditureReportList-wrap{
+    min-height: 700px;
+    .chart-box{
+      height: 400px;
+      .chart-hj{
+        font-size: 22px;
+        text-align: center;
+      }
+      .chart{
+        width: 100%;
+        height: 450px;
+        overflow: auto;
+      }
     }
   }
 </style>

+ 51 - 30
src/views/reportData/stockIncomeReport/list.vue

@@ -1,5 +1,5 @@
 <template>
-  <a-card size="small" :bordered="false" class="noticeList-wrap">
+  <a-card size="small" :bordered="false" class="stockIncomeReportList-wrap">
     <a-spin :spinning="spinning" tip="Loading...">
       <!-- 搜索条件 -->
       <div class="table-page-search-wrapper">
@@ -18,21 +18,24 @@
               </a-form-model-item>
             </a-col>
             <a-col :md="6" :sm="24">
-              <a-button type="primary" @click="handelSearch" id="noticeList-refresh">查询</a-button>
-              <a-button style="margin-left: 8px" @click="resetSearchForm" id="noticeList-reset">重置</a-button>
+              <a-button type="primary" @click="handelSearch" id="stockIncomeReportList-refresh">查询</a-button>
+              <a-button style="margin-left: 8px" @click="resetSearchForm" id="stockIncomeReportList-reset">重置</a-button>
             </a-col>
           </a-row>
         </a-form-model>
       </div>
       <!-- 列表 -->
-      <a-row :gutter="15">
+      <a-row :gutter="15" style="margin-top: 50px;">
         <a-col :md="12" :sm="24">
           <div class="chart-box">
-            <div class="chart-hj">库存总入数量:28,总成本:¥189.50</div>
+            <div class="chart-hj">
+              库存总入数量:{{ (totalData&&totalData.totalQty) ? totalData.totalQty : '--' }},
+              总成本:¥{{ (totalData&&totalData.totalCost) ? totalData.totalCost : '--' }}
+            </div>
             <div id="con1" class="chart"></div>
           </div>
         </a-col>
-        <a-col :md="12" :sm="24">
+        <a-col :md="12" :sm="24" style="margin-top: 30px;">
           <a-table
             class="sTable"
             ref="table"
@@ -82,7 +85,8 @@ export default {
       tableData: [], //  含总计数据
       loadData: [], //  不含总计数据
       listLoading: false,
-      chart1: null
+      chart1: null,
+      totalData: null
     }
   },
 
@@ -130,7 +134,7 @@ export default {
         },
         series: [{
           type: 'pie',
-          radius: ['30%', '50%'],
+          radius: ['50%', '70%'],
           startAngle: 75,
           top: 50,
           avoidLabelOverlap: true, // 在标签拥挤重叠的情况下会挪动各个标签的位置,防止标签间的重叠
@@ -201,9 +205,14 @@ export default {
         this.listLoading = false
         if (res.status == 200) {
           const reportStockPutVOList = (res.data && res.data.reportStockPutVOList) ? res.data.reportStockPutVOList : []
-          const totalQty = (res.data && res.data.totalQty) ? res.data.totalQty : 0
-          const totalPrice = (res.data && res.data.totalPrice) ? res.data.totalPrice : 0
-          const totalCost = (res.data && res.data.totalCost) ? res.data.totalCost : 0
+          const totalQty = (res.data && (res.data.totalQty || res.data.totalQty == 0)) ? res.data.totalQty : '--'
+          const totalPrice = (res.data && (res.data.totalPrice || res.data.totalPrice == 0)) ? res.data.totalPrice : '--'
+          const totalCost = (res.data && (res.data.totalCost || res.data.totalCost == 0)) ? res.data.totalCost : '--'
+          this.totalData = {
+            totalQty: totalQty,
+            totalPrice: totalPrice,
+            totalCost: totalCost
+          }
           if (reportStockPutVOList) {
             this.loadData = res.data.reportStockPutVOList
             this.tableData = res.data.reportStockPutVOList
@@ -219,14 +228,19 @@ export default {
       })
     },
     chartInit () {
-      this.loadData.map((item, index) => {
-        if (index != this.loadData.length) {
-          this.pieData.push({
-            name: item.dataBizTypeDictValue + '总成本',
-            value: item.productCost
-          })
-        }
-      })
+      this.pieData = []
+      if (this.loadData.length < 1) {
+        this.pieData = [{ name: '总成本', value: 0 }]
+      } else {
+        this.loadData.map((item, index) => {
+          if (index != this.loadData.length) {
+            this.pieData.push({
+              name: item.dataBizTypeDictValue + '总成本',
+              value: item.productCost
+            })
+          }
+        })
+      }
       const con1 = document.getElementById('con1')
       const chart1 = echarts.init(con1)
       const option = this.initPie(chart1, '', this.pieData)
@@ -242,6 +256,8 @@ export default {
       this.queryParam.endDate = ''
       this.loadData = []
       this.tableData = []
+      this.totalData = null
+      this.chartInit()
     }
   },
   mounted () {
@@ -252,21 +268,26 @@ export default {
     }
   },
   beforeRouteEnter (to, from, next) {
-    next(vm => {})
+    next(vm => {
+      vm.chartInit()
+    })
   }
 }
 </script>
 <style lang="less">
-  .chart-box{
-    height: 400px;
-    .chart-hj{
-      font-size: 22px;
-      text-align: center;
-    }
-    .chart{
-      width: 100%;
-      height: 450px;
-      overflow: auto;
+  .stockIncomeReportList-wrap{
+    min-height: 700px;
+    .chart-box{
+      height: 400px;
+      .chart-hj{
+        font-size: 22px;
+        text-align: center;
+      }
+      .chart{
+        width: 100%;
+        height: 450px;
+        overflow: auto;
+      }
     }
   }
 </style>

+ 21 - 1
src/views/salesManagement/outboundOrder/list.vue

@@ -90,9 +90,11 @@
           <a-button
             size="small"
             type="link"
+            v-if="detailPermissions(record)"
             class="button-success"
             @click="handleDetail(record)"
             id="outboundOrderList-detail-btn">详情</a-button>
+          <span v-if="!(record.state=='WAIT'&&$hasPermissions('B_outboundOut')) && !(detailPermissions(record))">--</span>
         </template>
       </s-table>
     </a-spin>
@@ -171,6 +173,24 @@ export default {
     }
   },
   methods: {
+    detailPermissions (row) {
+      let state = false
+      //  根据出库类型和对应功能权限 判断是否有查看详情的权限
+      if ((row.outBizType == 'PURCHASE_RETURN') && this.$hasPermissions('B_purchaseReturnDetail')) { // 采购退货
+        state = true
+      } else if ((row.outBizType == 'SALES') && this.$hasPermissions('B_salesDetail')) { // 销售
+        state = true
+      } else if ((row.outBizType == 'DISPATCH_DEDUCT') && this.$hasPermissions('M_urgentDetail')) { // 急件冲减
+        state = true
+      } else if ((row.outBizType == 'SHOP_CALL_OUT') && this.$hasPermissions('B_storeCallOutDetail')) { // 店内调出
+        state = true
+      } else if ((row.outBizType == 'LINKAGE_CALL_OUT') && this.$hasPermissions('B_allocLinkageOutDetail')) { // 连锁调出
+        state = true
+      } else if ((row.outBizType == 'WAREHOUSE_CALL_OUT') && this.$hasPermissions('B_warehouseAllocationDetail')) { // 仓库调出
+        state = true
+      }
+      return state
+    },
     //  时间  change
     dateChange (date) {
       this.queryParam.beginDate = date[0]
@@ -199,7 +219,7 @@ export default {
       } else if (row.outBizType == 'SPARE_PARTS_RETURN') { // 散件退货
         this.$message.warning('该出库类型对应页面未开发')
         // this.$router.push({ path: `/purchasingManagement/purchaseReturn/detail/${row.outBizSn}` })
-      } else if (row.outBizType == 'SALES') { // 出库
+      } else if (row.outBizType == 'SALES') { // 销售
         this.$router.push({ path: `/salesManagement/salesQuery/detail/${row.outBizSn}` })
       } else if (row.outBizType == 'DISPATCH_DEDUCT') { // 急件冲减
         this.$router.push({ path: `/salesManagement/urgentItemsOffset/detail/${row.outBizSn}` })

+ 3 - 4
src/views/salesManagement/salesQuery/list.vue

@@ -154,7 +154,7 @@
             size="small"
             type="link"
             class="button-info"
-            v-if="(record.salesBillSource == 'PURCHASE' && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'AUDIT_REJECT' || record.billStatus == 'SUPERIOR_CHANGE')) && $hasPermissions('B_salesEdit')"
+            v-if="(record.salesBillSource == 'PURCHASE' && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'SUPERIOR_CHANGE')) && $hasPermissions('B_salesEdit')"
             @click="handleEdit(record)"
           >
             改单
@@ -163,13 +163,12 @@
             size="small"
             type="link"
             class="button-error"
-            v-if="(record.salesBillSource == 'PURCHASE' && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'AUDIT_REJECT' || record.billStatus == 'SUPERIOR_CHANGE')) && $hasPermissions('B_salesDel')"
+            v-if="(record.salesBillSource == 'PURCHASE' && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'SUPERIOR_CHANGE')) && $hasPermissions('B_salesDel')"
             @click="handleDel(record, 'cancel')"
           >
             取消
           </a-button>
-          <!-- <span v-if="record.billStatus == 'FINISH'">--</span> -->
-          <span v-if="!(record.billStatus == 'WAIT_AUDIT' && $hasPermissions('B_salesAudit')) &&!(record.billStatus == 'WAIT_OUT_WAREHOUSE' && $hasPermissions('B_salesStockOut')) &&(!((record.salesBillSource == 'SATELLITE' || record.salesBillSource == 'SALES') && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'WAIT_SUBMIT' || record.billStatus == 'AUDIT_REJECT')) && !$hasPermissions('B_salesEdit')) &&(!(record.salesBillSource == 'PURCHASE' && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'AUDIT_REJECT' || record.billStatus == 'SUPERIOR_CHANGE')) && !$hasPermissions('B_salesDel')) &&(!(record.salesBillSource == 'PURCHASE' && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'AUDIT_REJECT' || record.billStatus == 'SUPERIOR_CHANGE')) && !$hasPermissions('B_salesEdit') && !$hasPermissions('B_salesDel')) || record.billStatus == 'FINISH'">--</span>
+          <span v-if="!(record.billStatus == 'WAIT_AUDIT' && $hasPermissions('B_salesAudit')) && !(record.billStatus == 'WAIT_OUT_WAREHOUSE' && $hasPermissions('B_salesStockOut')) && !(((record.salesBillSource == 'SATELLITE' || record.salesBillSource == 'SALES') && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'WAIT_SUBMIT' || record.billStatus == 'AUDIT_REJECT')) && $hasPermissions('B_salesEdit')) && !(((record.salesBillSource == 'SATELLITE' || record.salesBillSource == 'SALES') && record.billStatus != 'FINISH') && $hasPermissions('B_salesDel')) && !((record.salesBillSource == 'PURCHASE' && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'SUPERIOR_CHANGE')) && $hasPermissions('B_salesEdit')) && !((record.salesBillSource == 'PURCHASE' && (record.billStatus == 'WAIT_AUDIT' || record.billStatus == 'SUPERIOR_CHANGE')) && $hasPermissions('B_salesDel'))">--</span>
         </template>
       </s-table>
     </a-spin>

+ 1 - 6
src/views/salesManagement/salesReturn/chooseCustomModal.vue

@@ -308,12 +308,7 @@ export default {
       }
       this.spinning = true
       updateByCustomerSn(params).then(res => {
-        if (res.status != 200) {
-          this.$message.error(res.message)
-          this.spinning = false
-        } else {
-          this.spinning = false
-        }
+        this.spinning = false
       })
     },
     //  保存

+ 11 - 9
src/views/salesManagement/urgentItemsOffset/detail.vue

@@ -18,14 +18,13 @@
       <a-card size="small" :bordered="false" class="urgentItemsOffsetDetail-info-wrapper">
         <a-collapse :activeKey="['1']">
           <a-collapse-panel key="1" header="基础信息">
-            <a-descriptions :column="3" v-if="detailData">
-              <a-descriptions-item label="客户名称">{{ detailData.buyerName || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="客户地址">{{ detailData.shippingAddressProvinceName || '--' }}{{ detailData.shippingAddressCityName || '--' }}{{ detailData.shippingAddressCountyName || '--' }}{{ detailData.shippingAddress || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="支付方式">{{ detailData.buyerName || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="联系电话">{{ detailData.consigneeTel || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="收款方式">{{ detailData.buyerName || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="急件单号">{{ detailData.urgentBillNo || '--' }}</a-descriptions-item>
-              <a-descriptions-item label="状态">{{ detailData.statusDictValue || '--' }}</a-descriptions-item>
+            <a-descriptions :column="3">
+              <a-descriptions-item label="客户名称">{{ (detailData&&detailData.buyerName) || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="客户地址">{{ (detailData&&detailData.shippingAddressProvinceName) || '' }}{{ (detailData&&detailData.shippingAddressCityName) || '' }}{{ (detailData&&detailData.shippingAddressCountyName) || '' }}{{ (detailData&&detailData.shippingAddress) || '' }}</a-descriptions-item>
+              <a-descriptions-item label="联系电话">{{ detailData&&detailData.consigneeTel || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="收款方式">{{ (detailData&&detailData.settleStyleEntity&&detailData.settleStyleEntity.name) || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="急件单号">{{ (detailData&&detailData.urgentBillNo) || '--' }}</a-descriptions-item>
+              <a-descriptions-item label="状态">{{ (detailData&&detailData.statusDictValue) || '--' }}</a-descriptions-item>
             </a-descriptions>
           </a-collapse-panel>
         </a-collapse>
@@ -34,7 +33,10 @@
       <a-card size="small" :bordered="false" class="urgentItemsOffsetDetail-table-wrapper">
         <!-- 合计 -->
         <a-alert type="info" showIcon style="margin-bottom:15px" v-if="detailData">
-          <div class="ftext" slot="message">总款数:<strong>{{ detailData.totalCategory || 0 }}</strong>;总数量:<strong>{{ detailData.totalQty || 0 }}</strong>。</div>
+          <div class="ftext" slot="message">
+            总款数:<strong>{{ (detailData&&(detailData.totalCategory || detailData.totalCategory == 0)) ? detailData.totalCategory : '--' }}</strong>;
+            总数量:<strong>{{ (detailData&&(detailData.totalQty || detailData.totalQty == 0)) ? detailData.totalQty : '--' }}</strong>。
+          </div>
         </a-alert>
         <s-table
           class="sTable"