From 7779e07bd84d081a8f14ef976397dc4c19b0e994 Mon Sep 17 00:00:00 2001
From: liujiandao <274878379@qq.com>
Date: 星期二, 20 二月 2024 14:02:33 +0800
Subject: [PATCH] 库中新增更新缓存

---
 cache/db.go |    9 +--------
 1 files changed, 1 insertions(+), 8 deletions(-)

diff --git a/cache/db.go b/cache/db.go
index a978572..f283c4b 100644
--- a/cache/db.go
+++ b/cache/db.go
@@ -75,12 +75,6 @@
 	PicDesc      string `gorm:"column:picDesc" json:"picDesc" example:"鐓х墖鏍囪瘑"`
 	Reserved     string `gorm:"column:reserved" json:"reserved" example:"鍏朵粬"`
 
-	CarNo      string `gorm:"column:carNo" json:"carNo" example:"杞︾墝鍙�"`
-	CarPicUrls string `gorm:"column:carPicUrls" json:"carPicUrls" example:"杞﹁締鐓х墖"`
-	CarType    int    `gorm:"column:carType" json:"carType" example:"杞﹁締绫诲瀷"`
-	CarBrand   int    `gorm:"column:carBrand" json:"carBrand" example:"杞﹁締鍝佺墝"`
-	CarColor   int    `gorm:"column:carColor" json:"carColor" example:"杞﹁締棰滆壊"`
-
 	FromServerId string `gorm:"column:fromServerId" json:"fromServerId,omitempty" example:"鍏ュ簱serverId"`
 }
 
@@ -114,7 +108,7 @@
 
 func (dbp *DbPersons) GetPersonsCompareCacheBase(from int, size int) (arr []*protomsg.Esinfo, err error) {
 	var persons []DbPersons
-	sql := "select id,faceFeature,tableId,enable,carNo from dbtablepersons where isDelete=0 and tableId in (select id from dbtables where isDelete=0)"
+	sql := "select id,faceFeature,tableId,enable from dbtablepersons where isDelete=0 and tableId in (select id from dbtables where isDelete=0)"
 	sql += " order by id asc limit " + strconv.Itoa(from) + "," + strconv.Itoa(size)
 	err = db.Raw(sql).Find(&persons).Error
 	if err != nil {
@@ -127,7 +121,6 @@
 				Tableid:     p.TableId,
 				FaceFeature: p.FaceFeature,
 				Enable:      int32(p.Enable),
-				CarNo:       p.CarNo,
 			})
 		}
 	}

--
Gitblit v1.8.0