This commit is contained in:
liuye
2024-03-11 12:03:12 +08:00
6 changed files with 1196 additions and 1263 deletions

View File

@@ -2,17 +2,20 @@
export default {
onLaunch() {
if (!wx.getUpdateManager) return
const updateManager = wx.getUpdateManager()
updateManager.onUpdateReady(() => {
this.$dialog.alert({
title: '更新提示',
content: '新版本已经准备好,点击确认按钮重启应用!'
}).then(() => {
updateManager.applyUpdate()
}).catch(() => {
})
})
if (uni.getUpdateManager) {
const updateManager = uni.getUpdateManager()
if (updateManager) {
updateManager.onUpdateReady(() => {
this.$dialog.alert({
title: '更新提示',
content: '新版本已经准备好,点击确认按钮重启应用!'
}).then(() => {
updateManager.applyUpdate()
}).catch(() => {
})
})
}
}
},
}
</script>

View File

@@ -40,7 +40,10 @@ export const user = {
reject(res);
}
},
fail: () => resolve(dispatch("getCode", ++count))
fail: err => {
console.error(err)
resolve(dispatch("getCode", ++count))
}
})
})
},
@@ -97,23 +100,23 @@ export const user = {
uni.navigateTo({url: modulePath});
} else if (checkType == 4) {
if (!token) {
return dispatch('autoLogin', { loginWay: 'qujing' }).then(() => dispatch('authCheck', { checkType, modulePath }));
return dispatch('autoLogin', {loginWay: 'qujing'}).then(() => dispatch('authCheck', {checkType, modulePath}));
}
if (!userInfo.areaId) {
return uni.showModal({
title: '温馨提示',
content: '您只有完成信息认证后,才可进行相关操作。',
confirmText: '去认证',
success: (res)=> {
success: (res) => {
if (res.confirm) {
uni.reLaunch({ url: `/pages/AppMine/userInfo?isFromTabbar=1&path=/pages/AppHome/AppHome` })
uni.reLaunch({url: `/pages/AppMine/userInfo?isFromTabbar=1&path=/pages/AppHome/AppHome`})
} else if (res.cancel) {
// 停留
}
}
})
}
uni.navigateTo({ url: modulePath });
uni.navigateTo({url: modulePath});
}
}
}

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -13,17 +13,17 @@
<div class="flex wrap">
<image class="fill imageItem" v-for="(item, index) in info.files" @click="preview(item.url)" :key="index" :src="item.url"/>
</div>
<span v-if="!info.files.length">暂无照片</span>
<span v-if="!hasFiles(info.files)">暂无照片</span>
</AiItem>
</AiGroup>
<u-gap height="24" v-if="result.doExplain" />
<u-gap height="24" v-if="result.doExplain"/>
<AiGroup title="处理详情" description noBorder labelColor="#999" v-if="result.doExplain">
<AiItem label="处理结果" top-label :value="result.doExplain"/>
<AiItem label="照片" class="not-line">
<div class="flex wrap">
<image class="fill imageItem" v-for="(item, index) in result.files" @click="preview(item.url)" :key="index" :src="item.url"/>
</div>
<span v-if="!result.files.length">暂无照片</span>
<span v-if="!hasFiles(result.files)">暂无照片</span>
</AiItem>
</AiGroup>
<!-- <u-gap height="24" v-if="info.judgeName"/>
@@ -50,9 +50,9 @@
<AiItem label="调处思路、措施及主要过程" :value="info.mediateInfo"/>
<AiItem label="调处结果" class="not-line" value="调解成功" />
</AiGroup> -->
<u-gap height="24" />
<u-tabs :list="evaluation && evaluation.id ? [{name:'办理进度'},{name:'我的评价'}] : [{name:'办理进度'}] " :current="currentTab" @change="v=>currentTab=v"/>
<u-gap height="24" bg-color="#fff" />
<u-gap height="24"/>
<u-tabs :list="tabs" :current="currentTab" @change="v=>currentTab=v"/>
<u-gap height="24" bg-color="#fff"/>
<AiGroup noBorder v-if="currentTab=='0'">
<AiStep v-for="(item,i) in process" :key="item.id" :index="i">
<div class="flex start">
@@ -98,8 +98,15 @@ export default {
systemExplain: `${createUserName}完成评价 (${score}星评价)`
})
}
return list
}
return list;
},
tabs: v => {
const tabs = [{name: "办理进度"}];
if (!!v.evaluation?.id) {
tabs.push({name: "我的评价"});
}
return tabs;
},
},
onShow() {
this.getInfo()
@@ -118,7 +125,7 @@ export default {
if (['3', '4'].includes(res.data.eventStatus) && res.data.groupName != '矛盾调解') {
this.result = res.data.processList[0]
}
if(this.info.judgeRisk) {
if (this.info.judgeRisk) {
this.info.judgeRiskList = this.info.judgeRisk.split(',')
}
}
@@ -134,11 +141,14 @@ export default {
preview(url) {
uni.previewImage({
urls: this.info.files.map(v => v.url),
current: url
})
}
}
}
current: url,
});
},
hasFiles(files) {
return files?.length > 0;
},
},
};
</script>
<style lang="scss">
@@ -196,7 +206,7 @@ export default {
background: #ff883c;
}
&.status-1, &.status-2, &.status-evaluation{
&.status-1, &.status-2, &.status-evaluation {
background: #1aaaff;
}
@@ -220,28 +230,34 @@ export default {
margin-right: 0;
}
}
.not-line {
.AiItem {
.normal {
border: none!important;
min-height: 112px!important;
border: none !important;
min-height: 112px !important;
}
}
}
::v-deep .AiGroup {
.groupHeader {
padding-top: 16px!important;
padding-top: 16px !important;
}
}
.level1 {
color: #3D88F5;
}
.level2 {
color: #52C75B;
}
.level3 {
color: #FF883C;
}
.level4 {
color: #FF3C3C;
}

View File

@@ -179,13 +179,11 @@ export default {
this.id = query.id
this.themeId = query.themeId
this.name = query.name || ''
this.$loading()
Promise.resolve(this.token || this.autoLogin()).then(() =>
Promise.all([
this.getInfo(query.id),
this.getCommontList(query.id)
])
).finally(() => this.$hideLoading())
this.$loading();
(this.token ? Promise.resolve() : this.autoLogin()).finally(() => Promise.all([
this.getInfo(query.id),
this.getCommontList(query.id)
])).finally(() => this.$hideLoading())
},
methods: {
...mapActions(['autoLogin']),
@@ -260,18 +258,15 @@ export default {
},
getInfo(id) {
this.$instance.post(`/app/appneighborhoodassistance/queryDetailById?id=${id}`, null, {
return this.$instance.post(`/app/appneighborhoodassistance/queryDetailById?id=${id}`, null, {
withoutToken: !this.token,
}).then(res => {
if (res.code === 0) {
if (res?.data) {
this.info = res.data
this.pageShow = true
return this.pageShow = true
}
uni.hideLoading()
})
},
reciate() {
this.$loading()
this.$instance.post(`/app/appneighborhoodassistance/appreciate?id=${this.id}`).then(res => {
@@ -329,7 +324,7 @@ export default {
if (this.isMore) return
this.$loading()
this.$instance.post(`/app/appneighborhoodassistance/commontList`, null, {
return this.$instance.post(`/app/appneighborhoodassistance/commontList`, null, {
withoutToken: !this.token,
params: {
id,
@@ -337,7 +332,7 @@ export default {
size: 10
}
}).then(res => {
if (res.code === 0) {
if (res?.data) {
this.$hideLoading()
if (this.current > 1) {
this.list = [...this.list, ...res.data.records]
@@ -353,7 +348,7 @@ export default {
} else {
this.isMore = true
}
}).catch(() => {
}).finally(() => {
this.$hideLoading()
})
}
@@ -362,13 +357,12 @@ export default {
onReachBottom() {
this.getCommontList()
},
// onShareTimeline() {
// return {
// title: this.info.content,
// // path: `/mods/AppCircle/Detail?id=${this.id}&themeId=${this.themeId}&name=${this.name}`
// }
// },
onShareTimeline() {
return {
title: this.info.content,
path: `/mods/AppCircle/Detail?id=${this.id}&themeId=${this.themeId}&name=${this.name}`
}
},
onShareAppMessage() {
this.$instance.post(`/app/appneighborhoodassistance/share?id=${this.id}`).then(res => {
if (res.code === 0) {
@@ -472,7 +466,6 @@ export default {
width: 100px;
height: 60px;
line-height: 60px;
text-align: right;
text-align: center;
font-size: 26px;
color: #fff;