Open dev-script opened 4 years ago
In Below Example Options comma(,) is missing before $scope.dateRangePicker object's picker: null property .
$scope.dateRangePicker
picker: null
Example options
$scope.dateRangePicker = { date: {startDate: moment().subtract(1, 'years'), endDate: moment().add(1, 'years')} picker: null, options: { pickerClasses: 'custom-display', //angular-daterangepicker extra buttonClasses: 'btn', applyButtonClasses: 'btn-primary', cancelButtonClasses: 'btn-danger', locale: { applyLabel: "Apply", cancelLabel: 'Cancel', customRangeLabel: 'Custom range', separator: ' - ', format: "YYYY-MM-DD", //will give you 2017-01-06 //format: "D-MMM-YY", //will give you 6-Jan-17 //format: "D-MMMM-YY", //will give you 6-January-17 }, ranges: { 'Last 7 Days': [moment().subtract(6, 'days'), moment()], 'Last 30 Days': [moment().subtract(29, 'days'), moment()] }, eventHandlers: { 'apply.daterangepicker': function(event, picker) { console.log('applied'); } } } };
In Below Example Options comma(,) is missing before
$scope.dateRangePicker
object'spicker: null
property .Example options