Przeglądaj źródła

商品资料库修改

喻文俊 3 lat temu
rodzic
commit
67b447f6a3

+ 12 - 14
src/main/resources/static/css/document/beauty-archive-detail.css

@@ -3,10 +3,10 @@ html{line-height:1.15;-webkit-text-size-adjust:100%}
 body{margin:0;font-family: Microsoft YaHei;}
 main{display:block}
 h1{font-size:2em;margin:0.67em 0}
-hr{box-sizing:content-box;height:0;overflow:visible}
+hr{-webkit-box-sizing:content-box;box-sizing:content-box;height:0;overflow:visible}
 pre{font-family:monospace,monospace;font-size:1em}
 a{background-color:transparent;text-decoration: none}
-abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}
+abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}
 b,strong{font-weight:bolder}
 code,kbd,samp{font-family:monospace,monospace;font-size:1em}
 small{font-size:80%}
@@ -21,10 +21,10 @@ button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}
 button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}
 button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}
 fieldset{padding:0.35em 0.75em 0.625em}
-legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}
+legend{-webkit-box-sizing:border-box;box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}
 progress{vertical-align:baseline}
 textarea{overflow:auto}
-[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0}
+[type="checkbox"],[type="radio"]{-webkit-box-sizing:border-box;box-sizing:border-box;padding:0}
 [type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}
 [type="search"]{-webkit-appearance:textfield;outline-offset:-2px}
 [type="search"]::-webkit-search-decoration{-webkit-appearance:none}
@@ -45,7 +45,7 @@ p{margin: 0}
 
 /*图片预览背景*/
 .viewer-backdrop{z-index:13140 !important;background:#000 !important}
-.loading{display: flex;justify-content: center;align-items: center;width: 100%; height: 100%;padding:80px 0;box-sizing: border-box; background: #fff;position: absolute;z-index: 99999;top: 0}
+.loading{display: -webkit-box;display: -ms-flexbox;display: flex;-webkit-box-pack: center;-ms-flex-pack: center;justify-content: center;-webkit-box-align: center;-ms-flex-align: center;align-items: center;width: 100%; height: 100%;padding:80px 0;-webkit-box-sizing: border-box;box-sizing: border-box; background: #fff;position: absolute;z-index: 99999;top: 0}
 /*PC端样式*/
 @media screen and (min-width: 768px){
 body::-webkit-scrollbar{width:10px;height:10px;background-color:#F6F6F6;}
@@ -69,7 +69,7 @@ body{padding-top: 72px;padding-bottom: 60px;}
 .cm-topbar .cm-search .cm-keyword::placeholder{color:#fff}
 .cm-topbar .cm-search .cm-search-btn{position:absolute;top:22px;right:-1px;display:block;width:32px;height:32px;background:url(/img/info/search.png) no-repeat left 8px}
 /*资料样式*/
-.cm-database{text-align:initial;margin-top: 16px;background: #fff;box-sizing: border-box;padding: 24px;}
+.cm-database{text-align:initial;margin-top: 16px;background: #fff;-webkit-box-sizing: border-box;box-sizing: border-box;padding: 24px;}
 /*去登陆*/
 .cm-goLogin {width: 100%;position: fixed;bottom: 0;left: 0;z-index: 99;background:#FFE6DC;}
 .cm-goLogin .cm-content{height:56px;-webkit-box-sizing:border-box;box-sizing:border-box;padding:0 32px;display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:center;-ms-flex-align:center;align-items:center;}
@@ -99,13 +99,13 @@ body{padding-top: 72px;padding-bottom: 60px;}
 .cm-database .cm-category .cm-player video{background:#000}
 .cm-database .cm-category.cm-file .cm-content .cm-title{height: 48px;}
 .cm-database .cm-category.cm-file .cm-content .cm-cover{width:72px;height:72px;overflow:hidden}
-.cm-database .cm-category.cm-file .cm-content .cm-detail{flex: 1;margin-left:16px;-webkit-box-sizing:border-box;box-sizing:border-box}
-.cm-database .cm-category.cm-file .cm-content .cm-detail .cm-row{margin:16px 0 8px;display: flex;justify-content: space-between;align-items: center;}
+.cm-database .cm-category.cm-file .cm-content .cm-detail{-webkit-box-flex: 1;-ms-flex: 1;flex: 1;margin-left:16px;-webkit-box-sizing:border-box;box-sizing:border-box}
+.cm-database .cm-category.cm-file .cm-content .cm-detail .cm-row{margin:16px 0 8px;display: -webkit-box;display: -ms-flexbox;display: flex;-webkit-box-pack: justify;-ms-flex-pack: justify;justify-content: space-between;-webkit-box-align: center;-ms-flex-align: center;align-items: center;}
 .cm-database .cm-category.cm-file .cm-content .cm-detail .cm-row .cm-time{margin:0;font-size:14px;color:#9AA5B5}
 .cm-database .cm-category.cm-file .cm-content .cm-detail .cm-row .cm-view{width:64px;font-size:16px;font-weight:400;color:#E15616;cursor:pointer}
-.cm-database .cm-category.cm-file .cm-content .cm-section{padding-bottom:0;border-bottom:0;display: flex;justify-content: space-between;align-items: center}
+.cm-database .cm-category.cm-file .cm-content .cm-section{padding-bottom:0;border-bottom:0;display: -webkit-box;display: -ms-flexbox;display: flex;-webkit-box-pack: justify;-ms-flex-pack: justify;justify-content: space-between;-webkit-box-align: center;-ms-flex-align: center;align-items: center}
 /*顶部商品简介*/
-.cm-header{background: #fff;margin-top: 16px;box-sizing: border-box;padding: 24px;}
+.cm-header{background: #fff;margin-top: 16px;-webkit-box-sizing: border-box;box-sizing: border-box;padding: 24px;}
 .cm-header .cm-cover{float:left;width:120px;height:120px;border:1px solid #E1E1E1;border-radius:2px;-webkit-box-sizing:border-box;box-sizing:border-box;overflow:hidden}
 .cm-header .cm-cover img{display:block;width:100%;height:inherit}
 .cm-header .cm-content{float: left;width:1032px;padding-left:16px;-webkit-box-sizing:border-box;box-sizing:border-box}
@@ -125,7 +125,7 @@ body{padding-bottom: 12vw}
 .cm-database{width:100vw;text-align:initial;background:#F7F7F7;overflow:hidden}
 /*去登陆*/
 .cm-goLogin {width: 100%;position: fixed;bottom: 0;z-index: 99;background:#FFE6DC;}
-.cm-goLogin .cm-content{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding:0 3.3vw;height:11.8vw;box-sizing: border-box}
+.cm-goLogin .cm-content{display:-webkit-box;display:-ms-flexbox;display:flex;-webkit-box-pack:justify;-ms-flex-pack:justify;justify-content:space-between;-webkit-box-align:center;-ms-flex-align:center;align-items:center;padding:0 3.3vw;height:11.8vw;-webkit-box-sizing: border-box;box-sizing: border-box}
 .cm-goLogin .cm-content span:nth-child(1){font-size:3.6vw;color:#E15616;line-height:11.8vw}
 .cm-goLogin .cm-content span:nth-child(2){width:16.8vw;height:6.3vw;background:#E15616;border-radius:0.4vw;font-size:3.6vw;color:#fff;text-align:center;line-height:6.3vw}
 .cm-database .cm-category{margin:2vw 0 0;background:#fff;padding:0 3.3vw;overflow:hidden}
@@ -164,7 +164,7 @@ body{padding-bottom: 12vw}
 .cm-database .cm-category.cm-file .cm-content .cm-section:last-child{padding-bottom:0;border-bottom:0}
 /*顶部商品简介*/
 .cm-header{background: #fff}
-.cm-header .cm-cover{width:100vw;height:100vw;box-sizing: border-box;}
+.cm-header .cm-cover{width:100vw;height:100vw;-webkit-box-sizing: border-box;box-sizing: border-box;}
 .cm-header .cm-cover img{display:block;width:100%;height:100%}
 .cm-header .cm-content{width:100vw;padding:3.2vw;-webkit-box-sizing:border-box;box-sizing:border-box}
 .cm-header .cm-section.no-border{border:0}
@@ -172,5 +172,3 @@ body{padding-bottom: 12vw}
 .cm-header .cm-content .cm-param{font-size:3vw;font-weight:400;color:#4A4F58;margin-top:1.6vw}
 .cm-header .cm-content .cm-param span:nth-child(1){color:#9AA5B5}
 }
-
-

+ 16 - 10
src/main/resources/static/css/document/beauty-archive.css

@@ -3,10 +3,10 @@ html{line-height:1.15;-webkit-text-size-adjust:100%}
 body{margin:0;font-family: Microsoft YaHei;}
 main{display:block}
 h1{font-size:2em;margin:0.67em 0}
-hr{box-sizing:content-box;height:0;overflow:visible}
+hr{-webkit-box-sizing:content-box;box-sizing:content-box;height:0;overflow:visible}
 pre{font-family:monospace,monospace;font-size:1em}
 a{background-color:transparent;text-decoration: none}
-abbr[title]{border-bottom:none;text-decoration:underline;text-decoration:underline dotted}
+abbr[title]{border-bottom:none;text-decoration:underline;-webkit-text-decoration:underline dotted;text-decoration:underline dotted}
 b,strong{font-weight:bolder}
 code,kbd,samp{font-family:monospace,monospace;font-size:1em}
 small{font-size:80%}
@@ -21,10 +21,10 @@ button,[type="button"],[type="reset"],[type="submit"]{-webkit-appearance:button}
 button::-moz-focus-inner,[type="button"]::-moz-focus-inner,[type="reset"]::-moz-focus-inner,[type="submit"]::-moz-focus-inner{border-style:none;padding:0}
 button:-moz-focusring,[type="button"]:-moz-focusring,[type="reset"]:-moz-focusring,[type="submit"]:-moz-focusring{outline:1px dotted ButtonText}
 fieldset{padding:0.35em 0.75em 0.625em}
-legend{box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}
+legend{-webkit-box-sizing:border-box;box-sizing:border-box;color:inherit;display:table;max-width:100%;padding:0;white-space:normal}
 progress{vertical-align:baseline}
 textarea{overflow:auto}
-[type="checkbox"],[type="radio"]{box-sizing:border-box;padding:0}
+[type="checkbox"],[type="radio"]{-webkit-box-sizing:border-box;box-sizing:border-box;padding:0}
 [type="number"]::-webkit-inner-spin-button,[type="number"]::-webkit-outer-spin-button{height:auto}
 [type="search"]{-webkit-appearance:textfield;outline-offset:-2px}
 [type="search"]::-webkit-search-decoration{-webkit-appearance:none}
@@ -42,7 +42,7 @@ p{margin: 0}
 .cm-fr{float: right}
 .cm-clearfix::after{content: "";display: block;clear: both}
 .cm-fixed-bottom{position: fixed;width: 100%;bottom: 0;left: 0}
-.loading{display: flex;justify-content: center;align-items: center;width: 100%; height: 100%;padding:80px 0;box-sizing: border-box; background: #fff;position: absolute;z-index: 99999;top: 0}
+.loading{display: -webkit-box;display: -ms-flexbox;display: flex;-webkit-box-pack: center;-ms-flex-pack: center;justify-content: center;-webkit-box-align: center;-ms-flex-align: center;align-items: center;width: 100%; height: 100%;padding:80px 0;-webkit-box-sizing: border-box;box-sizing: border-box; background: #fff;position: absolute;z-index: 99999;top: 0}
 /*pc端样式*/
 @media screen and (min-width: 768px) {
 ::-webkit-scrollbar{width:10px;height:10px;background-color:#F6F6F6;}
@@ -50,6 +50,9 @@ p{margin: 0}
 ::-webkit-scrollbar-thumb{border-radius:2px;-webkit-box-shadow:inset 0 0 6px rgba(0,0,0,.1);background-color:#93979F}
 body{background:#F5F5F5;color: #4A4F58;padding-top: 72px;}
 .cm-container{width:1200px;margin:0 auto;position: relative}
+.cm-empty{width: 100%;height: 460px; text-align: center;}
+.cm-empty.cm-empty-pc img{width: 180px;height: 180px;margin-top: 120px;}
+.cm-empty.cm-empty-pc span{display: block;font-size: 16px;color: #9AA5B5;font-weight: 400;}
 /*顶部区域*/
 .cm-topbar{background:#E15616;height:72px;position: fixed;width: 100%;top: 0;z-index: 999;}
 .cm-topbar .cm-title{font-size:24px;line-height:72px;color:#FFFFFF}
@@ -84,7 +87,7 @@ body{background:#F5F5F5;color: #4A4F58;padding-top: 72px;}
 .cm-loading{display: none;}
 /*分页*/
 .pageWrap{text-align:center;padding:30px 0}
-.pageWrap a{box-sizing:border-box;display:inline-block;width:40px;height:40px;line-height:40px;border:1px solid #EBECEF;font-size:16px;margin:0 5px;color:#2D3036;background:#fff;border-radius:2px}
+.pageWrap a{-webkit-box-sizing:border-box;box-sizing:border-box;display:inline-block;width:40px;height:40px;line-height:40px;border:1px solid #EBECEF;font-size:16px;margin:0 5px;color:#2D3036;background:#fff;border-radius:2px}
 .pageWrap a.on{background:#e15616;color:#fff;border:1px solid #e15616}
 .pageWrap a:hover{color:#E15616}
 .pageWrap a.on:hover{color:#fff;opacity:.8}
@@ -93,11 +96,11 @@ body{background:#F5F5F5;color: #4A4F58;padding-top: 72px;}
 .pageWrap .next:before{content:'\276F'}
 .pageWrap span{display:inline-block;height:40px;line-height:40px;margin:0 5px;color:#93979F}
 .pageWrap b{color:#2D3036;font-weight:normal}
-.pageWrap input{box-sizing:border-box;width:80px;height:40px;line-height:40px;font-size:16px;border:1px solid #EBECEF;outline:none;border-radius:2px;text-align:center}
-.crumbs{width:1184px;margin:0 auto;box-sizing:border-box;padding:12px 0;font-size:16px;color: #22272E;}
+.pageWrap input{-webkit-box-sizing:border-box;box-sizing:border-box;width:80px;height:40px;line-height:40px;font-size:16px;border:1px solid #EBECEF;outline:none;border-radius:2px;text-align:center}
+.crumbs{width:1184px;margin:0 auto;-webkit-box-sizing:border-box;box-sizing:border-box;padding:12px 0;font-size:16px;color: #22272E;}
 /*底部*/
 .foot{width:100%;height:130px;background:#262626;margin-top:100px}
-.footer{width:1190px;margin:0 auto;text-align:center;height: 130px;box-sizing: border-box;padding: 39px 0;}
+.footer{width:1190px;margin:0 auto;text-align:center;height: 130px;-webkit-box-sizing: border-box;box-sizing: border-box;padding: 39px 0;}
 .footer p{line-height: 30px;color: #FFFFFF;margin: 0;font-size: 14px}
 .footer p span{margin:0 5px}
 .footer p span img.icp{width: 18px;height: 18px;display: inline-block;}
@@ -108,6 +111,9 @@ body{background:#F5F5F5;color: #4A4F58;padding-top: 72px;}
 body{color:#4A4F58;background:#fff;padding-top: 26vw;}
 #meiye{margin:0 3.2vw;}
 .cm-container{position: relative}
+.cm-empty{width: 100%;margin-top: 40vw; text-align: center;}
+.cm-empty.cm-empty-h5 img{width: 36vw;height: 36vw}
+.cm-empty.cm-empty-h5 span{display: block;font-size: 3.4vw;color: #9AA5B5;font-weight: 400;}
 /*顶部区域*/
 .cm-mobile-fixed{position: fixed;width: 100%;top: 0;background: #fff;}
 .cm-topbar{padding:4vw 0 3vw}
@@ -126,7 +132,7 @@ body{color:#4A4F58;background:#fff;padding-top: 26vw;}
 .cm-tabs .cm-tab-item.on{border-color:#E15616;color:#E15616}
 .cm-tab-content .cm-list .cm-section{padding:3.2vw 0;border-top:1px solid #D8D8D8}
 .cm-tab-content .cm-list{margin-top:3.2vw;padding: 0 3.2vw;}
-.cm-tab-content .cm-list .cm-section .cm-cover{width:24vw;height:24vw;border: 1px solid #E1E1E1;box-sizing: border-box;}
+.cm-tab-content .cm-list .cm-section .cm-cover{width:24vw;height:24vw;border: 1px solid #E1E1E1;-webkit-box-sizing: border-box;box-sizing: border-box;}
 .cm-tab-content .cm-list .cm-section .cm-cover img{display:block;width:100%;height:100%}
 .cm-tab-content .cm-list .cm-section .cm-content{width:69vw;padding-left:3.2vw;-webkit-box-sizing:border-box;box-sizing:border-box}
 .cm-tab-content .cm-list .cm-section.no-border{border:0}

+ 4 - 6
src/main/resources/static/js/document/beauty-archive.js

@@ -29,10 +29,10 @@ var beautyArchive = new Vue({
             id: 0,
             name: '全部'
         }, {
-            id: 2,
+            id: 1,
             name: '产品'
         }, {
-            id: 1,
+            id: 2,
             name: '仪器'
         }]
     },
@@ -71,10 +71,10 @@ var beautyArchive = new Vue({
     filters: {
         productType: function (val) {
             if (val === 1) {
-                return '仪器';
+                return '产品';
             }
             if (val === 2) {
-                return '产品';
+                return '仪器';
             }
             return '未知';
         }
@@ -94,7 +94,6 @@ var beautyArchive = new Vue({
             _that.listLoading = true;
             BeautyArchiveApi.GetArchiveProduct(this.listQuery, function (res) {
                 if (res.code !== 0) return console.log('请求失败');
-                console.log(res.data);
                 _that.hasNextPage = res.data.hasNextPage;
                 _that.listQuery.pageNum = res.data.pageNum;
                 _that.listQuery.pageSize = res.data.pageSize;
@@ -104,7 +103,6 @@ var beautyArchive = new Vue({
                     _that.productList = res.data.results;
                 } else {
                     _that.productList = _that.productList.concat(res.data.results);
-                    console.log(_that.productList);
                 }
                 _that.listLoading = false;
                 _that.windowScroll();

+ 3 - 3
src/main/resources/static/js/document/beautyArchiveDetailMixin.js

@@ -35,7 +35,7 @@ var beautyArchiveDetailMixin = {
                 {text: '请升级成为会员机构后方可查看!', btn: '去升级', redirect: '/user/setting/upgrade.html'},
                 {text: '请升级成为医美会员机构后方可查看!', btn: '去升级', redirect: '/user/setting/upgrade.html'},
                 {text: '需抵扣100采美豆方可查看!', btn: '去查看', redirect: 10},
-                {text: '无权限查看!', btn: ''}
+                {text: '无权限查看!', btn: '确认'}
             ];
             // 0可查看,1未登录,2需升级会员机构,3需升级医美会员机构,4需要抵扣采美豆,5无权限查看
             return statusText[this.permission];
@@ -91,9 +91,9 @@ var beautyArchiveDetailMixin = {
             if (this.checkPermission() !== 0) return;
             var index = file.fileName.lastIndexOf('.');
             var suffix = file.fileName.substring(index);
-            if (suffix === '.doc' || suffix === '.ppt') {
+            if (suffix === '.doc' || suffix === '.ppt' || suffix === '.pptx' || suffix === '.docx') {
                 // 如果是 doc 或 ppt 直接打开链接预览
-                window.open(file.fileUrl, '_blank');
+                window.open(file.htmlUrl, '_blank');
             } else if (suffix === '.pdf') {
                 // 如果是 pdf 需要跳转到预览页面并设置type为1,src为pdf预览链接
                 if (isPC) {

+ 2 - 1
src/main/resources/static/js/user-center/account/beans.js

@@ -69,7 +69,8 @@ var orderPage = new Vue({
                     9:'抵用退回',
                     10:'抵用运费',
                     11:'退款回收',
-                    12:'登录奖励'
+                    12:'登录奖励',
+                    13:'查看商品资料'
                 };
             Object.keys(stateTextObject).forEach(function(key){
                 if(key == state){

+ 8 - 1
src/main/resources/templates/document/beauty-archive.html

@@ -36,6 +36,13 @@
     <div class="cm-container cm-tab-content">
         <div class="cm-search-info" v-if="isPC && openSearch">为您找到相关结果<span v-html="total"></span>条</div>
         <div class="cm-list">
+            <!--列表为空-->
+            <div class="cm-empty" :class="isPC ? 'cm-empty-pc' : 'cm-empty-h5'" v-if="productList.length == 0">
+                <img src="https://static.caimei365.com/app/img/icon2/PC-empty.png" v-if="isPC"/>
+                <img src="https://static.caimei365.com/app/img/icon2/H5-empty.png" v-else/>
+                <span>暂无资料~</span>
+            </div>
+            <!--列表不为空-->
             <template v-for="(product, index) in productList">
                 <div class="cm-section cm-clearfix " :class="{'no-border': index === 0}" :key="index"
                      @click="handleToDetail(product)">
@@ -57,7 +64,7 @@
             </template>
         </div>
         <!-- H5加载更多 -->
-        <div class="cm-loading" v-if="!isPC">
+        <div class="cm-loading" v-if="!isPC  && productList.length>0">
             <span class="cm-action" v-if="listLoading"></span>
             <span class="cm-text" v-else>{{ loadingText }}</span>
         </div>