|
@@ -239,7 +239,7 @@ func (s *SecondPush) SecondPushTask() {
|
|
|
"$lte": endtime,
|
|
|
},
|
|
|
}
|
|
|
- d, _ := MgoSecondPush.Find("usermail_0806_01", q, nil, nil, false, 0, 0)
|
|
|
+ d, _ := MgoCus.Find("usermail", q, nil, nil, false, 0, 0)
|
|
|
if len(*d) > 0 && d != nil {
|
|
|
for _, l := range *d {
|
|
|
xlsxArr = append(xlsxArr, l)
|
|
@@ -255,7 +255,7 @@ func (s *SecondPush) SecondPushTask() {
|
|
|
},
|
|
|
}
|
|
|
|
|
|
- d, _ := MgoSecondPush.Find("usermail", q, nil, nil, false, 0, 0)
|
|
|
+ d, _ := MgoCus.Find("usermail", q, nil, nil, false, 0, 0)
|
|
|
for _, l := range *d {
|
|
|
xlsxArr = append(xlsxArr, l)
|
|
|
}
|
|
@@ -394,8 +394,9 @@ func GetXlsxs(mMap []map[string]interface{}, fn, email, id string) {
|
|
|
}
|
|
|
if dataType == 1 {
|
|
|
sh := xf.Sheets[0]
|
|
|
- for _, v := range mMap {
|
|
|
+ for i, v := range mMap {
|
|
|
row := sh.AddRow()
|
|
|
+ row.AddCell().SetInt(i + 1)
|
|
|
row.AddCell().SetValue(v["matchkey"])
|
|
|
row.AddCell().SetValue(v["area"])
|
|
|
row.AddCell().SetValue(v["city"])
|
|
@@ -420,8 +421,9 @@ func GetXlsxs(mMap []map[string]interface{}, fn, email, id string) {
|
|
|
xf.Sheets = xf.Sheets[0:1]
|
|
|
} else if dataType == 2 {
|
|
|
sh := xf.Sheets[1]
|
|
|
- for _, v := range mMap {
|
|
|
+ for i, v := range mMap {
|
|
|
row := sh.AddRow()
|
|
|
+ row.AddCell().SetInt(i + 1)
|
|
|
row.AddCell().SetValue(v["matchkey"])
|
|
|
row.AddCell().SetValue(v["area"])
|
|
|
row.AddCell().SetValue(v["city"])
|
|
@@ -467,8 +469,9 @@ func GetXlsxs(mMap []map[string]interface{}, fn, email, id string) {
|
|
|
xf.Sheets = xf.Sheets[1:2]
|
|
|
} else {
|
|
|
sh := xf.Sheets[2]
|
|
|
- for _, v := range mMap {
|
|
|
+ for i, v := range mMap {
|
|
|
row := sh.AddRow()
|
|
|
+ row.AddCell().SetInt(i + 1)
|
|
|
row.AddCell().SetValue(v["matchkey"])
|
|
|
row.AddCell().SetValue(v["area"])
|
|
|
row.AddCell().SetValue(v["city"])
|