石广澎
2023-11-27 aef2a705884dbb25b24d23fc886c563327f4753e
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('保存成功!');