From 7d06c6472f1acea6b2e49e7b8837bf555e94e219 Mon Sep 17 00:00:00 2001
From: zhangqian <zhangqian@123.com>
Date: 星期二, 07 五月 2024 16:21:06 +0800
Subject: [PATCH] fox

---
 models/workshop_manage.go |   11 ++++++++++-
 1 files changed, 10 insertions(+), 1 deletions(-)

diff --git a/models/workshop_manage.go b/models/workshop_manage.go
index 8039ed2..ca05716 100644
--- a/models/workshop_manage.go
+++ b/models/workshop_manage.go
@@ -29,7 +29,7 @@
 )
 
 func (slf WorkshopManage) TableName() string {
-	return "workshop_manage"
+	return "silk_workshop_manage"
 }
 
 func NewWorkshopManageSearch() *WorkshopManageSearch {
@@ -56,6 +56,11 @@
 	return slf
 }
 
+func (slf *WorkshopManageSearch) SetWorkshopName(workshopName string) *WorkshopManageSearch {
+	slf.WorkshopName = workshopName
+	return slf
+}
+
 func (slf *WorkshopManageSearch) SetGroupNumber(groupNumber int) *WorkshopManageSearch {
 	slf.GroupNumber = groupNumber
 	return slf
@@ -77,6 +82,10 @@
 		db = db.Where("workshop_number = ?", slf.WorkshopNumber)
 	}
 
+	if slf.WorkshopName != "" {
+		db = db.Where("workshop_name = ?", slf.WorkshopName)
+	}
+
 	if slf.GroupNumber != 0 {
 		db = db.Where("group_number = ?", slf.GroupNumber)
 	}

--
Gitblit v1.8.0