|
@@ -70,7 +70,8 @@ func (f *Front) ProjectList() {
|
|
// ProjectSave 项目保存
|
|
// ProjectSave 项目保存
|
|
func (f *Front) ProjectSave() {
|
|
func (f *Front) ProjectSave() {
|
|
defer qu.Catch()
|
|
defer qu.Catch()
|
|
- s_name := f.GetString("s_name") //项目名称
|
|
|
|
|
|
+ s_name := f.GetString("s_name") //项目名称
|
|
|
|
+ clearType := f.GetString("s_clear") // 清洗类型 normal interior
|
|
if s_name == "" {
|
|
if s_name == "" {
|
|
f.ServeJson(map[string]interface{}{"success": false, "msg": "缺少项目名称字段"})
|
|
f.ServeJson(map[string]interface{}{"success": false, "msg": "缺少项目名称字段"})
|
|
return
|
|
return
|
|
@@ -115,6 +116,7 @@ func (f *Front) ProjectSave() {
|
|
"s_departname": s_departname, //部门名称
|
|
"s_departname": s_departname, //部门名称
|
|
"s_rulename": strings.Join(s_rulename, ","), //规则名称
|
|
"s_rulename": strings.Join(s_rulename, ","), //规则名称
|
|
"i_importnum": importDataNum, //导入数量
|
|
"i_importnum": importDataNum, //导入数量
|
|
|
|
+ "s_cleartype": clearType,
|
|
"appid": appid,
|
|
"appid": appid,
|
|
"s_createname": username, //创建人
|
|
"s_createname": username, //创建人
|
|
"s_status": "未开始", //项目状态
|
|
"s_status": "未开始", //项目状态
|
|
@@ -168,7 +170,7 @@ func (f *Front) ProjectSave() {
|
|
"i_createtime": time.Now().Unix(), //创建时间
|
|
"i_createtime": time.Now().Unix(), //创建时间
|
|
"s_importtype": "coll", //导入类型
|
|
"s_importtype": "coll", //导入类型
|
|
"s_historyid": historyid, //源数据集标识
|
|
"s_historyid": historyid, //源数据集标识
|
|
- "b_isassessment": false, //是否进行了质量评估
|
|
|
|
|
|
+ "b_isassessment": true, //是否进行了质量评估
|
|
}
|
|
}
|
|
} else if stype == "edit" { //编辑保存
|
|
} else if stype == "edit" { //编辑保存
|
|
success = true
|
|
success = true
|
|
@@ -367,10 +369,12 @@ func (f *Front) ProjectQualityAssessment() {
|
|
defer qu.Catch()
|
|
defer qu.Catch()
|
|
msg := ""
|
|
msg := ""
|
|
success := false
|
|
success := false
|
|
|
|
+ stype := ""
|
|
//质量评估
|
|
//质量评估
|
|
projectid := f.GetString("pid") //项目id
|
|
projectid := f.GetString("pid") //项目id
|
|
- project, _ := util.Mgo.FindById(util.PROJECTCOLLNAME, projectid, map[string]interface{}{"b_isassessment": 1, "appid": 1, "v_fields": 1})
|
|
|
|
|
|
+ project, _ := util.Mgo.FindById(util.PROJECTCOLLNAME, projectid, map[string]interface{}{"b_isassessment": 1, "appid": 1, "v_fields": 1, "s_cleartype": 1})
|
|
if project != nil && len(*project) > 0 {
|
|
if project != nil && len(*project) > 0 {
|
|
|
|
+ stype = qu.ObjToString((*project)["s_cleartype"])
|
|
if isAssessment, ok := (*project)["b_isassessment"].(bool); ok && !isAssessment {
|
|
if isAssessment, ok := (*project)["b_isassessment"].(bool); ok && !isAssessment {
|
|
appid := qu.ObjToString((*project)["appid"])
|
|
appid := qu.ObjToString((*project)["appid"])
|
|
// todo
|
|
// todo
|
|
@@ -386,7 +390,7 @@ func (f *Front) ProjectQualityAssessment() {
|
|
} else {
|
|
} else {
|
|
msg = "查询项目失败"
|
|
msg = "查询项目失败"
|
|
}
|
|
}
|
|
- f.ServeJson(map[string]interface{}{"success": success, "msg": msg})
|
|
|
|
|
|
+ f.ServeJson(map[string]interface{}{"success": success, "msg": msg, "stype": stype})
|
|
}
|
|
}
|
|
|
|
|
|
// ProjectGroupTaskList 用户组任务分发列表
|
|
// ProjectGroupTaskList 用户组任务分发列表
|