提交 f4ee83dc 编写于 作者: Yuanzhao.dai's avatar Yuanzhao.dai

封装明细排行页底部按钮组件

上级 8eef3493
...@@ -159,25 +159,5 @@ ...@@ -159,25 +159,5 @@
} }
} }
} }
.footer-btn {
width: 100%;
height: 40px;
padding: 5px 0;
box-shadow:0px -1px 0px 0px rgba(237,237,237,1);
position: fixed;
bottom: 0;
.btn {
width: 345px;
height: 40px;
margin: 0 auto;
line-height: 40px;
text-align: center;
background: linear-gradient(270deg,rgba(255,88,36,1) 0%,rgba(254,163,86,1) 100%);
border-radius: 20px;
color: #FFFFFF;
font-weight: 700;
font-size: 15px;
}
}
} }
} }
\ No newline at end of file
...@@ -74,19 +74,22 @@ ...@@ -74,19 +74,22 @@
<p class="num">{{itemD.score}}</p> <p class="num">{{itemD.score}}</p>
</div> </div>
</div> </div>
<div class="footer-btn"> <footer-button
<div class="btn">助力机构 创造佳绩</div> :btnText="btnText"
</div> :btnType="btnType">
</footer-button>
</div> </div>
</section> </section>
</template> </template>
<script> <script>
import RankingHeader from '@/components/ranking-header' import RankingHeader from '@/components/ranking-header';
import FooterButton from '@/components/footer-button';
export default { export default {
name: 'hospital-ranking', name: 'hospital-ranking',
components: { components: {
RankingHeader RankingHeader,
FooterButton
}, },
data() { data() {
return { return {
...@@ -100,7 +103,9 @@ ...@@ -100,7 +103,9 @@
}, },
activeBtnType: true, //true机构,false人员 activeBtnType: true, //true机构,false人员
hospitalRanking: {}, hospitalRanking: {},
contributionRanking: {} contributionRanking: {},
btnText: '助力机构 创造佳绩',
btnType: true
}; };
}, },
computed: { computed: {
......
...@@ -238,26 +238,5 @@ ...@@ -238,26 +238,5 @@
width: 300px; width: 300px;
} }
} }
.footer-btn {
width: 100%;
height: 40px;
padding: 5px 0;
box-shadow:0px -1px 0px 0px rgba(237,237,237,1);
position: fixed;
bottom: 0;
background: #fff;
.btn {
width: 345px;
height: 40px;
margin: 0 auto;
line-height: 40px;
text-align: center;
background: linear-gradient(270deg,rgba(255,88,36,1) 0%,rgba(254,163,86,1) 100%);
border-radius: 20px;
color: #FFFFFF;
font-weight: 700;
font-size: 15px;
}
}
} }
} }
\ No newline at end of file
...@@ -50,8 +50,8 @@ ...@@ -50,8 +50,8 @@
<p class="active-line" v-if="recordType==2"></p> <p class="active-line" v-if="recordType==2"></p>
</div> </div>
</div> </div>
<div class="record-list"> <div class="record-list" v-if="inviteList.length">
<p class="sum" v-if="recordTotal">{{recordTotal}}</p> <p class="sum">{{recordTotal}}</p>
<div class="loadMore" v-infinite-scroll="loadMore" infinite-scroll-disabled="busy" <div class="loadMore" v-infinite-scroll="loadMore" infinite-scroll-disabled="busy"
infinite-scroll-distance="10"> infinite-scroll-distance="10">
<div class="record-item" v-if="inviteList.length" v-for="item in inviteList"> <div class="record-item" v-if="inviteList.length" v-for="item in inviteList">
...@@ -80,22 +80,24 @@ ...@@ -80,22 +80,24 @@
<p v-if="recordType==1">提醒您的医生好友领取课程您将获得奖励哦!</p> <p v-if="recordType==1">提醒您的医生好友领取课程您将获得奖励哦!</p>
<p v-if="recordType==2" class="text-get">提醒您的医生好友领取课程后登录云鹊医APP您将再获得奖励哦!</p> <p v-if="recordType==2" class="text-get">提醒您的医生好友领取课程后登录云鹊医APP您将再获得奖励哦!</p>
</div> </div>
<div class="footer-btn"> <footer-button
<div class="btn">去邀请</div> :btnText="btnText"
</div> :btnType="btnType">
</footer-button>
</div> </div>
</div> </div>
</section> </section>
</template> </template>
<script> <script>
import NormalHeader from '@/components/normal-header';
import NormalHeader from '@/components/normal-header' import FooterButton from '@/components/footer-button';
import { getOneInviteDetails,getTwoInviteDetails } from '@/service/detailsAndRanking' import { getOneInviteDetails,getTwoInviteDetails } from '@/service/detailsAndRanking';
export default { export default {
name: "index", name: "index",
components: { components: {
NormalHeader NormalHeader,
FooterButton,
}, },
data() { data() {
return { return {
...@@ -110,6 +112,8 @@ ...@@ -110,6 +112,8 @@
pageNo: 0, pageNo: 0,
pageSize: 10, pageSize: 10,
noMore: false,//分页参数--end noMore: false,//分页参数--end
btnText: '去邀请',
btnType: true
}; };
}, },
mounted() { mounted() {
......
...@@ -57,7 +57,7 @@ ...@@ -57,7 +57,7 @@
<div class="no-data" v-if="!personDetails.length"> <div class="no-data" v-if="!personDetails.length">
<img src="~/assets/img/icon-nodata.png" alt=""> <img src="~/assets/img/icon-nodata.png" alt="">
<p>暂无记录,您还没有参加活动</p> <p>暂无记录,您还没有参加活动</p>
<div class="button">立即参加</div> <div class="button" @click="goInActivity">立即参加</div>
</div> </div>
</div> </div>
</section> </section>
...@@ -92,6 +92,9 @@ ...@@ -92,6 +92,9 @@
this.getPersonDetails(); this.getPersonDetails();
}, },
methods: { methods: {
goInActivity() {
this.$router.push('/in-activity')
},
detailTaskIcon(taskName) { detailTaskIcon(taskName) {
if(taskName == '打卡') { if(taskName == '打卡') {
return require('../../assets/img/person-detail/icon-invite.png') return require('../../assets/img/person-detail/icon-invite.png')
......
...@@ -130,25 +130,5 @@ ...@@ -130,25 +130,5 @@
} }
} }
} }
.footer-btn {
width: 100%;
height: 40px;
padding: 5px 0;
box-shadow:0px -1px 0px 0px rgba(237,237,237,1);
position: fixed;
bottom: 0;
.btn {
width: 345px;
height: 40px;
margin: 0 auto;
line-height: 40px;
text-align: center;
background: linear-gradient(270deg,rgba(255,88,36,1) 0%,rgba(254,163,86,1) 100%);
border-radius: 20px;
color: #FFFFFF;
font-weight: 700;
font-size: 15px;
}
}
} }
} }
\ No newline at end of file
...@@ -46,19 +46,22 @@ ...@@ -46,19 +46,22 @@
<p class="num">{{item.score}}</p> <p class="num">{{item.score}}</p>
</div> </div>
</div> </div>
<div class="footer-btn"> <footer-button
<div class="btn">获得更多勤奋分</div> :btnText="btnText"
</div> :btnType="btnType">
</footer-button>
</div> </div>
</section> </section>
</template> </template>
<script> <script>
import RankingHeader from '@/components/ranking-header' import RankingHeader from '@/components/ranking-header';
import FooterButton from '@/components/footer-button';
export default { export default {
name: 'person-ranking', name: 'person-ranking',
components: { components: {
RankingHeader RankingHeader,
FooterButton
}, },
data() { data() {
return { return {
...@@ -73,6 +76,8 @@ ...@@ -73,6 +76,8 @@
rightName: '累计排行榜' rightName: '累计排行榜'
}, },
activeBtnType: true, //true今日,false累计 activeBtnType: true, //true今日,false累计
btnText: '获得更多勤奋分',
btnType: true
}; };
}, },
computed: { computed: {
...@@ -135,6 +140,11 @@ ...@@ -135,6 +140,11 @@
} }
], ],
} }
if(this.rankData.score) {
this.btnText = '获得更多勤奋分'
} else {
this.btnText = '参与活动得勤奋分'
}
} }
}, },
}; };
......
...@@ -80,24 +80,4 @@ ...@@ -80,24 +80,4 @@
} }
} }
.footer-btn {
width: 100%;
height: 40px;
padding: 5px 0;
box-shadow:0px -1px 0px 0px rgba(237,237,237,1);
position: fixed;
bottom: 0;
.btn {
width: 345px;
height: 40px;
margin: 0 auto;
line-height: 40px;
text-align: center;
background: linear-gradient(270deg,rgba(255,88,36,1) 0%,rgba(254,163,86,1) 100%);
border-radius: 20px;
color: #FFFFFF;
font-weight: 700;
font-size: 15px;
}
}
} }
\ No newline at end of file
...@@ -21,18 +21,21 @@ ...@@ -21,18 +21,21 @@
</div> </div>
</div> </div>
</div> </div>
<div class="footer-btn"> <footer-button
<div class="btn">今日我要拿奖</div> :btnText="btnText"
</div> :btnType="btnType">
</footer-button>
</section> </section>
</template> </template>
<script> <script>
import NormalHeader from '@/components/normal-header' import NormalHeader from '@/components/normal-header';
import FooterButton from '@/components/footer-button';
export default { export default {
name: "index", name: "index",
components: { components: {
NormalHeader NormalHeader,
FooterButton
}, },
data() { data() {
return { return {
...@@ -41,7 +44,9 @@ ...@@ -41,7 +44,9 @@
barHeight: 0, barHeight: 0,
barColor: '#fff', barColor: '#fff',
rightText: '如何领奖', rightText: '如何领奖',
rewardsList: [] rewardsList: [],
btnText: '今日我要拿奖',
btnType: true
}; };
}, },
mounted() { mounted() {
......
Markdown 格式
0% or
您添加了 0 到此讨论。请谨慎行事。
先完成此消息的编辑!
想要评论请 注册