Selaa lähdekoodia

委托查询前端

110 2 vuotta sitten
vanhempi
commit
eb5837a6ae

+ 13 - 7
itdmWeb/src/views/module-iTDM/weituochaxun/ItdmWeituoYangpinList.vue

@@ -68,21 +68,21 @@
         </template>
 
         <span slot="action" slot-scope="text, record">
-          <a @click="handleEdit(record)">编辑</a>
+          <!-- <a @click="handleEdit(record)">编辑</a> -->
 
           <a-divider type="vertical" />
           <a-dropdown>
-            <a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
-            <a-menu slot="overlay">
+            <!-- <a class="ant-dropdown-link">更多 <a-icon type="down" /></a>
+            <a-menu slot="overlay"> -->
               <a-menu-item>
                 <a @click="handleDetail(record)">详情</a>
               </a-menu-item>
-              <a-menu-item>
+              <!-- <a-menu-item>
                 <a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
                   <a>删除</a>
                 </a-popconfirm>
               </a-menu-item>
-            </a-menu>
+            </a-menu> -->
           </a-dropdown>
         </span>
 
@@ -122,6 +122,11 @@
             }
           },
           {
+            title:'委托单位名称',
+            align:"center",
+            dataIndex: 'weituoClient'
+          },
+          {
             title:'委托单id',
             align:"center",
             dataIndex: 'weituoId'
@@ -156,12 +161,12 @@
             dataIndex: 'action',
             align:"center",
             fixed:"right",
-            width:147,
+            width:120,
             scopedSlots: { customRender: 'action' }
           }
         ],
         url: {
-          list: "/itdmWeituoChaXun/itdmWeituoYangpin/itdm/weituo",
+          list: "/weituo/ItdmWeituochaxun/list",
           delete: "/itdmWeituoChaXun/itdmWeituoYangpin/delete",
           deleteBatch: "/itdmWeituoChaXun/itdmWeituoYangpin/deleteBatch",
           exportXlsUrl: "/itdmWeituoChaXun/itdmWeituoYangpin/exportXls",
@@ -186,6 +191,7 @@
       getSuperFieldList(){
         let fieldList=[];
         fieldList.push({type:'string',value:'weituoId',text:'委托单id',dictCode:''})
+        fieldList.push({type:'string',value:'weituoClient',text:'委托单位名称',dictCode:''})
         fieldList.push({type:'string',value:'sampleName',text:'样品名称',dictCode:''})
         fieldList.push({type:'string',value:'sampleModelSpecification',text:'样品规格/型号',dictCode:''})
         fieldList.push({type:'string',value:'sampleQuantities',text:'样品数量',dictCode:''})

+ 230 - 91
itdmWeb/src/views/module-iTDM/weituochaxun/modules/ItdmWeituoYangpinForm.vue

@@ -29,10 +29,149 @@
             </a-form-model-item>
           </a-col>
           <a-col :span="24">
-            <a-form-model-item label="样品编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="sampleCode">
-              <a-input v-model="model.sampleCode" placeholder="请输入样品编号"  ></a-input>
+            <a-form-model-item label="创建人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="createBy">
+              <a-input v-model="model.createBy" placeholder="请输入创建人"  ></a-input>
             </a-form-model-item>
           </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="创建日期" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="createTime">
+              <a-input v-model="model.createTime" placeholder="请输入创建日期"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="更新人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="updateBy">
+              <a-input v-model="model.updateBy" placeholder="请输入更新人"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="更新日期" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="updateTime">
+              <a-input v-model="model.updateTime" placeholder="请输入更新日期"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="所属部门" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="sysOrgCode">
+              <a-input v-model="model.sysOrgCode" placeholder="请输入所属部门"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="委托编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="weituoNo">
+              <a-input v-model="model.weituoNo" placeholder="请输入委托编号"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="委托单位名称" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="weituoClient">
+              <a-input v-model="model.weituoClient" placeholder="请输入委托单位名称"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="委托单位地址" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="weituoAddress">
+              <a-input v-model="model.weituoAddress" placeholder="请输入委托单位地址"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="委托联系人" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="weituoLxr">
+              <a-input v-model="model.weituoLxr" placeholder="请输入委托联系人"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="委托电话" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="weituoPhone">
+              <a-input v-model="model.weituoPhone" placeholder="请输入委托电话"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="委托邮箱" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="weituoEmail">
+              <a-input v-model="model.weituoEmail" placeholder="请输入委托邮箱"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="报告用章" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="bgyz">
+              <a-input v-model="model.bgyz" placeholder="请输入报告用章"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="报告形式" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="bgxs">
+              <a-input v-model="model.bgxs" placeholder="请输入报告形式"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="特殊要求" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="teshuyaoqiu">
+              <a-input v-model="model.teshuyaoqiu" placeholder="请输入特殊要求"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="审核状态" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="shenheStatus">
+              <a-input v-model="model.shenheStatus" placeholder="请输入审核状态"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="审核错误原因" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="shenheMsg">
+              <a-input v-model="model.shenheMsg" placeholder="请输入审核错误原因"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="审核时间" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="shenheTime">
+              <a-input v-model="model.shenheTime" placeholder="请输入审核时间"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="试验条件文件地址" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="tiaojianFile">
+              <a-input v-model="model.tiaojianFile" placeholder="请输入试验条件文件地址"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="样品id" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="sampleCode">
+              <a-input v-model="model.sampleCode" placeholder="请输入样品id"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="样品编号" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="yangpinId">
+              <a-input v-model="model.yangpinId" placeholder="请输入样品编号"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="检测项目" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="testItems">
+              <a-input v-model="model.testItems" placeholder="请输入检测项目"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="检测依据" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="standardRequirement">
+              <a-input v-model="model.standardRequirement" placeholder="请输入检测依据"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+          <a-col :span="24">
+            <a-form-model-item label="判定依据" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="judgementBasis">
+              <a-input v-model="model.judgementBasis" placeholder="请输入判定依据"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+          <a-col :span="24">
+            <a-form-model-item label="备注" :labelCol="labelCol" :wrapperCol="wrapperCol" prop="judgementBasis">
+              <a-input v-model="model.judgementBasis" placeholder="请输入beizhu"  ></a-input>
+            </a-form-model-item>
+          </a-col>
+
+
         </a-row>
       </a-form-model>
     </j-form-container>
@@ -41,101 +180,101 @@
 
 <script>
 
-  import { httpAction, getAction } from '@/api/manage'
-  import { validateDuplicateValue } from '@/utils/util'
+import { httpAction, getAction } from '@/api/manage'
+import { validateDuplicateValue } from '@/utils/util'
 
-  export default {
-    name: 'ItdmWeituoYangpinForm',
-    components: {
-    },
-    props: {
-      //表单禁用
-      disabled: {
-        type: Boolean,
-        default: false,
-        required: false
-      }
-    },
-    data () {
-      return {
-        model:{
-         },
-        labelCol: {
-          xs: { span: 24 },
-          sm: { span: 5 },
-        },
-        wrapperCol: {
-          xs: { span: 24 },
-          sm: { span: 16 },
-        },
-        confirmLoading: false,
-        validatorRules: {
-           sampleName: [
-              { required: true, message: '请输入样品名称!'},
-           ],
-           sampleModelSpecification: [
-              { required: true, message: '请输入样品规格/型号!'},
-           ],
-           sampleQuantities: [
-              { required: true, message: '请输入样品数量!'},
-           ],
-           sampleManufacturer: [
-              { required: true, message: '请输入生产厂家!'},
-           ],
-        },
-        url: {
-          add: "/itdmWeituoChaXun/itdmWeituoYangpin/add",
-          edit: "/itdmWeituoChaXun/itdmWeituoYangpin/edit",
-          queryById: "/itdmWeituoChaXun/itdmWeituoYangpin/queryById"
-        }
+export default {
+  name: 'ItdmWeituoYangpinForm',
+  components: {
+  },
+  props: {
+    //表单禁用
+    disabled: {
+      type: Boolean,
+      default: false,
+      required: false
+    }
+  },
+  data () {
+    return {
+      model:{
+      },
+      labelCol: {
+        xs: { span: 24 },
+        sm: { span: 5 },
+      },
+      wrapperCol: {
+        xs: { span: 24 },
+        sm: { span: 16 },
+      },
+      confirmLoading: false,
+      validatorRules: {
+        sampleName: [
+          { required: true, message: '请输入样品名称!'},
+        ],
+        sampleModelSpecification: [
+          { required: true, message: '请输入样品规格/型号!'},
+        ],
+        sampleQuantities: [
+          { required: true, message: '请输入样品数量!'},
+        ],
+        sampleManufacturer: [
+          { required: true, message: '请输入生产厂家!'},
+        ],
+      },
+      url: {
+        add: "/itdmWeituoChaXun/itdmWeituoYangpin/add",
+        edit: "/itdmWeituoChaXun/itdmWeituoYangpin/edit",
+        queryById: "/itdmWeituoChaXun/itdmWeituoYangpin/queryById"
       }
+    }
+  },
+  computed: {
+    formDisabled(){
+      return this.disabled
     },
-    computed: {
-      formDisabled(){
-        return this.disabled
-      },
+  },
+  created () {
+    //备份model原始值
+    this.modelDefault = JSON.parse(JSON.stringify(this.model));
+  },
+  methods: {
+    add () {
+      this.edit(this.modelDefault);
     },
-    created () {
-       //备份model原始值
-      this.modelDefault = JSON.parse(JSON.stringify(this.model));
+    edit (record) {
+      this.model = Object.assign({}, record);
+      this.visible = true;
     },
-    methods: {
-      add () {
-        this.edit(this.modelDefault);
-      },
-      edit (record) {
-        this.model = Object.assign({}, record);
-        this.visible = true;
-      },
-      submitForm () {
-        const that = this;
-        // 触发表单验证
-        this.$refs.form.validate(valid => {
-          if (valid) {
-            that.confirmLoading = true;
-            let httpurl = '';
-            let method = '';
-            if(!this.model.id){
-              httpurl+=this.url.add;
-              method = 'post';
+    submitForm () {
+      const that = this;
+      // 触发表单验证
+      this.$refs.form.validate(valid => {
+        if (valid) {
+          that.confirmLoading = true;
+          let httpurl = '';
+          let method = '';
+          if(!this.model.id){
+            httpurl+=this.url.add;
+            method = 'post';
+          }else{
+            httpurl+=this.url.edit;
+            method = 'put';
+          }
+          httpAction(httpurl,this.model,method).then((res)=>{
+            if(res.success){
+              that.$message.success(res.message);
+              that.$emit('ok');
             }else{
-              httpurl+=this.url.edit;
-               method = 'put';
+              that.$message.warning(res.message);
             }
-            httpAction(httpurl,this.model,method).then((res)=>{
-              if(res.success){
-                that.$message.success(res.message);
-                that.$emit('ok');
-              }else{
-                that.$message.warning(res.message);
-              }
-            }).finally(() => {
-              that.confirmLoading = false;
-            })
-          }
-         
-        })
-      },
-    }
+          }).finally(() => {
+            that.confirmLoading = false;
+          })
+        }
+
+      })
+    },
   }
+}
 </script>