石广澎
2023-11-27 aef2a705884dbb25b24d23fc886c563327f4753e
feat:

1、采购、调拨、库存盘点、报废管理 列表页面优化
2、物品报废详情对接 明细对接
11个文件已修改
178 ■■■■ 已修改文件
admin-web/src/components/mySearch/SearchItem.vue 12 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/components/upload/index.vue 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/views/stock/inventorycount/exceptionDetails/index.vue 51 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/views/stock/inventorycount/inventorytask/detail.vue 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/views/stock/inventorycount/inventorytask/index.vue 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/views/stock/procure/receiptDetails/index.vue 12 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/views/stock/scrap/itemScrapping/detail.vue 30 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/views/stock/scrap/itemScrapping/edit.vue 11 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/views/stock/scrap/itemScrapping/index.vue 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/views/stock/scrap/scrapDetails/index.vue 15 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/views/stock/transfer/transferdetails/index.vue 17 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
admin-web/src/components/mySearch/SearchItem.vue
@@ -67,6 +67,7 @@
      type="year"
      :clearable="true"
      style="width: 150px"
      :value-format="item.format?item.format:'yyyy'"
      @change="(v) => panelChange(v, 'yyyy')"
    />
    <!--月选择器-->
@@ -76,6 +77,7 @@
      type="month"
      :clearable="true"
      style="width: 150px"
      :value-format="item.format?item.format:'yyyyMM'"
      @change="(v) => panelChange(v, 'yyyy-MM')"
    />
    <!--日选择器-->
@@ -85,6 +87,7 @@
      type="date"
      :clearable="true"
      style="width: 150px"
      :value-format="item.format?item.format:'yyyyMMdd'"
      @change="(v) => panelChange(v, 'yyyy-MM-dd')"
    />
    <!--日期带时间选择器-->
@@ -243,14 +246,7 @@
      }
    },
    panelChange(v, type) {
      var info = null
      if (v && this.item.type !== 'date-time-picker') {
        info = formatDates(v, type)
      } else {
        info = v
      }
      this.val = info
      this.$emit('change', info)
      this.$emit('change', v)
    },
    filterOption(input, option) {
      return option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0;
admin-web/src/components/upload/index.vue
@@ -85,7 +85,7 @@
        title: '附件上传',
        max: 100, // 最大大小,单位M
        num: 10, // 支持上传图片个数
        accept: '.jpg,.jpeg,.png,.bmp,.pdf,.doc,.docx,.xls,.xlsx,.apk,.zip', // 限制格式
        accept: '.jpg,.jpeg,.png,.pdf,.doc,.docx,.xls,.xlsx', // 限制格式
        tip: '', // 提示 默认:`只能上传${this.defaultSettings.num}个${this.defaultSettings.accept}文件,且不超过${this.defaultSettings.max}kb`
        uploadUrl: '', // 上传路径
        multiple: true, // 是否支持批量上传
admin-web/src/views/stock/inventorycount/exceptionDetails/index.vue
@@ -10,7 +10,7 @@
          <el-row style="margin-top: 15px">
            <el-col>
              <!--列表-->
              <my-table-v2 ref="myTable" :filter="filterFrom" :table="table" />
              <my-table-v2 ref="myTable" :filter="filterFrom" :table="table"/>
            </el-col>
          </el-row>
        </el-card>
@@ -23,16 +23,12 @@
import MyTableV2 from '@/components/myTable/myTableV2';
import MyButton from '@/components/myButton/myButton';
import SettingIplatform from '@/utils/settingIplatform';
import * as finsystenant from '@/api/baseSetting/finsystenant';
import { getBaseUrl } from '@/utils/base';
import { mapGetters } from 'vuex';
import { selectTenantWarehouse, goodsModel } from '@/api/baseSetting/finsystenant';
import { getDicts } from '@/api/system/dict/data';
import {mapGetters} from 'vuex';
import * as DateFormatter from '@/utils/DateFormatter';
export default {
  name: 'index',
  components: { MyButton, MyTableV2 },
  components: {MyButton, MyTableV2},
  data() {
    return {
      // 搜索框
@@ -42,7 +38,7 @@
          dataIndex: 'agencyId',
          label: '机构',
          placeholder: '请选择',
          optionsConfig: { url: '/pc/fin/sys/tenant/select/tree_fin_tenant', props: null },
          optionsConfig: {url: '/pc/fin/sys/tenant/select/tree_fin_tenant', props: null},
          defaultValue: '',
          options: [],
        },
@@ -66,7 +62,7 @@
          placeholder: '请输入',
          defaultValue: '',
          options: [],
          cascader: [{ key: 'baseGoodsModelsId', queryKey: 'goodsTemplatesId' }],
          cascader: [{key: 'baseGoodsModelsId', queryKey: 'goodsTemplatesId'}],
          optionsConfig: {
            label: 'goodsName',
            value: 'id',
@@ -158,8 +154,7 @@
      // 树数据
      treeDataList: [],
      // 搜索条件
      filterFrom: {
      },
      filterFrom: {},
      // 表格数据
      table: {
        showIndex: true, // 是否显示序号
@@ -180,30 +175,35 @@
        },
        // 列信息
        columns: [
          { title: '仓库', field: 'warehouseName', align: 'left' },
          { title: '物品名称', field: 'goodsTemplateName', align: 'center' },
          { title: '规格型号', field: 'baseGoodsModelsName', align: 'center' },
          { title: '类型', field: 'inventoryResultType', align: 'center' },
          { title: '库存数量', field: 'initCounts', align: 'left' },
          { title: '盘点数量', field: 'inventoryCounts', align: 'left' },
          { title: '异常数量', field: 'errorCounts', align: 'left' },
          {title: '仓库', field: 'warehouseName', align: 'left', width: 140},
          {title: '物品名称', field: 'goodsTemplateName', align: 'left', minWidth: 130},
          {title: '规格型号', field: 'baseGoodsModelsName', align: 'left', width: 120},
          {title: '类型', field: 'inventoryResultType', align: 'center'},
          {title: '库存数量', field: 'initCounts', align: 'left'},
          {title: '盘点数量', field: 'inventoryCounts', align: 'left'},
          {title: '异常数量', field: 'errorCounts', align: 'left'},
          {
            title: '出入库类型',
            field: 'inventoryType',
            align: 'left',
            align: 'center',
            width: 100,
            formatter: (row) => {
              return { value: row.inventoryType, type: row.inventoryType && row.inventoryType.includes('盘盈') ? 'success' : 'danger' };
              return {
                value: row.inventoryType,
                type: row.inventoryType && row.inventoryType.includes('盘盈') ? 'success' : 'danger'
              };
            },
          },
          { title: '出入库单号', field: 'warehouseFormCode', align: 'left' },
          { title: '机构', field: 'agencyName', align: 'left' },
          { title: '操作人', field: 'operatorName', align: 'left' },
          {title: '出入库单号', field: 'warehouseFormCode', align: 'center', width: 130},
          {title: '机构', field: 'agencyName', align: 'left', width: 130},
          {title: '操作人', field: 'operatorName', align: 'center', width: 90},
          {
            title: '操作时间',
            field: 'operatorTime',
            align: 'center',
            width: 160,
            formatter: (row) => {
              return { value: row.operatorTime ? DateFormatter.LongToDateTime(row.operatorTime) : '-' };
              return {value: row.operatorTime ? DateFormatter.LongToDateTime(row.operatorTime) : '-'};
            },
          },
        ],
@@ -230,7 +230,8 @@
  computed: {
    ...mapGetters(['userInfo']),
  },
  created() {},
  created() {
  },
  methods: {
    showAudit(row) {
      this.editSetting.id = row.id;
admin-web/src/views/stock/inventorycount/inventorytask/detail.vue
@@ -10,7 +10,11 @@
      <el-table-column prop="baseGoodsModelsName" label="型号" align="center"> </el-table-column>
      <el-table-column prop="inventoryCount" label="应盘数量" align="center"></el-table-column>
      <el-table-column prop="realNum" label="实盘数量" align="center"></el-table-column>
      <el-table-column prop="states" label="状态" align="center"></el-table-column>
      <el-table-column prop="states" label="状态" align="center">
        <template slot-scope="{row}">
          {{row.inventoryResultType}}
        </template>
      </el-table-column>
    </el-table>
  </win-md>
</template>
admin-web/src/views/stock/inventorycount/inventorytask/index.vue
@@ -162,11 +162,11 @@
        },
        // 列信息
        columns: [
          { title: '盘点单号', field: 'businessFormCode', align: 'left' },
          { title: '任务名称', field: 'businessFormName', align: 'left' },
          { title: '盘点仓库', field: 'warehouseName', align: 'left' },
          { title: '盘点人', field: 'operatorName', align: 'left' },
          { title: '监盘人', field: 'operatorName2', align: 'left' },
          { title: '盘点单号', field: 'businessFormCode', align: 'center', width: 130 },
          { title: '任务名称', field: 'businessFormName', align: 'left', minWidth: 140 },
          { title: '盘点仓库', field: 'warehouseName', align: 'left', minWidth: 130  },
          { title: '盘点人', field: 'operatorName', align: 'center', width: 120  },
          { title: '监盘人', field: 'operatorName2', align: 'center', width: 120  },
          {
            title: '盘点时间',
            field: 'inventoryDate',
@@ -188,7 +188,8 @@
          {
            title: '状态',
            field: 'states',
            align: 'left',
            align: 'center',
            width: 90,
            type: 'primary',
            formatter: (row) => {
              return {
@@ -263,7 +264,7 @@
              },
            },
            {
              title: '生产盘点表',
              title: '生成盘点表',
              type: 'primary',
              hidden: (row) => {
                if (row.states != 2) {
admin-web/src/views/stock/procure/receiptDetails/index.vue
@@ -159,9 +159,9 @@
        },
        // 列信息
        columns: [
          { title: '单号', field: 'businessFormCode', align: 'center' },
          { title: '物品名称', field: 'goodsTemplateName', align: 'center' },
          { title: '规格型号', field: 'baseGoodsModelsName', align: 'center' },
          { title: '单号', field: 'businessFormCode', align: 'center', width: 130 },
          { title: '物品名称', field: 'goodsTemplateName', align: 'left', width: 140 },
          { title: '规格型号', field: 'baseGoodsModelsName', align: 'left', width: 130 },
          {
            title: '单价',
            field: 'price',
@@ -179,8 +179,8 @@
              return { value: row.price / 100 };
            },
          },
          { title: '所属机构', field: 'agencyName', align: 'center' },
          { title: '创建人', field: 'buyerName', align: 'center' },
          { title: '所属机构', field: 'agencyName', align: 'center', width: 130 },
          { title: '创建人', field: 'buyerName', align: 'center', width: 90 },
          {
            title: '操作时间',
            field: 'procureTime',
@@ -194,7 +194,7 @@
        // 操作信息
        operation: {
          show: true, // 显示操作列
          width: '150', // 列宽
          width: 100, // 列宽
          attr: [
            {
              title: '详情',
admin-web/src/views/stock/scrap/itemScrapping/detail.vue
@@ -36,34 +36,18 @@
      <el-row :gutter="20">
        <el-col :span="8">
          <span>物品分类:</span>
          <span>{{ goodsItem.baseCategoryName }}</span>
          <span>{{ goodsItem.categoryName }}</span>
        </el-col>
        <el-col :span="8">
          <span>物品名称:</span>
          <span>{{ goodsItem.goodsTemplateName }}</span>
          <span>{{ goodsItem.goodsName }}</span>
        </el-col>
      </el-row>
      <el-table :data="goodsItem.models" :stripe="true" style="margin-top: 20px">
        <el-table-column prop="baseGoodsModelsName" label="规格型号" align="center">
          <template slot-scope="scope">
            {{ scope.row.baseGoodsModelsName }}
          </template>
        </el-table-column>
        <el-table-column label="单位" align="center">
          <template slot-scope="scope">
            {{ scope.row.unit }}
          </template>
        </el-table-column>
        <el-table-column prop="counts" label="报废数量" align="center">
          <template slot-scope="scope">
            {{ scope.row.counts }}
          </template>
        </el-table-column>
        <el-table-column prop="scrappedCode" label="报废原因" align="center">
          <template slot-scope="scope">
            {{ getDictName(scope.row.scrappedCode) }}
          </template>
        </el-table-column>
        <el-table-column prop="baseGoodsModelsName" label="规格型号" align="center"></el-table-column>
        <el-table-column label="单位" prop="unit" align="center"></el-table-column>
        <el-table-column prop="counts" label="报废数量" align="center"></el-table-column>
        <el-table-column prop="scrappedName" label="报废原因" align="center"></el-table-column>
      </el-table>
    </div>
    <div id="uploadPreviewImages" style="display: none">
@@ -113,7 +97,7 @@
        states: '',
        createName: '',
        time: '',
        scrappedGoodsInfo: [],
        scrappedGoods: [],
      },
    };
  },
admin-web/src/views/stock/scrap/itemScrapping/edit.vue
@@ -139,9 +139,9 @@
                <el-select v-model="scope.row.scrappedCode" placeholder="请选择">
                  <el-option
                    v-for="item in scrapReasonOptions"
                    :key="item.dict_value"
                    :key="item.dict_code"
                    :label="item.dict_label"
                    :value="item.dict_value"
                    :value="item.dict_code"
                  />
                </el-select>
              </template>
@@ -241,7 +241,6 @@
        warehouseId: [{ required: true, message: '请选择', trigger: 'change' }],
        dealTime: [{ required: true, message: '请选择', trigger: 'change' }],
        buyType: [{ required: true, message: '请选择', trigger: 'change' }],
        uploadFiles: [{ required: true, message: '请上传', trigger: 'change' }],
        baseCategoryIds: [{ required: true, message: '请选择', trigger: 'change' }],
        baseGoodsTemplateId: [{ validator: checkGoodsTemplateId, trigger: ['blur', 'change'] }],
@@ -252,7 +251,6 @@
        title: '上传',
        max: 20, // 最大大小,单位M
        num: 10, // 支持上传图片个数
        accept: '.jpg,.png', // 限制格式
        tip: '', // 提示 默认:`只能上传${this.defaultSettings.num}个${this.defaultSettings.accept}文件,且不超过${this.defaultSettings.max}kb`
        uploadUrl: getUploadUrl(), // 上传路径
        multiple: true, // 是否支持批量上传
@@ -272,7 +270,7 @@
      this.getWarehouseList();
      this.getgoodsTemplate();
      this.getgoodsModel();
      this.getCategoryTree();
      await this.getCategoryTree();
      this.formData.scrappedGoodsInfo.push(JSON.parse(JSON.stringify(this.goodsItem)));
      this.formData.operatorId = this.userInfo.id;
      this.formData.operatorName = this.userInfo.userName;
@@ -291,7 +289,7 @@
    // 获取报废仓库列表
    getWarehouseList() {
      selectTenantWarehouse()
      selectTenantWarehouse({ agencyId: this.userInfo.tenantId })
        .then((res) => {
          this.warehouses = res;
          if (this.warehouses.length && !this.formData.warehouseId) {
@@ -427,7 +425,6 @@
    handleSubmit() {
      this.$refs['ruleForm'].validate((valid) => {
        if (valid) {
          console.log('this.formData', this.formData);
          scrappedAdd(this.formData)
            .then((res) => {
              this.$message.success('保存成功!');
admin-web/src/views/stock/scrap/itemScrapping/index.vue
@@ -21,7 +21,7 @@
                        <div class="card-header-left">
                          <span>报废单号:</span>
                          <span class="value">{{ item.businessFormCode }}</span>
                        </div>
                        <div class="card-header-right">
                          <el-button site="form" type="success" size="mini" @click="handleExport(item)"
@@ -138,13 +138,13 @@
        },
        {
          type: 'date-picker',
          dataIndex: 'incomeTimeStart',
          dataIndex: 'startTime',
          label: '报废时间',
          defaultValue: '',
        },
        {
          type: 'date-picker',
          dataIndex: 'incomeTimeEnd',
          dataIndex: 'endTime',
          label: '至',
          defaultValue: '',
        },
@@ -199,7 +199,6 @@
        this.list = res.datas;
        this.total = res.totalRows;
        this.loading = false;
        console.log(this.list);
      });
    },
admin-web/src/views/stock/scrap/scrapDetails/index.vue
@@ -164,16 +164,17 @@
        },
        // 列信息
        columns: [
          { title: '单号', field: 'businessFormCode', align: 'left' },
          { title: '物品名称', field: 'goodsTemplateName', align: 'center' },
          { title: '规格型号', field: 'baseGoodsModelsName', align: 'center' },
          { title: '报废数量', field: 'lv', align: 'center' },
          { title: '所属机构', field: 'agencyName', align: 'left' },
          { title: '单号', field: 'businessFormCode', align: 'center', width: 130 },
          { title: '物品名称', field: 'goodsTemplateName', align: 'left', minWidth: 130 },
          { title: '规格型号', field: 'baseGoodsModelsName', align: 'left', width: 130  },
          { title: '报废数量', field: 'counts', align: 'center' },
          { title: '所属机构', field: 'agencyName', align: 'left', width: 130 },
          { title: '创建人', field: 'operatorName', align: 'left' },
          {
            title: '操作时间',
            field: 'dealTime',
            align: 'left',
            align: 'center',
            width: 160,
            formatter: (row) => {
              return { value: DateFormatter.LongToDateTime(row.dealTime) };
            },
@@ -182,7 +183,7 @@
        // 操作信息
        operation: {
          show: true, // 显示操作列
          width: '150', // 列宽
          width: 100, // 列宽
          attr: [
            {
              title: '详情',
admin-web/src/views/stock/transfer/transferdetails/index.vue
@@ -160,12 +160,12 @@
        },
        // 列信息
        columns: [
          { title: '单号', field: 'businessFormCode', align: 'center' },
          { title: '物品名称', field: 'goodsName', align: 'center' },
          { title: '规格型号', field: 'baseGoodsModelsName', align: 'center' },
          { title: '数量', field: 'counts', align: 'left' },
          { title: '接受机构', field: 'inAgencyName', align: 'left' },
          { title: '创建人', field: 'operatorName', align: 'left' },
          { title: '单号', field: 'businessFormCode', align: 'center', width: 130 },
          { title: '物品名称', field: 'goodsName', align: 'left', width: 140 },
          { title: '规格型号', field: 'baseGoodsModelsName', align: 'left', width: 130 },
          { title: '数量', field: 'counts', align: 'center' },
          { title: '接受机构', field: 'inAgencyName', align: 'left', width: 130 },
          { title: '创建人', field: 'operatorName', align: 'center', width: 90 },
          {
            title: '申请时间',
            field: 'createTime',
@@ -184,11 +184,12 @@
              return { value: row.inTime ? DateFormatter.LongToDateTime(row.inTime) : '-' };
            },
          },
          { title: '调拨机构', field: 'outAgencyName', align: 'left' },
          { title: '调拨机构', field: 'outAgencyName', align: 'left', width: 130 },
          {
            title: '调拨人',
            field: 'outOperatorName',
            align: 'center',
            width: 90,
            formatter: (row) => {
              return { value: row.outOperatorName || '-' };
            },
@@ -206,7 +207,7 @@
        // 操作信息
        operation: {
          show: true, // 显示操作列
          width: '150', // 列宽
          width: 100, // 列宽
          attr: [
            {
              title: '详情',