haoyahui
2023-11-17 b6a04be0a4cbf5d5a44006a09b83f52a71dfce27
admin-web/src/views/stock/procure/receiptDetails/index.vue
@@ -33,7 +33,7 @@
import SettingIplatform from '@/utils/settingIplatform';
import detail from '../purchaseOrder/detail';
import * as finsystenant from '@/api/baseSetting/finsystenant';
import {goodsModel} from '@/api/stock/procure/purchaseOrder';
import { goodsModel } from '@/api/stock/procure/purchaseOrder';
import myImport from '@/views/components/myImport';
import { getBaseUrl } from '@/utils/base';
@@ -64,7 +64,7 @@
          label: '规格型号',
          placeholder: '请选择',
          defaultValue: '',
          options:[]
          options: [],
        },
        {
          type: 'cascader',
@@ -100,7 +100,7 @@
      // 搜索条件
      filterFrom: {
        tenantId: null,
        agencyId:[],
        agencyId: [],
        status: 1,
      },
      // 导入
@@ -150,9 +150,23 @@
          { title: '单号', field: 'businessFormCode', align: 'center' },
          { title: '物品名称', field: 'goodsTemplateName', align: 'center' },
          { title: '规格型号', field: 'baseGoodsModelsName', align: 'center' },
          { title: '单价', field: 'price', align: 'center' },
          {
            title: '单价',
            field: 'price',
            align: 'center',
            formatter: (row) => {
              return { value: row.price / 100 };
            },
          },
          { title: '入库数量', field: 'counts', align: 'center' },
          { title: '金额', field: 'amount', align: 'center' },
          {
            title: '金额',
            field: 'amount',
            align: 'center',
            formatter: (row) => {
              return { value: row.price / 100 };
            },
          },
          { title: '所属机构', field: 'agencyName', align: 'center' },
          { title: '创建人', field: 'buyerName', align: 'center' },
          {
@@ -193,17 +207,16 @@
  },
  created() {
    // 搜索框规格型号
    goodsModel().then(res=>{
      this.items.forEach(v=>{
        if(v.label=='规格型号'){
          v.options = res.map(item=>{
            item.label = item.modelName,
            item.value = item.id
            return item
          })
    goodsModel().then((res) => {
      this.items.forEach((v) => {
        if (v.label == '规格型号') {
          v.options = res.map((item) => {
            (item.label = item.modelName), (item.value = item.id);
            return item;
          });
        }
      })
    })
      });
    });
  },
  methods: {
    //导入
@@ -247,9 +260,9 @@
        .catch(() => {});
    },
    showDetail(row) {
      this.detailSetting.id=row.businessId
      this.detailSetting.title='详情'
      this.detailSetting.show=true
      this.detailSetting.id = row.businessId;
      this.detailSetting.title = '详情';
      this.detailSetting.show = true;
    },
    // 查询table列表
    search(pageNum) {
@@ -267,7 +280,7 @@
      if (this.filterFrom.incomeTimeEnd) {
        this.filterFrom.incomeTimeEnd = this.filterFrom.incomeTimeEnd.replace(/\-/g, '');
      }
      if (params.agencyId&&params.agencyId.length) {
      if (params.agencyId && params.agencyId.length) {
        this.filterFrom.agencyId = params.agencyId[params.agencyId.length - 1];
      }
      this.search(1);