900字范文,内容丰富有趣,生活中的好帮手!
900字范文 > element-ui使用日历控件 如何在指定的日期显示一个小点

element-ui使用日历控件 如何在指定的日期显示一个小点

时间:2020-07-29 20:32:56

相关推荐

element-ui使用日历控件 如何在指定的日期显示一个小点

效果图如下:

代码:

<!--日历--><el-calendar v-model="value" style="height:620px" class="el_cal_out"><template slot="dateCell" slot-scope="{data}"><p style="margin:0px">{{data.day.split('-').slice(2).join() }}<br /><!--标记--><div v-for="(i, index) in dayTime" :key="index"><div v-if="data.day==i" class="budge"></div></div></p></template></el-calendar><script>export default {data () {dayTime: ["-03-28", "-01-26", "-03-16"]}}</script><style scoped>.budge {width: 8px;height: 8px;background: #e6a23c;border-radius: 50%;margin: 0 auto;margin-top: 10px;}</style >

**

**

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。