Compare commits
3 Commits
c135849195
...
41e28c9aed
Author | SHA1 | Date | |
---|---|---|---|
41e28c9aed | |||
d54a3df245 | |||
e2962353b9 |
File diff suppressed because it is too large
Load Diff
@ -1,7 +1,7 @@
|
||||
// Code generated by protoc-gen-go-triple. DO NOT EDIT.
|
||||
// versions:
|
||||
// - protoc-gen-go-triple v1.0.8
|
||||
// - protoc v4.24.0--rc1
|
||||
// - protoc-gen-go-triple v1.0.5
|
||||
// - protoc v6.32.0
|
||||
// source: pb/bundle.proto
|
||||
|
||||
package bundle
|
||||
|
@ -13,12 +13,13 @@ import (
|
||||
"fonchain-fiee/pkg/service/bundle/logic"
|
||||
bundleModel "fonchain-fiee/pkg/service/bundle/model"
|
||||
"fonchain-fiee/pkg/service/upload"
|
||||
"github.com/360EntSecGroup-Skylar/excelize"
|
||||
"github.com/gin-gonic/gin"
|
||||
"github.com/gin-gonic/gin/binding"
|
||||
"strconv"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"github.com/360EntSecGroup-Skylar/excelize"
|
||||
"github.com/gin-gonic/gin"
|
||||
"github.com/gin-gonic/gin/binding"
|
||||
)
|
||||
|
||||
func DeleteBundleOrder(c *gin.Context) {
|
||||
@ -502,6 +503,7 @@ func OrderRecordsListV2(c *gin.Context) {
|
||||
if u, ok := userMap[item.CustomerId]; ok {
|
||||
item.CustomerName = u.Name
|
||||
item.TelNum = u.TelNum
|
||||
item.SubNum = u.SubNum
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -583,6 +585,7 @@ func OrderRecordsListDownload(c *gin.Context) {
|
||||
if u, ok := userMap[item.CustomerId]; ok {
|
||||
item.CustomerName = u.Name
|
||||
item.TelNum = u.TelNum
|
||||
item.SubNum = u.SubNum
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -606,7 +609,7 @@ func exportExcel(orderList []*bundle.OrderBundleRecordInfo) (*excelize.File, err
|
||||
f.SetSheetName("Sheet1", sheetName)
|
||||
|
||||
headers := []string{
|
||||
"套餐订单号", "套餐类型", "套餐付款状态", "艺人手机号", "艺人", "套餐订单创建时间", "套餐支付时间", "套餐金额",
|
||||
"套餐订单号", "套餐类型", "套餐付款状态", "艺人手机号", "用户编号", "艺人", "套餐订单创建时间", "套餐支付时间", "套餐金额",
|
||||
"增值服务订单号", "增值税服务金额", "支付金额", "币种", "手续费", "增值订单创建时间", "增值付款状态",
|
||||
}
|
||||
for i, h := range headers {
|
||||
@ -636,22 +639,22 @@ func exportExcel(orderList []*bundle.OrderBundleRecordInfo) (*excelize.File, err
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("B%d", rowIndex), bundleInfo.BundleName)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("C%d", rowIndex), GetPayStatusText(bundleInfo.PayStatus))
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("D%d", rowIndex), bundleInfo.TelNum)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("E%d", rowIndex), bundleInfo.CustomerName)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("F%d", rowIndex), bundleInfo.BundleCreateAt)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("G%d", rowIndex), bundleInfo.PayTime)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("H%d", rowIndex), bundleInfo.Amount)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("E%d", rowIndex), bundleInfo.SubNum)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("F%d", rowIndex), bundleInfo.CustomerName)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("G%d", rowIndex), bundleInfo.BundleCreateAt)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("H%d", rowIndex), bundleInfo.PayTime)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("I%d", rowIndex), bundleInfo.Amount)
|
||||
|
||||
if addCount > 0 {
|
||||
for i, add := range bundleInfo.AddBundleInfo {
|
||||
r := rowIndex + i
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("I%d", r), add.OrderAddNo)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("J%d", r), add.Amount)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("K%d", r), add.SettlementAmount)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("L%d", r), GetCurrencyTypeText(add.CurrencyType))
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("M%d", r), add.HandlingFee)
|
||||
//f.SetCellValue(sheetName, fmt.Sprintf("N%d", r), add.ExchangeRate)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("N%d", r), add.OrderAddCreateAt)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("O%d", r), GetPayStatusText(add.AddPayStatus))
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("J%d", r), add.OrderAddNo)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("K%d", r), add.Amount)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("L%d", r), add.SettlementAmount)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("M%d", r), GetCurrencyTypeText(add.CurrencyType))
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("N%d", r), add.HandlingFee)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("O%d", r), add.OrderAddCreateAt)
|
||||
f.SetCellValue(sheetName, fmt.Sprintf("P%d", r), GetPayStatusText(add.AddPayStatus))
|
||||
}
|
||||
} else {
|
||||
for i := 8; i <= 15; i++ {
|
||||
|
@ -11,10 +11,11 @@ import (
|
||||
"fonchain-fiee/pkg/service/bundle/logic"
|
||||
bundleModel "fonchain-fiee/pkg/service/bundle/model"
|
||||
"fonchain-fiee/pkg/utils"
|
||||
"github.com/gin-gonic/gin"
|
||||
"github.com/gin-gonic/gin/binding"
|
||||
"strconv"
|
||||
"time"
|
||||
|
||||
"github.com/gin-gonic/gin"
|
||||
"github.com/gin-gonic/gin/binding"
|
||||
)
|
||||
|
||||
func GetReconciliationList(c *gin.Context) {
|
||||
@ -28,6 +29,29 @@ func GetReconciliationList(c *gin.Context) {
|
||||
service.Error(c, detailErr)
|
||||
return
|
||||
}
|
||||
var userIds []int64
|
||||
for _, u := range detail.List {
|
||||
userIds = append(userIds, int64(u.UserID))
|
||||
}
|
||||
userListResp, err := service.AccountFieeProvider.UserList(context.Background(), &accountFiee.UserListRequest{
|
||||
Ids: userIds,
|
||||
Domain: "app",
|
||||
})
|
||||
if err != nil {
|
||||
service.Error(c, err)
|
||||
return
|
||||
}
|
||||
userMap := make(map[int64]*accountFiee.UserListInfo, len(userListResp.UserList))
|
||||
if len(userListResp.UserList) > 0 {
|
||||
for _, u := range userListResp.UserList {
|
||||
userMap[int64(u.Id)] = u
|
||||
}
|
||||
for _, u := range detail.List {
|
||||
if user, ok := userMap[int64(u.UserID)]; ok {
|
||||
u.SubNum = user.SubNum
|
||||
}
|
||||
}
|
||||
}
|
||||
service.Success(c, detail)
|
||||
return
|
||||
|
||||
@ -44,8 +68,31 @@ func GetReconciliationListDownload(c *gin.Context) {
|
||||
service.Error(c, detailErr)
|
||||
return
|
||||
}
|
||||
var userIds []int64
|
||||
for _, u := range detail.List {
|
||||
userIds = append(userIds, int64(u.UserID))
|
||||
}
|
||||
userListResp, err := service.AccountFieeProvider.UserList(context.Background(), &accountFiee.UserListRequest{
|
||||
Ids: userIds,
|
||||
Domain: "app",
|
||||
})
|
||||
if err != nil {
|
||||
service.Error(c, err)
|
||||
return
|
||||
}
|
||||
userMap := make(map[int64]*accountFiee.UserListInfo, len(userListResp.UserList))
|
||||
if len(userListResp.UserList) > 0 {
|
||||
for _, u := range userListResp.UserList {
|
||||
userMap[int64(u.Id)] = u
|
||||
}
|
||||
for _, u := range detail.List {
|
||||
if user, ok := userMap[int64(u.UserID)]; ok {
|
||||
u.SubNum = user.SubNum
|
||||
}
|
||||
}
|
||||
}
|
||||
titleList := []string{
|
||||
"关联套餐订单号", "关联增值服务订单号", "对账单创建时间", "艺人", "艺人手机号", "套餐", "支付金额", "手续费", "币种", "支付渠道", "支付时间", "支付状态", "流水号",
|
||||
"关联套餐订单号", "关联增值服务订单号", "对账单创建时间", "用户编号", "艺人", "艺人手机号", "套餐", "支付金额", "手续费", "币种", "支付渠道", "支付时间", "支付状态", "流水号",
|
||||
}
|
||||
var dataList []interface{}
|
||||
|
||||
@ -60,6 +107,7 @@ func GetReconciliationListDownload(c *gin.Context) {
|
||||
i.BundleOrderOn,
|
||||
i.BundleAddOrderOn,
|
||||
i.CreationTime,
|
||||
i.SubNum,
|
||||
i.UserName,
|
||||
i.UserTel,
|
||||
i.BundleName,
|
||||
|
Loading…
Reference in New Issue
Block a user