Security News
The Push to Ban Ransom Payments Is Gaining Momentum
Ransomware costs victims an estimated $30 billion per year and has gotten so out of control that global support for banning payments is gaining momentum.
react-mobile-calendar
Advanced tools
Readme
用react做的用于手机端显示的日历
git clone https://github.com/scholar-ink/react-ttouch
npm install
npm start
import React from 'react'
import ReactDOM from 'react-dom'
import MultiMonthView,{DatePicker} from './src'
import './index.less'
const days = [
{
key:20161201,
text:'¥ 3000'
},
{
key:20161202,
text:'¥ 1000'
},
{
key:20161203,
text:'¥ 1000'
},
];
const onDayClick = (day,rangeDays,is_complete)=>{
for (var value of rangeDays) {
if(value.disable==false) { //使用rendDay 自定义的数据
console.log(value.moment.format('YYYY-MM-DD')+'不可以订');
return false;
}
}
if(is_complete){
console.log('选择完毕');
}else{
console.log('选择退房时间')
}
return true;
};
const rendDay = (day,props)=>{
let day_my = days.find((value)=>(value.key==day.number));
if(day_my==undefined){
day.disable = false; //自定义数据
day.money = '暂无'; //自定义数据
}else{
day.money = day_my.text;
day.disable = true;
}
//自定义 一天的样式
props.children = <div className="day"><span className="textNum">{day.text}</span><span className="textMoney">{day.money}</span></div>;
};
ReactDOM.render(
<div>
<MultiMonthView startText="入住" endText="退房" monthNumber="5" viewMoment="2016-12" onDayClick={onDayClick} rendDay={rendDay}/>
</div>,
document.getElementById('root')
);
FAQs
> 用react做的用于手机端显示的日历
We found that react-mobile-calendar demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Ransomware costs victims an estimated $30 billion per year and has gotten so out of control that global support for banning payments is gaining momentum.
Application Security
New SEC disclosure rules aim to enforce timely cyber incident reporting, but fear of job loss and inadequate resources lead to significant underreporting.
Security News
The Python Software Foundation has secured a 5-year sponsorship from Fastly that supports PSF's activities and events, most notably the security and reliability of the Python Package Index (PyPI).