Commit f611e1a3 by 陆志强

feat:提示更改&跳转限制开发

parent d2197c5e
...@@ -49,24 +49,21 @@ export const actions = { ...@@ -49,24 +49,21 @@ export const actions = {
const { title, intro, question, isJoined, status, referUrl } = data const { title, intro, question, isJoined, status, referUrl } = data
// 设置网页标题 // 设置网页标题
document.title = title || '调查问卷' document.title = title || '调查问卷'
// 如果不是iframe内嵌模式则弹窗 // 鉴权成功则转跳接口返回的对应网址
if (!isIframe) { if (referUrl && +status === ACTIVITY_STATE.end) {
// 鉴权成功则转跳接口返回的对应网址 Dialog.alert({
if (referUrl && +status === ACTIVITY_STATE.end) { message: '活动已结束,点击“确认”可以直接返回',
Dialog.alert({ }).then(() => {
message: '活动已结束,点击“确认”可以直接观看直播', window.location.href = referUrl
}).then(() => { })
window.location.href = referUrl }
}) // 鉴权成功则转跳接口返回的对应网址
} if (referUrl && !!isJoined && +status === ACTIVITY_STATE.start) {
// 鉴权成功则转跳接口返回的对应网址 Dialog.alert({
if (referUrl && !!isJoined && +status === ACTIVITY_STATE.start) { message: '您已提交过问卷,点击“确认”可以直接返回',
Dialog.alert({ }).then(() => {
message: '您已提交过问卷,点击“确认”可以直接观看直播', window.location.href = referUrl
}).then(() => { })
window.location.href = referUrl
})
}
} }
commit('SET_QUESTIONNAIREINFO', data) commit('SET_QUESTIONNAIREINFO', data)
const formatQuestion = question.map((item) => { const formatQuestion = question.map((item) => {
...@@ -142,8 +139,7 @@ export const actions = { ...@@ -142,8 +139,7 @@ export const actions = {
setQuestionnaire(params).then((res) => { setQuestionnaire(params).then((res) => {
const { code, errorCode, errorMessage } = res const { code, errorCode, errorMessage } = res
if (code === 200 && errorCode === 0) { if (code === 200 && errorCode === 0) {
// 如果不是iframe内嵌模式则转跳 if (referUrl) {
if (referUrl && !isIframe) {
Toast.success({ Toast.success({
message: '提交成功,正在跳转', message: '提交成功,正在跳转',
onClose: () => { onClose: () => {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment