25892
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
<u-input v-model="forms.publishUnitName" placeholder="请输入发布单位" maxlength="16" />
|
||||
</u-form-item>
|
||||
|
||||
<u-form-item label="正文" prop="content" required :border-bottom="false" label-position="top" class="contents">
|
||||
<u-form-item label="正文" prop="content" :border-bottom="false" label-position="top" class="contents">
|
||||
<u-input v-model="forms.content" placeholder="请输入正文" type="textarea" auto-height height="100" maxlength="500" />
|
||||
</u-form-item>
|
||||
|
||||
@@ -81,8 +81,13 @@ export default {
|
||||
return this.$u.toast('请输入发布组织')
|
||||
}
|
||||
|
||||
if (!this.forms.content) {
|
||||
return this.$u.toast('请输入正文')
|
||||
var isContent = false
|
||||
if (this.forms.content || this.forms.images.length > 0) {
|
||||
isContent = true
|
||||
}
|
||||
|
||||
if (!isContent) {
|
||||
return this.$u.toast('请输入正文或图片')
|
||||
}
|
||||
|
||||
const imgs = []
|
||||
@@ -105,9 +110,9 @@ export default {
|
||||
if (res.code == 0) {
|
||||
this.flag = false
|
||||
this.$u.toast('提交成功')
|
||||
uni.$emit('updateList')
|
||||
setTimeout(() => {
|
||||
uni.navigateBack()
|
||||
uni.$emit('updateList')
|
||||
setTimeout(() => {
|
||||
uni.navigateBack()
|
||||
}, 600)
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user