|
@@ -9,16 +9,20 @@
|
|
|
<!-- 内容 -->
|
|
|
<swiper :current="navIndex" @change="tabChange" class="swiper_content">
|
|
|
<swiper-item class="swiper_item">
|
|
|
- <FeedbackList :listArray="listArray" @click="onClick" @nextPage="onNextPage" />
|
|
|
+ <DetailedFeedbackList v-if="globalParameter.isLeader" :listArray="listArray" />
|
|
|
+ <FeedbackList v-else :listArray="listArray" @click="onClick" @nextPage="onNextPage" />
|
|
|
</swiper-item>
|
|
|
<swiper-item class="swiper_item">
|
|
|
- <FeedbackList :listArray="listArray" @click="onClick" @nextPage="onNextPage" />
|
|
|
+ <DetailedFeedbackList v-if="globalParameter.isLeader" :listArray="listArray" />
|
|
|
+ <FeedbackList v-else :listArray="listArray" @click="onClick" @nextPage="onNextPage" />
|
|
|
</swiper-item>
|
|
|
<swiper-item class="swiper_item">
|
|
|
- <FeedbackList :listArray="listArray" @click="onClick" @nextPage="onNextPage" />
|
|
|
+ <DetailedFeedbackList v-if="globalParameter.isLeader" :listArray="listArray" />
|
|
|
+ <FeedbackList v-else :listArray="listArray" @click="onClick" @nextPage="onNextPage" />
|
|
|
</swiper-item>
|
|
|
<swiper-item class="swiper_item">
|
|
|
- <FeedbackList :listArray="listArray" @click="onClick" @nextPage="onNextPage" />
|
|
|
+ <DetailedFeedbackList v-if="globalParameter.isLeader" :listArray="listArray" />
|
|
|
+ <FeedbackList v-else :listArray="listArray" @click="onClick" @nextPage="onNextPage" />
|
|
|
</swiper-item>
|
|
|
</swiper>
|
|
|
<!-- 新增 -->
|
|
@@ -26,22 +30,18 @@
|
|
|
<image class="add-icon" src="/static/image/add-icon.svg" mode="aspectFit"></image>
|
|
|
<view class="add-title">登记</view>
|
|
|
</view>
|
|
|
- <!-- 脚注 -->
|
|
|
- <view class="footnote_content">
|
|
|
- <view>本服务由重庆两江新区社会发展局提供</view>
|
|
|
- <view class="footnote_phone">服务咨询热线:<view class="phone_text" @click="makeCall">023-67685085</view></view>
|
|
|
- </view>
|
|
|
</view>
|
|
|
</template>
|
|
|
|
|
|
<script setup lang="ts">
|
|
|
- import { ref, onMounted } from "vue"
|
|
|
+ import { ref } from "vue"
|
|
|
import * as link from '@/lib/link'
|
|
|
import rest from '@/stores/rest'
|
|
|
import { onLoad, onShow } from "@dcloudio/uni-app";
|
|
|
import { aesEncrypt, aesDecrypt } from "@/lib/encryption";
|
|
|
import { formatDate } from '@/lib/util'
|
|
|
import FeedbackList from './FeedbackList.vue'
|
|
|
+ import DetailedFeedbackList from './DetailedFeedbackList.vue'
|
|
|
|
|
|
import { useUserStore } from '@/lib/store';
|
|
|
import { storeToRefs } from 'pinia';
|
|
@@ -139,10 +139,15 @@
|
|
|
{ title: '办件编号', key: 'id' },
|
|
|
{ title: '登记时间', key: 'createTime' },
|
|
|
];
|
|
|
+ const leaderArray = [
|
|
|
+ { title: '编号', key: 'id' },
|
|
|
+ { title: '内容', key: 'fkxq' },
|
|
|
+ ]
|
|
|
|
|
|
const getFormattedData = (listData) => {
|
|
|
+ const selectedArray = globalParameter.value.isLeader ? leaderArray : titleArray;
|
|
|
const formattedData = listData.map(item => {
|
|
|
- const formattedItem = titleArray.map(titleItem => {
|
|
|
+ const formattedItem = selectedArray.map(titleItem => {
|
|
|
let value = item[titleItem.key];
|
|
|
if (titleItem.key === 'createTime') {
|
|
|
value = formatDate(item[titleItem.key], '{y}-{m}-{d} {h}:{i}:{s}');
|
|
@@ -175,10 +180,6 @@
|
|
|
getList();
|
|
|
}
|
|
|
|
|
|
- const makeCall = ()=> {
|
|
|
- window.location.href = 'tel:023-67685085';
|
|
|
- }
|
|
|
-
|
|
|
const onClick = (e)=> {
|
|
|
link.goBJDetails(e.id)
|
|
|
}
|
|
@@ -187,22 +188,24 @@
|
|
|
}
|
|
|
|
|
|
onLoad((data) => {
|
|
|
- alert("onLoad:" + JSON.stringify(globalParameter.value))
|
|
|
+ // alert("onLoad:" + JSON.stringify(globalParameter.value))
|
|
|
queryParams.value.zjhm = aesDecrypt(data.hzsfzh)
|
|
|
let zjhm = aesDecrypt(data.hzsfzh)
|
|
|
let name = aesDecrypt(data.hzxm)
|
|
|
- globalParameter.value.zjhm = zjhm
|
|
|
- globalParameter.value.userName = name
|
|
|
})
|
|
|
|
|
|
onShow(() => {
|
|
|
- alert("onShow:" + JSON.stringify(globalParameter.value))
|
|
|
queryParams.value.pageNo = 1;
|
|
|
+ if (!globalParameter.value.zjhm || !globalParameter.value.userName || !globalParameter.value.authCode || !globalParameter.value.isLeader) {
|
|
|
+ queryParams.value.zjhm = localStorage.getItem('zjhm');
|
|
|
+ globalParameter.value.zjhm = localStorage.getItem('zjhm');
|
|
|
+ globalParameter.value.userName = localStorage.getItem('userName');
|
|
|
+ globalParameter.value.authCode = localStorage.getItem('authCode');
|
|
|
+ }
|
|
|
+ const isLeaderStr = localStorage.getItem('isLeader');
|
|
|
+ globalParameter.value.isLeader = isLeaderStr === 'true';
|
|
|
getList()
|
|
|
})
|
|
|
- onMounted(() => {
|
|
|
- alert("onMounted:" + JSON.stringify(globalParameter.value))
|
|
|
- });
|
|
|
</script>
|
|
|
|
|
|
|
|
@@ -211,7 +214,7 @@
|
|
|
display: flex;
|
|
|
background-color: #f2f2f2;
|
|
|
flex-direction: column;
|
|
|
- height: calc(100vh - 84rpx);
|
|
|
+ height: calc(100vh);
|
|
|
position: relative;
|
|
|
|
|
|
.scroll-view {
|
|
@@ -284,21 +287,5 @@
|
|
|
font-weight: 600;
|
|
|
}
|
|
|
}
|
|
|
- .footnote_content {
|
|
|
- background-color: #F6F7F8;
|
|
|
- @include flex-center;
|
|
|
- height: 136rpx;
|
|
|
- flex-direction: column;
|
|
|
- font-weight: 400;
|
|
|
- font-size: 24rpx;
|
|
|
- color: #B3B5B9;
|
|
|
- line-height: 40rpx;
|
|
|
- .footnote_phone {
|
|
|
- display: flex;
|
|
|
- .phone_text {
|
|
|
- color: #1E92F0;
|
|
|
- }
|
|
|
- }
|
|
|
- }
|
|
|
}
|
|
|
</style>
|