Jelajahi Sumber

机构个人中心

zhengjinyi 4 tahun lalu
induk
melakukan
5ce3f6b21f

+ 3 - 4
src/main/resources/static/css/base/base.pc.css

@@ -281,10 +281,6 @@ header{box-shadow: 0 2px 10px #ebecef;}
 .priceTag .promotion .more{color:#f55c5c;text-decoration:underline;float:right;}
 
 
-
-
-
-
 .login-btn{float:right;margin:10px 10px 0 0;padding:2px 5px;border:1px solid rgba(225,86,22,0.16862745098039217);color:#E15616;border-radius:2px;height:24px;line-height:24px}
 .pricebox{background:#e15616;width:244px;height:44px;line-height:44px;display:block;text-align:center;margin:12px auto}
 .activity{text-align:center;display:inline-block;height:24px;border:1px solid rgba(225,86,22,0.30196078431372547);opacity:1;border-radius:2px;font-size:12px;font-family:Microsoft YaHei;font-weight:400;line-height:24px;color:rgba(225,86,22,1) !important;position:relative;z-index:1;cursor:pointer;background:#fff;padding:0px 20px 0 5px;margin-left:15px}
@@ -294,3 +290,6 @@ header{box-shadow: 0 2px 10px #ebecef;}
 .activityBox{border:1px solid rgba(225,86,22,0.30196078431372547);border-radius:0px 2px 2px 2px;position:absolute;background:#fff;left:0;font-size:12px;text-align:center;top:28px;line-height:40px;padding:10px;max-height:319px;overflow:auto}
 .activeBtn{width:57px;height:24px;background:#E15616;color:#fff;border-radius:2px;float:right;margin-top:10px;cursor:pointer}
 .priceicon{font-weight:bold}
+
+/*  加载  */
+.loading {box-sizing: border-box;padding: 200px 0;text-align: center;}

+ 29 - 15
src/main/resources/static/css/user-center/dashboard.css

@@ -4,7 +4,8 @@ li{list-style:none}
  * PC端
  */
 @media screen and (min-width:768px){
-    .navLayout {min-height: 900px;}
+    .navLayout {min-height: 900px;opacity: 0;}
+    .navLayout.active {opacity: 1;}
     .crumbs{padding-left: 220px;}
     .navLayout .left{float:left;width:200px;line-height:50px;white-space:nowrap;text-indent:16px;font-size:16px;background:#FFF}
     .navLayout .left .title{color:#22272e;font-weight:bold;border-bottom:1px solid #f5f5f5}
@@ -24,9 +25,11 @@ li{list-style:none}
     .user-header .header-ml{width: 50%;height:80px;float: left;}
     .user-header .header-ml .logo{width: 110px;height:78px;float: left;border: 1px solid #f5f5f5;border-radius: 2px;margin-right: 8px;}
     .user-header .header-ml .logo img{width: 110px;height:78px;display: block;border-radius: 2px;}
-    .user-header .header-ml .account{float: left;}
-    .user-header .header-ml .account .name{line-height: 46px;font-size: 18px;font-weight: bold;color: #22272e;}
-    .user-header .header-ml .account .msg{font-size: 14px;line-height: 22px;color: #22272e;}
+    .user-header .header-ml .account{float: left;box-sizing: border-box;padding: 5px 0;}
+    .user-header .header-ml .account .name{width: 100%;height: 36px;float: left;margin-bottom: 10px;}
+    .user-header .header-ml .account .name span{line-height: 36px;font-size: 18px;font-weight: bold;color: #22272e;display: inline-block;float: left;}
+    .user-header .header-ml .account .name a{margin-left: 30px;width: 118px;height: 34px;border: 1px solid #E15616;border-radius: 2px;background-color: #ffe6dc;color: #E15616;display: block;line-height: 34px;text-align: center;float: left;}
+    .user-header .header-ml .account .msg{width:100%;font-size: 14px;line-height: 26px;color: #22272e;margin-top: 20px;}
     .user-header .header-ml .account .msg span{color: #22272e;display: inline-block;float: left;margin-right: 8px;}
     .user-header .header-ml .account .msg .red{color: #f94b4b;font-style: normal;margin: 0 5px;}
     .user-header .header-ml .account .msg a{display: inline-block;width: 64px;height: 22px;float: left;line-height: 22px;color: #FFFFFF;font-size:12px;text-align: center; background-image: linear-gradient(225deg,#61686f 0%,#313a43 100%);border-radius: 2px;}
@@ -34,22 +37,28 @@ li{list-style:none}
     .user-header .header-mr .message{width: 100%;float: right;height: 28px;}
     .user-header .header-mr .message .icon{width: 28px;height: 28px;float: right;display: block;position: relative;}
     .user-header .header-mr .message .icon:before{width: 28px;height: 28px;background-position: -240px -370px}
-    .user-header .header-mr .message .icon a{display: block;width: 18px;height: 18px;background-image: linear-gradient(90deg,#ff5353 0%,#ff2424 100%);position: absolute;top: -9px;left: -9px;font-style: normal;font-size: 13px;color: #f94b4b;line-height: 18px;text-align: center;border-radius: 50%;color: #fff;}
+    .user-header .header-mr .message .icon a{display: block;width: 20px;height: 20px;background-image: linear-gradient(90deg,#ff5353 0%,#ff2424 100%);position: absolute;top: -9px;left: -9px;font-style: normal;font-size: 13px;color: #f94b4b;line-height: 20px;text-align: center;border-radius: 50%;color: #fff;}
     .user-header .header-mr .money {width: 100%;height: 52px;line-height: 52px;font-size: 16px;}
     .user-header .header-mr .money span{color: #e15616;}
-    .user-content{width: 100%;height: auto;margin-top: 27px;}
+    .user-content{width: 100%;height: auto;margin-top: 10px;}
     .user-content .title{width: 100%;height: 44px;line-height: 44px;font-size: 16px;text-align: left;color: #22272e;}
+    .user-content .title a{display: block;float: right;position: relative;padding-right: 36px;position: relative;}
+    .user-content .title a .icon{display: block;width: 18px;height: 18px;position: absolute;top: 5px;right: 10px;}
+    .user-content .title a .icon:before{width: 18px;height: 18px;background-position: -304px -32px;}
     .user-content .section{width: 100%;height: auto;}
     .user-content .section .user-main{width: 100%;height:auto;background-color: #FFFFFF;box-sizing: border-box;padding: 20px;box-shadow: 0px 3px 6px 0px rgba(0, 0, 0, 0.07);margin-bottom: 10px;}
-    .user-content .section .user-main.tabs{height: 78px;padding: 15px 20px;}
+    .user-content .section .user-main.tabs{height: 90px;padding: 15px 20px;}
     .user-content .section .user-main .tabs-left{height: 100%;float: left;}
     .user-content .section .user-main .tabs-left .item{width: 50px;height: 100%;float: left;margin:0 40px;}
     .user-content .section .user-main .tabs-left .item a{width: 100%;height: 100%;display: block;}
-    .user-content .section .user-main .tabs-left .item a .icon{width: 24px;height: 24px;display: block;margin: 0 auto;position: relative;}
-    .user-content .section .user-main .tabs-left .item a .icon span{display: block;width: 18px;height: 18px;background-image: linear-gradient(90deg,#ff5353 0%,#ff2424 100%);position: absolute;top: -9px;left: -9px;font-style: normal;font-size: 13px;color: #f94b4b;line-height: 18px;text-align: center;border-radius: 50%;color: #fff;}
+    .user-content .section .user-main .tabs-left .item a .icon{width: 24px;height: 24px;display: block;margin: 0 auto;position: relative;margin-top: 10px;}
+    .user-content .section .user-main .tabs-left .item a .icon span{display: block;width: 20px;height: 20px;background-image: linear-gradient(90deg,#ff5353 0%,#ff2424 100%);position: absolute;top: -9px;right: -13px;font-style: normal;font-size: 13px;color: #f94b4b;line-height: 20px;text-align: center;border-radius: 50%;color: #fff;}
     .user-content .section .user-main .tabs-left .item a .icon:before{width: 24px;height: 24px;background-position: -273px -370px;}
     .user-content .section .user-main .tabs-left .item a p{font-size: 14px;color: #22272e;text-align: center;line-height: 20px;margin-top: 3px;}
-    .user-content .section .user-main .tabs-right{float: right;line-height: 48px;font-size: 14px;color: #22272e;}
+    .user-content .section .user-main .tabs-right{float: right;line-height: 60px;font-size: 14px;color: #22272e;}
+    .user-content .section .user-main .tabs-right a{display: block;float: right;padding-right: 16px;position: relative}
+    .user-content .section .user-main .tabs-right a .icon{width: 18px;height: 18px;display: block;position: absolute;top: 4px;right: -10px;}
+    .user-content .section .user-main .tabs-right a .icon:before{width: 18px;height: 18px;background-position: -304px -32px;}
     .user-content .section .user-main.order{height: 224px;padding-left: 68px;padding-top: 10px;}
     .user-content .section .user-main .order-title{width: 100%;height: 40px;position: relative;float: left;margin-bottom: 0;}
     .user-content .section .user-main .order-title .bag{display: block;position: absolute;left: -45px;top: 12px; width: 36px;height: 16px;background-image: linear-gradient(335deg,#e15616 0%,#ffb496 100%);border-radius: 2px;font-size: 10px;color: #FFFFFF;line-height: 16px;text-align: center;}
@@ -70,13 +79,17 @@ li{list-style:none}
     .user-content .section .user-main.product{height: 260px;padding: 20px 20px 10px 20px;}
     .user-content .section .user-main .product-item{width: 173px;height: auto;float: left;margin-right: 15px;cursor: pointer;}
     .user-content .section .user-main .product-item:last-child{margin-right: 0;}
-    .user-content .section .user-main .product-item .product-img{width: 173px;height: 173px;float: left;}
+    .user-content .section .user-main .product-item .product-img{width: 171px;height: 171px;float: left;border: 1px solid #e2e7ef;}
     .user-content .section .user-main .product-item .product-img img{width: 173px;height: 173px;display: block;}
     .user-content .section .user-main .product-item .product-name{width: 100%;height: 40px;float: left;margin-top: 10px;}
-    .user-content .section .user-main .product-item .product-name p{font-size: 14px;color: #22272e;text-align: justify;line-height: 20px;text-overflow: -o-ellipsis-lastline;overflow: hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-line-clamp: 2;line-clamp: 2;-webkit-box-orient: vertical;}
-    .user-content .section .user-main.news{height: 207px;}
-
-
+    .user-content .section .user-main .product-item .product-name p{font-size: 14px;color: #93979f;text-align: justify;line-height: 20px;text-overflow: -o-ellipsis-lastline;overflow: hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-line-clamp: 2;line-clamp: 2;-webkit-box-orient: vertical;}
+    .user-content .section .user-main .product-item .product-name p:hover{color: #E15616;text-decoration: underline;}
+    .user-content .section .user-main.news{height: 207px;padding: 13px 20px;}
+    .user-content .section .user-main .new-list{width: 100%;height: 36px;float: left;cursor: pointer;}
+    .user-content .section .user-main .new-list .text{width: 600px;line-height: 36px;font-size: 14px;color: #4a4f58;float: left;padding-left: 15px;position: relative; white-space: nowrap;text-overflow: ellipsis;overflow: hidden;word-break: break-all;}
+    .user-content .section .user-main .new-list .text:hover{color: #E15616;text-decoration: underline;}
+    .user-content .section .user-main .new-list .text:before{content: '';width: 8px;height: 8px;border-radius: 50%;background-color: #e15616;position: absolute;left: 0;top:10px;}
+    .user-content .section .user-main .new-list .time{line-height: 36px;font-size: 12px;color: #9aa5b5;float: right;}
 }
 
 /**
@@ -84,6 +97,7 @@ li{list-style:none}
 */
 @media screen and (max-width:768px){
 .navLayout{background:#FFF;border-top:1px solid #F5F5F5;border-bottom:1px solid #F5F5F5;}
+.navLayout.active {opacity: 1;}
 .navLayout .crumbs{display:none;}
 .navLayout .left{width:29.3vw;border-right:1px solid #F5F5F5;line-height:11.8vw;white-space:nowrap;text-indent:3.3vw;font-size:3.4vw;}
 .navLayout .left .title{color:#22272e;font-weight:bold;border-bottom:1px solid #f5f5f5;font-size: 3.7vw;}

+ 113 - 0
src/main/resources/static/css/user-center/orderlist.css

@@ -0,0 +1,113 @@
+@charset "utf-8";
+li{list-style:none}
+/**
+ * PC端
+ */
+@media screen and (min-width:768px){
+    .navLayout {min-height: 900px;}
+    .crumbs{padding-left: 220px;}
+    .navLayout .left{float:left;width:200px;line-height:50px;white-space:nowrap;text-indent:16px;font-size:16px;background:#FFF}
+    .navLayout .left .title{color:#22272e;font-weight:bold;border-bottom:1px solid #f5f5f5}
+    .navLayout .navList .tab{display:block;color:#22272e;position:relative;cursor: pointer;}
+    .navLayout .navList .tab:before{content:'\276F';font-weight:normal;position:absolute;right:10px;top:0;transform:rotate(90deg);width:32px;height:32px;line-height:32px;text-align:center;color:#bec2c9}
+    .navLayout .navList .con{position:relative;}
+    .navLayout .navList .con:before,.navLayout .navList .con:after{content:'';position:absolute;width:168px;border-top:1px solid #f5f5f5;left:16px}
+    .navLayout .navList .con:before{top:0}
+    .navLayout .navList .con:after{bottom:0}
+    .navLayout .navList .con a{display:block;font-size:14px;color:#627386;text-indent:32px}
+    .navLayout .navList.on .tab:before{top:18px;transform:rotate(270deg);color:#e15616}
+    .navLayout .navList.on .tab{color:#e15616}
+    .navLayout .navList .con a.on{color:#e15616;background-color:#ffe6dc}
+    /*个人中心右侧*/
+    .navLayout .right{float:right;width:968px}
+    .user-header{width: 100%;height: 120px;box-sizing: border-box;padding: 20px;background-color: #FFF;box-shadow: 0px 3px 6px 0px rgba(0, 0, 0, 0.07);}
+    .user-header .header-ml{width: 50%;height:80px;float: left;}
+    .user-header .header-ml .logo{width: 110px;height:78px;float: left;border: 1px solid #f5f5f5;border-radius: 2px;margin-right: 8px;}
+    .user-header .header-ml .logo img{width: 110px;height:78px;display: block;border-radius: 2px;}
+    .user-header .header-ml .account{float: left;}
+    .user-header .header-ml .account .name{line-height: 46px;font-size: 18px;font-weight: bold;color: #22272e;}
+    .user-header .header-ml .account .msg{font-size: 14px;line-height: 22px;color: #22272e;}
+    .user-header .header-ml .account .msg span{color: #22272e;display: inline-block;float: left;margin-right: 8px;}
+    .user-header .header-ml .account .msg .red{color: #f94b4b;font-style: normal;margin: 0 5px;}
+    .user-header .header-ml .account .msg a{display: inline-block;width: 64px;height: 22px;float: left;line-height: 22px;color: #FFFFFF;font-size:12px;text-align: center; background-image: linear-gradient(225deg,#61686f 0%,#313a43 100%);border-radius: 2px;}
+    .user-header .header-mr{height:80px;float: right;}
+    .user-header .header-mr .message{width: 100%;float: right;height: 28px;}
+    .user-header .header-mr .message .icon{width: 28px;height: 28px;float: right;display: block;position: relative;}
+    .user-header .header-mr .message .icon:before{width: 28px;height: 28px;background-position: -240px -370px}
+    .user-header .header-mr .message .icon a{display: block;width: 18px;height: 18px;background-image: linear-gradient(90deg,#ff5353 0%,#ff2424 100%);position: absolute;top: -9px;left: -9px;font-style: normal;font-size: 13px;color: #f94b4b;line-height: 18px;text-align: center;border-radius: 50%;color: #fff;}
+    .user-header .header-mr .money {width: 100%;height: 52px;line-height: 52px;font-size: 16px;}
+    .user-header .header-mr .money span{color: #e15616;}
+    .user-content{width: 100%;height: auto;margin-top: 27px;}
+    .user-content .title{width: 100%;height: 44px;line-height: 44px;font-size: 16px;text-align: left;color: #22272e;}
+    .user-content .title a{display: block;float: right;position: relative;padding-right: 36px;position: relative;}
+    .user-content .title a .icon{display: block;width: 18px;height: 18px;position: absolute;top: 5px;right: 10px;}
+    .user-content .title a .icon:before{width: 18px;height: 18px;background-position: -304px -32px;}
+    .user-content .section{width: 100%;height: auto;}
+    .user-content .section .user-main{width: 100%;height:auto;background-color: #FFFFFF;box-sizing: border-box;padding: 20px;box-shadow: 0px 3px 6px 0px rgba(0, 0, 0, 0.07);margin-bottom: 10px;}
+    .user-content .section .user-main.tabs{height: 78px;padding: 15px 20px;}
+    .user-content .section .user-main .tabs-left{height: 100%;float: left;}
+    .user-content .section .user-main .tabs-left .item{width: 50px;height: 100%;float: left;margin:0 40px;}
+    .user-content .section .user-main .tabs-left .item a{width: 100%;height: 100%;display: block;}
+    .user-content .section .user-main .tabs-left .item a .icon{width: 24px;height: 24px;display: block;margin: 0 auto;position: relative;}
+    .user-content .section .user-main .tabs-left .item a .icon span{display: block;width: 18px;height: 18px;background-image: linear-gradient(90deg,#ff5353 0%,#ff2424 100%);position: absolute;top: -9px;left: -9px;font-style: normal;font-size: 13px;color: #f94b4b;line-height: 18px;text-align: center;border-radius: 50%;color: #fff;}
+    .user-content .section .user-main .tabs-left .item a .icon:before{width: 24px;height: 24px;background-position: -273px -370px;}
+    .user-content .section .user-main .tabs-left .item a p{font-size: 14px;color: #22272e;text-align: center;line-height: 20px;margin-top: 3px;}
+    .user-content .section .user-main .tabs-right{float: right;line-height: 48px;font-size: 14px;color: #22272e;}
+    .user-content .section .user-main .tabs-right a{display: block;float: right;padding-right: 16px;}
+    .user-content .section .user-main.order{height: 224px;padding-left: 68px;padding-top: 10px;}
+    .user-content .section .user-main .order-title{width: 100%;height: 40px;position: relative;float: left;margin-bottom: 0;}
+    .user-content .section .user-main .order-title .bag{display: block;position: absolute;left: -45px;top: 12px; width: 36px;height: 16px;background-image: linear-gradient(335deg,#e15616 0%,#ffb496 100%);border-radius: 2px;font-size: 10px;color: #FFFFFF;line-height: 16px;text-align: center;}
+    .user-content .section .user-main .order-title .title-name{float: left;line-height:  40px;font-size: 14px;color: #22272e;}
+    .user-content .section .user-main .order-title .title-name p{float: left;margin-right: 10px;}
+    .user-content .section .user-main .order-title .title-name p.state{color: #E15616;}
+    .user-content .section .user-main .order-title .title-type{float: left;width: 40px;height: 40px;background: url("/img/order/second.png")center center no-repeat;background-size: cover;}
+    .user-content .section .user-main .order-title .title-time{float: right;line-height:  40px;font-size: 12px;color: #9aa5b5;}
+    .user-content .section .user-main .order-content{width: 100%;height: auto;float: left;}
+    .user-content .section .user-main .order-content .order-item{width: 100%;height: 36px;float: left;}
+    .user-content .section .user-main .order-content .order-item p{float: left;margin-right: 50px;line-height: 36px;color: #22272e;font-size: 14px;}
+    .user-content .section .user-main .order-content .order-item p span{margin-left: 5px;}
+    .user-content .section .user-main .order-content .order-item p .red{color: #f94b4b;}
+    .user-content .section .user-main .order-content .order-botton{width: 100%;height: 36px;float: left;margin-top: 8px;}
+    .user-content .section .user-main .order-content .order-botton .btn{width: 88px;height: 34px;border-radius: 2px;border: 1px solid #FFF;float: right;margin-left: 16px;font-size: 14px;line-height: 34px;text-align: center;display: block;}
+    .user-content .section .user-main .order-content .order-botton .btn.cancel{border-color: #9aa5b5;background-color: #FFFFFF;color: #22272e;}
+    .user-content .section .user-main .order-content .order-botton .btn.primary{border-color: #E15616;background-color: #E15616;color: #FFFFFF;}
+    .user-content .section .user-main.product{height: 260px;padding: 20px 20px 10px 20px;}
+    .user-content .section .user-main .product-item{width: 173px;height: auto;float: left;margin-right: 15px;cursor: pointer;}
+    .user-content .section .user-main .product-item:last-child{margin-right: 0;}
+    .user-content .section .user-main .product-item .product-img{width: 173px;height: 173px;float: left;}
+    .user-content .section .user-main .product-item .product-img img{width: 173px;height: 173px;display: block;}
+    .user-content .section .user-main .product-item .product-name{width: 100%;height: 40px;float: left;margin-top: 10px;}
+    .user-content .section .user-main .product-item .product-name p{font-size: 14px;color: #93979f;text-align: justify;line-height: 20px;text-overflow: -o-ellipsis-lastline;overflow: hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-line-clamp: 2;line-clamp: 2;-webkit-box-orient: vertical;}
+    .user-content .section .user-main .product-item .product-name p:hover{color: #E15616;text-decoration: underline;}
+    .user-content .section .user-main.news{height: 218px;padding: 13px 20px;}
+    .user-content .section .user-main .new-list{width: 100%;height: 32px;float: left;cursor: pointer;}
+    .user-content .section .user-main .new-list .text{width: 600px;line-height: 32px;font-size: 14px;color: #4a4f58;float: left;padding-left: 15px;position: relative; white-space: nowrap;text-overflow: ellipsis;overflow: hidden;word-break: break-all;}
+    .user-content .section .user-main .new-list .text:hover{color: #E15616;text-decoration: underline;}
+    .user-content .section .user-main .new-list .text:before{content: '';width: 8px;height: 8px;border-radius: 50%;background-color: #e15616;position: absolute;left: 0;top:10px;}
+    .user-content .section .user-main .new-list .time{line-height: 32px;font-size: 12px;color: #9aa5b5;float: right;}
+
+
+}
+
+/**
+* 移动端
+*/
+@media screen and (max-width:768px){
+.navLayout{background:#FFF;border-top:1px solid #F5F5F5;border-bottom:1px solid #F5F5F5;}
+.navLayout .crumbs{display:none;}
+.navLayout .left{width:29.3vw;border-right:1px solid #F5F5F5;line-height:11.8vw;white-space:nowrap;text-indent:3.3vw;font-size:3.4vw;}
+.navLayout .left .title{color:#22272e;font-weight:bold;border-bottom:1px solid #f5f5f5;font-size: 3.7vw;}
+.navLayout .navList .tab{display:block;color:#22272e;position:relative}
+.navLayout .navList .tab:before{content:'\276F';font-weight:normal;position:absolute;right:1.4vw;top:1vw;transform:rotate(90deg);width:6.4vw;height:6.4vw;line-height:6.4vw;text-align:center;color:#bec2c9}
+.navLayout .navList .con a{display:block;color:#9aa5b5;}
+.navLayout .navList.on .tab:before{top:4vw;transform:rotate(270deg);color:#e15616}
+.navLayout .navList.on .tab{color:#e15616}
+.navLayout .navList .con a.on{color:#e15616;background-color:#ffe6dc}
+.navLayout .right{width:70.5vw}
+
+
+
+
+
+}
+

+ 6 - 0
src/main/resources/static/js/common/serviceapi/user.service.js

@@ -46,6 +46,12 @@ var UserApi = {
                 callback(res);
             });
         },
+        GetMyPcCenterInfo : function(params,callback) {//机构个人中心数据查询
+            Http.AjaxService({ url:'/pcCenter/myPcCenter', type:'get', data:params, json:true})
+            .then(function(res){
+                callback(res);
+            });
+        },
         SupplierRgister:function(params, callback){//供应商注册
             Http.AjaxService({url: '/supplier/register', type: 'post', data: params, json: false})
             .then(function (res) {

+ 39 - 32
src/main/resources/static/js/user-center/dashboard.js

@@ -3,47 +3,54 @@ var helpSuggestion = new Vue({
     el: "#dashboard",
     data: {
         btnLoading: false,
+        isRequset:false,
         userId: 0,
-        messageNum:'99+',
-        productList:[
-            {name:'华熙生物润百颜液体华熙生物润百颜',image:'https://img.caimei365.com/group1/M00/03/A9/Cmis217DrRiAFqp6AAfSTE-r1ow47.JPEG'},
-            {name:'华熙生物润百颜液体华熙生物润百颜',image:'https://img.caimei365.com/group1/M00/03/A9/Cmis217DrRiAFqp6AAfSTE-r1ow47.JPEG'},
-            {name:'华熙生物润百颜液体华熙生物润百颜',image:'https://img.caimei365.com/group1/M00/03/A9/Cmis217DrRiAFqp6AAfSTE-r1ow47.JPEG'},
-            {name:'华熙生物润百颜液体华熙生物润百颜',image:'https://img.caimei365.com/group1/M00/03/A9/Cmis217DrRiAFqp6AAfSTE-r1ow47.JPEG'},
-            {name:'华熙生物润百颜液体华熙生物润百颜/款',image:'https://img.caimei365.com/group1/M00/03/A9/Cmis217DrRiAFqp6AAfSTE-r1ow47.JPEG'}
-        ]
+        degree:'',
+        userInfo:{},
+        unReadMessageCount:'',//消息数
+        confirmedCount:'',//待確認數量
+        paymentCount:'',//待付款
+        waitShipmentsCount:'',//待发货
+        shipmentsCount:'',//已发货
+        salesReturnCount:'',//退货款
+        productList:[],//推荐商品
+        newsList:[],//新闻动态
     },
     methods: {
-        postSuggestion: function () {  // 账号登录
+        GetMyPcCenterInfo:function(){
             var _self = this;
-            var pass = verifyForm();
-            if (this.btnLoading) {
-                return false;
-            }
-            this.$nextTick(function () {
-                if (!pass) {
-                    return false;
+            UserApi.GetMyPcCenterInfo({userId:_self.userId},function (response) {
+                if(response.code == 0){
+                    var data = response.data;
+                    _self.userInfo = data.user;
+                    _self.degree = data.degree;
+                    _self.unReadMessageCount = _self.showBadge(data.unReadMessageCount);
+                    _self.confirmedCount = _self.showBadge(data.confirmedCount);
+                    _self.paymentCount = _self.showBadge(data.paymentCount);
+                    _self.waitShipmentsCount = _self.showBadge(data.waitShipmentsCount);
+                    _self.shipmentsCount = _self.showBadge(data.shipmentsCount);
+                    _self.salesReturnCount = _self.showBadge(data.salesReturnCount);
+                    _self.productList = data.homePageAdvertiseList;
+                    _self.newsList = data.homePageInfoList;
+                    _self.isRequset = true;
+                }else{
+                    CAIMEI.Alert(response.msg, '确定', false);
                 }
-                _self.btnLoading = true;
-                var params = {
-                    suggestionTypeID: _self.suggestion.type,
-                    userID: _self.userId,
-                    title: _self.suggestion.title,
-                    content: _self.suggestion.content,
-                    linkMan: _self.suggestion.name,
-                    mobile: _self.suggestion.phone
-                };
-                console.log(JSON.stringify(params));
-                $.post("/help/suggestion", params, function(res){
-                    alertInfo(res.msg);
-                    _self.btnLoading = false;
-                });
-            });
-        }
+            })
+        },
+        showBadge:function(n){//处理标签
+            var num ='';
+            if(n>100){num = 99}else{num = n;}
+            return num;
+        },
+        toFixedFn:function(text){//处理小数点后两位数
+            return Number(text).toFixed(2);
+        },
     },
     mounted: function () {
         if(globalUserData){
             this.userId = globalUserData.userId;
+            this.GetMyPcCenterInfo();
         }
     }
 });

+ 56 - 0
src/main/resources/static/js/user-center/message.js

@@ -0,0 +1,56 @@
+jqMultipleShow("click", ".navList", ".tab", ".con");
+var helpSuggestion = new Vue({
+    el: "#dashboard",
+    data: {
+        btnLoading: false,
+        isRequset:false,
+        userId: 0,
+        degree:'',
+        userInfo:{},
+        unReadMessageCount:'',//消息数
+        confirmedCount:'',//待確認數量
+        paymentCount:'',//待付款
+        waitShipmentsCount:'',//待发货
+        shipmentsCount:'',//已发货
+        salesReturnCount:'',//退货款
+        productList:[],//推荐商品
+        newsList:[],//新闻动态
+    },
+    methods: {
+        GetMyPcCenterInfo:function(){
+            var _self = this;
+            UserApi.GetMyPcCenterInfo({userId:_self.userId},function (response) {
+                if(response.code == 0){
+                    var data = response.data;
+                    _self.userInfo = data.user;
+                    _self.degree = data.degree;
+                    _self.unReadMessageCount = _self.showBadge(data.unReadMessageCount);
+                    _self.confirmedCount = _self.showBadge(data.confirmedCount);
+                    _self.paymentCount = _self.showBadge(data.paymentCount);
+                    _self.waitShipmentsCount = _self.showBadge(data.waitShipmentsCount);
+                    _self.shipmentsCount = _self.showBadge(data.shipmentsCount);
+                    _self.salesReturnCount = _self.showBadge(data.salesReturnCount);
+                    _self.productList = data.homePageAdvertiseList;
+                    _self.newsList = data.homePageInfoList;
+                    _self.isRequset = true;
+                }else{
+                    CAIMEI.Alert(response.msg, '确定', false);
+                }
+            })
+        },
+        showBadge:function(n){//处理标签
+            var num ='';
+            if(n>100){num = 99}else{num = n;}
+            return num;
+        },
+        toFixedFn:function(text){//处理小数点后两位数
+            return Number(text).toFixed(2);
+        },
+    },
+    mounted: function () {
+        if(globalUserData){
+            this.userId = globalUserData.userId;
+            this.GetMyPcCenterInfo();
+        }
+    }
+});