fixed bug for payment api authorization

This commit is contained in:
RockYang 2024-05-24 11:31:38 +08:00
parent 717b137a6d
commit 2f9b1b7835
3 changed files with 19 additions and 9 deletions

View File

@ -9,12 +9,12 @@ package core
import (
"bytes"
"context"
"fmt"
"geekai/core/types"
"geekai/store/model"
"geekai/utils"
"geekai/utils/resp"
"context"
"fmt"
"github.com/gin-gonic/gin"
"github.com/go-redis/redis/v8"
"github.com/golang-jwt/jwt/v5"
@ -231,11 +231,15 @@ func needLogin(c *gin.Context) bool {
c.Request.URL.Path == "/api/product/list" ||
c.Request.URL.Path == "/api/menu/list" ||
c.Request.URL.Path == "/api/markMap/client" ||
c.Request.URL.Path == "/api/payment/alipay/notify" ||
c.Request.URL.Path == "/api/payment/hupipay/notify" ||
c.Request.URL.Path == "/api/payment/payjs/notify" ||
c.Request.URL.Path == "/api/payment/doPay" ||
c.Request.URL.Path == "/api/payment/payWays" ||
strings.HasPrefix(c.Request.URL.Path, "/api/test") ||
strings.HasPrefix(c.Request.URL.Path, "/api/function/") ||
strings.HasPrefix(c.Request.URL.Path, "/api/sms/") ||
strings.HasPrefix(c.Request.URL.Path, "/api/captcha/") ||
strings.HasPrefix(c.Request.URL.Path, "/api/payment/") ||
strings.HasPrefix(c.Request.URL.Path, "/static/") {
return false
}

View File

@ -21,8 +21,8 @@
cursor pointer
.el-image {
width 40px
height 40px
width 48px
height 48px
}
}
@ -86,7 +86,7 @@
.navigator {
display flex
flex-flow column
width 50px
width 60px
padding 10px 1px
border-right: 1px solid #3c3c3c
background-color: #1E1F22
@ -97,12 +97,14 @@
li {
margin-bottom 15px
display flex
flex-flow column
a {
color #DADBDC
border-radius 10px
width 40px
height 40px
width 48px
height 48px
display flex
justify-content center
align-items center
@ -125,9 +127,12 @@
.title {
font-size: 12px
padding-top: 5px
padding-top: 6px
color: #e5e7eb;
text-align: center;
white-space: nowrap; /* */
overflow: hidden; /* */
text-overflow: unset; /* 使 */
}
.active {

View File

@ -85,6 +85,7 @@
<el-image :src="item.icon" style="width: 30px;height: 30px"/>
</a>
</el-tooltip>
<span :class="item.url === curPath ? 'title active' : 'title'">{{ item.name }}</span>
</li>
<el-popover