瀏覽代碼

已下架的图表不会自动上架

xyxie 1 周之前
父節點
當前提交
faf1e01486
共有 2 個文件被更改,包括 2 次插入2 次删除
  1. 1 1
      controllers/data_manage/chart_classify.go
  2. 1 1
      services/eta_forum/eta_forum_hub.go

+ 1 - 1
controllers/data_manage/chart_classify.go

@@ -541,7 +541,7 @@ func (this *ChartClassifyController) DeleteChartClassifyCheck() {
 		tipsMsg = "可删除,进行删除操作"
 	}
 
-	if req.ChartClassifyId == 0 && req.ChartInfoId > 0 {
+	if req.ChartInfoId > 0 {
 		chartInfo, err := data_manage.GetChartInfoById(req.ChartInfoId)
 		if err != nil {
 			if utils.IsErrNoRow(err) {

+ 1 - 1
services/eta_forum/eta_forum_hub.go

@@ -726,7 +726,7 @@ func ChartBatchUpdateAndUpload(chartClassifyInfo *data_manage.ChartClassify, sys
 
 	// 批量上传已经上架的分类下的图表到资源库中
 	// 查询需要新增的图表ID
-	condition = " and source=1 and forum_chart_info_id=0 and chart_classify_id in ?"
+	condition = " and source=1 and forum_chart_info_id=0 and resource_status !=2 and chart_classify_id in ?"
 	total, err = data_manage.GetChartInfoCountByCondition(condition, []interface{}{upChartClassifyIdList})
 	if err != nil {
 		return