Browse Source

添加液氮罐页面显示,新增RBC1001液氮罐时后台配置架子和盒子规格,提取生成容器架子盒子的公共方法

jianglw 4 years ago
parent
commit
8c2d31deaf

+ 12 - 4
src/dashoo.cn/backend/api/controllers/samplesinfo/samplesinput.go

@@ -291,8 +291,16 @@ func (this *SamplesinputController) AnimalList() {
 	if donorname != "" {
 		where = where + " and SourceName like '%" + donorname + "%'"
 	}
+	ditem := this.GetString("DItem")
+	if ditem != "" {
+		where = where + " and f.DItem = '" + ditem + "'"
+	}
+	equipmentIds :=this.GetString("EquipmentIds")
+	if equipmentIds != "" {
+		where += " and f.Name in("+ equipmentIds +")"
+	}
 	var list []samplesinfo.SamplesInfoList
-	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "SourceName, groupNo asc , sampletype", where)
+	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "a.Id desc, SourceName, groupNo asc , sampletype", where)
 
 	var datainfo DataInfo
 	datainfo.Items = list
@@ -2346,7 +2354,7 @@ func (this *SamplesinputController) Listajax() {
 	}
 	svc := samplesinfo.GetSamplesInfoService(utils.DBE)
 	var samplespre []samplesinfo.SamplesInfoList
-	total, samplespre := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "SourceName, groupNo asc , sampletype", where)
+	total, samplespre := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "a.Id desc, SourceName, groupNo asc , sampletype", where)
 
 	var datainfo DataInfo
 	datainfo.Items = samplespre
@@ -2631,8 +2639,8 @@ func (this *SamplesinputController) SearchList() {
 	where += ")"
 
 	var list []samplesinfo.SamplesInfoList
-	//total, list := svc.GetPagingEntitiesWithOrderSearch(this.User.AccCode, page.CurrentPage, page.Size, "SourceName, groupNo asc , sampletype", where)
-	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "SourceName, groupNo asc , sampletype", where)
+	//total, list := svc.GetPagingEntitiesWithOrderSearch(this.User.AccCode, page.CurrentPage, page.Size, "a.Id desc, SourceName, groupNo asc , sampletype", where)
+	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "a.Id desc, SourceName, groupNo asc , sampletype", where)
 
 	var datainfo DataInfo
 	datainfo.Items = list

+ 11 - 3
src/dashoo.cn/backend/api/controllers/samplesinfo/samplespreinput.go

@@ -201,9 +201,17 @@ func (this *SamplespreinputController) AnimalList() {
 	if donorname != "" {
 		where = where + " and SourceName like '%" + donorname + "%'"
 	}
+	ditem := this.GetString("DItem")
+	if ditem != "" {
+		where = where + " and f.DItem = '" + ditem + "'"
+	}
+	equipmentIds :=this.GetString("EquipmentIds")
+	if equipmentIds != "" {
+		where += " and f.Name in("+ equipmentIds +")"
+	}
 	svc := samplesinfo.GetSamplesInfoService(utils.DBE)
 	var list []samplesinfo.SamplesInfoList
-	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "SourceName, groupNo asc , sampletype", where)
+	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "a.Id desc, SourceName, groupNo asc , sampletype", where)
 
 	var datainfo DataInfo
 	datainfo.Items = list
@@ -279,7 +287,7 @@ func (this *SamplespreinputController) AnimalApplyList() {
 	}
 	svc := samplesinfo.GetSamplesInfoService(utils.DBE)
 	var list []samplesinfo.SamplesInfoList
-	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "SourceName, groupNo asc , sampletype", where)
+	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "a.Id desc, SourceName, groupNo asc , sampletype", where)
 
 	var datainfo DataInfo
 	datainfo.Items = list
@@ -1098,7 +1106,7 @@ func (this *SamplespreinputController) SearchList() {
 
 	var list []samplesinfo.SamplesInfoList
 	//total, list := svc.GetPagingEntitiesWithOrderSearch(this.User.AccCode, page.CurrentPage, page.Size, "Id desc", where)
-	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "SourceName, groupNo asc , sampletype", where)
+	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "a.Id desc, SourceName, groupNo asc , sampletype", where)
 	var datainfo DataInfo
 	datainfo.Items = list
 	datainfo.CurrentItemCount = total

+ 10 - 3
src/dashoo.cn/backend/api/controllers/samplesinfo/samplesunsave.go

@@ -198,10 +198,17 @@ func (this *SamplesunsaveController) AnimalList() {
 	if donorname != "" {
 		where = where + " and SourceName like '%" + donorname + "%'"
 	}
-
+	ditem := this.GetString("DItem")
+	if ditem != "" {
+		where = where + " and f.DItem = '" + ditem + "'"
+	}
+	equipmentIds :=this.GetString("EquipmentIds")
+	if equipmentIds != "" {
+		where += " and f.Name in("+ equipmentIds +")"
+	}
 	svc := samplesinfo.GetSamplesInfoService(utils.DBE)
 	var list []samplesinfo.SamplesInfoList
-	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "SourceName, groupNo asc , sampletype", where)
+	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "a.Id desc, SourceName, groupNo asc , sampletype", where)
 
 	var datainfo DataInfo
 	datainfo.Items = list
@@ -363,7 +370,7 @@ func (this *SamplesunsaveController) SearchList() {
 
 	var list []samplesinfo.SamplesInfoList
 	//total, list := svc.GetPagingEntitiesWithOrderSearch(this.User.AccCode, page.CurrentPage, page.Size, "Id desc", where)
-	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "SourceName, groupNo asc , sampletype", where)
+	total, list := svc.GetPagingEntitiesWithTb(this.User.AccCode, page.CurrentPage, page.Size, this.User.AccCode+AnimaltbName, "a.Id desc, SourceName, groupNo asc , sampletype", where)
 	var datainfo DataInfo
 	datainfo.Items = list
 	datainfo.CurrentItemCount = total

+ 2 - 0
src/dashoo.cn/frontend_animal/src/layouts/default.vue

@@ -16,6 +16,8 @@
            id="cryobiobank97K_newmodelimg">
       <img src="/img/RCB600.png" style="width: 300px; height: 300px;display: none;"
            id="RCB600">
+      <img src="/img/RCB1000.png" style="width: 300px; height: 300px;display: none;"
+           id="RCB1000">
       <div id="divmenudiv" onmouseover="onoverdivmenu()" onmouseout="onoutdivmenu()" class="menudiv">
         <div class="menutext" style="display:none;" id="divmenutext">
         </div>

+ 61 - 13
src/dashoo.cn/frontend_animal/src/pages/equipment/_opera/manage_new.vue

@@ -240,7 +240,7 @@
             </el-row>
           <el-row>
           </el-row>
-              
+
           </el-card>
         </el-col>
          <!--冻存盒备注信息 结束-->
@@ -2714,7 +2714,7 @@
             height: 66,
             type: 1
           },
-  
+
           {
             XStation: 1,
             YStation: 4,
@@ -2724,7 +2724,7 @@
             height: 66,
             type: 1
           },
-  
+
           {
             XStation: 1,
             YStation: 5,
@@ -2752,7 +2752,7 @@
             height: 66,
             type: 1
           },
-  
+
           {
             XStation: 1,
             YStation: 8,
@@ -2762,7 +2762,7 @@
             height: 66,
             type: 1
           },
-  
+
           {
             XStation: 1,
             YStation: 9,
@@ -2772,7 +2772,7 @@
             height: 65,
             type: 1
           },
-  
+
           {
             XStation: 1,
             YStation: 10,
@@ -2782,7 +2782,7 @@
             height: 65,
             type: 1
           },
-  
+
           {
             XStation: 1,
             YStation: 11,
@@ -2810,7 +2810,7 @@
             height: 66,
             type: 1
           },
-  
+
           {
             XStation: 1,
             YStation: 14,
@@ -2929,6 +2929,48 @@
             type: 1
           }
         ],
+        rcb1000 : [
+          {YStation: 1,XStation: 1,type: 1, x:130,y:54,width:47,height:47},
+          {YStation: 2,XStation: 1,type: 1, x:177,y:54,width:47,height:47},
+          {YStation: 3,XStation: 1,type: 1, x:224,y:54,width:47,height:47},
+          {YStation: 4,XStation: 1,type: 1, x:271,y:54,width:47,height:47},
+          {YStation: 5,XStation: 1,type: 1, x:83,y:102,width:47,height:47},
+          {YStation: 6,XStation: 1,type: 1, x:130,y:102,width:47,height:47},
+          {YStation: 7,XStation: 1,type: 1, x:177,y:102,width:47,height:47},
+          {YStation: 8,XStation: 1,type: 1, x:224,y:102,width:47,height:47},
+          {YStation: 9,XStation: 1,type: 1, x:271,y:102,width:47,height:47},
+          {YStation: 10,XStation: 1,type: 1, x:318,y:102,width:47,height:47},
+          {YStation: 11,XStation: 1,type: 1, x:58,y:150,width:47,height:47},
+          {YStation: 12,XStation: 1,type: 1, x:105,y:150,width:47,height:47},
+          {YStation: 13,XStation: 1,type: 1, x:152,y:150,width:47,height:47},
+          {YStation: 14,XStation: 1,type: 1, x:199,y:150,width:47,height:47},
+          {YStation: 15,XStation: 1,type: 1, x:246,y:150,width:47,height:47},
+          {YStation: 16,XStation: 1,type: 1, x:293,y:150,width:47,height:47},
+          {YStation: 17,XStation: 1,type: 1, x:340,y:150,width:47,height:47},
+          {YStation: 18,XStation: 1,type: 1, x:58,y:198,width:47,height:47},
+          {YStation: 19,XStation: 1,type: 1, x:105,y:198,width:47,height:47},
+          {YStation: 20,XStation: 1,type: 1, x:152,y:198,width:47,height:47},
+          {YStation: 21,XStation: 1,type: 1, x:246,y:198,width:47,height:47},
+          {YStation: 22,XStation: 1,type: 1, x:293,y:198,width:47,height:47},
+          {YStation: 23,XStation: 1,type: 1, x:340,y:198,width:47,height:47},
+          {YStation: 24,XStation: 1,type: 1, x:58,y:246,width:47,height:48},
+          {YStation: 25,XStation: 1,type: 1, x:105,y:246,width:47,height:48},
+          {YStation: 26,XStation: 1,type: 1, x:152,y:246,width:47,height:48},
+          {YStation: 27,XStation: 1,type: 1, x:199,y:246,width:47,height:48},
+          {YStation: 28,XStation: 1,type: 1, x:246,y:246,width:47,height:48},
+          {YStation: 29,XStation: 1,type: 1, x:293,y:246,width:47,height:48},
+          {YStation: 30,XStation: 1,type: 1, x:340,y:246,width:47,height:48},
+          {YStation: 31,XStation: 1,type: 1, x:83,y:295,width:47,height:48},
+          {YStation: 32,XStation: 1,type: 1, x:130,y:295,width:47,height:48},
+          {YStation: 33,XStation: 1,type: 1, x:177,y:295,width:47,height:48},
+          {YStation: 34,XStation: 1,type: 1, x:224,y:295,width:47,height:48},
+          {YStation: 35,XStation: 1,type: 1, x:271,y:295,width:47,height:48},
+          {YStation: 36,XStation: 1,type: 1, x:318,y:295,width:47,height:48},
+          {YStation: 37,XStation: 1,type: 1, x:130,y:344,width:47,height:48},
+          {YStation: 38,XStation: 1,type: 1, x:177,y:344,width:47,height:48},
+          {YStation: 39,XStation: 1,type: 1, x:224,y:344,width:47,height:48},
+          {YStation: 40,XStation: 1,type: 1, x:271,y:344,width:47,height:48},
+        ],
         waituploads: [], // 等待上传的附件列表
         downloadTemplates: [{
           Name: '默认模版'
@@ -3006,8 +3048,10 @@
                 yedanguandatarrtrmp = _this.yedanguanrongqiarr
               } else if (_this.yedanguanitem === 21) {
                 yedanguandatarrtrmp = _this.yedanguanrongqiarr_newmodel
-              } else {
+              } else if (_this.yedanguanitem === 24) {
                 yedanguandatarrtrmp = _this.rcb600
+              } else if (_this.yedanguanitem === 25) {
+                yedanguandatarrtrmp = _this.rcb1000
               }
               for (let i = 0; i < yedanguandatarrtrmp.length; i++) {
                 if ((yedanguandatarrtrmp[i].XStation + '') === stationarr[0] && (yedanguandatarrtrmp[i].YStation +
@@ -3123,7 +3167,7 @@
               _this.showtsyedanguan = false
               _this.showcgshebei = true
               _this.fridgebottomimg = _this.filehost + '/static/img/sampletypeimg/bottomydg.png'
-            } else if (res.data && (res.data.DItem === 19 || res.data.DItem === 20 || res.data.DItem === 21 || res.data.DItem === 24)) {
+            } else if (res.data && (res.data.DItem === 19 || res.data.DItem === 20 || res.data.DItem === 21 || res.data.DItem === 24 || res.data.DItem === 25)) {
               _this.yedanguanitem = res.data.DItem
               if (res.data.DItem === 19) {
                 _this.yeshuyedanguanimgid = 'cryobiobank97Kimg'
@@ -3131,8 +3175,10 @@
                 _this.yeshuyedanguanimgid = 'cryobiobank97K_bloodbagimg'
               } else if (res.data.DItem === 21) {
                 _this.yeshuyedanguanimgid = 'cryobiobank97K_newmodelimg'
-              } else {
+              } else if (res.data.DItem === 24) {
                 _this.yeshuyedanguanimgid = 'RCB600'
+              } else if (res.data.DItem === 25) {
+                _this.yeshuyedanguanimgid = 'RCB1000'
               }
               // 加载特殊液氮罐
               _this.drawyedanguancanvasbgimg()
@@ -3171,8 +3217,10 @@
           yedanguandatarrtrmp = _this.yedanguanrongqiarr
         } else if (_this.yedanguanitem === 21) {
           yedanguandatarrtrmp = _this.yedanguanrongqiarr_newmodel
-        } else {
+        } else if (_this.yedanguanitem === 24) {
           yedanguandatarrtrmp = _this.rcb600
+        } else if (_this.yedanguanitem === 25) {
+          yedanguandatarrtrmp = _this.rcb1000
         }
         yedanguandatarrtrmp.forEach(function (v) {
           // 绘制颜色快
@@ -3339,7 +3387,7 @@
                 }
               }
             }
-  
+
             // 重置选择的冻存管
             _this.dchxtable = -1
             _this.dchytable = -1

+ 9 - 1
src/dashoo.cn/frontend_animal/src/pages/equipment/_opera/operation.vue

@@ -339,10 +339,12 @@
           })
       },
       selectPhoto (value) {
+        console.log("selectPhoto", value)
         let _this = this
         this.$axios.get('/equipment/getbydmodel/' + value, {})
           .then(res => {
             // response
+            console.log('res.data', res.data)
             if (res.data.Id > 0) {
               if (res.data.AccCode == 'ALL') {
                 _this.photoUrl = _this.remoteurl + res.data.Photo
@@ -356,7 +358,7 @@
               _this.formmodel.ModelId = res.data.Id
               _this.formmodel.ModelVersion = res.data.DModel
               _this.formmodel.DItem = res.data.DItem
-              // 19:贝尔Cryobiobank13K液氮罐;20:贝尔Cryobiobank13K_BloodBag液氮罐;21:贝尔最新型号液氮罐
+              // 19:贝尔Cryobiobank13K液氮罐;20:贝尔Cryobiobank13K_BloodBag液氮罐;21:贝尔最新型号液氮罐;25法液空RCB1000
               if (_this.isadd) {
                 switch (res.data.DItem) {
                   case 19:
@@ -383,6 +385,12 @@
                     _this.haveshelf = true
                     _this.showdchdcj = false
                     break
+                  case 25:
+                    _this.formmodel.RowNum = '40'
+                    _this.formmodel.ColumnNum = '1'
+                    _this.haveshelf = true
+                    _this.showdchdcj = false
+                    break
                   default:
                     _this.formmodel.RowNum = '1'
                     _this.formmodel.ColumnNum = '1'

+ 9 - 3
src/dashoo.cn/frontend_animal/src/pages/equipment/_opera/samplestorage.vue

@@ -2356,8 +2356,10 @@
           yedanguandatarrtrmp = _this.yedanguanrongqiarr
         } else if (_this.yedanguanitem === 21) {
           yedanguandatarrtrmp = _this.yedanguanrongqiarr_newmodel
-        } else {
+        }else if (_this.yedanguanitem === 24) {
           yedanguandatarrtrmp = _this.rcb600
+        }else if (_this.yedanguanitem === 25) {
+          yedanguandatarrtrmp = _this.rcb1000
         }
         yedanguandatarrtrmp.forEach(function(v) {
           // 绘制颜色快
@@ -2460,8 +2462,10 @@
                 _this.yeshuyedanguanimgid = 'cryobiobank97K_bloodbagimg'
               } else if (res.data.DItem === 21) {
                 _this.yeshuyedanguanimgid = 'cryobiobank97K_newmodelimg'
-              } else {
+              } else if (res.data.DItem === 21) {
                 _this.yeshuyedanguanimgid = 'RCB600'
+              } else if (res.data.DItem === 25) {
+                _this.yeshuyedanguanimgid = 'RCB1000'
               }
               // 加载特殊液氮罐
               _this.drawyedanguancanvasbgimg()
@@ -2536,8 +2540,10 @@
                 yedanguandatarrtrmp = _this.yedanguanrongqiarr
               } else if (_this.yedanguanitem === 21) {
                 yedanguandatarrtrmp = _this.yedanguanrongqiarr_newmodel
-              } else {
+              } else if (_this.yedanguanitem === 24) {
                 yedanguandatarrtrmp = _this.rcb600
+              } else if (_this.yedanguanitem === 25) {
+                yedanguandatarrtrmp = _this.rcb1000
               }
               for (let i = 0; i < yedanguandatarrtrmp.length; i++) {
                 if ((yedanguandatarrtrmp[i].XStation + '') === stationarr[0] && (yedanguandatarrtrmp[i].YStation + '') === stationarr[1]) {

+ 2 - 2
src/dashoo.cn/frontend_animal/src/pages/equipment/index.vue

@@ -63,7 +63,7 @@
               <router-link :to="'/equipment/' + v.Equipment.Id + '/manage_new?name=' + v.Equipment.Name + '&pname=equipment&size='+size+'&currentPage='+currentPage">
                 <el-button type="primary" size="mini">样本录入</el-button>
               </router-link>
-              <router-link v-if="v.Equipment.DItem !== 20 && v.Equipment.DItem !== 19 && v.Equipment.DItem !== 21 && v.Equipment.DItem !== 24" :to="'/equipment/' + v.Equipment.Id + '/shelfset_new?name=' + v.Equipment.Name + '&pname=equipment&size='+size+'&currentPage='+currentPage">
+              <router-link v-if="v.Equipment.DItem !== 20 && v.Equipment.DItem !== 19 && v.Equipment.DItem !== 21 && v.Equipment.DItem !== 24 && v.Equipment.DItem !== 25" :to="'/equipment/' + v.Equipment.Id + '/shelfset_new?name=' + v.Equipment.Name + '&pname=equipment&size='+size+'&currentPage='+currentPage">
                 <el-button type="primary" size="mini">设置</el-button>
               </router-link>
               <el-button type="primary" size="mini" @click="copy(v.Equipment.Id, v.Equipment.Code)">复制</el-button>
@@ -155,7 +155,7 @@
       loadsensordataall () {
         // console.log(222, this.list)
         if (this.list === null || this.list.length === 0) {
-  
+
         } else {
           for (let i = 0; i < this.list.length; i++) {
             if (this.list[i].SensorData && this.list[i].SensorData.length > 0) {

+ 1 - 1
src/dashoo.cn/frontend_animal/src/pages/samples/stored/index.vue

@@ -357,7 +357,7 @@
         Id: 0, // ID
         BarCode: '', // 样本条码
         SampleCode: '', // 样本编码
-        SampleType: 0, // 样本类型
+        SampleType: '', // 样本类型
         SamplingSite: '', // 取材部位
         Stnotevalue: '', // 特有扩展检索值
         STNoteField: [], // 特有扩展名称

+ 3 - 1
src/dashoo.cn/frontend_animal/src/pages/samples/waitingstore/_opera/unsave.vue

@@ -1699,8 +1699,10 @@
                 _this.yeshuyedanguanimgid = 'cryobiobank97K_bloodbagimg'
               } else if (res.data.DItem === 21) {
                 _this.yeshuyedanguanimgid = 'cryobiobank97K_newmodelimg'
-              } else {
+              } else if (res.data.DItem === 24) {
                 _this.yeshuyedanguanimgid = 'RCB600'
+              } else if (res.data.DItem === 25) {
+                _this.yeshuyedanguanimgid = 'RCB1000'
               }
               // 加载特殊液氮罐
               _this.drawyedanguancanvasbgimg()