Skip to content
This repository has been archived by the owner on Mar 21, 2019. It is now read-only.

点击当前日期设置样式 #67

Open
ljxyaly opened this issue Dec 18, 2018 · 2 comments
Open

点击当前日期设置样式 #67

ljxyaly opened this issue Dec 18, 2018 · 2 comments

Comments

@ljxyaly
Copy link

ljxyaly commented Dec 18, 2018

能否设置点击选中时的样式

@moonflower-wang
Copy link

同求

@Javen205
Copy link

Javen205 commented Feb 27, 2019

@ljxyaly @moonflower-wang

实现 点击当前日期设置样式 代码如下

  dayClick: function (event) {
    console.log(event.detail);

    let year = event.detail.year;
    let month = event.detail.month;
    let day = event.detail.day;

    let days_style = this.data.days_style;
    days_style.pop();
    days_style.push({
      month: 'current',
      day: day,
      color: 'white',
      background: '#b49eeb',
      bottomText: '已签到',
      fontSize: '20rpx'
    });
    this.setData({
      days_style
    });
}

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants