chenrui 4 年之前
父節點
當前提交
2af83c0c68
共有 28 個文件被更改,包括 2136 次插入381 次删除
  1. 40 0
      src/api/custType.js
  2. 8 0
      src/api/customer.js
  3. 24 0
      src/api/data.js
  4. 78 0
      src/api/warehouse.js
  5. 153 0
      src/config/router.config.js
  6. 118 0
      src/views/basicData/customerTypeManagement/editModal.vue
  7. 105 0
      src/views/basicData/customerTypeManagement/list.vue
  8. 2 3
      src/views/basicData/supplierManagement/edit.vue
  9. 9 9
      src/views/basicData/supplierManagement/list.vue
  10. 20 2
      src/views/bulkManagement/bulkWarehousingOrder/edit.vue
  11. 8 0
      src/views/chainAllocation/chainTransferIn/detail.vue
  12. 8 0
      src/views/chainAllocation/chainTransferIn/edit.vue
  13. 219 0
      src/views/chainAllocation/chainTransferIn/list.vue
  14. 1 1
      src/views/inventoryManagement/inventoryQuery/list.vue
  15. 41 3
      src/views/inventoryManagement/warehouse/editModal.vue
  16. 30 60
      src/views/inventoryManagement/warehouse/list.vue
  17. 62 9
      src/views/inventoryManagement/warehouse/storingLocation/editModal.vue
  18. 83 91
      src/views/inventoryManagement/warehouse/storingLocation/list.vue
  19. 109 0
      src/views/inventoryManagement/warehouseAllocation/basicInfoModal.vue
  20. 163 0
      src/views/inventoryManagement/warehouseAllocation/detail.vue
  21. 380 0
      src/views/inventoryManagement/warehouseAllocation/edit.vue
  22. 242 0
      src/views/inventoryManagement/warehouseAllocation/list.vue
  23. 24 4
      src/views/productManagement/productBrand/list.vue
  24. 9 9
      src/views/productManagement/productInfo/list.vue
  25. 1 1
      src/views/purchasingManagement/purchaseOrder/receivingAddress/chooseAddressModal.vue
  26. 166 147
      src/views/salesManagement/customerManagement/edit.vue
  27. 32 41
      src/views/salesManagement/customerManagement/list.vue
  28. 1 1
      vue.config.js

+ 40 - 0
src/api/custType.js

@@ -0,0 +1,40 @@
+import { axios } from '@/utils/request'
+
+//  客户类型列表  分页
+export const custTypeList = (params) => {
+  let url = `/custType/findPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
+
+//  客户类型列表  不分页
+export const custTypeFindAll = (params) => {
+  let url = `/custType/findAll`
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
+
+// 新增/编辑客户类型
+export const custTypeSave = params => {
+  return axios({
+    url: '/custType/save',
+    data: params,
+    method: 'post'
+  })
+}
+
+// 删除客户类型
+export const custTypeDel = params => {
+  return axios({
+    url: `/custType/del/${params.id}`,
+    method: 'post'
+  })
+}

+ 8 - 0
src/api/customer.js

@@ -19,4 +19,12 @@ export const custSave = params => {
     data: params,
     data: params,
     method: 'post'
     method: 'post'
   })
   })
+}
+
+// 删除客户
+export const custDel = params => {
+  return axios({
+    url: `/cust/del/${params.id}`,
+    method: 'post'
+  })
 }
 }

+ 24 - 0
src/api/data.js

@@ -103,3 +103,27 @@ function randomStr (len) {
   }
   }
   return pwd
   return pwd
 }
 }
+
+// 查询省
+export const getProvince = () => {
+  return axios({
+    url: `/area/findProvince`,
+    method: 'post'
+  })
+}
+// 查询市
+export const getCityByPro = params => {
+  return axios({
+    url: `/area/findCity/${params.id}`,
+    data: params,
+    method: 'post'
+  })
+}
+// 查询区
+export const getDistrictByCity = params => {
+  return axios({
+    url: `/area/findDistrict/${params.id}`,
+    data: params,
+    method: 'post'
+  })
+}

+ 78 - 0
src/api/warehouse.js

@@ -0,0 +1,78 @@
+import { axios } from '@/utils/request'
+
+//  仓库列表  有分页
+export const warehouseList = (params) => {
+  let url = `/warehouse/findPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
+//  仓库列表  无分页
+export const warehouseFindAll = (params) => {
+  let url = '/warehouse/findAll'
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
+// 新增/编辑仓库
+export const warehouseSave = params => {
+  return axios({
+    url: '/warehouse/save',
+    data: params,
+    method: 'post'
+  })
+}
+// 删除仓库
+export const warehouseDel = params => {
+  return axios({
+    url: `/warehouse/del/${params.id}`,
+    method: 'post'
+  })
+}
+
+
+
+//  仓位列表  有分页
+export const warehouseLocList = (params) => {
+  let url = `/warehouseLoc/findPage/${params.pageNo}/${params.pageSize}`
+  delete params.pageNo
+  delete params.pageSize
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
+//  仓位列表  无分页
+export const warehouseLocFindAll = (params) => {
+  let url = '/warehouseLoc/findAll'
+  return axios({
+    url: url,
+    data: params,
+    method: 'post'
+  })
+}
+
+// 新增/编辑仓位
+export const warehouseLocSave = params => {
+  return axios({
+    url: '/warehouseLoc/save',
+    data: params,
+    method: 'post'
+  })
+}
+
+// 删除仓位
+export const warehouseLocDel = params => {
+  return axios({
+    url: '/warehouseLoc/del',
+    data: params,
+    method: 'post'
+  })
+}

+ 153 - 0
src/config/router.config.js

@@ -303,6 +303,134 @@ export const asyncRouterMap = [{
             }
             }
           }
           }
         ]
         ]
+      },
+      {
+        path: '/inventoryManagement/warehouseAllocation',
+        redirect: '/inventoryManagement/warehouseAllocation/list',
+        name: 'warehouseAllocation',
+        component: RouteView,
+        meta: {
+          title: '仓库调拨',
+          icon: 'shopping'
+          // permission: 'M_goodsManage_list'
+        },
+        hideChildrenInMenu: true,
+        children: [
+          {
+            path: '/inventoryManagement/warehouseAllocation/list',
+            name: 'warehouseAllocationList',
+            component: () => import(/* webpackChunkName: "shop" */ '@/views/inventoryManagement/warehouseAllocation/list.vue'),
+            meta: {
+              title: '仓库调拨列表',
+              icon: 'shopping',
+              hidden: true
+              // permission: 'M_goodsManage_list'
+            }
+          },
+          {
+            path: '/inventoryManagement/warehouseAllocation/add',
+            name: 'warehouseAllocationAdd',
+            component: () => import(/* webpackChunkName: "shop" */ '@/views/inventoryManagement/warehouseAllocation/edit.vue'),
+            meta: {
+              title: '新增仓库调拨',
+              icon: 'shopping',
+              hidden: true
+              // permission: 'B_goodsManage_edit'
+            }
+          },
+          {
+            path: '/inventoryManagement/warehouseAllocation/edit/:id',
+            name: 'warehouseAllocationEdit',
+            component: () => import(/* webpackChunkName: "shop" */ '@/views/inventoryManagement/warehouseAllocation/edit.vue'),
+            meta: {
+              title: '编辑仓库调拨',
+              icon: 'shopping',
+              hidden: true
+              // permission: 'B_goodsManage_edit'
+            }
+          },
+          {
+            path: '/inventoryManagement/warehouseAllocation/detail/:id',
+            name: 'warehouseAllocationEdit',
+            component: () => import(/* webpackChunkName: "shop" */ '@/views/inventoryManagement/warehouseAllocation/detail.vue'),
+            meta: {
+              title: '仓库调拨详情',
+              icon: 'shopping',
+              hidden: true
+              // permission: 'B_goodsManage_edit'
+            }
+          },
+        ]
+      }
+    ]
+  },
+  {
+    path: '/chainAllocation',
+    redirect: '/chainAllocation/chainTransferIn',
+    component: PageView,
+    meta: {
+      title: '连锁调拨',
+      icon: 'shop'
+      // permission: 'M_shop'
+    },
+    children: [
+      {
+        path: '/chainAllocation/chainTransferIn',
+        redirect: '/chainAllocation/chainTransferIn/list',
+        name: 'chainTransferIn',
+        component: RouteView,
+        meta: {
+          title: '连锁调入',
+          icon: 'shopping'
+          // permission: 'M_goodsManage_list'
+        },
+        hideChildrenInMenu: true,
+        children: [
+          {
+            path: '/chainAllocation/chainTransferIn/list',
+            name: 'chainTransferInList',
+            component: () => import(/* webpackChunkName: "shop" */ '@/views/chainAllocation/chainTransferIn/list.vue'),
+            meta: {
+              title: '连锁调入列表',
+              icon: 'shopping',
+              hidden: true
+              // permission: 'M_goodsManage_list'
+            }
+          },
+          {
+            path: '/chainAllocation/chainTransferIn/add',
+            name: 'chainTransferInAdd',
+            component: () => import(/* webpackChunkName: "shop" */ '@/views/chainAllocation/chainTransferIn/edit.vue'),
+            meta: {
+              title: '新增连锁调入',
+              icon: 'shopping',
+              hidden: true
+              // permission: 'B_goodsManage_edit'
+            }
+          },
+          {
+            path: '/chainAllocation/chainTransferIn/edit/:id',
+            name: 'chainTransferInEdit',
+            component: () => import(/* webpackChunkName: "shop" */ '@/views/chainAllocation/chainTransferIn/edit.vue'),
+            meta: {
+              title: '编辑连锁调入',
+              icon: 'shopping',
+              hidden: true
+              // permission: 'B_goodsManage_edit'
+            }
+          },
+          {
+            path: '/chainAllocation/chainTransferIn/detail/:id',
+            name: 'chainTransferInEdit',
+            component: () => import(/* webpackChunkName: "shop" */ '@/views/chainAllocation/chainTransferIn/detail.vue'),
+            meta: {
+              title: '连锁调入详情',
+              icon: 'shopping',
+              hidden: true
+              // permission: 'B_goodsManage_edit'
+            }
+          }
+        ]
       }
       }
     ]
     ]
   },
   },
@@ -639,6 +767,31 @@ export const asyncRouterMap = [{
             }
             }
           }
           }
         ]
         ]
+      },
+      {
+        path: '/basicData/customerTypeManagement',
+        redirect: '/basicData/customerTypeManagement/list',
+        name: 'customerTypeManagement',
+        component: RouteView,
+        meta: {
+          title: '客户类型管理',
+          icon: 'shopping'
+          // permission: 'M_goodsManage_list'
+        },
+        hideChildrenInMenu: true,
+        children: [
+          {
+            path: '/basicData/customerTypeManagement/list',
+            name: 'customerTypeManagementList',
+            component: () => import(/* webpackChunkName: "shop" */ '@/views/basicData/customerTypeManagement/list.vue'),
+            meta: {
+              title: '客户类型列表',
+              icon: 'shopping',
+              hidden: true
+              // permission: 'M_goodsManage_list'
+            }
+          }
+        ]
       }
       }
     ]
     ]
   },
   },

+ 118 - 0
src/views/basicData/customerTypeManagement/editModal.vue

@@ -0,0 +1,118 @@
+<template>
+  <a-modal
+    centered
+    class="customerTypeEdit-modal"
+    :footer="null"
+    :maskClosable="false"
+    :title="modalTit"
+    v-model="isShow"
+    @cancle="isShow=false"
+    :width="800">
+    <!-- 表单 -->
+    <div>
+      <a-form-model
+        id="customerTypeEdit-form"
+        ref="ruleForm"
+        :model="form"
+        :rules="rules"
+        :label-col="formItemLayout.labelCol"
+        :wrapper-col="formItemLayout.wrapperCol"
+      >
+        <a-form-model-item label="客户类型名称" prop="name">
+          <a-input
+            id="customerTypeEdit-name"
+            :maxLength="30"
+            v-model="form.name"
+            placeholder="请输入客户类型名称(最多30个字符)"
+            allowClear />
+        </a-form-model-item>
+      </a-form-model>
+      <div class="btn-cont">
+        <a-button type="primary" id="customer-type-edit-modal-save" @click="handleSave">保存</a-button>
+        <a-button id="customer-type-edit-modal-back" @click="isShow = false" style="margin-left: 15px;">返回列表</a-button>
+      </div>
+    </div>
+  </a-modal>
+</template>
+
+<script>
+import { STable } from '@/components'
+export default {
+  name: 'customerTypeEditModal',
+  components: { STable },
+  props: {
+    openModal: { //  弹框显示状态
+      type: Boolean,
+      default: false
+    },
+    itemId: {
+      type: [Number, String],
+      default: ''
+    },
+    nowData: {
+      type: Object,
+      default: null
+    }
+  },
+  computed: {
+    modalTit () {
+      return (this.itemId ? '编辑' : '新增') + '客户类型'
+    }
+  },
+  data () {
+    return {
+      isShow: this.openModal, //  是否打开弹框
+      detailsData: null, //  品牌数据
+      formItemLayout: {
+        labelCol: { span: 6 },
+        wrapperCol: { span: 16 }
+      },
+      form: {
+        name: '', // 客户类型名称
+      },
+      rules: {
+        name: [
+          { required: true, message: '请输入客户类型名称', trigger: 'blur' }
+        ],
+      }
+    }
+  },
+  methods: {
+    //  保存
+    handleSave(){
+      
+    },
+  },
+  watch: {
+    //  父页面传过来的弹框状态
+    openModal (newValue, oldValue) {
+      this.isShow = newValue
+    },
+    //  重定义的弹框状态
+    isShow (newValue, oldValue) {
+      if (!newValue) {
+        this.$emit('close')
+      }
+    },
+    itemId (newValue, oldValue) {
+      if (this.isShow && newValue) {  //  编辑
+        this.form.name = this.nowData && this.nowData.name ? this.nowData.name : ''
+      }else{  //  添加
+        this.form.name = ''
+      }
+    }
+  }
+}
+</script>
+
+<style lang="less">
+  .customerTypeEdit-modal{
+    .ant-modal-body {
+    	padding: 40px 40px 24px;
+    }
+    .btn-cont {
+    	text-align: center;
+    	margin: 35px 0 10px;
+    }
+  }
+</style>

+ 105 - 0
src/views/basicData/customerTypeManagement/list.vue

@@ -0,0 +1,105 @@
+<template>
+  <a-card :bordered="false" class="customerTypeList-wrap">
+    <!-- 搜索条件 -->
+    <div class="table-page-search-wrapper">
+      <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
+        <a-row :gutter="15">
+          <a-col :md="6" :sm="24">
+            <a-form-item label="类型名称">
+              <a-input id="customerTypeList-bundleName" v-model.trim="queryParam.bundleName" allowClear placeholder="请输入客户类型名称"/>
+            </a-form-item>
+          </a-col>
+          <a-col :md="6" :sm="24">
+            <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="customerTypeList-refresh">查询</a-button>
+            <a-button style="margin-left: 8px" @click="resetSearchForm" :disabled="disabled" id="customerTypeList-reset">重置</a-button>
+          </a-col>
+        </a-row>
+      </a-form>
+    </div>
+    <!-- 操作按钮 -->
+    <div class="table-operator">
+      <a-button id="customerTypeList-add" type="primary" @click="handleEdit()">新增客户类型</a-button>
+    </div>
+    <!-- 列表 -->
+    <s-table
+      class="sTable"
+      ref="table"
+      size="default"
+      :rowKey="(record) => record.id"
+      :columns="columns"
+      :data="loadData"
+      bordered>
+      <!-- 操作 -->
+      <template slot="action" slot-scope="text, record">
+        <a-button type="primary" @click="handleEdit(record)" id="customerTypeList-edit-btn">编辑</a-button>
+      </template>
+    </s-table>
+    <!-- 新增/编辑客户类型 -->
+    <customer-type-edit-modal :openModal="openModal" :nowData="nowData" :itemId="itemId" @close="closeModal" />
+  </a-card>
+</template>
+
+<script>
+import moment from 'moment'
+import { custTypeFindAll } from '@/api/custType'
+import { STable, VSelect } from '@/components'
+import customerTypeEditModal from './editModal.vue'
+export default {
+  components: { STable, VSelect, customerTypeEditModal },
+  data () {
+    return {
+      queryParam: { //  查询条件
+        bundleName: '', //  品牌名称
+        state: undefined,  //  状态
+      },
+      disabled: false, //  查询、重置按钮是否可操作
+      columns: [
+        { title: '序号', dataIndex: 'no', width: 70, align: 'center' },
+        { title: '客户类型名称', dataIndex: 'productName', align: 'center', ellipsis: true },
+        { title: '创建时间', dataIndex: 'inventoryMoney', width: 180, align: 'center' },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: 240, align: 'center' }
+      ],
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        return custTypeFindAll( this.queryParam ).then(res => {
+          const data = res.data
+          // const no = (data.pageNo - 1) * data.pageSize
+          // for (var i = 0; i < data.list.length; i++) {
+          //   data.list[i].no = no + i + 1
+          // }
+          this.disabled = false
+          return data
+        })
+      },
+      openModal: false,  //  新增编辑客户类型  弹框
+      itemId: '',  //  当前id
+      nowData: null  //  当前记录数据
+    }
+  },
+  methods: {
+    //  重置
+    resetSearchForm () {
+      this.queryParam.orderBundleNo = ''
+      this.queryParam.orderBundle.custMobile = ''
+      this.queryParam.bundleName = ''
+      this.queryParam.itemName = ''
+      this.oldTime = undefined
+      this.newTime = undefined
+      this.$refs.table.refresh(true)
+    },
+    //  新增/编辑
+    handleEdit(row){
+      this.itemId = row ? row.id : null
+      this.openModal = true
+    },
+    //  关闭弹框
+    closeModal(){
+      this.itemId = ''
+      this.openModal = false
+    }
+  }
+}
+</script>
+
+<style lang="less"></style>

+ 2 - 3
src/views/basicData/supplierManagement/edit.vue

@@ -93,7 +93,7 @@
 
 
 <script>
 <script>
 import { STable, VSelect } from '@/components'
 import { STable, VSelect } from '@/components'
-// import { goodsSave, goodsFind } from '@/api/goods'
+import { getProvince, getCityByPro, getDistrictByCity } from '@/api/data'
 export default {
 export default {
   name: 'supplierManagementEdit',
   name: 'supplierManagementEdit',
   components: { STable, VSelect },
   components: { STable, VSelect },
@@ -245,8 +245,7 @@ export default {
   },
   },
   beforeRouteEnter (to, from, next) {
   beforeRouteEnter (to, from, next) {
     next(vm => {
     next(vm => {
-      // vm.getGoodsType()
-      // vm.getPartnerQueryList()
+      vm.getProvinceList()
       vm.$refs.ruleForm.resetFields()
       vm.$refs.ruleForm.resetFields()
       if (vm.isEdit) { //  编辑页
       if (vm.isEdit) { //  编辑页
         vm.getGoodsDetail()
         vm.getGoodsDetail()

+ 9 - 9
src/views/basicData/supplierManagement/list.vue

@@ -23,7 +23,7 @@
     </div>
     </div>
     <!-- 操作按钮 -->
     <!-- 操作按钮 -->
     <div class="table-operator">
     <div class="table-operator">
-      <a-button id="supplierManagementList-add" type="primary" @click="handleAdd">新增供应商</a-button>
+      <a-button id="supplierManagementList-add" type="primary" @click="handleEdit()">新增供应商</a-button>
     </div>
     </div>
     <!-- 列表 -->
     <!-- 列表 -->
     <s-table
     <s-table
@@ -48,7 +48,7 @@
 
 
 <script>
 <script>
 import moment from 'moment'
 import moment from 'moment'
-// import { customerBundleDelayList, customerBundleExportDelay } from '@/api/FinancialManagement'
+// import { getProvince, getCityByPro, getDistrictByCity } from '@/api/data'
 import { STable, VSelect } from '@/components'
 import { STable, VSelect } from '@/components'
 export default {
 export default {
   components: { STable, VSelect },
   components: { STable, VSelect },
@@ -112,14 +112,14 @@ export default {
       this.newTime = undefined
       this.newTime = undefined
       this.$refs.table.refresh(true)
       this.$refs.table.refresh(true)
     },
     },
-    //  新增
-    handleAdd(){
-      this.$router.push({ path: '/basicData/supplierManagement/add' })
-    },
-    //  编辑
+    //  新增/编辑
     handleEdit(row){
     handleEdit(row){
-      this.$router.push({ path: `/basicData/supplierManagement/edit/${row.id}` })
-    }
+      if(row){  //  编辑
+        this.$router.push({ path: `/basicData/supplierManagement/edit/${row.id}` })
+      }else{  //  新增
+        this.$router.push({ path: '/basicData/supplierManagement/add' })
+      }
+    },
   }
   }
 }
 }
 </script>
 </script>

+ 20 - 2
src/views/bulkManagement/bulkWarehousingOrder/edit.vue

@@ -1,13 +1,27 @@
 <template>
 <template>
   <div class="bulkWarehousingOrderEdit-wrap">
   <div class="bulkWarehousingOrderEdit-wrap">
     <!-- 内容 -->
     <!-- 内容 -->
-    <a-page-header title="单号:CG2021010100001" style="margin-top: -24px;" >
-      <!-- 操作区,位于 title 行的行尾 -->
+    <!-- <a-page-header title="单号:CG2021010100001" style="margin-top: -24px;" >
       <template slot="extra">
       <template slot="extra">
         <a-button key="2" id="bulkWarehousingOrderEdit-preview-btn">打印预览</a-button>
         <a-button key="2" id="bulkWarehousingOrderEdit-preview-btn">打印预览</a-button>
         <a-button key="1" type="primary" id="bulkWarehousingOrderEdit-print-btn">快速打印</a-button>
         <a-button key="1" type="primary" id="bulkWarehousingOrderEdit-print-btn">快速打印</a-button>
       </template>
       </template>
+    </a-page-header> -->
+    
+    <a-page-header :ghost="false" @back="handleBack" >
+      <!-- 自定义的二级文字标题 -->
+      <template slot="subTitle">
+        <a id="bulkWarehousingOrderDetail-back-btn" href="javascript:;" @click="handleBack">返回列表</a>
+      </template>
+      <!-- 操作区,位于 title 行的行尾 -->
+      <template slot="extra">
+        <a-button key="2" id="bulkWarehousingOrderDetail-preview-btn">打印预览</a-button>
+        <a-button key="1" type="primary" id="bulkWarehousingOrderDetail-print-btn">快速打印</a-button>
+      </template>
     </a-page-header>
     </a-page-header>
+    <!-- 内容 -->
+    <a-page-header title="单号:CG2021010100001" ></a-page-header>
+    
     <!-- 基础信息 -->
     <!-- 基础信息 -->
     <a-card :bordered="false" class="bulkWarehousingOrderEdit-cont">
     <a-card :bordered="false" class="bulkWarehousingOrderEdit-cont">
       <a-collapse :activeKey="['1']">
       <a-collapse :activeKey="['1']">
@@ -310,6 +324,10 @@
       handleImport(){
       handleImport(){
         console.log(333)
         console.log(333)
       },
       },
+      //  返回列表
+      handleBack(){
+        this.$router.push({ path: '/bulkManagement/bulkWarehousingOrder/list'})
+      },
       filterOption(input, option) {
       filterOption(input, option) {
       	return (
       	return (
       		option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
       		option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0

+ 8 - 0
src/views/chainAllocation/chainTransferIn/detail.vue

@@ -0,0 +1,8 @@
+<template>
+</template>
+
+<script>
+</script>
+
+<style>
+</style>

+ 8 - 0
src/views/chainAllocation/chainTransferIn/edit.vue

@@ -0,0 +1,8 @@
+<template>
+</template>
+
+<script>
+</script>
+
+<style>
+</style>

+ 219 - 0
src/views/chainAllocation/chainTransferIn/list.vue

@@ -0,0 +1,219 @@
+<template>
+  <a-card :bordered="false" class="chainTransferInList-wrap">
+    <!-- 搜索条件 -->
+    <div class="table-page-search-wrapper">
+      <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
+        <a-row :gutter="15">
+          <a-col :md="6" :sm="24">
+            <a-form-item label="入库时间">
+              <a-range-picker
+                  style="width:100%"
+                  id="inventoryQueryWarehouseDetail-bundleNamesss"
+                  :disabledDate="disabledDate"
+                  v-model="queryParam.brand"
+                  :format="dateFormat"
+                  :placeholder="['开始时间', '结束时间']" />
+              </a-form-item>
+            </a-form-item>
+          </a-col>
+          <a-col :md="6" :sm="24">
+            <a-form-item label="调出对象">
+              <v-select
+                v-model="queryParam.billStatus"
+                ref="billStatus"
+                id="bulkWarehousingOrderList-billStatus"
+                code="PAYMENT_TYPE"
+                placeholder="请选择调出对象"
+                allowClear></v-select>
+            </a-form-item>
+          </a-col>
+          <a-col :md="6" :sm="24">
+            <a-form-item label="调拨产品类型">
+              <v-select
+                v-model="queryParam.billStatus"
+                ref="billStatus"
+                id="bulkWarehousingOrderList-billStatus"
+                code="PAYMENT_TYPE"
+                placeholder="请选择调拨产品类型"
+                allowClear></v-select>
+            </a-form-item>
+          </a-col>
+          <template v-if="advanced">
+            <a-col :md="6" :sm="24">
+              <a-form-item label="单据状态">
+                <v-select
+                  v-model="queryParam.billStatus"
+                  ref="billStatus"
+                  id="bulkWarehousingOrderList-billStatus"
+                  code="PAYMENT_TYPE"
+                  placeholder="请选择单据状态"
+                  allowClear></v-select>
+              </a-form-item>
+            </a-col>
+          </template>
+          <a-col :md="6" :sm="24" style="margin-bottom: 24px;">
+            <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="chainTransferInList-refresh">查询</a-button>
+            <a-button style="margin-left: 8px" @click="resetSearchForm" :disabled="disabled" id="chainTransferInList-reset">重置</a-button>
+            <a @click="advanced=!advanced" style="margin-left: 8px">
+              {{ advanced ? '收起' : '展开' }}
+              <a-icon :type="advanced ? 'up' : 'down'"/>
+            </a>
+          </a-col>
+        </a-row>
+      </a-form>
+    </div>
+    <!-- 操作按钮 -->
+    <div class="table-operator">
+      <a-button id="chainTransferInList-add" type="primary" @click="handleEdit()">新增调入单</a-button>
+    </div>
+    <!-- 列表 -->
+    <s-table
+      class="sTable"
+      ref="table"
+      size="default"
+      :rowKey="(record) => record.id"
+      :columns="columns"
+      :data="loadData"
+      bordered>
+      <!-- 状态 -->
+      <template slot="status" slot-scope="text, record">
+        <span :class="record.status==1?'green':'red'"> {{ record.status==1? '待入库': '待审核' }} </span>
+      </template>
+      <!-- 操作 -->
+      <template slot="action" slot-scope="text, record">
+        <a-button type="primary" @click="handleWarehousing(record)" id="chainTransferInList-warehousing-btn">入库</a-button>
+        <a-button @click="handleExamine(record)" id="chainTransferInList-examine-btn" style="margin: 0 0 8px 8px;">审核</a-button>
+        <a-button type="primary" @click="handleEdit(record)" id="chainTransferInList-edit-btn" style="margin: 0 0 8px 8px;">编辑</a-button>
+        <a-button @click="handleDetail(record)" id="chainTransferInList-detail-btn" style="margin: 0 0 0 8px;">详情</a-button>
+      </template>
+    </s-table>
+    <!-- 新增/编辑产品品牌 -->
+    <!-- <product-brand-edit-modal :openModal="openModal" :itemId="itemId" @close="closeModal" /> -->
+  </a-card>
+</template>
+
+<script>
+import moment from 'moment'
+// import { customerBundleDelayList, customerBundleExportDelay } from '@/api/FinancialManagement'
+import { STable, VSelect } from '@/components'
+// import productBrandEditModal from './editModal.vue'
+export default {
+  components: { STable, VSelect },
+  data () {
+    return {
+      advanced: false,  // 高级搜索 展开/关闭
+      queryParam: { //  查询条件
+        bundleName: '', //  品牌名称
+        state: undefined,  //  状态
+      },
+      disabled: false, //  查询、重置按钮是否可操作
+      dateFormat: 'YYYY-MM-DD',
+      columns: [
+        { title: '创建时间', dataIndex: 'no', width: 70, align: 'center', width: 180 },
+        { title: '连锁调出单号', dataIndex: 'productName', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
+        { title: '店内单号', dataIndex: 'productOldNum', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '调往对象', dataIndex: 'inventoryMoney', width: 180, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '总款数', dataIndex: 'inventsoryMoney', width: 180, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '总数量', dataIndex: 'inventoryModney', width: 180, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '总成本', dataIndex: 'inventoryaMoney', width: 180, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '入库时间', dataIndex: 'inventoryMongey', width: 180, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '调拨产品类型', dataIndex: 'indventoryMoney', width: 180, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '状态', scopedSlots: { customRender: 'status' }, width: 180, align: 'center' },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: 300, align: 'center' }
+      ],
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        // return customerBundleDelayList( Object.assign(parameter, this.queryParam) ).then(res => {
+        //   const data = res.data
+        //   const no = (data.pageNo - 1) * data.pageSize
+        //   for (var i = 0; i < data.list.length; i++) {
+        //     data.list[i].no = no + i + 1
+        //   }
+        //   this.disabled = false
+        //   return data
+        // })
+        const _this = this
+        return new Promise(function(resolve, reject){
+          const data = {
+            pageNo: 1,
+            pageSize: 10,
+            list: [
+              { id: '1', productNum: 'jgqp11111111111', productName: '产品1', productOldNum: 'jgqp111123545', productBrand: '箭冠品牌', productType: '产品分类1', inventoryNum: '5', inventoryMoney: '122' }
+            ]
+          }
+          const no = (data.pageNo - 1) * data.pageSize
+          for (var i = 0; i < data.list.length; i++) {
+            data.list[i].no = no + i + 1
+          }
+          _this.disabled = false
+          resolve(data)
+        })
+      },
+      openModal: false,  //  新增编辑产品品牌  弹框
+      itemId: ''  //  当前品牌id
+    }
+  },
+  methods: {
+    // 不可选日期
+    disabledDate (date, dateStrings) {
+      return date && date.valueOf() > Date.now()
+    },
+    //  重置
+    resetSearchForm () {
+      this.queryParam.orderBundleNo = ''
+      this.queryParam.orderBundle.custMobile = ''
+      this.queryParam.bundleName = ''
+      this.queryParam.itemName = ''
+      this.oldTime = undefined
+      this.newTime = undefined
+      this.$refs.table.refresh(true)
+    },
+    //  入库
+    handleWarehousing(){},
+    //  审核
+    handleExamine(){
+      const _this = this
+      this.$confirm({
+        title: '提示',
+        content: '确认要审核通过吗?',
+        okText: '确定',
+        cancelText: '取消',
+        onOk () {
+          // delectRolePower({
+          //   id: row.id
+          // }).then(res => {
+          //   console.log(res, 'res1111')
+          //   if (res.status == 200) {
+          //     _this.$message.success(res.message)
+          //     _this.$refs.table.refresh()
+          //   }
+          // })
+        }
+      })
+    },
+    //  详情
+    handleDetail(row){
+      this.$router.push({ path: `/inventoryManagement/warehouseAllocation/detail/${row.id}` })
+    },
+    //  新增/编辑
+    handleEdit(row){
+      if(row){  //  编辑
+        this.$router.push({ path: `/inventoryManagement/warehouseAllocation/edit/${row.id}` })
+      }else{  //  新增
+        this.$router.push({ path: '/inventoryManagement/warehouseAllocation/add' })
+      }
+    },
+  }
+}
+</script>
+
+<style lang="less">
+  .chainTransferInList-wrap{
+    .sTable{
+      table{
+        width: auto;
+      }
+    }
+  }
+</style>

+ 1 - 1
src/views/inventoryManagement/inventoryQuery/list.vue

@@ -65,7 +65,7 @@
       bordered>
       bordered>
       <!-- 操作 -->
       <!-- 操作 -->
       <template slot="action" slot-scope="text, record">
       <template slot="action" slot-scope="text, record">
-        <a-button type="primary" @click="goDetail(record)" id="inventoryQueryList-detail-btn">库存详情</a-button>
+        <a-button type="primary" @click="goDetail(record)" id="inventoryQueryList-detail-btn" style="margin: 0 0 8px 0;">库存详情</a-button>
         <a-button style="margin-left: 8px" @click="goWarehouseDetail(record)" id="inventoryQueryList-warehouseDetail-btn">出入库明细</a-button>
         <a-button style="margin-left: 8px" @click="goWarehouseDetail(record)" id="inventoryQueryList-warehouseDetail-btn">出入库明细</a-button>
       </template>
       </template>
     </s-table>
     </s-table>

+ 41 - 3
src/views/inventoryManagement/warehouse/editModal.vue

@@ -40,6 +40,7 @@
 
 
 <script>
 <script>
 import { STable } from '@/components'
 import { STable } from '@/components'
+import { warehouseSave } from '@/api/warehouse'
 export default {
 export default {
   name: 'warehouseEditModal',
   name: 'warehouseEditModal',
   components: { STable },
   components: { STable },
@@ -51,6 +52,10 @@ export default {
     itemId: {
     itemId: {
       type: [Number, String],
       type: [Number, String],
       default: ''
       default: ''
+    },
+    nowData: {
+      type: Object,
+      default: null
     }
     }
   },
   },
   computed: {
   computed: {
@@ -77,13 +82,41 @@ export default {
     }
     }
   },
   },
   methods: {
   methods: {
-    //  获取详情
+    //  详情
     getDetail(){
     getDetail(){
-      
+      this.form = {
+        name: this.nowData && this.nowData.name ? this.nowData.name : '',
+        sort: this.nowData && this.nowData.sort ? this.nowData.sort : ''
+      }
     },
     },
     //  保存
     //  保存
     handleSave(){
     handleSave(){
-      
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          const params = {
+            id: this.itemId ? this.itemId : undefined,
+            name: this.form.name,  //  仓库名称
+            sort: this.form.sort,  //  排序
+            isDefault: 0  //  是否为默认仓库   0为非默认,1为默认
+          }
+          warehouseSave(params).then(res => {
+            if(res.status == 200){
+              _this.$message.success(res.message)
+              _this.$emit('ok')
+              setTimeout(function () {
+                _this.isShow = false
+                _this.$refs.ruleForm.resetFields()
+              }, 300)
+            }else{
+              
+            }
+          })
+        } else {
+          console.log('error submit!!')
+          return false
+        }
+      })
     },
     },
   },
   },
   watch: {
   watch: {
@@ -95,6 +128,11 @@ export default {
     isShow (newValue, oldValue) {
     isShow (newValue, oldValue) {
       if (!newValue) {
       if (!newValue) {
         this.$emit('close')
         this.$emit('close')
+      }else{
+        this.form = {
+          name: '',
+          sort: ''
+        }
       }
       }
     },
     },
     itemId (newValue, oldValue) {
     itemId (newValue, oldValue) {

+ 30 - 60
src/views/inventoryManagement/warehouse/list.vue

@@ -6,12 +6,7 @@
         <a-row :gutter="15">
         <a-row :gutter="15">
           <a-col :md="6" :sm="24">
           <a-col :md="6" :sm="24">
             <a-form-item label="仓库名称">
             <a-form-item label="仓库名称">
-              <a-input id="warehouseList-bundleName" v-model.trim="queryParam.bundleName" allowClear placeholder="请输入仓库名称"/>
-            </a-form-item>
-          </a-col>
-          <a-col :md="6" :sm="24">
-            <a-form-item label="状态">
-              <v-select code="CHECK_ENABLE_STATE" id="warehouseList-state" v-model="queryParam.state" allowClear placeholder="请选择状态"></v-select>
+              <a-input id="warehouseList-name" v-model.trim="queryParam.name" allowClear placeholder="请输入仓库名称"/>
             </a-form-item>
             </a-form-item>
           </a-col>
           </a-col>
           <a-col :md="6" :sm="24">
           <a-col :md="6" :sm="24">
@@ -23,7 +18,7 @@
     </div>
     </div>
     <!-- 操作按钮 -->
     <!-- 操作按钮 -->
     <div class="table-operator">
     <div class="table-operator">
-      <a-button id="warehouseList-add" type="primary" @click="handleEdit">新增仓库</a-button>
+      <a-button id="warehouseList-add" type="primary" @click="handleEdit()">新增仓库</a-button>
     </div>
     </div>
     <!-- 列表 -->
     <!-- 列表 -->
     <s-table
     <s-table
@@ -33,6 +28,7 @@
       :rowKey="(record) => record.id"
       :rowKey="(record) => record.id"
       :columns="columns"
       :columns="columns"
       :data="loadData"
       :data="loadData"
+      :showPagination="false"
       bordered>
       bordered>
       <!-- 仓位 -->
       <!-- 仓位 -->
       <template slot="storingLocation" slot-scope="text, record">
       <template slot="storingLocation" slot-scope="text, record">
@@ -45,13 +41,13 @@
       </template>
       </template>
     </s-table>
     </s-table>
     <!-- 新增/编辑仓库 -->
     <!-- 新增/编辑仓库 -->
-    <warehouse-edit-modal :openModal="openModal" :itemId="itemId" @close="closeModal" />
+    <warehouse-edit-modal :openModal="openModal" :nowData="nowData" :itemId="itemId" @ok="handleOk" @close="closeModal" />
   </a-card>
   </a-card>
 </template>
 </template>
 
 
 <script>
 <script>
 import moment from 'moment'
 import moment from 'moment'
-// import { customerBundleDelayList, customerBundleExportDelay } from '@/api/FinancialManagement'
+import { warehouseFindAll, warehouseDel } from '@/api/warehouse'
 import { STable, VSelect } from '@/components'
 import { STable, VSelect } from '@/components'
 import warehouseEditModal from './editModal.vue'
 import warehouseEditModal from './editModal.vue'
 export default {
 export default {
@@ -59,66 +55,45 @@ export default {
   data () {
   data () {
     return {
     return {
       queryParam: { //  查询条件
       queryParam: { //  查询条件
-        bundleName: '', //  品牌名称
-        state: undefined,  //  状态
+        name: '', //  仓库名称
       },
       },
       disabled: false, //  查询、重置按钮是否可操作
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
       columns: [
-        { title: '序号', dataIndex: 'no', width: 70, align: 'center' },
-        { title: '仓库名称', dataIndex: 'productName', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
-        { title: '排序', dataIndex: 'productOldNum', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '仓库名称', dataIndex: 'name', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
+        { title: '排序', dataIndex: 'sort', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '仓位', scopedSlots: { customRender: 'storingLocation' }, align: 'center' },
         { title: '仓位', scopedSlots: { customRender: 'storingLocation' }, align: 'center' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 240, align: 'center' }
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 240, align: 'center' }
       ],
       ],
       // 加载数据方法 必须为 Promise 对象
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
       loadData: parameter => {
         this.disabled = true
         this.disabled = true
-        // return customerBundleDelayList( Object.assign(parameter, this.queryParam) ).then(res => {
-        //   const data = res.data
-        //   const no = (data.pageNo - 1) * data.pageSize
-        //   for (var i = 0; i < data.list.length; i++) {
-        //     data.list[i].no = no + i + 1
-        //   }
-        //   this.disabled = false
-        //   return data
-        // })
-        const _this = this
-        return new Promise(function(resolve, reject){
-          const data = {
-            pageNo: 1,
-            pageSize: 10,
-            list: [
-              { id: '1', productNum: 'jgqp11111111111', productName: '产品1', productOldNum: 'jgqp111123545', warehouse: '箭冠品牌', productType: '产品分类1', inventoryNum: '5', inventoryMoney: '122' }
-            ]
-          }
-          const no = (data.pageNo - 1) * data.pageSize
-          for (var i = 0; i < data.list.length; i++) {
-            data.list[i].no = no + i + 1
-          }
-          _this.disabled = false
-          resolve(data)
+        return warehouseFindAll( this.queryParam ).then(res => {
+          const data = res.data
+          this.disabled = false
+          return data
         })
         })
       },
       },
       openModal: false,  //  新增编辑产品品牌  弹框
       openModal: false,  //  新增编辑产品品牌  弹框
-      itemId: ''  //  当前品牌id
+      itemId: '',  //  当前id
+      nowData: null  //  当前记录数据
     }
     }
   },
   },
   methods: {
   methods: {
     //  重置
     //  重置
     resetSearchForm () {
     resetSearchForm () {
-      this.queryParam.orderBundleNo = ''
-      this.queryParam.orderBundle.custMobile = ''
-      this.queryParam.bundleName = ''
-      this.queryParam.itemName = ''
-      this.oldTime = undefined
-      this.newTime = undefined
+      this.queryParam.name = ''
       this.$refs.table.refresh(true)
       this.$refs.table.refresh(true)
     },
     },
     //  新增/编辑
     //  新增/编辑
     handleEdit(row){
     handleEdit(row){
       this.itemId = row ? row.id : null
       this.itemId = row ? row.id : null
+      this.nowData = row ? row : null
       this.openModal = true
       this.openModal = true
     },
     },
+    //  新增/编辑  成功
+    handleOk(){
+      this.$refs.table.refresh(true)
+    },
     //  关闭弹框
     //  关闭弹框
     closeModal(){
     closeModal(){
       this.itemId = ''
       this.itemId = ''
@@ -133,28 +108,23 @@ export default {
         okText: '确定',
         okText: '确定',
         cancelText: '取消',
         cancelText: '取消',
         onOk () {
         onOk () {
-          // delectRolePower({
-          //   id: row.id
-          // }).then(res => {
-          //   console.log(res, 'res1111')
-          //   if (res.status == 200) {
-          //     _this.$message.success(res.message)
-          //     _this.$refs.table.refresh()
-          //   }
-          // })
+          warehouseDel({
+            id: row.id
+          }).then(res => {
+            if (res.status == 200) {
+              _this.$message.success(res.message)
+              _this.$refs.table.refresh()
+            }
+          })
         }
         }
       })
       })
     },
     },
     //  查看仓位
     //  查看仓位
     goStoringLocation(row){
     goStoringLocation(row){
       this.$router.push({ path: `/inventoryManagement/storingLocation/${row.id}` })
       this.$router.push({ path: `/inventoryManagement/storingLocation/${row.id}` })
-    },
+    }
   }
   }
 }
 }
 </script>
 </script>
 
 
-<style lang="less">
-  .warehouseList-wrap{
-    
-  }
-</style>
+<style lang="less"></style>

+ 62 - 9
src/views/inventoryManagement/warehouse/storingLocation/editModal.vue

@@ -26,9 +26,9 @@
             placeholder="请输入仓位名称(最多30个字符)"
             placeholder="请输入仓位名称(最多30个字符)"
             allowClear />
             allowClear />
         </a-form-model-item>
         </a-form-model-item>
-        <a-form-model-item label="所属仓库" prop="warehouse">
-          <a-select placeholder="请选择" allowClear v-model="form.warehouse">
-          	<a-select-option v-for="item in brandData" :key="item.salesChannelNo" :value="item.salesChannelNo">{{ item.salesChannelName }}</a-select-option>
+        <a-form-model-item label="所属仓库" prop="whId">
+          <a-select id="storingLocationEdit-whId" disabled placeholder="请选择所属仓库" allowClear v-model="form.whId">
+          	<a-select-option v-for="item in warehouseList" :key="item.id" :value="item.id">{{ item.name }}</a-select-option>
           </a-select>
           </a-select>
         </a-form-model-item>
         </a-form-model-item>
         <a-form-model-item label="排序" prop="sort">
         <a-form-model-item label="排序" prop="sort">
@@ -45,6 +45,7 @@
 
 
 <script>
 <script>
 import { STable } from '@/components'
 import { STable } from '@/components'
+import { warehouseLocSave, warehouseFindAll } from '@/api/warehouse'
 export default {
 export default {
   name: 'storingLocationEditModal',
   name: 'storingLocationEditModal',
   components: { STable },
   components: { STable },
@@ -56,6 +57,10 @@ export default {
     itemId: {
     itemId: {
       type: [Number, String],
       type: [Number, String],
       default: ''
       default: ''
+    },
+    nowData: {
+      type: Object,
+      default: null
     }
     }
   },
   },
   computed: {
   computed: {
@@ -72,28 +77,68 @@ export default {
       },
       },
       form: {
       form: {
         name: '', // 仓位名称
         name: '', // 仓位名称
-        warehouse: undefined,  //  所属仓库
+        whId: undefined,  //  所属仓库
         sort: '',  //  排序
         sort: '',  //  排序
       },
       },
       rules: {
       rules: {
         name: [
         name: [
           { required: true, message: '请输入仓位名称', trigger: 'blur' }
           { required: true, message: '请输入仓位名称', trigger: 'blur' }
         ],
         ],
-        warehouse: [
+        whId: [
           { required: true, message: '请选择所属仓库', trigger: 'change' }
           { required: true, message: '请选择所属仓库', trigger: 'change' }
         ],
         ],
       },
       },
-      brandData: []  //  仓库  下拉数据
+      warehouseList: []  //  仓库  下拉数据
     }
     }
   },
   },
   methods: {
   methods: {
-    //  获取详情
+    //  获取仓库列表数据
+    getWarehouseList(){
+      warehouseFindAll({}).then(res => {
+        if(res.status == 200){
+          this.warehouseList = res.data
+        }else{
+          this.warehouseList = []
+        }
+      })
+    },
+    //  详情
     getDetail(){
     getDetail(){
-      
+      this.form = {
+        name: this.nowData && this.nowData.name ? this.nowData.name : '',
+        whId: this.nowData && this.nowData.whId ? this.nowData.whId : '',
+        sort: this.nowData && this.nowData.sort ? this.nowData.sort : ''
+      }
     },
     },
     //  保存
     //  保存
     handleSave(){
     handleSave(){
-      
+      const _this = this
+      this.$refs.ruleForm.validate(valid => {
+        if (valid) {
+          const params = {
+            id: this.itemId ? this.itemId : undefined,
+            whId: this.form.whId,  //  所属仓库
+            name: this.form.name,  //  仓库名称
+            sort: this.form.sort,  //  排序
+            isDefault: 0  //  是否为默认仓位   0为非默认,1为默认
+          }
+          warehouseLocSave(params).then(res => {
+            if(res.status == 200){
+              _this.$message.success(res.message)
+              _this.$emit('ok')
+              setTimeout(function () {
+                _this.isShow = false
+                _this.$refs.ruleForm.resetFields()
+              }, 300)
+            }else{
+              
+            }
+          })
+        } else {
+          console.log('error submit!!')
+          return false
+        }
+      })
     },
     },
   },
   },
   watch: {
   watch: {
@@ -104,7 +149,15 @@ export default {
     //  重定义的弹框状态
     //  重定义的弹框状态
     isShow (newValue, oldValue) {
     isShow (newValue, oldValue) {
       if (!newValue) {
       if (!newValue) {
+        this.$refs.ruleForm.resetFields()
         this.$emit('close')
         this.$emit('close')
+      }else{
+        this.getWarehouseList()
+        this.form = {
+          name: '',
+          whId: this.nowData && this.nowData.whId ? this.nowData.whId : '',
+          sort: ''
+        }
       }
       }
     },
     },
     itemId (newValue, oldValue) {
     itemId (newValue, oldValue) {

+ 83 - 91
src/views/inventoryManagement/warehouse/storingLocation/list.vue

@@ -1,54 +1,57 @@
 <template>
 <template>
-  <a-card :bordered="false" class="storingLocationList-wrap">
-    <!-- 搜索条件 -->
-    <div class="table-page-search-wrapper">
-      <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
-        <a-row :gutter="15">
-          <a-col :md="6" :sm="24">
-            <a-form-item label="仓位名称">
-              <a-input id="storingLocationList-bundleName" v-model.trim="queryParam.bundleName" allowClear placeholder="请输入仓位名称"/>
-            </a-form-item>
-          </a-col>
-          <a-col :md="6" :sm="24">
-            <a-form-item label="状态">
-              <v-select code="CHECK_ENABLE_STATE" id="storingLocationList-state" v-model="queryParam.state" allowClear placeholder="请选择状态"></v-select>
-            </a-form-item>
-          </a-col>
-          <a-col :md="6" :sm="24">
-            <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="storingLocationList-refresh">查询</a-button>
-            <a-button style="margin-left: 8px" @click="resetSearchForm" :disabled="disabled" id="storingLocationList-reset">重置</a-button>
-          </a-col>
-        </a-row>
-      </a-form>
-    </div>
-    <!-- 操作按钮 -->
-    <div class="table-operator">
-      <a-button id="storingLocationList-back" @click="handleBack">返回列表</a-button>
-      <a-button id="storingLocationList-add" type="primary" @click="handleEdit">新增仓位</a-button>
-    </div>
-    <!-- 列表 -->
-    <s-table
-      class="sTable"
-      ref="table"
-      size="default"
-      :rowKey="(record) => record.id"
-      :columns="columns"
-      :data="loadData"
-      bordered>
-      <!-- 操作 -->
-      <template slot="action" slot-scope="text, record">
-        <a-button type="primary" @click="handleEdit(record)" id="storingLocationList-edit-btn">编辑</a-button>
-        <a-button type="danger" @click="handleDel(record)" id="storingLocationList-del-btn" style="margin-left: 15px;">删除</a-button>
+  <div class="storingLocationList-wrap">
+    <a-page-header :ghost="false" @back="handleBack" class="storingLocationList-back">
+      <!-- 自定义的二级文字标题 -->
+      <template slot="subTitle">
+        <a id="storingLocationList-back-btn" href="javascript:;" @click="handleBack">返回列表</a>
       </template>
       </template>
-    </s-table>
+    </a-page-header>
+    <a-card :bordered="false" class="storingLocationList-cont">
+      <!-- 搜索条件 -->
+      <div class="table-page-search-wrapper">
+        <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
+          <a-row :gutter="15">
+            <a-col :md="6" :sm="24">
+              <a-form-item label="仓位名称">
+                <a-input id="storingLocationList-name" v-model.trim="queryParam.name" allowClear placeholder="请输入仓位名称"/>
+              </a-form-item>
+            </a-col>
+            <a-col :md="6" :sm="24">
+              <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="storingLocationList-refresh">查询</a-button>
+              <a-button style="margin-left: 8px" @click="resetSearchForm" :disabled="disabled" id="storingLocationList-reset">重置</a-button>
+            </a-col>
+          </a-row>
+        </a-form>
+      </div>
+      <!-- 操作按钮 -->
+      <div class="table-operator">
+        <a-button id="storingLocationList-add" type="primary" @click="handleEdit()">新增仓位</a-button>
+      </div>
+      <!-- 列表 -->
+      <s-table
+        class="sTable"
+        ref="table"
+        size="default"
+        :rowKey="(record) => record.id"
+        :columns="columns"
+        :data="loadData"
+        :showPagination="false"
+        bordered>
+        <!-- 操作 -->
+        <template slot="action" slot-scope="text, record">
+          <a-button type="primary" @click="handleEdit(record)" id="storingLocationList-edit-btn">编辑</a-button>
+          <a-button type="danger" @click="handleDel(record)" id="storingLocationList-del-btn" style="margin-left: 15px;">删除</a-button>
+        </template>
+      </s-table>
+    </a-card>
     <!-- 新增/编辑仓位 -->
     <!-- 新增/编辑仓位 -->
-    <storing-location-edit-modal :openModal="openModal" :itemId="itemId" @close="closeModal" />
-  </a-card>
+    <storing-location-edit-modal :openModal="openModal" :nowData="nowData" :itemId="itemId" @ok="handleOk" @close="closeModal" />
+  </div>
 </template>
 </template>
 
 
 <script>
 <script>
 import moment from 'moment'
 import moment from 'moment'
-// import { customerBundleDelayList, customerBundleExportDelay } from '@/api/FinancialManagement'
+import { warehouseLocFindAll, warehouseFindAll, warehouseLocDel } from '@/api/warehouse'
 import { STable, VSelect } from '@/components'
 import { STable, VSelect } from '@/components'
 import storingLocationEditModal from './editModal.vue'
 import storingLocationEditModal from './editModal.vue'
 export default {
 export default {
@@ -56,65 +59,52 @@ export default {
   data () {
   data () {
     return {
     return {
       queryParam: { //  查询条件
       queryParam: { //  查询条件
-        bundleName: '', //  仓位名称
-        state: undefined,  //  状态
+        whId: this.$route.params.id,  //  仓库id
+        name: '', //  仓位名称
       },
       },
       disabled: false, //  查询、重置按钮是否可操作
       disabled: false, //  查询、重置按钮是否可操作
       columns: [
       columns: [
-        { title: '序号', dataIndex: 'no', width: 70, align: 'center' },
-        { title: '仓位名称', dataIndex: 'productName', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
-        { title: '排序', dataIndex: 'productOldNum', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '仓位名称', dataIndex: 'name', align: 'center', ellipsis: true },
+        { title: '排序', dataIndex: 'sort', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 240, align: 'center' }
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 240, align: 'center' }
       ],
       ],
       // 加载数据方法 必须为 Promise 对象
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
       loadData: parameter => {
         this.disabled = true
         this.disabled = true
-        // return customerBundleDelayList( Object.assign(parameter, this.queryParam) ).then(res => {
-        //   const data = res.data
-        //   const no = (data.pageNo - 1) * data.pageSize
-        //   for (var i = 0; i < data.list.length; i++) {
-        //     data.list[i].no = no + i + 1
-        //   }
-        //   this.disabled = false
-        //   return data
-        // })
-        const _this = this
-        return new Promise(function(resolve, reject){
-          const data = {
-            pageNo: 1,
-            pageSize: 10,
-            list: [
-              { id: '1', productNum: 'jgqp11111111111', productName: '产品1', productOldNum: 'jgqp111123545', storingLocation: '箭冠品牌', productType: '产品分类1', inventoryNum: '5', inventoryMoney: '122' }
-            ]
-          }
-          const no = (data.pageNo - 1) * data.pageSize
-          for (var i = 0; i < data.list.length; i++) {
-            data.list[i].no = no + i + 1
-          }
-          _this.disabled = false
-          resolve(data)
+        return warehouseLocFindAll( this.queryParam ).then(res => {
+          const data = res.data
+          this.disabled = false
+          return data
         })
         })
       },
       },
       openModal: false,  //  新增编辑产品品牌  弹框
       openModal: false,  //  新增编辑产品品牌  弹框
-      itemId: ''  //  当前品牌id
+      itemId: '',  //  当前品牌id
+      nowData: null  //  当前记录数据
     }
     }
   },
   },
   methods: {
   methods: {
     //  重置
     //  重置
     resetSearchForm () {
     resetSearchForm () {
-      this.queryParam.orderBundleNo = ''
-      this.queryParam.orderBundle.custMobile = ''
-      this.queryParam.bundleName = ''
-      this.queryParam.itemName = ''
-      this.oldTime = undefined
-      this.newTime = undefined
+      this.queryParam.whId = this.$route.params.id
+      this.queryParam.name = ''
       this.$refs.table.refresh(true)
       this.$refs.table.refresh(true)
     },
     },
     //  新增/编辑
     //  新增/编辑
     handleEdit(row){
     handleEdit(row){
-      this.itemId = row ? row.id : null
+      if(row){
+        this.itemId = row.id
+        row.whId = this.$route.params.id
+        this.nowData = row
+      }else{
+        this.itemId = null
+        this.nowData = { whId: this.$route.params.id }
+      }
       this.openModal = true
       this.openModal = true
     },
     },
+    //  新增/编辑  成功
+    handleOk(){
+      this.$refs.table.refresh(true)
+    },
     //  关闭弹框
     //  关闭弹框
     closeModal(){
     closeModal(){
       this.itemId = ''
       this.itemId = ''
@@ -129,15 +119,15 @@ export default {
         okText: '确定',
         okText: '确定',
         cancelText: '取消',
         cancelText: '取消',
         onOk () {
         onOk () {
-          // delectRolePower({
-          //   id: row.id
-          // }).then(res => {
-          //   console.log(res, 'res1111')
-          //   if (res.status == 200) {
-          //     _this.$message.success(res.message)
-          //     _this.$refs.table.refresh()
-          //   }
-          // })
+          warehouseLocDel({
+            id: row.id,
+            whId: _this.$route.params.id
+          }).then(res => {
+            if (res.status == 200) {
+              _this.$message.success(res.message)
+              _this.$refs.table.refresh()
+            }
+          })
         }
         }
       })
       })
     },
     },
@@ -151,6 +141,8 @@ export default {
 
 
 <style lang="less">
 <style lang="less">
   .storingLocationList-wrap{
   .storingLocationList-wrap{
-    
+    .storingLocationList-back{
+      margin-bottom: 15px;
+    }
   }
   }
 </style>
 </style>

+ 109 - 0
src/views/inventoryManagement/warehouseAllocation/basicInfoModal.vue

@@ -0,0 +1,109 @@
+<template>
+	<a-modal centered class="warehouseAllocation-basicInfo-modal" :footer="null" :maskClosable="false" title="新建散件入库单" v-model="isShow" @cancle="isShow = false" width="80%">
+		<a-form-model
+			id="warehouseAllocation-basicInfo-form"
+			ref="ruleForm"
+			:model="form"
+			:rules="rules"
+			:label-col="formItemLayout.labelCol"
+			:wrapper-col="formItemLayout.wrapperCol"
+		>
+			<a-form-model-item label="调出仓库" prop="sort">
+				<v-select
+					v-model="form.billStatus"
+					ref="billStatus"
+					id="warehouseAllocation-basicInfo-billStatus"
+					code="PAYMENT_TYPE"
+					placeholder="请选择调出仓库"
+					allowClear
+				></v-select>
+			</a-form-model-item>
+			<a-form-model-item label="调入仓库" prop="sort">
+				<v-select
+					v-model="form.billStatus"
+					ref="billStatus"
+					id="warehouseAllocation-basicInfo-billStatus"
+					code="PAYMENT_TYPE"
+					placeholder="请选择调入仓库"
+					allowClear
+				></v-select>
+			</a-form-model-item>
+			<a-form-model-item label="关联单号" prop="address">
+				<a-input id="warehouseAllocation-basicInfo-address" :maxLength="30" v-model="form.address" placeholder="请输入关联单号(最多30个字符)" allowClear />
+			</a-form-model-item>
+			<a-form-model-item label="备注" prop="remarks">
+				<a-textarea id="warehouseAllocation-basicInfo-remarks" :maxLength="500" v-model="form.remarks" placeholder="请输入备注(最多500个字符)" allowClear />
+			</a-form-model-item>
+		</a-form-model>
+		<div class="btn-cont">
+			<a-button type="primary" id="warehouseAllocation-basicInfo-modal-save" @click="handleSave">保存</a-button>
+			<a-button id="warehouseAllocation-basicInfo-modal-back" @click="isShow = false" style="margin-left: 15px;">取消</a-button>
+		</div>
+	</a-modal>
+</template>
+
+<script>
+import { VSelect } from '@/components';
+export default {
+	name: 'WarehouseAllocationBasicInfoModal',
+	components: { VSelect },
+	props: {
+		openModal: {
+			//  弹框显示状态
+			type: Boolean,
+			default: false
+		}
+	},
+	data() {
+		return {
+			isShow: this.openModal, //  是否打开弹框
+			formItemLayout: {
+				labelCol: { span: 6 },
+				wrapperCol: { span: 16 }
+			},
+			form: {
+				name: '', // 仓库名称
+				sort: '' //  排序
+			},
+			rules: {
+				name: [{ required: true, message: '请输入仓库名称', trigger: 'blur' }]
+			},
+			brandData: [] //  供应商  下拉数据
+		};
+	},
+	methods: {
+		//  保存
+		handleSave() {
+			this.isShow = false
+			this.$emit('ok')
+		},
+		filterOption(input, option) {
+			return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+		}
+	},
+	watch: {
+		//  父页面传过来的弹框状态
+		openModal(newValue, oldValue) {
+			this.isShow = newValue
+		},
+		//  重定义的弹框状态
+		isShow(newValue, oldValue) {
+			if (!newValue) {
+				this.$emit('close')
+			}
+		}
+	}
+};
+</script>
+
+<style lang="less">
+.warehouseAllocation-basicInfo-modal {
+	.ant-modal-body {
+		padding: 40px 40px 24px;
+	}
+	.btn-cont {
+		text-align: center;
+		margin: 35px 0 10px;
+	}
+}
+</style>

+ 163 - 0
src/views/inventoryManagement/warehouseAllocation/detail.vue

@@ -0,0 +1,163 @@
+<template>
+  <div class="warehouseAllocationDetail-wrap">
+    <a-page-header :ghost="false" @back="handleBack" class="warehouseAllocationDetail-back">
+      <!-- 自定义的二级文字标题 -->
+      <template slot="subTitle">
+        <a id="warehouseAllocationDetail-back-btn" href="javascript:;" @click="handleBack">返回列表</a>
+      </template>
+      <!-- 操作区,位于 title 行的行尾 -->
+      <template slot="extra">
+        <a-button key="2" id="warehouseAllocationDetail-preview-btn">打印预览</a-button>
+        <a-button key="1" type="primary" id="warehouseAllocationDetail-print-btn">快速打印</a-button>
+        <a-button key="3" type="danger" @click="handleExport" :loading="exportLoading" id="warehouseAllocationDetail-export-btn">导出</a-button>
+      </template>
+    </a-page-header>
+    <!-- 基础信息 -->
+    <a-card :bordered="false" class="warehouseAllocationDetail-cont">
+      <a-collapse :activeKey="['1']">
+        <a-collapse-panel key="1" header="基础信息">
+          <a-descriptions :column="3">
+            <a-descriptions-item label="调出仓库">箭冠营销中心</a-descriptions-item>
+            <a-descriptions-item label="调入仓库">箭冠营销中心</a-descriptions-item>
+            <a-descriptions-item label="调拨单号">箭冠营销中心</a-descriptions-item>
+            <a-descriptions-item label="关联单号">箭冠营销中心</a-descriptions-item>
+            <a-descriptions-item label="审核状态">箭冠营销中心</a-descriptions-item>
+            <a-descriptions-item label="完结状态">箭冠营销中心</a-descriptions-item>
+            <a-descriptions-item label="备注">箭冠营销中心</a-descriptions-item>
+          </a-descriptions>
+        </a-collapse-panel>
+      </a-collapse>
+    </a-card>
+    <!-- 详情 -->
+    <a-card :bordered="false" class="warehouseAllocationDetail-cont">
+      <a-collapse :activeKey="['1']">
+        <a-collapse-panel key="1" header="详情">
+          <!-- 总计 -->
+          <a-alert type="info" showIcon style="margin-bottom:15px">
+            <div slot="message">总款数: <strong>6</strong> ,总数量: <strong>6</strong> ,总成本:¥<strong>6.33</strong></div>
+          </a-alert>
+          <!-- 列表 -->
+          <s-table
+            class="sTable"
+            ref="table"
+            size="default"
+            :rowKey="(record) => record.id"
+            :columns="columns"
+            :data="loadData"
+            bordered>
+            <!-- 采购数量 -->
+            <template slot="purchaseNum" slot-scope="text, record">
+              <span>{{record.purchaseNum}}</span>
+            </template>
+            <!-- 缺货数量 -->
+            <template slot="outOfStockNum" slot-scope="text, record">
+              <span>{{record.outOfStockNum}}</span>
+            </template>
+          </s-table>
+        </a-collapse-panel>
+      </a-collapse>
+    </a-card>
+  </div>
+</template>
+
+<script>
+  import { STable, VSelect } from '@/components'
+  export default{
+    components: { STable, VSelect },
+    data(){
+      return{
+        exportLoading: false, // 导出loading
+        // 表头
+        columns: [
+          { title: '序号', dataIndex: 'no', align: 'center' },
+          { title: '产品编码', dataIndex: 'creatDate', align: 'center' },
+          { title: '产品名称', dataIndex: 'custName', align: 'center' },
+          { title: '原厂编码', dataIndex: 'totalP', align: 'center' },
+          { title: '类别', dataIndex: 'tostalP', align: 'center' },
+          { title: '数量', scopedSlots: { customRender: 'outOfStockNum' }, align: 'center' },
+          { title: '单位', dataIndex: 'mementPay', align: 'center' },
+          { title: '成本小计', dataIndex: 'totalNums', align: 'center' },
+          { title: '调出仓位', dataIndex: 'shDate', align: 'center' },
+          { title: '调入仓位', dataIndex: 'shDsate', align: 'center' },
+        ],
+        // 加载数据方法 必须为 Promise 对象
+        loadData: parameter => {
+          this.disabled = true
+          // return customerBundleDelayList( Object.assign(parameter, this.queryParam) ).then(res => {
+          //   const data = res.data
+          //   const no = (data.pageNo - 1) * data.pageSize
+          //   for (var i = 0; i < data.list.length; i++) {
+          //     data.list[i].no = no + i + 1
+          //   }
+          //   this.disabled = false
+          //   return data
+          // })
+          const _this = this
+          return new Promise(function(resolve, reject){
+            const data = {
+              pageNo: 1,
+              pageSize: 10,
+              list: [
+                { id: '1', purchaseNo: 'jgqp11111111111', creatDate: '产品1', custName: 'jgqp111123545', totalP: '箭冠品牌', totalNums: '产品分类1', totalPrice: '5', payType: '122' }
+              ],
+              count: 10
+            }
+            const no = (data.pageNo - 1) * data.pageSize
+            for (var i = 0; i < data.list.length; i++) {
+              data.list[i].no = no + i + 1
+            }
+            _this.disabled = false
+            resolve(data)
+          })
+        },
+      }
+    },
+    methods: {
+      //  返回列表
+      handleBack(){
+        this.$router.push({ path: '/inventoryManagement/warehouseAllocation/list'})
+      },
+      //  导出
+      handleExport () {
+        const params = this.queryParam
+        if (this.oldTime && this.oldTime.length > 0) {
+          params.beginOldExpiryDate = moment(this.oldTime[0]).format('YYYY-MM-DD')
+          params.endOldExpirydDate = moment(this.oldTime[1]).format('YYYY-MM-DD')
+        } else {
+          params.beginOldExpiryDate = ''
+          params.endOldExpirydDate = ''
+        }
+        if (this.newTime && this.newTime.length > 0) {
+          params.beginDate = moment(this.newTime[0]).format('YYYY-MM-DD')
+          params.endDate = moment(this.newTime[1]).format('YYYY-MM-DD')
+        } else {
+          params.beginDate = ''
+          params.endDate = ''
+        }
+        this.exportLoading = true
+        customerBundleExportDelay(params).then(res => {
+          this.exportLoading = false
+          this.download(res)
+        })
+      },
+      download (data) {
+        if (!data) { return }
+        const url = window.URL.createObjectURL(new Blob([data]))
+        const link = document.createElement('a')
+        link.style.display = 'none'
+        link.href = url
+        const a = moment().format('YYYYMMDDHHmmss')
+        const fname = '仓库调拨' + a
+        link.setAttribute('download', fname + '.xlsx')
+        document.body.appendChild(link)
+        link.click()
+      }
+    }
+  }
+</script>
+
+<style lang="less">
+  .warehouseAllocationDetail-cont, .warehouseAllocationDetail-back{
+    margin-bottom: 15px;
+  }
+</style>

+ 380 - 0
src/views/inventoryManagement/warehouseAllocation/edit.vue

@@ -0,0 +1,380 @@
+<template>
+  <div class="warehouseAllocationEdit-wrap">
+    <a-page-header :ghost="false" @back="handleBack" class="warehouseAllocationEdit-back">
+      <!-- 自定义的二级文字标题 -->
+      <template slot="subTitle">
+        <a id="warehouseAllocationEdit-back-btn" href="javascript:;" @click="handleBack">返回列表</a>
+      </template>
+      <!-- 操作区,位于 title 行的行尾 -->
+      <template slot="extra">
+        <a-button key="2" id="warehouseAllocationEdit-preview-btn">打印预览</a-button>
+        <a-button key="1" type="primary" id="warehouseAllocationEdit-print-btn">快速打印</a-button>
+      </template>
+    </a-page-header>
+    <!-- 基础信息 -->
+    <a-card :bordered="false" class="warehouseAllocationEdit-cont">
+      <a-collapse :activeKey="['1']">
+        <a-collapse-panel key="1">
+          <template slot="header">
+            基础信息
+            <a-button type="primary" shape="circle" size="small" icon="edit" class="edit-circle-btn" id="warehouseAllocationEdit-circle-btn" @click.stop="handleEditInfo" />
+          </template>
+          <a-descriptions :column="3">
+            <a-descriptions-item label="调出仓库">箭冠营销中心</a-descriptions-item>
+            <a-descriptions-item label="调入仓库">箭冠营销中心</a-descriptions-item>
+          </a-descriptions>
+        </a-collapse-panel>
+      </a-collapse>
+    </a-card>
+    <!-- 选择产品 -->
+    <a-card :bordered="false" class="warehouseAllocationEdit-cont">
+      <a-collapse :activeKey="['1']">
+        <a-collapse-panel key="1" header="选择产品">
+          <!-- 筛选条件 -->
+          <div class="table-page-search-wrapper">
+            <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
+              <a-row :gutter="15">
+                <a-col :md="6" :sm="24">
+                  <a-form-item label="产品编码" prop="name">
+                    <a-input id="warehouseAllocationEdit-name" v-model="queryParam.name" placeholder="请输入产品编码" allowClear />
+                  </a-form-item>
+                </a-col>
+                <a-col :md="6" :sm="24">
+                  <a-form-item label="产品名称" prop="name">
+                    <a-input id="warehouseAllocationEdit-name" v-model="queryParam.name" placeholder="请输入产品名称" allowClear />
+                  </a-form-item>
+                </a-col>
+                <a-col :md="6" :sm="24">
+                  <a-form-item label="原厂编码" prop="name">
+                    <a-input id="warehouseAllocationEdit-name" v-model="queryParam.name" placeholder="请输入原厂编码" allowClear />
+                  </a-form-item>
+                </a-col>
+                <template v-if="advanced">
+                  <a-col :md="6" :sm="24">
+                    <a-form-item label="产品品牌">
+                      <a-select placeholder="请选择" id="warehouseAllocationEdit-state" allowClear v-model="queryParam.dataSourceNo" :showSearch="true" option-filter-prop="children" :filter-option="filterOption">
+                        <a-select-option v-for="item in brandData" :key="item.salesChannelNo" :value="item.salesChannelNo">{{ item.salesChannelName }}</a-select-option>
+                      </a-select>
+                    </a-form-item>
+                  </a-col>
+                  <a-col :md="6" :sm="24">
+                    <a-form-item label="产品类别">
+                      <a-cascader :options="typeData" id="warehouseAllocationEdit-state" placeholder="请选择产品类别" allowClear v-model="queryParam.brand" />
+                    </a-form-item>
+                  </a-col>
+                  <a-col :md="6" :sm="24">
+                    <a-form-item label="调出仓位">
+                      <v-select
+                        v-model="queryParam.billStatus"
+                        ref="billStatus"
+                        id="warehouseAllocationEdit-billStatus"
+                        code="PAYMENT_TYPE"
+                        placeholder="请选择调出仓位"
+                        allowClear></v-select>
+                    </a-form-item>
+                  </a-col>
+                </template>
+                <a-col :md="6" :sm="24" style="margin-bottom: 24px;">
+                  <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="warehouseAllocationList-refresh">查询</a-button>
+                  <a-button style="margin-left: 8px" @click="resetSearchForm" :disabled="disabled" id="warehouseAllocationList-reset">重置</a-button>
+                  <a @click="advanced=!advanced" style="margin-left: 8px">
+                    {{ advanced ? '收起' : '展开' }}
+                    <a-icon :type="advanced ? 'up' : 'down'"/>
+                  </a>
+                </a-col>
+              </a-row>
+            </a-form>
+          </div>
+          <!-- 列表 -->
+          <s-table
+            class="sTable"
+            ref="table"
+            size="default"
+            :rowKey="(record) => record.id"
+            :columns="columns"
+            :data="loadData"
+            bordered>
+            <!-- 调入仓位 -->
+            <template slot="storageQuantity" slot-scope="text, record">
+              <a-select id="warehouseAllocationEdit-warehouse" placeholder="请选择" allowClear v-model="record.warehouse">
+              	<a-select-option v-for="item in typeData" :key="item.salesChannelNo" :value="item.salesChannelNo">{{ item.salesChannelName }}</a-select-option>
+              </a-select>
+            </template>
+            <!-- 调出数量 -->
+            <template slot="transferOutQuantity" slot-scope="text, record">
+              <a-input-number
+                id="warehouseAllocationEdit-storageQuantity"
+                :value="record.storageQuantity"
+                :precision="0"
+                :min="0"
+                :max="999999"
+                placeholder="请输入" />
+            </template>
+            <!-- 操作 -->
+            <template slot="action" slot-scope="text, record">
+              <a-button type="primary" @click="handleAdd(record)" id="warehouseAllocationEdit-add-btn">添加</a-button>
+            </template>
+          </s-table>
+        </a-collapse-panel>
+      </a-collapse>
+    </a-card>
+    <!-- 已选产品 -->
+    <a-card :bordered="false" class="warehouseAllocationEdit-cont">
+      <a-collapse :activeKey="['1']">
+        <a-collapse-panel key="1" header="已选产品">
+          <!-- 总计 -->
+          <a-alert type="info" showIcon style="margin-bottom:15px">
+            <div slot="message">总成本:¥<strong>6.33</strong>,总数量: <strong>6</strong> ,总款数: <strong>6</strong> </div>
+          </a-alert>
+          <!-- 筛选条件 -->
+          <a-row :gutter="15" justify="space-between">
+            <a-col :span="18">
+              <div class="table-page-search-wrapper">
+                <a-form layout="inline" @keyup.enter.native="$refs.chooseTable.refresh(true)">
+                  <a-row :gutter="15">
+                    <a-col :md="6" :sm="24">
+                      <a-form-item label="产品编码" prop="name">
+                        <a-input id="warehouseAllocationEdit-name" v-model="queryParam.name" placeholder="请输入产品编码" allowClear />
+                      </a-form-item>
+                    </a-col>
+                    <a-col :md="6" :sm="24">
+                      <a-form-item label="产品名称" prop="name">
+                        <a-input id="warehouseAllocationEdit-name" v-model="queryParam.name" placeholder="请输入产品名称" allowClear />
+                      </a-form-item>
+                    </a-col>
+                    <a-col :md="6" :sm="24" style="margin-bottom: 24px;">
+                      <a-button type="primary" @click="$refs.chooseTable.refresh(true)" :disabled="disabled" id="warehouseAllocationList-refresh">查询</a-button>
+                      <a-button style="margin-left: 8px" @click="resetSearchForm" :disabled="disabled" id="warehouseAllocationList-reset">重置</a-button>
+                    </a-col>
+                  </a-row>
+                </a-form>
+              </div>
+            </a-col>
+            <a-col :span="6">
+              <a-button type="primary" id="warehouseAllocationEdit-pladd-btn">批量添加</a-button>
+              <a-button style="margin-left: 8px" id="warehouseAllocationEdit-import-btn">导入明细</a-button>
+              <a-button type="danger" style="margin-left: 8px" id="warehouseAllocationEdit-del-all-btn">整单删除</a-button>
+            </a-col>
+          </a-row>
+          <!-- 列表 -->
+          <s-table
+            class="sTable"
+            ref="chooseTable"
+            size="default"
+            :rowKey="(record) => record.id"
+            :columns="chooseColumns"
+            :data="chooseLoadData"
+            bordered>
+            <!-- 调入仓位 -->
+            <template slot="storageQuantity" slot-scope="text, record">
+              <a-select id="warehouseAllocationEdit-warehouse" placeholder="请选择" allowClear v-model="record.warehouse">
+              	<a-select-option v-for="item in typeData" :key="item.salesChannelNo" :value="item.salesChannelNo">{{ item.salesChannelName }}</a-select-option>
+              </a-select>
+            </template>
+            <!-- 调出数量 -->
+            <template slot="transferOutQuantity" slot-scope="text, record">
+              <a-input-number
+                id="warehouseAllocationEdit-storageQuantity"
+                :value="record.storageQuantity"
+                :precision="0"
+                :min="0"
+                :max="999999"
+                placeholder="请输入" />
+            </template>
+            <!-- 操作 -->
+            <template slot="action" slot-scope="text, record">
+              <a-button type="danger" @click="handleDel(record)" id="warehouseAllocationEdit-del-btn">删除</a-button>
+            </template>
+          </s-table>
+        </a-collapse-panel>
+      </a-collapse>
+    </a-card>
+    <a-affix :offset-bottom="0">
+      <div style="text-align: center;width: 100%;background-color: #fff;padding: 30px 0;box-shadow: 0 0 20px #dcdee2;">
+        <a-button type="primary" size="large" @click="handleSubmit" style="padding: 0 60px;">提交</a-button>
+      </div>
+    </a-affix>
+    <!-- 选择基本信息弹框 -->
+    <basic-info-modal :openModal="openModal" @ok="handleOk" @close="openModal=false" />
+  </div>
+</template>
+
+<script>
+  import { STable, VSelect } from '@/components'
+  import basicInfoModal from './basicInfoModal.vue'
+  export default{
+    components: { STable, VSelect, basicInfoModal },
+    data(){
+      return{
+        queryParam: {
+          
+        },
+        brandData: [],  //  产品品牌  下拉数据
+        typeData: [],  //  产品类别  下拉数据
+        disabled: false, //  查询、重置按钮是否可操作
+        advanced: false,  // 高级搜索 展开/关闭
+        // 表头
+        columns: [
+          { title: '产品编码', dataIndex: 'creatDate', align: 'center' },
+          { title: '产品名称', dataIndex: 'custNahme', align: 'center', ellipsis: true },
+          { title: '原厂编码', dataIndex: 'totalP', align: 'center' },
+          { title: '品牌', dataIndex: 'custsNsame', align: 'center' },
+          { title: '类别', dataIndex: 'custsNdame', align: 'center' },
+          { title: '调出仓位', dataIndex: 'custsNafme', align: 'center' },
+          { title: '调入仓位', scopedSlots: { customRender: 'storageQuantity' }, align: 'center' },
+          { title: '库存数量', dataIndex: 'custsNagme', align: 'center' },
+          { title: '单位', dataIndex: 'custsNsagme', align: 'center' },
+          { title: '调出数量', scopedSlots: { customRender: 'transferOutQuantity' }, align: 'center' },
+          { title: '操作', scopedSlots: { customRender: 'action' }, width: 150, align: 'center' }
+        ],
+        // 加载数据方法 必须为 Promise 对象
+        loadData: parameter => {
+          this.disabled = true
+          // return customerBundleDelayList( Object.assign(parameter, this.queryParam) ).then(res => {
+          //   const data = res.data
+          //   const no = (data.pageNo - 1) * data.pageSize
+          //   for (var i = 0; i < data.list.length; i++) {
+          //     data.list[i].no = no + i + 1
+          //   }
+          //   this.disabled = false
+          //   return data
+          // })
+          const _this = this
+          return new Promise(function(resolve, reject){
+            const data = {
+              pageNo: 1,
+              pageSize: 10,
+              list: [
+                { id: '1', purchaseNo: 'jgqp11111111111', creatDate: '产品1', custName: 'jgqp111123545', totalP: '箭冠品牌', totalNums: '产品分类1', totalPrice: '5', payType: '122' }
+              ],
+              count: 10
+            }
+            const no = (data.pageNo - 1) * data.pageSize
+            for (var i = 0; i < data.list.length; i++) {
+              data.list[i].no = no + i + 1
+            }
+            _this.disabled = false
+            resolve(data)
+          })
+        },
+        // 表头
+        chooseColumns: [
+          { title: '产品编码', dataIndex: 'creatDaite', align: 'center', sorter: true },
+          { title: '产品名称', dataIndex: 'custNayme', align: 'center' },
+          { title: '原厂编码', dataIndex: 'custNdayme', align: 'center' },
+          { title: '品牌', dataIndex: 'mementPsay', align: 'center' },
+          { title: '类别', dataIndex: 'mementPay', align: 'center' },
+          { title: '调出仓位', scopedSlots: { customRender: 'storageQuantity' }, align: 'center' },
+          { title: '调入仓位', dataIndex: 'custsNakme', align: 'center' },
+          { title: '单位', dataIndex: 'custssNakme', align: 'center' },
+          { title: '调出数量', scopedSlots: { customRender: 'transferOutQuantity' }, align: 'center' },
+          { title: '操作', scopedSlots: { customRender: 'action' }, width: 150, align: 'center' }
+        ],
+        // 加载数据方法 必须为 Promise 对象
+        chooseLoadData: parameter => {
+          this.disabled = true
+          // return customerBundleDelayList( Object.assign(parameter, this.queryParam) ).then(res => {
+          //   const data = res.data
+          //   const no = (data.pageNo - 1) * data.pageSize
+          //   for (var i = 0; i < data.list.length; i++) {
+          //     data.list[i].no = no + i + 1
+          //   }
+          //   this.disabled = false
+          //   return data
+          // })
+          const _this = this
+          return new Promise(function(resolve, reject){
+            const data = {
+              pageNo: 1,
+              pageSize: 10,
+              list: [
+                { id: '1', purchaseNo: 'jgqp11111111111', custssName: 0, creatDate: '产品1', custName: 'jgqp111123545', totalP: '箭冠品牌', totalNums: '产品分类1', totalPrice: '5', payType: '122' }
+              ],
+              count: 10
+            }
+            const no = (data.pageNo - 1) * data.pageSize
+            for (var i = 0; i < data.list.length; i++) {
+              data.list[i].no = no + i + 1
+            }
+            _this.disabled = false
+            resolve(data)
+          })
+        },
+        openModal: false, // 选择基本信息弹框是否显示
+      }
+    },
+    methods: {
+      //  重置
+      resetSearchForm () {
+        this.queryParam.orderBundleNo = ''
+        this.queryParam.orderBundle.custMobile = ''
+        this.queryParam.bundleName = ''
+        this.queryParam.itemName = ''
+        this.oldTime = undefined
+        this.newTime = undefined
+        this.$refs.table.refresh(true)
+      },
+      //  添加
+      handleAdd(row){},
+      //  删除
+      handleDel(row){},
+      //  编辑基本信息
+      handleEditInfo(){
+        this.openModal = true
+      },
+      //  基本信息  保存
+      handleOk(){
+        
+      },
+      //  提交
+      handleSubmit(){},
+      //  导入明细
+      handleImport(){
+        console.log(333)
+      },
+      //  返回列表
+      handleBack(){
+        this.$router.push({ path: '/inventoryManagement/warehouseAllocation/list'})
+      },
+      filterOption(input, option) {
+      	return (
+      		option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
+      	)
+      },
+    },
+    beforeRouteEnter (to, from, next) {
+      next(vm => {
+        vm.openModal = false
+      })
+    }
+  }
+</script>
+
+<style lang="less">
+  .warehouseAllocationEdit-wrap{
+    .warehouseAllocationEdit-back{
+      margin-bottom: 15px;
+    }
+    .warehouseAllocationEdit-cont{
+      margin-bottom: 15px;
+      .sub-title{
+        font-size: 12px;
+        color: #808695;
+        margin-left: 10px;
+      }
+      .tag-txt{
+        font-size: 12px;
+        color: #ff0000;
+      }
+      .edit-circle-btn{
+        margin-left: 15px;
+        i{
+          vertical-align: text-bottom;
+        }
+      }
+      .import-btn{
+        margin-left: 15px;
+      }
+    }
+  }
+</style>

+ 242 - 0
src/views/inventoryManagement/warehouseAllocation/list.vue

@@ -0,0 +1,242 @@
+<template>
+  <a-card :bordered="false" class="warehouseAllocationList-wrap">
+    <!-- 搜索条件 -->
+    <div class="table-page-search-wrapper">
+      <a-form layout="inline" @keyup.enter.native="$refs.table.refresh(true)">
+        <a-row :gutter="15">
+          <a-col :md="6" :sm="24">
+            <a-form-item label="创建时间">
+              <a-range-picker
+                  style="width:100%"
+                  id="inventoryQueryWarehouseDetail-bundleNamesss"
+                  :disabledDate="disabledDate"
+                  v-model="queryParam.brand"
+                  :format="dateFormat"
+                  :placeholder="['开始时间', '结束时间']" />
+              </a-form-item>
+            </a-form-item>
+          </a-col>
+          <a-col :md="6" :sm="24">
+            <a-form-item label="调出仓库">
+              <v-select
+                v-model="queryParam.billStatus"
+                ref="billStatus"
+                id="bulkWarehousingOrderList-billStatus"
+                code="PAYMENT_TYPE"
+                placeholder="请选择调出仓库"
+                allowClear></v-select>
+            </a-form-item>
+          </a-col>
+          <a-col :md="6" :sm="24">
+            <a-form-item label="调入仓库">
+              <v-select
+                v-model="queryParam.billStatus"
+                ref="billStatus"
+                id="bulkWarehousingOrderList-billStatus"
+                code="PAYMENT_TYPE"
+                placeholder="请选择调入仓库"
+                allowClear></v-select>
+            </a-form-item>
+          </a-col>
+          <template v-if="advanced">
+            <a-col :md="6" :sm="24">
+              <a-form-item label="单据状态">
+                <v-select
+                  v-model="queryParam.billStatus"
+                  ref="billStatus"
+                  id="bulkWarehousingOrderList-billStatus"
+                  code="PAYMENT_TYPE"
+                  placeholder="请选择单据状态"
+                  allowClear></v-select>
+              </a-form-item>
+            </a-col>
+          </template>
+          <a-col :md="6" :sm="24" style="margin-bottom: 24px;">
+            <a-button type="primary" @click="$refs.table.refresh(true)" :disabled="disabled" id="warehouseAllocationList-refresh">查询</a-button>
+            <a-button style="margin-left: 8px" @click="resetSearchForm" :disabled="disabled" id="warehouseAllocationList-reset">重置</a-button>
+            <a @click="advanced=!advanced" style="margin-left: 8px">
+              {{ advanced ? '收起' : '展开' }}
+              <a-icon :type="advanced ? 'up' : 'down'"/>
+            </a>
+          </a-col>
+        </a-row>
+      </a-form>
+    </div>
+    <!-- 操作按钮 -->
+    <div class="table-operator">
+      <a-button id="warehouseAllocationList-add" type="primary" @click="handleEdit()">新增仓库调拨单</a-button>
+    </div>
+    <!-- 列表 -->
+    <s-table
+      class="sTable"
+      ref="table"
+      size="default"
+      :rowKey="(record) => record.id"
+      :columns="columns"
+      :data="loadData"
+      bordered>
+      <!-- 状态 -->
+      <template slot="status" slot-scope="text, record">
+        <span :class="record.status==1?'green':'red'"> {{ record.status==1? '待提交': '待审核' }} </span>
+      </template>
+      <!-- 操作 -->
+      <template slot="action" slot-scope="text, record">
+        <a-button type="primary" @click="handleExamine(record)" id="warehouseAllocationList-examine-btn">审核</a-button>
+        <a-button @click="handleEdit(record)" id="warehouseAllocationList-edit-btn" style="margin: 0 0 8px 8px;">编辑</a-button>
+        <a-button type="primary" @click="handleDetail(record)" id="warehouseAllocationList-detail-btn" style="margin: 0 0 8px 8px;">详情</a-button>
+        <a-button type="danger" @click="handleDel(record)" id="warehouseAllocationList-del-btn" style="margin: 0 0 0 8px;">删除</a-button>
+      </template>
+    </s-table>
+    <!-- 新增/编辑 -->
+    <basic-info-modal :openModal="openModal" @ok="handleOk" @close="openModal=false" />
+  </a-card>
+</template>
+
+<script>
+import moment from 'moment'
+// import { customerBundleDelayList, customerBundleExportDelay } from '@/api/FinancialManagement'
+import { STable, VSelect } from '@/components'
+import basicInfoModal from './basicInfoModal.vue'
+export default {
+  components: { STable, VSelect, basicInfoModal },
+  data () {
+    return {
+      advanced: false,  // 高级搜索 展开/关闭
+      queryParam: { //  查询条件
+        bundleName: '', //  品牌名称
+        state: undefined,  //  状态
+      },
+      disabled: false, //  查询、重置按钮是否可操作
+      dateFormat: 'YYYY-MM-DD',
+      columns: [
+        { title: '创建时间', dataIndex: 'no', width: 70, align: 'center', width: 180 },
+        { title: '单号', dataIndex: 'productName', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
+        { title: '调出仓库', dataIndex: 'inventoryMoney', width: 180, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '调入仓库', dataIndex: 'productOldNum', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '总款数', dataIndex: 'inventsoryMoney', width: 180, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '总数量', dataIndex: 'inventoryModney', width: 180, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '总成本', dataIndex: 'inventoryaMoney', width: 180, align: 'center', customRender: function (text) { return ((text || text == 0) ? text : '--') } },
+        { title: '审核时间', dataIndex: 'inventoryMongey', width: 180, align: 'center', customRender: function (text) { return text || '--' } },
+        { title: '状态', scopedSlots: { customRender: 'status' }, width: 180, align: 'center' },
+        { title: '操作', scopedSlots: { customRender: 'action' }, width: 300, align: 'center' }
+      ],
+      // 加载数据方法 必须为 Promise 对象
+      loadData: parameter => {
+        this.disabled = true
+        // return customerBundleDelayList( Object.assign(parameter, this.queryParam) ).then(res => {
+        //   const data = res.data
+        //   const no = (data.pageNo - 1) * data.pageSize
+        //   for (var i = 0; i < data.list.length; i++) {
+        //     data.list[i].no = no + i + 1
+        //   }
+        //   this.disabled = false
+        //   return data
+        // })
+        const _this = this
+        return new Promise(function(resolve, reject){
+          const data = {
+            pageNo: 1,
+            pageSize: 10,
+            list: [
+              { id: '1', productNum: 'jgqp11111111111', productName: '产品1', productOldNum: 'jgqp111123545', productBrand: '箭冠品牌', productType: '产品分类1', inventoryNum: '5', inventoryMoney: '122' }
+            ]
+          }
+          const no = (data.pageNo - 1) * data.pageSize
+          for (var i = 0; i < data.list.length; i++) {
+            data.list[i].no = no + i + 1
+          }
+          _this.disabled = false
+          resolve(data)
+        })
+      },
+      openModal: false,  //  新增编辑  弹框
+      itemId: ''  //  当前品牌id
+    }
+  },
+  methods: {
+    // 不可选日期
+    disabledDate (date, dateStrings) {
+      return date && date.valueOf() > Date.now()
+    },
+    //  重置
+    resetSearchForm () {
+      this.queryParam.orderBundleNo = ''
+      this.queryParam.orderBundle.custMobile = ''
+      this.queryParam.bundleName = ''
+      this.queryParam.itemName = ''
+      this.oldTime = undefined
+      this.newTime = undefined
+      this.$refs.table.refresh(true)
+    },
+    //  基本信息  保存
+    handleOk(){
+      this.$router.push({ path: `/inventoryManagement/warehouseAllocation/add` })
+    },
+    //  删除
+    handleDel(row){
+      const _this = this
+      this.$confirm({
+        title: '提示',
+        content: '删除后不可恢复,确定要进行删除吗?',
+        okText: '确定',
+        cancelText: '取消',
+        onOk () {
+          // delectRolePower({
+          //   id: row.id
+          // }).then(res => {
+          //   console.log(res, 'res1111')
+          //   if (res.status == 200) {
+          //     _this.$message.success(res.message)
+          //     _this.$refs.table.refresh()
+          //   }
+          // })
+        }
+      })
+    },
+    //  审核
+    handleExamine(){
+      const _this = this
+      this.$confirm({
+        title: '提示',
+        content: '确认要审核通过吗?',
+        okText: '确定',
+        cancelText: '取消',
+        onOk () {
+          // delectRolePower({
+          //   id: row.id
+          // }).then(res => {
+          //   console.log(res, 'res1111')
+          //   if (res.status == 200) {
+          //     _this.$message.success(res.message)
+          //     _this.$refs.table.refresh()
+          //   }
+          // })
+        }
+      })
+    },
+    //  详情
+    handleDetail(row){
+      this.$router.push({ path: `/inventoryManagement/warehouseAllocation/detail/${row.id}` })
+    },
+    //  新增/编辑
+    handleEdit(row){
+      // if(row){  //  编辑
+      //   this.$router.push({ path: `/inventoryManagement/warehouseAllocation/edit/${row.id}` })
+      // }else{  //  新增
+      //   this.$router.push({ path: '/inventoryManagement/warehouseAllocation/add' })
+      // }
+      this.openModal = true
+    },
+  }
+}
+</script>
+
+<style lang="less">
+  .warehouseAllocationList-wrap{
+    .sTable{
+      table{
+        width: auto;
+      }
+    }
+  }
+</style>

+ 24 - 4
src/views/productManagement/productBrand/list.vue

@@ -23,7 +23,7 @@
     </div>
     </div>
     <!-- 操作按钮 -->
     <!-- 操作按钮 -->
     <div class="table-operator">
     <div class="table-operator">
-      <a-button id="productBrandList-add" type="primary" @click="handleEdit">新增品牌</a-button>
+      <a-button id="productBrandList-add" type="primary" @click="handleEdit()">新增品牌</a-button>
       <a-button id="productBrandList-import" @click="handleImport">导入品牌</a-button>
       <a-button id="productBrandList-import" @click="handleImport">导入品牌</a-button>
     </div>
     </div>
     <!-- 列表 -->
     <!-- 列表 -->
@@ -36,8 +36,14 @@
       :data="loadData"
       :data="loadData"
       bordered>
       bordered>
       <!-- 状态 -->
       <!-- 状态 -->
-      <template slot="state" slot-scope="text, record">
-        <span>{{record.state == 1 ? '已启用' : '已禁用'}}</span>
+      <template slot="status" slot-scope="text, record">
+        <a-switch
+          id="productBrandList-enable"
+          checkedChildren="启用"
+          unCheckedChildren="禁用"
+          @change="changeStatus(record)"
+          v-model="record.status" />
+        <!-- <span :class="record.status==1?'green':'red'" v-else> {{ record.status==1? '已启用': '已禁用' }} </span> -->
       </template>
       </template>
       <!-- 操作 -->
       <!-- 操作 -->
       <template slot="action" slot-scope="text, record">
       <template slot="action" slot-scope="text, record">
@@ -68,7 +74,7 @@ export default {
         { title: '产品品牌名称', dataIndex: 'productName', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
         { title: '产品品牌名称', dataIndex: 'productName', align: 'center', ellipsis: true, customRender: function (text) { return text || '--' } },
         { title: '首字母', dataIndex: 'productOldNum', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '首字母', dataIndex: 'productOldNum', width: 160, align: 'center', customRender: function (text) { return text || '--' } },
         { title: '创建时间', dataIndex: 'inventoryMoney', width: 180, align: 'center' },
         { title: '创建时间', dataIndex: 'inventoryMoney', width: 180, align: 'center' },
-        { title: '状态', scopedSlots: { customRender: 'state' }, width: 180, align: 'center' },
+        { title: '状态', scopedSlots: { customRender: 'status' }, width: 180, align: 'center' },
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 240, align: 'center' }
         { title: '操作', scopedSlots: { customRender: 'action' }, width: 240, align: 'center' }
       ],
       ],
       // 加载数据方法 必须为 Promise 对象
       // 加载数据方法 必须为 Promise 对象
@@ -125,6 +131,20 @@ export default {
       this.itemId = ''
       this.itemId = ''
       this.openModal = false
       this.openModal = false
     },
     },
+    // 启用 禁用
+    changeStatus (record) {
+      const _data = {
+        id: record.id,
+        flag: record.loginFlag ? '1' : '0'
+      }
+      // updateEnableStatus(_data).then(res => {
+      //   if (res.status === 200) {
+      //     this.$message.success(res.message)
+      //   } else {
+      //     record.loginFlag = !record.loginFlag
+      //   }
+      // })
+    },
     //  导入
     //  导入
     handleImport(){},
     handleImport(){},
   }
   }

+ 9 - 9
src/views/productManagement/productInfo/list.vue

@@ -69,7 +69,7 @@
     </div>
     </div>
     <!-- 操作按钮 -->
     <!-- 操作按钮 -->
     <div class="table-operator">
     <div class="table-operator">
-      <a-button id="productInfoList-add" type="primary" @click="handleAdd">新增产品</a-button>
+      <a-button id="productInfoList-add" type="primary" @click="handleEdit()">新增产品</a-button>
       <a-button id="productInfoList-import" @click="handleImport" style="margin: 0 15px;">批量导入产品</a-button>
       <a-button id="productInfoList-import" @click="handleImport" style="margin: 0 15px;">批量导入产品</a-button>
       <a-button id="productInfoList-state" @click="handleEditState">批量修改状态</a-button>
       <a-button id="productInfoList-state" @click="handleEditState">批量修改状态</a-button>
     </div>
     </div>
@@ -199,14 +199,14 @@ export default {
       this.newTime = undefined
       this.newTime = undefined
       this.$refs.table.refresh(true)
       this.$refs.table.refresh(true)
     },
     },
-    //  新增
-    handleAdd(){
-      this.$router.push({ path: '/productManagement/productInfo/add' })
-    },
-    //  编辑
-    handleEdit(row){
-      this.$router.push({ path: `/productManagement/productInfo/edit/${row.id}` })
-    },
+	//  新增/编辑
+	handleEdit(row){
+	  if(row){  //  编辑
+	    this.$router.push({ path: `/productManagement/productInfo/edit/${row.id}` })
+	  }else{  //  新增
+	    this.$router.push({ path: '/productManagement/productInfo/add' })
+	  }
+	},
     //  批量导入
     //  批量导入
     handleImport(){
     handleImport(){
       
       

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

@@ -10,7 +10,7 @@
     width="70%">
     width="70%">
     <!-- 操作按钮 -->
     <!-- 操作按钮 -->
     <div class="table-operator">
     <div class="table-operator">
-      <a-button id="chooseAddressList-add" type="primary" @click="handleEdit">新增收货地址</a-button>
+      <a-button id="chooseAddressList-add" type="primary" @click="handleEdit()">新增收货地址</a-button>
     </div>
     </div>
     <!-- 列表 -->
     <!-- 列表 -->
     <s-table
     <s-table

+ 166 - 147
src/views/salesManagement/customerManagement/edit.vue

@@ -1,149 +1,157 @@
 <template>
 <template>
-  <a-card :bordered="false" class="customerManagementEdit-table-page-wrapper">
-    <a-form-model
-      id="customerManagementEdit-form"
-      ref="ruleForm"
-      :model="form"
-      :rules="rules"
-      :label-col="formItemLayout.labelCol"
-      :wrapper-col="formItemLayout.wrapperCol"
-    >
-      <a-row :gutter="15">
-        <a-col :span="8">
-          <a-form-model-item label="客户名称" prop="name">
-            <a-input
-              id="customerManagementEdit-name"
-              :maxLength="30"
-              v-model="form.name"
-              placeholder="请输入客户名称(最多30个字符)"
-              allowClear />
-          </a-form-model-item>
-        </a-col>
-        <a-col :span="8">
-          <a-form-model-item label="联系手机" prop="address">
-            <a-input
-              id="customerManagementEdit-address"
-              :maxLength="11"
-              v-model="form.address"
-              placeholder="请输入联系手机(最多11个字符)"
-              allowClear />
-          </a-form-model-item>
-        </a-col>
-        <a-col :span="8">
-          <a-form-model-item label="联系人" prop="address">
-            <a-input
-              id="customerManagementEdit-address"
-              :maxLength="30"
-              v-model="form.address"
-              placeholder="请输入联系人(最多30个字符)"
-              allowClear />
-          </a-form-model-item>
-        </a-col>
-      </a-row>
-      <a-row :gutter="15">
-        <a-col :span="16">
-          <a-form-model-item label="客户地址" required style="margin: 0;" :labelCol="{ span: 4 }" :wrapperCol="{ span: 20 }">
-            <a-row :gutter="15">
-              <!-- 客户地址 -->
-              <a-col span="8">
-                <a-form-model-item prop="provinceCode">
-                  <a-select id="customerManagementEdit-provinceCode" @change="getCityList" v-model="form.provinceCode" placeholder="请选择省">
-                    <a-select-option v-for="item in addrProvinceList" :value="item.id" :key="item.id + 'a'">{{ item.name }}</a-select-option>
-                  </a-select>
-                </a-form-model-item>
-              </a-col>
-              <a-col span="8">
-                <a-form-model-item prop="cityCode">
-                  <a-select id="customerManagementEdit-cityCode" @change="getAreaList" v-model="form.cityCode" placeholder="请选择市">
-                    <a-select-option v-for="item in addrCityList" :value="item.id" :key="item.id + 'b'">{{ item.name }}</a-select-option>
-                  </a-select>
-                </a-form-model-item>
-              </a-col>
-              <a-col span="8">
-                <a-form-model-item prop="districtCode">
-                  <a-select id="customerManagementEdit-districtCode" @change="areaCharged" v-model="form.districtCode" placeholder="请选择区/县">
-                    <a-select-option v-for="item in addrDistrictList" :value="item.id" :key="item.id + 'c'">{{ item.name }}</a-select-option>
-                  </a-select>
-                </a-form-model-item>
-              </a-col>
-            </a-row>
-          </a-form-model-item>
-        </a-col>
-        <a-col :span="8">
-          <a-form-model-item label="详细地址" prop="address">
-            <a-input
-              id="customerManagementEdit-address"
-              :maxLength="60"
-              v-model="form.address"
-              placeholder="请输入详细地址(最多60个字符)"
-              allowClear />
-          </a-form-model-item>
-        </a-col>
-      </a-row>
-      <a-row :gutter="15">
-        <a-col :span="8">
-          <a-form-model-item label="客户传真" prop="contactName">
-            <a-input
-              id="customerManagementEdit-contactName"
-              :maxLength="30"
-              v-model="form.contactName"
-              placeholder="请输入客户传真(最多30个字符)"
-              allowClear />
-          </a-form-model-item>
-        </a-col>
-        <a-col :span="8">
-          <a-form-model-item label="配送方式" prop="contactPhone">
-            <v-select code="DISPATCH_FASHION" id="customerManagementEdit-dispatchFashion" v-model="form.dispatchFashion" allowClear placeholder="请选择配送方式"></v-select>
-          </a-form-model-item>
-        </a-col>
-        <a-col :span="8">
-          <a-form-model-item label="是否卫星仓客户" prop="contactPhone">
-            <a-select id="customerManagementEdit-districtCode" v-model="form.districtCode" placeholder="请选择">
-              <a-select-option v-for="item in addrDistrictList" :value="item.id" :key="item.id + 'c'">{{ item.name }}</a-select-option>
-            </a-select>
-          </a-form-model-item>
-        </a-col>
-      </a-row>
-      <a-row :gutter="15">
-        <a-col :span="8">
-          <a-form-model-item label="价格类型" prop="contactPhone">
-            <v-select code="PRICE_TYPE" id="customerManagementEdit-priceType" v-model="form.priceType" allowClear placeholder="请选择价格类型"></v-select>
-          </a-form-model-item>
-        </a-col>
-        <a-col :span="8">
-          <a-form-model-item label="支付方式" prop="contactPhone">
-            <v-select code="PAY_FASHION" id="customerManagementEdit-payFashion" v-model="form.payFashion" allowClear placeholder="请选择支付方式"></v-select>
-          </a-form-model-item>
-        </a-col>
-        <a-col :span="8">
-          <a-form-model-item label="收款方式" prop="contactPhone">
-            <v-select code="RECEIPT_PAYMENT" id="customerManagementEdit-receiptPayment" v-model="form.receiptPayment" allowClear placeholder="请选择收款方式"></v-select>
-          </a-form-model-item>
-        </a-col>
-      </a-row>
-      <a-row :gutter="15">
-        <a-col :span="8">
-          <a-form-model-item label="联系电话" prop="address">
-            <a-input
-              id="customerManagementEdit-address"
-              :maxLength="20"
-              v-model="form.address"
-              placeholder="请输入联系电话(最多20个字符)"
-              allowClear />
-          </a-form-model-item>
-        </a-col>
-      </a-row>
-      <a-form-model-item :wrapper-col="{ span: 12, offset: 6 }" style="text-align: center;">
-        <a-button type="primary" @click="handleSubmit" id="customerManagementEdit-btn-submit">保存</a-button>
-        <a-button @click="goBack" style="margin-left: 15px" id="customerManagementEdit-btn-back">返回列表</a-button>
-      </a-form-model-item>
-    </a-form-model>
-  </a-card>
+  <div class="customerManagementEdit-wrap">
+    <a-page-header :ghost="false" @back="handleBack" class="customerManagementEdit-back">
+      <!-- 自定义的二级文字标题 -->
+      <template slot="subTitle">
+        <a id="customerManagementEdit-back-btn" href="javascript:;" @click="handleBack">返回列表</a>
+      </template>
+    </a-page-header>
+    <a-card :bordered="false" class="customerManagementEdit-table-page-wrapper">
+      <a-form-model
+        id="customerManagementEdit-form"
+        ref="ruleForm"
+        :model="form"
+        :rules="rules"
+        :label-col="formItemLayout.labelCol"
+        :wrapper-col="formItemLayout.wrapperCol"
+      >
+        <a-row :gutter="15">
+          <a-col :span="8">
+            <a-form-model-item label="客户名称" prop="name">
+              <a-input
+                id="customerManagementEdit-name"
+                :maxLength="30"
+                v-model="form.name"
+                placeholder="请输入客户名称(最多30个字符)"
+                allowClear />
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="8">
+            <a-form-model-item label="联系手机" prop="address">
+              <a-input
+                id="customerManagementEdit-address"
+                :maxLength="11"
+                v-model="form.address"
+                placeholder="请输入联系手机(最多11个字符)"
+                allowClear />
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="8">
+            <a-form-model-item label="联系人" prop="address">
+              <a-input
+                id="customerManagementEdit-address"
+                :maxLength="30"
+                v-model="form.address"
+                placeholder="请输入联系人(最多30个字符)"
+                allowClear />
+            </a-form-model-item>
+          </a-col>
+        </a-row>
+        <a-row :gutter="15">
+          <a-col :span="16">
+            <a-form-model-item label="客户地址" required style="margin: 0;" :labelCol="{ span: 4 }" :wrapperCol="{ span: 20 }">
+              <a-row :gutter="15">
+                <!-- 客户地址 -->
+                <a-col span="8">
+                  <a-form-model-item prop="provinceCode">
+                    <a-select id="customerManagementEdit-provinceCode" @change="getCityList" v-model="form.provinceCode" placeholder="请选择省">
+                      <a-select-option v-for="item in addrProvinceList" :value="item.id" :key="item.id + 'a'">{{ item.name }}</a-select-option>
+                    </a-select>
+                  </a-form-model-item>
+                </a-col>
+                <a-col span="8">
+                  <a-form-model-item prop="cityCode">
+                    <a-select id="customerManagementEdit-cityCode" @change="getAreaList" v-model="form.cityCode" placeholder="请选择市">
+                      <a-select-option v-for="item in addrCityList" :value="item.id" :key="item.id + 'b'">{{ item.name }}</a-select-option>
+                    </a-select>
+                  </a-form-model-item>
+                </a-col>
+                <a-col span="8">
+                  <a-form-model-item prop="districtCode">
+                    <a-select id="customerManagementEdit-districtCode" @change="areaCharged" v-model="form.districtCode" placeholder="请选择区/县">
+                      <a-select-option v-for="item in addrDistrictList" :value="item.id" :key="item.id + 'c'">{{ item.name }}</a-select-option>
+                    </a-select>
+                  </a-form-model-item>
+                </a-col>
+              </a-row>
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="8">
+            <a-form-model-item label="详细地址" prop="address">
+              <a-input
+                id="customerManagementEdit-address"
+                :maxLength="60"
+                v-model="form.address"
+                placeholder="请输入详细地址(最多60个字符)"
+                allowClear />
+            </a-form-model-item>
+          </a-col>
+        </a-row>
+        <a-row :gutter="15">
+          <a-col :span="8">
+            <a-form-model-item label="客户传真" prop="contactName">
+              <a-input
+                id="customerManagementEdit-contactName"
+                :maxLength="30"
+                v-model="form.contactName"
+                placeholder="请输入客户传真(最多30个字符)"
+                allowClear />
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="8">
+            <a-form-model-item label="配送方式" prop="contactPhone">
+              <v-select code="DISPATCH_FASHION" id="customerManagementEdit-dispatchFashion" v-model="form.dispatchFashion" allowClear placeholder="请选择配送方式"></v-select>
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="8">
+            <a-form-model-item label="是否卫星仓客户" prop="contactPhone">
+              <a-select id="customerManagementEdit-districtCode" v-model="form.districtCode" placeholder="请选择">
+                <a-select-option v-for="item in addrDistrictList" :value="item.id" :key="item.id + 'c'">{{ item.name }}</a-select-option>
+              </a-select>
+            </a-form-model-item>
+          </a-col>
+        </a-row>
+        <a-row :gutter="15">
+          <a-col :span="8">
+            <a-form-model-item label="价格类型" prop="contactPhone">
+              <v-select code="PRICE_TYPE" id="customerManagementEdit-priceType" v-model="form.priceType" allowClear placeholder="请选择价格类型"></v-select>
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="8">
+            <a-form-model-item label="支付方式" prop="contactPhone">
+              <v-select code="PAY_FASHION" id="customerManagementEdit-payFashion" v-model="form.payFashion" allowClear placeholder="请选择支付方式"></v-select>
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="8">
+            <a-form-model-item label="收款方式" prop="contactPhone">
+              <v-select code="RECEIPT_PAYMENT" id="customerManagementEdit-receiptPayment" v-model="form.receiptPayment" allowClear placeholder="请选择收款方式"></v-select>
+            </a-form-model-item>
+          </a-col>
+        </a-row>
+        <a-row :gutter="15">
+          <a-col :span="8">
+            <a-form-model-item label="联系电话" prop="address">
+              <a-input
+                id="customerManagementEdit-address"
+                :maxLength="20"
+                v-model="form.address"
+                placeholder="请输入联系电话(最多20个字符)"
+                allowClear />
+            </a-form-model-item>
+          </a-col>
+        </a-row>
+        <a-form-model-item :wrapper-col="{ span: 12, offset: 6 }" style="text-align: center;">
+          <a-button type="primary" @click="handleSubmit" id="customerManagementEdit-btn-submit" style="padding: 0 60px;">保存</a-button>
+        </a-form-model-item>
+      </a-form-model>
+    </a-card>
+  </div>
 </template>
 </template>
 
 
 <script>
 <script>
 import { STable, VSelect } from '@/components'
 import { STable, VSelect } from '@/components'
 import { custSave } from '@/api/customer'
 import { custSave } from '@/api/customer'
+import { custTypeFindAll } from '@/api/custType'
 export default {
 export default {
   name: 'customerManagementEdit',
   name: 'customerManagementEdit',
   components: { STable, VSelect },
   components: { STable, VSelect },
@@ -195,7 +203,8 @@ export default {
       },
       },
       addrProvinceList: [], //  省下拉
       addrProvinceList: [], //  省下拉
       addrCityList: [], //  市下拉
       addrCityList: [], //  市下拉
-      addrDistrictList: [] //  区下拉
+      addrDistrictList: [], //  区下拉
+      custTypeList: [],  //  客户类型  下拉数据
     }
     }
   },
   },
   computed: {
   computed: {
@@ -212,6 +221,14 @@ export default {
       //   }
       //   }
       // })
       // })
     },
     },
+    //  客户类型
+    getCustTypeList(){
+      custTypeFindAll({}).then(res => {
+        if(res.status == 200){
+          this.custTypeList = res.data
+        }
+      })
+    },
     //  保存
     //  保存
     handleSubmit (e) {
     handleSubmit (e) {
       e.preventDefault()
       e.preventDefault()
@@ -236,8 +253,8 @@ export default {
         }
         }
       })
       })
     },
     },
-    //  返回
-    goBack () {
+    //  返回列表
+    handleBack(){
       this.$router.push({ path: '/salesManagement/customerManagement/list' })
       this.$router.push({ path: '/salesManagement/customerManagement/list' })
     },
     },
     // 获取省列表'
     // 获取省列表'
@@ -295,8 +312,8 @@ export default {
   },
   },
   beforeRouteEnter (to, from, next) {
   beforeRouteEnter (to, from, next) {
     next(vm => {
     next(vm => {
-      // vm.getGoodsType()
-      // vm.getPartnerQueryList()
+      vm.getProvinceList()  //  省市区
+      vm.getCustTypeList()  //  客户类型
       vm.$refs.ruleForm.resetFields()
       vm.$refs.ruleForm.resetFields()
       if (vm.isEdit) { //  编辑页
       if (vm.isEdit) { //  编辑页
         vm.getDetail()
         vm.getDetail()
@@ -307,7 +324,9 @@ export default {
 </script>
 </script>
 
 
 <style lang="less">
 <style lang="less">
-  .customerManagementEdit-table-page-wrapper{
-    
+  .customerManagementEdit-wrap{
+    .customerManagementEdit-back{
+      margin-bottom: 15px;
+    }
   }
   }
 </style>
 </style>

+ 32 - 41
src/views/salesManagement/customerManagement/list.vue

@@ -88,7 +88,7 @@
     </div>
     </div>
     <!-- 操作按钮 -->
     <!-- 操作按钮 -->
     <div class="table-operator">
     <div class="table-operator">
-      <a-button id="customerManagementList-add" type="primary" @click="handleAdd">新增客户</a-button>
+      <a-button id="customerManagementList-add" type="primary" @click="handleEdit()">新增客户</a-button>
       <a-button id="customerManagementList-merge" @click="handleMerge" style="margin: 0 0 0 15px;">客户合并</a-button>
       <a-button id="customerManagementList-merge" @click="handleMerge" style="margin: 0 0 0 15px;">客户合并</a-button>
     </div>
     </div>
     <!-- 列表 -->
     <!-- 列表 -->
@@ -118,7 +118,8 @@
 
 
 <script>
 <script>
 import moment from 'moment'
 import moment from 'moment'
-import { custList } from '@/api/customer'
+import { getProvince, getCityByPro, getDistrictByCity } from '@/api/data'
+import { custList, custDel, custTypeFindAll } from '@/api/customer'
 import { STable, VSelect } from '@/components'
 import { STable, VSelect } from '@/components'
 import customerManagementDetailModal from './detailModal.vue'
 import customerManagementDetailModal from './detailModal.vue'
 export default {
 export default {
@@ -127,10 +128,12 @@ export default {
     return {
     return {
       advanced: false,  // 高级搜索 展开/关闭
       advanced: false,  // 高级搜索 展开/关闭
       queryParam: { //  查询条件
       queryParam: { //  查询条件
-        orderBundleNo: '', //  订单编号
-        bundleName: '', //  套餐名称
-        itemName: '', //  服务名称
-        brand: undefined,  //  产品品牌
+        // orderBundleNo: '', //  客户名称
+        // bundleName: '', //  联系人
+        // provinceCode: undefined,  //  省
+        // cityCode: undefined,  //  市
+        // districtCode: undefined,  //  区
+        // itemName: '', //  是否卫星仓客户
       },
       },
       exportLoading: false, // 导出loading
       exportLoading: false, // 导出loading
       disabled: false, //  查询、重置按钮是否可操作
       disabled: false, //  查询、重置按钮是否可操作
@@ -152,30 +155,14 @@ export default {
       // 加载数据方法 必须为 Promise 对象
       // 加载数据方法 必须为 Promise 对象
       loadData: parameter => {
       loadData: parameter => {
         this.disabled = true
         this.disabled = true
-        // return custList( Object.assign(parameter, this.queryParam) ).then(res => {
-        //   const data = res.data
-        //   const no = (data.pageNo - 1) * data.pageSize
-        //   for (var i = 0; i < data.list.length; i++) {
-        //     data.list[i].no = no + i + 1
-        //   }
-        //   this.disabled = false
-        //   return data
-        // })
-        const _this = this
-        return new Promise(function(resolve, reject){
-          const data = {
-            pageNo: 1,
-            pageSize: 10,
-            list: [
-              { id: '1', productNum: 'jgqp11111111111', productName: '产品1', productOldNum: 'jgqp111123545', productBrand: '箭冠品牌', productType: '产品分类1', inventoryNum: '5', inventoryMoney: '122' }
-            ]
-          }
+        return custList( Object.assign(parameter, this.queryParam) ).then(res => {
+          const data = res.data
           const no = (data.pageNo - 1) * data.pageSize
           const no = (data.pageNo - 1) * data.pageSize
           for (var i = 0; i < data.list.length; i++) {
           for (var i = 0; i < data.list.length; i++) {
             data.list[i].no = no + i + 1
             data.list[i].no = no + i + 1
           }
           }
-          _this.disabled = false
-          resolve(data)
+          this.disabled = false
+          return data
         })
         })
       },
       },
       addrProvinceList: [], //  省下拉
       addrProvinceList: [], //  省下拉
@@ -200,13 +187,13 @@ export default {
       this.newTime = undefined
       this.newTime = undefined
       this.$refs.table.refresh(true)
       this.$refs.table.refresh(true)
     },
     },
-    //  新增
-    handleAdd(){
-      this.$router.push({ path: '/salesManagement/customerManagement/add' })
-    },
-    //  编辑
+    //  新增/编辑
     handleEdit(row){
     handleEdit(row){
-      this.$router.push({ path: `/salesManagement/customerManagement/edit/${row.id}` })
+      if(row){  //  编辑
+        this.$router.push({ path: `/salesManagement/customerManagement/edit/${row.id}` })
+      }else{  //  新增
+        this.$router.push({ path: '/salesManagement/customerManagement/add' })
+      }
     },
     },
     //  删除
     //  删除
     handleDel(row){
     handleDel(row){
@@ -217,15 +204,14 @@ export default {
         okText: '确定',
         okText: '确定',
         cancelText: '取消',
         cancelText: '取消',
         onOk () {
         onOk () {
-          // delectRolePower({
-          //   id: row.id
-          // }).then(res => {
-          //   console.log(res, 'res1111')
-          //   if (res.status == 200) {
-          //     _this.$message.success(res.message)
-          //     _this.$refs.table.refresh()
-          //   }
-          // })
+          custDel({
+            id: row.id
+          }).then(res => {
+            if (res.status == 200) {
+              _this.$message.success(res.message)
+              _this.$refs.table.refresh()
+            }
+          })
         }
         }
       })
       })
     },
     },
@@ -292,6 +278,11 @@ export default {
         }
         }
       })
       })
     }
     }
+  },
+  beforeRouteEnter (to, from, next) {
+    next(vm => {
+      vm.getProvinceList()
+    })
   }
   }
 }
 }
 </script>
 </script>

+ 1 - 1
vue.config.js

@@ -108,7 +108,7 @@ const vueConfig = {
     // If you want to turn on the proxy, please remove the mockjs /src/main.jsL11
     // If you want to turn on the proxy, please remove the mockjs /src/main.jsL11
     proxy: {
     proxy: {
       '/api': {
       '/api': {
-        target: 'http://192.168.31.87:8503/qpls-md',
+        target: 'http://192.168.0.119:8503/qpls-md',
         // target: 'http://it.test.zyucgj.com/zyit',
         // target: 'http://it.test.zyucgj.com/zyit',
         // target: 'https://it.test.qiubcar.com/zyit',
         // target: 'https://it.test.qiubcar.com/zyit',
         ws: false,
         ws: false,