Quellcode durchsuchen

我的关注顾问跳转优化

liting2017 vor 6 Jahren
Ursprung
Commit
0c83e01ff3

BIN
image/adviserInit.jpg


BIN
image/policyInit.jpg


+ 16 - 0
js/component/account/index/collection.less

@@ -67,6 +67,22 @@
 						display: inline-block;
 					}
 				}
+				.adviserInit{
+					box-sizing: border-box;
+					position: absolute;
+					border-radius: 5px;
+					left: 3%;
+					top: 3%;
+					width: 94%;
+					height: 94%; 
+					background: url(../../../../image/adviserInit.jpg)no-repeat;
+					background-size:100% 100%;
+					img {
+						width: 100%;
+						height: 100%;
+						display: inline-block;
+					}
+				}
                 .divP{
                     opacity: 0;
                     width: 100%;

+ 11 - 6
js/component/account/index/follow.jsx

@@ -12,7 +12,7 @@ class Collection extends Component {
             nub:'1'
         };
     }
-    //服务
+    //关注
     loadDataService(page){
         this.setState({
             loading:true,
@@ -38,6 +38,7 @@ class Collection extends Component {
                         key: i,
                         id: thisdata.uid,
                         name:thisdata.username,
+                        expert:thisdata.expert,
                         introduce:thisdata.introduction&&thisdata.introduction.length>40?thisdata.introduction.substr(0,40)+'...':thisdata.introduction,
                         img: thisdata.headPortraitUrl, //编号
                     });
@@ -70,10 +71,14 @@ class Collection extends Component {
     }
     jump(item){
         let url='';
-        switch(this.state.nub){
-            case '1':
+        switch(item.expert){
+            case 1:
                 url = globalConfig.context+`/portal/subscriberDetail.html?uid=${item.id}&type=0`;
-            break;
+                break;
+            case 2:
+                url = globalConfig.context+`/portal/adviser/adviserDetail?id=${item.id}`;
+                break;
+            default:return;
         }
         window.open(url);
     }
@@ -93,12 +98,12 @@ class Collection extends Component {
                             return<Col span={5} key={index} onClick={(e)=>{this.jump(item)}}>
                                     <div className="img">
                                         <div className="imgHeader">
-                                            <div className="popImgBj">
+                                            <div className={item.expert=='1'?"popImgBj":'adviserInit'}>
                                                  {item.img?<img src={globalConfig.avatarHost+'/upload'+item.img}  alt=""/>:''}
                                             </div>
                                             <div className="divP"><p>{item.introduce}</p></div>
                                         </div>  
-                                        <p className="txt">{item.name?item.name:'佚名'}</p>
+                                        <p className="txt">{item.name?item.name:'佚名'}<span>{item.expert==1?' - (专家)':' - (顾问)'}</span></p>
                                     </div>
                                 </Col>
                         })

+ 1 - 1
js/component/administration/news/newForm.jsx

@@ -259,7 +259,7 @@ const NewDetailForm = Form.create()(React.createClass({
 							})(
 								<Select placeholder="新闻类型">
 									<Select.Option value="0" >普通新闻</Select.Option>
-									<Select.Option value="98" >技淘百科</Select.Option>
+									<Select.Option value="98" >知产百科</Select.Option>
 									<Select.Option value="99" >技淘观点</Select.Option>
                     			</Select>
 							)}

+ 1 - 1
js/component/dataDic.js

@@ -2297,7 +2297,7 @@ module.exports = {
 	        key: "普通新闻"
 	    },{
 	        value: "98",
-	        key: "技淘百科"
+	        key: "知产百科"
 	    }, {
 	        value: "99",
 	        key: "技淘观点"