LP1816475: making datetime-select in fmeditor more consistent with date-select
authorJane Sandberg <sandbej@linnbenton.edu>
Sun, 7 Apr 2019 16:21:51 +0000 (09:21 -0700)
committerJane Sandberg <sandbej@linnbenton.edu>
Wed, 17 Apr 2019 20:41:53 +0000 (13:41 -0700)
Signed-off-by: Jane Sandberg <sandbej@linnbenton.edu>
Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.html
Open-ILS/src/eg2/src/app/share/fm-editor/fm-editor.component.ts

index b758fd4..7d0bb2d 100644 (file)
@@ -51,6 +51,7 @@
                 [timezone]="timezone"
                 domId="{{idPrefix}}-{{field.name}}"
                 (onChangeAsMoment)="field.validate(field.name, $event, record)"
+                (onChangeAsIso)="record[field.name]($event)"
                 [validatorError]="field.validatorError"
                 i18n-validatorError
                 [readOnly]="field.readOnly"
index d955424..d36d56f 100644 (file)
@@ -276,8 +276,6 @@ export class FmRecordEditorComponent
                 } else { // TODO: some bools can be NULL
                     rec[field.name]('f');
                 }
-            } else if ( field.datatype === 'timestamp' && field.datetime && rec[field.name]() ) {
-                rec[field.name] = this.format.idlFormatDatetime(rec[field.name](), this.timezone);
             } else if (field.datatype === 'org_unit') {
                 const org = rec[field.name]();
                 if (org && typeof org === 'object') {