update:更新页面

This commit is contained in:
2021-09-17 10:47:08 +08:00
parent c67d0c11a7
commit fa1bce7667
7 changed files with 309 additions and 113 deletions

View File

@@ -1,3 +1,4 @@
// 设置ticket
export function SetTicket(data) {
window.sessionStorage.setItem("ticket", data);
}

View File

@@ -26,10 +26,10 @@ export default new Router({
},
// 评估结果页面
{
path: "/report/compensate",
name: "reportCompensate",
path: "/report/evalute",
name: "evaluteResult",
component: () =>
import ("../views/report/compensate")
import ("../views/report/evalute")
},
// 协议结果页面
{

View File

@@ -23,6 +23,7 @@
<span class="baseFont">{{ data.idCard }}</span>
</div>
</div>
<!-- 三张背景图 -->
<div>
<div class="gridBg centerMagin">
<van-image
@@ -280,7 +281,6 @@
import "./home.css";
import { apis } from "@/common/apis";
import { mgop } from "@aligov/jssdk-mgop";
import { SetTicket } from "@/common/util/tools";
export default {
name: "home",
data() {
@@ -291,13 +291,13 @@ export default {
policiesRegulationsLists: {
totalCount: 0
}
}
},
ticket: "8a118afe7bda7976017bf14c94de35e0-ticket"
};
},
async created() {
this.onInit();
console.log("this", this);
SetTicket("8a1188557bda7894017bed584f803119-ticket");
},
methods: {
// 获取数据
@@ -308,8 +308,7 @@ export default {
dataType: "JSON",
type: "POST",
data: {
// ticket: this.$route.query.ticket
ticket: "8a1188557bda7894017bed584f803119-ticket"
ticket: this.ticket
},
appKey: "es4b8zmz+2001833218+dehllx",
onSuccess: data => {
@@ -337,7 +336,7 @@ export default {
gotoProject(type) {
this.$router.push({
name: "projectSelect",
params: { type: type, ticket: this.$route.query.ticket }
params: { type: type, ticket: this.ticket }
});
},
// 加载项目数统计信息
@@ -348,11 +347,10 @@ export default {
},
// 政策信息页面跳转
pageJump(id) {
// this.$router.push({
// name: "policyInfo",
// params: { type: type, ticket: this.$route.query.ticket }
// });
window.location.replace("http://localhost:8080/#/policyInfo?id=" + id);
this.$router.push({
name: "policyInfo",
params: { ticket: this.ticket, id: id }
});
},
setZwUserAplus(Userid, userName) {
// 设置用户信息埋点

View File

@@ -26,8 +26,8 @@ export default {
dataType: "JSON",
type: "POST",
data: {
ticket: window.sessionStorage.getItem("ticket"),
id: this.$route.query.id
ticket: this.$route.params.ticket,
id: this.$route.params.id
},
appKey: "es4b8zmz+2001833218+dehllx",
onSuccess: data => {

View File

@@ -1,17 +1,24 @@
<template>
<div>
<div :class="type == 'pg' ? 'proTopBoxpg': 'proTopBoxxy'">
<div :class="type == 'pg' ? 'proTopBoxpg' : 'proTopBoxxy'">
<div class="proCenterBox">
<div class="proCenterInfo">
<van-image :src="require('@/assets/img/expropriated_person.png')" class="proCenterImg" />
<van-image
:src="require('@/assets/img/expropriated_person.png')"
class="proCenterImg"
/>
<div>
<div>
<span class="proCenterFont">被征收人姓名</span>
<span class="proCenterFont" style="color:#626262;">{{user.name}}</span>
<span class="proCenterFont" style="color:#626262;">{{
info.userName
}}</span>
</div>
<div>
<span class="proCenterFont">身份证号</span>
<span class="proCenterFont" style="color:#626262;">{{user.identityId}}</span>
<span class="proCenterFont" style="color:#626262;">{{
info.idCard
}}</span>
</div>
</div>
</div>
@@ -27,23 +34,23 @@
:key="item.id"
@click="gotoDetail(item.id)"
class="proListBox shadow"
v-for="(item) in list"
v-for="item in info.prjList"
>
<div class="proAreaBox">
<div class="proArea">{{item.area}}</div>
<div class="proCenterFont" v-if="item.state_cd == 1">· {{item.state}}</div>
<div
class="proCenterFont"
style="color:#179D5C"
v-else-if="item.state_cd == 2"
>· {{item.state}}</div>
<div class="proArea">{{ item.area }}</div>
<div class="proCenterFont" v-if="item.state_cd == 1">
· {{ item.currentState }}
</div>
<div class="proCenterFont" style="color:#179D5C" v-else>
· {{ item.currentState }}
</div>
</div>
<div class="proAreaBox">
<div class="proTitleBox">{{item.title}}</div>
<div class="proTitleBox">{{ item.zsbm }}</div>
</div>
<van-divider style="margin:8px 0;" />
<div class="proDateBox">
<div>{{item.date}}</div>
<div>{{ item.year }}</div>
</div>
</div>
</van-list>
@@ -52,80 +59,77 @@
</template>
<script>
import './project.css';
import { apis } from '@/common/apis';
import "./project.css";
import { mgop } from "@aligov/jssdk-mgop";
export default {
data() {
return {
loading: true,
type: '',
type: "",
data: new Object(),
user: {
name: '胡伯钧',
identityId: '3302041982893743782',
},
list: [
{
id: 11,
area: '镇海区',
title: '郁金花园北块地',
date: '2021-09-08',
state_cd: '1',
state: '协议签订阶段',
},
{
id: 22,
area: '象山县',
title: '象山县人民广场周边区块改造项目',
date: '2021-09-08',
state_cd: '2',
state: '项目已报结',
},
// {
// id: 33,
// area: '全大市',
// title: '宁波市住房和城乡建设委员会开展关于住房的政策',
// date: '2021年09月05日',
// state_cd: '0',
// state: '测试',
// },
],
loading: false,
finished: true,
ticket: '',
// 初始数据
info: {
userName: "无数据",
idCard: "无数据",
prjList: [
{
area: "无数据",
currentState: "无数据",
zsbm: "无数据",
year: "无数据"
}
]
}
};
},
created() {
this.onInit();
this.onLoadData();
},
methods: {
onInit() {
this.onLoadData();
mgop({
api: "mgop.kykj.houseexpropriat.getprjlist",
host: "https://mapi.zjzwfw.gov.cn/",
dataType: "JSON",
type: "POST",
data: {
ticket: this.$route.params.ticket
},
appKey: "es4b8zmz+2001833218+dehllx",
onSuccess: data => {
console.log("首页数据", data);
const { data: res } = data;
this.info = res.data;
},
onFail: err => {
console.log("用户无数据,不展示");
}
});
},
onLoadData() {
// apis.mailDetail({ id: this.$route.query.id }).then(({ result }) => {
// this.loading = false;
// this.data = result;
// });
this.type = this.$route.params.type;
this.ticket = this.$route.params.ticket;
},
gotoDetail(id) {
if (this.type == 'pg') {
if (this.type == "pg") {
// 评估结果页面
this.$router.push({
name: 'reportCompensate',
params: { projectid: id, type: this.type, ticket: this.ticket },
name: "evaluteResult",
params: { projectid: id, type: this.type, ticket: this.ticket }
});
} else if (this.type == 'xy') {
} else if (this.type == "xy") {
// 协议结果页面
this.$router.push({ name: 'reportAgreement', params: { projectid: id, type: this.type, ticket: this.ticket } });
this.$router.push({
name: "reportAgreement",
params: { projectid: id, type: this.type, ticket: this.ticket }
});
}
},
},
}
}
};
</script>
<style>
</style>
<style></style>

View File

@@ -3,33 +3,39 @@
<div class="image">
<img alt src="@/assets/img/agreement.png" />
</div>
<div class="text">为您查询到{{ this.result }}条结果</div>
<div :key="index" @click="showPdf(item.url)" v-for="(item, index) in info">
<div class="text">
为您查询到{{ this.info.prjList[0].bcxyList.length }}条结果
</div>
<div
:key="index"
@click="showPdf(item.url)"
v-for="(item, index) in info.prjList[0].bcxyList"
>
<el-card body-style="padding:10px 10px 0">
<div>
<img alt src="@/assets/img/bianhao.png" />
评估报告编号
<b>{{ item.number }}</b>
<b>{{ info.prjList[0].fhpgList[0].assessmentNo }}</b>
</div>
<div>
<img alt src="@/assets/img/name.png" />
被征收人姓名
<b>{{ item.name }}</b>
<b>{{ info.userName }}</b>
</div>
<div>
<img alt src="@/assets/img/address.png" />
被征收人房屋地址
<b>{{ item.address }}</b>
<b>{{ item.houseAddress }}</b>
</div>
<div>
<img alt src="@/assets/img/money.png" />
评估总金额
<b style="color: red">{{ item.money }}</b>
<b style="color: red">{{ info.prjList[0].fhpgList[0].countValue }}</b>
</div>
<div>
<img alt src="@/assets/img/money.png" />
合计补偿金额
<b style="color: red">{{ item.money }}</b>
<b style="color: red">{{ item.summationShouldCompensateMoney }}</b>
</div>
<div class="line">
<img alt src="@/assets/img/hengxian.png" />
@@ -37,7 +43,7 @@
<div class="flex">
<div class="flex backgroundColor">
<img alt src="@/assets/img/shijian.png" />
<span>签订日期{{ item.time }}</span>
<span>签订日期{{ item.date }}</span>
</div>
</div>
</el-card>
@@ -45,35 +51,48 @@
</div>
</template>
<script>
import { mgop } from "@aligov/jssdk-mgop";
export default {
data() {
return {
result: '2',
info: [
{
number: '044',
name: '胡守钧',
address: '宁波市江北区四洲街16号404',
money: '180234元',
person: '王勇',
time: '2021-9-1',
url: '',
},
{
number: '044',
name: '胡守钧',
address: '宁波市江北区四洲街16号404',
money: '180234元',
person: '王勇',
time: '2021-9-1',
url: '',
},
],
result: "2",
info: {
userName: "无数据",
prjList: [
{
bcxyList: [
{
houseAddress: "无数据",
summationShouldCompensateMoney: "无数据",
date: "无数据"
}
],
fhpgList: [{ countValue: "无数据", assessmentNo: "无数据" }]
}
]
}
};
},
created() {
this.onInit();
console.log(1234);
mgop({
api: "mgop.kykj.houseexpropriat.getprjlist",
host: "https://mapi.zjzwfw.gov.cn/",
dataType: "JSON",
type: "POST",
data: {
ticket: this.$route.params.ticket
},
appKey: "es4b8zmz+2001833218+dehllx",
onSuccess: data => {
const { data: res } = data.data;
console.log("res", res);
this.info = res;
},
onFail: err => {
console.log("用户无数据,不展示");
}
});
},
methods: {
onInit() {
@@ -84,10 +103,10 @@ export default {
this.type = this.$route.params.type;
},
showPdf(url) {
url = '';
this.$router.push({ name: 'showPdf', params: { url: url } });
},
},
url = "";
this.$router.push({ name: "showPdf", params: { url: url } });
}
}
};
</script>
<style>

View File

@@ -0,0 +1,174 @@
<template>
<div class="container">
<div class="image">
<img alt src="@/assets/img/evalute.png" />
</div>
<div class="text">
为您查询到{{ this.info.prjList[0].fhpgList.length }}条结果
</div>
<div
:key="index"
v-for="(item, index) in info.prjList[0].fhpgList"
@click="pageJump()"
>
<el-card body-style="padding:10px">
<div>
<img alt src="@/assets/img/bianhao.png" />
评估报告编号
<b>{{ item.assessmentNo }}</b>
</div>
<div>
<img alt src="@/assets/img/name.png" />
被征收人姓名
<b>{{ info.userName }}</b>
</div>
<div>
<img alt src="@/assets/img/address.png" />
被征收人房屋地址
<b>{{ item.houseAddress }}</b>
</div>
<div>
<img alt src="@/assets/img/money.png" />
评估总金额
<b style="color: red">{{ item.countValue }}</b>
</div>
<div class="line">
<img alt src="@/assets/img/hengxian.png" />
</div>
<div class="content">
<div class=" backgroundColor">
<img alt src="@/assets/img/renyuan.png" />
<span> 评估人员{{ item.person }}</span>
</div>
<div class="backgroundColor">
<img alt src="@/assets/img/shijian.png" />
<span> 评估时间{{ item.time }}</span>
</div>
</div>
</el-card>
</div>
</div>
</template>
<script>
import { mgop } from "@aligov/jssdk-mgop";
export default {
data() {
return {
info: {
userName: "无数据",
prjList: [
{
fhpgList: [
{
assessmentNo: "无数据",
houseAddress: "无数据",
countValue: "无数据",
person: "无数据",
time: "无数据"
}
]
}
]
}
};
},
created() {
this.onInit();
},
methods: {
onInit() {
this.onLoadData();
mgop({
api: "mgop.kykj.houseexpropriat.getprjlist",
host: "https://mapi.zjzwfw.gov.cn/",
dataType: "JSON",
type: "POST",
data: {
ticket: this.$route.params.ticket
},
appKey: "es4b8zmz+2001833218+dehllx",
onSuccess: data => {
const { data: res } = data.data;
console.log("res", res);
this.info = res;
},
onFail: err => {
console.log("用户无数据,不展示");
}
});
},
onLoadData() {
console.log(this.$route.params);
this.type = this.$route.params.type;
},
pageJump(type) {
this.$router.push({
name: "evaluteResult",
params: { type: type, ticket: this.$route.query.ticket }
});
}
}
};
</script>
<style lang="less" scoped>
.container {
font-size: 12px;
.image {
margin-top: 20px;
text-align: center;
img {
width: 90%;
}
}
.text {
font-weight: bolder;
margin: 10px 0;
text-align: center;
color: #2d6df2;
}
.el-card {
margin: 0 10px 10px;
.el-card__body {
> div {
margin: 14px 0;
display: flex;
align-items: center;
img {
margin-right: 6px;
}
b {
font-size: 14px;
}
}
.line {
opacity: 1;
img {
width: 100%;
}
img {
height: 2px;
}
}
.content {
display: flex;
justify-content: space-between;
> div {
display: flex;
align-items: center;
}
.backgroundColor {
background-color: #e3ebfd;
img {
margin-right: 10px;
}
span {
padding-right: 10px;
}
}
}
}
}
}
</style>