浏览代码

Merge branch 'ETA_1.9.0_v2' into debug

zwxi 10 月之前
父节点
当前提交
5fcd9ee5e7

+ 5 - 2
controllers/data_manage/excel/excel_info.go

@@ -248,6 +248,7 @@ func (c *ExcelInfoController) Add() {
 		ParentId:           req.ParentId,
 		UpdateUserId:       sysUser.AdminId,
 		UpdateUserRealName: sysUser.RealName,
+		SourcesFrom:     req.SourcesFrom,
 	}
 
 	excelEdbMappingList := make([]*excel3.ExcelEdbMapping, 0)
@@ -936,12 +937,14 @@ func (c *ExcelInfoController) Edit() {
 	excelInfo.UpdateUserId = sysUser.AdminId
 	excelInfo.UpdateUserRealName = sysUser.RealName
 	excelInfo.Content = content
+	excelInfo.SourcesFrom = req.SourcesFrom
+
 	// 自动保存时不会传缩略图,也就不更新这个字段
 	var updateExcelInfoParams []string
 	if req.ExcelImage != "" {
-		updateExcelInfoParams = []string{"ModifyTime", "ExcelName", "ExcelType", "ExcelClassifyId", "ExcelImage", "Content", "UpdateUserId", "UpdateUserRealName"}
+		updateExcelInfoParams = []string{"ModifyTime", "ExcelName", "ExcelType", "ExcelClassifyId", "ExcelImage", "Content", "SourcesFrom"}
 	} else {
-		updateExcelInfoParams = []string{"ModifyTime", "ExcelName", "ExcelType", "ExcelClassifyId", "Content", "UpdateUserId", "UpdateUserRealName"}
+		updateExcelInfoParams = []string{"ModifyTime", "ExcelName", "ExcelType", "ExcelClassifyId", "Content", "SourcesFrom"}
 	}
 
 	excelEdbMappingList := make([]*excel3.ExcelEdbMapping, 0)

+ 1 - 0
models/data_manage/excel/excel_info.go

@@ -33,6 +33,7 @@ type ExcelInfo struct {
 	UpdateUserRealName string    `description:"更新人真实姓名"`
 	RelExcelInfoId     int       `description:"平衡表里静态表关联的动态表excel id"`
 	VersionName        string    `description:"静态表版本名称"`
+	SourcesFrom        string    `description:"图表来源"`
 }
 
 // Update 更新 excel表格基础信息

+ 2 - 0
models/data_manage/excel/request/excel_info.go

@@ -24,6 +24,7 @@ type AddExcelInfoReq struct {
 	Content         string      `description:"Excel表格内容"`
 	TableData       interface{} `description:"自定义表格的数据内容"`
 	ParentId        int         `description:"表格的父级id"`
+	SourcesFrom     string      `description:"图表来源"`
 }
 
 // EditExcelInfoReq 编辑表格请求
@@ -35,6 +36,7 @@ type EditExcelInfoReq struct {
 	ExcelClassifyId int         `description:"分类id"`
 	Content         string      `description:"Excel表格内容"`
 	TableData       interface{} `description:"自定义表格的数据内容"`
+	SourcesFrom     string      `description:"图表来源"`
 }
 
 // SetExcelInfoImageReq 设置excel表格图片请求