feat:完善项目信息
This commit is contained in:
@ -4,7 +4,6 @@ import (
|
||||
config2 "SciencesServer/app/basic/config"
|
||||
"SciencesServer/config"
|
||||
"SciencesServer/utils"
|
||||
"encoding/json"
|
||||
"strings"
|
||||
"time"
|
||||
)
|
||||
@ -46,19 +45,13 @@ type Images struct {
|
||||
}
|
||||
|
||||
// AnalysisSlice Slice解析
|
||||
func (m *Images) AnalysisSlice(domain string) []string {
|
||||
images := make([]string, 0)
|
||||
utils.FromJSON(m.Images, &images)
|
||||
func (m *Images) AnalysisSlice(domain string) string {
|
||||
images := strings.Split(m.Images, ",")
|
||||
|
||||
for k, v := range images {
|
||||
images[k] = domain + v
|
||||
}
|
||||
return images
|
||||
}
|
||||
|
||||
func (m *Images) SetImagesAttribute(value []string) {
|
||||
_bytes, _ := json.Marshal(value)
|
||||
m.Images = string(_bytes)
|
||||
return strings.Join(images, ",")
|
||||
}
|
||||
|
||||
type Local struct {
|
||||
|
Reference in New Issue
Block a user