Compare commits
2 Commits
34b816ec44
...
31ff426acf
| Author | SHA1 | Date | |
|---|---|---|---|
| 31ff426acf | |||
| 3f1c64f9d4 |
|
Before Width: | Height: | Size: 746 B After Width: | Height: | Size: 22 KiB |
|
Before Width: | Height: | Size: 632 B After Width: | Height: | Size: 13 KiB |
|
Before Width: | Height: | Size: 715 B After Width: | Height: | Size: 15 KiB |
|
Before Width: | Height: | Size: 716 B After Width: | Height: | Size: 20 KiB |
|
Before Width: | Height: | Size: 683 B After Width: | Height: | Size: 8.8 KiB |
|
Before Width: | Height: | Size: 674 B After Width: | Height: | Size: 9.7 KiB |
BIN
FrontCode2/sunshine_levy/src/assets/img/zhuzhai.png
Normal file
|
After Width: | Height: | Size: 124 B |
@@ -7,12 +7,18 @@
|
|||||||
</div>
|
</div>
|
||||||
<div>
|
<div>
|
||||||
<div class="baseInfo">
|
<div class="baseInfo">
|
||||||
<van-image :src="require('@/assets/img/renyuanliebiao.png')" class="baseImg" />
|
<van-image
|
||||||
|
:src="require('@/assets/img/renyuanliebiao.png')"
|
||||||
|
class="baseImg"
|
||||||
|
/>
|
||||||
<span class="baseFont">被征收人姓名:</span>
|
<span class="baseFont">被征收人姓名:</span>
|
||||||
<span class="baseFont">{{ data.userName }}</span>
|
<span class="baseFont">{{ data.userName }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="baseInfo">
|
<div class="baseInfo">
|
||||||
<van-image :src="require('@/assets/img/credentials_icon.png')" class="baseImg" />
|
<van-image
|
||||||
|
:src="require('@/assets/img/credentials_icon.png')"
|
||||||
|
class="baseImg"
|
||||||
|
/>
|
||||||
<span class="baseFont">身份证号码:</span>
|
<span class="baseFont">身份证号码:</span>
|
||||||
<span class="baseFont">{{ data.idCard }}</span>
|
<span class="baseFont">{{ data.idCard }}</span>
|
||||||
</div>
|
</div>
|
||||||
@@ -21,22 +27,42 @@
|
|||||||
<div>
|
<div>
|
||||||
<div class="gridBg centerMagin">
|
<div class="gridBg centerMagin">
|
||||||
<div class="gridImg" style="background:#1897FB;">
|
<div class="gridImg" style="background:#1897FB;">
|
||||||
<van-image :src="require('@/assets/img/scan.png')" class="gridImgBg" />
|
<van-image
|
||||||
|
:src="require('@/assets/img/scan.png')"
|
||||||
|
class="gridImgBg"
|
||||||
|
/>
|
||||||
<span class="baseFont" style="padding-top: 5px;">扫一扫</span>
|
<span class="baseFont" style="padding-top: 5px;">扫一扫</span>
|
||||||
</div>
|
</div>
|
||||||
<div @click="gotoProject('pg')" class="gridImg" style="background:#F1AE4B;">
|
<div
|
||||||
<van-image :src="require('@/assets/img/evaluation.png')" class="gridImgBg" />
|
@click="gotoProject('pg')"
|
||||||
|
class="gridImg"
|
||||||
|
style="background:#F1AE4B;"
|
||||||
|
>
|
||||||
|
<van-image
|
||||||
|
:src="require('@/assets/img/evaluation.png')"
|
||||||
|
class="gridImgBg"
|
||||||
|
/>
|
||||||
<span class="baseFont" style="padding-top: 5px;">查评估结果</span>
|
<span class="baseFont" style="padding-top: 5px;">查评估结果</span>
|
||||||
</div>
|
</div>
|
||||||
<div @click="gotoProject('xy')" class="gridImg" style="background:#16D7ED;">
|
<div
|
||||||
<van-image :src="require('@/assets/img/compensation.png')" class="gridImgBg" />
|
@click="gotoProject('xy')"
|
||||||
|
class="gridImg"
|
||||||
|
style="background:#16D7ED;"
|
||||||
|
>
|
||||||
|
<van-image
|
||||||
|
:src="require('@/assets/img/compensation.png')"
|
||||||
|
class="gridImgBg"
|
||||||
|
/>
|
||||||
<span class="baseFont" style="padding-top: 5px;">查补偿协议</span>
|
<span class="baseFont" style="padding-top: 5px;">查补偿协议</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="centerMagin">
|
<div class="centerMagin">
|
||||||
<van-image :src="require('@/assets/img/government.png')" class="bigImg" />
|
<van-image
|
||||||
|
:src="require('@/assets/img/government.png')"
|
||||||
|
class="bigImg"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<!-- 项目内容 -->
|
<!-- 项目内容 -->
|
||||||
<van-list>
|
<van-list>
|
||||||
@@ -56,7 +82,10 @@
|
|||||||
</div>
|
</div>
|
||||||
<!-- 补偿协议图标 -->
|
<!-- 补偿协议图标 -->
|
||||||
<div class="projectRight">
|
<div class="projectRight">
|
||||||
<van-image :src="require('@/assets/img/menu_yhxy.png')" class="projectRightIcon" />
|
<van-image
|
||||||
|
:src="require('@/assets/img/menu_yhxy.png')"
|
||||||
|
class="projectRightIcon"
|
||||||
|
/>
|
||||||
<span class="projectRightFont">{{ item.currentState }}</span>
|
<span class="projectRightFont">{{ item.currentState }}</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -103,9 +132,7 @@
|
|||||||
/>
|
/>
|
||||||
<span class="projectCenterFont">征收决定号:</span>
|
<span class="projectCenterFont">征收决定号:</span>
|
||||||
<span class="projectCenterFont" style="color: #3883f1">
|
<span class="projectCenterFont" style="color: #3883f1">
|
||||||
{{
|
{{ item.zsjdh }}
|
||||||
item.zsjdh
|
|
||||||
}}
|
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -114,7 +141,10 @@
|
|||||||
<!-- 分户评估结果部分 -->
|
<!-- 分户评估结果部分 -->
|
||||||
<div class="assess">
|
<div class="assess">
|
||||||
<div>
|
<div>
|
||||||
<van-image :src="require('@/assets/img/assess_1.png')" class="assessIcon" />
|
<van-image
|
||||||
|
:src="require('@/assets/img/assess_1.png')"
|
||||||
|
class="assessIcon"
|
||||||
|
/>
|
||||||
<span class="assessTitle">分户评估结果</span>
|
<span class="assessTitle">分户评估结果</span>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -128,26 +158,33 @@
|
|||||||
>
|
>
|
||||||
<div class="assessBox">
|
<div class="assessBox">
|
||||||
<span class="projectCenterFont">评估报告编号:</span>
|
<span class="projectCenterFont">评估报告编号:</span>
|
||||||
<span class="projectCenterFont">{{ assess.assessmentNo }}</span>
|
<span class="projectCenterFont">{{
|
||||||
|
assess.assessmentNo
|
||||||
|
}}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="assessBox">
|
<div class="assessBox">
|
||||||
<span class="projectCenterFont" style="width: 40%">被征收房屋地址:</span>
|
<span class="projectCenterFont" style="width: 40%"
|
||||||
|
>被征收房屋地址:</span
|
||||||
|
>
|
||||||
<span class="projectCenterFont protocolTitle">
|
<span class="projectCenterFont protocolTitle">
|
||||||
{{
|
{{ assess.houseAddress }}
|
||||||
assess.houseAddress
|
|
||||||
}}
|
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="assessBox">
|
<div class="assessBox">
|
||||||
<span class="projectCenterFont">评估总金额:</span>
|
<span class="projectCenterFont">评估总金额:</span>
|
||||||
<span class="projectTitle" style="color: red">¥{{ assess.countValue }}</span>
|
<span class="projectTitle" style="color: red"
|
||||||
|
>¥{{ assess.countValue }}</span
|
||||||
|
>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</van-list>
|
</van-list>
|
||||||
<!-- 补偿协议部分 -->
|
<!-- 补偿协议部分 -->
|
||||||
<div class="assess">
|
<div class="assess">
|
||||||
<div>
|
<div>
|
||||||
<van-image :src="require('@/assets/img/assess_2.png')" class="assessIcon" />
|
<van-image
|
||||||
|
:src="require('@/assets/img/assess_2.png')"
|
||||||
|
class="assessIcon"
|
||||||
|
/>
|
||||||
<span class="assessTitle">补偿协议</span>
|
<span class="assessTitle">补偿协议</span>
|
||||||
</div>
|
</div>
|
||||||
<!-- <div>
|
<!-- <div>
|
||||||
@@ -167,27 +204,24 @@
|
|||||||
<span class="projectCenterFont">{{ protocol.xyNo }}</span>
|
<span class="projectCenterFont">{{ protocol.xyNo }}</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="assessBox">
|
<div class="assessBox">
|
||||||
<span class="projectCenterFont" style="width: 40%">被征收房屋地址:</span>
|
<span class="projectCenterFont" style="width: 40%"
|
||||||
|
>被征收房屋地址:</span
|
||||||
|
>
|
||||||
<span class="projectCenterFont protocolTitle">
|
<span class="projectCenterFont protocolTitle">
|
||||||
{{
|
{{ protocol.houseAddress }}
|
||||||
protocol.houseAddress
|
|
||||||
}}
|
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="assessBox">
|
<div class="assessBox">
|
||||||
<span class="projectCenterFont">补偿方式:</span>
|
<span class="projectCenterFont">补偿方式:</span>
|
||||||
<span class="projectCenterFont">
|
<span class="projectCenterFont">
|
||||||
{{
|
{{ protocol.switchProductionWay }}
|
||||||
protocol.switchProductionWay
|
|
||||||
}}
|
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
<div class="assessBox">
|
<div class="assessBox">
|
||||||
<span class="projectCenterFont">合计补偿资金:</span>
|
<span class="projectCenterFont">合计补偿资金:</span>
|
||||||
<span
|
<span class="projectTitle" style="color: red"
|
||||||
class="projectTitle"
|
>¥{{ protocol.summationShouldCompensateMoney }}</span
|
||||||
style="color: red"
|
>
|
||||||
>¥{{ protocol.summationShouldCompensateMoney }}</span>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</van-list>
|
</van-list>
|
||||||
@@ -197,16 +231,18 @@
|
|||||||
</van-list>
|
</van-list>
|
||||||
<!-- 征收政策背景图 -->
|
<!-- 征收政策背景图 -->
|
||||||
<div class="centerMagin">
|
<div class="centerMagin">
|
||||||
<van-image :src="require('@/assets/img/expropriationPolicy.png')" class="bigImg" />
|
<van-image
|
||||||
|
:src="require('@/assets/img/expropriationPolicy.png')"
|
||||||
|
class="bigImg"
|
||||||
|
/>
|
||||||
</div>
|
</div>
|
||||||
<!-- 征收政策部分 -->
|
<!-- 征收政策部分 -->
|
||||||
<div class="centerMagin">
|
<div class="centerMagin">
|
||||||
<span class="projectTitle" style="color: #202020">征收政策</span>
|
<span class="projectTitle" style="color: #202020">征收政策</span>
|
||||||
<div class="assessBox" style="padding-left: 5px; padding-right: 5px">
|
<div class="assessBox" style="padding-left: 5px; padding-right: 5px">
|
||||||
<span
|
<span class="font11" style="color: #2c2b2b"
|
||||||
class="font11"
|
>共{{ data.policiesRegulationsLists.totalCount }}条</span
|
||||||
style="color: #2c2b2b"
|
>
|
||||||
>共{{ data.policiesRegulationsLists.totalCount }}条</span>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="centerMagin" style="padding-bottom: 20px">
|
<div class="centerMagin" style="padding-bottom: 20px">
|
||||||
@@ -220,9 +256,15 @@
|
|||||||
v-for="(item, i) in data.policiesRegulationsLists.list"
|
v-for="(item, i) in data.policiesRegulationsLists.list"
|
||||||
>
|
>
|
||||||
<!-- 非最后一行 -->
|
<!-- 非最后一行 -->
|
||||||
<div class="protocolLine" v-if="i != data.policiesRegulationsLists.list.length - 1">
|
<div
|
||||||
|
class="protocolLine"
|
||||||
|
v-if="i != data.policiesRegulationsLists.list.length - 1"
|
||||||
|
>
|
||||||
<div class="font14 protocolTitle">{{ item.title }}</div>
|
<div class="font14 protocolTitle">{{ item.title }}</div>
|
||||||
<div class="assessBox" style="padding-left: 5px; padding-right: 5px">
|
<div
|
||||||
|
class="assessBox"
|
||||||
|
style="padding-left: 5px; padding-right: 5px"
|
||||||
|
>
|
||||||
<div>
|
<div>
|
||||||
<span class="font11">发布时间:</span>
|
<span class="font11">发布时间:</span>
|
||||||
<span class="font11">{{ item.publicTime }}</span>
|
<span class="font11">{{ item.publicTime }}</span>
|
||||||
@@ -236,7 +278,10 @@
|
|||||||
<!-- 最后一行 -->
|
<!-- 最后一行 -->
|
||||||
<div style="padding-bottom: 10px" v-else>
|
<div style="padding-bottom: 10px" v-else>
|
||||||
<div class="font14 protocolTitle">{{ item.title }}</div>
|
<div class="font14 protocolTitle">{{ item.title }}</div>
|
||||||
<div class="assessBox" style="padding-left: 5px; padding-right: 5px">
|
<div
|
||||||
|
class="assessBox"
|
||||||
|
style="padding-left: 5px; padding-right: 5px"
|
||||||
|
>
|
||||||
<div>
|
<div>
|
||||||
<span class="font11">发布时间:</span>
|
<span class="font11">发布时间:</span>
|
||||||
<span class="font11">{{ item.publicTime }}</span>
|
<span class="font11">{{ item.publicTime }}</span>
|
||||||
@@ -256,27 +301,27 @@
|
|||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script>
|
<script>
|
||||||
import './home.css';
|
import "./home.css";
|
||||||
import { apis } from '@/common/apis';
|
import { apis } from "@/common/apis";
|
||||||
import { mgop } from '@aligov/jssdk-mgop';
|
import { mgop } from "@aligov/jssdk-mgop";
|
||||||
import { SetTicket } from '@/common/util//tools';
|
import { SetTicket } from "@/common/util//tools";
|
||||||
export default {
|
export default {
|
||||||
name: 'home',
|
name: "home",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
data: {
|
data: {
|
||||||
idCard: '加载中...',
|
idCard: "加载中...",
|
||||||
userName: '加载中...',
|
userName: "加载中...",
|
||||||
policiesRegulationsLists: {
|
policiesRegulationsLists: {
|
||||||
totalCount: 0,
|
totalCount: 0
|
||||||
|
}
|
||||||
},
|
},
|
||||||
},
|
ticket: "8a11885a7bda783f017bf73e5e095219-ticket"
|
||||||
ticket: '8a1189377bdad67c017bf66039d76376-ticket',
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
async created() {
|
async created() {
|
||||||
this.onInit();
|
this.onInit();
|
||||||
console.log('this', this);
|
console.log("this", this);
|
||||||
this.setLocationAplus();
|
this.setLocationAplus();
|
||||||
SetTicket(this.$route.query.ticket || this.ticket);
|
SetTicket(this.$route.query.ticket || this.ticket);
|
||||||
},
|
},
|
||||||
@@ -284,16 +329,16 @@ export default {
|
|||||||
// 获取数据
|
// 获取数据
|
||||||
onInit() {
|
onInit() {
|
||||||
mgop({
|
mgop({
|
||||||
api: 'mgop.kykj.houseexpropriat.getprjlist',
|
api: "mgop.kykj.houseexpropriat.getprjlist",
|
||||||
host: 'https://mapi.zjzwfw.gov.cn/',
|
host: "https://mapi.zjzwfw.gov.cn/",
|
||||||
dataType: 'JSON',
|
dataType: "JSON",
|
||||||
type: 'POST',
|
type: "POST",
|
||||||
data: {
|
data: {
|
||||||
ticket: this.$route.query.ticket || this.ticket,
|
ticket: this.$route.query.ticket || this.ticket
|
||||||
},
|
},
|
||||||
appKey: 'es4b8zmz+2001833218+dehllx',
|
appKey: "es4b8zmz+2001833218+dehllx",
|
||||||
onSuccess: (data) => {
|
onSuccess: data => {
|
||||||
console.log('首页数据', data);
|
console.log("首页数据", data);
|
||||||
if (data.data && data.data.success == true) {
|
if (data.data && data.data.success == true) {
|
||||||
this.data = data.data.data;
|
this.data = data.data.data;
|
||||||
// 埋点
|
// 埋点
|
||||||
@@ -303,25 +348,25 @@ export default {
|
|||||||
// 跳转到政务系统;
|
// 跳转到政务系统;
|
||||||
if (errorCodes.indexOf(data.data.bizCode) > -1) {
|
if (errorCodes.indexOf(data.data.bizCode) > -1) {
|
||||||
window.location.replace(
|
window.location.replace(
|
||||||
'https://puser.zjzwfw.gov.cn/sso/mobile.do?action=oauth&scope=1&servicecode=fwzs'
|
"https://puser.zjzwfw.gov.cn/sso/mobile.do?action=oauth&scope=1&servicecode=fwzs"
|
||||||
);
|
);
|
||||||
} else console.log('用户无数据,不展示');
|
} else console.log("用户无数据,不展示");
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onFail: (err) => {
|
onFail: err => {
|
||||||
console.log('用户无数据,不展示');
|
console.log("用户无数据,不展示");
|
||||||
},
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 跳转项目详情
|
// 跳转项目详情
|
||||||
gotoProject(type, id) {
|
gotoProject(type, id) {
|
||||||
this.$router.push({
|
this.$router.push({
|
||||||
name: 'projectSelect',
|
name: "projectSelect",
|
||||||
params: {
|
params: {
|
||||||
type: type,
|
type: type,
|
||||||
ticket: this.$route.query.ticket || this.ticket,
|
ticket: this.$route.query.ticket || this.ticket,
|
||||||
prjId: id || this.data.prjList[0].prjId,
|
prjId: id || this.data.prjList[0].prjId
|
||||||
},
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 加载项目数统计信息
|
// 加载项目数统计信息
|
||||||
@@ -333,68 +378,68 @@ export default {
|
|||||||
// 政策信息页面跳转
|
// 政策信息页面跳转
|
||||||
pageJump(id) {
|
pageJump(id) {
|
||||||
this.$router.push({
|
this.$router.push({
|
||||||
name: 'policyInfo',
|
name: "policyInfo",
|
||||||
params: { ticket: this.ticket, id: id },
|
params: { ticket: this.ticket, id: id }
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
setZwUserAplus(Userid, userName) {
|
setZwUserAplus(Userid, userName) {
|
||||||
// 设置用户信息埋点
|
// 设置用户信息埋点
|
||||||
aplus_queue.push({
|
aplus_queue.push({
|
||||||
action: 'aplus.setMetaInfo',
|
action: "aplus.setMetaInfo",
|
||||||
arguments: ['_hold', 'BLOCK'],
|
arguments: ["_hold", "BLOCK"]
|
||||||
});
|
});
|
||||||
aplus_queue.push({
|
aplus_queue.push({
|
||||||
action: 'aplus.setMetaInfo',
|
action: "aplus.setMetaInfo",
|
||||||
arguments: ['_user_nick', userName], // this.userInfoData.username],
|
arguments: ["_user_nick", userName] // this.userInfoData.username],
|
||||||
});
|
});
|
||||||
aplus_queue.push({
|
aplus_queue.push({
|
||||||
action: 'aplus.setMetaInfo',
|
action: "aplus.setMetaInfo",
|
||||||
arguments: ['_user_id', Userid],
|
arguments: ["_user_id", Userid]
|
||||||
});
|
});
|
||||||
aplus_queue.push({
|
aplus_queue.push({
|
||||||
action: 'aplus.setMetaInfo',
|
action: "aplus.setMetaInfo",
|
||||||
arguments: ['_hold', 'START'],
|
arguments: ["_hold", "START"]
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
setLocationAplus() {
|
setLocationAplus() {
|
||||||
ZWJSBridge.onReady(() => {
|
ZWJSBridge.onReady(() => {
|
||||||
console.log('初始化完成后,执行bridge方法');
|
console.log("初始化完成后,执行bridge方法");
|
||||||
ZWJSBridge.getUserType()
|
ZWJSBridge.getUserType()
|
||||||
.then((result1) => {
|
.then(result1 => {
|
||||||
console.log('getUserType():' + JSON.stringify(result1));
|
console.log("getUserType():" + JSON.stringify(result1));
|
||||||
console.log('result1.userType:' + result1.userType);
|
console.log("result1.userType:" + result1.userType);
|
||||||
//经纬度
|
//经纬度
|
||||||
ZWJSBridge.getLocation()
|
ZWJSBridge.getLocation()
|
||||||
.then((result2) => {
|
.then(result2 => {
|
||||||
console.log('getLocation():' + JSON.stringify(result2));
|
console.log("getLocation():" + JSON.stringify(result2));
|
||||||
console.log('result2.longitude:' + result2.longitude);
|
console.log("result2.longitude:" + result2.longitude);
|
||||||
console.log('result2.latitude:' + result2.latitude);
|
console.log("result2.latitude:" + result2.latitude);
|
||||||
aplus_queue.push({
|
aplus_queue.push({
|
||||||
action: 'aplus.sendPV',
|
action: "aplus.sendPV",
|
||||||
arguments: [
|
arguments: [
|
||||||
{
|
{
|
||||||
is_auto: false,
|
is_auto: false
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
isMini: true,
|
isMini: true,
|
||||||
miniAppId: '2001833218', //'应用开发管理平台-应用 ID
|
miniAppId: "2001833218", //'应用开发管理平台-应用 ID
|
||||||
miniAppName: '房屋征收',
|
miniAppName: "房屋征收",
|
||||||
long: result2.longitude,
|
long: result2.longitude,
|
||||||
lati: result2.latitude,
|
lati: result2.latitude,
|
||||||
userType: result1.userType,
|
userType: result1.userType
|
||||||
},
|
}
|
||||||
],
|
]
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
.catch((error) => {
|
.catch(error => {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
});
|
});
|
||||||
})
|
})
|
||||||
.catch((error) => {
|
.catch(error => {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
},
|
}
|
||||||
},
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
137
FrontCode2/sunshine_levy/src/views/pdf/agreementInfo.vue
Normal file
@@ -0,0 +1,137 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
<div ref="content" class="content">
|
||||||
|
<!-- <pdf :src="url" class="PDF"></pdf> -->
|
||||||
|
</div>
|
||||||
|
<div class="bottom">
|
||||||
|
<a href="" download="">
|
||||||
|
<el-button type="primary">保存到相册</el-button>
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
<iframe
|
||||||
|
src="https://zsxt.nbzs.org.cn/Files/UploadFiles/e85a13ef-431c-46a5-85cd-9dd1b4f50fc6/80616f98-da17-49bc-92d0-b87199963787.pdf"
|
||||||
|
frameborder="0"
|
||||||
|
></iframe>
|
||||||
|
<!-- <el-button type="primary" @click="this.savePdf()">测试2</el-button>
|
||||||
|
<el-button type="primary" @click="this.handlePrint()">测试3</el-button>
|
||||||
|
<el-button type="primary" @click="testdownload4()">测试4</el-button>
|
||||||
|
<div id="nav">222</div> -->
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script src="https://cdn.bootcss.com/html2canvas/0.5.0-beta4/html2canvas.js"></script>
|
||||||
|
<script>
|
||||||
|
import pdf from "vue-pdf";
|
||||||
|
import $ from "jquery";
|
||||||
|
import html2canvas from "html2canvas";
|
||||||
|
// import axios from "axios";
|
||||||
|
import request from "@/common/util";
|
||||||
|
import { mgop } from "@aligov/jssdk-mgop";
|
||||||
|
export default {
|
||||||
|
components: {
|
||||||
|
pdf
|
||||||
|
},
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
url: ""
|
||||||
|
};
|
||||||
|
},
|
||||||
|
created() {
|
||||||
|
this.onInit();
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
// 截图
|
||||||
|
// html2canvas(this.$refs.PDF).then(canvas => {
|
||||||
|
// canvas.id = "mycanvas";
|
||||||
|
// const base64 = canvas.toDataURL("image/png");
|
||||||
|
// jquery("a").prop("href", base64);
|
||||||
|
// });
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
onInit() {
|
||||||
|
this.onLoadData();
|
||||||
|
request({
|
||||||
|
url: "http://10.19.94.9:7099/api/agreement/info",
|
||||||
|
method: "post",
|
||||||
|
data: {
|
||||||
|
ticket: window.sessionStorage.getItem("ticket"),
|
||||||
|
id: "C655515B-FD91-48F2-BD79-EAABAFB7077C"
|
||||||
|
},
|
||||||
|
headers: { "Content-Type": "application/json; charset=UTF-8" },
|
||||||
|
responseType: "arraybuffer" //一定要设置响应类型,否则页面会是空白pdf
|
||||||
|
}).then(result => {
|
||||||
|
console.log("请求成功了", result);
|
||||||
|
const binaryData = [];
|
||||||
|
binaryData.push(result.data);
|
||||||
|
//获取blob链接
|
||||||
|
this.url = window.URL.createObjectURL(
|
||||||
|
new Blob(binaryData, { type: "application/pdf" })
|
||||||
|
);
|
||||||
|
$("a").prop("href", this.url);
|
||||||
|
// if (pdfUrl) {
|
||||||
|
// this.handlePrint(pdfUrl);
|
||||||
|
// }
|
||||||
|
});
|
||||||
|
},
|
||||||
|
handlePrint() {
|
||||||
|
if (document.getElementById("print-iframe")) {
|
||||||
|
document.body.removeChild(document.getElementById("print-iframe"));
|
||||||
|
}
|
||||||
|
//判断iframe是否存在,不存在则创建iframe
|
||||||
|
let iframe = document.getElementById("print-iframe");
|
||||||
|
if (!iframe) {
|
||||||
|
iframe = document.createElement("IFRAME");
|
||||||
|
let doc = null;
|
||||||
|
iframe.setAttribute("src", this.url);
|
||||||
|
iframe.setAttribute("id", "print-iframe");
|
||||||
|
document.body.appendChild(iframe);
|
||||||
|
doc = iframe.contentWindow.document;
|
||||||
|
doc.close();
|
||||||
|
iframe.contentWindow.focus();
|
||||||
|
}
|
||||||
|
iframe.contentWindow.print();
|
||||||
|
},
|
||||||
|
savePdf() {
|
||||||
|
ZWJSBridge.onReady(() => {
|
||||||
|
console.log("初始化完成后,执行bridge方法-savePdf");
|
||||||
|
ZWJSBridge.saveImage({
|
||||||
|
url: this.url
|
||||||
|
})
|
||||||
|
.then(result => {
|
||||||
|
console.log("saveImage()成功:" + JSON.stringify(result));
|
||||||
|
})
|
||||||
|
.catch(error => {
|
||||||
|
console.log("saveImage()失败:" + JSON.stringify(result));
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
},
|
||||||
|
testdownload4() {
|
||||||
|
ZWJSBridge.onReady(() => {
|
||||||
|
console.log("初始化完成后,执行bridge方法-testdownload4");
|
||||||
|
ZWJSBridge.openLink({
|
||||||
|
url: this.url
|
||||||
|
})
|
||||||
|
.then(result => {
|
||||||
|
console.log("testdownload4():" + result);
|
||||||
|
})
|
||||||
|
.catch(error => {
|
||||||
|
console.log(error);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style lang="less" scoped>
|
||||||
|
.content {
|
||||||
|
text-align: center;
|
||||||
|
line-height: 200px;
|
||||||
|
font-size: 30px;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
.bottom {
|
||||||
|
text-align: center;
|
||||||
|
margin-bottom: 20px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
@@ -8,9 +8,10 @@
|
|||||||
<el-button type="primary">保存到相册</el-button>
|
<el-button type="primary">保存到相册</el-button>
|
||||||
</a>
|
</a>
|
||||||
</div>
|
</div>
|
||||||
<el-button type="primary" @click="this.savePdf()">测试2</el-button>
|
<iframe :src="url" frameborder="0"></iframe>
|
||||||
|
<!-- <el-button type="primary" @click="this.savePdf()">测试2</el-button>
|
||||||
<el-button type="primary" @click="this.handlePrint()">测试3</el-button>
|
<el-button type="primary" @click="this.handlePrint()">测试3</el-button>
|
||||||
<el-button type="primary" @click="testdownload4()">测试4</el-button>
|
<el-button type="primary" @click="testdownload4()">测试4</el-button> -->
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -24,44 +25,47 @@ import request from "@/common/util";
|
|||||||
import { mgop } from "@aligov/jssdk-mgop";
|
import { mgop } from "@aligov/jssdk-mgop";
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
pdf,
|
pdf
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
url: "",
|
url:
|
||||||
|
"https://zsxt.nbzs.org.cn/Files/UploadFiles/e85a13ef-431c-46a5-85cd-9dd1b4f50fc6/80616f98-da17-49bc-92d0-b87199963787.pdf"
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
this.onInit();
|
this.onInit();
|
||||||
console.log("pdf");
|
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
// 截图
|
// 截图
|
||||||
html2canvas(this.$refs.PDF).then((canvas) => {
|
// html2canvas(this.$refs.PDF).then(canvas => {
|
||||||
canvas.id = "mycanvas";
|
// canvas.id = "mycanvas";
|
||||||
const base64 = canvas.toDataURL("image/png");
|
// const base64 = canvas.toDataURL("image/png");
|
||||||
jquery("a").prop("href", base64);
|
// jquery("a").prop("href", base64);
|
||||||
});
|
// });
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
onInit() {
|
onInit() {
|
||||||
this.onLoadData();
|
// this.onLoadData();
|
||||||
request({
|
request({
|
||||||
url: "http://10.19.94.9:7099/api/agreement/info",
|
url: "http://10.19.94.9:7099/api/agreement/info",
|
||||||
method: "post",
|
method: "post",
|
||||||
data: {
|
data: {
|
||||||
ticket: window.sessionStorage.getItem("ticket"),
|
ticket: window.sessionStorage.getItem("ticket"),
|
||||||
id: "C655515B-FD91-48F2-BD79-EAABAFB7077C",
|
id: "C655515B-FD91-48F2-BD79-EAABAFB7077C"
|
||||||
},
|
},
|
||||||
headers: { "Content-Type": "application/json; charset=UTF-8" },
|
headers: { "Content-Type": "application/json; charset=UTF-8" },
|
||||||
responseType: "arraybuffer", //一定要设置响应类型,否则页面会是空白pdf
|
responseType: "blob" //一定要设置响应类型,否则页面会是空白pdf
|
||||||
}).then((result) => {
|
}).then(result => {
|
||||||
|
console.log("结果", result);
|
||||||
const binaryData = [];
|
const binaryData = [];
|
||||||
binaryData.push(result.data);
|
binaryData.push(result.data);
|
||||||
//获取blob链接
|
//获取blob链接
|
||||||
this.url = window.URL.createObjectURL(
|
const gan = window.URL.createObjectURL(
|
||||||
new Blob(binaryData, { type: "application/pdf" })
|
new Blob(binaryData, { type: "application/pdf" })
|
||||||
);
|
);
|
||||||
|
this.url = this.getObjectURL(result.data);
|
||||||
|
console.log("aaa", this.url);
|
||||||
$("a").prop("href", this.url);
|
$("a").prop("href", this.url);
|
||||||
// if (pdfUrl) {
|
// if (pdfUrl) {
|
||||||
// this.handlePrint(pdfUrl);
|
// this.handlePrint(pdfUrl);
|
||||||
@@ -73,31 +77,34 @@ export default {
|
|||||||
dataType: "JSON",
|
dataType: "JSON",
|
||||||
type: "POST",
|
type: "POST",
|
||||||
data: {
|
data: {
|
||||||
ticket: "8a1189377bdad67c017bf66039d76376-ticket",
|
ticket: window.sessionStorage.getItem("ticket"),
|
||||||
id: "C655515B-FD91-48F2-BD79-EAABAFB7077C",
|
id: "C655515B-FD91-48F2-BD79-EAABAFB7077C"
|
||||||
},
|
},
|
||||||
appKey: "es4b8zmz+2001833218+dehllx",
|
appKey: "es4b8zmz+2001833218+dehllx",
|
||||||
onSuccess: (result) => {
|
onSuccess: result => {
|
||||||
console.log("pdf.vue页面请求pdf文件:", result);
|
console.log("pdf.vue页面请求pdf文件:", result);
|
||||||
if (result.data && result.data.success == true) {
|
if (result.data && result.data.success == true) {
|
||||||
console.log("result.data.data:", result.data.data);
|
console.log("result.data.data:", result.data.data);
|
||||||
this.url = result.data.data;
|
// this.url = result.data.data;
|
||||||
// const binaryData = [];
|
const binaryData = [];
|
||||||
// binaryData.push(result.data);
|
binaryData.push(result.data.data);
|
||||||
// //获取blob链接
|
//获取blob链接
|
||||||
// this.url = window.URL.createObjectURL(
|
const gan = window.URL.createObjectURL(
|
||||||
// new Blob(binaryData, { type: "application/pdf" })
|
new Blob(binaryData, { type: "application/pdf" })
|
||||||
// );
|
);
|
||||||
|
this.url = this.getObjectURL(gan);
|
||||||
|
console.log("aaa", this.url);
|
||||||
// if (pdfUrl) {
|
// if (pdfUrl) {
|
||||||
// this.handlePrint(pdfUrl);
|
// this.handlePrint(pdfUrl);
|
||||||
// }
|
// }
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
onFail: (err) => {
|
onFail: err => {
|
||||||
console.log("用户无数据,不展示");
|
console.log("用户无数据,不展示");
|
||||||
},
|
}
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
handlePrint() {
|
handlePrint() {
|
||||||
if (document.getElementById("print-iframe")) {
|
if (document.getElementById("print-iframe")) {
|
||||||
document.body.removeChild(document.getElementById("print-iframe"));
|
document.body.removeChild(document.getElementById("print-iframe"));
|
||||||
@@ -124,12 +131,12 @@ export default {
|
|||||||
ZWJSBridge.onReady(() => {
|
ZWJSBridge.onReady(() => {
|
||||||
console.log("初始化完成后,执行bridge方法-savePdf");
|
console.log("初始化完成后,执行bridge方法-savePdf");
|
||||||
ZWJSBridge.saveImage({
|
ZWJSBridge.saveImage({
|
||||||
url: this.url,
|
url: this.url
|
||||||
})
|
})
|
||||||
.then((result) => {
|
.then(result => {
|
||||||
console.log("saveImage()成功:" + JSON.stringify(result));
|
console.log("saveImage()成功:" + JSON.stringify(result));
|
||||||
})
|
})
|
||||||
.catch((error) => {
|
.catch(error => {
|
||||||
console.log("saveImage()失败:" + JSON.stringify(result));
|
console.log("saveImage()失败:" + JSON.stringify(result));
|
||||||
console.log(error);
|
console.log(error);
|
||||||
});
|
});
|
||||||
@@ -139,17 +146,17 @@ export default {
|
|||||||
ZWJSBridge.onReady(() => {
|
ZWJSBridge.onReady(() => {
|
||||||
console.log("初始化完成后,执行bridge方法-testdownload4");
|
console.log("初始化完成后,执行bridge方法-testdownload4");
|
||||||
ZWJSBridge.openLink({
|
ZWJSBridge.openLink({
|
||||||
url: this.url,
|
url: this.url
|
||||||
})
|
})
|
||||||
.then((result) => {
|
.then(result => {
|
||||||
console.log("testdownload4():" + result);
|
console.log("testdownload4():" + result);
|
||||||
})
|
})
|
||||||
.catch((error) => {
|
.catch(error => {
|
||||||
console.log(error);
|
console.log(error);
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
},
|
}
|
||||||
},
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style lang="less" scoped>
|
<style lang="less" scoped>
|
||||||
@@ -158,6 +165,7 @@ export default {
|
|||||||
line-height: 200px;
|
line-height: 200px;
|
||||||
font-size: 30px;
|
font-size: 30px;
|
||||||
margin-bottom: 20px;
|
margin-bottom: 20px;
|
||||||
|
height: 200px;
|
||||||
}
|
}
|
||||||
.bottom {
|
.bottom {
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
|||||||
@@ -93,6 +93,9 @@ export default {
|
|||||||
// 获取数据
|
// 获取数据
|
||||||
onInit() {
|
onInit() {
|
||||||
this.type = this.$route.params.type;
|
this.type = this.$route.params.type;
|
||||||
|
if (this.$route.params.type) {
|
||||||
|
window.sessionStorage.setItem("type", this.$route.params.type);
|
||||||
|
}
|
||||||
this.ticket = this.$route.params.ticket;
|
this.ticket = this.$route.params.ticket;
|
||||||
mgop({
|
mgop({
|
||||||
api: "mgop.kykj.houseexpropriat.getprjlist",
|
api: "mgop.kykj.houseexpropriat.getprjlist",
|
||||||
@@ -115,7 +118,8 @@ export default {
|
|||||||
},
|
},
|
||||||
// 页面跳转
|
// 页面跳转
|
||||||
gotoDetail(id) {
|
gotoDetail(id) {
|
||||||
if (this.type == "pg") {
|
console.log("跳转了");
|
||||||
|
if (window.sessionStorage.getItem("type") == "pg") {
|
||||||
// 评估结果页面
|
// 评估结果页面
|
||||||
this.$router.push({
|
this.$router.push({
|
||||||
name: "evaluteResult",
|
name: "evaluteResult",
|
||||||
@@ -124,7 +128,7 @@ export default {
|
|||||||
ticket: this.$route.params.ticket
|
ticket: this.$route.params.ticket
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
} else if (this.type == "xy") {
|
} else if (window.sessionStorage.getItem("type") == "xy") {
|
||||||
// 协议结果页面
|
// 协议结果页面
|
||||||
this.$router.push({
|
this.$router.push({
|
||||||
name: "reportAgreement",
|
name: "reportAgreement",
|
||||||
|
|||||||
@@ -147,19 +147,25 @@ export default {
|
|||||||
margin: 14px 0;
|
margin: 14px 0;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
height: 20px;
|
||||||
b {
|
b {
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
img {
|
img {
|
||||||
margin-right: 6px;
|
margin-right: 6px;
|
||||||
|
height: 100%;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.flex {
|
.flex {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
|
> div {
|
||||||
|
height: 100%;
|
||||||
|
}
|
||||||
img {
|
img {
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
|
height: 100%;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
.line {
|
.line {
|
||||||
|
|||||||