瀏覽代碼

Merge branch '3.3.1-dspf' into 3.3.2-dzxxp

dedsudiyu 1 年之前
父節點
當前提交
103405ba3d

+ 241 - 241
src/views/medicUniversity-3_1/chemicalManagement/chemicalLibrary/ChemicalInfo/addPage.vue

@@ -30,19 +30,19 @@
             </el-select>
           </el-form-item>
           <!--<el-form-item label="属性:" prop="classifyAttribute" label-width="70px">-->
-            <!--<el-select-->
-              <!--style="width:250px;"-->
-              <!--v-model="formData.classifyAttribute"-->
-              <!--multiple-->
-              <!--collapse-tags-->
-              <!--placeholder="请选择属性">-->
-              <!--<el-option-->
-                <!--v-for="item in optionsListTwo"-->
-                <!--:key="item.dictValue"-->
-                <!--:label="item.dictLabel"-->
-                <!--:value="item.dictValue">-->
-              <!--</el-option>-->
-            <!--</el-select>-->
+          <!--<el-select-->
+          <!--style="width:250px;"-->
+          <!--v-model="formData.classifyAttribute"-->
+          <!--multiple-->
+          <!--collapse-tags-->
+          <!--placeholder="请选择属性">-->
+          <!--<el-option-->
+          <!--v-for="item in optionsListTwo"-->
+          <!--:key="item.dictValue"-->
+          <!--:label="item.dictLabel"-->
+          <!--:value="item.dictValue">-->
+          <!--</el-option>-->
+          <!--</el-select>-->
           <!--</el-form-item>-->
           <el-form-item class="criticality-input" label="临界量(T):" prop="criticality" label-width="100px" v-if="formData.chemicalClassify == 1">
             <el-input-number
@@ -67,12 +67,12 @@
           </el-form-item>
         </div>
         <!--<div class="form-min-box">-->
-          <!--<el-form-item label="标签类型:" prop="labelType" style="width:500px;">-->
-            <!--<el-radio-group v-model="formData.labelType">-->
-              <!--<el-radio :label="1">RFID</el-radio>-->
-              <!--<el-radio :label="2">二维码</el-radio>-->
-            <!--</el-radio-group>-->
-          <!--</el-form-item>-->
+        <!--<el-form-item label="标签类型:" prop="labelType" style="width:500px;">-->
+        <!--<el-radio-group v-model="formData.labelType">-->
+        <!--<el-radio :label="1">RFID</el-radio>-->
+        <!--<el-radio :label="2">二维码</el-radio>-->
+        <!--</el-radio-group>-->
+        <!--</el-form-item>-->
         <!--</div>-->
         <div class="form-min-box">
           <el-form-item label="计量方式:" prop="measuringMethod">
@@ -99,12 +99,12 @@
           </el-form-item>
         </div>
         <!--<div class="form-min-box">-->
-          <!--<el-form-item label="检验方式:" prop="verification">-->
-            <!--<el-select v-model="formData.verification" clearable placeholder="请选择检验方式" style="width:500px;">-->
-              <!--<el-option label="单人验证" :value="1"></el-option>-->
-              <!--<el-option label="双人双卡" :value="2"></el-option>-->
-            <!--</el-select>-->
-          <!--</el-form-item>-->
+        <!--<el-form-item label="检验方式:" prop="verification">-->
+        <!--<el-select v-model="formData.verification" clearable placeholder="请选择检验方式" style="width:500px;">-->
+        <!--<el-option label="单人验证" :value="1"></el-option>-->
+        <!--<el-option label="双人双卡" :value="2"></el-option>-->
+        <!--</el-select>-->
+        <!--</el-form-item>-->
         <!--</div>-->
         <div class="form-min-box">
           <el-form-item label="别名:" prop="anotherName">
@@ -180,252 +180,252 @@
 </template>
 
 <script>
-  import { classifyList,addHxpChemical,putHxpChemical } from "@/api/medicUniversity-3_1/index";
-  export default {
-    name: "addPage",
-    props:{
-      addPropsData:{},
-    },
-    data() {
-      return {
-        rules:{
-          chemicalName:[
-            { required: true, message: '请输入化学品名', trigger: 'blur' },
-            { required: true, message: "请输入化学品名", validator: this.spaceJudgment, trigger: "blur" }
-          ],
-          chemicalClassify:[
-            { required: true, message: '请选择化学品分类', trigger: 'blur' },
-            { required: true, message: "请选择化学品分类", validator: this.spaceJudgment, trigger: "blur" }
-          ],
-          chemicalShape:[
-            { required: true, message: '请选择形态', trigger: 'blur' },
-            { required: true, message: "请选择形态", validator: this.spaceJudgment, trigger: "blur" }
-          ],
-          // labelType:[
-          //   { required: true, message: '请选择标签类型', trigger: 'blur' },
-          //   { required: true, message: "请选择标签类型", validator: this.spaceJudgment, trigger: "blur" }
-          // ],
-          measuringMethod:[
-            { required: true, message: '请选择计量方式', trigger: 'blur' },
-            { required: true, message: "请选择计量方式", validator: this.spaceJudgment, trigger: "blur" }
-          ],
-          chemicalUnit:[
-            { required: true, message: '请选择单位', trigger: 'blur' },
-            { required: true, message: "请选择单位", validator: this.spaceJudgment, trigger: "blur" }
-          ],
-          verification:[
-            { required: true, message: '请选择检验方式', trigger: 'blur' },
-            { required: true, message: "请选择检验方式", validator: this.spaceJudgment, trigger: "blur" }
-          ],
-        },
-        formData:{
-          // labelType:1,
-          classifyAttribute:[],
-        },
-        //化学品形态
-        optionsList:[],
-        //化学品分类列表
-        optionsListOne:[],
-        //属性列表
-        optionsListTwo:[],
-        //化学品计量单位
-        chemicalsMeasuringUnit:[],
-      };
-    },
-    created() {
-    },
-    mounted(){
-      this.getDicts("chemicals_measuring_unit").then((response) => {
-        this.chemicalsMeasuringUnit = response.data;
-      });
-      this.getDicts("chemical_shape").then(response => {
-        this.optionsList = response.data;
-      })
-      this.getDicts("hxp_classifyattribute").then(response => {
-        this.optionsListTwo = response.data;
-      })
-      this.classifyList();
-      if(this.addPropsData.id){
-        this.formData = JSON.parse(JSON.stringify(this.addPropsData));
-        this.formData.chemicalShape = this.addPropsData.chemicalShape+''
-        if(this.formData.classifyAttribute){
-          this.formData.classifyAttribute = this.formData.classifyAttribute.split(",");
-        }
+import { classifyList,addHxpChemical,putHxpChemical } from "@/api/medicUniversity-3_1/index";
+export default {
+  name: "addPage",
+  props:{
+    addPropsData:{},
+  },
+  data() {
+    return {
+      rules:{
+        chemicalName:[
+          { required: true, message: '请输入化学品名', trigger: 'blur' },
+          { required: true, message: "请输入化学品名", validator: this.spaceJudgment, trigger: "blur" }
+        ],
+        chemicalClassify:[
+          { required: true, message: '请选择化学品分类', trigger: 'blur' },
+          { required: true, message: "请选择化学品分类", validator: this.spaceJudgment, trigger: "blur" }
+        ],
+        chemicalShape:[
+          { required: true, message: '请选择形态', trigger: 'blur' },
+          { required: true, message: "请选择形态", validator: this.spaceJudgment, trigger: "blur" }
+        ],
+        // labelType:[
+        //   { required: true, message: '请选择标签类型', trigger: 'blur' },
+        //   { required: true, message: "请选择标签类型", validator: this.spaceJudgment, trigger: "blur" }
+        // ],
+        measuringMethod:[
+          { required: true, message: '请选择计量方式', trigger: 'blur' },
+          { required: true, message: "请选择计量方式", validator: this.spaceJudgment, trigger: "blur" }
+        ],
+        chemicalUnit:[
+          { required: true, message: '请选择单位', trigger: 'blur' },
+          { required: true, message: "请选择单位", validator: this.spaceJudgment, trigger: "blur" }
+        ],
+        verification:[
+          { required: true, message: '请选择检验方式', trigger: 'blur' },
+          { required: true, message: "请选择检验方式", validator: this.spaceJudgment, trigger: "blur" }
+        ],
+      },
+      formData:{
+        // labelType:1,
+        classifyAttribute:[],
+      },
+      //化学品形态
+      optionsList:[],
+      //化学品分类列表
+      optionsListOne:[],
+      //属性列表
+      optionsListTwo:[],
+      //化学品计量单位
+      chemicalsMeasuringUnit:[],
+    };
+  },
+  created() {
+  },
+  mounted(){
+    this.getDicts("chemicals_measuring_unit").then((response) => {
+      this.chemicalsMeasuringUnit = response.data;
+    });
+    this.getDicts("chemical_shape").then(response => {
+      this.optionsList = response.data;
+    })
+    this.getDicts("hxp_classifyattribute").then(response => {
+      this.optionsListTwo = response.data;
+    })
+    this.classifyList();
+    if(this.addPropsData.id){
+      this.formData = JSON.parse(JSON.stringify(this.addPropsData));
+      this.formData.chemicalShape = this.addPropsData.chemicalShape+''
+      if(this.formData.classifyAttribute){
+        this.formData.classifyAttribute = this.formData.classifyAttribute.split(",");
       }
-    },
-    methods: {
-      //提交接口
-      upData(){
-        let self = this;
-        console.log('this.addPropsData',this.addPropsData);
-        this.$refs["form"].validate(valid => {
-          if (valid) {
-            console.log('this.addPropsData',this.addPropsData);
-            if(this.addPropsData.id){
-              //编辑
-              if(this.formData.chemicalClassify != 1){
+    }
+  },
+  methods: {
+    //提交接口
+    upData(){
+      let self = this;
+      console.log('this.addPropsData',this.addPropsData);
+      this.$refs["form"].validate(valid => {
+        if (valid) {
+          console.log('this.addPropsData',this.addPropsData);
+          if(this.addPropsData.id){
+            //编辑
+            if(this.formData.chemicalClassify != 1){
+              this.formData.criticality = 0;
+            }else{
+              if(!this.formData.criticality){
                 this.formData.criticality = 0;
-              }else{
-                if(!this.formData.criticality){
-                  this.formData.criticality = 0;
-                }
               }
-              this.formData.classifyAttribute = this.formData.classifyAttribute+'';
-              putHxpChemical(this.formData).then(response => {
-                if(response.code == 200){
-                  this.msgSuccess(response.msg);
-                  this.$parent.pageToggle(1,'get');
-                }
-              });
+            }
+            this.formData.classifyAttribute = this.formData.classifyAttribute+'';
+            putHxpChemical(this.formData).then(response => {
+              if(response.code == 200){
+                this.msgSuccess(response.msg);
+                this.$parent.pageToggle(1,'get');
+              }
+            });
+          }else{
+            //新增
+            if(this.formData.chemicalClassify != 1){
+              this.formData.criticality = 0;
             }else{
-              //新增
-              if(this.formData.chemicalClassify != 1){
+              if(!this.formData.criticality){
                 this.formData.criticality = 0;
-              }else{
-                if(!this.formData.criticality){
-                  this.formData.criticality = 0;
-                }
               }
-              this.formData.classifyAttribute = this.formData.classifyAttribute+'';
-              addHxpChemical(this.formData).then(response => {
-                if(response.code == 200){
-                  this.msgSuccess(response.msg);
-                  this.$parent.pageToggle(1,'refresh');
-                }
-              });
             }
+            this.formData.classifyAttribute = this.formData.classifyAttribute+'';
+            addHxpChemical(this.formData).then(response => {
+              if(response.code == 200){
+                this.msgSuccess(response.msg);
+                this.$parent.pageToggle(1,'refresh');
+              }
+            });
           }
-        });
-      },
-      //获取化学品分类列表
-      classifyList(){
-        classifyList().then(response => {
-          this.optionsListOne = response.rows;
-        });
-      },
-      backPage(){
-        this.$parent.pageToggle(1);
-      },
-    }
+        }
+      });
+    },
+    //获取化学品分类列表
+    classifyList(){
+      classifyList().then(response => {
+        this.optionsListOne = response.rows;
+      });
+    },
+    backPage(){
+      this.$parent.pageToggle(1);
+    },
   }
+}
 </script>
 
 <style scoped lang="scss">
-  .listPage{
+.listPage{
+  flex:1;
+  display: flex;
+  flex-direction: column;
+  overflow: hidden;
+  p{
+    margin:0;
+    padding:0;
+  }
+  .title-box{
+    display: flex;
+    height:90px;
+    border-bottom: 1px solid #D8D8D8;
+    p:nth-child(1){
+      flex:1;
+      font-size:16px;
+      line-height:90px;
+      margin-left:18px;
+      color:#0045AF;
+    }
+    p:nth-child(2){
+      margin:25px 25px 0 0;
+    }
+  }
+  .listPage-min{
     flex:1;
     display: flex;
     flex-direction: column;
-    overflow: hidden;
-    p{
-      margin:0;
-      padding:0;
-    }
-    .title-box{
-      display: flex;
-      height:90px;
-      border-bottom: 1px solid #D8D8D8;
-      p:nth-child(1){
-        flex:1;
-        font-size:16px;
-        line-height:90px;
-        margin-left:18px;
-        color:#0045AF;
+    padding:20px;
+    .form-min-box{
+      display: inline-block;
+      width:750px;
+      height:70px;
+      .form-i-icon{
+        margin-right:10px;
+        color:rgba(255,192,0,1);
       }
-      p:nth-child(2){
-        margin:25px 25px 0 0;
+      .form-left-text{
+        line-height:30px;
+        font-size:14px;
+        color:#606266;
+        margin-right:40px;
       }
-    }
-    .listPage-min{
-      flex:1;
-      display: flex;
-      flex-direction: column;
-      padding:20px;
-      .form-min-box{
-        display: inline-block;
-        width:750px;
-        height:70px;
-        .form-i-icon{
-          margin-right:10px;
-          color:rgba(255,192,0,1);
-        }
-        .form-left-text{
-          line-height:30px;
-          font-size:14px;
-          color:#606266;
-          margin-right:40px;
-        }
-        .form-right-text{
-          line-height:40px;
-          font-size:14px;
-          color:#606266;
+      .form-right-text{
+        line-height:40px;
+        font-size:14px;
+        color:#606266;
 
-        }
       }
-      .bottom-button-box{
-        display: flex;
-        width:160px;
-        margin:40px auto 20px;
-        .left-button{
-          margin-right:20px;
-        }
+    }
+    .bottom-button-box{
+      display: flex;
+      width:160px;
+      margin:40px auto 20px;
+      .left-button{
+        margin-right:20px;
       }
     }
   }
+}
 </style>
 <style lang="scss">
-  .listPage{
-    .listPage-min{
-      .criticality-input{
-        .el-input-number__decrease,.el-input-number__increase{
-          display: none;
-        }
-        .el-input-number .el-input{
-          input{
-            padding:0 15px;
-            text-align: left;
-          }
+.listPage{
+  .listPage-min{
+    .criticality-input{
+      .el-input-number__decrease,.el-input-number__increase{
+        display: none;
+      }
+      .el-input-number .el-input{
+        input{
+          padding:0 15px;
+          text-align: left;
         }
       }
-      .form-el-checkbox-group{
-        .el-form-item{
-          display: flex;
-          .el-form-item__label{
-            width:120px;
-          }
-          .el-form-item__content{
-            flex:1;
-          }
-          .el-checkbox{
-            display: inline-block;
-          }
+    }
+    .form-el-checkbox-group{
+      .el-form-item{
+        display: flex;
+        .el-form-item__label{
+          width:120px;
+        }
+        .el-form-item__content{
+          flex:1;
+        }
+        .el-checkbox{
+          display: inline-block;
         }
       }
     }
   }
-  .num-input-item{
-    .num-input-min-box{
-      display: flex;
-      .el-input-number__increase{
-        display: none;
-      }
-      .el-input-number__decrease{
-        display: none;
-      }
-      input{
-        padding:0 20px!important;
-        border-top-right-radius: 0;
-        border-bottom-right-radius: 0;
-      }
-      .num-title-span{
-        display: inline-block;
-        width:40px;
-        height:40px;
-        text-align: center;
-        border: 1px solid #DCDFE6;
-        border-left:none;
-        border-top-right-radius: 4px;
-        border-bottom-right-radius: 4px;
-      }
+}
+.num-input-item{
+  .num-input-min-box{
+    display: flex;
+    .el-input-number__increase{
+      display: none;
+    }
+    .el-input-number__decrease{
+      display: none;
+    }
+    input{
+      padding:0 20px!important;
+      border-top-right-radius: 0;
+      border-bottom-right-radius: 0;
+    }
+    .num-title-span{
+      display: inline-block;
+      width:40px;
+      height:40px;
+      text-align: center;
+      border: 1px solid #DCDFE6;
+      border-left:none;
+      border-top-right-radius: 4px;
+      border-bottom-right-radius: 4px;
     }
   }
+}
 </style>

+ 1 - 1
src/views/medicUniversity-3_1/chemicalManagement/deviceManagement/smartLocker/associatedCabinetLock.vue

@@ -6,7 +6,7 @@
         <p class="reset-button-one" @click="backPage"><i class="el-icon-arrow-left"></i>返回</p>
       </div>
       <div class="associatedCabinetLock-min-page">
-        <el-form ref="form" :model="form" label-width="0px">
+        <el-form style="flex: 1;flex-direction: column;display: flex;overflow: hidden;" ref="form" :model="form" label-width="0px">
           <el-table  border :data="tableList" ref="multipleTable">
           <el-table-column label="柜锁编号" align="center" prop="hardwareNum" width="300px"/>
           <el-table-column label="柜锁名称" align="center" prop="name" width="200px"/>