|
@@ -1005,25 +1005,23 @@ func (this *SandboxController) EditSandboxClassify() {
|
|
|
return
|
|
|
}
|
|
|
|
|
|
- if item.SandboxClassifyName != req.SandboxClassifyName {
|
|
|
- count, err := sandbox.GetSandboxClassifyCount(req.SandboxClassifyName, item.ParentId)
|
|
|
- if err != nil {
|
|
|
- br.Msg = "判断名称是否已存在失败"
|
|
|
- br.ErrMsg = "判断名称是否已存在失败,Err:" + err.Error()
|
|
|
- return
|
|
|
- }
|
|
|
- if count > 0 {
|
|
|
- br.Msg = "分类名称已存在,请重新输入"
|
|
|
- br.IsSendEmail = false
|
|
|
- return
|
|
|
- }
|
|
|
+ //count, err := sandbox.GetSandboxClassifyCount(req.SandboxClassifyName, item.ParentId)
|
|
|
+ //if err != nil {
|
|
|
+ // br.Msg = "判断名称是否已存在失败"
|
|
|
+ // br.ErrMsg = "判断名称是否已存在失败,Err:" + err.Error()
|
|
|
+ // return
|
|
|
+ //}
|
|
|
+ //if count > 0 {
|
|
|
+ // br.Msg = "分类名称已存在,请重新输入"
|
|
|
+ // br.IsSendEmail = false
|
|
|
+ // return
|
|
|
+ //}
|
|
|
|
|
|
- err = sandbox.EditSandboxClassify(req.SandboxClassifyId, req.SandboxClassifyName)
|
|
|
- if err != nil {
|
|
|
- br.Msg = "保存失败"
|
|
|
- br.ErrMsg = "保存失败,Err:" + err.Error()
|
|
|
- return
|
|
|
- }
|
|
|
+ err = sandbox.EditSandboxClassify(req.SandboxClassifyId, req.ChartPermissionId, req.SandboxClassifyName, req.ChartPermissionName)
|
|
|
+ if err != nil {
|
|
|
+ br.Msg = "保存失败"
|
|
|
+ br.ErrMsg = "保存失败,Err:" + err.Error()
|
|
|
+ return
|
|
|
}
|
|
|
br.Ret = 200
|
|
|
br.Msg = "保存成功"
|
|
@@ -1798,9 +1796,9 @@ func (this *SandboxController) SaveV2() {
|
|
|
//缩略图为空时不更新
|
|
|
var updateSandboxColumn = []string{}
|
|
|
if req.PicUrl == "" {
|
|
|
- updateSandboxColumn = []string{"Content", "MindmapData", "ModifyTime", "SandboxClassifyId","Style"}
|
|
|
+ updateSandboxColumn = []string{"Content", "MindmapData", "ModifyTime", "SandboxClassifyId", "Style"}
|
|
|
} else {
|
|
|
- updateSandboxColumn = []string{"Content", "MindmapData", "PicUrl", "ModifyTime", "SandboxClassifyId","Style"}
|
|
|
+ updateSandboxColumn = []string{"Content", "MindmapData", "PicUrl", "ModifyTime", "SandboxClassifyId", "Style"}
|
|
|
}
|
|
|
err = sandboxInfo.Update(updateSandboxColumn)
|
|
|
if err != nil {
|