Browse Source

样本预录入缺失代码提交

jianglw 4 years ago
parent
commit
bcbee9ac06
1 changed files with 62 additions and 7 deletions
  1. 62 7
      src/dashoo.cn/frontend_animal/src/pages/samples/archived/index.vue

+ 62 - 7
src/dashoo.cn/frontend_animal/src/pages/samples/archived/index.vue

@@ -45,7 +45,7 @@
         </el-form>
       </div>
 
-      <el-table ref="multipleTable" :data="list" bordertooltip-effect="dark" border height="calc(100vh - 230px)"
+      <el-table ref="multipleTable" :data="donorsList" bordertooltip-effect="dark" border height="calc(100vh - 230px)"
         style="width: 100%;" @selection-change="handleSelectionChange" @header-dragend="header_dragend">
         <el-table-column type="selection" width="55"></el-table-column>
         <el-table-column label="操作" width="80" align="center" fixed>
@@ -122,7 +122,7 @@
             </el-form-item>
 
             <el-form-item label="容器类型">
-              <el-select size="mini" style="width:100%" v-model="value" placeholder="请选择">
+              <el-select size="mini" style="width:100%" v-model="DItem" placeholder="请选择" @change="GetEquipmentInfos">
                 <el-option
                   v-for="item in EquipmentList"
                   :key="item.DItem"
@@ -157,6 +157,22 @@
                 placeholder="结束日期">
               </el-date-picker>
             </el-form-item>
+            <el-form-item label="容器名称">
+              <el-select
+                size="mini"
+                v-model="EquipmentIds"
+                multiple
+                collapse-tags
+                style="width: 100%"
+                placeholder="请选择">
+                <el-option
+                  v-for="item in EquipmentInfosList"
+                  :key="item.id"
+                  :label="item.name"
+                  :value="item.id">
+                </el-option>
+              </el-select>
+            </el-form-item>
           </el-col>
           <el-col :span="8">
             <el-form-item label="样本源名称">
@@ -198,6 +214,7 @@
       </div>
     </el-dialog>
 
+<<<<<<< HEAD
 <!--    <el-dialog title="自定义搜索" :visible.sync="searchDialogVisible" width="1000px" top="5vh">
       <el-form ref="form" inline label-width="120px">
         <el-row :gutter="0">
@@ -312,7 +329,9 @@
           </div>
         </el-col>
       </el-row>
-    </el-dialog>--> 
+    </el-dialog>-->
+=======
+>>>>>>> d569b8d166cfda79e6f095425552cbd0d6d0ab6b
 
     <!-- 自定义查询 -->
     <samplesearchdialog @close="closeDialog"
@@ -357,7 +376,10 @@
         EndDate: '', // 结束时期
         GroupName: '', // 所属分组
         Name: '', // 名称
+        DItem: '', // 容器类型id
         SourceName: '', // 样本来源
+        EquipmentInfosList: [], // 容器名称列表
+        EquipmentIds: [], // 设备id列表
         Validity: [], // 有效日期
         InnerCode: '', // 样本内码
         dialogFormVisible: false, // 添加弹框是否显示
@@ -581,6 +603,24 @@
         }
         this.currentSearchTemplate = ''
         let _this = this
+        // 增加自定义显示列,存储位置,之后需要去掉
+        let ishaslocation = false
+        for (let i = 0; i < _this.showcolumn.length; i++) {
+          if (_this.showcolumn[i].filed === 'Location') {
+            ishaslocation = true
+            break
+          }
+        }
+        if (!ishaslocation) {
+          _this.showcolumn.push({
+            filed: 'Location',
+            name: '存储位置',
+            show: true,
+            kuoz: false,
+            columnwidth: 200
+          })
+        }
+        // paginate
         let params = {
           _currentPage: this.currentPage,
           _size: this.size,
@@ -589,10 +629,10 @@
           SampleType: this.SampleType,
           Stnotevalue: this.Stnotevalue,
           STNoteField: this.STNoteField,
-          Noteitemvalue: this.Noteitemvalue,
-          Noteitem: this.Noteitem,
           CreateBy: this.CreateBy,
           SourceName: this.SourceName,
+          DItem: this.DItem,
+          EquipmentIds: this.EquipmentIds,
           Name: this.Name,
           Validity: this.Validity,
           CreateOn: this.CreateOn,
@@ -606,8 +646,16 @@
           }
           params = Object.assign(params, params2)
         }
-        store.set('samplearchivedseach', params)
-        this.$axios.get('/samplesfiles/animallist', {
+        if (this.Validity && this.Validity.length === 2) {
+          let params3 = {
+            Validitystart: this.Validity[0] / 1000,
+            Validityend: this.Validity[1] / 1000
+          }
+          params = Object.assign(params, params3)
+        }
+        store.set('samplestoredseach', params)
+        _this.getAllSearchTab()
+        this.$axios.get('/sampleinput/animallist', {
           params
         })
           .then(res => {
@@ -622,6 +670,12 @@
             this.EquipmentList = res.data
           })
       },
+      GetEquipmentInfos () {
+        service.postRequest('dashoo.biobank.bee-0.1', 'Equipment', 'GetEquipmentInfos', {DItem: this.DItem})
+          .then(res => {
+            this.EquipmentInfosList = res.data
+          })
+      },
       // 根据子code获取所有父code
       getparentcodebytopcode (v) {
         let _this = this
@@ -1315,6 +1369,7 @@
         this.SourceName = ''
         this.InnerCode = ''
         this.Name = ''
+        this.EquipmentIds = ''
         this.CreateBy = ''
         this.CreateOn = []
         this.SampleType = ''