zouyu
2023-10-11 ede9169afeeb21ff2d8113f02b6f2492ce83ae57
src/views/plan/customerorder/sample-customerorder-form.vue
@@ -68,7 +68,9 @@
          </el-col>
          <el-col :span="6">
            <el-form-item label="业务员" prop="salesMan">
              <el-input v-model="dataForm.salesMan" placeholder=""></el-input>
              <el-select v-model="dataForm.salesMan" style="width:100%">
                <el-option v-for="(item,index) in staffOptions" :key="index" :value="item.staff_no" :label="item.staffName"/>
              </el-select>
            </el-form-item>
          </el-col>
          <el-col :span="6">
@@ -114,6 +116,19 @@
            <el-form-item label="工厂下单日期" prop="factoryPlaceOrderDate">
              <el-date-picker
                v-model="dataForm.factoryPlaceOrderDate"
                style="width: 100%"
                type="datetime"
                value-format="yyyy-MM-dd HH:mm:ss"
              >
              </el-date-picker>
            </el-form-item>
          </el-col>
        </el-row>
        <el-row>
          <el-col :span="6">
            <el-form-item label="交货日期" prop="deliveryDate">
              <el-date-picker
                v-model="dataForm.deliveryDate"
                style="width: 100%"
                type="datetime"
                value-format="yyyy-MM-dd HH:mm:ss"
@@ -231,26 +246,6 @@
          ></el-input>
        </el-col>
        <el-col :span="2">
          <span>印字类型</span>
        </el-col>
        <el-col :span="6">
          <el-input
            v-model="dataForm.customerOrder.printType"
            placeholder=""
          ></el-input>
        </el-col>
      </el-row>
      <el-row :gutter="20">
        <el-col :span="2">
          <span>印字要求</span>
        </el-col>
        <el-col :span="6">
          <el-input
            v-model="dataForm.customerOrder.printingRequirements"
            placeholder=""
          ></el-input>
        </el-col>
        <el-col :span="2">
          <span>包装要求</span>
        </el-col>
        <el-col :span="6">
@@ -259,6 +254,8 @@
            placeholder=""
          ></el-input>
        </el-col>
      </el-row>
      <el-row :gutter="20">
        <el-col :span="2">
          <span>质量要求</span>
        </el-col>
@@ -268,8 +265,6 @@
            placeholder=""
          ></el-input>
        </el-col>
      </el-row>
      <el-row :gutter="20">
        <el-col :span="2">
          <span>生产需求说明</span>
        </el-col>
@@ -288,6 +283,8 @@
            placeholder=""
          ></el-input>
        </el-col>
      </el-row>
      <el-row :gutter="20">
        <el-col :span="2">
          <span>收货地址</span>
        </el-col>
@@ -297,16 +294,13 @@
            placeholder=""
          ></el-input>
        </el-col>
      </el-row>
      <el-row :gutter="20">
        <el-col :span="2">
          <span>业务员</span>
        </el-col>
        <el-col :span="6">
          <el-input
            v-model="dataForm.customerOrder.salesmanName"
            placeholder=""
          ></el-input>
          <el-select v-model="dataForm.customerOrder.salesmanName" style="width:100%">
                <el-option v-for="(item,index) in staffOptions" :key="index" :value="item.staff_no" :label="item.staffName"/>
          </el-select>
        </el-col>
        <el-col :span="2">
          <span>盘长要求</span>
@@ -317,12 +311,23 @@
            placeholder=""
          ></el-input>
        </el-col>
      </el-row>
      <el-row :gutter="20">
        <el-col :span="2">
          <span>备注</span>
        </el-col>
        <el-col :span="6">
          <el-input
            v-model="dataForm.customerOrder.remark"
            placeholder=""
          ></el-input>
        </el-col>
        <el-col :span="2">
          <span>产品类型</span>
        </el-col>
        <el-col :span="6">
          <el-input
            v-model="dataForm.customerOrder.productType"
            placeholder=""
          ></el-input>
        </el-col>
@@ -370,6 +375,7 @@
import { remote } from '@/api/admin/dict'
import PartDialog from '@/views/common/part.vue'
import { validateSixDecimal } from '@/util/validate'
import { chooseStaff } from '@/api/admin/productType'
export default {
  components: {
@@ -377,6 +383,7 @@
  },
  data() {
    return {
      staffOptions: [],
      title: '',
      isFullScreen: false,
      visible: false,
@@ -396,6 +403,7 @@
        returnStatus: null,
        placeOrderDate: null,
        factoryPlaceOrderDate: null,
        deliveryDate: null,
        customerOrder: {
          partNo: null,
          unit: null,
@@ -414,7 +422,8 @@
          shippingAddress: null,
          salesmanName: null,
          lengthRequirement: null,
          remark: null
          remark: null,
          productType: null
        }
      },
      dataRule: {},
@@ -425,8 +434,14 @@
  mounted: function() {
    this.getDicUnit('unit') // 获取单位
    this.getManufactureAttrs('manufacture_attr_type')
    this.getStaffOptions();
  },
  methods: {
    getStaffOptions(){
      chooseStaff().then((response)=>{
        this.staffOptions = response.data.data
      })
    },
    init(id) {
      this.initDataForm()
      this.visible = true
@@ -448,6 +463,7 @@
      this.dataForm.returnStatus = null
      this.dataForm.placeOrderDate = null
      this.dataForm.factoryPlaceOrderDate = null
      this.dataForm.deliveryDate = null
      this.dataForm.customerOrder.partNo = null
      this.dataForm.customerOrder.unit = null
      this.dataForm.customerOrder.buyQtyDue = null