Browse Source
Merge pull request #11743 from abpframework/fix/datetime-form-prop
change ePropType.DateTime value from 'dateTime' to 'datetime'
pull/11744/head
Mahmut Gundogdu
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with
5 additions and
5 deletions
-
npm/ng-packs/packages/theme-shared/extensions/src/lib/adapters/date-time.adapter.ts
-
npm/ng-packs/packages/theme-shared/extensions/src/lib/enums/props.enum.ts
|
|
|
@ -27,16 +27,16 @@ export class DateTimeAdapter { |
|
|
|
toModel(value: NgbDateTimeStruct | null): string { |
|
|
|
if (!value) return ''; |
|
|
|
|
|
|
|
//const now = new Date();
|
|
|
|
const now = new Date(); |
|
|
|
|
|
|
|
value = { |
|
|
|
// TODO
|
|
|
|
/* year: now.getUTCFullYear(), |
|
|
|
// TODO look for strict mode errors
|
|
|
|
year: now.getUTCFullYear(), |
|
|
|
month: now.getMonth() + 1, |
|
|
|
day: now.getDate(), |
|
|
|
hour: 0, |
|
|
|
minute: 0, |
|
|
|
second: 0, */ |
|
|
|
second: 0, |
|
|
|
...this.value, |
|
|
|
...value, |
|
|
|
}; |
|
|
|
|
|
|
|
@ -1,7 +1,7 @@ |
|
|
|
export const enum ePropType { |
|
|
|
Boolean = 'boolean', |
|
|
|
Date = 'date', |
|
|
|
DateTime = 'dateTime', |
|
|
|
DateTime = 'datetime', |
|
|
|
Email = 'email', |
|
|
|
Enum = 'enum', |
|
|
|
Hidden = 'hidden', |
|
|
|
|