Commit 5e18dda3 Harvey

建议提交

1 个父辈 ff86874f
......@@ -12,17 +12,38 @@
txt: ''
}
},
async onLoad(e) {
// const res = await uni.$u.request.graphql({
// name: 'lottery_shop_get_my_shop_info'
// })
},
methods: {
save(){
uni.showToast({
title:'接口未实现'
})
}
async onLoad(e) {},
methods: {
async save() {
let txt = this.txt.trim()
if (txt.length < 20) {
uni.showToast({
icon: 'error',
title: '您描述的问题内容太少'
})
return
}
const res = await uni.$u.request.graphql({
type: 'mutation',
name: 'suggestAdd',
args: `url:"",img:"",typeId:5,content:"${txt}"`
})
if (res.Error) {
uni.showToast({
icon: 'error',
title: res.Error
})
return
}
uni.showToast({
title: '提交成功'
})
this.txt = ''
}
}
}
</script>
......
支持 Markdown 格式
你添加了 0 到此讨论。请谨慎行事。
Finish editing this message first!