更新正式版本

This commit is contained in:
路 范
2021-12-29 11:32:54 +08:00
parent fabb68741d
commit b1362f6e17
3 changed files with 115 additions and 151 deletions

View File

@@ -7,28 +7,28 @@
content="width=device-width,user-scalable=no,initial-scale=1.0,maximum-scale=1.0,minimum-scale=1.0" />
<title>宁波房屋征收</title>
<script>
// function getQueryString(name) {
// var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
// var r = window.location.search.substr(1).match(reg);
// if (r != null) return unescape(r[2]); return null;
// }
// console.log('1201-当前页面路径:' + location.href)
// var sp = getQueryString('sp');
// var ticket = getQueryString('ticket');
// if (sp)
// location.href = (sp + '&ticket=' + ticket)
// //debugger
// console.log('1201-url中ticket' + ticket)
// if (ticket)
// window.sessionStorage.setItem('ticket', ticket)
// else {
// if (!window.sessionStorage.getItem('ticket')) {
// // setTimeout(function () { window.close() }, 10);
// // location.replace('https://puser.zjzwfw.gov.cn/sso/mobile.do?action=oauth&scope=1&servicecode=fwzs')
// location.replace('https://puser.zjzwfw.gov.cn/sso/mobile.do?action=oauth&scope=1&servicecode=fwzs&goto=https://mapi.zjzwfw.gov.cn/web/mgop/gov-open/zj/2001833218/0.99997/index.html?debug=true')
// }
// console.log('有ticket正常进入,' + window.sessionStorage.getItem('ticket'))
// }
function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return unescape(r[2]); return null;
}
console.log('1201-当前页面路径:' + location.href)
var sp = getQueryString('sp');
var ticket = getQueryString('ticket');
if (sp)
location.href = (sp + '&ticket=' + ticket)
//debugger
console.log('1201-url中ticket' + ticket)
if (ticket)
window.sessionStorage.setItem('ticket', ticket)
else {
if (!window.sessionStorage.getItem('ticket')) {
// setTimeout(function () { window.close() }, 10);
location.replace('https://puser.zjzwfw.gov.cn/sso/mobile.do?action=oauth&scope=1&servicecode=fwzs')
//location.replace('https://puser.zjzwfw.gov.cn/sso/mobile.do?action=oauth&scope=1&servicecode=fwzs&goto=https://mapi.zjzwfw.gov.cn/web/mgop/gov-open/zj/2001833218/1.0/index.html?debug=true')
}
console.log('有ticket正常进入,' + window.sessionStorage.getItem('ticket'))
}
</script>
<script type="text/javascript" src="https://d.alicdn.com/alilog/mlog/aplus.js?id=202951085"></script>
<script type="text/javascript" src="//jssdk.yyhj.zjzwfw.gov.cn/jsbridge/v2.0.0/bridge.min.js"></script>

View File

@@ -39,36 +39,26 @@
</div> -->
<!-- 项目内容 -->
<div :key="item.prjId" v-for="(item, index) in data.prjList">
<div class="project">
<!-- window图标 -->
<div>
<!-- 上面展示的列表的问题 -->
<div class="TitList" v-on:click="absolute0_click($event, index, item)">
<div class="TitListLeft">
<div class="projectIcon">
<img src="@/assets/img/project.png" />
</div>
<span class="projectTitle">{{ item.name }}</span>
<span>
<div class="projectTitle">
{{ item.name }}
<van-icon
color="white"
:name="item.show ? 'arrow-down' : 'arrow'"
/>
</span>
<div class="absolute0"></div>
</div>
<!-- 补偿协议图标 -->
<div
class="projectRight"
v-on:click="absolute0_click($event, index, item)"
>
</div>
<div class="TitListRight">
<div>
<img src="@/assets/img/yhxy.png" />
</div>
<span>{{ item.currentState }}</span>
</div>
<div
class="absolute"
v-on:click="absolute_click($event, index, item)"
></div>
<!-- <div class="absolute" v-on:click="aaa"></div> -->
</div>
<div class="projectCenter" v-show="item.show">
<!-- 项目内容 -->
@@ -110,9 +100,9 @@
<van-icon
color="#2468f2"
:name="activeIndexSon === index + 0 ? 'arrow-down' : 'arrow'"
class="van-icon"
/>
<!-- <i></i>
-->
<div
class="absolute1"
v-on:click="absolute1_click($event, index, 0)"
@@ -154,6 +144,7 @@
<van-icon
color="#2468f2"
:name="activeIndexSonTwo === index + 1 ? 'arrow-down' : 'arrow'"
class="van-icon"
/>
<!-- <i></i>
-->
@@ -242,7 +233,7 @@
<script>
// import { apis } from "@/common/apis";
import { mgop } from "@aligov/jssdk-mgop";
import { SetTicket } from "@/common/util//tools";
// import { SetTicket } from "@/common/util//tools";
/*import { settestdata } from "@/common/util/test.js";*/
export default {
name: "home",
@@ -268,13 +259,22 @@ export default {
// settestdata();
// debugger
if (!sessionStorage.getItem("homeData")) {
console.log("1201-我是index的created的1.1");
this.onInit();
} else {
console.log("1201-我是index的created的1.2");
let d = JSON.parse(sessionStorage.getItem("homeData"));
if (d.data.data.prjList.length > 0) {
this.$set(d.data.data.prjList[0], "show", true);
} else {
d.data.data.prjList = [];
}
this.data = d.data.data;
}
console.log("1201-我是index的created的2");
this.setLocationAplus();
this.mode = this.$root.mode; //调用全局变量mode中的数据。
console.log("1201-我是index的created的3");
},
beforeRouteLeave(to, from, next) {
//debugger;
@@ -311,7 +311,7 @@ export default {
methods: {
// 获取数据
onInit() {
console.log("1201-我是index的onInit的5");
console.log("1201-我是index的onInit的15");
mgop({
api: "mgop.kykj.houseexpropriat.getprjlist",
host: "https://mapi.zjzwfw.gov.cn/",
@@ -323,11 +323,16 @@ export default {
},
appKey: "es4b8zmz+2001833218+dehllx",
onSuccess: (data) => {
console.log("1201-我是index的onInit的6");
console.log("1201-我是index的onInit的16");
this.loading = false;
window.sessionStorage.setItem("homeData", JSON.stringify(data));
if (data.data.success) {
if (data.data.data.prjList.length > 0) {
this.$set(data.data.data.prjList[0], "show", true);
} else {
data.data.data.prjList = [];
}
this.data = data.data.data;
// 埋点
this.setZwUserAplus(this.data.idCard, this.data.userName);
@@ -335,12 +340,11 @@ export default {
var errorCodes = [6001, 6501];
// 跳转到政务系统;
if (errorCodes.indexOf(data.data.bizCode) > -1) {
this.$toast({
message: "登录超时,请重新登录",
duration: 3000,
type: "info",
})
});
/* this.$message({
message: "登录超时,请重新登录",
duration: 3000,
@@ -357,7 +361,7 @@ export default {
message: "请求出错",
duration: 3000,
type: "info",
})
});
/* this.$message({
message: "请求出错",
@@ -370,7 +374,11 @@ export default {
},
onFail: (err) => {
this.loading = false;
this.$notify({ type: 'warning', message: '请求失败',duration: 3000, });
this.$notify({
type: "warning",
message: "请求失败",
duration: 3000,
});
/* this.$notify({
title: "错误",
message: "请求失败",
@@ -502,8 +510,8 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, });
message: data.text,
duration: 3000,
type: "info",
})
/*
});
/*
this.$message({
message: data.text,
duration: 3000,
@@ -557,6 +565,7 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, });
margin: 10px 12px 0 10px;
}
}
// 最上面盒子
.topBox {
background: url(~@/assets/img/bg.png) no-repeat;
@@ -641,19 +650,20 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, });
}
}
// 项目部分
.project {
//修改的项目部分
.TitList {
margin-top: 15px;
width: 100%;
height: 25px;
background-color: red;
display: flex;
align-items: center;
justify-content: space-between;
height: 41px;
background: url(~@/assets/img/project_bg.png) no-repeat 0 -2px/101% 120%;
position: relative;
> :nth-child(1) {
.TitListLeft {
display: flex;
align-items: center;
width: 50%;
height: 100%;
position: relative;
.projectIcon {
display: flex;
align-items: center;
@@ -668,32 +678,17 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, });
height: 25px;
}
}
span {
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
padding-right: 2px;
/* i {
display: inline-block;
height: 9px;
width: 9px;
border-right: 2px solid white;
border-bottom: 2px solid white;
transform: rotate(45deg);
margin-left: 7px;
} */
}
> :last-child {
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
.projectTitle {
display: flex;
align-items: center;
justify-content: center;
font-family: PingFangSC-Semibold, PingFang SC;
font-size: 16px;
font-weight: 600;
color: #fff;
}
}
.projectRight {
.TitListRight {
display: flex;
align-items: center;
height: 27px;
@@ -719,14 +714,8 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, });
line-height: 27px;
}
}
> :last-child {
position: absolute;
left: 0;
right: 0;
top: 0;
bottom: 0;
}
}
.projectTitle {
font-family: PingFangSC-Semibold, PingFang SC;
font-size: 16px;
@@ -968,63 +957,38 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, });
}
}
}
.project {
display: unset;
.projectTitle {
//修改的项目部分
.TitList {
.TitListLeft {
.projectIcon {
font-size: 24px;
}
> :nth-child(1) {
display: flex;
align-items: center;
height: 41px;
padding: unset 0;
width: 100%;
background: url(~@/assets/img/project_bg.png);
background-position: 0 -2px;
background-size: 100% 120%;
}
.projectRight {
/* */
/* margin-top: 10px;
height: 27px;
> :nth-child(1) {
border-radius: unset !important;
padding-right: 5px;
}
> span {
font-size: 20px;
border-radius: 0px 13px 13px 0px;
} */
display: flex;
align-items: center;
justify-content: right;
margin-top: -33px;
position: relative;
height: 27px;
margin-bottom: 15px;
> div {
background: #24bca3;
height: 100%;
display: flex;
align-items: center;
border-radius: 13px 0 0 13px;
img {
width: 17px;
width: 27px;
height: 27px;
}
}
.projectTitle {
font-size: 22px !important;
}
}
.TitListRight {
display: flex;
align-items: center;
height: 27px;
> div {
img {
width: 20px;
margin-right: 3px;
margin-left: 10px;
}
}
span {
font-size: 18px;
font-weight: 600;
padding-right: 10px;
color: #fff;
background: #24bca3;
height: 27px;
line-height: 27px;
font-size: 16px;
}
}
}
.projectCenterBox {
font-size: 20px;
> div {

View File

@@ -11,7 +11,7 @@ export default {
console.log("1201-我是中转页面的1");
console.log("1201-中专页面的路径:" + location.href);
//debugger;
this.$router.push("final2");
this.$router.push("final");
console.log("1201-我是中转页面的2");
},
methods: {},