城阳工作端uniH5前端代码
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

24 lines
620 B

10 months ago
import baseComponent from '../helpers/baseComponent'
import popupMixin from '../helpers/popupMixin'
import { props } from '../date-picker-view/props'
import { formatDate } from './utils'
const platformProps = {
labelPropName: 'label',
format(values, props) {
const o = {
datetime: 'yyyy-MM-dd hh:mm',
date: 'yyyy-MM-dd',
year: 'yyyy',
month: 'yyyy-MM',
time: 'hh:mm',
}
return formatDate(values.date, o[props.mode])
},
}
baseComponent({
behaviors: [popupMixin('#wux-picker', platformProps)],
properties: props,
})