Преглед на файлове

优化base64图片上传错误提示

hsun преди 1 година
родител
ревизия
eca37535c9
променени са 2 файла, в които са добавени 4 реда и са изтрити 0 реда
  1. 2 0
      controllers/data_manage/chart_info.go
  2. 2 0
      controllers/data_manage/future_good/future_good_chart_info.go

+ 2 - 0
controllers/data_manage/chart_info.go

@@ -2218,6 +2218,8 @@ func (this *ChartInfoController) ChartInfoBase64Upload() {
 	case <-doneChannel:
 		fmt.Println("done")
 	case err := <-errorChannel:
+		br.Msg = "文件上传失败"
+		br.ErrMsg = fmt.Sprintf("execute command failure err: %s", err.Error())
 		fmt.Println("execute command failure err:" + err.Error())
 		return
 	}

+ 2 - 0
controllers/data_manage/future_good/future_good_chart_info.go

@@ -2207,6 +2207,8 @@ func (this *FutureGoodChartInfoController) ChartInfoBase64Upload() {
 	case <-doneChannel:
 		fmt.Println("done")
 	case err := <-errorChannel:
+		br.Msg = "文件上传失败"
+		br.ErrMsg = fmt.Sprintf("execute command failure err: %s", err.Error())
 		fmt.Println("execute command failure err:" + err.Error())
 		return
 	}