Sfoglia il codice sorgente

1.容器批量导入bug修改2.样本类型添加单位显示bug修改

hanmj 6 anni fa
parent
commit
9367610706

+ 1 - 1
src/dashoo.cn/backend/api/business/device/deviceService.go

@@ -56,7 +56,7 @@ func (s *DeviceService) GetPagingEntitiesWithOrderSearch(pageIndex, itemsPerPage
 	if pageIndex > 0 {
 		limitstr = ` limit ` + utils.ToStr((pageIndex-1)*itemsPerPage) + "," + utils.ToStr(itemsPerPage)
 	}
-	sql = `select a.Id, a.Code,a.Title,a.Tags,a.About,a.Local,a.Serial,a.TagCode,b.Code BCode,b.Title BTitle,a.DeviceState,a.DataItem,a.Description  from Channels a left join Device b on a.DId=b.Id
+	sql = `select a.Id, a.Code,a.Title,a.Tags,a.About,a.Serial,a.TagCode,b.Code BCode,b.Title BTitle,a.DataItem,a.Description  from Channels a left join Device b on a.DId=b.Id
 		left join ChannelsSort c on a.Id=c.ChannelId and c.UserId=` + Uid + `
 		left join Base_User d on a.CreateUserId=d.Id
 		where ` + searchstring + ` order by ` + order + limitstr

+ 10 - 5
src/dashoo.cn/backend/api/business/samplesinfo/samplesinfoService.go

@@ -322,8 +322,16 @@ func (s *SamplesInfoService) InsertExcelSamplesInput(excelpath, acccode, createb
 	tbldetail := acccode + SamplesDetailtbName
 	tblfile := acccode + SamplesDetailFiletbName
 	tblbuss := acccode + SamplesBusstbName
-	tbldonor := acccode + AnimalInfoName
+	//tbldonor := acccode + AnimalInfoName
 	//tbldonor := acccode + DonorstbName
+	//当是蜜蜂所用户时,取acccode + AnimalInfoName  动物表数据
+	tbldonor := ""
+	if(strings.EqualFold(acccode,"sBBo4")){
+		tbldonor = acccode + AnimalInfoName
+	}else{
+		tbldonor = acccode + DonorstbName
+	}
+
 
 	var datadetail SamplesDetail
 	var databuss samplesbusiness.SamplesBusiness //业务记录
@@ -383,7 +391,6 @@ func (s *SamplesInfoService) InsertExcelSamplesInput(excelpath, acccode, createb
 					}
 
 					if cell.String() != "" && len(cell.String()) != 0 {
-						fmt.Println("mmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmmm", field)
 						if field == "EquipmentId" {
 							basestation.EquipmentId, _ = utils.StrTo(cell.String()).Int()
 						} else if field == "ShelfId" {
@@ -415,11 +422,9 @@ func (s *SamplesInfoService) InsertExcelSamplesInput(excelpath, acccode, createb
 							}
 							basestation.BarCode = cell.String()
 						} else if field == "SampleType" {
-							fmt.Println("dvvvvvvvbv            ddd", field)
 							basestation.SampleTypeName = cell.String()
 							where2 := " AccCode='" + acccode + "' and Name='" + cell.String() + "'"
 							sampletype_data = svc.GetSampleType(where2)
-							fmt.Println("ddddddddddddddddddddddddd", sampletype_data)
 							if sampletype_data.Id == 0 {
 								flag = 1
 								warn1 = " "
@@ -710,7 +715,7 @@ func (s *SamplesInfoService) InsertExcelSamplesInput(excelpath, acccode, createb
 
 				if flag == 1 {
 					flag = 0
-					continue
+					//continue
 				}
 
 				if basestation.CreateBy == "" {

+ 3 - 0
src/dashoo.cn/backend/api/business/sampletest/sampletest.go

@@ -108,6 +108,9 @@ type Donorsdetailmodel struct {
 	ProtocolNo   string
 	ZBack11      string
 	ZBack12      string
+	WeiZhi       string //兴瑞扩展字段  位置信息
+	RiQi         string//兴瑞扩展字段  存储日期信息
+	NianXian     string//兴瑞扩展字段  存储年薪信息
 }
 
 //检测结果 model

+ 1 - 1
src/dashoo.cn/backend/api/business/sampletest/sampletestService.go

@@ -48,7 +48,7 @@ func (s *SampleTestService) GetSamplesDetailandDoninfo(where string) []Donorsdet
 		where = " 1=1 "
 	}
 	var sql string
-	sql = `select a.Name,a.Nation,a.Telephone,a.HomeAddress,a.ZBack11,a.ZBack12,a.IdCard,b.BarCode,b.SampleCode,
+	sql = `select a.Name,a.Nation,a.Telephone,a.HomeAddress,a.ZBack11,a.ZBack12,a.IdCard,b.BarCode,b.SampleCode,d.ZBack11 WeiZhi,d.ZBack12 RiQi,d.ZBack13 NianXian,
 	c.EquipmentId,c.ShelfId,c.BoxId,c.Position,c.ValidityDate,d.ReceiveDate,
 	e.XStation ShelfX,e.YStation ShelfY,f.XStation BoxX,f.YStation BoxY,g.Code ECode,h.ProtocolNo
     from ` + DonorsInfo + ` a

+ 2 - 1
src/dashoo.cn/frontend_web/src/pages/setting/sampletype/sampletypeadd.vue

@@ -166,7 +166,7 @@
       // initial data
       this.initData()
       // 加载单位
-      // this.getsampetypeunit()
+      this.getsampetypeunit()
   },
     methods: {
       initData () {
@@ -222,6 +222,7 @@
         // 获取样本单位
         let _this = this
         _this.$axios.get('sampletype/sunitajax', {}).then(res => {
+          console.log(res)
           _this.sampeunitlist = res.data
         })
       },

+ 0 - 2
src/dashoo.cn/frontend_weixin/src/pages/index.vue

@@ -56,7 +56,6 @@ export default {
       } else {
         this.XISNum = ''
       }
-      console.log(2222)
         let _this = this
         const params = {
           XISNum: this.Search.XISNum,
@@ -66,7 +65,6 @@ export default {
             params
           })
           .then(function (response) {
-            console.log(response.data.items)
             _this.list = response.data.items
             console.log(response.data.items)
             if(_this.list.XISNum != '' && _this.list.XISNum != 'undefined'&& _this.list.XISNum != '888888'){