Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
Daniel 2025-12-01 09:48:24 +08:00
parent 323b9345fc
commit a2152fd423
No known key found for this signature in database
GPG key ID: 86211BA83DF03017
2 changed files with 20 additions and 2 deletions

View file

@ -682,6 +682,15 @@ type ValueSelect struct {
Color string `json:"color"` // 1-14
}
func MSelectRemoveOption(mSelect []*ValueSelect, opt string) (ret []*ValueSelect) {
for _, s := range mSelect {
if s.Content != opt {
ret = append(ret, s)
}
}
return
}
func MSelectExistOption(mSelect []*ValueSelect, opt string) bool {
for _, s := range mSelect {
if s.Content == opt {