snow 2 éve
szülő
commit
3b63311306

A különbségek nem kerülnek megjelenítésre, a fájl túl nagy
+ 0 - 0
dist/static/js/0.js


+ 9 - 4
src/views/sellOut/sellReturn/components/ShowDataTableColumns.js

@@ -3,24 +3,29 @@ const showColumns = [
   {
     prop: 'returnCode',
     label: '退货单编号',
-    span: 7
+    span: 6
+  },
+  {
+    prop: 'orderCode',
+    label: '销售订单编码',
+    span: 6
   },
   {
     prop: 'status',
     label: '退货单状态',
     _slot_: 'status',
-    span: 5
+    span: 4
   },
   {
     prop: 'order_type',
     label: '订单来源',
     _slot_: 'order_type',
-    span: 6
+    span: 4
   },
   {
     prop: 'apply_name',
     label: '创建人',
-    span: 6
+    span: 4
   },
   {
     prop: 'supplierName',

+ 3 - 1
src/views/supplierPurchaseIn/supplierWorkbench/components/baseForm.vue

@@ -649,6 +649,7 @@
 <script>
 import asyncRequest from "@/apis/service/supplierPurchaseIn/supplierWorkbench";
 import resToken from "@/mixins/resToken";
+import companyHelper from "@/mixins/companyHelper";
 import { mapGetters } from "vuex";
 import baseFormAddEdit from "./baseFormAddEdit";
 import { add_sum, accMul, accDiv } from "@/utils/validate";
@@ -668,7 +669,7 @@ import {
 } from "../columns";
 export default {
   name: "goodsCostAdd",
-  mixins: [resToken],
+  mixins: [resToken,companyHelper],
   props: ["showModel", "id", "type", "sitem", "askItem", "newTime", "editId"],
   components: {
     baseFormAddEdit,
@@ -1074,6 +1075,7 @@ export default {
 
           if (this.type === "add") {
             this.spec_tableData = JSON.parse(JSON.stringify(this.askItem.specinfo));
+            this.ruleForm.supplierNo = [this.currentCompany]
           }
           await this.set_must_spec();
         }

+ 0 - 445
src/views/supplierWorkbench/workbench/columns.js

@@ -1,445 +0,0 @@
-import { isSpecialSymbol, hasSpace } from "@/utils/validate";
-//是否定制
-const options1 = [
-  { id: "0", name: "否" },
-  { id: "1", name: "是" },
-];
-//专属类型
-const options2 = [
-  { id: "0", name: "非泰康" },
-  { id: "1", name: "泰康" },
-];
-//销售权限
-const options3 = [
-  { id: "0", name: "无销售权限" },
-  { id: "1", name: "有销售权限" },
-];
-
-//是否库存品
-const options4 = [
-  { id: "0", name: "非库存品" },
-  { id: "1", name: "库存品" },
-];
-//是否启用实时金价
-const options5 = [
-  { id: "0", name: "否" },
-  { id: "1", name: "是" },
-];
-//供货区域
-const options6 = [
-  { id: "1", name: "全国" },
-  { id: "2", name: "全国除偏远" },
-];
-//是否启用阶梯
-const options7 = [
-  { id: "0", name: "否" },
-  { id: "1", name: "是" },
-];
-//有无工差
-const options8 = [
-  { id: "0", name: "无工差" },
-  { id: "1", name: "有工差" },
-];
-//配置要求
-const options9 = ["证书", "包装盒", "绒布袋", "标签", "其他"];
-//付款方式
-const options10 = [
-  { id: "0", name: "现结" },
-  { id: "1", name: "月清" },
-  { id: "2", name: "双月清" },
-];
-//发货方式
-const options11 = [
-  { id: "0", name: "公司自提" },
-  { id: "1", name: "供应商包邮" },
-];
-const listCol = [
-  {
-    prop: "cgdNo",
-    label: "采购单编号",
-    width: "160px",
-  },
-  {
-    prop: "apply_name",
-    label: "申请人",
-    width: "65px",
-  },
-  {
-    prop: "good_code",
-    label: "商品编码",
-    width: "150px",
-  },
-  {
-    prop: "good_name",
-    label: "商品名称",
-  },
-  {
-    prop: "class_cat",
-    label: "商品分类",
-  },
-
-  {
-    prop: "good_weight",
-    label: "商品总重量(g)",
-    width: "110px",
-  },
-  {
-    prop: "diff_weight",
-    label: "工差总重量(g)",
-    width: "110px",
-  },
-
-  {
-    prop: "status",
-    label: "状态",
-    _slot_: "status",
-    width: "120px",
-  },
-  {
-    prop: "addtime",
-    label: "创建时间",
-    width: "140px",
-    sortable: true,
-  },
-  {
-    prop: "",
-    label: "操作",
-    fixed: "right",
-    _noset_: true,
-    width: "52px",
-    _slot_: "operation",
-  },
-];
-
-const validate_num = (rule, value, callback) => {
-  const { required } = rule;
-  if (required) {
-  if (value === "") {
-    callback(new Error("不能为空!"));
-  } else {
-    callback();
-  }}else{
-    callback();
-  }
-};
-const validate_num_0 = (rule, value, callback) => {
-  const { required } = rule;
-  if (required) {
-    if (value === "") {
-      callback(new Error("不能为空!"));
-    } else if (
-      value === "0" ||
-      value === "0." ||
-      value === "0.0" ||
-      value === "0.00" ||
-      value === "0.000"
-    ) {
-      callback(new Error("不能为零!"));
-    } else {
-      callback();
-    }
-  } else {
-    callback();
-  }
-};
-const validate_desc = (rule, value, callback) => {
-  const { required } = rule;
-  let str = value ?? "";
-  if (required && str === "") {
-    callback(new Error("不能为空!"));
-  } else if (isSpecialSymbol(str)) {
-    callback(new Error("不能使用英文特殊字符!"));
-  } else {
-    callback();
-  }
-};
-const validate_good_name = (rule, value, callback) => {
-  const { required } = rule;
-  if (required && value.length == 0) {
-    callback(new Error("不能为空!"));
-  } else if (hasSpace(value)) {
-    callback(new Error("不能出现/回车/换行符!"));
-  } else if (isSpecialSymbol(value)) {
-    callback(new Error("不能使用英文特殊字符!"));
-  } else {
-    callback();
-  }
-};
-const rules = {
-  cat_id: [
-    {
-      type: "array",
-      required: true,
-      message: "商品分类",
-      trigger: "change",
-    },
-  ],
-  expire_day: [
-    {
-      required: true,
-      validator: validate_num_0,
-      trigger: "blur",
-    },
-  ],
-
-  supplierNo: [
-    {
-      type: "array",
-      required: true,
-      message: "请选择供应商",
-      trigger: "change",
-    },
-  ],
-  delivery_day: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-
-  pname: [
-    {
-      required: true,
-      validator: validate_good_name,
-      trigger: "blur",
-    },
-  ],
-  work_day: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-  model: [
-    {
-      required: true,
-      message: "型号不能为空",
-      trigger: "blur",
-    },
-  ],
-
-  color: [
-    {
-      required: true,
-      message: "颜色不能为空",
-      trigger: "blur",
-    },
-  ],
-  material: [
-    {
-      required: true,
-      message: "材质不能为空",
-      trigger: "blur",
-    },
-  ],
-
-  brandid: [
-    {
-      type: "array",
-      required: true,
-      message: "商品品牌",
-      trigger: "change",
-    },
-  ],
-  unit_id: [
-    {
-      type: "array",
-      required: true,
-      message: "请输入商品单位",
-      trigger: "blur",
-    },
-  ],
-  weight: [
-    {
-      required: true,
-      validator: validate_num_0,
-      trigger: "blur",
-    },
-  ],
-  tax: [
-    {
-      required: true,
-      message: "请选择税率",
-      trigger: "change",
-    },
-  ],
-  supply_area: [
-    {
-      required: true,
-      message: "请选择供货区域",
-      trigger: "change",
-    },
-  ],
-  origin_place: [
-    {
-      type: "array",
-      required: true,
-      message: "请选择产地",
-      trigger: "change",
-    },
-  ],
-
-  delivery_place: [
-    {
-      type: "array",
-      required: true,
-      message: "请选择发货地",
-      trigger: "change",
-    },
-  ],
-  //固定成本
-  cert_fee: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-  pakge_fee: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-  cost_fee: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-
-  mark_fee: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-  demo_fee: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-
-  open_fee: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-  delivery_fee: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-  nake_fee: [
-    {
-      required: true,
-      validator: validate_num,
-      trigger: "blur",
-    },
-  ],
-  noble_weight: [
-    {
-      required: true,
-      validator: validate_num_0,
-      trigger: "blur",
-    },
-  ],
-  metal_id: [
-    {
-      required: true,
-      message: "请选择贵金属种类",
-      trigger: "change",
-    },
-  ],
-  is_gold_price: [
-    {
-      required: true,
-      message: "请选择是否启用实时金价",
-      trigger: "change",
-    },
-  ],
-  is_diff: [
-    {
-      required: true,
-      message: "请选择有无工差",
-      trigger: "change",
-    },
-  ],
-  config: [
-    {
-      required: true,
-      type: "array",
-      message: "请选择配置要求",
-      trigger: "change",
-    },
-  ],
-  other_config: [
-    {
-      required: true,
-      message: "其他要求不能为空",
-      trigger: "blur",
-    },
-  ],
-  pay_way: [
-    {
-      required: true,
-      message: "请选择付款方式",
-      trigger: "change",
-    },
-  ],
-  send_way: [
-    {
-      required: true,
-      message: "请选择发货方式",
-      trigger: "change",
-    },
-  ],
-
-  cost_desc: [
-    {
-      required: false,
-      validator: validate_desc,
-      trigger: "blur",
-    },
-  ],
-  remark: [
-    {
-      required: true,
-      validator: validate_desc,
-      trigger: "blur",
-    },
-  ],
-  good_img: [
-    {
-      required: true,
-      message: "商品图片不能为空",
-      trigger: "change",
-    },
-  ],
-};
-export {
-  options1,
-  options2,
-  options3,
-  options4,
-  options5,
-  options6,
-  options7,
-  options8,
-  options9,
-  options10,
-  options11,
-  listCol,
-  rules,
-};

+ 0 - 1480
src/views/supplierWorkbench/workbench/components/baseForm.vue

@@ -1,1480 +0,0 @@
-<template>
-  <el-form
-    :model="ruleForm"
-    status-icon
-    :rules="rules"
-    ref="ruleForm"
-    :size="'mini'"
-    v-loading="loading"
-    label-width="85px"
-    class="demo-ruleForm"
-  >
-    <el-row>
-      <el-col :span="24" style="padding: 12px 16px 12px 16px; text-align: right">
-        <span>
-          预计成本合计:<span>
-            {{ newPrice }}
-          </span></span
-        >
-        <span class="fl" style="height: 28px; font-size: 16px; line-height: 28px">{{
-          title
-        }}</span>
-        <el-button :size="'mini'" @click="$emit('cancel')">取 消 </el-button>
-        <el-button
-          :size="'mini'"
-          type="primary"
-          v-if="type !== 'view'"
-          @click="submitForm"
-          >保 存
-        </el-button>
-      </el-col>
-      <el-col :span="16">
-        <el-form-item label="供应商" prop="supplierNo">
-          <search-supplier
-            :value="ruleForm.supplierNo"
-            :placeholder="'供应商'"
-            :size="'mini'"
-            :names="supplierNo_name"
-            :disabled="type === 'view'"
-            :isDetail="type !== 'add'"
-            @searchChange="supplierNosearchChange"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="8">
-        <el-form-item label="品牌" prop="brandid" label-width="60px">
-          <search-brand
-            :value="ruleForm.brandid"
-            :size="'mini'"
-            :disabled="false"
-            :isDetail="true"
-            :names="brand_name"
-            :placeholder="'品牌'"
-            @searchChange="brandidsearchChange"
-          />
-        </el-form-item>
-      </el-col>
-
-      <el-col :span="5">
-        <el-form-item label="有效期" prop="expire_day">
-          <digital-input
-            :values="ruleForm.expire_day"
-            :placeholder="'有效期'"
-            :min="1"
-            :max="100000000000"
-            :position="'right'"
-            :precision="0"
-            :size="'mini'"
-            :disabled="type === 'view'"
-            :controls="false"
-            :append="'天'"
-            @reschange="number_change($event, 'expire_day')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="5">
-        <el-form-item label="物流时间" prop="delivery_day">
-          <digital-input
-            :values="ruleForm.delivery_day"
-            :placeholder="'物流时间'"
-            :min="0"
-            :max="100000000000"
-            :position="'right'"
-            :precision="0"
-            :size="'mini'"
-            :disabled="type === 'view'"
-            :controls="false"
-            :append="'天'"
-            @reschange="number_change($event, 'delivery_day')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="5">
-        <el-form-item label="生产工期" prop="work_day">
-          <digital-input
-            :values="ruleForm.work_day"
-            :placeholder="'生产工期'"
-            :min="0"
-            :max="100000000000"
-            :disabled="type === 'view'"
-            :position="'right'"
-            :precision="0"
-            :size="'mini'"
-            :controls="false"
-            :append="'天'"
-            @reschange="number_change($event, 'work_day')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="5">
-        <el-form-item label="税点" prop="tax" label-width="60px">
-          <search-tax
-            :value="ruleForm.tax"
-            :size="'mini'"
-            :disabled="type === 'view'"
-            :isDetail="type !== 'add'"
-            :placeholder="'税点'"
-            @searchChange="taxsearchChange"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="4">
-        <el-form-item label="单位" prop="unit_id" label-width="60px">
-          <search-unit
-            :value="ruleForm.unit_id"
-            :size="'mini'"
-            :isDetail="true"
-            :names="unit_name"
-            :disabled="false"
-            :placeholder="'单位'"
-            @searchChange="unitsearchChange"
-          />
-        </el-form-item>
-      </el-col>
-
-      <el-col :span="24">
-        <el-row>
-          <el-col :span="12">
-            <el-form-item label="分类" prop="cat_id">
-              <search-sort
-                :value="ruleForm.cat_id"
-                :placeholder="'分类'"
-                :size="'mini'"
-                :names="cat_id_name"
-                :disabled="false"
-                :isDetail="true"
-                @searchChange="cat_id_change"
-              />
-            </el-form-item>
-            <el-form-item label="商品名称" prop="pname">
-              <el-input
-                placeholder="商品名称"
-                maxlength="100"
-                :disabled="type === 'view'"
-                v-model="ruleForm.pname"
-              ></el-input>
-            </el-form-item>
-            <el-form-item label="产地" prop="origin_place">
-              <select-area
-                :placeholder="'产地'"
-                :value="ruleForm.origin_place"
-                :size="'mini'"
-                :disabled="type === 'view'"
-                :is-detail="id !== 'add'"
-                @selectChange="selectAreaorigin_place"
-              />
-            </el-form-item>
-
-            <el-form-item label="发货地" prop="delivery_place">
-              <select-area
-                :placeholder="'发货地'"
-                :value="ruleForm.delivery_place"
-                :size="'mini'"
-                :disabled="type === 'view'"
-                :is-detail="id !== 'add'"
-                @selectChange="selectAreadelivery_place"
-              />
-            </el-form-item>
-          </el-col>
-          <el-col :span="12" style="padding: 0 0 0 15px">
-            <el-table
-              :data="spec_tableData"
-              :size="'mini'"
-              border
-              style="width: 100%"
-              max-height="175px"
-            >
-              <el-table-column prop="spec_name" label="规格类型" />
-              <el-table-column prop="spec_value_name" label="规格值" />
-              <el-table-column fixed="right" width="88px" v-if="type !== 'view'">
-                <template slot="header" slot-scope="scope">
-                  <span>操作</span>
-                  <el-tooltip
-                    class="item"
-                    effect="dark"
-                    content="添加规格类型"
-                    placement="top"
-                  >
-                    <i
-                      class="el-icon-circle-plus-outline fr"
-                      style="font-size: 18px; margin-top: 2px"
-                      @click="openEdit('-1', {})"
-                    />
-                  </el-tooltip>
-                </template>
-                <template slot-scope="scope">
-                  <el-tooltip effect="dark" content="修改" placement="top">
-                    <i
-                      class="el-icon-edit tb-icon"
-                      @click="openEdit(scope.$index, scope.row)"
-                    ></i>
-                  </el-tooltip>
-                  <el-tooltip
-                    effect="dark"
-                    v-if="!scope.row.isMust"
-                    content="删除"
-                    placement="top"
-                  >
-                    <i
-                      class="el-icon-delete tb-icon"
-                      @click="openDelete(scope.$index)"
-                    ></i>
-                  </el-tooltip>
-                </template>
-              </el-table-column>
-            </el-table>
-            <!-- 弹窗 新增/修改 -->
-            <base-form-add-edit
-              :index="modelIndex"
-              :show-model="showOtherModel"
-              :sitem="modelSitem"
-              @refresh="refreshEdit"
-              @cancel="showOtherModel = false"
-            />
-          </el-col>
-        </el-row>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="总重量" prop="weight">
-          <digital-input
-            :values="ruleForm.weight"
-            :placeholder="'总重量'"
-            :min="0"
-            :max="100000000000"
-            :position="'right'"
-            :precision="3"
-            :disabled="type === 'view'"
-            :size="'mini'"
-            :controls="false"
-            :append="'g'"
-            @reschange="number_change($event, 'weight')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="供货区域" prop="supply_area">
-          <el-select
-            v-model="ruleForm.supply_area"
-            filterable
-            :disabled="type === 'view'"
-            clearable
-            style="width: 100%"
-            placeholder="供货区域"
-          >
-            <el-option
-              v-for="group in options6"
-              :key="group.id"
-              :label="group.name"
-              :value="group.id"
-            />
-          </el-select>
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="付款方式" prop="pay_way" class="clear">
-          <el-select
-            v-model="ruleForm.pay_way"
-            filterable
-            :disabled="type === 'view'"
-            clearable
-            style="width: 100%"
-            placeholder="付款方式"
-          >
-            <el-option
-              v-for="group in options10"
-              :key="group.id"
-              :label="group.name"
-              :value="group.id"
-            />
-          </el-select>
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="发货方式" prop="send_way" class="clear">
-          <el-select
-            v-model="ruleForm.send_way"
-            filterable
-            clearable
-            :disabled="type === 'view'"
-            style="width: 100%"
-            placeholder="发货方式"
-          >
-            <el-option
-              v-for="group in options11"
-              :key="group.id"
-              :label="group.name"
-              :value="group.id"
-            />
-          </el-select>
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="证书费" prop="cert_fee">
-          <digital-input
-            :values="ruleForm.cert_fee"
-            :placeholder="'证书费'"
-            :min="0"
-            :disabled="type === 'view'"
-            :max="100000000000"
-            :position="'right'"
-            :precision="2"
-            :size="'mini'"
-            :controls="false"
-            :append="'元'"
-            @reschange="number_change($event, 'cert_fee')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="包装费" prop="pakge_fee">
-          <digital-input
-            :values="ruleForm.pakge_fee"
-            :placeholder="'包装费'"
-            :min="0"
-            :disabled="type === 'view'"
-            :max="100000000000"
-            :position="'right'"
-            :precision="2"
-            :size="'mini'"
-            :controls="false"
-            :append="'元'"
-            @reschange="number_change($event, 'pakge_fee')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="工艺费" prop="cost_fee">
-          <digital-input
-            :values="ruleForm.cost_fee"
-            :placeholder="'工艺费'"
-            :min="0"
-            :disabled="type === 'view'"
-            :max="100000000000"
-            :position="'right'"
-            :precision="2"
-            :size="'mini'"
-            :controls="false"
-            :append="'元'"
-            @reschange="number_change($event, 'cost_fee')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="加标费" prop="mark_fee">
-          <digital-input
-            :values="ruleForm.mark_fee"
-            :placeholder="'加标费'"
-            :min="0"
-            :disabled="type === 'view'"
-            :max="100000000000"
-            :position="'right'"
-            :precision="2"
-            :size="'mini'"
-            :controls="false"
-            :append="'元'"
-            @reschange="number_change($event, 'mark_fee')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="打样费" prop="demo_fee">
-          <digital-input
-            :values="ruleForm.demo_fee"
-            :placeholder="'打样费'"
-            :min="0"
-            :disabled="type === 'view'"
-            :max="100000000000"
-            :position="'right'"
-            :precision="2"
-            :size="'mini'"
-            :controls="false"
-            :append="'元'"
-            @reschange="number_change($event, 'demo_fee')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="开模费" prop="open_fee">
-          <digital-input
-            :values="ruleForm.open_fee"
-            :placeholder="'开模费'"
-            :min="0"
-            :disabled="type === 'view'"
-            :max="100000000000"
-            :position="'right'"
-            :precision="2"
-            :size="'mini'"
-            :controls="false"
-            :append="'元'"
-            @reschange="number_change($event, 'open_fee')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="物流费" prop="delivery_fee">
-          <digital-input
-            :values="ruleForm.delivery_fee"
-            :placeholder="'物流费'"
-            :min="0"
-            :disabled="type === 'view'"
-            :max="100000000000"
-            :position="'right'"
-            :precision="2"
-            :size="'mini'"
-            :controls="false"
-            :append="'元'"
-            @reschange="number_change($event, 'delivery_fee')"
-          />
-        </el-form-item>
-      </el-col>
-      <el-col :span="6">
-        <el-form-item label="裸价" prop="nake_fee" class="clear">
-          <digital-input
-            :values="ruleForm.nake_fee"
-            :placeholder="'裸价'"
-            :min="0"
-            :disabled="type === 'view' || is_noble"
-            :max="100000000000"
-            :position="'right'"
-            :precision="2"
-            :size="'mini'"
-            :controls="false"
-            :append="'元'"
-            @reschange="number_change($event, 'nake_fee')"
-          />
-        </el-form-item>
-      </el-col>
-
-      <el-col :span="24" v-show="pid + '' === '6'">
-        <el-col :span="6">
-          <el-form-item label="金属重量" prop="noble_weight">
-            <digital-input
-              :values="ruleForm.noble_weight"
-              :placeholder="'金属重量'"
-              :min="0"
-              :disabled="type === 'view'"
-              :max="100000000000"
-              :position="'right'"
-              :precision="3"
-              :size="'mini'"
-              :controls="false"
-              :append="'g'"
-              @reschange="number_change($event, 'noble_weight')"
-            />
-          </el-form-item>
-        </el-col>
-        <el-col :span="6">
-          <el-form-item label="金属种类" prop="metal_id">
-            <search-metal-kind
-              :value="ruleForm.metal_id"
-              :size="'mini'"
-              :disabled="type === 'view'"
-              :isDetail="true"
-              :placeholder="'金属种类'"
-              @searchChange="metal_idsearchChange"
-            />
-          </el-form-item>
-        </el-col>
-        <el-col :span="6">
-          <el-form-item label="启用金价" prop="is_gold_price">
-            <el-select
-              v-model="ruleForm.is_gold_price"
-              filterable
-              clearable
-              :disabled="type === 'view'"
-              style="width: 100%"
-              placeholder="启用金价"
-              @change="is_gold_price_change"
-            >
-              <el-option
-                v-for="group in options5"
-                :key="group.id"
-                :label="group.name"
-                :value="group.id"
-              />
-            </el-select>
-          </el-form-item>
-        </el-col>
-
-        <el-col :span="6">
-          <el-form-item label="有无工差" prop="is_diff">
-            <el-select
-              v-model="ruleForm.is_diff"
-              filterable
-              clearable
-              :disabled="type === 'view'"
-              style="width: 100%"
-              placeholder="有无工差"
-            >
-              <el-option
-                v-for="group in options8"
-                :key="group.id"
-                :label="group.name"
-                :value="group.id"
-              />
-            </el-select>
-          </el-form-item>
-        </el-col>
-        <el-col :span="12">
-          <el-form-item label="配置要求" prop="config">
-            <el-select
-              v-model="ruleForm.config"
-              multiple
-              :disabled="type === 'view'"
-              style="width: 100%"
-              placeholder="配置要求"
-            >
-              <el-option
-                v-for="(item, index) in options9"
-                :key="item + index"
-                :label="item"
-                :value="item"
-              >
-              </el-option>
-            </el-select>
-          </el-form-item>
-        </el-col>
-        <el-col :span="12">
-          <el-form-item label="其他配置要求" prop="other_config" label-width="120px">
-            <el-input
-              placeholder="其他要求"
-              maxlength="100"
-              :disabled="type === 'view'"
-              v-model="ruleForm.other_config"
-            >
-            </el-input>
-          </el-form-item>
-        </el-col>
-      </el-col>
-
-      <el-col :span="24">
-        <el-form-item label="采购备注" prop="remark">
-          <el-input
-            placeholder="采购备注"
-            maxlength="500"
-            :disabled="type === 'view'"
-            v-model="ruleForm.remark"
-          >
-          </el-input>
-        </el-form-item>
-        <el-form-item label="工艺说明" prop="cost_desc">
-          <el-input
-            placeholder="工艺说明"
-            maxlength="500"
-            :disabled="type === 'view'"
-            v-model="ruleForm.cost_desc"
-          >
-          </el-input>
-        </el-form-item>
-      </el-col>
-      <!-- <el-col :span="24">
-        <el-form-item
-          label="商品图片(<1mb)"
-          prop="good_img"
-          class="activity-upload"
-        >
-          <div class="btnupload" style="position: relative">
-            <img
-              v-if="ruleForm.good_img"
-              :src="ruleForm.good_img"
-              class="avatar"
-            />
-            <i v-else class="el-icon-plus avatar-uploader-icon"></i>
-            <file-upload
-              class="Upload"
-              :accept="'.jpg,.png,.jpeg'"
-              :multiple="true"
-              :disabled="type === 'view'"
-              :uploadcondition="beforeAvatarUpload"
-              @UploadErrorEvent="UploadErrorEventgood_img"
-              @UploadSuccessEvent="UploadSuccessEventgood_img"
-            ></file-upload>
-          </div>
-        </el-form-item>
-      </el-col> -->
-
-      <el-col :span="24">
-        <el-form-item
-          label="商品图片(<1mb)"
-          prop="good_img"
-          v-if="ruleForm.good_img"
-          class="activity-upload"
-        >
-          <div
-            class="btnupload"
-            style="position: relative; margin-left: 10px"
-            v-for="(item, index) in ruleForm.good_img"
-            :key="index"
-          >
-            <img :src="ruleForm.good_img[index]" class="avatar" />
-            <i
-              v-if="type == 'add' || type === 'editBase' || type === 'edit'"
-              class="el-icon-close"
-              @click="closeImg(index, 'good_img')"
-            ></i>
-          </div>
-          <div v-if="type == 'view' ? false : true">
-            <i
-              class="el-icon-plus avatar-uploader-icon"
-              style="position: relative; width: 50px; height: 50px"
-            >
-              <file-upload
-                class="Upload"
-                :accept="'.jpg,.png,.jpeg'"
-                :multiple="true"
-                :disabled="type === 'view'"
-                :uploadcondition="beforeAvatarUpload"
-                @UploadErrorEvent="UploadErrorEventgood_img"
-                @UploadSuccessEvent="UploadSuccessEventgood_img"
-              ></file-upload>
-            </i>
-          </div>
-        </el-form-item>
-        <!-- <i class="el-icon-plus avatar-uploader-icon">
-
-        </i>
-            <file-upload
-              class="Upload"
-              :accept="'.jpg,.png,.jpeg'"
-              :multiple="true"
-              :disabled="false"
-              :uploadcondition="beforeAvatarUpload"
-              @UploadErrorEvent="UploadErrorEventgood_img"
-              @UploadSuccessEvent="UploadSuccessEventgood_img"
-            ></file-upload> -->
-      </el-col>
-    </el-row>
-  </el-form>
-</template>
-<script>
-import asyncRequest from "@/apis/service/purchaseIn/workbench";
-import resToken from "@/mixins/resToken";
-import { mapGetters } from "vuex";
-import baseFormAddEdit from "./baseFormAddEdit.vue";
-import { add_sum, accMul, accDiv } from "@/utils/validate";
-import {
-  options1,
-  options2,
-  options3,
-  options4,
-  options5,
-  options6,
-  options7,
-  options8,
-  options9,
-  options10,
-  options11,
-  rules,
-} from "../columns";
-export default {
-  name: "goodsCostAdd",
-  mixins: [resToken],
-  props: ["showModel", "id", "type", "sitem", "askItem", "newTime", "editId"],
-  components: {
-    baseFormAddEdit,
-  },
-  computed: {
-    ...mapGetters(["tablebtnSize", "searchSize", "size"]),
-    powers() {
-      const tran =
-        this.$store.getters.btnList.find((item) => item.menu_route == "goodsCostAdd") ||
-        {};
-      const { action } = tran ?? {};
-      return action ?? [];
-    },
-  },
-  watch: {
-    newTime: function (val) {
-      if (val) {
-        this.initForm();
-      }
-    },
-  },
-
-  data() {
-    return {
-      pid: "",
-      cat_id_name: "",
-      supplierNo: "",
-      brand_name: "",
-      unit_name: "",
-      title: "",
-      modelIndex: "",
-      modelSitem: {},
-      showOtherModel: false,
-      is_noble: false,
-      status: "",
-      rulesThis: this.rules,
-      activeName: "1",
-      loading: true,
-
-      //新实时金价
-      newGoldPrice: 0,
-
-      options1: options1,
-      options2: options2,
-      options3: options3,
-      options4: options4,
-      options5: options5,
-      options6: options6,
-      options7: options7,
-      options8: options8,
-      options9: options9,
-      options10: options10,
-      options11: options11,
-      ruleForm: {},
-      rules,
-      //乘法处理
-      r1: "",
-      r2: "",
-      //除法处理
-      r3: "",
-      r4: "",
-
-      //成本合算
-      newPrice: 0,
-    };
-  },
-  mounted() {
-    this.initForm();
-  },
-  methods: {
-    //图片悬浮删除
-    closeImg(index, key) {
-      this.ruleForm[key].splice(index, 1);
-      this.$refs.ruleForm.validateField(key);
-    },
-    async initForm() {
-      this.supplierNo = [];
-      this.loading = true;
-      if (this.type === "add") {
-        this.title = "新建采返商品";
-      } else if (this.type === "edit") {
-        this.title = "编辑采返商品";
-      } else {
-        this.title = "采返商品详情";
-      }
-      this.resetFormData();
-
-      await this.resetForm();
-
-      if (this.type === "edit" || this.type === "view") {
-        await this.initData();
-      }
-      //调用实时金价获取接口
-      this.golpricelast();
-      //调用成本合算计算函数
-      // this.computedCost()
-      this.rulesThis = this.rules;
-      this.setrules();
-      this.loading = false;
-    },
-    //计算价格
-    computedCost() {
-      const { num } = this.askItem;
-      const {
-        demo_fee,
-        open_fee,
-        noble_weight,
-        cost_fee,
-        pakge_fee,
-        mark_fee,
-        cert_fee,
-        nake_fee,
-        delivery_fee,
-      } = this.ruleForm;
-      let a = accDiv(demo_fee, num); // 打样费/购买数量
-      let b = accDiv(open_fee, num); //开模费/购买数量
-      let c = accMul(noble_weight, this.newGoldPrice); //金属重量* 最新金价
-      let d = accMul(cost_fee, noble_weight); //工艺费* 金属重量
-      let e = add_sum(pakge_fee, mark_fee); //包装费+加标费
-      let f = add_sum(cert_fee, nake_fee); //证书费+产品裸价
-      if (this.is_noble) {
-        this.newPrice = add_sum(
-          add_sum(add_sum(a, b), add_sum(c, d)),
-          add_sum(add_sum(e, f), delivery_fee)
-        ).toFixed(2);
-      } else {
-        this.newPrice = add_sum(
-          add_sum(add_sum(a, b), add_sum(e, f)),
-          delivery_fee
-        ).toFixed(2);
-      }
-    },
-
-    number_change(e, key) {
-      this.ruleForm[key] = e + "" || "0";
-      this.$refs.ruleForm.validateField(key);
-      this.computedCost();
-    },
-    async initData() {
-      this.loading = true;
-      const { code, message, data } = await asyncRequest.good_detail({
-        bidNo: this.editId,
-      });
-      if (code === 0) {
-        const {
-          bidNo,
-          good_name, //string	名称
-          cat_id, //array 分类
-          cat_info,
-          brand_id, //string	品牌id
-          unit, //	string	单位
-          unit_id, //单位ID
-          tax, //string	税率
-          supplierNo, //	string	供应商
-          cost_desc, //	string	工艺说明
-          remark, //	string	采购备注
-          weight, //	string	重量
-          supply_area, //	string	供货区域 1 全国2 除偏远地区
-          origin_place, //	string	产地
-          delivery_place, // string 发货地
-          delivery_day, //	string	物流天数
-          expire_day, //	string	信息有效期
-          good_img, //
-          // good_name,
-          cert_fee, //	string	证书费
-          pakge_fee, //	string	打包费
-          cost_fee, //	string	工艺费
-          mark_fee, //	string	加标费
-          demo_fee, //	string	打样费
-          open_fee, //	string	开模费
-          metal_id, //	string	金属类别
-          noble_weight, //	string	金属重量
-          is_gold_price, //	string	是否使用实时金价
-          delivery_fee, //	string	物流费
-          status, //		string	状态
-          brand_name,
-          work_day,
-          pay_way,
-          send_way,
-          is_diff,
-          config,
-          nake_fee,
-          other_config,
-          supplierName,
-          specinfo,
-        } = JSON.parse(JSON.stringify(data));
-        if (specinfo && specinfo.length > 0) {
-          this.spec_tableData = JSON.parse(JSON.stringify(specinfo));
-        }
-        this.cat_id_name = "";
-        if (cat_info && cat_info.length) {
-          cat_info.forEach((e, ei) => {
-            if (ei === 0) {
-              this.pid = e.id;
-            }
-            this.cat_id_name += `${ei !== 0 ? "_" : ""}${e.name}`;
-          });
-        }
-        this.supplierNo_name = supplierName || "";
-        this.is_noble = is_gold_price === "1" && this.pid === "6";
-        // this.is_noble = this.askItem.is_metal;
-        this.brand_name = brand_name || "";
-        this.unit_name = unit || "";
-        this.ruleForm = {
-          infoNo: this.id || "",
-          bidNo: bidNo || "",
-          infoNo: this.id || "",
-          cat_id: cat_id ? [cat_id] : [],
-          supplierNo: supplierNo ? [supplierNo] : [],
-          pname: good_name || "",
-          expire_day: expire_day || "1", //有效期
-          delivery_day: delivery_day || "0", //物流时间
-          work_day: work_day || "0", //生产工期
-          brandid: brand_id ? [brand_id] : [],
-          unit_id: unit_id ? [unit_id] : [],
-          weight: weight || "0.000",
-          tax: tax ? tax + "%" : "",
-          supply_area: supply_area || "",
-          origin_place: origin_place ? origin_place.split(",") : [],
-          delivery_place: delivery_place ? delivery_place.split(",") : [],
-
-          cert_fee: cert_fee || "0.00",
-          pakge_fee: pakge_fee || "0.00",
-          cost_fee: cost_fee || "0.00",
-          mark_fee: mark_fee || "0.00",
-          demo_fee: demo_fee || "0.00",
-          open_fee: open_fee || "0.00",
-          delivery_fee: delivery_fee || "0.00",
-          nake_fee: nake_fee || "0.00",
-          pay_way: pay_way || "",
-          send_way: send_way || "",
-          noble_weight: noble_weight || "0.000",
-
-          metal_id: metal_id || "",
-          is_gold_price: is_gold_price || "",
-          is_diff: is_diff || "",
-          config: config ? config.split(",") : [],
-          other_config: other_config || "",
-          remark: remark || "",
-          cost_desc: cost_desc || "",
-          good_img: good_img || [],
-        };
-
-        this.status = status;
-        if (this.is_noble) {
-          this.ruleForm.nake_fee = "0";
-        }
-      } else if (code >= 100 && code <= 104) {
-        await this.logout();
-      } else {
-        this.$message.warning(message);
-      }
-    },
-    async submitForm() {
-      if (this.loading) {
-        return;
-      }
-      if (this.is_noble) {
-        this.ruleForm.nake_fee = "0";
-      }
-      this.computedCost();
-      if (this.ruleForm.good_img.length > 10) {
-        this.$message.warning("上传图片不能超过10张");
-        return;
-      }
-
-      // for (let key in this.ruleForm) {
-      //   console.log(this.rulesThis[key]);
-      //   console.log(
-      //     key + "---" + this.rulesThis[key][0].required + "-----" + this.ruleForm[key]
-      //   );
-      // }
-      await this.$refs.ruleForm.validate(async (valid) => {
-        console.log(valid);
-        if (valid) {
-          if (!this.loading) {
-            this.loading = true;
-            if (this.spec_tableData.length === 0) {
-              this.$message.warning("请填写规格!");
-              this.loading = false;
-              return;
-            }
-            let model = JSON.parse(JSON.stringify(this.ruleForm));
-            model.cat_id = model.cat_id[model.cat_id.length - 1];
-            model.brandid = model.brandid.toString();
-            model.supplierNo = model.supplierNo.toString();
-            model.origin_place = model.origin_place.toString();
-            model.delivery_place = model.delivery_place.toString();
-
-            model.unit_id = model.unit_id.toString();
-            model.config = model.config.toString();
-            model.tax = parseInt(model.tax + "") + "";
-            model.specinfo = [];
-            let list = JSON.parse(JSON.stringify(this.spec_tableData));
-            list.forEach((a) => {
-              let am = {
-                specid: a.specid,
-                spec_value_id: a.spec_value_id,
-              };
-              model.specinfo.push(am);
-            });
-            console.log(model);
-            let res = {};
-            if (this.type === "add") {
-              delete model["bidNo"];
-              res = await asyncRequest.good_add(model);
-            } else {
-              res = await asyncRequest.good_update(model);
-            }
-            this.loading = false;
-            if (res && res.code === 0) {
-              const title = this.type === "add" ? "新建成功!" : "修改成功!";
-              this.$notify.success({
-                title: title,
-                message: "",
-              });
-              this.showModelThis = false;
-              // 刷新
-              this.$emit("refresh");
-            } else if (res && res.code >= 100 && res.code <= 104) {
-              await this.logout();
-            } else {
-              this.$message.warning(res.message);
-            }
-          }
-        } else {
-          console.log("error submit!!");
-          return false;
-        }
-      });
-    },
-
-    async resetForm() {
-      // 重置
-      await this.$nextTick(async () => {
-        if (this.$refs.ruleForm) {
-          console.log(this.queryId)
-
-          this.$refs.ruleForm.resetFields();
-          this.$refs.ruleForm.clearValidate();
-          this.spec_tableData = [];
-          // console.log(this.askItem);
-          this.is_noble = false;
-          const { can_id_arr, is_gold_price } = this.askItem;
-          can_id_arr.forEach((e, index) => {
-            if (index == 0) {
-              this.pid = e;
-            }
-          });
-          if (this.pid === "6" && is_gold_price === "1") {
-            this.is_noble = true;
-          }
-          this.cat_id_name = this.type === "add" ? this.askItem.can_name : "";
-          this.brand_name = "";
-          // this.type === "add" ? this.askItem.brand : "";
-          this.unit_name = "";
-          let good_img = this.askItem.good_img ? this.askItem.good_img.split(",") : [];
-          //this.type === "add" ? this.askItem.unit_name : "";
-          this.ruleForm = {
-            infoNo: this.id || "",
-            cat_id: this.type === "add" ? [this.askItem.cat_id] : [],
-            supplierNo: [],
-            pname: this.type === "add" ? this.askItem.good_name : "",
-            expire_day: "1", //有效期
-            delivery_day: "0", //物流时间
-            work_day: "0", //生产工期
-            brandid: [],
-            // this.type === "add" && this.askItem.brand_id
-            //   ? [this.askItem.brand_id]
-            //   : [],
-            unit_id: [],
-            //this.type === "add" ? [this.askItem.unit] : [],
-            weight: this.type === "add" ? this.askItem.total_weight : "0.000",
-            tax: "",
-            supply_area: "",
-            origin_place: [],
-            delivery_place: [],
-            cert_fee: "0.00",
-            pakge_fee: "0.00",
-            cost_fee: "0.00",
-            mark_fee: "0.00",
-            demo_fee: "0.00",
-            open_fee: "0.00",
-            delivery_fee: "0.00",
-            nake_fee: "0.00",
-            pay_way: "",
-            send_way: "",
-            noble_weight: this.type === "add" ? this.askItem.specs_weight : "0.000",
-            metal_id: this.type === "add" ? this.askItem.metal_id : "",
-            is_gold_price: this.type === "add" ? this.askItem.is_gold_price : "",
-            is_diff: "",
-            config:
-              this.type === "add"
-                ? this.askItem.config
-                  ? this.askItem.config.split(",")
-                  : []
-                : [],
-            other_config: this.type === "add" ? this.askItem.other_config : "",
-            remark: "",
-            cost_desc: this.type === "add" ? this.askItem.cost_desc : "",
-            good_img: this.type === "add" ? good_img : [],
-          };
-
-          if (this.type === "add") {
-            this.spec_tableData = JSON.parse(JSON.stringify(this.askItem.specinfo));
-          }
-          await this.set_must_spec();
-        }
-      });
-    },
-
-    openEdit(index, sitem) {
-      this.modelIndex = index;
-      this.modelSitem = sitem;
-      this.showOtherModel = true;
-    },
-    openDelete(index) {
-      this.spec_tableData.splice(index, 1);
-    },
-    //规格编辑修改结果
-    refreshEdit(e) {
-      let item = JSON.parse(JSON.stringify(e));
-      const { index, specid, spec_name, spec_value_id, spec_value_name } = item;
-      if (index + "" === "-1") {
-        this.spec_tableData.push(item);
-      } else {
-        let findex = parseInt(index + "");
-        this.spec_tableData[findex].specid = specid;
-        this.spec_tableData[findex].spec_name = spec_name;
-        this.spec_tableData[findex].spec_value_id = spec_value_id;
-        this.spec_tableData[findex].spec_value_name = spec_value_name;
-      }
-      this.showOtherModel = false;
-    },
-    //分类选择
-    async cat_id_change(e) {
-      const { pid, id, label } = e;
-      this.pid = pid || "";
-      this.ruleForm.cat_id = id ? [id] : [];
-
-      this.$refs.ruleForm.validateField("cat_id");
-      const { is_gold_price } = this.ruleForm;
-      this.is_noble = this.pid === "6" && is_gold_price === "1";
-      this.setrules();
-      if (this.is_noble) {
-        this.ruleForm.nake_fee = "0";
-      }
-
-      this.computedCost();
-      await this.set_must_spec();
-    },
-    async set_must_spec() {
-      const { cat_id } = this.ruleForm;
-      let id = cat_id.length == 1 ? cat_id[0] : "";
-      if (id) {
-        const { code, message, data } = await asyncRequest.catinfo({ id: id });
-        if (code === 0) {
-          const { spec } = data;
-          if (spec && spec.length > 0) {
-            if (this.spec_tableData && this.spec_tableData.length > 0) {
-              this.spec_tableData.forEach((c) => {
-                c.isMust = false;
-              });
-              spec.forEach((a, ai) => {
-                let findex = this.spec_tableData.findIndex((b) => b.specid === a.id);
-                if (findex !== -1) {
-                  this.spec_tableData[findex].isMust = true;
-                } else {
-                  this.spec_tableData.push({
-                    id: "",
-                    index: "1",
-                    specid: a.id,
-                    spec_name: a.spec_name,
-                    isMust: true,
-                    spec_value_name: "",
-                    spec_value_id: "",
-                  });
-                }
-              });
-            } else {
-              spec.forEach((a, ai) => {
-                let model = {
-                  id: "",
-                  index: "1",
-                  specid: a.id,
-                  spec_name: a.spec_name,
-                  isMust: true,
-                  spec_value_name: "",
-                  spec_value_id: "",
-                };
-                this.spec_tableData.push(model);
-              });
-            }
-          }
-          this.spec_tableData.map((e, ei) => {
-            e.index = ei + "";
-            return e;
-          });
-
-          this.spec_tableData.forEach((si, sii) => {
-            this.$set(this.spec_tableData, sii, si);
-          });
-          console.log(this.spec_tableData);
-        } else if (code >= 100 && code <= 104) {
-          await this.logout();
-        } else {
-          this.$message.warning(message);
-        }
-      } else {
-        this.spec_tableData.forEach((si, sii) => {
-          si.isMust = false;
-          this.$set(this.spec_tableData, sii, si);
-        });
-      }
-    },
-    setrules() {
-      let list1 = ["noble_weight", "is_gold_price", "is_diff"];
-      for (let i = 0; i < list1.length; i++) {
-        this.rulesThis[list1[i]][0].required = this.is_noble;
-      }
-      let list2 = ["metal_id", "config", "other_config"];
-      for (let i = 0; i < list2.length; i++) {
-        this.rulesThis[list2[i]][0].required = this.pid === "6";
-      }
-    },
-    is_gold_price_change() {
-      const { is_gold_price } = this.ruleForm;
-      this.$refs.ruleForm.validateField("is_gold_price");
-      this.is_noble = this.pid === "6" && is_gold_price === "1";
-      this.setrules();
-      if (this.is_noble) {
-        this.ruleForm.nake_fee = "0";
-      }
-      this.computedCost();
-    },
-    //品牌选择
-    brandidsearchChange(e) {
-      const { id, code, label } = e;
-      if (id) {
-        this.ruleForm.brandid = [id];
-      } else {
-        this.ruleForm.brandid = [];
-      }
-      this.$refs.ruleForm.validateField("brandid");
-    },
-    //供应商选择
-    supplierNosearchChange(e) {
-      console.log(e);
-      const { id, code, label } = e;
-      if (id) {
-        this.ruleForm.supplierNo = [code];
-      } else {
-        this.ruleForm.supplierNo = [];
-      }
-      this.$refs.ruleForm.validateField("supplierNo");
-    },
-    //税点选择
-    taxsearchChange(e) {
-      this.ruleForm.tax = e;
-      this.$refs.ruleForm.validateField("tax");
-    },
-    //单位选择
-    unitsearchChange(e) {
-      const { id, code, label } = e;
-      if (id) {
-        this.ruleForm.unit_id = [code];
-      } else {
-        this.ruleForm.unit_id = [];
-      }
-      this.$refs.ruleForm.validateField("unit_id");
-    },
-    //金属种类选择
-    //需修改,未改完
-    async metal_idsearchChange(e) {
-      this.loading = true;
-      const { id, code, label } = e;
-      if (id) {
-        this.ruleForm.metal_id = id;
-      } else {
-        this.ruleForm.metal_id = "";
-      }
-      this.$refs.ruleForm.validateField("metal_id");
-
-      //获取实时金价
-      this.golpricelast();
-
-      this.loading = false;
-    },
-    //获取实时金价
-    async golpricelast() {
-      const { metal_id } = this.ruleForm;
-      if (metal_id === "" && metal_id === "0") {
-        this.newGoldPrice = 0;
-        this.computedCost();
-        return;
-      }
-      const { code, data } = await asyncRequest.golpricelast({
-        type: metal_id,
-      });
-      if (code === 0) {
-        if (data.length !== 1) {
-          this.newGoldPrice = 0;
-        } else {
-          this.newGoldPrice = data[0].price;
-        }
-      } else if (code >= 100 && code <= 104) {
-        this.newGoldPrice = 0;
-        await this.logout();
-      } else {
-        this.newGoldPrice = 0;
-      }
-      this.computedCost();
-    },
-
-    //仓库省市区
-    selectAreaorigin_place(e) {
-      this.ruleForm.origin_place = e;
-      this.$refs.ruleForm.validateField("origin_place");
-    },
-    //发货地省市区
-    selectAreadelivery_place(e) {
-      this.ruleForm.delivery_place = e;
-      this.$refs.ruleForm.validateField("delivery_place");
-    },
-
-    //图片上传成功
-    async UploadSuccessEventgood_img(data) {
-      await this.UploadSuccessEvent(1, data);
-    },
-
-    //图片上传成功
-    async UploadSuccessEvent(type, data) {
-      if (this.ruleForm.good_img.length > 10) {
-        this.$message.warning("上传图片最多不能超过10张");
-        return;
-      }
-      const { url } = data;
-      if (url === "noToken") {
-        await this.logout();
-      } else {
-        if (type === 1) {
-          this.ruleForm.good_img.push(url);
-          this.$refs.ruleForm.validateField("good_img");
-        } else if (type === 2) {
-          this.ruleForm.good_img.push(url);
-          this.$refs.ruleForm.validateField("good_img");
-        }
-        console.log(this.ruleForm.good_img.length);
-        this.$message.success("图片上传成功!");
-      }
-    },
-    //图片上传失败
-    UploadErrorEventgood_img(res) {
-      this.imgUploadError(1, res);
-    },
-
-    imgUploadError(type, res) {
-      if (res !== "break") {
-        this.$message.error("图片上传失败!");
-        this.$refs.ruleForm.validateField(
-          type === 1 ? "good_img" : type === 2 ? "good_img" : ""
-        );
-      }
-    },
-    //判断图片规格
-    beforeAvatarUpload(file) {
-      let isJPG = false;
-      if (
-        file.type === "image/jpg" ||
-        file.type === "image/png" ||
-        file.type === "image/jpeg"
-      ) {
-        isJPG = true;
-      }
-      const isLt2M = file.size / 1024 / 1024 < 1;
-      if (!isJPG) {
-        this.$message.error("图片格式不正确!");
-      }
-      if (!isLt2M) {
-        this.$message.error("图片大小不能超过 1MB!");
-      }
-      return isJPG && isLt2M;
-    },
-    resetFormData() {
-      this.status = "";
-      this.is_noble = false;
-      this.cat_id_name = "";
-      this.brand_name = "";
-      this.unit_name = "";
-      this.ruleForm = {
-        infoNo: "",
-        cat_id: [],
-        supplierNo: [],
-        pname: "",
-        expire_day: "1", //有效期
-        delivery_day: "0", //物流时间
-        work_day: "0", //生产工期
-        color: "",
-        model: "",
-        material: "",
-        brandid: [],
-        unit_id: [],
-        weight: "0.000",
-        tax: "",
-        supply_area: "",
-        origin_place: [],
-        delivery_place: [],
-        cert_fee: "0.00",
-        pakge_fee: "0.00",
-        cost_fee: "0.00",
-        mark_fee: "0.00",
-        demo_fee: "0.00",
-        open_fee: "0.00",
-        delivery_fee: "0.00",
-        nake_fee: "0.00",
-        pay_way: "",
-        send_way: "",
-        noble_weight: "0.000",
-        metal_id: "",
-        is_gold_price: "",
-        is_diff: "",
-        config: [],
-        other_config: "",
-        remark: "",
-        cost_desc: "",
-        good_img: [],
-      };
-    },
-    addFormData() {
-      this.status = "";
-      this.is_noble = false;
-      this.cat_id_name = "";
-      this.brand_name = "";
-      this.unit_name = "";
-      this.ruleForm = {
-        infoNo: "",
-        cat_id: [],
-        supplierNo: [],
-        pname: "",
-        expire_day: "1", //有效期
-        delivery_day: "0", //物流时间
-        work_day: "0", //生产工期
-        color: "",
-        model: "",
-        material: "",
-        brandid: [],
-        unit_id: [],
-        weight: "0.000",
-        tax: "",
-        supply_area: "",
-        origin_place: [],
-        delivery_place: [],
-        cert_fee: "0.00",
-        pakge_fee: "0.00",
-        cost_fee: "0.00",
-        mark_fee: "0.00",
-        demo_fee: "0.00",
-        open_fee: "0.00",
-        delivery_fee: "0.00",
-        nake_fee: "0.00",
-        pay_way: "",
-        send_way: "",
-        noble_weight: "0.000",
-        metal_id: "",
-        is_gold_price: "",
-        is_diff: "",
-        config: [],
-        other_config: "",
-        remark: "",
-        cost_desc: "",
-        good_img: [],
-      };
-    },
-  },
-};
-</script>
-<style lang="scss" scoped>
-.goodsCostDetail {
-  .goodsCostAdd-title {
-    border-top: 1px solid #ebeef5;
-    span {
-      height: 50px;
-      line-height: 50px;
-      font-family: "微软雅黑", sans-serif;
-      font-weight: 400;
-      font-style: normal;
-      font-size: 16px;
-      text-align: left;
-    }
-  }
-}
-i.el-icon-close {
-  position: absolute;
-  z-index: 2;
-  top: 0;
-  right: 0;
-  color: #6954f0;
-  font-weight: bold;
-  cursor: pointer;
-}
-
-// /deep/ .fileUp {
-//       opacity: 10 !important;
-//     width: 228px !important;
-//     height: 200px !important;
-//     outline: none;
-//     position: static !important;
-// }
-</style>

+ 0 - 265
src/views/supplierWorkbench/workbench/components/baseFormAddEdit.vue

@@ -1,265 +0,0 @@
-<template>
-  <el-dialog
-    v-loading="loading"
-    :title="title"
-    :center="true"
-    align="left"
-    top="5vh"
-    width="1040px"
-    :close-on-click-modal="false"
-    :visible.sync="showModelThis"
-    element-loading-text="拼命加载中"
-    element-loading-spinner="el-icon-loading"
-    element-loading-background="rgba(0, 0, 0, 0.8)"
-    @close="showModelThis = false"
-    append-to-body
-  >
-    <el-card style="margin: -20px 0 0 0">
-      <el-row :gutter="10">
-        <el-col :span="24">
-          <el-form
-            ref="ruleForm"
-            :model="ruleForm"
-            status-icon
-            :size="'small'"
-            :rules="rulesThis"
-            label-width="80px"
-            class="demo-ruleForm"
-          >
-            <el-form-item label="规格类型" prop="specid">
-              <search-spec
-                :value="ruleForm.specid"
-                :disabled="sitem.isMust"
-                :size="'mini'"
-                :isDetail="false"
-                :placeholder="'规格类型'"
-                @searchChange="specidsearchChange"
-              />
-            </el-form-item>
-            <el-form-item label="规格值" prop="spec_value_id">
-              <div v-if="specVlist.length > 0">
-                <el-select
-                  placeholder="请选择规格值"
-                  v-model="ruleForm.spec_value_id"
-                  @change="spec_value_id_change"
-                  style="width: 100%"
-                  filterable
-                >
-                  <el-option
-                    v-for="item in specVlist"
-                    :key="item.id + item.spec_value"
-                    :label="item.spec_value"
-                    :value="item.id"
-                    >{{ item.spec_value }}</el-option
-                  >
-                </el-select>
-              </div>
-              <div class="no-data" v-else>暂无规格值,请添加!</div>
-            </el-form-item>
-          </el-form>
-        </el-col>
-        <el-col :span="24" style="text-align: right">
-          <el-input
-            style="width: 209px"
-            v-model="sinput"
-            class="fl"
-            :disabled="id == 'edit'"
-            :size="'small'"
-            placeholder="规格值名称,如红色"
-            maxlength="50"
-          />
-          <el-button
-            style="margin: 0 0 0 10px"
-            icon="el-icon-plus"
-            :size="'small'"
-            @click="add_spec"
-            class="fl"
-            >新增规格值</el-button
-          >
-          <el-button
-            v-if="id !== 'edit'"
-            :size="'small'"
-            type="primary"
-            @click="submitForm"
-            >保 存
-          </el-button>
-          <el-button @click="showModelThis = false" :size="'small'">{{
-            id == "edit" ? "关 闭" : "取 消"
-          }}</el-button>
-        </el-col>
-      </el-row>
-    </el-card>
-  </el-dialog>
-</template>
-<script>
-import asyncRequest from "@/apis/service/goodStore/goodsCost";
-import resToken from "@/mixins/resToken";
-export default {
-  name: "brand",
-  props: ["showModel", "index", "sitem"],
-  mixins: [resToken],
-  data() {
-    return {
-      loading: false,
-      title: "商品规格",
-      sinput: "",
-      showModelThis: this.showModel,
-      specVlist: [],
-      ruleForm: {},
-      rulesThis: this.rules,
-
-      rules: {
-        specid: [
-          {
-            required: true,
-            message: "规格类型不能为空",
-            trigger: "change",
-          },
-        ],
-        spec_value_id: [{ required: true, message: "请选择规格值", trigger: "change" }],
-      },
-    };
-  },
-  watch: {
-    showModel: function (val) {
-      this.showModelThis = val;
-      if (val) {
-        this.initForm();
-      }
-    },
-    showModelThis(val) {
-      if (!val) {
-        this.$emit("cancel");
-      }
-    },
-  },
-  methods: {
-    async initForm() {
-      this.loading = true;
-      this.resetFormData();
-      this.rulesThis = this.rules;
-      if (this.index + "" === "-1") {
-        this.title = "添加商品规格值";
-      } else {
-        this.title = "修改商品规格值";
-      }
-      await this.resetForm();
-      this.loading = false;
-    },
-    async resetForm() {
-      // 重置
-      await this.$nextTick(async () => {
-        if (this.$refs.ruleForm) {
-          this.$refs.ruleForm.resetFields();
-          this.$refs.ruleForm.clearValidate();
-          if (this.index + "" !== "-1") {
-            this.specVlist = [];
-            const { specid, spec_name, spec_value_id, spec_value_name } = this.sitem;
-            this.ruleForm = {
-              index: this.index,
-              specid: specid || "",
-              spec_name: spec_name || "",
-              spec_value_id: spec_value_id || "",
-              spec_value_name: spec_value_name || "",
-            };
-            await this.getlist();
-            console.log(this.ruleForm);
-          }
-        }
-      });
-    },
-    resetFormData() {
-      this.specVlist = [];
-      this.ruleForm = {
-        index: "-1",
-        specid: "",
-        spec_name: "",
-        spec_value_id: "",
-        spec_value_name: "",
-      };
-    },
-    async add_spec() {
-      const { specid } = this.ruleForm;
-      if (specid) {
-        if (this.sinput) {
-          const { code, data, message } = await asyncRequest.valueadd({
-            spec_id: specid,
-            spec_value: this.sinput,
-          });
-          if (code === 0) {
-            await this.getlist();
-          } else if (code >= 100 && code <= 104) {
-            await this.logout();
-          } else {
-            this.$message.warning(message);
-          }
-        } else {
-          this.$message.warning("请输入规格值!");
-        }
-      } else {
-        this.$message.warning("请选择规格类型!");
-      }
-    },
-    async specidsearchChange(e) {
-      const { id, spec_name } = e;
-      this.ruleForm.specid = id || "";
-      this.ruleForm.spec_name = spec_name || "";
-      this.$refs.ruleForm.validateField("specid");
-      await this.getlist();
-    },
-    spec_value_id_change(e) {
-      if (e) {
-        const { id, spec_value } = this.specVlist.find((i) => i.id === e);
-        this.ruleForm.spec_value_id = id || "";
-        this.ruleForm.spec_value_name = spec_value || "";
-      } else {
-        this.ruleForm.spec_value_id = "";
-        this.ruleForm.spec_value_name = "";
-      }
-      this.$refs.ruleForm.validateField("spec_value_id");
-    },
-    async getlist() {
-      const { specid } = this.ruleForm;
-      if (specid) {
-        const { code, data, message } = await asyncRequest.valueall({
-          spec_id: specid,
-        });
-        if (code === 0) {
-          this.specVlist = data;
-        } else if (code >= 100 && code <= 104) {
-          await this.logout();
-        } else {
-          this.$message.warning(message);
-        }
-      } else {
-        this.specVlist = [];
-      }
-    },
-
-    async submitForm() {
-      await this.$refs.ruleForm.validate(async (valid) => {
-        if (valid) {
-          this.showModelThis = false;
-          console.log(this.ruleForm);
-          this.$emit("refresh", this.ruleForm);
-        } else {
-          console.log("error submit!!");
-          return false;
-        }
-      });
-    },
-  },
-};
-</script>
-
-<style lang="scss" scoped>
-.goodsCostAdd {
-  .no-data {
-    text-align: center;
-    line-height: 32px;
-    color: #8492a6;
-    // border: 1px solid #ccc;
-    border-radius: 6px;
-  }
-}
-</style>

+ 0 - 553
src/views/supplierWorkbench/workbench/detail.vue

@@ -1,553 +0,0 @@
-<template>
-  <div class="workbenchdetail">
-    <div
-      class="page-main clear"
-    >
-      <div v-if="status !== '1'">
-        <search-not :placeholder="'招标任务已结束!'" />
-      </div>
-      <div v-else>
-        <div class="left">
-          <div class="left-main">
-            <div class="left-card" v-if="sitem">
-              <div class="page-main-title">招标任务信息</div>
-              <ul class="page-main-ul clear">
-                <li>任务单号:</li>
-                <li>{{ queryId }}</li>
-                <li>截止时间:</li>
-                <li>{{ sitem.endtime }}</li>
-                <!-- <li>剩余时间:</li>
-                <li>2020-09-20 17:00:00</li> -->
-                <li>购买数量:</li>
-                <li>{{ sitem.num }}{{ sitem.unit_name }}</li>
-                <li>预算单价:</li>
-                <li>{{ sitem.original_price }}元</li>
-                <li>竞价人:</li>
-                <li>{{ sitem.salesman }}</li>
-                <li>到货时间:</li>
-                <li>{{ sitem.arrival_time }}</li>
-                <li>客户名称:</li>
-                <li>{{ sitem.khname }}</li>
-              </ul>
-            </div>
-            <div class="left-card" v-if="sitem">
-              <div class="page-main-title">商品要求</div>
-              <ul class="page-main-ul clear">
-                <li>商品名称:</li>
-                <li>{{ sitem.good_name }}</li>
-                <li v-if="sitem.good_img">商品图片:</li>
-                <li v-if="sitem.good_img">
-                  <img
-                    v-viewer
-                    :src="sitem.good_img"
-                    class="hover"
-                    style="width: 20px; height: 20px; display: inline-block"
-                  />
-                </li>
-                <li>商品分类:</li>
-                <li>{{ sitem.can_name }}</li>
-                <li>商品品牌:</li>
-                <li>{{ sitem.brand ? sitem.brand : "无要求" }}</li>
-                <li>商品规格:</li>
-                <li>
-                  <el-table
-                    :data="sitem.specinfo"
-                    border
-                    stripe
-                    :size="'mini'"
-                    style="width: 100%"
-                  >
-                    <el-table-column
-                      prop="spec_name"
-                      label="类型:值"
-                      show-overflow-tooltip
-                    >
-                      <template slot-scope="scope">
-                        {{ scope.row.spec_name }}:{{
-                          scope.row.spec_value_name
-                        }}
-                      </template></el-table-column
-                    >
-                  </el-table>
-                </li>
-                <li>总重量:</li>
-                <li>{{ sitem.total_weight }}g</li>
-                <li>是否多地:</li>
-                <li>{{ sitem.is_addrs + '' === "1" ? "多地" : "一地" }}</li>
-                <li>是否定制:</li>
-                <li>{{ sitem.is_custom + '' === "1" ? "定制" : "非定制" }}</li>
-
-                <li v-if="sitem.is_metal">启用金价:</li>
-                <li v-if="sitem.is_metal">
-                  {{ sitem.is_gold_price + '' === "1" ? "启用" : "不启用" }}
-                </li>
-                <li v-if="sitem.is_metal">配置要求:</li>
-                <li v-if="sitem.is_metal">{{ sitem.config }}</li>
-
-                <li v-if="sitem.is_metal">金属克重:</li>
-                <li v-if="sitem.is_metal">{{ sitem.specs_weight }}g</li>
-                <li v-if="sitem.is_metal">其他要求:</li>
-                <li v-if="sitem.is_metal">
-                  {{ sitem.other_config }}
-                </li>
-                <li v-if="sitem.is_metal">金属种类:</li>
-                <li v-if="sitem.is_metal">
-                  {{ sitem.metal_name }}
-                </li>
-
-                <li v-if="sitem && sitem.cost_desc">工艺说明:</li>
-                <li v-if="sitem && sitem.cost_desc">{{ sitem.cost_desc }}</li>
-                <li>产品用途:</li>
-                <li>{{ sitem.use_desc }}</li>
-                <li>商品备注:</li>
-                <li>{{ sitem.remark }}</li>
-                <li>商品附件:</li>
-                <li v-if="sitem && sitem.enclosure_file">
-                  <a :href="sitem.enclosure_file" download="附件" class="fl"
-                    >点击下载附件</a
-                  >
-                </li>
-              </ul>
-            </div>
-          </div>
-        </div>
-        <div class="p-right">
-          <div
-            v-if="editType == '' || editType == 'wait'"
-            class="right-mian-wait"
-          >
-            <div class="title">采返工作台</div>
-            <div class="main">暂无工作数据!</div>
-          </div>
-          <template v-else>
-            <base-form
-              :id="queryId"
-              :editId="editId"
-              :type="editType"
-              :askItem="sitem"
-              :sitem="baseSitem"
-              :newTime="newTime"
-              @refresh="(editType = 'wait'), searchList()"
-              @cancel="editType = 'wait'"
-              v-if="newTime !== ''"
-            />
-          </template>
-        </div>
-        <div class="bottom">
-          <el-table
-            :data="tableData"
-            border
-            stripe
-            :size="'mini'"
-            style="width: 100%"
-          >
-            <!-- <el-table-column
-              prop="good_img"
-              label="图片"
-              width="48"
-              show-overflow-tooltip
-            >
-              <template slot-scope="scope">
-                <div
-                  v-if="scope.row.good_img"
-                  style="width: 20px; height: 20px"
-                  class="hover"
-                  v-viewer
-                >
-                  <img
-                    :src="scope.row.good_img"
-                    style="display: inline-block; width: 100%; height: 100%"
-                    alt=""
-                  />
-                </div>
-              </template>
-            </el-table-column> -->
-            <el-table-column
-              prop="good_name"
-              label="商品名称"
-              min-width="120"
-              show-overflow-tooltip
-            />
-            <el-table-column
-              prop="total_fee"
-              label="成本合计"
-              width="110"
-              show-overflow-tooltip
-            />
-            <el-table-column
-              prop="bargain_status"
-              label="采返信息状态"
-              width="100"
-              show-overflow-tooltip
-            >
-              <template slot-scope="scope">
-                <el-tag
-                  type="''"
-                  :size="'mini'"
-                  v-if="
-                    scope.row.bargain_status + '' === '0' && scope.row.status == '1'
-                  "
-                  >新建信息</el-tag
-                >
-                <el-tag type="danger" :size="'mini'" v-else>待确认</el-tag>
-              </template></el-table-column
-            >
-
-            <el-table-column
-              prop="specinfo"
-              label="规格"
-              width="100"
-              show-overflow-tooltip
-            >
-              <template slot-scope="scope">
-                <span v-for="(item, ii) in scope.row.specinfo" :key="item + ii"
-                  ><span v-if="ii !== 0">--</span>{{ item.spec_name }}[{{
-                    item.spec_value_name
-                  }}]</span
-                >
-              </template></el-table-column
-            >
-
-            <el-table-column
-              prop="unit"
-              label="单位"
-              width="45"
-              show-overflow-tooltip
-            />
-            <el-table-column
-              prop="brand_name"
-              label="品牌"
-              width="80"
-              show-overflow-tooltip
-            />
-
-            <el-table-column
-              prop="supplierName"
-              label="供应商"
-              show-overflow-tooltip
-            />
-            <el-table-column fixed="right" label="操作" width="80">
-              <template slot="header" slot-scope="scope">
-                <span>操作</span>
-                <el-tooltip
-                  effect="dark"
-                  content="添加反馈商品"
-                  placement="top"
-                >
-                  <i
-                    class="el-icon-circle-plus-outline tb-icon fr"
-                    @click="openModal('add', 'add')"
-                  ></i>
-                </el-tooltip>
-              </template>
-              <template slot-scope="scope">
-                <el-tooltip
-                  effect="dark"
-                  content="详情"
-                  placement="top"
-                >
-                  <i
-                    class="el-icon-view tb-icon"
-                    @click="openModal(scope.row.bidNo, 'view')"
-                  ></i>
-                </el-tooltip>
-                <el-tooltip effect="dark" content="修改" placement="top">
-                  <i
-                    class="el-icon-edit tb-icon"
-                    @click="openModal(scope.row.bidNo, 'edit')"
-                  ></i>
-                </el-tooltip>
-              </template>
-            </el-table-column>
-          </el-table>
-        </div>
-      </div>
-    </div>
-  </div>
-</template>
-   <script>
-import asyncRequest from "@/apis/service/purchaseIn/workbench";
-import resToken from "@/mixins/resToken";
-import { mapGetters } from "vuex";
-import baseForm from "./components/baseForm.vue";
-export default {
-  name: "supplierWorkbenchDetail",
-  components: {
-    baseForm,
-  },
-
-  mixins: [resToken],
-  computed: {
-    ...mapGetters(["tablebtnSize", "searchSize", "size"]),
-    powers() {
-      const tran =
-        this.$store.getters.btnList.find(
-          (item) => item.menu_route == "workbenchDetail"
-        ) || {};
-      const { action } = tran ?? {};
-      return action ?? [];
-    },
-  },
-  data() {
-    return {
-      num: 60,
-      timer: null,
-      loading: false,
-      showModel: false,
-      tableData: [],
-      baseSitem: {},
-      isDetail: false,
-      modelId: 0,
-      queryId: "",
-      status: "",
-      sitem: {},
-      newTime: "",
-      editId: "add",
-      editType: "wait",
-      parmValue: {
-        page: 1,
-        size: 100,
-        zxNo: "",
-        infoNo: "",
-        bidNo: "",
-        projectNo: "",
-        is_own: "1",
-      },
-    };
-  },
-  mounted() {
-    this.initForm();
-  },
-  beforeDestroy() {
-    if (this.timer) {
-      clearInterval(this.timer);
-    }
-  },
-  methods: {
-    async initForm() {
-      this.editType = "wait";
-      const { id } = this.$route.query;
-      this.queryId = id;
-      console.log(this.queryId);
-      this.loading = true;
-
-      await this.initData();
-      await this.searchList();
-
-      this.loading = false;
-    },
-
-    async initData() {
-      const { code, message, data } = await asyncRequest.detail({
-        infoNo: this.queryId,
-      });
-      if (code === 0) {
-        const { status } = data;
-        this.status = status;
-        this.sitem = JSON.parse(JSON.stringify(data));
-
-        const { can } = this.sitem;
-        this.sitem.is_metal = "";
-        this.sitem.can_id_arr = [];
-        this.sitem.can_name = "";
-        let can_name = "",
-          can_id_arr = [],
-          is_metal = false;
-        can.forEach((e, i) => {
-          can_name += i == 0 ? e.name : `_${e.name}`;
-          can_id_arr.push(e.id);
-          if (e.id === "6") {
-            is_metal = true;
-          }
-        });
-        this.sitem.is_metal = is_metal;
-        this.sitem.can_id_arr = can_id_arr;
-        this.sitem.can_name = can_name;
-        this.getNewTime();
-        await this.well_timer();
-      } else if (code >= 100 && code <= 104) {
-        await this.logout();
-      } else {
-        this.$message.warning(message);
-      }
-    },
-    async well_timer() {
-      this.timer = setInterval(async () => {
-        if (this.num !== 0) {
-          this.num--;
-        } else {
-          if (this.timer) {
-            const { code, status, message } = await this.repeat_initData();
-            if (code === 0 && status + '' === "1") {
-              this.num = 60;
-            } else if (code === 0 && status !== "1") {
-              this.status = status;
-              this.clearTime();
-            } else if (code >= 100 && code <= 104) {
-              this.clearTime();
-              await this.logout();
-            } else {
-              this.clearTime();
-              this.$message.warning(message);
-            }
-          }
-        }
-      }, 1000);
-    },
-    clearTime() {
-      if (this.timer) {
-        clearInterval(this.timer);
-        this.num = 0;
-      }
-    },
-    async repeat_initData() {
-      const { code, message, data } = await asyncRequest.detail({
-        infoNo: this.queryId,
-      });
-      const { status } = data;
-      const res = { code, status, message };
-
-      return res;
-    },
-    getNewTime() {
-      this.newTime = new Date().valueOf();
-    },
-    openModal(bidNo, type) {
-      const { id } = this.$route.query;
-      this.queryId = id;
-      this.editId = bidNo;
-      this.editType = type;
-      this.getNewTime();
-    },
-    // 刷新表格
-    async searchList() {
-      this.loading = true;
-      this.parmValue.infoNo = this.queryId;
-
-      const { code, data, message } = await asyncRequest.good_list(
-        this.parmValue
-      );
-      if (code === 0) {
-        const { list } = data;
-        this.tableData = list;
-      } else if (code >= 100 && code <= 104) {
-        await this.logout();
-      } else {
-        this.tableData = [];
-      }
-      this.loading = false;
-    },
-  },
-};
-</script>
-   <style lang="scss" scoped>
-@import "~@/styles/mixin.scss";
-.workbenchdetail {
-  //
-  position: relative;
-  width: 100%;
-  height: calc(100vh - 50px);
-  box-sizing: border-box;
-  overflow: hidden;
-
-  .page-main {
-    position: relative;
-    background: #f2f2f2;
-    width: 100%;
-    height: calc(100vh - 50px);
-    box-sizing: border-box;
-    // padding:16px;
-    .left {
-      position: absolute;
-      top: 16px;
-      left: 16px;
-      width: 220px;
-      overflow: hidden;
-      height: calc(100vh - 82px);
-      .left-main {
-        background: rgba(242, 242, 242, 1);
-        width: 100%;
-        overflow-y: scroll;
-        overflow-x: hidden;
-        // background: #fff;
-        height: calc(100vh - 82px);
-        @include scrollBar();
-      }
-    }
-    .p-right {
-      top: 16px;
-      right: 16px;
-      width: calc(100% - 258px);
-      height: calc(100vh - 276px);
-      overflow-y: scroll;
-      background: #fff;
-      overflow-x: hidden;
-      position: absolute;
-      @include scrollBar();
-      .right-mian-wait {
-        .title {
-          height: 45px;
-          font-size: 17px;
-          line-height: 45px;
-          box-sizing: border-box;
-          padding: 0 16px;
-          border-bottom: 1px solid rgba(242, 242, 242, 1);
-        }
-        .main {
-          text-align: center;
-          line-height: 180px;
-        }
-      }
-    }
-    .bottom {
-      position: absolute;
-      bottom: 16px;
-      right: 16px;
-      background: #fff;
-      width: calc(100% - 258px);
-      height: 180px;
-      min-height: 180px;
-      overflow-y: scroll;
-      overflow-x: hidden;
-      @include scrollBar();
-      padding: 16px;
-    }
-    .left-card,
-    .right-card,
-    .bottom-card {
-      background: #fff;
-      font-size: 12px;
-      // padding:16px;
-      line-height: 18px;
-      margin: 8px 0 0 0;
-      &:first-child {
-        margin: 0;
-      }
-      .page-main-title {
-        height: 45px;
-        font-size: 17px;
-        line-height: 45px;
-        box-sizing: border-box;
-        padding: 0 16px;
-        border-bottom: 1px solid rgba(242, 242, 242, 1);
-      }
-      .page-main-ul {
-        padding: 10px 16px 16px 16px;
-        li {
-          float: left;
-          font-size: 12px;
-          line-height: 25px;
-
-          &:nth-child(2n + 1) {
-            width: 60px;
-            text-align: right;
-          }
-          &:nth-child(2n + 2) {
-            width: calc(100% - 60px);
-          }
-        }
-      }
-    }
-  }
-}
-</style>

+ 0 - 473
src/views/supplierWorkbench/workbench/index.vue

@@ -1,473 +0,0 @@
-<template>
-  <div class="workbench">
-    <div class="workbench-main" v-loading="loading">
-      <ul class="clear po-ul">
-        <li class="po-li">
-          <div class="taskTitle color1">竞价单任务</div>
-          <div class="taskList clear">
-            <div
-              class="task-item"
-              v-for="item in list"
-              :key="item"
-              @click="wantTo(item.infoNo)"
-              :style="
-                item.is_all_feed + '' === '0'
-                  ? 'background:#fdf6ec'
-                  : item.is_feed + '' == '1'
-                  ? 'background: #ecf5ff'
-                  : 'background: #fff'
-              "
-            >
-              <ul class="fl item-ul">
-                <li class="fl item-li">
-                  <span class="label">任务编号:</span>
-                  <span class="label-main">{{ item.infoNo }}</span>
-                </li>
-                <li class="fl item-li">
-                  <span class="label">截止时间:</span>
-                  <span class="label-main">{{ item.endtime }}</span>
-                </li>
-                <li class="fl item-li">
-                  <span class="label">商品分类:</span>
-                  <span class="label-main">{{ item.cat_name }}</span>
-                </li>
-                <li class="fl item-li">
-                  <span class="label">商品品牌:</span>
-                  <span class="label-main">{{ item.brand_name }}</span>
-                </li>
-                <li class="fl item-li">
-                  <span class="label">商品名称:</span>
-                  <span class="label-main">
-                    <img
-                      @click="imgclick"
-                      v-if="item.good_img"
-                      class="hover"
-                      v-viewer
-                      style="width: 20px; height: 20px"
-                      :src="item.good_img"
-                      alt=""
-                    />
-                    {{ item.good_name }}</span
-                  >
-                </li>
-                <li class="fl item-li">
-                  <span class="label">商品预算:</span>
-                  <span class="label-main">
-                    {{ item.original_price }}元/{{ item.num }}{{ unit }}</span
-                  >
-                </li>
-              </ul>
-            </div>
-            <div class="no-data">暂无数据!</div>
-          </div>
-        </li>
-
-        <!-- <li class="po-li">
-          <div class="taskTitle color2">客户指定商品任务</div>
-          <div class="taskList">
-            <div
-              class="task-item"
-              v-for="item in list1"
-              :key="item"
-              @click="
-                routeGoto('workbenchDetail', { id: 'INF2203151428199103' })
-              "
-            >
-              {{ item }}
-            </div>
-            <div class="no-data">暂无数据!</div>
-          </div>
-        </li> -->
-      </ul>
-    </div>
-    <!-- 弹窗 新增/修改 -->
-    <add-edit
-      :id="modelId"
-      :show-model="showModel"
-      :sitem="sitem"
-      @refresh="searchList"
-      @cancel="showModel = false"
-    />
-  </div>
-</template>
-<script>
-import asyncRequest from "@/apis/service/purchaseIn/workbench";
-import roleLevel from "@/assets/js/roleLevel";
-import mixinPage from "@/mixins/elPaginationHandle";
-import { mapGetters } from "vuex";
-import resToken from "@/mixins/resToken";
-import companyHelper from "@/mixins/companyHelper";
-export default {
-  name: "supplierWorkbench",
-  mixins: [mixinPage, resToken, companyHelper],
-  computed: {
-    //组件SIZE设置
-    ...mapGetters(["tablebtnSize", "searchSize", "size"]),
-    powers() {
-      const { btnList } = this.$store.getters
-      const tran = btnList.find((i) => i.menu_route == "supplierWorkbench") || {};
-      const { action } = tran ?? {};
-      return action ?? [];
-    },
-  },
-  data() {
-    return {
-      num: 60,
-      timer: null,
-      roleLevel: roleLevel,
-      loading: false,
-      showModel: false,
-      modelId: "000",
-      sitem: {},
-      list1: [],
-      list: [],
-      parmValue: {
-        page: 1, // 页码
-        size: 1000, // 每页显示条数
-        status: "1",
-      },
-      // 状态
-      statusOptions: [
-        { id: "0", label: "禁用" },
-        { id: "1", label: "启用" },
-      ],
-      // 表格 - 数据
-      tableData: [],
-      // 表格 - 参数
-      table: {
-        stripe: true,
-        border: true,
-        _defaultHeader_: ["setcol"],
-      },
-      // 表格 - 分页
-      pageInfo: {
-        size: 15,
-        curr: 1,
-        total: 0,
-      },
-      // 表格 - 列参数
-      columns: [
-        {
-          prop: "id",
-          label: "ID",
-        },
-        {
-          prop: "workbench",
-          label: "活动名称",
-        },
-        {
-          prop: "status",
-          label: "状态",
-          sortable: true,
-          _slot_: "status",
-        },
-        {
-          prop: "creater",
-          label: "创建人",
-        },
-        {
-          prop: "addtime",
-          label: "创建时间",
-          sortable: true,
-        },
-        {
-          prop: "",
-          label: "操作",
-          fixed: "right",
-          _noset_: true,
-          _slot_: "operation",
-        },
-      ],
-    };
-  },
-  mounted() {
-    this.searchList(true);
-  },
-  beforeDestroy() {
-    if (this.timer) {
-      clearInterval(this.timer);
-    }
-  },
-  methods: {
-    wantTo(infoNo) {
-      // if (this.powers.some((i) => i == "007")) {
-        this.routeGoto("workbenchDetail", { id: infoNo });
-      // }
-    },
-    async well_timer() {
-      this.timer = setInterval(async () => {
-        if (this.num !== 0) {
-          this.num--;
-        } else {
-          if (this.timer) {
-            await this.searchList();
-            this.num = 60;
-          } else {
-            this.clearTime();
-          }
-        }
-      }, 1000);
-    },
-    restSearch() {
-      // 表格 - 分页
-      this.pageInfo = {
-        size: 1000,
-        curr: 1,
-        total: 0,
-      };
-      this.parmValue = {
-        page: 1, // 页码
-        size: 15, // 每页显示条数
-        status: "1",
-      };
-      this.searchList();
-    },
-    // 新建/编辑/详情
-    openModal(row, type) {
-      this.sitem = row;
-      this.modelId = type;
-      this.showModel = true;
-    },
-    // 时间
-    async handleTime(e) {
-      this.parmValue.starttime = e.startTime || "";
-      this.parmValue.endtime = e.endTime || "";
-      if (
-        (this.parmValue.starttime !== "" && this.parmValue.endtime !== "") ||
-        (this.parmValue.starttime === "" && this.parmValue.endtime === "")
-      ) {
-        this.pageInfo.curr = 1;
-        this.parmValue.page = 1;
-        await this.searchList();
-      }
-    },
-    /**
-     * 启用/禁用
-     * @param {String} id id
-     * @param {String} status 0-禁用 1-启用
-     */
-    async changeStatus(id, status) {
-      await this.$confirm(`确定要改为${status + '' === "1" ? "禁用" : "启用"}?`, {
-        confirmButtonText: "确定",
-        cancelButtonText: "取消",
-        type: "warning",
-      })
-        .then(async () => {
-          this.loading = true;
-          const model = {
-            id: id,
-            status: status + '' === "1" ? "0" : "1",
-          };
-          const res = await asyncRequest.status(model);
-          if (res && res.code === 0) {
-            this.loading = false;
-            this.$notify.success({
-              title: "状态修改成功!",
-              message: "",
-            });
-            await this.searchList();
-          } else if (res && res.code >= 100 && res.code <= 104) {
-            await this.logout();
-          } else {
-            this.loading = false;
-            this.$message.warning(res.message);
-          }
-        })
-        .catch(() => {
-          console.log("取消");
-        });
-    },
-
-    imgclick(e) {
-      e.stopPropagation();
-      e.preventDefault();
-    },
-    // 刷新表格
-    async searchList(type) {
-      if (!this.loading) {
-        this.loading = true;
-        const { code, data } = await asyncRequest.list({...this.parmValue, supplierNo: this.currentCompany});
-        if (code === 0) {
-          const { list, count } = data;
-          this.list = list;
-          this.list.map((e) => {
-            e.cat_name = "";
-            if (e.can && e.can.length > 0) {
-              e.can.forEach((a, ai) => {
-                e.cat_name += `${ai !== 0 ? "_" : ""}${a.name}`;
-              });
-            }
-            return e;
-          });
-
-          this.pageInfo.total = Number(count);
-          if (type) {
-            await this.well_timer();
-          }
-        } else if (code >= 100 && code <= 104) {
-          await this.logout();
-        } else {
-          this.list = [];
-          this.pageInfo.total = 0;
-        }
-        this.loading = false;
-      }
-    },
-  },
-};
-</script>
-
-<style lang="scss" scoped>
-@import "~@/styles/mixin.scss";
-.workbench {
-  position: relative;
-  width: 100%;
-  height: calc(100vh - 50px);
-  box-sizing: border-box;
-  background: #f0f2f5;
-  padding: 16px;
-  .workbench-main {
-    position: relative;
-    width: 100%;
-    height: 100%;
-    box-sizing: border-box;
-    ul.po-ul {
-      width: 100%;
-      height: 100%;
-      overflow-y: hidden;
-      box-sizing: border-box;
-      li.po-li {
-        position: relative;
-        height: 100%;
-        width: 100%;
-        border-radius: 5px;
-        overflow: hidden;
-        box-sizing: border-box;
-        // border: 1px solid rgba(121, 121, 121, 1);
-        .task-item {
-          border-bottom: 1px dashed #e6ebf5;
-          line-height: 20px;
-          overflow: hidden;
-          float: left;
-          width: 100%;
-          padding: 10px 12px;
-          text-align: center;
-          font-size: 12px;
-          ul.item-ul {
-            width: 100%;
-            padding: 0;
-            margin: 0;
-
-            li.item-li {
-              width: 100%;
-              padding: 0;
-              margin: 0;
-              .label,
-              .label-main {
-                height: 20px;
-                line-height: 20px;
-                overflow: hidden;
-              }
-              .label {
-                width: 60px;
-                float: left;
-                color: #909499;
-                text-align: left;
-              }
-              .label-main {
-                float: left;
-                width: calc(100% - 60px);
-                text-align: right;
-                color: #454545;
-                img {
-                  display: inline-block;
-                  vertical-align: top;
-                  margin: 0 2px 0 0;
-                }
-              }
-            }
-          }
-          .order {
-            width: 100%;
-          }
-          // &:last-child{
-          //   border: 0;
-          // }
-        }
-        &:first-child {
-          float: left;
-          width: 100%;
-          // margin: 0 2% 0 0;
-          .task-item {
-            width: 20%;
-            &:nth-child(3n + 1) {
-              border-right: 1px dashed #e6ebf5;
-            }
-            &:nth-child(3n + 2) {
-              border-right: 1px dashed #e6ebf5;
-            }
-          }
-          .tast-item-active {
-            width: 20%;
-            background: skyblue;
-            &:nth-child(3n + 1) {
-              border-right: 1px dashed #e6ebf5;
-            }
-            &:nth-child(3n + 2) {
-              border-right: 1px dashed #e6ebf5;
-            }
-          }
-        }
-        // &:last-child {
-        //   margin: 0;
-        //   float: right;
-        //   width: 32%;
-        // }
-        .taskTitle {
-          width: 100%;
-          height: 55px;
-          line-height: 55px;
-          text-align: center;
-          position: absolute;
-          top: 0;
-          left: 0;
-          z-index: 2;
-          // border-bottom: 1px solid rgba(121, 121, 121, 1);
-          &.color1 {
-            background: rgba(250, 205, 145, 1);
-          }
-          &.color2 {
-            background: rgba(202, 249, 130, 1);
-          }
-          // &.color3 {
-          //   background: rgba(129, 211, 248, 1);
-          // }
-          // &.color4 {
-          //   background: rgba(255, 255, 128, 1);
-          // }
-        }
-        .taskList {
-          position: relative;
-          // padding: 0 0 0 5px;
-          margin: 56px 0 0 0;
-          background: #fff;
-
-          height: calc(100% - 56px);
-          width: 100%;
-          overflow-y: scroll;
-          @include scrollBar();
-          .no-data {
-            width: 100%;
-            height: 60px;
-            line-height: 60px;
-            font-size: 14px;
-            float: left;
-            text-align: center;
-            color: rgba(0, 0, 0, 0.65);
-          }
-        }
-      }
-    }
-  }
-}
-</style>

+ 0 - 258
src/views/supplierWorkbench/workbench/ladderPrice.vue

@@ -1,258 +0,0 @@
-<template>
-  <el-dialog
-    :title="title"
-    :center="true"
-    align="left"
-    top="12vh"
-    width="1040px"
-    :close-on-click-modal="false"
-    :visible.sync="showModelThis"
-    @close="closeModel"
-  >
-    <el-card>
-      <el-row :gutter="10">
-        <el-col :span="24">
-          <div
-            v-if="
-              left &&
-                left.header &&
-                left.header.length > 0 &&
-                right &&
-                right.header &&
-                right.header.length > 0
-            "
-          >
-            <div class="list-table clearfix">
-              <div class="left" :style="{ width: lang }">
-                <div class="header">
-                  <div
-                    v-for="(lhead, lhi) in left.header"
-                    :key="'lhead' + lhi"
-                    class="header-item"
-                  >
-                    {{ lhead.spec_name }}
-                  </div>
-                </div>
-                <div
-                  v-if="left.spec && left.spec.length > 0"
-                  class="header-body"
-                >
-                  <div
-                    v-for="(lhr, lhri) in left.spec"
-                    :key="'lheadrow' + lhri"
-                    class="header-body-row"
-                  >
-                    <div
-                      v-for="(lhc, lhci) in lhr"
-                      :key="'lheadcol' + lhci"
-                      class="heder-body-col"
-                    >
-                      {{ lhc.spec_value }}
-                    </div>
-                  </div>
-                </div>
-              </div>
-              <div class="right" :style="{ paddingLeft: lang }">
-                <div class="header">
-                  <div
-                    v-for="(lhr, lhri) in right.header"
-                    :key="'lheadr' + lhri"
-                    class="header-col clearfix"
-                  >
-                    <div class="header-col-jieti clearfix">
-                      <div class="header-col-jieti-title tc clearfix">
-                        阶梯{{ lhri + 1 }}
-                      </div>
-                      <div class="header-col-jieti-main clearfix">
-                        <div class="header-col-item fl tc">{{ lhr.num }}</div>
-                        <div class="header-col-item fl tc">{{ lhr.price }}</div>
-                      </div>
-                    </div>
-                  </div>
-                </div>
-                <div
-                  v-if="right.spec && right.spec.length > 0"
-                  class="right-body"
-                >
-                  <div
-                    v-for="(lbr, lbri) in right.spec"
-                    :key="'lbodyr' + lbri"
-                    class="right-body-col"
-                  >
-                    <div
-                      v-for="(lbritem, lbritemi) in lbr.limit"
-                      :key="'lbritem' + lbritemi"
-                      class="right-body-col-item clearfix"
-                    >
-                      <div class="right-body-col-item-div fl tc">
-                        {{ lbritem.begin_num }}
-                      </div>
-                      <div class="right-body-col-item-div fl tc">
-                        {{ lbritem.shop_price }}
-                      </div>
-                    </div>
-                  </div>
-                </div>
-              </div>
-            </div>
-          </div>
-          <div v-else class="tc">
-            <el-tag type="warning">暂无阶梯价!</el-tag>
-          </div>
-        </el-col>
-      </el-row>
-    </el-card>
-  </el-dialog>
-</template>
-<script>
-export default {
-  name: 'Active',
-  props: ['showModel', 'left', 'right', 'lang'],
-  data() {
-    return {
-      loading: true,
-      title: '商品阶梯价格',
-      showModelThis: this.showModel
-    }
-  },
-  watch: {
-    showModel: function(val) {
-      this.showModelThis = val
-      if (val) {
-        this.initForm()
-      }
-    },
-    showModelThis(val) {
-      if (!val) {
-        this.$emit('cancel')
-      }
-    }
-  },
-  methods: {
-    closeModel(e) {
-      console.log(e)
-      this.showModelThis = false
-    },
-    async initForm() {
-      this.loading = false
-    }
-  }
-}
-</script>
-
-   <style lang="scss" scoped>
-.active {
-  $gBC: #dfe6ec;
-  .list-table {
-    position: relative;
-    width: 100%;
-    border-top: 1px solid $gBC;
-    border-left: 1px solid $gBC;
-    .left {
-      position: absolute;
-      top: 0;
-      left: 0;
-      z-index: 2;
-      background: #fff;
-      .header {
-        width: 100%;
-        display: flex;
-        .header-item {
-          width: 100px;
-          flex: 1;
-          padding: 0 10px;
-          height: 64px;
-          line-height: 64px;
-          border-right: 1px solid $gBC;
-          border-bottom: 1px solid $gBC;
-        }
-      }
-      .header-body {
-        width: 100%;
-        position: relative;
-        .header-body-row {
-          width: 100%;
-          display: flex;
-          .heder-body-col {
-            flex: 1;
-            padding: 0 10px;
-            height: 38px;
-            border-right: 1px solid $gBC;
-            border-bottom: 1px solid $gBC;
-            line-height: 38px;
-          }
-        }
-      }
-    }
-    .right {
-      position: relative;
-      width: 100%;
-      display: block;
-      overflow-x: scroll;
-      .header {
-        width: 100%;
-        display: flex;
-        .header-col {
-          min-width: 220px;
-          flex: 1;
-          height: 64px;
-          line-height: 64px;
-
-          // position: relative;
-          .header-col-jieti {
-            height: 64px;
-            line-height: 64px;
-            // position: relative;
-            width: 100%;
-            .header-col-jieti-title {
-              // position: relative;
-              width: 100%;
-              line-height: 32px;
-              border-right: 1px solid $gBC;
-              border-bottom: 1px solid $gBC;
-              height: 32px;
-            }
-            .header-col-jieti-main {
-              // position: relative;
-              width: 100%;
-              .header-col-item {
-                // position: relative;
-                height: 32px;
-                line-height: 32px;
-                width: 50%;
-                border-right: 1px solid $gBC;
-                border-bottom: 1px solid $gBC;
-              }
-            }
-          }
-        }
-      }
-      .right-body {
-        position: relative;
-        .right-body-col {
-          position: relative;
-          width: 100%;
-          display: flex;
-          .right-body-col-item {
-            min-width: 220px;
-            flex: 1;
-
-            position: relative;
-            overflow: hidden;
-            .right-body-col-item-div {
-              position: relative;
-              height: 38px;
-              line-height: 38px;
-              width: 50%;
-              padding: 0 10px;
-              border-right: 1px solid $gBC;
-              border-bottom: 1px solid $gBC;
-            }
-          }
-        }
-      }
-    }
-  }
-}
-</style>
-

+ 0 - 0
src/views/supplierWorkbench/workbench/招标工作台-供应商


Nem az összes módosított fájl került megjelenítésre, mert túl sok fájl változott