瀏覽代碼

Merge branch 'master' of http://121.40.253.172:3000/pengyue/jsh_erp into dev_huangjunjie

huang 3 周之前
父節點
當前提交
d4d90f79a7
共有 25 個文件被更改,包括 1649 次插入911 次删除
  1. 1 1
      jshERP-web/src/components/jeecg/JEditableTable.vue
  2. 42 0
      jshERP-web/src/components/jeecgbiz/JSelectList.vue
  3. 522 0
      jshERP-web/src/components/jeecgbiz/modal/JSelectMaterialModal2.vue
  4. 1 0
      jshERP-web/src/utils/JEditableTableUtil.js
  5. 6 6
      jshERP-web/src/views/bill/dialog/BillDetail.vue
  6. 97 3
      jshERP-web/src/views/bill/mixins/BillModalMixin.js
  7. 1 1
      jshERP-web/src/views/bill/modules/AllocationOutModal.vue
  8. 56 43
      jshERP-web/src/views/bill/modules/OtherInModal.vue
  9. 44 43
      jshERP-web/src/views/bill/modules/OtherOutModal.vue
  10. 67 54
      jshERP-web/src/views/bill/modules/PurchaseInModal.vue
  11. 58 46
      jshERP-web/src/views/bill/modules/PurchaseOrderModal.vue
  12. 38 38
      jshERP-web/src/views/bill/modules/SaleOrderModal.vue
  13. 46 46
      jshERP-web/src/views/bill/modules/SaleOutModal.vue
  14. 2 2
      jshERP-web/src/views/material/MaterialList.vue
  15. 1 1
      jshERP-web/src/views/material/modules/BatchSetStockModal.vue
  16. 194 590
      jshERP-web/src/views/material/modules/MaterialModal.vue
  17. 1 2
      jshERP-web/src/views/stock/CheckList.vue
  18. 3 3
      jshERP-web/src/views/stock/TaskList.vue
  19. 1 1
      jshERP-web/src/views/stock/components/FilterForm.vue
  20. 58 23
      jshERP-web/src/views/stock/components/checkModal.vue
  21. 6 2
      jshERP-web/src/views/stock/components/stockModal.vue
  22. 87 0
      jshERP-web/src/views/system/AppVersionList.vue
  23. 293 0
      jshERP-web/src/views/system/modules/AppVersionModal.vue
  24. 22 5
      jshERP-web/src/views/system/modules/VendorModal.vue
  25. 2 1
      jshERP-web/vue.config.js

+ 1 - 1
jshERP-web/src/components/jeecg/JEditableTable.vue

@@ -481,7 +481,7 @@
 
                     <!-- update-begin-author:jsh date:20210308 for:popupJsh -->
                     <template v-else-if="col.type === formTypes.popupJsh">
-                      <div :key="i">
+                      <div style="max-width: 190px" :key="i">
                         <a-tooltip
                           :id="id"
                           placement="top"

+ 42 - 0
jshERP-web/src/components/jeecgbiz/JSelectList.vue

@@ -31,6 +31,37 @@
       </a-select>
       <a-button icon="search" @click="onSearch" />
     </a-input-group>
+    <a-input-group v-if="kind === 'material2'" compact style="width: 100%; top: 0px">
+      <a-select
+        placeholder="输入商品条码"
+        :dropdownMatchSelectWidth="false"
+        showSearch
+        :showArrow="false"
+        v-model="names"
+        optionFilterProp="children"
+        :style="searchWidth"
+        notFoundContent="需在商品管理先新增才能使用"
+        @search="handleSearch"
+        @change="handleChange"
+        style="width: 100%"
+      >
+        <div slot="dropdownRender" slot-scope="menu">
+          <v-nodes :vnodes="menu" />
+          <a-divider v-if="materialData.length === 20" style="margin: 4px 0" />
+          <div
+            v-if="materialData.length === 20"
+            style="padding: 4px 8px; cursor: pointer"
+            @mousedown="(e) => e.preventDefault()"
+          >
+            此处最多显示20条,如需更多请点击放大镜查询
+          </div>
+        </div>
+        <a-select-option v-for="item in materialData" :key="item.batchNumber">
+          {{ item.batchNumber }}
+        </a-select-option>
+      </a-select>
+      <a-button icon="search" @click="onSearch" />
+    </a-input-group>
     <a-input-search
       v-if="kind === 'batch' || kind === 'sn' || kind === 'snAdd'"
       v-model="names"
@@ -47,6 +78,15 @@
       @ok="selectOK"
       @initComp="initComp"
     />
+    <j-select-material-modal2
+      v-if="kind === 'material2'"
+      ref="selectModal"
+      :rows="rows"
+      :multi="multi"
+      :bar-code="value"
+      @ok="selectOK"
+      @initComp="initComp"
+    />
     <j-select-batch-modal
       v-if="kind === 'batch'"
       ref="selectModal"
@@ -79,6 +119,7 @@
 
 <script>
 import JSelectMaterialModal from './modal/JSelectMaterialModal'
+import JSelectMaterialModal2 from './modal/JSelectMaterialModal2'
 import JSelectBatchModal from './modal/JSelectBatchModal'
 import JSelectSnModal from './modal/JSelectSnModal'
 import JSelectSnAddModal from './modal/JSelectSnAddModal'
@@ -88,6 +129,7 @@ export default {
   name: 'JSelectList',
   components: {
     JSelectMaterialModal,
+    JSelectMaterialModal2,
     JSelectBatchModal,
     JSelectSnModal,
     JSelectSnAddModal,

+ 522 - 0
jshERP-web/src/components/jeecgbiz/modal/JSelectMaterialModal2.vue

@@ -0,0 +1,522 @@
+<template>
+  <a-modal
+    :width="modalWidth"
+    :visible="visible"
+    :title="title"
+    :wrapClassName="wrapClassNameInfo()"
+    @ok="handleSubmit"
+    @cancel="close"
+    cancelText="关闭(ESC)"
+    style="top: 20px; height: 95%"
+  >
+    <a-row :gutter="10" style="padding: 10px; margin: -10px">
+      <a-col :md="24" :sm="24">
+        <!-- 查询区域 -->
+        <div class="table-page-search-wrapper">
+          <!-- 搜索区域 -->
+          <a-form layout="inline" @keyup.enter.native="onSearch">
+            <a-row :gutter="24">
+              <a-col :md="6" :sm="8">
+                <a-form-item label="关键词" :labelCol="labelCol" :wrapperCol="wrapperCol">
+                  <a-input ref="material" placeholder="请输入条码、名称、助记码等查询" v-model="queryParam.q"></a-input>
+                </a-form-item>
+              </a-col>
+              <a-col :md="6" :sm="8">
+                <a-form-item label="规格型号" :labelCol="labelCol" :wrapperCol="wrapperCol">
+                  <a-input placeholder="请输入规格、型号" v-model="queryParam.standardOrModel"></a-input>
+                </a-form-item>
+              </a-col>
+              <a-col :md="6" :sm="8">
+                <a-form-item label="颜色" :labelCol="{ span: 5 }" :wrapperCol="{ span: 18, offset: 1 }">
+                  <a-input placeholder="请输入颜色" v-model="queryParam.color"></a-input>
+                </a-form-item>
+              </a-col>
+              <!-- <a-col :md="6" :sm="8">
+                <a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="仓库">
+                  <a-select
+                    placeholder="选择仓库"
+                    v-model="queryParam.depotId"
+                    @change="onDepotChange"
+                    :dropdownMatchSelectWidth="false"
+                    showSearch
+                    optionFilterProp="children"
+                    allow-clear
+                  >
+                    <a-select-option v-for="(item, index) in depotList" :key="index" :value="item.id">
+                      {{ item.depotName }}
+                    </a-select-option>
+                  </a-select>
+                </a-form-item>
+              </a-col> -->
+              <span style="float: left; overflow: hidden" class="table-page-search-submitButtons">
+                <a-col :md="6" :sm="8">
+                  <a-button type="primary" @click="loadMaterialData(1)">查询</a-button>
+                  <a-button style="margin-left: 8px" @click="searchReset(1)">重置</a-button>
+                  <a-tooltip title="没查询到,决定新增商品!">
+                    <a-button style="margin-left: 8px" @click="addMaterial">新增</a-button>
+                  </a-tooltip>
+                  <a @click="handleToggleSearch" style="margin-left: 8px">
+                    {{ toggleSearchStatus ? '收起' : '展开' }}
+                    <a-icon :type="toggleSearchStatus ? 'up' : 'down'" />
+                  </a>
+                </a-col>
+              </span>
+              <template v-if="toggleSearchStatus">
+          
+                <a-col :md="6" :sm="8">
+                  <a-form-item label="品牌" :labelCol="{ span: 5 }" :wrapperCol="{ span: 18, offset: 1 }">
+                    <a-input placeholder="请输入品牌" v-model="queryParam.brand"></a-input>
+                  </a-form-item>
+                </a-col>
+                <a-col :md="6" :sm="8">
+                  <a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="类别">
+                    <a-tree-select
+                      style="width: 100%"
+                      :dropdownStyle="{ maxHeight: '200px', overflow: 'auto' }"
+                      allow-clear
+                      :treeData="categoryTree"
+                      v-model="queryParam.categoryId"
+                      placeholder="请选择类别"
+                    >
+                    </a-tree-select>
+                  </a-form-item>
+                </a-col>
+                <!-- <a-col :md="6" :sm="8">
+                  <a-form-item label="制造商" :labelCol="{ span: 5 }" :wrapperCol="{ span: 18, offset: 1 }">
+                    <a-input placeholder="请输入制造商" v-model="queryParam.mfrs"></a-input>
+                  </a-form-item>
+                </a-col> -->
+                <a-col :md="6" :sm="24">
+                  <a-form-item label="序列号" :labelCol="labelCol" :wrapperCol="wrapperCol">
+                    <a-select placeholder="有无序列号" v-model="queryParam.enableSerialNumber">
+                      <a-select-option value="1">有</a-select-option>
+                      <a-select-option value="0">无</a-select-option>
+                    </a-select>
+                  </a-form-item>
+                </a-col>
+                <!-- <a-col :md="6" :sm="24">
+                  <a-form-item label="仓库货架" :labelCol="labelCol" :wrapperCol="wrapperCol">
+                    <a-input placeholder="请输入仓库货架" v-model="queryParam.position"></a-input>
+                  </a-form-item>
+                </a-col> -->
+                <!-- <a-col :md="6" :sm="24">
+                  <a-form-item label="批号" :labelCol="{ span: 5 }" :wrapperCol="{ span: 18, offset: 1 }">
+                    <a-select placeholder="有无批号" v-model="queryParam.enableBatchNumber">
+                      <a-select-option value="1">有</a-select-option>
+                      <a-select-option value="0">无</a-select-option>
+                    </a-select>
+                  </a-form-item>
+                </a-col> -->
+              </template>
+            </a-row>
+          </a-form>
+          <a-button v-if="isStock" type="primary" @click="findAllSelect">一键全选</a-button>
+          <a-table
+            ref="table"
+            :scroll="scrollTrigger"
+            size="middle"
+            rowKey="id"
+            :columns="columns"
+            :dataSource="dataSource"
+            :pagination="ipagination"
+            :rowSelection="{ selectedRowKeys: selectedRowKeys, onChange: onSelectChange, type: getType }"
+            :loading="loading"
+            :customRow="rowAction"
+            @change="handleTableChange"
+          >
+            <template slot="customBarCode" slot-scope="text, record">
+              <div :style="record.imgName ? 'float:left;line-height:30px' : 'float:left;'">{{ record.mBarCode }}</div>
+              <a-popover placement="right" trigger="click">
+                <template slot="content">
+                  <img :src="getImgUrl(record.imgName, record.imgLarge)" width="500px" />
+                </template>
+                <div class="item-info" v-if="record.imgName">
+                  <img
+                    v-if="record.imgName"
+                    :src="getImgUrl(record.imgName, record.imgSmall)"
+                    class="item-img"
+                    title="查看大图"
+                  />
+                </div>
+              </a-popover>
+            </template>
+            <template slot="customName" slot-scope="text, record">
+              {{ record.name }}
+              <a-tag v-if="record.enableSerialNumber == 1" color="orange">序</a-tag>
+              <a-tag v-if="record.enableBatchNumber == 1" color="orange">批</a-tag>
+            </template>
+            <span slot="action" slot-scope="text, record">
+              <a @click.stop="handleEdit(record)">编辑</a>
+            </span>
+          </a-table>
+        </div>
+      </a-col>
+    </a-row>
+    <material-modal ref="modalForm" @ok="modalFormOk"></material-modal>
+  </a-modal>
+</template>
+
+<script>
+import { getAction, getFileAccessHttpUrl } from '@/api/manage'
+import { filterObj, getMpListShort } from '@/utils/util'
+import { getMaterialBySelect, queryMaterialCategoryTreeList, getMaterialById } from '@/api/api'
+import { JeecgListMixin } from '@/mixins/JeecgListMixin'
+import { mixinDevice } from '@/utils/mixin'
+import Vue from 'vue'
+
+export default {
+  name: 'JSelectMaterialModal',
+  mixins: [JeecgListMixin, mixinDevice],
+  components: {
+    MaterialModal: () => import('@/views/material/modules/MaterialModal'),
+  },
+  props: ['rows', 'multi', 'barCode', 'isStock'],
+  data() {
+    return {
+      modalWidth: 1450,
+      queryParam: {
+        q: '',
+        standardOrModel: '',
+        color: '',
+        brand: '',
+        categoryId: undefined,
+        mfrs: '',
+        enableSerialNumber: undefined,
+        enableBatchNumber: undefined,
+        position: '',
+      },
+      labelCol: {
+        xs: { span: 24 },
+        sm: { span: 5 },
+      },
+      wrapperCol: {
+        xs: { span: 24 },
+        sm: { span: 16 },
+      },
+      categoryTree: [],
+      columns: [
+        {
+          title: '操作',
+          dataIndex: 'action',
+          align: 'center',
+          width: 60,
+          scopedSlots: { customRender: 'action' },
+        },
+        // { dataIndex: 'mBarCode', title: '条码', scopedSlots: { customRender: 'customBarCode' } },
+        // { dataIndex: 'batchNumber', title: '批次号' },
+        { dataIndex: 'barCode', title: '商品条码' },
+        { dataIndex: 'name', title: '名称', scopedSlots: { customRender: 'customName' } },
+        { dataIndex: 'categoryName', title: '类别' },
+        // { dataIndex: 'standard', title: '规格' },
+        { dataIndex: 'model', title: '型号' },
+        { dataIndex: 'color', title: '颜色' },
+        { dataIndex: 'brand', title: '品牌' },
+        // { dataIndex: 'supplierName', title: '供应商' },
+        { dataIndex: 'unit', title: '单位' },
+        { dataIndex: 'sku', title: '多属性' },
+        { dataIndex: 'inventory', title: '库存' },
+        // { dataIndex: 'productionDate', title: '生产日期' },
+        // { dataIndex: 'expiryNum', title: '保质期' },
+        // { dataIndex: 'barCode', title: '商品条码' },
+        // { dataIndex: 'depotName', title: '仓库名称' },
+        // { dataIndex: 'position', title: '仓库货架' },
+
+        // { dataIndex: 'expand', title: '扩展信息' },
+      ],
+      scrollTrigger: {},
+      dataSource: [],
+      selectedRowKeys: [],
+      selectMaterialRows: [],
+      selectMaterialIds: [],
+      title: '选择商品',
+      ipagination: {
+        current: 1,
+        pageSize: 10,
+        pageSizeOptions: ['10', '20', '30'],
+        showTotal: (total, range) => {
+          return range[0] + '-' + range[1] + ' 共' + total + '条'
+        },
+        showQuickJumper: true,
+        showSizeChanger: true,
+        total: 0,
+      },
+      isorter: {
+        column: 'createTime',
+        order: 'desc',
+      },
+      departTree: [],
+      depotList: [],
+      visible: false,
+      form: this.$form.createForm(this),
+      loading: false,
+      expandedKeys: [],
+      disableMixinCreated: true,
+    }
+  },
+  computed: {
+    // 计算属性的 getter
+    getType: function () {
+      return this.multi == true ? 'checkbox' : 'radio'
+    },
+  },
+  watch: {
+    barCode: {
+      immediate: true,
+      handler() {
+        this.initBarCode()
+      },
+    },
+  },
+  created() {
+    // 该方法触发屏幕自适应
+    this.resetScreenSize()
+  },
+  methods: {
+    initBarCode() {
+      if (this.barCode) {
+        this.$emit('initComp', this.barCode)
+      } else {
+        // JSelectUserByDep组件bug issues/I16634
+        this.$emit('initComp', '')
+      }
+    },
+    loadMaterialData(arg) {
+      if (arg === 1) {
+        this.ipagination.current = 1
+      }
+      this.loading = true
+      let params = this.getQueryParams() //查询条件
+      getMaterialBySelect(params).then((res) => {
+        if (res) {
+          this.dataSource = res.rows
+          this.ipagination.total = res.total
+          if (res.total === 1) {
+            if (
+              this.queryParam.q === this.dataSource[0].barCode ||
+              this.queryParam.q === this.dataSource[0].name ||
+              this.queryParam.q === this.dataSource[0].mnemonic
+            ) {
+              this.title = '选择商品【再次回车可以直接选中】'
+              this.$nextTick(() => this.$refs.material.focus())
+            } else {
+              this.title = '选择商品'
+            }
+          } else {
+            this.title = '选择商品'
+          }
+        }
+        this.loading = false
+        this.onClearSelected()
+      })
+    },
+    loadTreeData() {
+      let that = this
+      let params = {}
+      params.id = ''
+      queryMaterialCategoryTreeList(params).then((res) => {
+        if (res) {
+          that.categoryTree = []
+          for (let i = 0; i < res.length; i++) {
+            let temp = res[i]
+            that.categoryTree.push(temp)
+          }
+        }
+      })
+    },
+    // 触发屏幕自适应
+    resetScreenSize() {
+      let realScreenWidth = window.screen.width
+      this.modalWidth = realScreenWidth < 1600 ? '1300px' : '1550px'
+      let screenWidth = document.body.clientWidth
+      if (screenWidth < 500) {
+        this.scrollTrigger = { x: 800 }
+      } else {
+        this.scrollTrigger = {}
+      }
+    },
+    showModal(barCode) {
+      this.visible = true
+      this.title = '选择商品'
+      this.queryParam.q = barCode
+      this.$nextTick(() => this.$refs.material.focus())
+      this.loadTreeData()
+      // this.getDepotList()
+      // this.initDepotSelect()
+      this.loadMaterialData()
+      this.form.resetFields()
+    },
+    getQueryParams() {
+      let param = Object.assign({}, this.queryParam, this.isorter)
+      param.mpList = getMpListShort(Vue.ls.get('materialPropertyList')) //扩展属性
+      param.page = this.ipagination.current
+      param.rows = this.ipagination.pageSize
+      return filterObj(param)
+    },
+    getQueryField() {
+      let str = 'id,'
+      for (let a = 0; a < this.columns.length; a++) {
+        str += ',' + this.columns[a].dataIndex
+      }
+      return str
+    },
+    searchReset(num) {
+      let that = this
+      if (num !== 0) {
+        that.queryParam = {}
+        that.loadMaterialData(1)
+      }
+      that.selectedRowKeys = []
+      that.selectMaterialIds = []
+    },
+    addMaterial() {
+      this.$refs.modalForm.add()
+      this.$refs.modalForm.title = '新增商品'
+    },
+    handleEdit(record) {
+      getMaterialById({ mid: record.mid }).then((res) => {
+        this.$refs.modalForm.edit(res.data)
+        this.$refs.modalForm.title = '编辑'
+        this.$refs.modalForm.disableSubmit = false
+        this.$refs.modalForm.showOkFlag = true
+      })
+    },
+    getImgUrl(imgName, type) {
+      if (imgName && imgName.split(',')) {
+        type = type ? type + '/' : ''
+        return getFileAccessHttpUrl('systemConfig/static/' + type + imgName.split(',')[0])
+      } else {
+        return ''
+      }
+    },
+    close() {
+      this.searchReset(0)
+      this.visible = false
+    },
+    handleTableChange(pagination, filters, sorter) {
+      if (Object.keys(sorter).length > 0) {
+        this.isorter.column = sorter.field
+        this.isorter.order = 'ascend' === sorter.order ? 'asc' : 'desc'
+      }
+      this.ipagination = pagination
+      this.loadMaterialData()
+    },
+    handleSubmit() {
+      let that = this
+      this.getSelectMaterialRows()
+      that.$emit('ok', that.selectMaterialRows, that.selectMaterialIds)
+      that.searchReset(0)
+      that.close()
+    },
+    //获取选择信息
+    getSelectMaterialRows(rowId) {
+      let dataSource = this.dataSource
+      let materialIds = ''
+      this.selectMaterialRows = []
+      console.log('getSelectMaterialRows', this.selectedRowKeys)
+      for (let i = 0, len = dataSource.length; i < len; i++) {
+        if (this.selectedRowKeys.includes(dataSource[i].id)) {
+          this.selectMaterialRows.push(dataSource[i])
+          materialIds = materialIds + ',' + dataSource[i].barCode
+        }
+      }
+      console.log('materialIds=====',materialIds)
+      this.selectMaterialIds = materialIds.substring(1)
+    },
+    getDepotList() {
+      let that = this
+      getAction('/depot/findDepotByCurrentUser').then((res) => {
+        if (res.code === 200) {
+          that.depotList = res.data
+        }
+      })
+    },
+    // initDepotSelect() {
+    //   if (this.rows) {
+    //     if (JSON.parse(this.rows).depotId) {
+    //       const id = JSON.parse(this.rows).depotId - 0
+    //       this.queryParam.depotId = id + ''
+    //     }
+    //   }
+    // },
+    // onDepotChange(value) {
+    //   this.queryParam.depotId = value
+    // },
+    onSelectChange(selectedRowKeys, selectionRows) {
+      this.selectedRowKeys = selectedRowKeys
+      this.selectionRows = selectionRows
+      console.log('onSelectChange', selectedRowKeys, selectionRows)
+    },
+    onSearch() {
+      if (this.dataSource && this.dataSource.length === 1) {
+        if (
+          this.queryParam.q === this.dataSource[0].mBarCode ||
+          this.queryParam.q === this.dataSource[0].name ||
+          this.queryParam.q === this.dataSource[0].mnemonic
+        ) {
+          let arr = []
+          arr.push(this.dataSource[0].id)
+          this.selectedRowKeys = arr
+          this.handleSubmit()
+        } else {
+          this.loadMaterialData(1)
+        }
+      } else {
+        this.loadMaterialData(1)
+      }
+    },
+    modalFormOk() {
+      this.loadMaterialData()
+    },
+    rowAction(record, index) {
+      return {
+        on: {
+          click: () => {
+            let arr = []
+            arr.push(record.id)
+            this.selectedRowKeys = arr
+          },
+          dblclick: () => {
+            let arr = []
+            arr.push(record.id)
+            this.selectedRowKeys = arr
+            this.handleSubmit()
+          },
+        },
+      }
+    },
+    findAllSelect() {
+      this.$emit('all', this.queryParam)
+    },
+  },
+}
+</script>
+
+<style scoped>
+.ant-table-tbody .ant-table-row td {
+  padding-top: 10px;
+  padding-bottom: 10px;
+}
+
+#components-layout-demo-custom-trigger .trigger {
+  font-size: 18px;
+  line-height: 64px;
+  padding: 0 24px;
+  cursor: pointer;
+  transition: color 0.3s;
+}
+
+.item-info {
+  float: left;
+  width: 30px;
+  height: 30px;
+  margin-left: 8px;
+}
+.item-img {
+  cursor: pointer;
+  position: static;
+  display: block;
+  width: 100%;
+  height: 100%;
+  object-fit: cover;
+}
+</style>

+ 1 - 0
jshERP-web/src/utils/JEditableTableUtil.js

@@ -63,6 +63,7 @@ export function validateFormAndTables(form, cases) {
     })
   })
     .then((values) => {
+      console.log(11111,values)
       Object.assign(options, { formValue: values })
       // 验证所有子表的表单
       return validateTables(cases)

+ 6 - 6
jshERP-web/src/views/bill/dialog/BillDetail.vue

@@ -1640,7 +1640,7 @@ export default {
         { title: '品牌', dataIndex: 'brand', width: 90 },
         { title: '制造商', dataIndex: 'mfrs', width: 90 },
         { title: '扩展信息', dataIndex: 'materialOther', width: 90 },
-        { title: '库存', dataIndex: 'stock', width: 90 },
+        { title: '库存', dataIndex: 'inventory', width: 90 },
         { title: '单位', dataIndex: 'unit', width: 90 },
         { title: '序列号', dataIndex: 'snList', width: 300 },
         { title: '有效期', dataIndex: 'expirationDate', width: 90 },
@@ -1746,7 +1746,7 @@ export default {
         { title: '品牌', dataIndex: 'brand', width: 90 },
         { title: '制造商', dataIndex: 'mfrs', width: 90 },
         { title: '扩展信息', dataIndex: 'materialOther', width: 90 },
-        { title: '库存', dataIndex: 'stock', width: 90 },
+        { title: '库存', dataIndex: 'inventory', width: 90 },
         { title: '单位', dataIndex: 'unit', width: 90 },
         { title: '序列号', dataIndex: 'snList', width: 300 },
         { title: '有效期', dataIndex: 'expirationDate', width: 90 },
@@ -1786,7 +1786,7 @@ export default {
         { title: '品牌', dataIndex: 'brand', width: 90 },
         { title: '制造商', dataIndex: 'mfrs', width: 90 },
         { title: '扩展信息', dataIndex: 'materialOther', width: 90 },
-        { title: '库存', dataIndex: 'stock', width: 90 },
+        { title: '库存', dataIndex: 'inventory', width: 90 },
         { title: '单位', dataIndex: 'unit', width: 90 },
         { title: '序列号', dataIndex: 'snList', width: 300 },
         { title: '有效期', dataIndex: 'expirationDate', width: 90 },
@@ -1852,7 +1852,7 @@ export default {
         { title: '品牌', dataIndex: 'brand', width: 90 },
         { title: '制造商', dataIndex: 'mfrs', width: 90 },
         { title: '扩展信息', dataIndex: 'materialOther', width: 90 },
-        { title: '库存', dataIndex: 'stock', width: 90 },
+        { title: '库存', dataIndex: 'inventory', width: 90 },
         { title: '单位', dataIndex: 'unit', width: 90 },
         { title: '序列号', dataIndex: 'snList', width: 300 },
         { title: '有效期', dataIndex: 'expirationDate', width: 90 },
@@ -1887,7 +1887,7 @@ export default {
         { title: '品牌', dataIndex: 'brand', width: 90 },
         { title: '制造商', dataIndex: 'mfrs', width: 90 },
         { title: '扩展信息', dataIndex: 'materialOther', width: 90 },
-        { title: '库存', dataIndex: 'stock', width: 90 },
+        { title: '库存', dataIndex: 'inventory', width: 90 },
         { title: '单位', dataIndex: 'unit', width: 90 },
         { title: '序列号', dataIndex: 'snList', width: 300 },
         { title: '有效期', dataIndex: 'expirationDate', width: 90 },
@@ -1923,7 +1923,7 @@ export default {
         { title: '品牌', dataIndex: 'brand', width: 90 },
         { title: '制造商', dataIndex: 'mfrs', width: 90 },
         { title: '扩展信息', dataIndex: 'materialOther', width: 90 },
-        { title: '库存', dataIndex: 'stock', width: 90 },
+        { title: '库存', dataIndex: 'inventory', width: 90 },
         { title: '调入仓库', dataIndex: 'anotherDepotName' },
         { title: '单位', dataIndex: 'unit', width: 90 },
         { title: '多属性', dataIndex: 'sku' },

+ 97 - 3
jshERP-web/src/views/bill/mixins/BillModalMixin.js

@@ -8,6 +8,8 @@ import {
   getBatchNumberList,
   getCurrentSystemConfig,
   getMaterialByBatchNumber,
+  getMaterialByBarCode,
+  getMaterialBySelect,
   getPersonByNumType,
   getPlatformConfigByKey,
   getUnitInfo,
@@ -82,6 +84,9 @@ export const BillModalMixin = {
   },
   watch:{
     $route(to, from) {
+      if(this.handleCancel){
+        this.handleCancel()
+      }
       this.visible = false
     }
   },
@@ -383,8 +388,6 @@ export const BillModalMixin = {
       this.initRetail(1)
     },
     batchSetDepotModalFormOk(depotId) {
-      console.log('22222222222222222211')
-
       this.getAllTable()
         .then((tables) => {
           return getListData(this.form, tables)
@@ -471,7 +474,35 @@ export const BillModalMixin = {
         })
       }
     },
-
+    //根据【仓库名】带出对应的【仓位货架】
+    async setProPosition(barCode, depotId, event){
+      const { row, column, value, target } = event
+      const res = await getMaterialBySelect({
+        q: barCode,
+        page: 1,
+        rows: 20
+      })
+      let proDetail
+      if (res && res.rows) {
+        proDetail = res.rows[0]? res.rows[0] : {}
+      }
+      // 商品id
+      if(proDetail.mid){
+        const res2 = await getAction('/material/getPositionByDidAndMid', { mid: proDetail.mid, did: depotId })
+        console.log('getPositionByDidAndMid======',res2)
+        if (res2 && res2.code === 200) {
+          const msg = res2.msg
+          if(msg){
+            target.setValues([
+              {
+                rowKey: row.id,
+                values: { position: msg },
+              },
+            ])
+          }
+        }
+      }
+    },
     //单元值改变一个字符就触发一次
     onValueChange(event) {
       let that = this
@@ -483,6 +514,16 @@ export const BillModalMixin = {
           if (row.barCode) {
             that.getStockByDepotBarCode(row, target)
           }
+          console.log('row========', row)
+          // // 选择商品自动带出barCode、商品ID
+          if(row.depotId&&row.barCode){
+            // console.log('row.depotId========', row.depotId)
+            // // 根据仓库id自动带出仓位货架(若有)参数:商品id、仓库id
+            // getAction('/material/getPositionByDidAndMid',{mid:row.mid,did:row.depotId}).then((res) => {
+            //   console.log('res========', res)
+            // })
+            this.setProPosition(row.barCode, row.depotId, event)
+          }
           break
         case 'batchNumber':
           param = {
@@ -566,6 +607,58 @@ export const BillModalMixin = {
             }
           })
           break
+        case 'barCode':
+          param = {
+            barCode: value,
+            organId: this.form.getFieldValue('organId'),
+            mpList: getMpListShort(Vue.ls.get('materialPropertyList')), //扩展属性
+            prefixNo: this.prefixNo,
+          }
+          getMaterialByBarCode(param).then((res) => {
+            if (res && res.code === 200) {
+              let mList = res.data
+              target.getValues((error, values) => {
+                const clickRowIndex = values.findIndex((item) => item.id === row.id) //获取当前行的索引
+                // values.pop() //移除最后一行数据
+                values.splice(clickRowIndex, 1) //移除当前行数据
+                let mArr = values // 新加的行
+                for (let i = 0; i < mList.length; i++) {
+                  let mInfo = mList[i]
+                  if (mInfo.unitId) {
+                    mInfo.unitList = JSON.stringify(mInfo.unitList)
+                  }
+                  this.changeColumnShow(mInfo)
+                  let mObj = this.parseInfoToObj(mInfo)
+                  mObj.depotId = mInfo.depotId
+                  mObj.stock = mInfo.stock
+                  mObj.inventory = mInfo.inventory
+                  mArr.push(mObj)
+                }
+                let allPriceTotal = 0
+                let taxLastMoneyTotal = 0
+                for (let j = 0; j < mArr.length; j++) {
+                  allPriceTotal += mArr[j].allPrice - 0
+                  taxLastMoneyTotal += mArr[j].taxLastMoney - 0
+                  //组合和拆分单据给商品类型进行重新赋值
+                  if (j === 0) {
+                    mArr[0].mType = '组合件'
+                  } else {
+                    mArr[j].mType = '普通子件'
+                  }
+                }
+                this.materialTable.dataSource = mArr
+                if (this.prefixNo === 'LSCK' || this.prefixNo === 'LSTH') {
+                  target.statisticsColumns.allPrice = allPriceTotal
+                } else {
+                  target.statisticsColumns.taxLastMoney = taxLastMoneyTotal
+                }
+                that.autoChangePrice(target)
+                //强制渲染
+                target.$forceUpdate()
+              })
+            }
+          })
+          break
         case 'snList':
           snList = value
           if (snList) {
@@ -751,6 +844,7 @@ export const BillModalMixin = {
         unitId: mInfo.unitId,
         unitList: mInfo.unitList,
         depotId: mInfo.depotId,
+        inventory: mInfo.inventory,
       }
     },
     //使得型号、颜色、扩展信息、sku等为隐藏

+ 1 - 1
jshERP-web/src/views/bill/modules/AllocationOutModal.vue

@@ -233,7 +233,7 @@ export default {
           { title: '品牌', key: 'brand', width: '9%', type: FormTypes.normal },
           { title: '制造商', key: 'mfrs', width: '6%', type: FormTypes.normal },
           { title: '扩展信息', key: 'materialOther', width: '5%', type: FormTypes.normal },
-          { title: '库存', key: 'stock', width: '5%', type: FormTypes.normal },
+          { title: '库存', key: 'inventory', width: '5%', type: FormTypes.normal },
           {
             title: '调入仓库',
             key: 'anotherDepotId',

+ 56 - 43
jshERP-web/src/views/bill/modules/OtherInModal.vue

@@ -283,76 +283,89 @@ export default {
           // },
           // { title: '批次号', key: 'batchNumber', width: '9%', type: FormTypes.normal },
           {
-            title: '批次号',
-            key: 'batchNumber',
-            width: '12%',
+            title: '商品条码',
+            key: 'barCode',
+            width: '200px',
             type: FormTypes.popupJsh,
-            kind: 'material',
+            kind: 'material2',
             multi: true,
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '名称', key: 'name', width: '9%', type: FormTypes.normal },
+          { title: '名称', key: 'name', width: '120px', type: FormTypes.normal },
           // { title: '规格', key: 'standard', width: '9%', type: FormTypes.normal },
 
-          { title: '生产日期', key: 'productionDate', width: '9%', type: FormTypes.normal },
-          { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
-          { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '9%', type: FormTypes.normal },
-          { title: '仓库货架', key: 'position', width: '6%', type: FormTypes.normal },
-          { title: '包装规格', key: 'unitName', width: '7%', type: FormTypes.normal },
+          {
+            title: '生产日期',
+            key: 'productionDate',
+            width: '200px',
+            type: FormTypes.datetime,
+            validateRules: [{ required: true, message: '${title}不能为空' }],
+          },
+          { title: '保质期', key: 'expiryNum', width: '120px', type: FormTypes.inputNumber },
+          // { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
+          { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 
-          { title: '型号', key: 'model', width: '9%', type: FormTypes.normal },
-          { title: '颜色', key: 'color', width: '9%', type: FormTypes.normal },
-          { title: '品牌', key: 'brand', width: '9%', type: FormTypes.normal },
-          { title: '制造商', key: 'mfrs', width: '6%', type: FormTypes.normal },
-          { title: '扩展信息', key: 'materialOther', width: '5%', type: FormTypes.normal },
-          { title: '库存', key: 'stock', width: '5%', type: FormTypes.normal },
+          { title: '型号', key: 'model', width: '120px', type: FormTypes.normal },
+          { title: '颜色', key: 'color', width: '120px', type: FormTypes.normal },
+          { title: '品牌', key: 'brand', width: '120px', type: FormTypes.normal },
+          { title: '制造商', key: 'mfrs', width: '120px', type: FormTypes.normal },
+          { title: '扩展信息', key: 'materialOther', width: '120px', type: FormTypes.normal },
+          { title: '库存', key: 'stock', width: '120px', type: FormTypes.normal },
           {
             title: '单位',
             key: 'unit',
-            width: '6%',
-            type: FormTypes.slot,
-            options: [],
-            allowClear: false,
-            slotName: 'unit',
+            width: '120px',
+            type: FormTypes.normal,
+            // options: [],
+            // allowClear: false,
+            // slotName: 'unit',
           },
-          { title: '单位id', key: 'unitId', width: '4%', type: FormTypes.hidden },
-          { title: '单位列表', key: 'unitList', width: '5%', type: FormTypes.hidden },
-          { title: '序列号', key: 'snList', width: '12%', type: FormTypes.popupJsh, kind: 'snAdd', multi: true },
-          { title: '有效期', key: 'expirationDate', width: '7%', type: FormTypes.date },
-          { title: '多属性', key: 'sku', width: '9%', type: FormTypes.normal },
-          { title: '原数量', key: 'preNumber', width: '4%', type: FormTypes.normal },
-          { title: '已入库', key: 'finishNumber', width: '4%', type: FormTypes.normal },
+          {
+            title: '销售价',
+            key: 'wholesaleDecimal',
+            width: '120px',
+            type: FormTypes.input,
+            validateRules: [{ required: true, message: '${title}不能为空' }],
+          },
+          { title: '单位id', key: 'unitId', width: '120px', type: FormTypes.hidden },
+          { title: '单位列表', key: 'unitList', width: '120px', type: FormTypes.hidden },
+          { title: '序列号', key: 'snList', width: '120px', type: FormTypes.popupJsh, kind: 'snAdd', multi: true },
+          { title: '有效期', key: 'expirationDate', width: '120px', type: FormTypes.date },
+          { title: '多属性', key: 'sku', width: '120px', type: FormTypes.normal },
+          { title: '原数量', key: 'preNumber', width: '120px', type: FormTypes.normal },
+          { title: '已入库', key: 'finishNumber', width: '120px', type: FormTypes.normal },
           {
             title: '入库数量',
             key: 'operNumber',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             statistics: true,
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '单价', key: 'unitPrice', width: '5%', type: FormTypes.inputNumber },
-          { title: '金额', key: 'allPrice', width: '5%', type: FormTypes.inputNumber, statistics: true },
+          { title: '单价', key: 'unitPrice', width: '120px', type: FormTypes.inputNumber },
+          { title: '金额', key: 'allPrice', width: '120px', type: FormTypes.inputNumber, statistics: true },
           {
             title: '实际入库数量',
             key: 'actualQuantityInStorage',
-            width: '9%',
+            width: '120px',
             type: FormTypes.inputNumber,
             validateRules: [{ required: true, message: '实际入库数量不能为空' }],
           },
-          { title: '入库差异', key: 'warehousingVariance', width: '9%', type: FormTypes.input },
-          { title: '入库差异原因', key: 'reasonOfDifference', width: '9%', type: FormTypes.input },
+          { title: '入库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.input },
+          { title: '入库差异原因', key: 'reasonOfDifference', width: '120px', type: FormTypes.input },
           {
             title: '入库人',
             key: 'warehousingUser',
-            width: '9%',
+            width: '120px',
             type: FormTypes.slot,
             slotName: 'warehousingUser',
             validateRules: [{ required: true, message: '入库人不能为空' }],
           },
-          { title: '入库时间', key: 'warehousingTime', width: '9%', type: FormTypes.date },
-          { title: '备注', key: 'remark', width: '5%', type: FormTypes.input },
-          { title: '关联id', key: 'linkId', width: '5%', type: FormTypes.hidden },
+          { title: '入库时间', key: 'warehousingTime', width: '200px', type: FormTypes.date },
+          { title: '备注', key: 'remark', width: '200px', type: FormTypes.input },
+          { title: '关联id', key: 'linkId', width: '120px', type: FormTypes.hidden },
         ],
       },
       confirmLoading: false,
@@ -394,10 +407,10 @@ export default {
         this.fileList = []
         this.imageList = []
       } else {
-        if (this.model.linkNumber) {
-          this.rowCanEdit = false
-          this.materialTable.columns[1].type = FormTypes.normal
-        }
+        // if (this.model.linkNumber) {
+        //   this.rowCanEdit = false
+        //   this.materialTable.columns[1].type = FormTypes.normal
+        // }
         this.model.operTime = this.model.operTimeStr
         this.fileList = this.model.fileName
         this.imageList = this.model.voucherPicture

+ 44 - 43
jshERP-web/src/views/bill/modules/OtherOutModal.vue

@@ -282,78 +282,79 @@ export default {
           //   validateRules: [{ required: true, message: '${title}不能为空' }],
           // },
           {
-            title: '批次号',
-            key: 'batchNumber',
-            width: '12%',
+            title: '商品条码',
+            key: 'barCode',
+            width: '200px',
             type: FormTypes.popupJsh,
-            kind: 'material',
+            kind: 'material2',
             multi: true,
             newBatch: true,
 
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '名称', key: 'name', width: '9%', type: FormTypes.normal },
+          { title: '名称', key: 'name', width: '120px', type: FormTypes.normal },
           // { title: '规格', key: 'standard', width: '9%', type: FormTypes.normal },
 
-          { title: '生产日期', key: 'productionDate', width: '9%', type: FormTypes.normal, disabled: true },
-          { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
-          { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '9%', type: FormTypes.select, disabled: true },
-          { title: '仓库货架', key: 'position', width: '6%', type: FormTypes.normal },
-          { title: '包装规格', key: 'unitName', width: '7%', type: FormTypes.normal },
+          // { title: '生产日期', key: 'productionDate', width: '200px', type: FormTypes.normal, disabled: true },
+          // { title: '保质期', key: 'expiryNum', width: '120px', type: FormTypes.normal },
+          // { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.normal },
+          { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 
-          { title: '型号', key: 'model', width: '9%', type: FormTypes.normal },
-          { title: '颜色', key: 'color', width: '9%', type: FormTypes.normal },
-          { title: '品牌', key: 'brand', width: '9%', type: FormTypes.normal },
-          { title: '制造商', key: 'mfrs', width: '6%', type: FormTypes.normal },
-          { title: '扩展信息', key: 'materialOther', width: '5%', type: FormTypes.normal },
-          { title: '库存', key: 'stock', width: '5%', type: FormTypes.normal },
+          { title: '型号', key: 'model', width: '120px', type: FormTypes.normal },
+          { title: '颜色', key: 'color', width: '120px', type: FormTypes.normal },
+          { title: '品牌', key: 'brand', width: '120px', type: FormTypes.normal },
+          { title: '制造商', key: 'mfrs', width: '120px', type: FormTypes.normal },
+          { title: '扩展信息', key: 'materialOther', width: '120px', type: FormTypes.normal },
+          { title: '库存', key: 'stock', width: '120px', type: FormTypes.normal },
           {
             title: '单位',
             key: 'unit',
-            width: '6%',
-            type: FormTypes.slot,
-            options: [],
-            allowClear: false,
-            slotName: 'unit',
+            width: '120px',
+            type: FormTypes.normal,
+            // options: [],
+            // allowClear: false,
+            // slotName: 'unit',
           },
-          { title: '单位id', key: 'unitId', width: '4%', type: FormTypes.hidden },
-          { title: '单位列表', key: 'unitList', width: '5%', type: FormTypes.hidden },
-          { title: '序列号', key: 'snList', width: '12%', type: FormTypes.popupJsh, kind: 'sn', multi: true },
-          { title: '有效期', key: 'expirationDate', width: '7%', type: FormTypes.input, readonly: true },
-          { title: '多属性', key: 'sku', width: '9%', type: FormTypes.normal },
-          { title: '原数量', key: 'preNumber', width: '4%', type: FormTypes.normal },
-          { title: '已入库', key: 'finishNumber', width: '4%', type: FormTypes.normal },
+          { title: '销售价', key: 'wholesaleDecimal', width: '120px', type: FormTypes.input },
+          { title: '单位id', key: 'unitId', width: '120px', type: FormTypes.hidden },
+          { title: '单位列表', key: 'unitList', width: '120px', type: FormTypes.hidden },
+          { title: '序列号', key: 'snList', width: '120px', type: FormTypes.popupJsh, kind: 'sn', multi: true },
+          // { title: '有效期', key: 'expirationDate', width: '120px', type: FormTypes.date, readonly: true },
+          { title: '多属性', key: 'sku', width: '120px', type: FormTypes.normal },
+          { title: '原数量', key: 'preNumber', width: '120px', type: FormTypes.normal },
+          { title: '已入库', key: 'finishNumber', width: '120px', type: FormTypes.normal },
           {
             title: '出库数量',
             key: 'operNumber',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             statistics: true,
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '单价', key: 'unitPrice', width: '5%', type: FormTypes.inputNumber },
-          { title: '金额', key: 'allPrice', width: '5%', type: FormTypes.inputNumber, statistics: true },
+          { title: '单价', key: 'unitPrice', width: '120px', type: FormTypes.inputNumber },
+          { title: '金额', key: 'allPrice', width: '120px', type: FormTypes.inputNumber, statistics: true },
           {
             title: '实际出库数量',
             key: 'actualQuantityInStorage',
-            width: '9%',
+            width: '120px',
             type: FormTypes.inputNumber,
             validateRules: [{ required: true, message: '实际入库数量不能为空' }],
           },
-          { title: '出库差异', key: 'warehousingVariance', width: '9%', type: FormTypes.input },
-          { title: '出库差异原因', key: 'reasonOfDifference', width: '9%', type: FormTypes.input },
+          { title: '出库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.input },
+          { title: '出库差异原因', key: 'reasonOfDifference', width: '120px', type: FormTypes.input },
           {
             title: '出库人',
             key: 'warehousingUser',
-            width: '9%',
+            width: '120px',
             type: FormTypes.slot,
             slotName: 'warehousingUser',
             validateRules: [{ required: true, message: '出库人不能为空' }],
           },
-          { title: '出库时间', key: 'warehousingTime', width: '9%', type: FormTypes.date },
-          { title: '备注', key: 'remark', width: '5%', type: FormTypes.input },
-          { title: '关联id', key: 'linkId', width: '5%', type: FormTypes.hidden },
+          { title: '出库时间', key: 'warehousingTime', width: '200px', type: FormTypes.date },
+          { title: '备注', key: 'remark', width: '120px', type: FormTypes.input },
+          { title: '关联id', key: 'linkId', width: '120px', type: FormTypes.hidden },
         ],
       },
       confirmLoading: false,
@@ -395,10 +396,10 @@ export default {
         this.fileList = []
         this.imageList = []
       } else {
-        if (this.model.linkNumber) {
-          this.rowCanEdit = false
-          this.materialTable.columns[1].type = FormTypes.normal
-        }
+        // if (this.model.linkNumber) {
+        //   this.rowCanEdit = false
+        //   this.materialTable.columns[1].type = FormTypes.normal
+        // }
         this.model.operTime = this.model.operTimeStr
         this.fileList = this.model.fileName
         this.imageList = this.model.voucherPicture

+ 67 - 54
jshERP-web/src/views/bill/modules/PurchaseInModal.vue

@@ -102,7 +102,7 @@
           :loading="materialTable.loading"
           :columns="materialTable.columns"
           :dataSource="materialTable.dataSource"
-          :minWidth="minWidth"
+          :minWidth="1200"
           :maxHeight="300"
           :rowNumber="false"
           :rowSelection="rowCanEdit"
@@ -461,90 +461,103 @@ export default {
           //   validateRules: [{ required: true, message: '${title}不能为空' }],
           // },
           {
-            title: '批次号',
-            key: 'batchNumber',
-            width: '12%',
+            title: '商品条码',
+            key: 'barCode',
+            width: '200px',
             type: FormTypes.popupJsh,
-            kind: 'material',
+            kind: 'material2',
             multi: true,
             newBatch: true,
 
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '名称', key: 'name', width: '9%', type: FormTypes.normal },
-          { title: '规格', key: 'standard', width: '9%', type: FormTypes.normal },
+          { title: '名称', key: 'name', width: '120px', type: FormTypes.normal },
+          { title: '规格', key: 'standard', width: '120px', type: FormTypes.normal },
 
-          { title: '生产日期', key: 'productionDate', width: '9%', type: FormTypes.normal, disabled: true },
-          { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
-          { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '9%', type: FormTypes.select, disabled: true },
-          { title: '仓库货架', key: 'position', width: '6%', type: FormTypes.normal },
-          { title: '包装规格', key: 'unitName', width: '7%', type: FormTypes.normal },
+          {
+            title: '生产日期',
+            key: 'productionDate',
+            width: '200px',
+            type: FormTypes.datetime,
+            validateRules: [{ required: true, message: '${title}不能为空' }],
+          },
+          { title: '保质期', key: 'expiryNum', width: '120px', type: FormTypes.inputNumber },
+          // { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
+          { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 
-          { title: '型号', key: 'model', width: '9%', type: FormTypes.normal },
-          { title: '颜色', key: 'color', width: '9%', type: FormTypes.normal },
-          { title: '品牌', key: 'brand', width: '9%', type: FormTypes.normal },
-          { title: '制造商', key: 'mfrs', width: '6%', type: FormTypes.normal },
-          { title: '扩展信息', key: 'materialOther', width: '5%', type: FormTypes.normal },
-          { title: '库存', key: 'inventory', width: '5%', type: FormTypes.normal },
+          { title: '型号', key: 'model', width: '120px', type: FormTypes.normal },
+          { title: '颜色', key: 'color', width: '120px', type: FormTypes.normal },
+          { title: '品牌', key: 'brand', width: '120px', type: FormTypes.normal },
+          { title: '制造商', key: 'mfrs', width: '120px', type: FormTypes.normal },
+          { title: '扩展信息', key: 'materialOther', width: '120px', type: FormTypes.normal },
+          { title: '库存', key: 'inventory', width: '120px', type: FormTypes.normal },
           {
             title: '单位',
             key: 'unit',
-            width: '6%',
-            type: FormTypes.slot,
-            options: [],
-            allowClear: false,
-            slotName: 'unit',
+            width: '120px',
+            type: FormTypes.normal,
+            // options: [],
+            // allowClear: false,
+            // slotName: 'unit',
+          },
+          {
+            title: '销售价',
+            key: 'wholesaleDecima',
+            width: '120px',
+            type: FormTypes.input,
+            validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '单位id', key: 'unitId', width: '4%', type: FormTypes.hidden },
-          { title: '单位列表', key: 'unitList', width: '5%', type: FormTypes.hidden },
-          { title: '序列号', key: 'snList', width: '12%', type: FormTypes.popupJsh, kind: 'snAdd', multi: true },
-          { title: '有效期', key: 'expirationDate', width: '7%', type: FormTypes.date },
-          { title: '多属性', key: 'sku', width: '9%', type: FormTypes.normal },
-          { title: '原数量', key: 'preNumber', width: '4%', type: FormTypes.normal },
-          { title: '已入库', key: 'finishNumber', width: '4%', type: FormTypes.normal },
+          { title: '单位id', key: 'unitId', width: '120px', type: FormTypes.hidden },
+          { title: '单位列表', key: 'unitList', width: '120px', type: FormTypes.hidden },
+          { title: '序列号', key: 'snList', width: '120px', type: FormTypes.popupJsh, kind: 'snAdd', multi: true },
+          { title: '有效期', key: 'expirationDate', width: '120px', type: FormTypes.date },
+          { title: '多属性', key: 'sku', width: '120px', type: FormTypes.normal },
+          { title: '原数量', key: 'preNumber', width: '120px', type: FormTypes.normal },
+          { title: '已入库', key: 'finishNumber', width: '120px', type: FormTypes.normal },
           {
             title: '入库数量',
             key: 'operNumber',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             statistics: true,
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '单价', key: 'unitPrice', width: '4%', type: FormTypes.inputNumber },
-          { title: '金额', key: 'allPrice', width: '5%', type: FormTypes.inputNumber, statistics: true },
-          { title: '税率', key: 'taxRate', width: '4%', type: FormTypes.inputNumber, placeholder: '%' },
+          { title: '单价', key: 'unitPrice', width: '120px', type: FormTypes.inputNumber },
+          { title: '金额', key: 'allPrice', width: '120px', type: FormTypes.inputNumber, statistics: true },
+          { title: '税率', key: 'taxRate', width: '120px', type: FormTypes.inputNumber, placeholder: '%' },
           {
             title: '税额',
             key: 'taxMoney',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             readonly: true,
             statistics: true,
           },
-          { title: '价税合计', key: 'taxLastMoney', width: '7%', type: FormTypes.inputNumber, statistics: true },
+          { title: '价税合计', key: 'taxLastMoney', width: '120px', type: FormTypes.inputNumber, statistics: true },
 
-          {
-            title: '实际入库数量',
-            key: 'actualQuantityInStorage',
-            width: '9%',
-            type: FormTypes.inputNumber,
-            validateRules: [{ required: true, message: '实际入库数量不能为空' }],
-          },
-          { title: '入库差异', key: 'warehousingVariance', width: '9%', type: FormTypes.input },
-          { title: '入库差异原因', key: 'reasonOfDifference', width: '9%', type: FormTypes.input },
+          // {
+          //   title: '实际入库数量',
+          //   key: 'actualQuantityInStorage',
+          //   width: '120px',
+          //   type: FormTypes.inputNumber,
+          //   validateRules: [{ required: true, message: '实际入库数量不能为空' }],
+          // },
+          { title: '入库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.input },
+          { title: '入库差异原因', key: 'reasonOfDifference', width: '120px', type: FormTypes.input },
           {
             title: '入库人',
             key: 'warehousingUser',
-            width: '9%',
+            width: '120px',
             type: FormTypes.slot,
             slotName: 'warehousingUser',
             validateRules: [{ required: true, message: '入库人不能为空' }],
           },
-          { title: '入库时间', key: 'warehousingTime', width: '9%', type: FormTypes.date },
+          { title: '入库时间', key: 'warehousingTime', width: '200px', type: FormTypes.date },
 
-          { title: '备注', key: 'remark', width: '6%', type: FormTypes.input },
-          { title: '关联id', key: 'linkId', width: '5%', type: FormTypes.hidden },
+          { title: '备注', key: 'remark', width: '200px', type: FormTypes.input },
+          { title: '关联id', key: 'linkId', width: '120px', type: FormTypes.hidden },
         ],
       },
       confirmLoading: false,
@@ -597,10 +610,10 @@ export default {
           handleIntroJs(this.prefixNo, 1)
         })
       } else {
-        if (this.model.linkNumber) {
-          this.rowCanEdit = false
-          this.materialTable.columns[0].type = FormTypes.normal
-        }
+        // if (this.model.linkNumber) {
+        //   this.rowCanEdit = false
+        //   this.materialTable.columns[0].type = FormTypes.normal
+        // }
         this.model.operTime = this.model.operTimeStr
         if (this.model.deposit) {
           this.depositStatus = true

+ 58 - 46
jshERP-web/src/views/bill/modules/PurchaseOrderModal.vue

@@ -115,12 +115,11 @@
           </a-col>
         </a-row>
         <j-editable-table
-          id="billModal"
           :ref="refKeys[0]"
           :loading="materialTable.loading"
           :columns="materialTable.columns"
           :dataSource="materialTable.dataSource"
-          :minWidth="minWidth"
+          :minWidth="1200"
           :maxHeight="300"
           :rowNumber="false"
           :rowSelection="rowCanEdit"
@@ -166,7 +165,7 @@
               <a-button icon="import" @click="onImport(prefixNo)">导入明细</a-button>
             </a-row>
           </template>
-          <template #unit="{ handleChange, handleFocus, value }">
+          <!-- <template #unit="{ handleChange, handleFocus, value }">
             <a-select
               placeholder="请选择"
               v-decorator="['unit']"
@@ -182,7 +181,7 @@
                 {{ item.name }}
               </a-select-option>
             </a-select>
-          </template>
+          </template> -->
         </j-editable-table>
         <a-row class="form-row" :gutter="24">
           <a-col :lg="24" :md="24" :sm="24">
@@ -387,6 +386,7 @@ export default {
     },
   },
   data() {
+    const that = this
     return {
       title: '操作',
       width: '1600px',
@@ -419,56 +419,68 @@ export default {
         loading: false,
         dataSource: [],
         columns: [
-          { title: '', key: 'hiddenKey', width: '1%', type: FormTypes.hidden },
           {
-            title: '批次号',
-            key: 'batchNumber',
-            width: '12%',
+            title: '商品条码',
+            key: 'barCode',
+            width: '200px',
             type: FormTypes.popupJsh,
-            kind: 'material',
+            kind: 'material2',
             multi: true,
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '名称', key: 'name', width: '10%', type: FormTypes.normal },
-          { title: '规格', key: 'standard', width: '9%', type: FormTypes.normal },
+          { title: '名称', key: 'name', width: '120px', type: FormTypes.normal },
+          { title: '规格', key: 'standard', width: '120px', type: FormTypes.normal },
 
-          { title: '生产日期', key: 'productionDate', width: '9%', type: FormTypes.normal },
-          { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
-          { title: '商品条码', key: 'barCode', width: '6%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '9%', type: FormTypes.select, disabled: true },
-          { title: '仓库货架', key: 'position', width: '6%', type: FormTypes.normal },
-          { title: '包装规格', key: 'unitName', width: '6%', type: FormTypes.normal },
+          {
+            title: '生产日期',
+            key: 'productionDate',
+            width: '200px',
+            type: FormTypes.datetime,
+            validateRules: [{ required: true, message: '${title}不能为空' }],
+          },
+          { title: '保质期', key: 'expiryNum', width: '120px', type: FormTypes.inputNumber },
+          // { title: '商品条码', key: 'barCode', width: '120px', type: FormTypes.normal },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
+          { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 
-          { title: '型号', key: 'model', width: '9%', type: FormTypes.normal },
-          { title: '颜色', key: 'color', width: '5%', type: FormTypes.normal },
-          { title: '品牌', key: 'brand', width: '6%', type: FormTypes.normal },
-          { title: '制造商', key: 'mfrs', width: '6%', type: FormTypes.normal },
-          { title: '扩展信息', key: 'materialOther', width: '5%', type: FormTypes.normal },
-          { title: '库存', key: 'inventory', width: '5%', type: FormTypes.normal },
+          { title: '型号', key: 'model', width: '120px', type: FormTypes.normal },
+          { title: '颜色', key: 'color', width: '120px', type: FormTypes.normal },
+          { title: '品牌', key: 'brand', width: '120px', type: FormTypes.normal },
+          { title: '制造商', key: 'mfrs', width: '120px', type: FormTypes.normal },
+          { title: '扩展信息', key: 'materialOther', width: '120px', type: FormTypes.normal },
+          { title: '库存', key: 'inventory', width: '120px', type: FormTypes.normal },
           {
             title: '单位',
             key: 'unit',
-            width: '6%',
-            type: FormTypes.slot,
-            options: [],
-            allowClear: false,
-            slotName: 'unit',
+            width: '120px',
+            type: FormTypes.normal,
+            // options: [],
+            // allowClear: false,
+            // slotName: 'unit',
           },
-          { title: '单位id', key: 'unitId', width: '4%', type: FormTypes.hidden },
-          { title: '单位列表', key: 'unitList', width: '5%', type: FormTypes.hidden },
-          { title: '多属性', key: 'sku', width: '9%', type: FormTypes.normal },
-          { title: '原数量', key: 'preNumber', width: '4%', type: FormTypes.normal },
-          { title: '已采购', key: 'finishNumber', width: '4%', type: FormTypes.normal },
+          {
+            title: '销售价',
+            key: 'wholesaleDecima',
+            width: '120px',
+            type: FormTypes.input,
+            validateRules: [{ required: true, message: '${title}不能为空' }],
+          },
+          { title: '单位id', key: 'unitId', width: '120px', type: FormTypes.hidden },
+          { title: '单位列表', key: 'unitList', width: '120px', type: FormTypes.hidden },
+          { title: '多属性', key: 'sku', width: '120px', type: FormTypes.normal },
+          { title: '原数量', key: 'preNumber', width: '120px', type: FormTypes.normal },
+          { title: '已采购', key: 'finishNumber', width: '120px', type: FormTypes.normal },
           {
             title: '数量',
             key: 'operNumber',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             statistics: true,
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '单价', key: 'unitPrice', width: '5%', type: FormTypes.inputNumber },
-          { title: '金额', key: 'allPrice', width: '5%', type: FormTypes.inputNumber, statistics: true },
+          { title: '单价', key: 'unitPrice', width: '120px', type: FormTypes.inputNumber },
+          { title: '金额', key: 'allPrice', width: '120px', type: FormTypes.inputNumber, statistics: true },
 
           // {
           //   title: '实际入库数量',
@@ -488,18 +500,18 @@ export default {
           // },
           // { title: '入库时间', key: 'warehousingTime', width: '9%', type: FormTypes.date },
 
-          { title: '税率', key: 'taxRate', width: '4%', type: FormTypes.inputNumber, placeholder: '%' },
+          { title: '税率', key: 'taxRate', width: '120px', type: FormTypes.inputNumber, placeholder: '%' },
           {
             title: '税额',
             key: 'taxMoney',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             readonly: true,
             statistics: true,
           },
-          { title: '价税合计', key: 'taxLastMoney', width: '7%', type: FormTypes.inputNumber, statistics: true },
-          { title: '备注', key: 'remark', width: '6%', type: FormTypes.input },
-          { title: '关联id', key: 'linkId', width: '5%', type: FormTypes.hidden },
+          { title: '价税合计', key: 'taxLastMoney', width: '120px', type: FormTypes.inputNumber, statistics: true },
+          { title: '备注', key: 'remark', width: '200px', type: FormTypes.input },
+          { title: '关联id', key: 'linkId', width: '120px', type: FormTypes.hidden },
         ],
       },
       confirmLoading: false,
@@ -527,7 +539,7 @@ export default {
       this.billStatus = '0'
       this.currentSelectDepotId = ''
       this.rowCanEdit = true
-      this.materialTable.columns[1].type = FormTypes.popupJsh
+      // this.materialTable.columns[1].type = FormTypes.popupJsh
       this.changeColumnHide()
       this.changeFormTypes(this.materialTable.columns, 'preNumber', 0)
       this.changeFormTypes(this.materialTable.columns, 'finishNumber', 0)
@@ -539,10 +551,10 @@ export default {
           handleIntroJs(this.prefixNo, 1)
         })
       } else {
-        if (this.model.linkNumber) {
-          this.rowCanEdit = false
-          this.materialTable.columns[1].type = FormTypes.normal
-        }
+        // if (this.model.linkNumber) {
+        //   this.rowCanEdit = false
+        //   this.materialTable.columns[1].type = FormTypes.normal
+        // }
         this.model.operTime = this.model.operTimeStr
         if (this.model.accountId == null && this.model.accountIdList) {
           this.model.accountId = 0

+ 38 - 38
jshERP-web/src/views/bill/modules/SaleOrderModal.vue

@@ -146,7 +146,7 @@
               <a-button icon="import" @click="onImport(prefixNo)">导入明细</a-button>
             </a-row>
           </template>
-          <template #unit="{ handleChange, handleFocus, value }">
+          <!-- <template #unit="{ handleChange, handleFocus, value }">
             <a-select
               placeholder="请选择"
               v-decorator="['unit']"
@@ -162,7 +162,7 @@
                 {{ item.name }}
               </a-select-option>
             </a-select>
-          </template>
+          </template> -->
         </j-editable-table>
         <a-row class="form-row" :gutter="24">
           <a-col :lg="24" :md="24" :sm="24">
@@ -385,68 +385,68 @@ export default {
         loading: false,
         dataSource: [],
         columns: [
-          { title: '', key: 'hiddenKey', width: '1%', type: FormTypes.hidden },
+          // { title: '', key: 'hiddenKey', width: '1%', type: FormTypes.hidden },
           {
-            title: '批次号',
-            key: 'batchNumber',
-            width: '12%',
+            title: '商品条码',
+            key: 'barCode',
+            width: '200px',
             type: FormTypes.popupJsh,
-            kind: 'material',
+            kind: 'material2',
             multi: true,
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '名称', key: 'name', width: '9%', type: FormTypes.normal },
+          { title: '名称', key: 'name', width: '120px', type: FormTypes.normal },
           // { title: '规格', key: 'standard', width: '9%', type: FormTypes.normal },
 
-          { title: '生产日期', key: 'productionDate', width: '6%', type: FormTypes.normal },
-          { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
-          { title: '商品条码', key: 'barCode', width: '6%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '9%', type: FormTypes.select, disabled: true },
-          { title: '仓库货架', key: 'position', width: '6%', type: FormTypes.normal },
-          { title: '包装规格', key: 'unitName', width: '6%', type: FormTypes.normal },
+          // { title: '生产日期', key: 'productionDate', width: '6%', type: FormTypes.normal },
+          // { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
+          // { title: '商品条码', key: 'barCode', width: '6%', type: FormTypes.normal },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
+          { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 
-          { title: '型号', key: 'model', width: '9%', type: FormTypes.normal },
-          { title: '颜色', key: 'color', width: '5%', type: FormTypes.normal },
-          { title: '品牌', key: 'brand', width: '6%', type: FormTypes.normal },
-          { title: '制造商', key: 'mfrs', width: '6%', type: FormTypes.normal },
-          { title: '扩展信息', key: 'materialOther', width: '5%', type: FormTypes.normal },
-          { title: '库存', key: 'stock', width: '5%', type: FormTypes.normal },
+          { title: '型号', key: 'model', width: '120px', type: FormTypes.normal },
+          { title: '颜色', key: 'color', width: '120px', type: FormTypes.normal },
+          { title: '品牌', key: 'brand', width: '120px', type: FormTypes.normal },
+          { title: '制造商', key: 'mfrs', width: '120px', type: FormTypes.normal },
+          { title: '扩展信息', key: 'materialOther', width: '120px', type: FormTypes.normal },
+          { title: '库存', key: 'stock', width: '120px', type: FormTypes.normal },
           {
             title: '单位',
             key: 'unit',
-            width: '6%',
-            type: FormTypes.slot,
-            options: [],
-            allowClear: false,
-            slotName: 'unit',
+            width: '120px',
+            type: FormTypes.normal,
+            // options: [],
+            // allowClear: false,
+            // slotName: 'unit',
           },
-          { title: '单位id', key: 'unitId', width: '4%', type: FormTypes.hidden },
-          { title: '单位列表', key: 'unitList', width: '5%', type: FormTypes.hidden },
-          { title: '序列号', key: 'snList', width: '12%', type: FormTypes.popupJsh, kind: 'sn', multi: true },
-          { title: '有效期', key: 'expirationDate', width: '7%', type: FormTypes.input, readonly: true },
-          { title: '多属性', key: 'sku', width: '9%', type: FormTypes.normal },
+          { title: '单位id', key: 'unitId', width: '120px', type: FormTypes.hidden },
+          { title: '单位列表', key: 'unitList', width: '120px', type: FormTypes.hidden },
+          { title: '序列号', key: 'snList', width: '120px', type: FormTypes.popupJsh, kind: 'sn', multi: true },
+          // { title: '有效期', key: 'expirationDate', width: '7%', type: FormTypes.input, readonly: true },
+          { title: '多属性', key: 'sku', width: '120px', type: FormTypes.normal },
           // { title: '原数量', key: 'preNumber', width: '4%', type: FormTypes.normal },
           // { title: '已出库', key: 'finishNumber', width: '4%', type: FormTypes.normal },
           {
             title: '出库数量',
             key: 'operNumber',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             statistics: true,
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '单价', key: 'unitPrice', width: '4%', type: FormTypes.inputNumber },
-          { title: '金额', key: 'allPrice', width: '5%', type: FormTypes.inputNumber, statistics: true },
-          { title: '税率', key: 'taxRate', width: '4%', type: FormTypes.inputNumber, placeholder: '%' },
+          { title: '单价', key: 'unitPrice', width: '120px', type: FormTypes.inputNumber },
+          { title: '金额', key: 'allPrice', width: '120px', type: FormTypes.inputNumber, statistics: true },
+          { title: '税率', key: 'taxRate', width: '120px', type: FormTypes.inputNumber, placeholder: '%' },
           {
             title: '税额',
             key: 'taxMoney',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             readonly: true,
             statistics: true,
           },
-          { title: '价税合计', key: 'taxLastMoney', width: '7%', type: FormTypes.inputNumber, statistics: true },
+          { title: '价税合计', key: 'taxLastMoney', width: '120px', type: FormTypes.inputNumber, statistics: true },
 
           // {
           //   title: '实际出库数量',
@@ -466,8 +466,8 @@ export default {
           // },
           // { title: '出库时间', key: 'warehousingTime', width: '9%', type: FormTypes.date },
 
-          { title: '备注', key: 'remark', width: '6%', type: FormTypes.input },
-          { title: '关联id', key: 'linkId', width: '5%', type: FormTypes.hidden },
+          { title: '备注', key: 'remark', width: '200px', type: FormTypes.input },
+          { title: '关联id', key: 'linkId', width: '120px', type: FormTypes.hidden },
         ],
       },
       confirmLoading: false,

+ 46 - 46
jshERP-web/src/views/bill/modules/SaleOutModal.vue

@@ -486,90 +486,90 @@ export default {
         dataSource: [],
         columns: [
           {
-            title: '批次号',
-            key: 'batchNumber',
-            width: '12%',
+            title: '商品条码',
+            key: 'barCode',
+            width: '200px',
             type: FormTypes.popupJsh,
-            kind: 'material',
+            kind: 'material2',
             multi: true,
             newBatch: true,
 
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '名称', key: 'name', width: '9%', type: FormTypes.normal },
+          { title: '名称', key: 'name', width: '120px', type: FormTypes.normal },
           // { title: '规格', key: 'standard', width: '9%', type: FormTypes.normal },
 
-          { title: '生产日期', key: 'productionDate', width: '9%', type: FormTypes.normal, disabled: true },
-          { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
-          { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
-          { title: '仓库名', key: 'depotId', width: '9%', type: FormTypes.select, disabled: true },
-          { title: '仓库货架', key: 'position', width: '6%', type: FormTypes.normal },
-          { title: '包装规格', key: 'unitName', width: '7%', type: FormTypes.normal },
+          // { title: '生产日期', key: 'productionDate', width: '9%', type: FormTypes.normal, disabled: true },
+          // { title: '保质期', key: 'expiryNum', width: '6%', type: FormTypes.normal },
+          // { title: '商品条码', key: 'barCode', width: '9%', type: FormTypes.normal },
+          { title: '仓库名', key: 'depotId', width: '120px', type: FormTypes.select },
+          { title: '仓库货架', key: 'position', width: '120px', type: FormTypes.input },
+          { title: '包装规格', key: 'unitName', width: '120px', type: FormTypes.normal },
 
-          { title: '型号', key: 'model', width: '9%', type: FormTypes.normal },
-          { title: '颜色', key: 'color', width: '9%', type: FormTypes.normal },
-          { title: '品牌', key: 'brand', width: '9%', type: FormTypes.normal },
-          { title: '制造商', key: 'mfrs', width: '6%', type: FormTypes.normal },
-          { title: '扩展信息', key: 'materialOther', width: '5%', type: FormTypes.normal },
-          { title: '库存', key: 'stock', width: '5%', type: FormTypes.normal },
+          { title: '型号', key: 'model', width: '120px', type: FormTypes.normal },
+          { title: '颜色', key: 'color', width: '120px', type: FormTypes.normal },
+          { title: '品牌', key: 'brand', width: '120px', type: FormTypes.normal },
+          { title: '制造商', key: 'mfrs', width: '120px', type: FormTypes.normal },
+          { title: '扩展信息', key: 'materialOther', width: '120px', type: FormTypes.normal },
+          { title: '库存', key: 'stock', width: '120px', type: FormTypes.normal },
           {
             title: '单位',
             key: 'unit',
-            width: '6%',
-            type: FormTypes.slot,
-            options: [],
-            allowClear: false,
-            slotName: 'unit',
+            width: '120px',
+            type: FormTypes.normal,
+            // options: [],
+            // allowClear: false,
+            // slotName: 'unit',
           },
-          { title: '单位id', key: 'unitId', width: '4%', type: FormTypes.hidden },
-          { title: '单位列表', key: 'unitList', width: '5%', type: FormTypes.hidden },
-          { title: '序列号', key: 'snList', width: '12%', type: FormTypes.popupJsh, kind: 'sn', multi: true },
-          { title: '有效期', key: 'expirationDate', width: '7%', type: FormTypes.input, readonly: true },
-          { title: '多属性', key: 'sku', width: '9%', type: FormTypes.normal },
-          { title: '原数量', key: 'preNumber', width: '4%', type: FormTypes.normal },
-          { title: '已出库', key: 'finishNumber', width: '4%', type: FormTypes.normal },
+          { title: '单位id', key: 'unitId', width: '120px', type: FormTypes.hidden },
+          { title: '单位列表', key: 'unitList', width: '120px', type: FormTypes.hidden },
+          { title: '序列号', key: 'snList', width: '120px', type: FormTypes.popupJsh, kind: 'sn', multi: true },
+          // { title: '有效期', key: 'expirationDate', width: '7%', type: FormTypes.input, readonly: true },
+          { title: '多属性', key: 'sku', width: '120px', type: FormTypes.normal },
+          { title: '原数量', key: 'preNumber', width: '120px', type: FormTypes.normal },
+          { title: '已出库', key: 'finishNumber', width: '120px', type: FormTypes.normal },
           {
             title: '出库数量',
             key: 'operNumber',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             statistics: true,
             validateRules: [{ required: true, message: '${title}不能为空' }],
           },
-          { title: '单价', key: 'unitPrice', width: '4%', type: FormTypes.inputNumber },
-          { title: '金额', key: 'allPrice', width: '5%', type: FormTypes.inputNumber, statistics: true },
-          { title: '税率', key: 'taxRate', width: '4%', type: FormTypes.inputNumber, placeholder: '%' },
+          { title: '单价', key: 'unitPrice', width: '120px', type: FormTypes.inputNumber },
+          { title: '金额', key: 'allPrice', width: '120px', type: FormTypes.inputNumber, statistics: true },
+          { title: '税率', key: 'taxRate', width: '120px', type: FormTypes.inputNumber, placeholder: '%' },
           {
             title: '税额',
             key: 'taxMoney',
-            width: '5%',
+            width: '120px',
             type: FormTypes.inputNumber,
             readonly: true,
             statistics: true,
           },
-          { title: '价税合计', key: 'taxLastMoney', width: '7%', type: FormTypes.inputNumber, statistics: true },
+          { title: '价税合计', key: 'taxLastMoney', width: '120px', type: FormTypes.inputNumber, statistics: true },
 
           {
             title: '实际出库数量',
             key: 'actualQuantityInStorage',
-            width: '9%',
+            width: '120px',
             type: FormTypes.inputNumber,
             validateRules: [{ required: true, message: '实际入库数量不能为空' }],
           },
-          { title: '出库差异', key: 'warehousingVariance', width: '9%', type: FormTypes.input },
-          { title: '出库差异原因', key: 'reasonOfDifference', width: '9%', type: FormTypes.input },
+          { title: '出库差异', key: 'warehousingVariance', width: '120px', type: FormTypes.input },
+          { title: '出库差异原因', key: 'reasonOfDifference', width: '120px', type: FormTypes.input },
           {
             title: '出库人',
             key: 'warehousingUser',
-            width: '9%',
+            width: '120px',
             type: FormTypes.slot,
             slotName: 'warehousingUser',
             validateRules: [{ required: true, message: '出库人不能为空' }],
           },
-          { title: '出库时间', key: 'warehousingTime', width: '9%', type: FormTypes.date },
+          { title: '出库时间', key: 'warehousingTime', width: '200px', type: FormTypes.date },
 
-          { title: '备注', key: 'remark', width: '6%', type: FormTypes.input },
-          { title: '关联id', key: 'linkId', width: '5%', type: FormTypes.hidden },
+          { title: '备注', key: 'remark', width: '200px', type: FormTypes.input },
+          { title: '关联id', key: 'linkId', width: '120px', type: FormTypes.hidden },
         ],
       },
       confirmLoading: false,
@@ -623,10 +623,10 @@ export default {
           handleIntroJs(this.prefixNo, 1)
         })
       } else {
-        if (this.model.linkNumber) {
-          this.rowCanEdit = false
-          this.materialTable.columns[1].type = FormTypes.normal
-        }
+        // if (this.model.linkNumber) {
+        //   this.rowCanEdit = false
+        //   this.materialTable.columns[1].type = FormTypes.normal
+        // }
         this.model.operTime = this.model.operTimeStr
         if (this.model.deposit) {
           this.depositStatus = true

+ 2 - 2
jshERP-web/src/views/material/MaterialList.vue

@@ -151,9 +151,9 @@
           <a-button v-if="btnEnableList.indexOf(1) > -1" @click="batchSetMaterialCurrentStock()" icon="stock"
             >修正库存</a-button
           >
-          <a-button v-if="btnEnableList.indexOf(1) > -1" @click="batchSetMaterialCurrentUnitPrice()" icon="fund"
+          <!-- <a-button v-if="btnEnableList.indexOf(1) > -1" @click="batchSetMaterialCurrentUnitPrice()" icon="fund"
             >修正成本</a-button
-          >
+          > -->
           <a-popover trigger="click" placement="right">
             <template slot="content">
               <a-checkbox-group @change="onColChange" v-model="settingDataIndex" :defaultValue="settingDataIndex">

+ 1 - 1
jshERP-web/src/views/material/modules/BatchSetStockModal.vue

@@ -63,7 +63,7 @@ export default {
   methods: {
     add(type) {
       this.batchType = type
-      if (type === 'initStock') {
+      if (type === 'currentStock') {
         this.title = '期初库存-批量设置'
       } else if (type === 'lowSafeStock') {
         this.title = '最低安全库存-批量设置'

文件差異過大導致無法顯示
+ 194 - 590
jshERP-web/src/views/material/modules/MaterialModal.vue


+ 1 - 2
jshERP-web/src/views/stock/CheckList.vue

@@ -47,8 +47,7 @@
           <span slot="action" slot-scope="text, record">
             <a @click="addTask('detail', record)">查看</a>
             <a-divider type="vertical" />
-            <a :disabled="record.taskStatus !== 1" @click="addTask('edit', record)">编辑</a>
-            <a-divider type="vertical" />
+            <a :disabled="record.taskStatus > 3" @click="addTask('edit', record)">编辑</a>
             <!-- <a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
               <a :disabled="record.taskStatus !== 1 || record.taskStatus !== 4">删除</a>
             </a-popconfirm> -->

+ 3 - 3
jshERP-web/src/views/stock/TaskList.vue

@@ -96,10 +96,10 @@ export default {
       // 权限按钮集合
       btnEnableList: [1, 1, 1],
       queryParam: {
-        taskStatus: '',
+        taskStatus: undefined,
         number: '',
-        depotId: '',
-        createBy: '',
+        depotId: undefined,
+        createBy: undefined,
       },
       // stockTable: {
       //   loading: false,

+ 1 - 1
jshERP-web/src/views/stock/components/FilterForm.vue

@@ -5,7 +5,7 @@
       <a-row :gutter="24">
         <a-col :md="4" :sm="24">
           <a-form-item label="盘点状态" :labelCol="labelCol" :wrapperCol="wrapperCol">
-            <a-select placeholder="请选择供应商" showSearch :options="taskStatusList" v-model="queryParam.taskStatus">
+            <a-select placeholder="请选择盘点状态" showSearch :options="taskStatusList" v-model="queryParam.taskStatus">
             </a-select>
           </a-form-item>
         </a-col>

+ 58 - 23
jshERP-web/src/views/stock/components/checkModal.vue

@@ -105,26 +105,41 @@
       :isStock="true"
     ></j-select-material-modal>
     <a-modal @cancel="editVisible = false" @ok="onSubmitGoods" :visible="editVisible" title="编辑" width="50%">
-      <a-form :form="editForm">
-        <a-form-item label="盘点任务名称" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }">
+      <a-form-model :model="editForm" :rules="editFormRules" ref="editFormModel">
+        <a-form-model-item label="盘点任务名称" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }" prop="name">
           <a-input disabled v-model="editForm.name" placeholder="请输入"></a-input>
-        </a-form-item>
-        <a-form-item label="批次号" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }">
+        </a-form-model-item>
+        <a-form-model-item label="批次号" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }" prop="batchNumber">
           <a-input disabled v-model="editForm.batchNumber" placeholder="请输入"></a-input>
-        </a-form-item>
-        <a-form-item label="实际库存" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }">
-          <a-input v-model="editForm.newInventory" placeholder="请输入"></a-input>
-        </a-form-item>
-        <a-form-item label="实际仓位货架" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }">
+        </a-form-model-item>
+        <a-form-model-item label="实际库存" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }" prop="newInventory">
+          <a-input-number
+            placeholder="请输入"
+            v-model="editForm.newInventory"
+            @change="handleChangeNewInventory"
+            :min="0"
+            style="width: 100%"
+          />
+        </a-form-model-item>
+        <a-form-model-item label="实际仓位货架" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }" prop="newPosition">
           <a-input v-model="editForm.newPosition" placeholder="请输入"></a-input>
-        </a-form-item>
-        <a-form-item label="差异数量" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }">
-          <a-input v-model="editForm.differenceCount" placeholder="请输入"></a-input>
-        </a-form-item>
-        <a-form-item label="差异原因" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }">
+        </a-form-model-item>
+        <a-form-model-item :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }" prop="differenceCount">
+          <template slot="label">
+            差异数量
+            <span>
+              <a-tooltip>
+                <template slot="title"> 盘盈是正数,盘亏是负数 </template>
+                <a-icon type="question-circle" />
+              </a-tooltip>
+            </span>
+          </template>
+          <span :class="editForm.differenceCount !== 0 ? 'red-num' : ''">{{ editForm.differenceCount }}</span>
+        </a-form-model-item>
+        <a-form-model-item label="差异原因" :labelCol="{ span: 4 }" :wrapperCol="{ span: 14 }" prop="differenceReason">
           <a-input v-model="editForm.differenceReason" placeholder="请输入"></a-input>
-        </a-form-item>
-      </a-form>
+        </a-form-model-item>
+      </a-form-model>
     </a-modal>
   </div>
 </template>
@@ -221,6 +236,12 @@ export default {
       },
       editForm: {},
       editVisible: false,
+      editFormRules: {
+        newInventory: [
+          { required: true, message: '请输入实际库存' },
+          { pattern: /^[0-9]*$/, message: '只能输入数字' },
+        ],
+      },
     }
   },
   watch: {
@@ -249,10 +270,8 @@ export default {
   },
   computed: {
     isShowBtn() {
-      console.log('==================', this.form.taskStatus)
-
       if (this.openType === 'detail') return false
-      if (this.form.taskStatus !== 1) return false
+      if (this.form.taskStatus > 3) return false
 
       return true
     },
@@ -261,11 +280,18 @@ export default {
     handleEdit(data) {
       this.editForm = { ...data }
       this.editVisible = true
+      this.handleChangeNewInventory(data.newInventory)
     },
     onSubmitGoods() {
-      postAction(this.url.edit, this.editForm).then((res) => {
-        this.$message.success('操作成功')
-        this.editVisible = false
+      this.$refs.editFormModel.validate((valid) => {
+        if (valid) {
+          postAction(this.url.edit, this.editForm).then((res) => {
+            this.$message.success('操作成功')
+            this.editVisible = false
+          })
+        } else {
+          return false
+        }
       })
     },
     loadCategoryTreeData() {
@@ -425,8 +451,17 @@ export default {
         this.findAllSelect()
       }
     },
+
+    handleChangeNewInventory(val) {
+      const inventory = this.editForm.inventory ? Number(this.editForm.inventory) : 0
+      this.editForm.differenceCount = val - inventory
+    },
   },
 }
 </script>
 
-<style></style>
+<style>
+.red-num {
+  color: #f5222d;
+}
+</style>

+ 6 - 2
jshERP-web/src/views/stock/components/stockModal.vue

@@ -167,8 +167,12 @@ export default {
           }
           const url = this.openType === 'add' ? this.url.add : this.url.update
           postAction(url, params).then((res) => {
-            this.$message.success('操作成功')
-            this.handleCancel()
+            if (res.code === 200) {
+              this.$message.success('操作成功')
+              this.handleCancel()
+            } else {
+              this.$message.error(res.msg)
+            }
           })
         }
       })

+ 87 - 0
jshERP-web/src/views/system/AppVersionList.vue

@@ -0,0 +1,87 @@
+<template>
+  <a-row :gutter="24">
+    <a-col :md="24">
+      <a-card :style="cardStyle" :bordered="false">
+        <!-- 操作按钮区域 -->
+        <div class="table-operator" style="margin-top: 5px">
+          <a-button @click="handleAdd" type="primary" icon="plus">发布新版本</a-button>
+        </div>
+        <!-- table区域-begin -->
+        <div>
+          <a-table
+            ref="table"
+            size="middle"
+            bordered
+            rowKey="id"
+            :columns="columns"
+            :dataSource="dataSource"
+            :pagination="ipagination"
+            :scroll="scroll"
+            :loading="loading"
+            @change="handleTableChange"
+          >
+          </a-table>
+        </div>
+        <!-- table区域-end -->
+        <!-- 表单区域 -->
+        <app-version-modal ref="modalForm" @ok="modalFormOk"></app-version-modal>
+      </a-card>
+    </a-col>
+  </a-row>
+</template>
+<script>
+import AppVersionModal from './modules/AppVersionModal'
+import { JeecgListMixin } from '@/mixins/JeecgListMixin'
+import { postAction } from '@/api/manage'
+
+export default {
+  name: 'AppVersionList',
+  mixins: [JeecgListMixin],
+  components: {
+    AppVersionModal,
+  },
+  data() {
+    return {
+      // 表头
+      columns: [
+        { title: '版本号', dataIndex: 'version', },
+        { title: '发布时间', dataIndex: 'createTime', },
+        { title: '文件路径', dataIndex: 'url',},
+      ],
+      url: {
+        list: '/apkVersion/list',
+      },
+    }
+  },
+  computed: {},
+  methods: {
+    loadData(arg) {
+      if (!this.url.list) {
+        this.$message.error('请设置url.list属性!')
+        return
+      }
+      //加载数据 若传入参数1则加载第一页的内容
+      if (arg === 1) {
+        this.ipagination.current = 1
+      }
+      this.loading = true
+      postAction(this.url.list, {}).then((res) => {
+        if (res.code === 200) {
+          this.dataSource = res.data.rows
+          this.ipagination.total = Number(res.data.total)
+          this.tableAddTotalRow(this.columns, this.dataSource)
+        } else if (res.code === 510) {
+          this.$message.warning(res.data)
+        } else {
+          this.$message.warning(res.data.message)
+        }
+        this.loading = false
+        this.onClearSelected()
+      })
+    },
+  },
+}
+</script>
+<style scoped>
+@import '~@assets/less/common.less';
+</style>

+ 293 - 0
jshERP-web/src/views/system/modules/AppVersionModal.vue

@@ -0,0 +1,293 @@
+<template>
+  <div ref="container">
+    <a-modal
+      title="发布新版本"
+      :visible="visible"
+      :confirmLoading="confirmLoading"
+      :getContainer="() => $refs.container"
+      :maskStyle="{ top: '93px', left: '154px' }"
+      :wrapClassName="wrapClassNameInfo()"
+      :mask="isDesktop()"
+      :maskClosable="false"
+      @cancel="handleCancel"
+      :footer="null"
+      width="500px"
+      style="top: 5%"
+    >
+      <a-spin :spinning="confirmLoading">
+        <a-form :form="form" class="form-content" id="appVersionModal">
+          <a-form-item label="版本号" :labelCol="labelCol" :wrapperCol="wrapperCol">
+            <a-input placeholder="请输入" allowClear v-decorator="['version', validatorRules.version]" />
+          </a-form-item>
+          
+          <a-form-item label="上传文件" :labelCol="labelCol" :wrapperCol="wrapperCol">
+            <div class="upload-container">
+              <a-upload
+                name="file"
+                :data="uploadOpts.data"
+                :showUploadList="true"
+                :multiple="false"
+                :headers="uploadOpts.headers"
+                :action="uploadOpts.action"
+                :method="uploadOpts.method"
+                :accept="uploadOpts.accept"
+                :fileList="fileList"
+                @change="handleChange"
+                :beforeUpload="beforeUpload"
+                @reject="handleReject"
+              >
+                <div class="upload-content">
+                  <div class="upload-icon">
+                    <a-icon type="folder-open" style="color: #4e73f8; font-size: 32px;" />
+                  </div>
+                  <a-button type="primary" class="upload-button">上传文件</a-button>
+                </div>
+              </a-upload>
+            </div>
+          </a-form-item>
+          
+          <div class="form-actions">
+            <a-button @click="handleCancel" class="cancel-button">取消</a-button>
+            <a-button type="primary" @click="handleOk" :loading="confirmLoading" class="confirm-button">确定发布新版本</a-button>
+          </div>
+        </a-form>
+      </a-spin>
+    </a-modal>
+  </div>
+</template>
+<script>
+import Vue from 'vue'
+import { ACCESS_TOKEN } from '@/store/mutation-types'
+import pick from 'lodash.pick'
+import { autoJumpNextInput } from '@/utils/util'
+import { mixinDevice } from '@/utils/mixin'
+import { postAction } from '@/api/manage'
+
+export default {
+  name: 'AppVersionModal',
+  mixins: [mixinDevice],
+  data() {
+    return {
+      visible: false,
+      confirmLoading: false,
+      labelCol: { span: 4 },
+      wrapperCol: { span: 20 },
+      fileList: [],
+      validatorRules: {
+        version: {
+          rules: [
+            { required: true, message: '请输入版本号!' },
+            { pattern: /^\d+\.\d+\.\d+$/, message: '版本号格式不正确!' }
+          ]
+        },
+        url: {
+          rules: [
+            { required: true, message: '请上传.apk文件!' }
+          ]
+        }
+      },
+      form: this.$form.createForm(this),
+      model: {},
+      uploadOpts:{
+        headers: {
+          'X-Access-Token': Vue.ls.get(ACCESS_TOKEN)
+        },
+        method: 'POST',
+        action: window._CONFIG['domianURL'] + '/apkVersion/upload',
+        accept: '.apk',
+        data:{
+          biz: 'bill' 
+        }
+      },
+    }
+  },
+  methods: {
+    add() {
+      this.edit({})
+    },
+    edit(record) {
+      this.form.resetFields()
+      this.model = Object.assign({}, record)
+      this.fileList = []
+      this.visible = true
+      this.$nextTick(() => {
+        this.form.setFieldsValue(
+          pick(
+            this.model,
+            'url',
+            'version'
+          )
+        )
+        autoJumpNextInput('appVersionModal')
+      })
+    },
+    beforeUpload(file) {
+      // 检查文件类型
+      const isAPK = file.type === 'application/vnd.android.package-archive' || file.name.endsWith('.apk')
+      if (!isAPK) {
+        this.$message.error('只能上传APK文件!')
+        return false
+      }
+      
+      // 阻止自动上传
+      return true
+    },
+    handleChange(info) {
+      this.fileList = [info.file]
+      console.log('文件列表:', this.fileList)
+      if (info.file.status === 'uploading') {
+        console.log(info.file, info.fileList)
+        this.confirmLoading = true
+      }else if(info.file.status === 'removed'){
+        this.fileList = []
+        this.model.url = ''
+      }else if (info.file.status === 'done') {
+        this.confirmLoading = false
+        console.log('model=====', this.model)
+        if (info.file.response) {
+          if (info.file.response.code === 200) {
+            info.file.name = info.file.response.data
+            this.model.url = info.file.response.data
+          } else {
+            this.$message.warning(info.file.response.data, 8)
+          }
+        } else {
+          this.$message.error(`${info.file.name} ${info.file.response.data}.`)
+        }
+      } else if (info.file.status === 'error') {
+        this.confirmLoading = false
+        this.$message.error(`文件上传失败: ${info.file.msg} `)
+      }
+    },
+    handleReject(file) {
+      console.log('文件类型不正确:', file)
+      this.$message.error('文件类型不正确,请上传.apk文件!')
+    },
+    handleOk() {
+      this.form.validateFields((err, values) => {
+        if (err) return
+        console.log('values======',values)
+        if (this.fileList.length === 0) {
+          this.$message.error('请上传.apk类型文件!')
+          return
+        }
+        
+        const formData = {
+          version: values.version,
+          url: this.fileList[0].name // 实际应用中这里应该是上传后的URL
+        }
+        
+        this.confirmLoading = true
+        
+        postAction('/apkVersion/add', formData).then(res => {
+          if (res.code === 200) {
+            this.$message.success(res.msg)
+            this.visible = false
+            this.$emit('ok', formData)
+          } else {
+            this.$message.error(res.data||'操作失败')
+          }
+        }).catch(err => {
+          console.error(err)
+        }).finally(() => {
+          this.confirmLoading = false
+        })
+      })
+    },
+    handleCancel() {
+      this.visible = false
+    }
+  }
+}
+</script>
+<style lang="less" scoped>
+.form-content {
+  padding: 0 10px;
+}
+
+.upload-container {
+  border: 1px dashed #d9d9d9;
+  border-radius: 4px;
+  padding: 24px;
+  background-color: #fafafa;
+}
+
+.upload-content {
+  display: flex;
+  flex-direction: column;
+  align-items: center;
+  justify-content: center;
+  padding: 10px 0;
+}
+
+.upload-icon {
+  margin-bottom: 16px;
+}
+
+.upload-button {
+  height: 32px;
+  font-size: 14px;
+  border-radius: 4px;
+  background-color: #4e73f8;
+  border-color: #4e73f8;
+}
+
+.reupload-button {
+  background-color: #4e73f8;
+  border-color: #4e73f8;
+}
+
+.form-actions {
+  display: flex;
+  justify-content: flex-end;
+  margin-top: 24px;
+  
+  .cancel-button {
+    margin-right: 12px;
+    min-width: 80px;
+    height: 32px;
+  }
+  
+  .confirm-button {
+    background-color: #4e73f8;
+    border-color: #4e73f8;
+    min-width: 120px;
+    height: 32px;
+  }
+}
+
+/deep/ .ant-upload.ant-upload-select {
+  display: block;
+}
+
+/deep/ .ant-upload-list-item {
+  margin-top: 8px;
+}
+
+/deep/ .ant-form-item-label {
+  text-align: left;
+  line-height: 32px;
+}
+
+/deep/ .ant-form-item {
+  margin-bottom: 24px;
+}
+
+/deep/ .ant-modal-close-x {
+  width: 46px;
+  height: 46px;
+  line-height: 46px;
+}
+
+/deep/ .ant-modal-body {
+  padding: 16px 24px 24px;
+}
+
+/deep/ .ant-form-item-control {
+  line-height: 32px;
+}
+
+/deep/ .ant-input {
+  height: 32px;
+}
+</style>

+ 22 - 5
jshERP-web/src/views/system/modules/VendorModal.vue

@@ -14,7 +14,7 @@
       @cancel="handleCancel"
       cancelText="取消"
       okText="保存"
-      style="top: 10%; height: 80%"
+      style="top: 10%"
     >
       <template slot="footer">
         <a-button key="back" v-if="isReadOnly" @click="handleCancel"> 取消 </a-button>
@@ -87,7 +87,11 @@
             </a-col>
             <a-col :span="24 / 2">
               <a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="排序">
-                <a-input placeholder="请输入排序" v-decorator.trim="['sort']" />
+                <a-input
+                  placeholder="请输入排序"
+                  oninput="value=value.replace(/[^\d]/g, '')"
+                  v-decorator.trim="['sort']"
+                />
               </a-form-item>
             </a-col>
             <a-col :span="24 / 2">
@@ -106,7 +110,11 @@
             </a-col>
             <a-col :span="24 / 2">
               <a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="账单周期">
-                <a-input placeholder="请输入账单周期" v-decorator.trim="['billingCycleDays']" />
+                <a-input
+                  placeholder="请输入账单周期"
+                  oninput="value=value.replace(/[^\d]/g, '')"
+                  v-decorator.trim="['billingCycleDays']"
+                />
               </a-form-item>
             </a-col>
             <a-col :span="24 / 2">
@@ -116,7 +124,11 @@
             </a-col>
             <a-col :span="24 / 2">
               <a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="到货天数">
-                <a-input placeholder="请输入到货天数" v-decorator.trim="['deliveryDays']" />
+                <a-input
+                  placeholder="请输入到货天数"
+                  oninput="value=value.replace(/[^\d]/g, '')"
+                  v-decorator.trim="['deliveryDays']"
+                />
               </a-form-item>
             </a-col>
             <a-col :span="24 / 2">
@@ -130,7 +142,12 @@
             </a-col>
             <a-col :span="24 / 2">
               <a-form-item :labelCol="labelCol" :wrapperCol="wrapperCol" label="税率(%)">
-                <a-input-number style="width: 100%" placeholder="请输入税率" v-decorator.trim="['taxRate']" />
+                <a-input-number
+                  style="width: 100%"
+                  oninput="value=value.replace(/[^\d.]/g, '')"
+                  placeholder="请输入税率"
+                  v-decorator.trim="['taxRate']"
+                />
               </a-form-item>
             </a-col>
             <a-col :span="24 / 2">

+ 2 - 1
jshERP-web/vue.config.js

@@ -54,7 +54,8 @@ module.exports = {
     open: true,
     proxy: {
       [process.env.VUE_APP_BASE_API]: {
-        target: 'http://localhost:8080', // 请求本地 需要jshERP-boot后台项目
+        // target: 'https://test-erp.xianglitech.com.cn/stage-api', // 请求本地 需要jshERP-boot后台项目
+        target: 'http://192.168.2.112:8080', // 请求本地 需要jshERP-boot后台项目
         changeOrigin: true,
         pathRewrite: {
           ['^' + process.env.VUE_APP_BASE_API]: '',

部分文件因文件數量過多而無法顯示