修改我已知晓的顺序

This commit is contained in:
Leo_Ding 2025-08-27 14:14:41 +08:00
parent 7231bd1d01
commit 744ac0cc11
2 changed files with 23 additions and 18 deletions

View File

@ -626,9 +626,7 @@
// A // A
const app = getApp() const app = getApp()
app.globalData.applyInfo = applyInfo app.globalData.applyInfo = applyInfo
uni.navigateTo({ this.readShow=true
url: `/pages/sign/sign?isSelfStudy=${this.isSelfStudy}`
})
} }
if (this.applyType === 2) { if (this.applyType === 2) {
if (!this.stampUrl) return uni.showToast({ if (!this.stampUrl) return uni.showToast({
@ -659,20 +657,27 @@
}, },
async postApply(){ async postApply(){
this.readShow=false this.readShow=false
// API if(this.applyType===1){
const res = await post('/api/v1/app_auth/metting-room/order/register', this.applyInfo) uni.navigateTo({
if (!res || !res.success) { url: `/pages/sign/sign?isSelfStudy=${this.isSelfStudy}`
throw new Error('会议室预定失败');
}
uni.showToast({
title: '预约完成,请致电社区,并关注预约记录留意审核状态,谢谢!',
icon: 'success'
});
if (res.success == true) {
uni.redirectTo({
url: `/pages/docList/index?files=${JSON.stringify(res.data)}&&isSelfStudy=${this.isSelfStudy}`
}) })
}else{
// API
const res = await post('/api/v1/app_auth/metting-room/order/register', this.applyInfo)
if (!res || !res.success) {
throw new Error('会议室预定失败');
}
uni.showToast({
title: '预约完成,请致电社区,并关注预约记录留意审核状态,谢谢!',
icon: 'success'
});
if (res.success == true) {
uni.redirectTo({
url: `/pages/docList/index?files=${JSON.stringify(res.data)}&&isSelfStudy=${this.isSelfStudy}`
})
}
} }
} }
} }

View File

@ -31,17 +31,17 @@
<!-- <button @click="saveCanvasAsImg" class="saveBtn">保存</button> --> <!-- <button @click="saveCanvasAsImg" class="saveBtn">保存</button> -->
<!-- <button @click="previewCanvasImg" class="previewBtn">预览</button> --> <!-- <button @click="previewCanvasImg" class="previewBtn">预览</button> -->
<button @click="undo" class="undoBtn">撤销</button> <button @click="undo" class="undoBtn">撤销</button>
<button @click="readShow=true" class="subBtn">完成</button> <button class="subBtn" @click="postApply">完成</button>
</view> </view>
</view> </view>
<pickerColor :isShow="showPickerColor" :bottom="0" @callback='getPickerColor' /> <pickerColor :isShow="showPickerColor" :bottom="0" @callback='getPickerColor' />
<u-popup :show="readShow" mode="bottom" :round="10"> <!-- <u-popup :show="readShow" mode="bottom" :round="10">
<instructionVue @change='readChange' /> <instructionVue @change='readChange' />
<u-button type="primary" text="我已知晓" :disabled="hasReaded" @click="postApply"></u-button> <u-button type="primary" text="我已知晓" :disabled="hasReaded" @click="postApply"></u-button>
</u-popup> </u-popup> -->
</view> </view>
</template> </template>