前三个点位所有功能已调通
This commit is contained in:
17
internal/routes/play/only_video.go
Normal file
17
internal/routes/play/only_video.go
Normal file
@@ -0,0 +1,17 @@
|
||||
package play
|
||||
|
||||
import (
|
||||
"game-driver/internal/middleware"
|
||||
"game-driver/internal/schema"
|
||||
"game-driver/leaf"
|
||||
"game-driver/pkg/utils"
|
||||
"game-driver/pkg/video"
|
||||
)
|
||||
|
||||
func OnlyVideo(c *leaf.Context) {
|
||||
payload := leaf.Value[*schema.PlayModal](c, middleware.PayloadJSONKey)
|
||||
|
||||
if url, ok := payload.Game["video"]; ok {
|
||||
_ = video.Play(c, utils.LinkVideo(url.(string)))
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user