smDateTimeRangePicker
smDateTimeRangePicker copied to clipboard
Invalid date format and model not binding
Hello
Thank you for awesome design
1- I want to use date type format 'YYYY/MM/DD HH:mm' but do not accept this format and send me error invalid date I want year in first.
2- I want to use /
instead of -
but in load data show by -
not /
3- When I set model date load successfully but time not shown.
4- please !important
red color. Its blue in my project I like red one.
5- Please force LTR
or add option config direction my project is RTL and everything is reversed
Hi, I know the fix for this. But I am not able to understand that attributes like mode
, format
are getting assigned to self
but not $scope
. So problem is that code takes values from $scope (like mode, format), which is not there.
For fix, un-comment these lines for whatever mode you want.
self.mode = angular.isUndefined($scope.mode) ? 'date' : $scope.mode;
self.format = angular.isUndefined($scope.format) ? 'MM-DD-YYYY' : $scope.format;
If someone can help me understand this part, I can fix and submit changes. Cheers :)
can u tell me which directive u want to apply this fix to, I will help you out in understanding it
@mominsamir I used this one:
When I load model with "1988/10/25" (Error invalid date format) I put model data in load : "10/12/1988 12:20" but loaded 10/12/1988 time not shown in date I used this datetime in my RTL version website please force ltr direction in objects thank you
RTL 1 https://postimg.org/image/ux1yjni03/ Rtl2 https://postimg.org/image/eyo0mn4l9/
sorry for late reply, this date should work fine as long as date format is defined in picker attribute. I will create demo for above mentioned dates and test it