1
0
mirror of https://github.com/silenceper/wechat.git synced 2026-02-13 17:22:26 +08:00

feat: create mini program virtual payment (#709)

This commit is contained in:
houseme
2023-08-21 22:09:30 +08:00
committed by GitHub
parent 7df3fe1a09
commit 26b0aacb4c
12 changed files with 1216 additions and 27 deletions

View File

@@ -27,7 +27,7 @@ const (
PermanentMaterialTypeImage PermanentMaterialType = "image"
// PermanentMaterialTypeVideo 永久素材视频类型video
PermanentMaterialTypeVideo PermanentMaterialType = "video"
// PermanentMaterialTypeVoice 永久素材语音类型 voice
// PermanentMaterialTypeVoice 永久素材语音类型voice
PermanentMaterialTypeVoice PermanentMaterialType = "voice"
// PermanentMaterialTypeNews 永久素材图文类型news
PermanentMaterialTypeNews PermanentMaterialType = "news"
@@ -278,7 +278,7 @@ type ArticleList struct {
Item []ArticleListItem `json:"item"`
}
// ArticleListItem 用于ArticleListitem节点
// ArticleListItem 用于 ArticleListitem 节点
type ArticleListItem struct {
MediaID string `json:"media_id"`
Content ArticleListContent `json:"content"`
@@ -287,14 +287,14 @@ type ArticleListItem struct {
UpdateTime int64 `json:"update_time"`
}
// ArticleListContent 用于ArticleListItemcontent节点
// ArticleListContent 用于 ArticleListItemcontent 节点
type ArticleListContent struct {
NewsItem []Article `json:"news_item"`
UpdateTime int64 `json:"update_time"`
CreateTime int64 `json:"create_time"`
}
// reqBatchGetMaterial BatchGetMaterial请求参数
// reqBatchGetMaterial BatchGetMaterial 请求参数
type reqBatchGetMaterial struct {
Type PermanentMaterialType `json:"type"`
Count int64 `json:"count"`
@@ -337,7 +337,7 @@ type ResMaterialCount struct {
NewsCount int64 `json:"news_count"` // 图文总数量
}
// GetMaterialCount 获取素材总数.
// GetMaterialCount 获取素材总数
func (material *Material) GetMaterialCount() (res ResMaterialCount, err error) {
var accessToken string
accessToken, err = material.GetAccessToken()