@@ -53,6 +53,7 @@ | |||
"@dcloudio/uni-mp-weixin": "3.0.0-3081220230817001", | |||
"@dcloudio/uni-quickapp-webview": "3.0.0-3081220230817001", | |||
"dayjs": "^1.10.4", | |||
"html2canvas": "^1.4.1", | |||
"less": "^4.2.0", | |||
"less-loader": "^11.1.3", | |||
"mp-html": "^2.4.1", | |||
@@ -11,36 +11,36 @@ import request from '../utils/request'; | |||
* 获得banner图分页 | |||
* @param {*} data | |||
*/ | |||
const getBannerApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/banner/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
const getBannerApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/banner/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 获得字典类型的分页列表 | |||
* @param {*} data | |||
*/ | |||
const getDictDataApi = function (data) { | |||
return request({ | |||
url: '/admin-api/system/dict-data/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
const getDictDataApi = function(data) { | |||
return request({ | |||
url: '/admin-api/system/dict-data/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 上传文件 | |||
* @param {*} data | |||
*/ | |||
const uploadApi = function (data) { | |||
return request({ | |||
url: '/admin-api/infra/file/upload', | |||
method: 'post', | |||
data: data | |||
}); | |||
const uploadApi = function(data) { | |||
return request({ | |||
url: '/admin-api/infra/file/upload', | |||
method: 'post', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
@@ -49,161 +49,174 @@ const uploadApi = function (data) { | |||
* @param {*} data.bannerType // 字典TabBar模块 1民生、2生活... | |||
* @param {*} data.parentId // 根据上级列表id查询下级列表 | |||
*/ | |||
const recursionApi = function (data) { | |||
return request( | |||
{ | |||
url: '/admin-api/people/category/recursion', | |||
method: 'get', | |||
data: data | |||
}, | |||
false | |||
); | |||
const recursionApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/category/recursion', | |||
method: 'get', | |||
data: data | |||
}, | |||
false | |||
); | |||
}; | |||
/** | |||
* 创建点赞 | |||
* @param {*} data | |||
*/ | |||
const praiseCreateApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/praise/create', | |||
method: 'post', | |||
data: data | |||
}); | |||
const praiseCreateApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/praise/create', | |||
method: 'post', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 取消点赞 | |||
* @param {*} data | |||
*/ | |||
const praiseCancelApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/praise/cancel', | |||
method: 'post', | |||
data: data | |||
}); | |||
const praiseCancelApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/praise/cancel', | |||
method: 'post', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 创建分享 | |||
* @param {*} data | |||
*/ | |||
const shareCreateApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/share/create', | |||
method: 'post', | |||
data: data | |||
}); | |||
const shareCreateApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/share/create', | |||
method: 'post', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 创建用户收藏 | |||
* @param {*} data | |||
*/ | |||
const collectionCreateApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/collection/create', | |||
method: 'post', | |||
data: data | |||
}); | |||
const collectionCreateApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/collection/create', | |||
method: 'post', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 取消用户收藏 | |||
* @param {*} data | |||
*/ | |||
const collectionCancelApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/collection/cancel', | |||
method: 'post', | |||
data: data | |||
}); | |||
const collectionCancelApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/collection/cancel', | |||
method: 'post', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 获得案件处理过程分页 | |||
* @param {*} data | |||
*/ | |||
const casesProcessPageApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/cases-process/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
const casesProcessPageApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/cases-process/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 获取部门树 | |||
* @param {*} data | |||
*/ | |||
const deptTreeApi = function (data) { | |||
return request({ | |||
url: '/admin-api/system/dept/tree', | |||
method: 'get', | |||
data: data | |||
}); | |||
const deptTreeApi = function(data) { | |||
return request({ | |||
url: '/admin-api/system/dept/tree', | |||
method: 'get', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 获得服务记录详情 | |||
* @param {*} data | |||
*/ | |||
const serveRecordGetApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/serve-record/get', | |||
method: 'get', | |||
data: data | |||
}); | |||
const serveRecordGetApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/serve-record/get', | |||
method: 'get', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 获得服务记录分页 | |||
* @param {*} data | |||
*/ | |||
const serveRecordPageApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/serve-record/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
const serveRecordPageApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/serve-record/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 获得线上问诊分页 | |||
* @param {*} data | |||
*/ | |||
const inquiriesOnlinePageApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/inquiries-online/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
const inquiriesOnlinePageApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/inquiries-online/page', | |||
method: 'get', | |||
data: data | |||
}); | |||
}; | |||
/** | |||
* 获得线上问诊详情 | |||
* @param {*} data | |||
*/ | |||
const inquiriesOnlineGetApi = function (data) { | |||
return request({ | |||
url: '/admin-api/people/inquiries-online/get', | |||
method: 'get', | |||
data: data | |||
}); | |||
const inquiriesOnlineGetApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/inquiries-online/get', | |||
method: 'get', | |||
data: data | |||
}); | |||
}; | |||
export { | |||
getBannerApi, | |||
getDictDataApi, | |||
uploadApi, | |||
recursionApi, | |||
praiseCreateApi, | |||
praiseCancelApi, | |||
shareCreateApi, | |||
collectionCreateApi, | |||
collectionCancelApi, | |||
casesProcessPageApi, | |||
deptTreeApi, | |||
serveRecordGetApi, | |||
serveRecordPageApi, | |||
inquiriesOnlineGetApi, | |||
inquiriesOnlinePageApi | |||
/** | |||
* 获得线上问诊详情 | |||
* @param {*} data | |||
*/ | |||
const categorygetApi = function(data) { | |||
return request({ | |||
url: '/admin-api/people/category/get', | |||
method: 'get', | |||
data: data | |||
}); | |||
}; | |||
export { | |||
getBannerApi, | |||
getDictDataApi, | |||
uploadApi, | |||
recursionApi, | |||
praiseCreateApi, | |||
praiseCancelApi, | |||
shareCreateApi, | |||
collectionCreateApi, | |||
collectionCancelApi, | |||
casesProcessPageApi, | |||
deptTreeApi, | |||
serveRecordGetApi, | |||
serveRecordPageApi, | |||
inquiriesOnlineGetApi, | |||
inquiriesOnlinePageApi, | |||
categorygetApi | |||
}; |
@@ -11,6 +11,7 @@ | |||
</swiper-item> | |||
</block> | |||
</swiper> | |||
<view class="guide-list flex" v-if="option.name === '五星党员'"> | |||
<view class="guide-item flex flex-col flex-v-center" :data-id="item.id" @tap="jumpDetail" | |||
v-for="(item, index) in doctorPageList" :key="index"> | |||
@@ -31,10 +32,10 @@ | |||
</view> | |||
<block v-if="option.path === 'sonGuide3'"> | |||
<view class="second-section-gird"> | |||
<!-- <view class="second-section-gird"> | |||
<view :class="songuid == 1 ? 'action' :''" @click="headerSonguid(1)">村务监督</view> | |||
<view :class="songuid == 2 ? 'action' :''" @click="headerSonguid(2)">在线投诉</view> | |||
</view> | |||
</view> --> | |||
<view class="rural-list flex"> | |||
<view class="guide-item flex flex-col flex-v-center" :data-item="item" @tap="toArea" | |||
v-for="(item, index) in agencyPageList" :key="index"> | |||
@@ -1,35 +1,65 @@ | |||
<template> | |||
<view> | |||
<custom-nav-bar position="fixed" color="black" :left-text="optins.name" left-arrow /> | |||
<custom-nav-bar position="fiexd" color="block" v-if="getCategorygetList === null" :left-text="optins.name" | |||
left-arrow /> | |||
<custom-nav-bar v-else :left-text="optins.name" left-arrow /> | |||
<web-view v-if="optins.name === '手机充值' || optins.name === '生活缴费'" :src="url"></web-view> | |||
<view v-else class="web-view-image"> | |||
<view v-if="optins.name === '随手拍'"> | |||
<image class="img" mode="aspectFit" src="/static/images/WechatIMG8826.jpg" /> | |||
<view v-if="optins.name === '随手拍'" style="margin-top: 100rpx;"> | |||
<image class="img" mode="aspectFit" ref="imgSrc" @click="Download" | |||
src="https://jiexiu.xuqidata.com:8083/jiexiujumin/be5140bf13039c546a08f2ec60fd18dee3341d442b281fe93dba0a2a2a1bdf96.jpg" /> | |||
<view style="padding:20rpx 100rpx;font-size:30rpx;line-height: 54rpx;"> | |||
长按图片前往“民生介休”公众号或保存图片并扫码,关注“民生介休”公众号 | |||
即可发布随手拍。 | |||
</view> | |||
</view> | |||
<view v-if="optins.name === '智慧社区'"> | |||
<image class="img" mode="aspectFit" src="/static/images/WechatIMG8889.jpg" /> | |||
<view v-else-if="optins.name === '智慧社区'"> | |||
<image class="img" mode="aspectFit" ref="imgSrc" @click="Download" | |||
src="https://jiexiu.xuqidata.com:8083/jiexiujumin/ebce776f2737a8a74d99cb55c9d01ce009611bcc984dcf7c1735f87defcbd7f3.jpg" /> | |||
<view style="padding:20rpx 100rpx;font-size:30rpx;line-height: 54rpx;"> | |||
图片保存到手机本地,打开微信扫码此图片,前往“介休智慧示范社区服务端了解相关小区的智慧便民服务 | |||
</view> | |||
</view> | |||
<view v-else> | |||
<swiper class="people-custom-swiper" v-if="imageList" :indicator-color="indicatorColor" | |||
:indicator-active-color="indicatorActiveColor"> | |||
<!-- <block v-for="(item, index) in imageList" :key="index" @click="jumpDetails"> --> | |||
<swiper-item> | |||
<!-- <navigator v-if="item.clickUrl" open-type="navigate" class="line-navigator" :url="item.clickUrl" hover-class="none"></navigator> --> | |||
<image class="custom-swiper-img" :src="imageList.icon"></image> | |||
</swiper-item> | |||
<!-- </block> --> | |||
</swiper> | |||
<image class="img" mode="aspectFit" v-if="getCategorygetList" @click="Download" ref="imgSrc" | |||
:src="getCategorygetList.icon" /> | |||
<view style="padding:20rpx 100rpx;font-size:30rpx;line-height: 54rpx;text-align: left;"> | |||
基层小微权力“监督一点通”平台聚焦群众身边腐败和作风问题,是为解决群众诉求、引导群众参与监督的服务平台,专门负责监督基层小微权力运行,督促解决群众身边的操心事、烦心事、揪心事。 | |||
</view> | |||
</view> | |||
</view> | |||
</view> | |||
</template> | |||
<script> | |||
// const app = getApp(); | |||
import * as publicApi from '@/api/publicApi.js'; // 公共 API | |||
import html2canvas from 'html2canvas'; | |||
export default { | |||
data() { | |||
return { | |||
indicatorColor: 'rgba(255,255,255,0.4)', | |||
indicatorActiveColor: '#FFFFFF', | |||
optins: { | |||
name: '' | |||
}, | |||
url: '' | |||
url: '', | |||
imageList: null, | |||
getCategorygetList: null | |||
}; | |||
}, | |||
onLoad(optins) { | |||
@@ -53,8 +83,36 @@ | |||
} | |||
console.log(url) | |||
this.url = url | |||
this.getCategorygetApi(); | |||
}, | |||
methods: {} | |||
methods: { | |||
async getCategorygetApi() { | |||
const res = await publicApi.recursionApi({ | |||
bannerType: 1, | |||
parentId: this.optins.parentId | |||
}); | |||
if (res.data) { | |||
this.imageList = res.data[0] || null | |||
this.getCategorygetList = res.data[1] || null | |||
console.log(res) | |||
} | |||
}, | |||
Download() { | |||
console.log(this.$refs.imgSrc.src) | |||
// html2canvas(this.$refs.imgSrc, { | |||
// useCORS: true | |||
// }).then(canvas => { | |||
const file = document.createElement("a"); | |||
file.style.display = "none"; | |||
file.href = this.$refs.imgSrc.src | |||
// file.download = decodeURI(this.optins.name); | |||
document.body.appendChild(file); | |||
file.click(); | |||
document.body.removeChild(file); | |||
// }); | |||
} | |||
} | |||
}; | |||
</script> | |||
<style lang="less"> | |||
@@ -69,7 +127,7 @@ | |||
position: absolute; | |||
text-align: center; | |||
transform: translate(-50% -50%); | |||
margin-top: 100rpx; | |||
// margin-top: 100rpx; | |||
} | |||
.img { | |||
@@ -79,4 +137,16 @@ | |||
// width: 750rpx; | |||
// height: 1334rpx; | |||
} | |||
.people-custom-swiper { | |||
width: 100%; | |||
height: 330rpx; | |||
position: relative; | |||
.custom-swiper-img { | |||
width: 100%; | |||
height: 100%; | |||
display: block; | |||
} | |||
} | |||
</style> |
@@ -42,14 +42,14 @@ | |||
</view> | |||
<view class="second-model flex flex-v-center flex-between" v-else> | |||
<view :class="'second-line flex flex-col ' + (idx === 0 || idx === 5 ? 'line1' : '')" | |||
:style="itemName.cssStyle" v-for="(itemName, idx) in item.children" :key="idx"> | |||
<view :class="'second-line flex flex-col ' + (idx === 0 ? 'line1' : '')" :style="itemName.cssStyle" | |||
v-for="(itemName, idx) in item.children" :key="idx"> | |||
<navigator v-if="itemName.clickUrl" class="line-navigator" :url="updateQuery(itemName.clickUrl, itemName)" | |||
hover-class="none"></navigator> | |||
<image class="line-bg" :src="itemName.icon"></image> | |||
<view class="line-title">{{ itemName.name }}</view> | |||
<view class="line-title" :style="itemName.sort === 6 ? 'font-size:24rpx':''">{{ itemName.name }}</view> | |||
<view v-if="itemName.remark" class="line-msg">{{ itemName.remark }}</view> | |||
</view> | |||