Skip to content

Commit 11c0b42

Browse files
committed
mp:增加图文草稿箱的修改;优化前端代码
1 parent aa3a9fa commit 11c0b42

File tree

3 files changed

+305
-340
lines changed

3 files changed

+305
-340
lines changed

src/api/mp/draft.js

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,3 +19,12 @@ export function createDraft(accountId, articles) {
1919
}
2020
})
2121
}
22+
23+
// 更新草稿
24+
export function updateDraft(accountId, mediaId, articles) {
25+
return request({
26+
url: '/mp/draft/update?accountId=' + accountId + '&mediaId=' + mediaId,
27+
method: 'put',
28+
data: articles
29+
})
30+
}

src/views/mp/components/wx-material-select/main.vue

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@
117117
},
118118
props: {
119119
objData: {
120-
type: Object,
120+
type: Object, // type - 类型;accountId - 公众号账号编号
121121
required: true
122122
},
123123
newsType:{ // 图文类型:1、已发布图文;2、草稿箱图文
@@ -148,6 +148,11 @@
148148
selectMaterial(item) {
149149
this.$emit('selectMaterial', item)
150150
},
151+
/** 搜索按钮操作 */
152+
handleQuery() {
153+
this.queryParams.pageNo = 1
154+
this.getPage()
155+
},
151156
getPage() {
152157
this.loading = true
153158
if (this.objData.type === 'news' && this.newsType === '1') { // 【图文】+ 【已发布】

0 commit comments

Comments
 (0)