move files to subfolders

This commit is contained in:
Sergio Crisostomo 2018-01-16 22:24:21 +01:00
parent c4e3fe331f
commit ca8e830cc3
8 changed files with 297 additions and 385 deletions

View file

@ -0,0 +1,25 @@
<template>
<span>
<span
v-if="datePanelLabel"
v-show="datePanelLabel.labels[0].type === 'year' || currentView === 'date'"
:class="[datePrefixCls + '-header-label']"
@click="datePanelLabel.labels[0].handler">{{ datePanelLabel.labels[0].label }}</span>
<template v-if="datePanelLabel && currentView === 'date'">{{ datePanelLabel.separator }}</template>
<span
v-if="datePanelLabel"
v-show="datePanelLabel.labels[1].type === 'year' || currentView === 'date'"
:class="[datePrefixCls + '-header-label']"
@click="datePanelLabel.labels[1].handler">{{ datePanelLabel.labels[1].label }}</span>
</span>
</template>
<script>
export default {
props: {
datePanelLabel: Object,
currentView: String,
datePrefixCls: String
}
};
</script>

View file

@ -0,0 +1,50 @@
import { oneOf } from '../../../../utils/assist';
import {initTimeDate } from '../../util';
export default {
props: {
confirm: {
type: Boolean,
default: false
},
showTime: {
type: Boolean,
default: false
},
format: {
type: String,
default: 'yyyy-MM-dd'
},
selectionMode: {
type: String,
validator (value) {
return oneOf(value, ['year', 'month', 'date', 'time']);
},
default: 'date'
},
shortcuts: {
type: Array,
default: () => []
},
disabledDate: {
type: Function,
default: () => false
},
value: {
type: Array,
default: () => [initTimeDate(), initTimeDate()]
}
},
computed: {
isTime(){
return this.currentView === 'time';
}
},
methods: {
handleToggleTime(){
this.currentView = this.currentView === 'time' ? this.selectionMode : 'time';
},
}
};