diff --git a/app/admin/svc/svc_data_statisstics.go b/app/admin/svc/svc_data_statisstics.go index f50dc6c..687c614 100644 --- a/app/admin/svc/svc_data_statisstics.go +++ b/app/admin/svc/svc_data_statisstics.go @@ -676,7 +676,15 @@ func CentralKitchenForSchoolDataStatisticsExport(req md.CentralKitchenForSchoolD titleList = []string{"年级", "班级", "早餐", "午餐", "晚餐"} xlsx.SetSheetRow("Sheet1", "A2", &titleList) xlsx.MergeCell("Sheet1", "A1", "E1") //合并单元格 - j := 3 //表头前两行用了,只能从第三行开始 + style, err := xlsx.NewStyle(`{"fill":{"type":"pattern","color":["FF0000"],"pattern":1}}`) + if err != nil { + logx.Error(err) + println("<<<>>>>Error:::", err.Error()) + panic(err) + } + xlsx.SetCellStyle("Sheet1", "A1", "E1", style) + + j := 3 //表头前两行用了,只能从第三行开始 for k2, v2 := range v1 { if k2 == "" { //若年级为空,则为教师餐