feat: 添加天猫订单管理页面

This commit is contained in:
danial
2024-10-13 22:18:47 +08:00
parent 4d4d465a8a
commit 22fc234591
4 changed files with 43 additions and 0 deletions

View File

@@ -143,6 +143,24 @@ func (c *PageAuthController) RechargeTMallGameOrderPage() {
c.TplName = "t-mall-game/recharge-order.html"
}
func (c *PageAuthController) RechargeTMallGameShopOrderPage() {
token := ""
// 获取当前时间的时间戳
currentTime := time.Now()
targetMinute := (currentTime.Minute() / 10) * 10
targetTime := time.Date(currentTime.Year(), currentTime.Month(), currentTime.Day(), currentTime.Hour(), targetMinute, 0, 0, currentTime.Location())
now := strconv.Itoa(int(targetTime.Unix()))
secretCfg := config.GetSecret()
tokenB, err := utils.AesCBCEncrypt([]byte(now), []byte(secretCfg.Key), []byte(secretCfg.IV))
if err == nil {
//base64编码
token = base64.URLEncoding.EncodeToString(tokenB)
}
c.Data["token"] = token
c.Data["portalHost"] = config.GetPortalHost()
c.TplName = "t-mall-game/recharge-shop-order.html"
}
func (c *PageAuthController) RechargeTMallGameSummaryPage() {
token := ""
// 获取当前时间的时间戳

View File

@@ -30,6 +30,7 @@ func init() {
beego.Router("/recharge-t-mall-game-account.html", &controllers.PageAuthController{}, "*:RechargeTMallGameAccountPage")
beego.Router("/recharge-t-mall-game-order.html", &controllers.PageAuthController{}, "*:RechargeTMallGameOrderPage")
beego.Router("/recharge-t-mall-game-shop-order.html", &controllers.PageAuthController{}, "*:RechargeTMallGameShopOrderPage")
beego.Router("/recharge-t-mall-game-workplace.html", &controllers.PageAuthController{}, "*:RechargeTMallGameSummaryPage")
beego.Router("/operator.html", &controllers.PageAuthController{}, "*:OperatorPage")

View File

@@ -343,6 +343,9 @@
<a href="#" onclick='loadMainContent("/recharge-t-mall-game-order.html")'>
<span>订单管理</span>
</a>
<a href="#" onclick='loadMainContent("/recharge-t-mall-game-shop-order.html")'>
<span>天猫订单管理</span>
</a>
</div>
</div>
<!-- <div>-->

View File

@@ -0,0 +1,21 @@
<!DOCTYPE html>
<html lang="zh">
<body>
<iframe src="">
</iframe>
</body>
<style>
iframe {
width: 100%;
height: 90vh;
}
</style>
<script>
// 构建链接
const url = "{{.portalHost}}" + "/iframe/tMallGameShopOrder?token={{.token}}";
// 链接添加至到iframe中
document.getElementsByTagName("iframe")[0].src = url;
</script>
</html>