diff --git a/FrontCode2/sunshine_levy/src/common/util/test.js b/FrontCode2/sunshine_levy/src/common/util/test.js index eab011c..4087e14 100644 --- a/FrontCode2/sunshine_levy/src/common/util/test.js +++ b/FrontCode2/sunshine_levy/src/common/util/test.js @@ -10,6 +10,7 @@ export const settestdata = function () { idCard: "330226198811175590", prjList: [ { + // show:true, prjId: "e85a13ef-431c-46a5-85cd-9dd1b4f50fc6", area: "海曙区", name: "测试项目1", diff --git a/FrontCode2/sunshine_levy/src/views/test.vue b/FrontCode2/sunshine_levy/src/views/test.vue index dfd1eba..ce0b77d 100644 --- a/FrontCode2/sunshine_levy/src/views/test.vue +++ b/FrontCode2/sunshine_levy/src/views/test.vue @@ -39,37 +39,27 @@ -->
-
- -
-
+ + +
+
+
- {{ item.name }} - - {{ item.name }} + - -
-
- -
+
+
+
{{ item.currentState }}
-
- -
+
@@ -110,9 +100,9 @@ - +
@@ -264,14 +256,12 @@ export default { }; }, created() { - - this.$toast({ +/* this.$toast({ message: "登录超时,请重新登录", duration: 3000, type: "info", }) -this.$notify({ type: 'warning', message: '请求失败',duration: 3000, }); - +this.$notify({ type: 'warning', message: '请求失败',duration: 3000, }); */ console.log("1201-我是index的created的1"); settestdata(); // debugger @@ -279,6 +269,11 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, }); this.onInit(); } else { 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; } this.setLocationAplus(); @@ -333,9 +328,14 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, }); onSuccess: (data) => { console.log("1201-我是index的onInit的6"); 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); @@ -348,7 +348,6 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, }); duration: 3000, type: "info", }) - /* this.$message({ message: "登录超时,请重新登录", @@ -566,6 +565,7 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, }); margin: 10px 12px 0 10px; } } + // 最上面盒子 .topBox { background: url(~@/assets/img/bg.png) no-repeat; @@ -650,20 +650,21 @@ 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) { - display: flex; - align-items: center; - width: 50%; - height: 100%; - position: relative; - .projectIcon { + .TitListLeft{ + display: flex; + height: 100%; + .projectIcon { display: flex; align-items: center; justify-content: center; @@ -677,32 +678,18 @@ 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; +.projectTitle { + display: flex; + align-items: center; + justify-content: center; + font-family: PingFangSC-Semibold, PingFang SC; + font-size: 16px; + font-weight: 600; + color: #fff; +} - 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; - } - } - .projectRight { + } + .TitListRight{ display: flex; align-items: center; height: 27px; @@ -727,15 +714,13 @@ this.$notify({ type: 'warning', message: '请求失败',duration: 3000, }); height: 27px; 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; @@ -977,63 +962,39 @@ 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; - margin-right: 3px; - margin-left: 10px; - } - } - span { - font-size: 18px; - font-weight: 600; - padding-right: 10px; - color: #fff; - background: #24bca3; + img { + width: 27px; height: 27px; - line-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: 16px; + } + } +} + .projectCenterBox { font-size: 20px; > div {