@wavemaker/app-ng-runtime 12.0.0-next.45032 → 12.0.0-next.45501
Sign up to get free protection for your applications and to get access to all the features.
- app-ng-runtime/build-task/bundles/index.umd.js +405 -451
- app-ng-runtime/build-task/esm2022/data/form/form-field/form-field.build.mjs +2 -3
- app-ng-runtime/build-task/esm2022/public_api.mjs +1 -3
- app-ng-runtime/build-task/fesm2022/index.mjs +406 -454
- app-ng-runtime/build-task/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/build-task/public_api.d.ts +0 -2
- app-ng-runtime/components/base/bundles/index.umd.js +14 -62
- app-ng-runtime/components/base/components.module.d.ts +11 -12
- app-ng-runtime/components/base/esm2022/components.module.mjs +1 -5
- app-ng-runtime/components/base/esm2022/public_api.mjs +1 -2
- app-ng-runtime/components/base/esm2022/widgets/common/base/base.component.mjs +15 -25
- app-ng-runtime/components/base/fesm2022/index.mjs +15 -62
- app-ng-runtime/components/base/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/components/base/public_api.d.ts +0 -1
- app-ng-runtime/components/base/widgets/common/base/base.component.d.ts +5 -10
- app-ng-runtime/components/containers/wizard/bundles/index.umd.js +17 -0
- app-ng-runtime/components/containers/wizard/esm2022/wizard.component.mjs +18 -1
- app-ng-runtime/components/containers/wizard/fesm2022/index.mjs +17 -0
- app-ng-runtime/components/containers/wizard/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/components/containers/wizard/wizard.component.d.ts +1 -0
- app-ng-runtime/components/data/form/esm2022/form-field/form-field.directive.mjs +1 -3
- app-ng-runtime/components/data/form/fesm2022/index.mjs +0 -2
- app-ng-runtime/components/data/form/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/components/dialogs/default/bundles/index.umd.js +11 -0
- app-ng-runtime/components/dialogs/default/esm2022/base-dialog.mjs +12 -1
- app-ng-runtime/components/dialogs/default/fesm2022/index.mjs +11 -0
- app-ng-runtime/components/dialogs/default/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/components/input/default/bundles/index.umd.js +63 -39
- app-ng-runtime/components/input/default/checkboxset/checkboxset.component.d.ts +0 -1
- app-ng-runtime/components/input/default/esm2022/checkboxset/checkboxset.component.mjs +5 -8
- app-ng-runtime/components/input/default/esm2022/radioset/radioset.component.mjs +5 -8
- app-ng-runtime/components/input/default/esm2022/select/select.component.mjs +57 -29
- app-ng-runtime/components/input/default/esm2022/text/base/base-input.mjs +1 -4
- app-ng-runtime/components/input/default/esm2022/text/locale/number-locale.mjs +2 -2
- app-ng-runtime/components/input/default/esm2022/textarea/textarea.component.mjs +4 -1
- app-ng-runtime/components/input/default/fesm2022/index.mjs +63 -39
- app-ng-runtime/components/input/default/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/components/input/default/radioset/radioset.component.d.ts +0 -1
- app-ng-runtime/components/input/default/select/select.component.d.ts +2 -4
- app-ng-runtime/components/input/default/textarea/textarea.component.d.ts +3 -2
- app-ng-runtime/components/input/epoch/bundles/index.umd.js +3 -0
- app-ng-runtime/components/input/epoch/esm2022/date-time/date-time.component.mjs +4 -1
- app-ng-runtime/components/input/epoch/fesm2022/index.mjs +3 -0
- app-ng-runtime/components/input/epoch/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/components/input/file-upload/bundles/index.umd.js +31 -5
- app-ng-runtime/components/input/file-upload/esm2022/file-upload.component.mjs +34 -8
- app-ng-runtime/components/input/file-upload/fesm2022/index.mjs +32 -6
- app-ng-runtime/components/input/file-upload/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/components/input/file-upload/file-upload.component.d.ts +6 -2
- app-ng-runtime/components/navigation/menu/bundles/index.umd.js +2 -2
- app-ng-runtime/components/navigation/menu/esm2022/menu.component.mjs +2 -2
- app-ng-runtime/components/navigation/menu/esm2022/nav/nav.component.mjs +2 -2
- app-ng-runtime/components/navigation/menu/fesm2022/index.mjs +2 -2
- app-ng-runtime/components/navigation/menu/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/core/bundles/index.umd.js +6 -16
- app-ng-runtime/core/enums/enums.d.ts +1 -2
- app-ng-runtime/core/esm2022/enums/enums.mjs +1 -2
- app-ng-runtime/core/esm2022/types/types.mjs +1 -4
- app-ng-runtime/core/esm2022/utils/build-utils.mjs +1 -6
- app-ng-runtime/core/esm2022/utils/utils.mjs +4 -3
- app-ng-runtime/core/fesm2022/index.mjs +4 -12
- app-ng-runtime/core/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/core/types/types.d.ts +1 -5
- app-ng-runtime/core/utils/utils.d.ts +1 -0
- app-ng-runtime/mobile/core/bundles/index.umd.js +18 -2
- app-ng-runtime/mobile/core/esm2022/native.xhr.mjs +19 -3
- app-ng-runtime/mobile/core/fesm2022/index.mjs +18 -2
- app-ng-runtime/mobile/core/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/package.json +1 -1
- app-ng-runtime/runtime/base/bundles/index.umd.js +5 -288
- app-ng-runtime/runtime/base/esm2022/public_api.mjs +1 -2
- app-ng-runtime/runtime/base/esm2022/runtime-base.module.mjs +1 -6
- app-ng-runtime/runtime/base/esm2022/services/i18n.service.mjs +2 -2
- app-ng-runtime/runtime/base/esm2022/types/types.mjs +1 -2
- app-ng-runtime/runtime/base/fesm2022/index.mjs +4 -287
- app-ng-runtime/runtime/base/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/runtime/base/public_api.d.ts +0 -1
- app-ng-runtime/runtime/base/runtime-base.module.d.ts +8 -9
- app-ng-runtime/runtime/base/types/types.d.ts +1 -2
- app-ng-runtime/runtime/dynamic/bundles/index.umd.js +9 -27
- app-ng-runtime/runtime/dynamic/esm2022/app/app.module.mjs +2 -5
- app-ng-runtime/runtime/dynamic/esm2022/app/services/component-ref-provider.service.mjs +7 -23
- app-ng-runtime/runtime/dynamic/fesm2022/index.mjs +7 -26
- app-ng-runtime/runtime/dynamic/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/scripts/@wavemaker/nvd3/build/nv.d3.min.js +1 -1
- app-ng-runtime/scripts/datatable/datatable.js +6 -3
- app-ng-runtime/scripts/summernote/dist/summernote-lite.min.js +2 -3
- app-ng-runtime/transpiler/bundles/index.umd.js +0 -5
- app-ng-runtime/transpiler/esm2022/build.mjs +1 -4
- app-ng-runtime/transpiler/esm2022/imports.mjs +1 -3
- app-ng-runtime/transpiler/fesm2022/index.mjs +0 -5
- app-ng-runtime/transpiler/fesm2022/index.mjs.map +1 -1
- app-ng-runtime/build-task/advanced/custom-widget-container/custom-widget-container.build.d.ts +0 -2
- app-ng-runtime/build-task/advanced/custom-widget-wrapper/custom-widget-wrapper.build.d.ts +0 -2
- app-ng-runtime/build-task/esm2022/advanced/custom-widget-container/custom-widget-container.build.mjs +0 -15
- app-ng-runtime/build-task/esm2022/advanced/custom-widget-wrapper/custom-widget-wrapper.build.mjs +0 -26
- app-ng-runtime/components/advanced/custom/.npmignore +0 -2
- app-ng-runtime/components/advanced/custom/bundles/index.umd.js +0 -232
- app-ng-runtime/components/advanced/custom/custom-widget-container/custom-widget-container.directive.d.ts +0 -19
- app-ng-runtime/components/advanced/custom/custom-widget-container/custom-widget.props.d.ts +0 -2
- app-ng-runtime/components/advanced/custom/custom-widget-prop.d.ts +0 -1
- app-ng-runtime/components/advanced/custom/custom-widget.directive.d.ts +0 -19
- app-ng-runtime/components/advanced/custom/custom-widget.module.d.ts +0 -10
- app-ng-runtime/components/advanced/custom/esm2022/custom-widget-container/custom-widget-container.directive.mjs +0 -102
- app-ng-runtime/components/advanced/custom/esm2022/custom-widget-container/custom-widget.props.mjs +0 -12
- app-ng-runtime/components/advanced/custom/esm2022/custom-widget-prop.mjs +0 -8
- app-ng-runtime/components/advanced/custom/esm2022/custom-widget.directive.mjs +0 -68
- app-ng-runtime/components/advanced/custom/esm2022/custom-widget.module.mjs +0 -32
- app-ng-runtime/components/advanced/custom/esm2022/index.mjs +0 -5
- app-ng-runtime/components/advanced/custom/esm2022/public_api.mjs +0 -4
- app-ng-runtime/components/advanced/custom/fesm2022/index.mjs +0 -215
- app-ng-runtime/components/advanced/custom/fesm2022/index.mjs.map +0 -1
- app-ng-runtime/components/advanced/custom/index.d.ts +0 -5
- app-ng-runtime/components/advanced/custom/package.json +0 -23
- app-ng-runtime/components/advanced/custom/public_api.d.ts +0 -3
- app-ng-runtime/components/base/esm2022/widgets/common/base/custom-widget-container.directive.mjs +0 -39
- app-ng-runtime/components/base/widgets/common/base/custom-widget-container.directive.d.ts +0 -14
- app-ng-runtime/runtime/base/components/base-custom-widget.component.d.ts +0 -72
- app-ng-runtime/runtime/base/esm2022/components/base-custom-widget.component.mjs +0 -288
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"index.mjs","sources":["../../../../../projects/components/widgets/data/form/src/form.props.ts","../../../../../projects/components/widgets/data/form/src/form.component.html","../../../../../projects/components/widgets/data/form/src/form.component.ts","../../../../../projects/components/widgets/data/form/src/form-widget.directive.ts","../../../../../projects/components/widgets/data/form/src/form-action/form-action.props.ts","../../../../../projects/components/widgets/data/form/src/form-action/form-action.directive.ts","../../../../../projects/components/widgets/data/form/src/form-field/form-field.props.ts","../../../../../projects/components/widgets/data/form/src/form-field/form-field.directive.ts","../../../../../projects/components/widgets/data/form/src/live-actions/live-actions.directive.ts","../../../../../projects/components/widgets/data/form/src/live-actions/dependson.directive.ts","../../../../../projects/components/widgets/data/form/src/live-filter/live-filter.directive.ts","../../../../../projects/components/widgets/data/form/src/live-form/live-form.directive.ts","../../../../../projects/components/widgets/data/form/src/form.module.ts","../../../../../projects/components/widgets/data/form/src/index.ts"],"sourcesContent":["import { isMobileApp } from '@wm/core';\n\nimport { PROP_ANY, PROP_BOOLEAN, PROP_NUMBER, PROP_STRING, register } from '@wm/components/base';\n\nconst propsMap = new Map(\n [\n ['autocomplete', {value: false, ...PROP_BOOLEAN}],\n ['captionalign', {value: 'left', ...PROP_STRING}],\n ['captionposition', {value: 'left', ...PROP_STRING}],\n ['captionsize', PROP_STRING],\n ['captionwidth', {value: 'xs-12 sm-3 md-3 lg-3', ...PROP_STRING}],\n ['class', PROP_STRING],\n ['collapsible', PROP_BOOLEAN],\n ['dataset', PROP_ANY],\n ['datasource', PROP_STRING],\n ['expanded', {value: true, ...PROP_BOOLEAN}],\n ['formdatasource', PROP_STRING],\n ['name', PROP_STRING],\n ['numberOfFields', PROP_NUMBER],\n ['show', {value: true, ...PROP_BOOLEAN}],\n ['showindevice', {displayType: 'inline-block', value: 'all', ...PROP_STRING}],\n ['subheading', PROP_STRING],\n ['tabindex', {value: 0, ...PROP_NUMBER}],\n ['title', PROP_STRING]\n ]\n);\n\n\nexport const registerFormProps = () => {\n if (isMobileApp()) {\n propsMap.set('captionwidth', {value: 'xs-4 sm-4 md-4 lg-4', ...PROP_STRING});\n }\n const formMap = new Map(propsMap);\n formMap.set('action', PROP_STRING);\n formMap.set('defaultmode', {value: 'Edit', ...PROP_STRING});\n formMap.set('metadata', PROP_STRING);\n formMap.set('method', PROP_STRING);\n formMap.set('postmessage', {value: 'Data posted successfully', ...PROP_STRING});\n formMap.set('target', PROP_STRING);\n formMap.set('enctype', PROP_STRING);\n formMap.set('errormessage', {value: 'An error occured. Please try again!', ...PROP_STRING});\n formMap.set('messagelayout', {value: 'Inline', ...PROP_STRING});\n formMap.set('formdata', PROP_STRING);\n formMap.set('novalidate', PROP_BOOLEAN);\n formMap.set('validationtype', {value: 'default', ...PROP_STRING});\n formMap.set('iconclass', PROP_STRING);\n\n register(\n 'wm-form',\n formMap\n );\n};\n\nexport const registerLiveFormProps = () => {\n if (isMobileApp()) {\n propsMap.set('captionwidth', {value: 'xs-4 sm-4 md-4 lg-4', ...PROP_STRING});\n }\n const liveFormMap = new Map(propsMap);\n liveFormMap.set('defaultmode', {value: 'View', ...PROP_STRING});\n liveFormMap.set('formlayout', {value: 'inline', ...PROP_STRING});\n liveFormMap.set('insertmessage', {value: 'Record added successfully', ...PROP_STRING});\n liveFormMap.set('updatemessage', {value: 'Record updated successfully', ...PROP_STRING});\n liveFormMap.set('deletemessage', {value: 'Record deleted successfully', ...PROP_STRING});\n liveFormMap.set('errormessage', {value: 'An error occured. Please try again!', ...PROP_STRING});\n liveFormMap.set('messagelayout', {value: 'Toaster', ...PROP_STRING});\n liveFormMap.set('formdata', PROP_STRING);\n liveFormMap.set('novalidate', PROP_BOOLEAN);\n liveFormMap.set('validationtype', {value: 'default', ...PROP_STRING});\n liveFormMap.set('iconclass', PROP_STRING);\n\n register(\n 'wm-liveform',\n liveFormMap\n );\n};\n\nexport const registerLiveFilterProps = () => {\n if (isMobileApp()) {\n propsMap.set('captionwidth', {value: 'xs-4 sm-4 md-4 lg-4', ...PROP_STRING});\n }\n const liveFilterMap = new Map(propsMap);\n liveFilterMap.set('autoupdate', PROP_BOOLEAN);\n liveFilterMap.set('enableemptyfilter', {value: ' ', ...PROP_STRING});\n liveFilterMap.set('pagesize', {value: 20, ...PROP_NUMBER});\n liveFilterMap.set('iconclass', {value: 'wi wi-filter-list', ...PROP_STRING});\n\n register(\n 'wm-livefilter',\n liveFilterMap\n );\n};\n","<ng-template #content><ng-content></ng-content></ng-template>\n\n<ng-container *ngIf=\"formlayout === 'page'; then pageLayoutTemplate else defaultTemplate\">\n</ng-container>\n\n<ng-template #defaultTemplate>\n <div class=\"panel-heading\" *ngIf=\"!isLayoutDialog && (title || subheading || iconclass || showButtons('header'))\">\n <h3 class=\"panel-title\">\n <div class=\"pull-left\">\n <i class=\"app-icon panel-icon\" aria-hidden=\"true\" [ngClass]=\"iconclass\" *ngIf=\"iconclass\"></i>\n </div>\n <div class=\"pull-left\">\n <div class=\"heading\" [innerHTML]=\"title\"></div>\n <div class=\"description\" [innerHTML]=\"subheading\"></div>\n </div>\n <div class=\"form-action panel-actions basic-btn-grp\">\n <ng-container *ngFor=\"let btn of buttonArray | filter : 'position' : 'header'; let index = index\"\n [ngTemplateOutlet]=\"btn.widgetType === 'button' ? buttonRef : anchorRef\"\n [ngTemplateOutletContext]=\"{btn:btn}\"\n [ngTemplateOutletInjector]=\"createCustomInjector('action_header_' + index, {btn:btn})\">\n </ng-container>\n <button type=\"button\" class=\"app-icon wi panel-action\" *ngIf=\"collapsible\" title=\"Collapse/Expand\"\n [ngClass]=\"expanded ? 'wi-minus': 'wi-plus'\" (click)=\"expandCollapsePanel();\"></button>\n </div>\n </h3>\n </div>\n <div class=\"panel-body\" [ngClass]=\"{'form-elements': isLayoutDialog, 'form-body': !isLayoutDialog}\" [class.hidden]=\"!expanded\">\n <p wmMessage *ngIf=\"!!statusMessage.caption\" [attr.aria-hidden]=\"!statusMessage.caption\" [attr.aria-label]=\"statusMessage.caption\" caption.bind=\"statusMessage.caption\" type.bind=\"statusMessage.type\"></p>\n <div [ngClass]=\"{'form-elements': !isLayoutDialog, 'form-content': isLayoutDialog}\">\n <ng-container *ngTemplateOutlet=\"content\"></ng-container>\n </div>\n <div class=\"basic-btn-grp form-action panel-footer clearfix\" [ngClass]=\"{'modal-footer': isLayoutDialog}\" [class.hidden]=\"!expanded || !showButtons('footer')\">\n <ng-container *ngFor=\"let btn of buttonArray | filter : 'position' : 'footer'; let index = index\"\n [ngTemplateOutlet]=\"btn.widgetType === 'button' ? buttonRef : anchorRef\"\n [ngTemplateOutletContext]=\"{btn:btn}\"\n [ngTemplateOutletInjector]=\"createCustomInjector('action_footer_' + index, {btn:btn})\">\n </ng-container>\n </div>\n </div>\n</ng-template>\n\n<ng-template #pageLayoutTemplate>\n <ng-container *ngTemplateOutlet=\"content\"></ng-container>\n</ng-template>\n\n<ng-template #buttonRef let-btn=\"btn\">\n <button wmButton name=\"{{btn.key}}\" caption.bind=\"btn.displayName\" class.bind=\"btn.class\" iconclass.bind=\"btn.iconclass\" show.bind=\"btn.show\"\n (click)=\"invokeActionEvent($event, btn.action)\" type.bind=\"btn.type\" hint.bind=\"btn.title\" shortcutkey.bind=\"btn.shortcutkey\" disabled.bind=\"ngform.status === 'PENDING' || btn.disabled\"\n tabindex.bind=\"btn.tabindex\" [attr.aria-label]=\"btn.displayName\" [class.hidden]=\"btn.updateMode ? !isUpdateMode : isUpdateMode\"></button>\n</ng-template>\n\n<ng-template #anchorRef let-btn=\"btn\">\n <a wmAnchor name=\"{{btn.key}}\" caption.bind=\"btn.displayName\" class.bind=\"btn.class\" iconclass.bind=\"btn.iconclass\" show.bind=\"btn.show\"\n (click)=\"invokeActionEvent($event, btn.action)\" hint.bind=\"btn.title\" shortcutkey.bind=\"btn.shortcutkey\"\n hyperlink.bind=\"btn.hyperlink\" target.bind=\"btn.target\"\n tabindex.bind=\"btn.tabindex\" [class.hidden]=\"btn.updateMode ? !isUpdateMode : isUpdateMode\"></a>\n</ng-template>\n\n<ng-container #dynamicForm></ng-container>\n","import {\n AfterContentInit,\n AfterViewInit,\n Attribute,\n Component,\n ContentChildren,\n HostBinding,\n HostListener, Inject,\n Injector,\n NgZone,\n OnDestroy,\n Optional,\n SkipSelf,\n ViewChild,\n ViewContainerRef\n} from '@angular/core';\nimport {FormArray, FormBuilder, FormGroup} from '@angular/forms';\n\nimport {\n $appDigest,\n $invokeWatchers,\n $parseEvent,\n AbstractDialogService,\n App,\n DataSource,\n DataType,\n debounce,\n DynamicComponentRefProvider,\n extendProto,\n getClonedObject,\n getFiles,\n getValidJSON,\n isDefined,\n isElementInViewport,\n removeAttr,\n removeClass,\n scrollToElement,\n} from '@wm/core';\nimport {\n getFieldLayoutConfig,\n Live_Operations,\n MessageComponent,\n parseValueByType,\n PartialDirective,\n performDataOperation,\n provideAsWidgetRef,\n StylableComponent,\n styler,\n WidgetRef\n} from '@wm/components/base';\nimport {PrefabDirective} from '@wm/components/prefab';\nimport {ListComponent} from '@wm/components/data/list';\n\nimport {registerFormProps} from './form.props';\nimport {\n debounce as _debounce,\n filter,\n find, findIndex,\n forEach,\n get,\n includes,\n isArray,\n isEmpty, isEqual,\n isUndefined,\n keys,\n last,\n set,\n some,\n split\n} from \"lodash-es\";\n\nconst WIDGET_CONFIG = {widgetType: 'wm-form', hostClass: 'panel app-panel app-form'};\nconst LOGIN_FORM_CONFIG = {widgetType: 'wm-form', hostClass: 'app-form app-login-form'};\nconst LIVE_FORM_CONFIG = {widgetType: 'wm-liveform', hostClass: 'panel app-panel app-liveform liveform-inline'};\nconst LIVE_FILTER_CONFIG = {widgetType: 'wm-livefilter', hostClass: 'panel app-panel app-livefilter clearfix liveform-inline'};\n\nconst getWidgetConfig = (isLiveForm, isLiveFilter, role) => {\n let config = WIDGET_CONFIG;\n if (isLiveForm !== null) {\n config = LIVE_FORM_CONFIG;\n } else if (isLiveFilter !== null) {\n config = LIVE_FILTER_CONFIG;\n } else if (role === 'app-login') {\n config = LOGIN_FORM_CONFIG;\n }\n return config;\n};\n\n// Generate the form field with given field definition. Add a grid column wrapper around the form field.\nconst setMarkupForFormField = (field, columnWidth) => {\n let propsTmpl = '';\n forEach(field, (value, key) => {\n propsTmpl = `${propsTmpl} ${key}=\"${value}\"`;\n });\n return `<wm-gridcolumn columnwidth=\"${columnWidth}\">\n <wm-form-field ${propsTmpl}></wm-form-field>\n </wm-gridcolumn>`;\n};\n\n// Function to find out the first invalid element in form\nconst findInvalidElement = ($formEle, ngForm) => {\n const $ele = $formEle.find('form.ng-invalid:visible, [formControlName].ng-invalid:visible').first();\n let formObj = ngForm;\n // If element is form, find out the first invalid element in this form\n if ($ele.is('form')) {\n formObj = ngForm && ngForm.controls[$ele.attr('formControlName') || $ele.attr('name')];\n if (formObj) {\n return findInvalidElement($ele, formObj);\n }\n }\n return {\n ngForm: formObj,\n $ele: $ele\n };\n};\n\n// Function to get the active element markup based on widget type\nconst getActiveElement = (element) => {\n const widgetType = element.getAttribute('widgettype');\n switch (widgetType) {\n case 'select':\n return element.querySelector('select');\n break;\n case 'textarea':\n return element.querySelector('textarea');\n break;\n default:\n return element.querySelector('input');\n }\n}\nconst setTouchedState = (self, ngForm, fieldName) => {\n if (ngForm.valid) {\n return;\n }\n if (ngForm.controls) {\n forEach(ngForm.controls, (ctrl, fieldName) => {\n setTouchedState(self, ctrl, fieldName);\n });\n } else {\n let element = self.$element.find(`[wmformfield][key=\"${fieldName}\"]`);\n if (!element.length) {\n element = self.$element.find(`[wmformfield][name=\"${fieldName}\"]`);\n }\n element[0].setAttribute('__errormsg', element[0].getAttribute('__validationId'));\n let activeElement = getActiveElement(element[0]);\n activeElement?.setAttribute('aria-invalid', ngForm.invalid);\n activeElement?.setAttribute('aria-describedby', element[0].getAttribute('__validationId'));\n ngForm.markAsTouched();\n }\n};\n\n@Component({\n selector: 'form[wmForm]',\n templateUrl: './form.component.html',\n providers: [\n provideAsWidgetRef(FormComponent)\n ]\n})\nexport class FormComponent extends StylableComponent implements OnDestroy, AfterContentInit, AfterViewInit {\n static initializeProps = registerFormProps();\n @ViewChild('dynamicForm', { static: true, read: ViewContainerRef }) dynamicFormRef: ViewContainerRef;\n @ViewChild(MessageComponent) messageRef;\n // this is the reference to the component refs inside the form-group\n @ContentChildren(WidgetRef, {descendants: true}) componentRefs;\n\n autoupdate;\n public formlayout: any;\n public isDataSourceUpdated: boolean;\n captionAlignClass: string;\n validationtype: string;\n captionalign: string;\n captionposition: string;\n captionsize;\n collapsible: boolean;\n expanded: boolean;\n elScope;\n _widgetClass = '';\n captionwidth: string;\n _captionClass = '';\n ngform: FormGroup;\n formFields = [];\n formfields = {};\n formWidgets = {};\n filterWidgets = {};\n buttonArray = [];\n dataoutput = {};\n datasource;\n formdatasource;\n formdata = {};\n isSelected;\n prevDataValues;\n prevDataObject;\n prevformFields;\n statusMessage = {\n caption: '',\n type: ''\n };\n messagelayout;\n metadata;\n errormessage;\n onError;\n onSuccess;\n primaryKey = [];\n postmessage;\n _liveTableParent;\n updateMode;\n name;\n // Live Form Methods\n clearData: Function;\n cancel: Function;\n delete: Function;\n save: Function;\n saveAndNew: Function;\n saveAndView: Function;\n setPrimaryKey: () => {};\n dialogId: string;\n // Live Filter\n enableemptyfilter;\n pagesize;\n result;\n pagination;\n clearFilter: Function;\n applyFilter: Function;\n filter: Function;\n filterOnDefault: Function;\n onMaxDefaultValueChange: Function;\n numberOfFields: number;\n\n private _debouncedUpdateFieldSource: Function = _debounce(this.updateFieldSource, 350);\n private operationType;\n private _isLayoutDialog;\n private _dynamicContext;\n private _isGridLayoutPresent;\n private validationMessages = [];\n private formGroupName;\n private formArrayIndex;\n private bindingValue;\n private _formIsInList;\n private _triggeredByUser: boolean;\n\n\n private _debouncedSubmitForm = debounce(($event) => {\n // calling submit event in ngZone as change detection is not triggered post the submit callback and actions like notification are not shown\n this.ngZone.run(() => {\n this.submitForm($event);\n });\n }, 250);\n\n set isLayoutDialog(nv) {\n if (nv) {\n removeClass(this.nativeElement, 'panel app-panel liveform-inline');\n }\n this._isLayoutDialog = nv;\n }\n\n get isLayoutDialog() {\n return this._isLayoutDialog;\n }\n\n private _isUpdateMode;\n set isUpdateMode(nv) {\n this._isUpdateMode = nv;\n this.formFields.forEach(field => {\n field.setReadOnlyState(nv);\n });\n }\n\n get isUpdateMode() {\n return this._isUpdateMode;\n }\n\n @HostBinding('action') action: string;\n\n @HostListener('submit', ['$event']) submit($event) {\n this._debouncedSubmitForm($event);\n }\n\n @HostListener('reset') onReset() {\n this.reset();\n }\n\n @HostListener('keydown', ['$event']) onKeydownHandler(event: KeyboardEvent) {\n this._triggeredByUser = true;\n }\n // returns the formArray control on the parentForm.\n get parentFormArray(): FormArray {\n return this.parentForm && this.isParentList && this.parentForm.ngform.get(this.parentList.name) as FormArray;\n }\n\n // returns true only when closest livelist is the immediate parent of the form.\n // checks for livelist having any form elements with parentForm name.\n // If livelist is not containing any parentForm elements then it returns true.\n get isParentList() {\n if (this.parentList && this.parentForm && !isDefined(this._formIsInList)) {\n const formEle = this.$element;\n const listEle = formEle.closest('.app-livelist[name=\"' + this.parentList.name + '\"]');\n if (listEle.length) {\n this._formIsInList = !(listEle.find('form[widget-id=\"' + this.parentForm.widgetId + '\"]')).length;\n }\n }\n return isDefined(this._formIsInList) ? this._formIsInList : this.parentList;\n }\n\n constructor(\n inj: Injector,\n private fb: FormBuilder,\n private app: App,\n private dialogService: AbstractDialogService,\n private dynamicComponentProvider: DynamicComponentRefProvider,\n private ngZone: NgZone,\n @Optional() public parentList: ListComponent,\n @SkipSelf() @Optional() public parentForm: FormComponent,\n @SkipSelf() @Optional() public parentPrefab: PrefabDirective,\n @SkipSelf() @Optional() public parentPartial: PartialDirective,\n @Attribute('beforesubmit.event') public onBeforeSubmitEvt,\n @Attribute('submit.event') public onSubmitEvt,\n @Attribute('beforerender.event') public onBeforeRenderEvt,\n @Attribute('dataset.bind') public binddataset,\n @Attribute('formdata.bind') private bindformdata,\n @Attribute('wmLiveForm') isLiveForm,\n @Attribute('wmLiveFilter') isLiveFilter,\n @Attribute('data-role') role,\n @Attribute('key') key,\n @Attribute('name') name,\n @Inject('EXPLICIT_CONTEXT') @Optional() explicitContext: any\n ) {\n super(inj, getWidgetConfig(isLiveForm, isLiveFilter, role), explicitContext);\n\n styler(this.nativeElement, this);\n\n // remove title property as attribute as it is causing unnecessary tooltip\n removeAttr(this.nativeElement, 'title');\n this.isUpdateMode = true;\n this.dialogId = this.nativeElement.getAttribute('dialogId');\n this.ngform = fb.group({});\n this.bindingValue = key || name;\n\n // On value change in form, update the dataoutput\n const onValueChangeSubscription = this.ngform.valueChanges\n .subscribe(this.updateDataOutput.bind(this));\n this.registerDestroyListener(() => onValueChangeSubscription.unsubscribe());\n this.elScope = this;\n\n this.addEventsToContext(this.context);\n }\n\n ngAfterContentInit() {\n setTimeout(() => {\n this.componentRefs.forEach(componentRef => {\n if (componentRef.name) {\n // Register widgets inside form with formWidgets\n this.formWidgets[componentRef.name] = componentRef;\n }\n });\n }, 250);\n }\n\n ngAfterViewInit() {\n if (this.parentForm && this.parentForm.ngform && this.isParentList) {\n // setting formArray control on ngform.\n if (!get(this.parentForm.ngform.controls, this.parentList.name)) {\n this.parentForm.ngform.setControl(this.parentList.name, new FormArray([]));\n }\n // pushing the ngform to formArray.\n this.parentFormArray.push(this.ngform);\n this.formArrayIndex = this.parentFormArray.length - 1;\n }\n this.addInnerNgFormToForm(this.bindingValue);\n }\n\n findOperationType() {}\n\n private addInnerNgFormToForm(binding) {\n if (this.parentForm && this.parentForm.ngform) {\n // handling as formArray when parent is list. Hence returning here from adding to parentForm again.\n if (this.isParentList) {\n return;\n }\n // assigning the control name of the form inside the prefab with the prefab name.\n // This will happen only when there is only one form inside prefab.\n // We do not support changing this when multiple forms are inside prefab.\n // This scenario has to be handled by end user by changing form names in prefab according to the datamodel binding.\n const parentContainer = this.parentPrefab || this.parentPartial;\n if (parentContainer) {\n let parentContentEl;\n if (this.parentPrefab) {\n parentContentEl = parentContainer.$element.find('[wmprefabcontainer]');\n } else {\n parentContentEl = parentContainer.$element;\n }\n /**\n * assigning the form name to the parentContainer name i.e. partial name or perfab name by following\n * 1. retrieving all the forms in the parentContainer\n * 2. consider the first form\n * 3. if this form is inside list i.e. also find if this list is also inside the parentContainer (prefab / partial)\n * 4. then do not change the form name when form is inside list and also when there are siblings to the form\n * 5. this means form name change applies only when there is single form (immediate child) inside the parentContainer.\n */\n const prefabInnerForm = parentContentEl.find('form').first();\n if (get(prefabInnerForm[0], 'widget.widgetId') === this.widgetId) {\n // check whether form inside prefab container is inside the list. If true, do not change the name.\n if (!prefabInnerForm.isParentList && !prefabInnerForm.siblings('form').length) {\n binding = get(parentContainer, 'name');\n }\n }\n }\n let counter = 1;\n let innerBinding = binding;\n // Inner forms may have same names. If same name is present, append unqiue identifier\n while (this.parentForm.ngform.controls.hasOwnProperty(innerBinding)) {\n innerBinding = `${binding}_${counter}`;\n counter++;\n }\n this.formGroupName = innerBinding;\n // If parent form is present, add the current form as as formGroup for parent form\n this.parentForm.ngform.addControl(innerBinding, this.ngform);\n }\n }\n\n // Expose the events on context so that they can be accessed by form actions\n private addEventsToContext(context) {\n context.cancel = () => this.cancel();\n context.reset = () => this.reset();\n context.save = evt => this.save(evt);\n context.saveAndNew = () => this.saveAndNew();\n context.saveAndView = () => this.saveAndView();\n context.delete = () => this.delete();\n context.new = () => this.new();\n context.edit = () => this.edit();\n context.highlightInvalidFields = () => this.highlightInvalidFields();\n context.filter = () => this.filter();\n context.clearFilter = () => this.clearFilter();\n context.submit = evt => this.submit(evt);\n }\n\n // This method gets all the inner forms and validates each form.\n private setValidationOnInnerForms(validateTouch) {\n const formEle = this.getNativeElement();\n const formObjs = formEle.querySelectorAll('.app-form');\n const validationMsgs = [];\n forEach(formObjs, e => {\n const formInstance = (e as any).widget;\n // differentiating the validationMessages prefix based on the formGroupName\n // as the formName's are same when forms are in list\n let formName = get(formInstance, 'formGroupName') || formInstance.name;\n if (isDefined(formInstance.formArrayIndex)) {\n formName = formName + '[' + formInstance.formArrayIndex + ']';\n }\n let current = formInstance;\n while (get(current, 'parentForm')) {\n let parentName = current.parentForm.formGroupName || current.parentForm.name;\n if (current.parentForm.parentFormArray) {\n parentName = parentName + '[' + current.parentForm.formArrayIndex + ']';\n }\n formName = parentName + '.' + formName;\n current = current.parentForm;\n }\n this.setValidationOnFields(formInstance, formName, validateTouch);\n });\n }\n\n /**\n * This method sets validation on formFields.\n * Applies to innerform and also sets innerform validation on parent form.\n * @param prefix contains the form name, which also includes its parents form name\n * @param {boolean} validateTouch\n */\n private setValidationOnFields(form: FormComponent, prefix: string, validateTouch?: boolean) {\n const controls = form.ngform.controls;\n const formFields = form.formFields;\n if (!formFields) {\n return;\n }\n forEach(controls, (v, k) => {\n const field = formFields.find(e => e.key === k);\n if (!field || (validateTouch && !v.touched)) {\n return;\n }\n field.nativeElement.querySelector('input')?.setAttribute('aria-invalid', v.invalid);\n // invoking the prepareValidation on both parent form and current form.\n this.prepareValidationObj(v, k, field, prefix);\n this.prepareValidationObj.call(form, v, k, field, prefix);\n });\n }\n\n // Assigns / updates validationMessages based on angular errors on field\n private prepareValidationObj(v, k, field, prefix) {\n const index = this.validationMessages.findIndex(e => (e.field === k && e.fullyQualifiedFormName === prefix));\n if (v.invalid) {\n if (index === -1) {\n /**\n * field contains the fieldName\n * value contains the field value\n * errorType contains the list of errors\n * message contains the validation message\n * getElement returns the element having focus-target\n * formName returns the name of the form\n */\n this.validationMessages.push({\n field: k,\n value: field.value,\n errorType: keys(v.errors),\n message: field.validationmessage || '',\n getElement: () => {\n return field.$element.find('[focus-target]');\n },\n formName: last(prefix.split('.')),\n fullyQualifiedFormName: prefix\n });\n } else {\n this.validationMessages[index].value = field.value;\n this.validationMessages[index].errorType = keys(v.errors);\n }\n } else if (v.valid && index > -1) {\n this.validationMessages.splice(index, 1);\n }\n }\n\n // This will return a object containing the error details from the list of formFields that are invalid\n private setValidationMsgs(validateTouch?: boolean) {\n if (!this.formFields.length && isEmpty(this.ngform.controls)) {\n return;\n }\n this.setValidationOnFields(this, this.name, validateTouch);\n this.setValidationOnInnerForms(validateTouch);\n }\n\n // change and blur events are added from the template\n protected handleEvent(node: HTMLElement, eventName: string, callback: Function, locals: any) {\n if (eventName !== 'submit') {\n super.handleEvent(this.nativeElement, eventName, callback, locals);\n }\n }\n\n private updateFieldSource() {\n if (this.formdatasource && this.formdatasource.execute(DataSource.Operation.IS_API_AWARE)) {\n return;\n } else if (this.formdatasource && !this.formdatasource.twoWayBinding) {\n return;\n }\n this.formFields.forEach(formField => {\n formField.setFormWidget('datavaluesource', this.formdatasource);\n formField.setFormWidget('binddatavalue', `${this.bindformdata}.${formField.key}`);\n });\n }\n\n // This method loops through the form fields and highlights the invalid fields by setting state to touched\n highlightInvalidFields() {\n setTouchedState(this, this.ngform, '');\n }\n\n // Disable the form submit if form is in invalid state. Highlight all the invalid fields if validation type is default\n validateFieldsOnSubmit() {\n this.setValidationMsgs();\n // Disable the form submit if form is in invalid state. For delete operation, do not check the validation.\n if (this.operationType !== 'delete' && (this.validationtype === 'html' || this.validationtype === 'default')\n && this.ngform && this.ngform.invalid) {\n\n if (this.ngform.invalid) {\n if (this.validationtype === 'default') {\n this.highlightInvalidFields();\n }\n // Find the first invalid untoched element and set it to touched.\n // Safari does not form validations. this will ensure that error is shown for user\n const eleForm = findInvalidElement(this.$element, this.ngform);\n const $invalidForm = eleForm.ngForm;\n let $invalidEle = eleForm.$ele;\n $invalidEle = $invalidEle.parent().find('[focus-target]');\n if ($invalidEle.length) {\n // on save click in page layout liveform, focus of autocomplete widget opens full-screen search.\n if (!$invalidEle.hasClass('app-search-input')) {\n $invalidEle.focus();\n }\n const ngEle = $invalidForm && $invalidForm.controls[$invalidEle.attr('formControlName') || $invalidEle.attr('name')];\n if (ngEle && ngEle.markAsTouched) {\n ngEle.markAsTouched();\n }\n $appDigest();\n return true;\n }\n return true;\n }\n return false;\n }\n return false;\n }\n\n onPropertyChange(key, nv, ov?) {\n switch (key) {\n case 'captionalign':\n this.captionAlignClass = 'align-' + nv;\n break;\n case 'captionposition':\n this.setLayoutConfig();\n break;\n case 'captionwidth':\n this.setLayoutConfig();\n break;\n case 'captionsize':\n this.captionsize = nv;\n break;\n case 'novalidate':\n // Set validation type based on the novalidate property\n this.widget.validationtype = (nv === true || nv === 'true') ? 'none' : 'default';\n break;\n case 'formdata':\n // For livelist when multiselect is enabled, formdata will be array of objects. In this case consider the last object as formdata.\n if (isEqual(nv, ov)) {\n break;\n }\n isArray(nv) ? this.setFormData(last(nv)) : this.setFormData(nv);\n // if dataset on the formFields are not set as the datasourceChange is triggered before the formFields are registered.\n if (!this.isDataSourceUpdated && this.datasource) {\n this.onDataSourceChange();\n }\n break;\n case 'defaultmode':\n if (!this.isLayoutDialog) {\n if (nv && nv === 'Edit') {\n this.updateMode = true;\n } else {\n this.updateMode = false;\n }\n this.isUpdateMode = this.updateMode;\n }\n break;\n case 'datasource':\n this.onDataSourceChange();\n break;\n case 'formdatasource':\n this.onFormDataSourceChange();\n break;\n case 'metadata':\n this.generateFormFields();\n break;\n case 'dataset':\n const formFields = this.getFormFields();\n formFields.forEach(field => {\n // notifying the dataset change to the form-field widget.\n if (!field.isDataSetBound && get(field.formWidget, 'dataset$')) {\n field.formWidget.dataset$.next();\n }\n });\n break;\n default:\n super.onPropertyChange(key, nv, ov);\n }\n }\n\n // Event callbacks on success/error\n onResultCb(data, status, event?) {\n const params = {$event: event, $data: data, $operation: this.operationType};\n // whether service call success or failure call this method\n this.invokeEventCallback('result', params);\n if (status) {\n // if service call is success call this method\n this.invokeEventCallback('success', params);\n } else {\n // if service call fails call this method\n this.invokeEventCallback('error', params);\n }\n }\n\n // Display or hide the inline message/ toaster\n toggleMessage(show: boolean, msg?: string, type?: string, header?: string) {\n let template;\n if (show && msg) {\n template = (type === 'error' && this.errormessage) ? this.errormessage : msg;\n if (this.messagelayout === 'Inline') {\n template = this.checkAppServiceErrorMsg(type) || template;\n this.statusMessage = {'caption': template || '', type: type};\n if (this.messageRef) {\n this.messageRef.showMessage(this.statusMessage.caption, this.statusMessage.type);\n }\n // when message layout is inline on save, scroll the view to top of the form to see the status of the operation\n if (!isElementInViewport(this.$element[0])) {\n scrollToElement(this.$element[0]);\n }\n } else {\n this.app.notifyApp(template, type, header);\n }\n } else {\n this.statusMessage.caption = '';\n }\n }\n\n // if there is an App.onServiceError handler for the app, that message should be used instead of server returned error message\n checkAppServiceErrorMsg(type) {\n const notificationAction = get(this.app, 'Actions.appNotification');\n if (notificationAction && type === 'error') {\n return notificationAction.getMessage();\n }\n return;\n }\n\n // Hide the inline message/ toaster\n clearMessage() {\n this.toggleMessage(false);\n }\n\n // Set the classes on the form based on the captionposition and captionwidth properties\n private setLayoutConfig() {\n let layoutConfig;\n layoutConfig = getFieldLayoutConfig(this.captionwidth, this.captionposition, get(this.app.selectedViewPort, 'os'));\n this._widgetClass = layoutConfig.widgetCls;\n this._captionClass = layoutConfig.captionCls;\n\n $appDigest();\n }\n\n registerFormWidget(widget) {\n const name = widget.name || widget.key;\n this.formWidgets[name] = widget;\n }\n\n registerFormFields(formField) {\n const fieldCount = this.formFields.push(formField);\n this.formfields[formField.key] = formField;\n this.registerFormWidget(formField);\n this._debouncedUpdateFieldSource();\n if (this.parentForm) {\n this.parentForm.formFields.push(formField);\n this.parentForm.formfields[formField.key] = formField;\n // inner formfields are pushed to parentForm, passing current innerForm's formdata to set innerFormdata to these innerFormFields\n this.parentForm.setFormData(this.parentForm.formdata, this.formFields, this.formdata || {});\n }\n // WMS-18967: Applying formadata after formfields are ready\n if (fieldCount === this.numberOfFields && !isEmpty(this.formdata)) {\n this.onDataSourceChange();\n isArray(this.formdata) ? this.setFormData(last(this.formdata)) : this.setFormData(this.formdata);\n }\n }\n\n registerActions(formAction) {\n this.buttonArray.push(formAction);\n }\n\n // Update the dataoutput whenever there is a change in inside form widget value\n updateFormDataOutput(dataObject) {\n // Set the values of the widgets inside the live form (other than form fields) in form data\n forEach(this.ngform.value, (val, key) => {\n if (!find(this.formFields, {key})) {\n dataObject[key] = val;\n }\n });\n this.dataoutput = dataObject;\n }\n\n // Construct the data object merging the form fields and custom widgets data\n constructDataObject() {\n const formData = {};\n const formFields = this.getFormFields();\n // Get all form fields and prepare form data as key value pairs\n formFields.forEach(field => {\n let fieldName,\n fieldValue;\n fieldValue = field.datavalue || field._control.value;\n fieldValue = (fieldValue === null || fieldValue === '') ? undefined : fieldValue;\n\n if (field.type === 'file') {\n fieldValue = getFiles(this.name, field.key + '_formWidget', field.multiple);\n }\n\n fieldName = field.key || field.target || field.name;\n\n // on current Form, when field is innerForm field then we group these fields under new object using formGroupName as key\n // For suppose, applicantName, applicantID are formfields in currentForm\n // This form is having innerform i.e. address, these fields are listed as\n // {\"applicantName\": \"\", \"applicantID\": \"\", \"address\": {\"street\": \"\"}}\n if (field.form.widgetId !== this.widgetId && field.form.formGroupName) {\n const fd = get(formData, field.form.formGroupName, {});\n fd[fieldName] = fieldValue;\n set(formData, field.form.formGroupName, fd);\n } else if ((typeof field.form.formArrayIndex === 'number') && field.form.isParentList && !this.parentForm) { // Fix for [WMS-25806]: use formArrayIndex only if form has a parent form\n // setting formdata based on formArrayIndex\n const fd = get(formData, field.form.parentList.name, []);\n fd[field.form.formArrayIndex] = fd[field.form.formArrayIndex] || {};\n fd[field.form.formArrayIndex][fieldName] = fieldValue;\n set(formData, field.form.parentList.name, fd);\n } else {\n // In case of update the field will be already present in form data\n set(formData, fieldName, fieldValue);\n }\n });\n this.updateFormDataOutput(formData);\n return this.dataoutput;\n }\n\n updateDataOutput() {\n this.constructDataObject();\n if (this.ngform.touched) {\n this.setValidationMsgs(true);\n }\n }\n\n // FormFields will contain all the fields in parent and inner form also.\n // This returns the formFields in the form based on the form name.\n getFormFields() {\n return filter(this.formFields, formField => {\n return formField.form.name === this.name;\n });\n }\n\n setFieldValue(field, data, innerFormdata?) {\n const key = field.key || field.name;\n // if customfield param value is not in the formdata then do not assign field value\n // as it can contain default value which will again be overridden by undefined.\n const fd = innerFormdata ? innerFormdata : data;\n if (fd) {\n if (fd.hasOwnProperty(key)) {\n field.value = get(fd, key);\n } else if (includes(key, '.')) {\n // key contains '.' when mapping the fields to child reference i.e. childCol is having key as \"parent.childCol\"\n if (fd.hasOwnProperty(split(key, '.')[0])) {\n field.value = get(fd, key);\n }\n }\n // WMS-18906: For default value, do not mark the form as dirty.\n if (this.dirty && !this._triggeredByUser) {\n this.markAsPristine();\n }\n }\n const formGroupName = field.form.formGroupName;\n /**\n * if formGroupName is defined which means field is inside the inner form\n * then set the formdata on the field's form using formGroupName\n */\n if (formGroupName && get(data, formGroupName)) {\n this.setFormData.call(field.form, data[formGroupName]);\n }\n // if formdata is assigned later then on propertyChangeHandler, even inner forms data also needs to be updated.\n if (get(field.form, 'parentFormArray')) {\n this.setFormDataFromParentFormData.call(field.form, data);\n }\n }\n\n setFormData(data, innerFormFields?, innerFormdata?) {\n // whereas formFields explicitly passed can contain innerform fields also.\n const formFields = innerFormFields || this.formFields;\n formFields.forEach(field => {\n this.setFieldValue(field, data, innerFormdata);\n if (field.fieldValidations) {\n field.fieldValidations.setCustomValidationMessage();\n }\n });\n this.constructDataObject();\n }\n\n resetFormState() {\n // clearing the validationMessages on reset.\n if (this.validationMessages.length) {\n this.validationMessages = [];\n }\n if (!this.ngform) {\n return;\n }\n this.ngform.markAsUntouched();\n this.ngform.markAsPristine();\n }\n\n reset() {\n this.resetFormState();\n this.formFields.forEach(field => {\n field.value = '';\n if (field.widgettype === 'upload' || field.type === DataType.BLOB) {\n this.resetFileUploadWidget(field, true);\n }\n field.nativeElement.querySelector('input')?.removeAttribute('aria-invalid');\n });\n this.constructDataObject();\n this.clearMessage();\n }\n\n savePrevformFields() {\n this.prevformFields = getClonedObject(this.formFields.map(field => {\n return {\n 'key': field.key,\n 'type': field.type,\n 'widgettype': field.widgettype,\n 'outputformat': field.outputformat,\n 'value': field.value\n };\n }));\n }\n\n savePrevDataValues() {\n this.prevDataValues = this.formFields.map((obj) => {\n return {'key': obj.key, 'value': obj.value};\n });\n }\n\n setReadonlyFields() {\n this.formFields.forEach(field => {\n field.setReadOnlyState();\n });\n }\n\n resetFileUploadWidget(field, skipValueSet?) {\n const $formEle = this.$element;\n $formEle.find('[name=\"' + field.key + '_formWidget\"]').val('');\n field._control.reset();\n if (!skipValueSet) {\n field.href = '';\n field.value = null;\n }\n }\n\n emptyDataModel() {\n this.formFields.forEach(field => {\n if (isDefined(field)) {\n if (field.type === DataType.BLOB) {\n this.resetFileUploadWidget(field);\n } else {\n field.datavalue = '';\n }\n }\n });\n }\n\n setDefaultValues() {\n this.formFields.forEach(field => {\n this.onFieldDefaultValueChange(field, field.defaultvalue);\n });\n }\n\n setOperationType(mode) {\n this.operationType = mode || 'insert';\n }\n\n new() {\n this.resetFormState();\n this.operationType = Live_Operations.INSERT;\n this.clearMessage();\n if (this.isSelected) {\n this.savePrevformFields();\n }\n this.emptyDataModel();\n setTimeout(() => {\n this.setDefaultValues();\n this.savePrevDataValues();\n this.constructDataObject();\n });\n this.isUpdateMode = true;\n }\n\n edit() {\n this.resetFormState();\n this.clearMessage();\n\n this.operationType = Live_Operations.UPDATE;\n\n if (this.isSelected) {\n this.savePrevformFields();\n this.savePrevDataValues();\n }\n this.prevDataObject = getClonedObject(this.formdata || {});\n\n this.setReadonlyFields();\n this.isUpdateMode = true;\n\n $appDigest();\n }\n\n private triggerWMEvent(eventName) {\n const tableId = this.nativeElement.getAttribute('dependsontable');\n if (!tableId) {\n return;\n }\n $invokeWatchers(true);\n this.app.notify('wm-event', {eventName, widgetName: tableId});\n }\n\n submitForm($event) {\n let template, formData, result;\n const dataSource = this.datasource;\n // Disable the form submit if form is in invalid state.\n if (this.validateFieldsOnSubmit()) {\n return;\n }\n\n formData = getClonedObject(this.constructDataObject());\n\n const getParams = () => {\n return {$event, $formData: formData, $data: formData};\n };\n\n\n if (this.onBeforeSubmitEvt) {\n if (this.invokeEventCallback('beforesubmit', getParams()) === false) {\n return;\n } else {\n this.resetFormState();\n }\n } else {\n this.resetFormState();\n }\n\n if (this.onSubmitEvt || dataSource) {\n // If on submit is there execute it and if it returns true do service variable invoke else return\n // If its a service variable call setInput and assign form data and invoke the service\n if (dataSource) {\n const currentPageNum = dataSource.pagination && dataSource.pagination.number + 1;\n const operationType = this.operationType ? this.operationType : 'insert';\n performDataOperation(dataSource, formData, {operationType: operationType})\n .then((data) => {\n if (dataSource.category === 'wm.CrudVariable') {\n this.triggerWMEvent('resetEditMode');\n this.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true,\n 'operation': 'list',\n 'page': currentPageNum,\n 'preventMissingOpMsg': true\n });\n if (this.dialogId) {\n this.closeDialog();\n }\n }\n if (isDefined(data.body)) {\n result = getValidJSON(data.body);\n result = isDefined(result) ? result : data.body;\n } else {\n result = data;\n }\n return {\n 'result': result,\n 'status': true,\n 'message': this.postmessage,\n 'type': 'success'\n };\n }, (error) => {\n template = this.errormessage || error.error || error;\n $appDigest();\n return {\n 'result': get(error, 'error') || error,\n 'status': false,\n 'message': template,\n 'type': 'error'\n };\n }).then(response => {\n if ((response.type === 'error' && !this.onError) || (response.type === 'success' && !this.onSuccess)) {\n this.toggleMessage(true, response.message, response.type);\n }\n this.invokeEventCallback('submit', getParams());\n this.onResultCb(response.result, response.status, $event);\n });\n } else {\n this.invokeEventCallback('submit', getParams());\n this.onResultCb({}, true, $event);\n }\n } else {\n this.onResultCb({}, true, $event);\n }\n }\n\n closeDialog() {\n this.dialogService.close(this.dialogId);\n }\n\n // Method to show/hide the panel header or footer based on the buttons\n showButtons(position) {\n return some(this.buttonArray, btn => {\n return includes(btn.position, position) && btn.updateMode === this.isUpdateMode;\n });\n }\n\n // Expand or collapse the panel\n expandCollapsePanel() {\n if (this.collapsible) {\n // flip the active flag\n this.expanded = !this.expanded;\n }\n }\n\n onDataSourceUpdate(response, newForm, updateMode) {\n if (newForm) {\n this.new();\n } else {\n this.setFormData(response);\n this.closeDialog();\n }\n this.isUpdateMode = isDefined(updateMode) ? updateMode : true;\n }\n\n /**\n * This method tranverses through the parent containing formdata and returns the parent formdata.\n * @param form, represents the current form instance\n * @returns {any}\n */\n getNearestParentFormData(form) {\n if (!form.parentForm) {\n return {};\n }\n if (!form.bindformdata && get(form.parentForm, 'formdata') && !isEmpty(form.parentForm.formdata)) {\n return form.parentForm.formdata;\n }\n return this.getNearestParentFormData(form.parentForm);\n }\n\n setFormDataFromParentFormData(formdata: any) {\n if (isEmpty(this.formdata) && this.parentForm && formdata) {\n /**\n * If form is inside list,\n * 1. directly applying the formdata to the formArray to update the formdata on list of forms using patchValue.\n * 2. and also setting individual formdata to the form inside each item based on formArrayIndex, when form is not bound to formdata.\n * 3. explicitly invoking formdata as formFields will contain all the formfields including innerForm's fields\n * (if we do not invoke explicitly then formFields will just contain the fields inside current form and not inner form fields)\n * 4. if childFormArrayData is not available we will check for inner form data using \"formGroupName\" and will set the innerform data\n * If not inside list, just set the formdata on all the formfields including innerForm fields\n */\n if (this.parentFormArray) {\n let childFormArrayData = get(formdata, this.parentList.name);\n if (childFormArrayData) {\n if (!isArray(childFormArrayData)) {\n childFormArrayData = [childFormArrayData];\n }\n this.parentFormArray.patchValue(childFormArrayData);\n if (!this.bindformdata) {\n this.formdata = childFormArrayData[this.formArrayIndex];\n }\n this.setFormData(this.formdata);\n } else if (this.isParentList && this.parentForm.formGroupName) {\n const parentFormData = get(formdata, this.parentForm.formGroupName);\n this.setFormDataFromParentFormData(parentFormData);\n }\n } else {\n this.setFormData(formdata);\n }\n }\n }\n\n // On form data source change. This method is overridden by live form and live filter\n onDataSourceChange() {\n if (get(this.formFields, 'length') && !this.bindformdata) {\n this.isDataSourceUpdated = true;\n /**\n * formdata on the parent form will be set before the inner forms are rendered.\n * Hence handling formdata on the innerForms, which might be rendered slowly (suppose prefab with form)\n * setting inner form's formdata obtained from parent formdata\n * this applies only when formdata is not given on the inner form.\n */\n const formdata = this.getNearestParentFormData(this);\n this.setFormDataFromParentFormData(formdata);\n }\n }\n\n // On form data source change. This method is overridden by live form and live filter\n onFormDataSourceChange() {\n this.updateFieldSource();\n }\n\n // On form field default value change. This method is overridden by live form and live filter\n onFieldDefaultValueChange(field, nv) {\n field.value = parseValueByType(nv, undefined, field.widgettype, field.trailingzero);\n // WMS-22434: For default value set on individual form fields, do not mark the form as dirty.\n if (this.dirty && !this._triggeredByUser) {\n this.markAsPristine();\n }\n }\n\n // On form field value change. This method is overridden by live form and live filter\n onFieldValueChange() {\n }\n\n // Function to generate and compile the form fields from the metadata\n async generateFormFields() {\n let noOfColumns;\n let $gridLayout;\n // Check if grid layout is present or not for first time\n if (isUndefined(this._isGridLayoutPresent)) {\n this._isGridLayoutPresent = this.$element.find('.panel-body [wmlayoutgrid]').length > 0;\n }\n if (this._isGridLayoutPresent) {\n $gridLayout = this.$element.find('.form-elements [wmlayoutgrid]').first();\n noOfColumns = Number($gridLayout.attr('columns')) || 1;\n } else {\n $gridLayout = this.$element.find('.form-elements .dynamic-form-container');\n if (!$gridLayout.length) {\n this.$element.find('.form-elements').prepend('<div class=\"dynamic-form-container\"></div>');\n $gridLayout = this.$element.find('.form-elements .dynamic-form-container');\n }\n noOfColumns = 1;\n }\n const columnWidth = 12 / noOfColumns;\n let fieldTemplate = '';\n let colCount = 0;\n let index;\n let userFields;\n let fields = this.metadata ? this.metadata.data || this.metadata : [];\n\n this.formFields = []; // empty the form fields\n\n if (isEmpty(fields)) {\n return;\n }\n\n if (this.onBeforeRenderEvt) {\n userFields = this.invokeEventCallback('beforerender', {$metadata: fields});\n if (userFields) {\n fields = userFields;\n }\n }\n\n if (!isArray(fields)) {\n return;\n }\n\n while (fields[colCount]) {\n let colTmpl = '';\n for (index = 0; index < noOfColumns; index++) {\n if (fields[colCount]) {\n colTmpl += setMarkupForFormField(fields[colCount], columnWidth);\n }\n colCount++;\n }\n fieldTemplate += `<wm-gridrow>${colTmpl}</wm-gridrow>`;\n }\n\n if (!this._isGridLayoutPresent) {\n fieldTemplate = `<wm-layoutgrid>${fieldTemplate}</wm-layoutgrid>`;\n }\n\n this.dynamicFormRef.clear();\n\n if (!this._dynamicContext) {\n this._dynamicContext = Object.create(this.viewParent);\n this._dynamicContext.form = this;\n }\n const componentFactoryRef = await this.dynamicComponentProvider.getComponentFactoryRef(\n 'app-form-dynamic-' + this.widgetId,\n fieldTemplate,\n {\n noCache: true,\n transpile: true\n });\n const component = this.dynamicFormRef.createComponent(componentFactoryRef, 0, this.inj);\n extendProto(component.instance, this._dynamicContext);\n $gridLayout[0].appendChild(component.location.nativeElement);\n this.setFormData(this.formdata);\n }\n\n get mode() {\n return this.operationType || this.findOperationType();\n }\n\n get dirty() {\n return this.ngform && this.ngform.dirty;\n }\n\n /**\n * This method sets the form state to pristine by internally calling angular markAsPristine method on the form\n * @param value, When true, mark only this control. When false or not supplied, marks all direct ancestors. Default is false\n * @returns {void}\n */\n markAsPristine(value: boolean = false) {\n this.ngform.markAsPristine({ onlySelf: value });\n }\n\n /**\n * This method sets the form state to dirty by internally calling angular markAsDirty method on the form\n * @param value, When true, mark only this control. When false or not supplied, marks all direct ancestors. Default is false\n * @returns {void}\n */\n markAsDirty(value: boolean = false) {\n this.ngform.markAsDirty({ onlySelf: value });\n }\n\n get invalid() {\n return this.ngform && this.ngform.invalid;\n }\n\n get touched() {\n return this.ngform && this.ngform.touched;\n }\n\n get valid() {\n return this.ngform && this.ngform.valid;\n }\n\n get pristine() {\n return this.ngform && this.ngform.pristine;\n }\n\n /**\n * This method sets the form state to touched by internally calling angular markAsTouched method on the form\n * @param value, When true, mark only this control. When false or not supplied, marks all direct ancestors. Default is false\n * @returns {void}\n */\n markAsTouched(value: boolean = false) {\n this.ngform.markAsTouched({ onlySelf: value });\n }\n\n /**\n * This method sets the form state to untouched by internally calling angular markAsUntouched method on the form\n * @param value, When true, mark only this control. When false or not supplied, marks all direct ancestors. Default is false\n * @returns {void}\n */\n markAsUntouched(value: boolean = false) {\n this.ngform.markAsUntouched({ onlySelf: value });\n }\n\n invokeActionEvent($event, expression: string) {\n const fn = $parseEvent(expression);\n fn(this.viewParent, Object.assign(this.context, {$event}));\n }\n\n ngOnDestroy() {\n // on form destroy, removing this form from the parentForm too.\n const controls = this.parentForm && get(this.parentForm, 'ngform.controls');\n if (controls) {\n // when current form is inside the list (i.e. incase of formArray).\n if (get(this.parentList, 'name') && controls.hasOwnProperty(this.parentList.name)) {\n //get the index of current form in the list and remove the FormControl from FormArray\n const index = findIndex(this.parentList.getWidgets(this.name), {widgetId: this.widgetId});\n (<FormArray>this.parentForm.ngform.controls[this.parentList.name]).removeAt(index);\n }\n // when we have formGroupName set i.e. multiple formInstance with counter appended to formName\n if (this.formGroupName && controls.hasOwnProperty(this.formGroupName)) {\n this.parentForm.ngform.removeControl(this.formGroupName);\n } else {\n this.parentForm.ngform.removeControl(this.name);\n }\n }\n super.ngOnDestroy();\n }\n}\n","import { Attribute, Directive, Inject, OnInit, Self, Optional } from '@angular/core';\nimport { FormBuilder, FormGroup } from '@angular/forms';\n\nimport { WidgetRef } from '@wm/components/base';\nimport { TableComponent } from '@wm/components/data/table';\n\nimport { FormComponent } from './form.component';\n\n@Directive({\n selector: '[wmFormWidget]'\n})\nexport class FormWidgetDirective implements OnInit {\n\n ngform: FormGroup;\n fb;\n parent;\n\n constructor(\n @Optional() @Inject(FormComponent) form,\n @Optional() @Inject(TableComponent) table,\n @Self() @Inject(WidgetRef) public componentInstance,\n fb: FormBuilder,\n @Attribute('name') public name,\n @Attribute('key') public key) {\n this.fb = fb;\n this.parent = form || table;\n this.ngform = this.parent.ngform;\n\n this.componentInstance.registerPropertyChangeListener((k, nv) => {\n if (k === 'datavalue' && this._control) {\n this._control.setValue(nv);\n } else if (k === 'name' && !this._control) {\n this.addControl(this.key || nv);\n }\n });\n }\n\n get _control() {\n const fieldName = this.key || this.name;\n if (!fieldName) {\n return undefined;\n }\n return this.ngform && this.ngform.controls[fieldName];\n }\n\n addControl(fieldName) {\n this.ngform.addControl(fieldName, this.createControl());\n }\n\n createControl() {\n return this.fb.control(this.componentInstance.datavalue);\n }\n\n ngOnInit() {\n const fieldName = this.key || this.name;\n\n if (fieldName && !this._control) {\n this.addControl(fieldName);\n this.parent.registerFormWidget(this.componentInstance);\n }\n }\n}\n","import { PROP_BOOLEAN, PROP_NUMBER, PROP_STRING, register } from '@wm/components/base';\n\nexport const registerProps = () => {\n register(\n 'wm-form-action',\n new Map(\n [\n ['accessroles', PROP_STRING],\n ['action', PROP_STRING],\n ['class', PROP_STRING],\n ['binding', PROP_STRING],\n ['disabled', PROP_BOOLEAN],\n ['display-name', PROP_STRING],\n ['hyperlink', PROP_STRING],\n ['iconclass', PROP_STRING],\n ['iconname', PROP_STRING],\n ['key', PROP_STRING],\n ['position', {value: 'footer', ...PROP_STRING}],\n ['shortcutkey', PROP_STRING],\n ['show', {value: true, ...PROP_BOOLEAN}],\n ['tabindex', {value: 0, ...PROP_NUMBER}],\n ['target', PROP_STRING],\n ['title', PROP_STRING],\n ['type', {value: 'button', ...PROP_STRING}],\n ['update-mode', {value: true, ...PROP_BOOLEAN}],\n ['widget-type', {value: 'button', ...PROP_STRING}]\n ]\n )\n );\n};\n","import {Directive, Inject, Injector, OnInit, Optional} from '@angular/core';\n\nimport { BaseComponent, provideAsWidgetRef } from '@wm/components/base';\n\nimport { registerProps } from './form-action.props';\nimport { FormComponent } from '../form.component';\nimport {isUndefined} from \"lodash-es\";\n\nconst WIDGET_CONFIG = {widgetType: 'wm-form-action', hostClass: ''};\n\n@Directive({\n selector: '[wmFormAction]',\n providers: [\n provideAsWidgetRef(FormActionDirective)\n ]\n})\nexport class FormActionDirective extends BaseComponent implements OnInit {\n static initializeProps = registerProps();\n\n accessroles;\n action;\n binding;\n class;\n disabled;\n displayName;\n iconclass;\n iconname;\n key;\n position;\n shortcutkey;\n show;\n tabindex;\n title;\n type;\n updateMode;\n buttonDef;\n hyperlink;\n target;\n\n private _propsInitialized: boolean;\n\n constructor(inj: Injector, @Optional() public form: FormComponent, @Inject('EXPLICIT_CONTEXT') @Optional() explicitContext: any) {\n super(inj, WIDGET_CONFIG, explicitContext);\n }\n\n populateAction() {\n this.buttonDef = {\n key: this.key || this.binding,\n displayName: this['display-name'],\n show: this.show,\n class: this.class ? this.class : (this['widget-type'] === 'button' ? 'btn-secondary' : ''),\n iconclass: this.iconclass || '',\n title: isUndefined(this.title) ? (this['display-name'] || '') : this.title,\n action: this.action,\n accessroles: this.accessroles,\n shortcutkey: this.shortcutkey,\n disabled: this.disabled,\n tabindex: this.tabindex,\n iconname: this.iconname,\n type: this.type,\n updateMode: this['update-mode'],\n position: this.position,\n widgetType: this['widget-type'],\n hyperlink: this.hyperlink,\n target: this.target\n };\n this._propsInitialized = true;\n }\n\n ngOnInit() {\n super.ngOnInit();\n this.populateAction();\n this.form.registerActions(this.buttonDef);\n }\n\n onPropertyChange(key, nv, ov) {\n if (!this._propsInitialized) {\n return;\n }\n switch (key) {\n case 'display-name':\n this.buttonDef.displayName = nv;\n default:\n this.buttonDef[key] = nv;\n break;\n }\n }\n}\n","import { FormWidgetType } from '@wm/core';\n\nimport { PROP_BOOLEAN, PROP_NUMBER, PROP_STRING, getWidgetPropsByType } from '@wm/components/base';\n\nexport const registerProps = () => {\n const formFieldMap = new Map(\n [\n ['dataentrymode', {value: 'default', ...PROP_STRING}],\n ['debouncetime', {value: 250, ...PROP_NUMBER}],\n ['defaultvalue', PROP_STRING],\n ['displayname', PROP_STRING],\n ['display-name', PROP_STRING],\n ['field', PROP_STRING],\n ['filterexpressions', PROP_STRING],\n ['filter-on', PROP_STRING],\n ['generator', PROP_STRING],\n ['hint', PROP_STRING],\n ['inputtype', PROP_STRING],\n ['is-primary-key', PROP_BOOLEAN],\n ['is-range', PROP_BOOLEAN],\n ['is-related', PROP_BOOLEAN],\n ['isformfield', {value: true}],\n ['key', PROP_STRING],\n ['limit', PROP_NUMBER],\n ['lookup-type', PROP_STRING],\n ['lookup-field', PROP_STRING],\n ['name', PROP_STRING],\n ['matchmode', PROP_STRING],\n ['maxdefaultvalue', PROP_STRING],\n ['maxplaceholder', PROP_STRING],\n ['mobile-display', {value: true, ...PROP_BOOLEAN}],\n ['period', PROP_BOOLEAN],\n ['pc-display', {value: true, ...PROP_BOOLEAN}],\n ['placeholder', PROP_STRING],\n ['primary-key', PROP_BOOLEAN],\n ['related-entity-name', PROP_STRING],\n ['required', PROP_BOOLEAN],\n ['show', {value: true, ...PROP_BOOLEAN}],\n ['tablet-display', {value: true, ...PROP_BOOLEAN}],\n ['type', PROP_STRING],\n ['validationmessage', PROP_STRING],\n ['viewmodewidget', PROP_STRING],\n ['widgettype', PROP_STRING]\n ]\n );\n\n for (const key in FormWidgetType) {\n const widgetName = 'wm-form-field-' + FormWidgetType[key];\n const widgetProps = getWidgetPropsByType(widgetName);\n formFieldMap.forEach((v, k: string) => {\n if (widgetProps.get(k) == undefined) {\n widgetProps.set(k, v);\n }\n });\n }\n};\n","import {\n AfterContentInit,\n Attribute,\n ContentChild,\n Directive,\n HostListener,\n Inject,\n Injector,\n OnInit,\n Optional,\n Self\n} from '@angular/core';\nimport {FormBuilder, FormGroup, NG_VALUE_ACCESSOR} from '@angular/forms';\n\nimport {debounceTime} from 'rxjs/operators';\n\nimport {\n addForIdAttributes,\n App,\n debounce,\n FormWidgetType,\n isDateTimeType,\n isDefined,\n isMobile,\n noop,\n Viewport\n} from '@wm/core';\nimport {\n BaseFieldValidations,\n Context,\n getDefaultViewModeWidget,\n getEvaluatedData,\n provideAs,\n provideAsWidgetRef,\n StylableComponent\n} from '@wm/components/base';\nimport {ListComponent} from '@wm/components/data/list';\n\nimport {registerProps} from './form-field.props';\nimport {FormComponent} from '../form.component';\nimport {forEach, get, isArray, isObject, join} from \"lodash-es\";\n\ndeclare const $;\n\n// Custom validator to show validation error, if setValidationMessage method is used\nconst customValidatorFn = () => {\n return { custom: true };\n};\n\nconst FILE_TYPES = {\n 'image' : 'image/*',\n 'video' : 'video/*',\n 'audio' : 'audio/*'\n};\n\n@Directive({\n selector: '[wmFormField]',\n exportAs: 'wmFormField',\n providers: [\n provideAsWidgetRef(FormFieldDirective),\n provideAs(FormFieldDirective, NG_VALUE_ACCESSOR, true),\n {provide: Context, useFactory: () => { return {} }, multi: true}\n ]\n})\nexport class FormFieldDirective extends StylableComponent implements OnInit, AfterContentInit {\n static initializeProps = registerProps();\n\n @ContentChild('formWidget', {static: true}) formWidget;\n @ContentChild('formWidgetMax') formWidgetMax;\n\n private fb;\n private viewport;\n\n // excludeProps is used to store the props that should not be applied on inner widget\n private excludeProps;\n private _validators;\n private _oldUploadVal;\n\n ngform: FormGroup;\n defaultvalue;\n displayexpression;\n displayfield;\n displaylabel;\n displayname;\n generator;\n key;\n target;\n binding;\n widgettype;\n class;\n readonly;\n show;\n type;\n isDataSetBound;\n viewmodewidget;\n binddataset;\n binddisplayexpression;\n bindChipclass;\n displayimagesrc: string;\n binddisplayimagesrc;\n binddisplaylabel;\n form;\n filetype;\n extensions;\n permitted;\n period;\n isRange;\n name;\n // Validation properties\n required;\n maxchars;\n minvalue;\n maxvalue;\n regexp;\n fieldDefConfig;\n placeholder;\n inputtype;\n validationmessage;\n\n public _fieldName;\n\n private _debounceSetUpValidators;\n private _initPropsRes;\n private parentList;\n private showPendingSpinner: boolean;\n private _activeField: boolean;\n private notifyForFields: any;\n private fieldValidations;\n private _triggeredByUser: boolean;\n private _clicktriggeredByUser: boolean;\n private app: App;\n\n @HostListener('keydown', ['$event']) onKeydownHandler(event: KeyboardEvent) {\n this._triggeredByUser = true;\n }\n\n @HostListener('click', ['$event']) handleClick(event) {\n this._clicktriggeredByUser = true;\n }\n\n private isFocused;\n constructor(\n inj: Injector,\n form: FormComponent,\n fb: FormBuilder,\n viewport: Viewport,\n app: App,\n @Optional() parentList: ListComponent,\n @Attribute('chipclass.bind') bindChipclass: string,\n @Attribute('dataset.bind') binddataset,\n @Attribute('displayexpression.bind') binddisplayexpression: string,\n @Attribute('displaylabel.bind') binddisplaylabel: string,\n @Attribute('widgettype') _widgetType,\n @Attribute('name') name,\n @Attribute('displayimagesrc.bind') binddisplayimagesrc: String,\n @Attribute('key') key,\n @Attribute('is-range') isRange,\n @Attribute('pc-display') pcDisplay,\n @Attribute('mobile-display') mobileDisplay,\n @Attribute('tablet-display') tabletDisplay,\n @Self() @Inject(Context) contexts: Array<any>,\n @Inject('EXPLICIT_CONTEXT') @Optional() explicitContext: any\n ) {\n const WIDGET_CONFIG = {\n widgetType: 'wm-form-field',\n hostClass: '',\n widgetSubType: 'wm-form-field-' + (_widgetType || FormWidgetType.TEXT).trim()\n };\n let resolveFn: Function = noop;\n\n super(inj, WIDGET_CONFIG, explicitContext, new Promise(res => resolveFn = res));\n this._initPropsRes = resolveFn;\n this.app = app;\n this.fieldDefConfig = {};\n this.class = '';\n this.binddataset = binddataset;\n this.binddisplayimagesrc = binddisplayimagesrc;\n this.binddisplayexpression = binddisplayexpression;\n this.bindChipclass = bindChipclass;\n this.binddisplaylabel = binddisplaylabel;\n this.form = form;\n this.fb = fb;\n this.viewport = viewport;\n this._fieldName = key || name;\n this.isRange = isRange;\n this.excludeProps = new Set(['type', 'name']);\n this.widgettype = _widgetType;\n this.parentList = parentList;\n this.notifyForFields = [];\n\n if (this.binddataset || this.$element.attr('dataset')) {\n this.isDataSetBound = true;\n }\n\n contexts[0]._onFocusField = this._onFocusField.bind(this);\n contexts[0]._onBlurField = this._onBlurField.bind(this);\n\n this._debounceSetUpValidators = debounce(() => this.setUpValidators(), 500);\n }\n\n _onFocusField($evt) {\n this._activeField = true;\n $($evt.target).closest('.live-field').addClass('active');\n\n }\n\n // Function to get the active element markup based on widget type\n getActiveElement() {\n const widgetType = this.nativeElement.getAttribute('widgettype');\n switch (widgetType) {\n case 'select':\n return this.nativeElement.querySelector('select');\n break;\n case 'textarea':\n return this.nativeElement.querySelector('textarea');\n break;\n default:\n return this.nativeElement.querySelector('input');\n }\n }\n\n setAriaAttributes() {\n const element = this.getActiveElement();\n if (this.ngform.controls[this._fieldName].invalid && this.ngform.controls[this._fieldName].touched && this.form.isUpdateMode) {\n this.nativeElement.setAttribute('__errormsg', `${this.nativeElement.getAttribute('__validationId')}`);\n element?.setAttribute('aria-invalid', `${this.ngform.controls[this._fieldName].invalid}`);\n element?.setAttribute('aria-describedby', `${this.nativeElement.getAttribute('__validationId')}`);\n } else {\n this.nativeElement.removeAttribute('__errormsg');\n element?.removeAttribute('aria-invalid');\n element?.removeAttribute('aria-describedby');\n }\n }\n\n _onBlurField($evt) {\n $($evt.target).closest('.live-field').removeClass('active');\n const ele = this.nativeElement.querySelector('p.text-danger');\n // Fix for [WMS-23959]: ADA issue - adding aria-describedby, aria-invalid, __errormsg attributes only when the form field is invalid , else removing the attributes\n this.setAriaAttributes();\n this._activeField = false;\n this._triggeredByUser = false;\n this._clicktriggeredByUser = false;\n }\n\n // Expression to be evaluated in view mode of form field\n evaluateExpr(object, displayField, displayExpr) {\n if (!displayExpr || !displayField) {\n displayField = Object.keys(object)[0];\n // If dataset is not ready, display expression will not be defined\n if (!displayField) {\n return;\n }\n }\n return getEvaluatedData(object, {\n field: displayField,\n expression: displayExpr\n }, this.viewParent);\n }\n\n // Expression to be evaluated in view mode of form field\n getDisplayExpr() {\n const caption = [];\n const value = this.value;\n const displayField = this.displayfield || this.displaylabel\n const displayExpr = this.displayexpression;\n if (isObject(value)) {\n if (isArray(value)) {\n forEach(value, obj => {\n if (isObject(obj)) {\n caption.push(this.evaluateExpr(obj, displayField, displayExpr));\n }\n });\n } else {\n caption.push(this.evaluateExpr(value, displayField, displayExpr));\n }\n return join(caption, ',');\n }\n return (value === undefined || value === null) ? '' : this.value;\n }\n\n getCaption() {\n return (this.value === undefined || this.value === null) ? (get(this.form.dataoutput, this._fieldName) || '') : this.value;\n }\n\n // Notifies changes to observing validation fields\n notifyChanges() {\n forEach(this.notifyForFields, field => {\n field.fieldValidations.validate();\n });\n }\n\n // Registers observer of validation fields\n observeOn(fields) {\n this.fieldValidations.observeOn(fields, 'formfields');\n }\n\n // Method to setup validators for reactive form control\n setUpValidators(customValidator?) {\n this.fieldValidations.setUpValidators(customValidator);\n }\n\n // sets the custom async validation on the form field\n setAsyncValidators(validators) {\n this.fieldValidations.setAsyncValidators(validators);\n }\n\n // sets the default and custom sync validation on the form field\n setValidators(validators) {\n this.fieldValidations.setValidators(validators);\n }\n\n // Method to set the properties on inner form widget\n setFormWidget(key, val) {\n if (this.formWidget && this.formWidget.widget) {\n this.formWidget.widget[key] = val;\n }\n }\n\n boundFn(fn) {\n return fn();\n }\n\n // Method to set the properties on inner max form widget (when range is selected)\n setMaxFormWidget(key, val) {\n if (this.formWidgetMax) {\n this.formWidgetMax.widget[key] = val;\n }\n }\n\n onPropertyChange(key, nv, ov?) {\n const isFormDirty = this.form.dirty;\n\n if (key !== 'tabindex') {\n super.onPropertyChange(key, nv, ov);\n }\n\n if (this.excludeProps.has(key)) {\n return;\n }\n\n // As upload widget is an HTML widget, only required property is setup\n if (this.widgettype === FormWidgetType.UPLOAD) {\n if (key === 'required') {\n this._debounceSetUpValidators();\n }\n super.onPropertyChange(key, nv, ov);\n return;\n }\n\n this.setFormWidget(key, nv);\n\n // Placeholder should not be setup on max widget\n if (key !== 'placeholder') {\n this.setMaxFormWidget(key, nv);\n }\n\n switch (key) {\n case 'defaultvalue':\n this.form.onFieldDefaultValueChange(this, nv);\n break;\n case 'maxdefaultvalue':\n this.maxValue = nv;\n this.setMaxFormWidget('datavalue', nv);\n this.form.onMaxDefaultValueChange();\n break;\n case 'maxplaceholder':\n this.setMaxFormWidget('placeholder', nv);\n break;\n case 'required':\n // WMS-18906 : Do not make form as dirty during required prop initialization\n if (isFormDirty !== this.form.dirty) {\n this.form.markAsPristine();\n }\n case 'maxchars':\n case 'minvalue':\n case 'maxvalue':\n case 'regexp':\n case 'show':\n this._debounceSetUpValidators();\n break;\n case 'primary-key':\n if (nv) {\n this.form.setPrimaryKey(this._fieldName);\n }\n break;\n case 'display-name':\n this.displayname = nv;\n break;\n case 'readonly':\n this.setReadOnlyState();\n break;\n }\n }\n\n onStyleChange(key, nv, ov?) {\n this.setFormWidget(key, nv);\n this.setMaxFormWidget(key, nv);\n super.onStyleChange(key, nv, ov);\n }\n\n get datavalue() {\n return this.formWidget && this.formWidget.datavalue;\n }\n\n set datavalue(val) {\n if (this._control && this.widgettype !== FormWidgetType.UPLOAD) {\n this._control.setValue(val);\n }\n }\n\n get value() {\n return this.datavalue;\n }\n\n set value(val) {\n this.datavalue = val;\n }\n\n get maxValue() {\n return this.formWidgetMax && this.formWidgetMax.datavalue;\n }\n\n set maxValue(val) {\n if (this._maxControl) {\n this._maxControl.setValue(val);\n }\n }\n\n get minValue() {\n return this.value;\n }\n\n set minValue(val) {\n this.value = val;\n }\n\n // Get the reactive form control\n get _control() {\n return this.ngform && this.ngform.controls[this._fieldName];\n }\n\n // Get the reactive max form control\n get _maxControl() {\n return this.ngform && this.ngform.controls[this._fieldName + '_max'];\n }\n\n // Get the displayValue\n get displayValue() {\n return this.formWidget && this.formWidget.displayValue;\n }\n\n //Get the timestamp\n get timestamp(){\n return this.formWidget && this.formWidget.timestamp;\n }\n\n //Get the charlength\n get charlength(){\n return this.formWidget && this.formWidget.charlength;\n }\n\n // Create the reactive form control\n createControl() {\n return this.fb.control(undefined, {\n validators: this._validators\n });\n }\n\n // On field value change, propagate event to parent form\n onValueChange(val) {\n if (!this.isDestroyed) {\n const captionEl = $(this.nativeElement).find('.caption-floating');\n if (captionEl.length > 0) {\n // hasValue check whether form-field has a value from passed val attribute\n // Added sanity check on val to support values liked 0, false etc as input val - WMS-20084\n // explicitly checking for input value or -webkit-autofill to see whether there are any autofilled fields - WMS-20141\n\n const hasValue = ((isDefined(val) && val !== '' && val !== null) || captionEl.find('input').val()) || captionEl.find('input:-webkit-autofill').length;\n\n this.app.notify('captionPositionAnimate', {\n displayVal: hasValue,\n nativeEl: captionEl,\n isSelectMultiple: this.formWidget && this.formWidget.multiple,\n isFocused: this._activeField\n });\n }\n // Fix for [WMS-23959]: ADA issue - adding aria-describedby, aria-invalid, __errormsg attributes only when the form field is invalid , else removing the attributes\n this.setAriaAttributes();\n this.form.onFieldValueChange(this, val);\n this.notifyChanges();\n // Do mark as touched, only incase when user has entered an input but not through the script. Hence added mousedown event check\n // active class checks whether user is on the current field, if so marking the field as touched. And form field validation happens once a field is touched\n // _triggeredByUser checks whether the field is touched by the user or triggered from external script\n // WMS-22456: _clicktriggeredByUser checks when user selects datetimetype from picker, mark the field as touched to show validation errors in mobile\n\n if (this.$element.find('.active').length > 0 || this.form.touched) {\n if (this._triggeredByUser || (isMobile() && this._clicktriggeredByUser && isDateTimeType(this.widgettype))) {\n this.ngform.controls[this._fieldName].markAsTouched();\n }\n this.fieldValidations.setCustomValidationMessage();\n }\n }\n }\n\n onStatusChange(status) {\n if (!this.isDestroyed) {\n this.showPendingSpinner = (status === 'PENDING');\n // while running validation, widget is disabled and spinner is shown\n // otherwise formWidget disabled state is reset to the state of the formField.\n if (status === 'PENDING') {\n this.formWidget.disabled = true;\n } else if (this.formWidget.disabled !== (this as any).disabled) {\n this.formWidget.disabled = (this as any).disabled;\n }\n }\n }\n\n // Method to expose validation message and set control to invalid\n setValidationMessage(val) {\n setTimeout(() => {\n this.validationmessage = val;\n this.setUpValidators(customValidatorFn);\n });\n }\n\n setReadOnlyState() {\n let readOnly;\n if (this.form.isUpdateMode) {\n if (this['primary-key'] && !this['is-related'] && !this.period) {\n /*If the field is primary but is assigned set readonly false.\n Assigned is where the user inputs the value while a new entry.\n This is not editable(in update mode) once entry is successful*/\n readOnly = !(this.generator === 'assigned' && this.form.operationType !== 'update');\n } else {\n readOnly = this.readonly;\n }\n } else {\n // In view mode, set widget state to readonly always\n readOnly = true;\n }\n this.setFormWidget('readonly', readOnly);\n }\n\n resetDisplayInput() {\n if ((!isDefined(this.value) || this.value === '')) {\n this.formWidget && this.formWidget.resetDisplayInput && this.formWidget.resetDisplayInput();\n }\n }\n\n triggerUploadEvent($event, eventName) {\n const params: any = { $event };\n if (eventName === 'change') {\n params.newVal = $event.target.files;\n params.oldVal = this._oldUploadVal;\n this._oldUploadVal = params.newVal;\n }\n this.invokeEventCallback(eventName, params);\n }\n\n private registerFormField() {\n\n const fieldName = this._fieldName;\n\n if (this.parentList && !(this.form.parentList === this.parentList)) {\n let counter = 1;\n let _fieldName = fieldName;\n while (this.ngform.controls.hasOwnProperty(_fieldName)) {\n _fieldName = `${fieldName}_${counter}`;\n counter++;\n }\n this.ngform.addControl(_fieldName, this.createControl());\n this._fieldName = _fieldName;\n } else {\n this.ngform.addControl(fieldName, this.createControl());\n }\n const onValueChangeSubscription = this._control.valueChanges\n .pipe(debounceTime(200))\n .subscribe(this.onValueChange.bind(this));\n this.registerDestroyListener(() => onValueChangeSubscription.unsubscribe());\n\n const onStatusChangeSubscription = this._control.statusChanges\n .pipe(debounceTime(100))\n .subscribe(this.onStatusChange.bind(this));\n this.registerDestroyListener(() => onStatusChangeSubscription.unsubscribe());\n\n if (this.isRange === 'true') {\n this.ngform.addControl(fieldName + '_max', this.createControl());\n // registering for valueChanges on MaxformWidget\n const onMaxValueChangeSubscription = this._maxControl.valueChanges\n .pipe(debounceTime(200))\n .subscribe(this.onValueChange.bind(this));\n this.registerDestroyListener(() => onMaxValueChangeSubscription.unsubscribe());\n }\n this.value = get(this.form.formdata, this._fieldName);\n }\n\n ngOnInit() {\n this.ngform = this.form.ngform;\n this.registerFormField();\n // Instantiate custom validators class for form field\n this.fieldValidations = new BaseFieldValidations(this, this.formWidget, this.widgettype, this._control, this.form);\n super.ngOnInit();\n }\n\n ngAfterContentInit() {\n super.ngAfterContentInit();\n\n if (this.formWidget) {\n this._initPropsRes();\n\n // setting displayExpressions on the formwidget explicitly as expr was evaluated to \"\".\n this.setFormWidget('binddisplaylabel', this.binddisplaylabel);\n this.setFormWidget('binddisplayexpression', this.binddisplayexpression);\n this.setFormWidget('binddisplayimagesrc', this.binddisplayimagesrc);\n this.setFormWidget('bindChipclass', this.bindChipclass);\n this.setFormWidget('binddataset', this.binddataset);\n }\n\n this.registerReadyStateListener(() => {\n this.key = this._fieldName || this.target || this.binding;\n this.viewmodewidget = this.viewmodewidget || getDefaultViewModeWidget(this.widgettype);\n\n // For upload widget, generate the permitted field\n if (this.widgettype === FormWidgetType.UPLOAD) {\n let fileType;\n // Create the accepts string from file type and extensions\n fileType = this.filetype ? FILE_TYPES[this.filetype] : '';\n this.permitted = fileType + (this.extensions ? (fileType ? ',' : '') + this.extensions : '');\n }\n if (isMobile() && this.viewport.isMobileType) {\n if (!this['mobile-display']) {\n this.widget.show = false;\n }\n } else if (this.viewport.isTabletType) {\n if (!this['tablet-display']) {\n this.widget.show = false;\n }\n } else {\n if (!this['pc-display']) {\n this.widget.show = false;\n }\n }\n\n this.fieldDefConfig.displaname = this.displayname;\n this.fieldDefConfig.show = this.show;\n this.fieldDefConfig.isRelated = this['is-related'];\n this.fieldDefConfig.inputtype = this.inputtype;\n this.fieldDefConfig.generator = this.generator;\n this.fieldDefConfig.placeholder = this.placeholder;\n this.fieldDefConfig.primaryKey = this['primary-key'];\n this.fieldDefConfig.required = this.required;\n this.fieldDefConfig._readonly = this.readonly;\n this.fieldDefConfig.regexp = this.regexp;\n this.fieldDefConfig.type = this.type;\n this.fieldDefConfig.key = this.key;\n this.fieldDefConfig.mobileDisplay = this['mobile-display'];\n this.fieldDefConfig.name = this.name;\n this.fieldDefConfig.pcDisplay = this['pc-display'];\n this.fieldDefConfig.tabletDisplay = this['tablet-display'];\n this.fieldDefConfig.validationmessage = this.validationmessage;\n this.fieldDefConfig.viewmodewidget = this.viewmodewidget;\n this.fieldDefConfig.widget = this.widgettype;\n\n // Register the form field with parent form\n this.form.registerFormFields(this.widget);\n\n addForIdAttributes(this.nativeElement);\n\n this.setReadOnlyState();\n });\n }\n}\n","import { Directive, Inject, Self } from '@angular/core';\n\nimport { AbstractDialogService, App, DataSource, triggerFn } from '@wm/core';\nimport { Live_Operations, performDataOperation } from '@wm/components/base';\nimport { ListComponent } from '@wm/components/data/list';\n\n@Directive({\n selector: '[wmLiveActions]'\n})\nexport class LiveActionsDirective {\n\n constructor(\n @Self() @Inject(ListComponent) private subscribedWidget,\n private app: App,\n private dialogService: AbstractDialogService\n ) {\n subscribedWidget.addRow = this.addRow.bind(this);\n subscribedWidget.updateRow = this.updateRow.bind(this);\n subscribedWidget.deleteRow = this.deleteRow.bind(this);\n subscribedWidget.call = this.call.bind(this);\n }\n\n public addRow() {\n this.app.notify('wm-event', {eventName: Live_Operations.INSERT, widgetName: this.subscribedWidget.name, row: this.subscribedWidget.selecteditem});\n }\n\n public updateRow() {\n this.app.notify('wm-event', {eventName: Live_Operations.UPDATE, widgetName: this.subscribedWidget.name, row: this.subscribedWidget.selecteditem});\n }\n\n public deleteRow() {\n this.app.notify('wm-event', {eventName: Live_Operations.DELETE, widgetName: this.subscribedWidget.name, row: this.subscribedWidget.selecteditem});\n }\n\n private successHandler(options, response) {\n triggerFn(options.success, response);\n }\n\n private errorHandler(options, error) {\n this.app.notifyApp(error, 'error', 'ERROR');\n triggerFn(options.error, error);\n }\n\n public getRecords(options, operation) {\n let index;\n let dataNavigator;\n\n if (this.subscribedWidget.navigation !== 'None' && this.subscribedWidget.dataNavigator) {\n dataNavigator = this.subscribedWidget.dataNavigator;\n\n // If operation is delete, decrease the data size and check if navigation to previous page is required\n if (operation === Live_Operations.DELETE) {\n dataNavigator.dataSize -= 1;\n dataNavigator.calculatePagingValues();\n index = dataNavigator.pageCount < dataNavigator.dn.currentPage ? 'prev' : undefined;\n } else {\n // If operation is insert, go to last page. If update operation, stay on current page\n index = operation === Live_Operations.INSERT ? 'last' : 'current';\n if (index === 'last') {\n dataNavigator.dataSize += 1;\n }\n dataNavigator.calculatePagingValues();\n }\n\n dataNavigator.navigatePage(index, null, true, response => {\n this.successHandler(options, response);\n });\n } else {\n this.subscribedWidget.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true\n }).then(response => {\n this.successHandler(options, response);\n }, err => {\n this.errorHandler(options, err);\n });\n }\n }\n\n private performCUDOperation(requestData, operation, options) {\n performDataOperation(this.subscribedWidget.datasource, requestData, {\n operationType: operation\n }).then(response => {\n if (response.error) {\n this.errorHandler(options, response.error);\n return;\n }\n if (this.subscribedWidget.datasource.category === 'wm.CrudVariable' && operation === 'delete') {\n this.subscribedWidget.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true\n }).then(response => {\n this.successHandler(options, response);\n }, err => {\n this.errorHandler(options, err);\n });\n } else {\n this.getRecords(options, operation);\n }\n // show delete success toaster\n if (operation === 'delete') {\n this.app.notifyApp(this.app.appLocale.MESSAGE_DELETE_RECORD_SUCCESS, 'success');\n }\n }, (error) => {\n this.errorHandler(options, error);\n });\n }\n\n private insertRecord(requestData, operation, options) {\n this.performCUDOperation(requestData, operation, options);\n }\n\n private updateRecord(requestData, operation, options) {\n this.performCUDOperation(requestData, operation, options);\n }\n\n private deleteRecord(requestData, operation, options) {\n // Show the delete confirmation dialog. On Ok, delete the record.\n this.dialogService.showAppConfirmDialog({\n title: this.app.appLocale.MESSAGE_DELETE_RECORD || 'Delete Record',\n iconclass: 'wi wi-delete fa-lg',\n message: this.subscribedWidget.confirmdelete || 'Are you sure you want to delete this?',\n oktext: this.subscribedWidget.deleteoktext || 'Ok',\n canceltext: this.subscribedWidget.deletecanceltext || 'Cancel',\n onOk: () => {\n this.performCUDOperation(requestData, operation, options);\n this.dialogService.closeAppConfirmDialog();\n },\n onCancel: () => {\n triggerFn(options.cancelDeleteCallback);\n this.dialogService.closeAppConfirmDialog();\n }\n });\n }\n\n private performOperation(operation, options) {\n const requestData = {\n row: options.row,\n prevData: {},\n rowData: {},\n transform: true,\n skipNotification: true\n };\n\n if (operation === Live_Operations.UPDATE) {\n requestData.rowData = options.rowData;\n requestData.prevData = options.prevData;\n }\n\n /* decide routine based on CRUD operation to be performed */\n switch (operation) {\n case Live_Operations.INSERT:\n this.insertRecord(requestData, operation, options);\n break;\n case Live_Operations.UPDATE:\n this.updateRecord(requestData, operation, options);\n break;\n case Live_Operations.DELETE:\n this.deleteRecord(requestData, operation, options);\n break;\n case Live_Operations.READ:\n this.getRecords(options, operation);\n break;\n }\n }\n\n // API exposed to make CRUD operations\n public call(operation, options, success?, error?) {\n options.success = success;\n options.error = error;\n\n this.performOperation(operation, options);\n }\n}\n","import { Directive, Attribute, ContentChildren, AfterContentInit, OnDestroy } from '@angular/core';\n\nimport { AbstractDialogService, App, DataSource } from '@wm/core';\nimport { Live_Operations } from '@wm/components/base';\nimport { FormComponent } from '../form.component';\n\n@Directive({\n selector: '[dependson]'\n})\nexport class DependsonDirective implements AfterContentInit, OnDestroy {\n\n @ContentChildren(FormComponent, {descendants: true}) formChildren;\n\n private dialogId;\n private dependson;\n private isLayoutDialog;\n private form;\n private editMode;\n private currentOp;\n private currentFormData;\n private formSubscription;\n private eventSubscription;\n\n constructor(\n @Attribute('dialogid') dialogId: string,\n @Attribute('dependson') dependson: string,\n private dialogService: AbstractDialogService,\n private app: App\n ) {\n // If dialogId is present, form is in dialog mode\n if (dialogId) {\n this.isLayoutDialog = true;\n this.dialogId = dialogId;\n }\n this.dependson = dependson;\n // Listen to the wm-event called from subscribed widgets\n this.eventSubscription = this.app.subscribe('wm-event', this.handleEvent.bind(this));\n }\n\n private openFormDialog() {\n this.dialogService.open(this.dialogId);\n }\n\n private onUpdate(newValue?, table?, editClicked?) {\n this.editMode = editClicked || this.editMode ;\n this.form.operationType = Live_Operations.UPDATE;\n this.form.isSelected = true;\n let rowData = this.currentFormData;\n if (newValue && table) {\n if (table.multiselect) {\n rowData = newValue[0];\n } else {\n rowData = newValue[newValue.length - 1];\n }\n }\n this.form.setFormData(rowData);\n this.form.edit();\n if (!this.editMode) {\n this.form.isUpdateMode = false;\n }\n }\n private onInsert() {\n this.form.operationType = Live_Operations.INSERT;\n this.form.isSelected = true;\n this.form.setFormData({});\n this.form.new();\n }\n\n private handleEvent(options) {\n if (this.dependson !== options.widgetName) {\n return;\n }\n this.currentOp = options.eventName;\n switch (options.eventName) {\n case Live_Operations.UPDATE:\n this.currentFormData = options.row;\n if (this.isLayoutDialog) {\n this.openFormDialog();\n } else {\n this.onUpdate(undefined,undefined, true);\n }\n break;\n case Live_Operations.INSERT:\n if (this.isLayoutDialog) {\n this.openFormDialog();\n } else {\n this.onInsert();\n }\n break;\n case Live_Operations.DELETE:\n (<any>this.app).Widgets[this.dependson].call('delete', {row: options.row});\n break;\n case Live_Operations.READ:\n if (!this.isLayoutDialog) {\n this.form.isUpdateMode = false;\n }\n break;\n case 'rerender':\n if (options.dataSource) {\n options.dataSource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true,\n 'operation': 'list'\n });\n }\n break;\n case 'selectedItemChange':\n if (options.table) {\n this.onUpdate(options.row, options.table);\n }\n break;\n case 'resetEditMode':\n this.editMode = false;\n }\n }\n\n private onFormRender() {\n // On opening the form in dialog mode, complete the pending operations\n if (this.form && this.isLayoutDialog) {\n this.form.isLayoutDialog = true;\n setTimeout(() => {\n if (this.currentOp === Live_Operations.UPDATE) {\n this.onUpdate(undefined, undefined, true);\n } else if (this.currentOp === Live_Operations.INSERT) {\n this.onInsert();\n }\n }, 250);\n }\n }\n\n ngAfterContentInit() {\n // If form instance is present, form is in inline mode. Else, it is in dialog mode and listen to form instance changes\n if (this.formChildren.first) {\n this.form = this.formChildren.first;\n } else {\n this.formSubscription = this.formChildren.changes.subscribe((val) => {\n this.form = val.first;\n this.onFormRender();\n });\n }\n\n // find the dependent widget (table/list)\n this.app.notify('setup-cud-listener', this.dependson);\n }\n\n ngOnDestroy() {\n if (this.formSubscription) {\n this.formSubscription.unsubscribe();\n }\n if (this.eventSubscription) {\n this.eventSubscription();\n }\n }\n}\n","import { Directive, Inject, Self } from '@angular/core';\nimport { $appDigest, DataSource, DataType, debounce, FormWidgetType, getClonedObject, isDefined } from '@wm/core';\nimport { applyFilterOnField, fetchDistinctValues, getDistinctValuesForField, getEmptyMatchMode, getEnableEmptyFilter, getRangeFieldValue, getRangeMatchMode, isDataSetWidget } from '@wm/components/base';\n\nimport { FormComponent } from '../form.component';\nimport { registerLiveFilterProps } from '../form.props';\nimport {find} from \"lodash-es\";\n\nconst FILTER_CONSTANTS = {\n 'EMPTY_KEY' : 'EMPTY_NULL_FILTER'\n};\nconst noop = () => {};\n\n@Directive({\n selector: '[wmLiveFilter]'\n})\nexport class LiveFilterDirective {\n static initializeProps = registerLiveFilterProps();\n private _options;\n\n orderBy;\n\n // debounce the filter function. If multiple filter calls are made at same time, calls will be delayed and last call is fired\n _filter = debounce(options => {\n this.filter(options);\n }, 250);\n\n constructor(@Self() @Inject(FormComponent) private form) {\n form.clearFilter = this.clearFilter.bind(this);\n form.applyFilter = this.applyFilter.bind(this);\n form.filter = this.filter.bind(this);\n form.filterOnDefault = this.filterOnDefault.bind(this);\n form.execute = this.execute.bind(this);\n form.onFieldDefaultValueChange = this.onFieldDefaultValueChange.bind(this);\n form.onMaxDefaultValueChange = this.onMaxDefaultValueChange.bind(this);\n form.onDataSourceChange = this.onDataSourceChange.bind(this);\n form.onFieldValueChange = this.onFieldValueChange.bind(this);\n form.submitForm = this.submitForm.bind(this);\n form.registerFormWidget = this.registerFormWidget.bind(this);\n }\n\n execute(operation, options) {\n if (operation === DataSource.Operation.LIST_RECORDS || operation === DataSource.Operation.DOWNLOAD) {\n return this.applyFilter(options);\n }\n if (operation === DataSource.Operation.GET_OPTIONS) {\n return this._options || {};\n }\n if (operation === DataSource.Operation.GET_PAGING_OPTIONS) {\n return this.form.pagination;\n }\n if (!this.form.datasource) {\n return {};\n }\n if (operation === DataSource.Operation.FETCH_DISTINCT_VALUES) {\n return fetchDistinctValues(this.form.datasource, this.form.formFields, {\n widget: 'widgettype',\n enableemptyfilter: this.form.enableemptyfilter,\n EMPTY_VALUE: this.form.appLocale.LABEL_NO_VALUE\n });\n }\n return this.form.datasource.execute(operation, options);\n }\n\n onFieldDefaultValueChange(field, nv) {\n field.minValue = nv;\n field.value = nv;\n this.filterOnDefault();\n }\n\n onFieldValueChange(field, nv) {\n applyFilterOnField(this.form.datasource, field.widget, this.form.formFields, nv, {\n EMPTY_VALUE: this.form.appLocale.LABEL_NO_VALUE\n });\n if (this.form.autoupdate && isDefined(nv)) {\n this._filter();\n }\n }\n\n onMaxDefaultValueChange() {\n setTimeout(() => {\n this.filterOnDefault();\n });\n }\n\n onDataSourceChange() {\n const dataSource = this.form.datasource;\n\n if (!dataSource) {\n return;\n }\n\n this.form.formFields.forEach(field => {\n if (isDataSetWidget(field.widgettype)) {\n getDistinctValuesForField(dataSource, field.widget, {\n widget: 'widgettype',\n enableemptyfilter: this.form.enableemptyfilter,\n EMPTY_VALUE: this.form.appLocale.LABEL_NO_VALUE\n });\n applyFilterOnField(dataSource, field.widget, this.form.formFields, field.value, {\n isFirst: true,\n EMPTY_VALUE: this.form.appLocale.LABEL_NO_VALUE\n });\n }\n });\n\n // On load check if default value exists and apply filter, Call the filter with the result options\n this._filter(this._options);\n }\n\n clearFilter() {\n this.form.resetFormState();\n this.form.formFields.forEach(filterField => {\n // Added check for range field\n if (!filterField.readonly && filterField.show) {\n if (filterField.widgettype === FormWidgetType.AUTOCOMPLETE || filterField.widgettype === FormWidgetType.TYPEAHEAD) {\n this.form.$element.find('div[name=' + filterField.name + '] input').val('');\n }\n if (filterField['is-range']) {\n filterField.minValue = '';\n filterField.maxValue = '';\n } else {\n filterField.value = '';\n filterField.resetDisplayInput();\n }\n }\n });\n // If variable has any bindings, wait for the bindings to be updated\n setTimeout(() => {\n // Setting result to the default data\n this._filter();\n });\n }\n\n submitForm() {\n this.filter();\n }\n\n applyFilter(options) {\n options = options ? (options.data || options) : {};\n options.page = options.page || 1;\n options.orderBy = isDefined(options.orderBy) ? options.orderBy : this.orderBy;\n return this.filter(options);\n }\n\n filter(options?) {\n if (!this.form.datasource) {\n return;\n }\n const filterFields = {};\n const dataModel = {};\n let page = 1,\n orderBy,\n isValid;\n options = options || {};\n page = options.page || page;\n orderBy = isDefined(options.orderBy) ? options.orderBy : (this.orderBy || '');\n this.orderBy = orderBy; // Store the order by in scope. This can be used to retain the sort after filtering\n // Copy the values to be sent to the user as '$data' before servicecall\n this.form.formFields.forEach(field => {\n const fieldSelector = 'div[name=' + field.name + '] input';\n const $el = this.form.$element;\n let fieldEle;\n if ((field.widgettype === FormWidgetType.AUTOCOMPLETE || field.widgettype === FormWidgetType.TYPEAHEAD) && $el) {\n fieldEle = $el.find(fieldSelector);\n if (!field['is-range']) {\n dataModel[field.field] = {\n 'value': isDefined(field.value) ? field.value : fieldEle.val() // For autocomplete, set the datavalue. If not present, set query value\n };\n } else {\n dataModel[field.field] = {\n 'minValue': isDefined(field.minValue) ? field.minValue : fieldEle.first().val(),\n 'maxValue': isDefined(field.maxValue) ? field.maxValue : fieldEle.last().val()\n };\n }\n return;\n }\n if (!field['is-range']) {\n dataModel[field.field] = {\n 'value': field.value\n };\n } else {\n dataModel[field.field] = {\n 'minValue': field.minValue,\n 'maxValue': field.maxValue\n };\n }\n });\n /*Perform this function for the event onBeforeservicecall*/\n try {\n isValid = this.form.invokeEventCallback('beforeservicecall', {$data: dataModel});\n if (isValid === false) {\n return;\n }\n if (isValid && isValid.error) {\n this.form.toggleMessage(true, isValid.error, 'error', 'ERROR');\n return;\n }\n /*Update these values in the formFields with new reference, inorder to maintain the UI values*/\n this.form.formFields.forEach(filterField => {\n if (!filterField['is-range']) {\n filterField._value = dataModel[filterField.field].value;\n } else {\n filterField._minValue = dataModel[filterField.field].minValue;\n filterField._maxValue = dataModel[filterField.field].maxValue;\n }\n });\n } catch (err) {\n if (err.message === 'Abort') {\n return;\n }\n }\n /* Construct the formFields Variable to send it to the queryBuilder */\n this.form.formFields.forEach(filterField => {\n let fieldValue;\n let matchMode;\n let colName = filterField.field;\n const minValue = filterField._minValue;\n const maxvalue = filterField._maxValue;\n /* if field is part of a related entity, column name will be 'entity.fieldName' */\n if (filterField['is-related']) {\n colName += '.' + filterField['lookup-field'];\n }\n if (filterField['is-range']) {\n /*Based on the min and max values, decide the matchmode condition*/\n fieldValue = getRangeFieldValue(minValue, maxvalue);\n matchMode = getRangeMatchMode(minValue, maxvalue);\n if (isDefined(fieldValue)) {\n filterFields[colName] = {\n 'value' : fieldValue,\n 'matchMode' : matchMode,\n 'logicalOp' : 'AND'\n };\n }\n } else {\n switch (filterField.widgettype) {\n case FormWidgetType.SELECT:\n case FormWidgetType.RADIOSET:\n if (getEnableEmptyFilter(this.form.enableemptyfilter) && filterField._value === FILTER_CONSTANTS.EMPTY_KEY) {\n matchMode = getEmptyMatchMode(this.form.enableemptyfilter);\n fieldValue = filterField._value;\n } else {\n if (filterField.type === DataType.BOOLEAN) {\n if (isDefined(filterField._value) && filterField._value !== '') {\n fieldValue = JSON.parse(filterField._value);\n }\n } else {\n fieldValue = filterField._value;\n }\n }\n break;\n case FormWidgetType.CHECKBOXSET:\n case FormWidgetType.CHIPS:\n if (filterField._value && filterField._value.length) {\n fieldValue = filterField._value;\n }\n break;\n case FormWidgetType.CHECKBOX:\n case FormWidgetType.TOGGLE:\n if (isDefined(filterField._value) && filterField._value !== '') {\n fieldValue = filterField.type === DataType.BOOLEAN ? JSON.parse(filterField._value) : filterField._value;\n }\n break;\n default:\n fieldValue = filterField._value;\n break;\n }\n if (isDefined(fieldValue) && fieldValue !== '' && fieldValue !== null) {\n filterFields[colName] = {};\n if (matchMode) {\n filterFields[colName].matchMode = matchMode;\n fieldValue = undefined;\n } else if (filterField.type === DataType.STRING || filterField.isRelated) { // Only for string types and related fields, custom match modes are enabled.\n filterFields[colName].matchMode = matchMode || filterField.matchmode ||\n this.form.datasource.execute(DataSource.Operation.GET_MATCH_MODE);\n }\n filterFields[colName].value = fieldValue;\n filterFields[colName].logicalOp = 'AND';\n filterFields[colName].type = filterField.type;\n }\n }\n });\n\n if (options.exportType) {\n return this.form.datasource.execute(DataSource.Operation.DOWNLOAD, {\n data: {\n matchMode : 'anywhereignorecase',\n filterFields : filterFields,\n orderBy : orderBy,\n exportType : options.exportType,\n logicalOp : 'AND',\n exportSize : options.exportSize,\n fields : options.fields,\n fileName: options.fileName\n }\n });\n }\n return this.form.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n filterFields : filterFields,\n orderBy : orderBy,\n page : page,\n pagesize : this.form.pagesize || 20,\n skipDataSetUpdate : true, // dont update the actual variable dataset,\n inFlightBehavior : 'executeAll'\n }).then(response => {\n const data = response.data;\n this.form.pagination = response.pagination;\n\n if (data.error) {\n // disable readonly and show the appropriate error\n this.form.toggleMessage(true, data.error, 'error', 'ERROR');\n this.form.onResultCb(data, false);\n } else {\n this._options = {\n 'page': page,\n 'orderBy': orderBy\n };\n this.form.result = getClonedObject(data);\n this.form.onResultCb(data, true);\n }\n $appDigest();\n return this.form.result;\n }, error => {\n this.form.toggleMessage(true, error, 'error', 'ERROR');\n this.form.onResultCb(error, false);\n return error;\n });\n }\n\n // Calls the filter function if default values are present\n filterOnDefault() {\n /*Check if default value is present for any filter field*/\n const defaultObj = find(this.form.formFields, obj => {\n return isDefined(obj.value) || isDefined(obj.minValue) || isDefined(obj.maxValue);\n });\n /*If default value exists and data is loaded, apply the filter*/\n if (defaultObj) {\n this._filter(this._options);\n }\n }\n\n registerFormWidget(widget) {\n const name = widget.key || widget.name;\n this.form.filterWidgets[name] = widget;\n }\n}\n","import { Directive, Inject, Optional, Self, Attribute, HostListener } from '@angular/core';\n\nimport { $appDigest, AbstractDialogService, DataSource, DataType, debounce, getClonedObject, getFiles, getValidDateObject, isDateTimeType, isDefined, isEmptyObject } from '@wm/core';\nimport { ALLFIELDS, applyFilterOnField, fetchRelatedFieldData, getDistinctValuesForField, isDataSetWidget, Live_Operations, parseValueByType, performDataOperation, ToDatePipe } from '@wm/components/base';\nimport { LiveTableComponent } from '@wm/components/data/live-table';\n\nimport { registerLiveFormProps } from '../form.props';\nimport { FormComponent } from '../form.component';\nimport {forEach, fromPairs, get, isEmpty, isEqual, isString, map, some, split} from \"lodash-es\";\n\nconst isTimeType = field => field.widgettype === DataType.TIME || (field.type === DataType.TIME && !field.widgettype);\nconst getValidTime = val => {\n if (val) {\n const date = (new Date()).toDateString();\n return (new Date(`${date} ${val}`)).getTime();\n }\n return undefined;\n};\n\n@Directive({\n selector: '[wmLiveForm]'\n})\nexport class LiveFormDirective {\n static initializeProps = registerLiveFormProps();\n private _triggeredByUser: boolean;\n private _debouncedSavePrevDataValues = debounce(() => {\n this.savePrevDataValues();\n }, 250);\n\n @HostListener('keydown', ['$event']) onKeydownHandler(event: KeyboardEvent) {\n this._triggeredByUser = true;\n }\n\n constructor(\n @Self() @Inject(FormComponent) private form,\n @Optional() liveTable: LiveTableComponent,\n public datePipe: ToDatePipe,\n private dialogService: AbstractDialogService,\n @Attribute('formlayout') formlayout: string\n ) {\n // If parent live table is present and this form is first child of live table, set this form instance on livetable\n if (liveTable) {\n if (!this.form.parentForm) {\n this.form._liveTableParent = liveTable;\n }\n this.form.isLayoutDialog = liveTable.isLayoutDialog;\n liveTable.onFormReady(this.form);\n } else {\n this.form.isLayoutDialog = formlayout === 'dialog';\n }\n // CUD operations\n form.cancel = this.cancel.bind(this);\n form.reset = this.reset.bind(this);\n form.delete = this.delete.bind(this);\n form.save = this.save.bind(this);\n form.saveAndNew = this.saveAndNew.bind(this);\n form.saveAndView = this.saveAndView.bind(this);\n\n form.setPrimaryKey = this.setPrimaryKey.bind(this);\n form.constructDataObject = this.constructDataObject.bind(this);\n form.changeDataObject = this.setFormData.bind(this);\n form.setFormData = this.setFormData.bind(this);\n form.findOperationType = this.findOperationType.bind(this);\n form.clearData = this.clearData.bind(this);\n form.onFieldDefaultValueChange = this.onFieldDefaultValueChange.bind(this);\n form.onDataSourceChange = this.onDataSourceChange.bind(this);\n form.onFieldValueChange = this.onFieldValueChange.bind(this);\n form.submitForm = this.submitForm.bind(this);\n form.form_registerFormFields = form.registerFormFields;\n form.registerFormFields = this.registerFormFields.bind(this);\n }\n\n /*\n WMS:18583\n Overriding 'registerFormFields' for liveForms,\n On Each field added, check if the dataSource is updated or not\n if the field is added after the dataSource is updated at LiveForm, retrigger\n */\n registerFormFields(formField) {\n const formFields = this.form.getFormFields();\n this.form.form_registerFormFields(formField);\n if (this.form.isDataSourceUpdated) {\n this._updateFieldOnDataSourceChange(formField, formFields);\n }\n }\n private _updateFieldOnDataSourceChange(field, formFields) {\n if (!field.isDataSetBound && isDataSetWidget(field.widgettype)) {\n if (field['is-related']) {\n field.isDataSetBound = true;\n fetchRelatedFieldData(this.form.datasource, field.widget, {\n relatedField: field.key,\n datafield: ALLFIELDS,\n widget: 'widgettype',\n });\n } else {\n getDistinctValuesForField(this.form.datasource, field.widget, {\n widget: 'widgettype',\n enableemptyfilter: this.form.enableemptyfilter\n });\n applyFilterOnField(this.form.datasource, field.widget, formFields, field.value, {isFirst: true});\n }\n }\n }\n onDataSourceChange() {\n if (get(this.form.formFields, 'length')) {\n this.form.isDataSourceUpdated = true;\n }\n const formFields = this.form.getFormFields();\n formFields.forEach(field => {\n this._updateFieldOnDataSourceChange(field, formFields);\n });\n }\n\n onFieldDefaultValueChange(field, nv) {\n // In Edit, do not set default values\n if (this.form.operationType === 'update') {\n return;\n }\n // Set the default value only if it exists.\n if (isDefined(nv) && nv !== null && nv !== '' && nv !== 'null') {\n field.value = parseValueByType(nv, field.type, field.widgettype, field.trailingzero);\n } else {\n field.value = undefined;\n }\n\n // WMS-22434: For default value set on individual form fields, do not mark the form as dirty.\n if (this.form.dirty && !this._triggeredByUser) {\n this.form.markAsPristine();\n }\n this._debouncedSavePrevDataValues();\n }\n\n onFieldValueChange(field, nv) {\n applyFilterOnField(this.form.datasource, field.widget, this.form.formFields, nv);\n }\n\n getBlobURL(dataObj, key, value) {\n let href = '';\n let primaryKeys;\n let primaryKey;\n if (value === null || value === undefined || !this.form.datasource) {\n return href;\n }\n primaryKeys = this.form.datasource.execute(DataSource.Operation.GET_PRIMARY_KEY) || [];\n primaryKey = dataObj[primaryKeys[0]];\n // TODO: Handle mobile case\n // if (CONSTANTS.hasCordova && CONSTANTS.isRunMode) {\n // href += $rootScope.project.deployedUrl;\n // }\n href += this.form.datasource.execute(DataSource.Operation.GET_BLOB_URL, {\n primaryValue: primaryKey,\n columnName: key\n });\n href += '?' + Math.random();\n return href;\n }\n\n setFormData(dataObj, formFields?) {\n if (!dataObj) {\n return;\n }\n formFields = formFields || this.form.formFields;\n formFields.forEach(field => {\n const value = get(dataObj, field.key || field.name);\n if (isTimeType(field)) {\n field.value = getValidTime(value);\n } else if (field.type === DataType.BLOB) {\n this.form.resetFileUploadWidget(field, true);\n field.href = this.getBlobURL(dataObj, field.key, value);\n field.value = isString(value) ? '' : value;\n } else {\n this.form.setFieldValue(field, dataObj);\n }\n });\n this.savePrevDataValues();\n this.form.constructDataObject();\n }\n\n onDataSourceUpdate(response, newForm, updateMode) {\n if (newForm) {\n this.form.new();\n } else {\n this.form.setFormData(response);\n this.closeDialog();\n }\n this.form.isUpdateMode = isDefined(updateMode) ? updateMode : true;\n }\n\n savePrevformFields() {\n this.form.prevformFields = getClonedObject(this.form.formFields.map(field => {\n return {\n 'key': field.key,\n 'type': field.type,\n 'widgettype': field.widgettype,\n 'outputformat': field.outputformat,\n 'value': field.value\n };\n }));\n }\n\n getPrevformFields() {\n this.form.formFields.map(field => {\n const prevField = this.form.prevformFields.find(pField => pField.key === field.key);\n field.value = prevField.value;\n });\n }\n\n getDataObject() {\n if (this.form.operationType === Live_Operations.INSERT) {\n return {};\n }\n if (isDefined(this.form.prevDataObject) && !isEmptyObject(this.form.prevDataObject)) {\n return getClonedObject(this.form.prevDataObject);\n }\n return getClonedObject(this.form.formdata || {});\n }\n\n constructDataObject(isPreviousData?) {\n const dataObject = this.getDataObject();\n const formName = this.form.name;\n let formFields;\n formFields = isPreviousData ? this.form.prevformFields : this.form.getFormFields();\n formFields.forEach(field => {\n let dateTime,\n fieldValue;\n const fieldTarget = split(field.key, '.');\n const fieldName = fieldTarget[0] || field.key;\n\n /*collect the values from the fields and construct the object*/\n /*Format the output of date time widgets to the given output format*/\n if ((field.widgettype && isDateTimeType(field.widgettype)) || isDateTimeType(field.type)) {\n if (field.value) {\n dateTime = getValidDateObject(field.value);\n if (field.outputformat === DataType.TIMESTAMP || field.type === DataType.TIMESTAMP) {\n fieldValue = field.value ? dateTime : null;\n } else if (field.outputformat) {\n fieldValue = this.datePipe.transform(dateTime, field.outputformat);\n } else {\n fieldValue = field.value;\n }\n } else {\n fieldValue = undefined;\n }\n } else if (field.type === DataType.BLOB) {\n fieldValue = getFiles(formName, fieldName + '_formWidget', field.multiple);\n } else if (field.type === DataType.LIST) {\n fieldValue = field.value || undefined;\n } else {\n fieldValue = (field.value === null || field.value === '') ? undefined : field.value;\n }\n\n if (fieldTarget.length === 1) {\n dataObject[fieldName] = fieldValue;\n } else {\n dataObject[fieldName] = dataObject[fieldName] || {};\n dataObject[fieldName][fieldTarget[1]] = fieldValue;\n }\n });\n if (!isPreviousData) {\n this.form.updateFormDataOutput(dataObject);\n return this.form.dataoutput;\n }\n return dataObject;\n }\n\n setPrimaryKey(fieldName) {\n /*Store the primary key of data*/\n this.form.primaryKey = this.form.primaryKey || [];\n if (this.form.primaryKey.indexOf(fieldName) === -1) {\n this.form.primaryKey.push(fieldName);\n }\n }\n\n findOperationType() {\n let operation;\n let isPrimary = false;\n const sourceOperation = this.form.datasource && this.form.datasource.execute(DataSource.Operation.GET_OPERATION_TYPE);\n if (sourceOperation && sourceOperation !== 'read') {\n return sourceOperation;\n }\n /*If OperationType is not set then based on the formdata object return the operation type,\n this case occurs only if the form is outside a livegrid*/\n /*If the formdata object has primary key value then return update else insert*/\n if (this.form.primaryKey && !isEmpty(this.form.formdata)) {\n /*If only one column is primary key*/\n if (this.form.primaryKey.length === 1) {\n if (this.form.formdata[this.form.primaryKey[0]]) {\n operation = Live_Operations.UPDATE;\n }\n /*If only no column is primary key*/\n } else if (this.form.primaryKey.length === 0) {\n forEach(this.form.formdata, (value) => {\n if (value) {\n isPrimary = true;\n }\n });\n if (isPrimary) {\n operation = Live_Operations.UPDATE;\n }\n /*If multiple columns are primary key*/\n } else {\n isPrimary = some(this.form.primaryKey, (primaryKey) => {\n if (this.form.formdata[primaryKey]) {\n return true;\n }\n });\n if (isPrimary) {\n operation = Live_Operations.UPDATE;\n }\n }\n }\n return operation || Live_Operations.INSERT;\n }\n\n getPrevDataValues() {\n const prevDataValues = fromPairs(map(this.form.prevDataValues, (item) => {\n return [item.key, item.value];\n })); // Convert of array of values to an object\n this.form.formFields.forEach(field => {\n field.value = prevDataValues[field.key] || '';\n field.resetDisplayInput();\n });\n return prevDataValues;\n }\n\n savePrevDataValues() {\n this.form.prevDataValues = this.form.formFields.map((obj) => {\n return {'key': obj.key, 'value': obj.value};\n });\n }\n\n clearData() {\n this.form.toggleMessage(false);\n this.form.emptyDataModel();\n }\n\n setReadonlyFields() {\n this.form.formFields.forEach(field => {\n field.setReadOnlyState();\n });\n }\n\n reset() {\n let prevDataValues;\n this.form.resetFormState();\n prevDataValues = this.getPrevDataValues();\n this.form.formFields.forEach(field => {\n if (field.type === DataType.BLOB || field.widgettype === 'upload') {\n this.form.resetFileUploadWidget(field, true);\n field.href = this.getBlobURL(prevDataValues, field.key, field.value);\n }\n field.nativeElement.querySelector('input')?.removeAttribute('aria-invalid');\n });\n this.form.constructDataObject();\n }\n\n closeDialog() {\n if (this.form.isLayoutDialog) {\n this.dialogService.close(this.form.dialogId);\n }\n }\n\n cancel() {\n this.form.clearMessage();\n this.form.isUpdateMode = false;\n\n this.form.reset();\n /*Show the previous selected data*/\n if (this.form.isSelected) {\n this.getPrevformFields();\n }\n this.form.isUpdateMode = false;\n if (this.form._liveTableParent) {\n this.form._liveTableParent.onCancel();\n } else {\n /*\n WMS-18759: dialog close is calling twice and dialog onHidden subscription is calling once from the library\n due to this if we have another dialog inside liveform and if we click on cancel of second dialog the library\n subscription is calling for both the dialogs.\n */\n this.closeDialog();\n }\n $appDigest();\n }\n\n\n\n delete(callBackFn) {\n this.form.resetFormState();\n this.form.operationType = Live_Operations.DELETE;\n this.form.prevDataObject = getClonedObject(this.form.formdata || {});\n this.form.save(undefined, undefined, undefined, callBackFn);\n }\n\n // Function use to save the form and open new form after save\n saveAndNew() {\n this.save(undefined, true, true);\n }\n // Function use to save the form and open new form after save\n saveAndView() {\n this.save(undefined, false);\n }\n\n submitForm($event) {\n this.save($event);\n }\n\n save(event?, updateMode?, newForm?) {\n if (!this.form.datasource) {\n return;\n }\n let data, prevData, operationType, isValid;\n const requestData: any = {};\n\n operationType = this.form.operationType = this.form.operationType || this.findOperationType();\n\n // Disable the form submit if form is in invalid state.\n if (this.form.validateFieldsOnSubmit()) {\n return;\n }\n\n data = getClonedObject(this.form.constructDataObject());\n prevData = this.form.prevformFields ? this.form.constructDataObject(true) : data;\n\n try {\n isValid = this.form.invokeEventCallback('beforeservicecall', {$event: event, $operation: this.form.operationType, $data: data, options: requestData});\n if (isValid === false) {\n return;\n }\n if (isValid && isValid.error) {\n this.form.toggleMessage(true, isValid.error, 'error');\n return;\n }\n } catch (err) {\n if (err.message === 'Abort') {\n return;\n }\n }\n\n // If operation is update, form is not touched and current data and previous data is same, Show no changes detected message\n if (this.form.operationType === Live_Operations.UPDATE && this.form.ngform && this.form.ngform.pristine &&\n (this.form.isSelected && isEqual(data, prevData))) {\n this.form.toggleMessage(true, this.form.appLocale.MESSAGE_NO_CHANGES, 'info', '');\n $appDigest();\n return;\n }\n\n requestData.row = data;\n requestData.transform = true;\n requestData.skipNotification = true;\n\n if (operationType === Live_Operations.UPDATE) {\n requestData.rowData = this.form.formdata;\n requestData.prevData = prevData;\n }\n\n performDataOperation(this.form.datasource, requestData, {\n operationType: operationType\n }).then((response) => {\n const msg = operationType === Live_Operations.INSERT ? this.form.insertmessage : (operationType === Live_Operations.UPDATE ?\n this.form.updatemessage : this.form.deletemessage);\n let result;\n\n if (operationType === Live_Operations.DELETE) {\n result = requestData.row;\n this.form.emptyDataModel();\n this.form.prevDataValues = [];\n this.form.isSelected = false;\n } else {\n result = response;\n }\n if (!this.form.onSuccess) {\n this.form.toggleMessage(true, msg, 'success');\n }\n if (this.form._liveTableParent) {\n // highlight the current updated row\n this.form._liveTableParent.onResult(operationType, response, newForm, updateMode);\n } else {\n /*get updated data without refreshing page*/\n this.form.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true\n });\n this.onDataSourceUpdate(response, newForm, updateMode);\n }\n return {\n 'result': result,\n 'status': true\n };\n }, (error) => {\n if (!this.form.onError) {\n this.form.toggleMessage(true, error, 'error');\n }\n $appDigest();\n return {\n 'result': error,\n 'status': false\n };\n }).then(response => {\n // reset the form to pristine state\n this.form.resetFormState();\n this.form.onResultCb(response.result, response.status, event);\n });\n\n\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { WmComponentsModule } from '@wm/components/base';\nimport { BasicModule } from '@wm/components/basic';\nimport { InputModule } from '@wm/components/input';\nimport { DesignDialogModule } from '@wm/components/dialogs/design-dialog';\n\nimport { FormComponent } from './form.component';\nimport { FormWidgetDirective } from './form-widget.directive';\nimport { FormActionDirective } from './form-action/form-action.directive';\nimport { FormFieldDirective } from './form-field/form-field.directive';\nimport { LiveActionsDirective } from './live-actions/live-actions.directive';\nimport { DependsonDirective } from './live-actions/dependson.directive';\nimport { LiveFilterDirective } from './live-filter/live-filter.directive';\nimport { LiveFormDirective } from './live-form/live-form.directive';\n\nconst components = [\n FormComponent,\n FormWidgetDirective,\n FormActionDirective,\n FormFieldDirective,\n LiveActionsDirective,\n DependsonDirective,\n LiveFilterDirective,\n LiveFormDirective\n];\n\n@NgModule({\n imports: [\n BasicModule,\n CommonModule,\n DesignDialogModule,\n InputModule,\n WmComponentsModule\n ],\n declarations: [...components],\n exports: [...components]\n})\nexport class FormModule {\n}\n","/**\n * Generated bundle index. Do not edit.\n */\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AClB,WAAW;YACX,kBAAkB,CAAA,EAAA,CAAA,CAAA,EAAA;;iFAKb,UAAU,EAAA,CAAA;cAXtB,QAAQ;AAAC,QAAA,IAAA,EAAA,CAAA;AACN,gBAAA,OAAO,EAAE;oBACL,WAAW;oBACX,YAAY;oBACZ,kBAAkB;oBAClB,WAAW;oBACX,kBAAkB;AACrB,iBAAA;AACD,gBAAA,YAAY,EAAE,CAAC,GAAG,UAAU,CAAC;AAC7B,gBAAA,OAAO,EAAE,CAAC,GAAG,UAAU,CAAC;AAC3B,aAAA,CAAA;;AACY,CAAA,YAAA,EAAA,CAAA,OAAA,SAAA,KAAA,WAAA,IAAA,SAAA,KAAA,EAAA,CAAA,kBAAA,CAAA,UAAU,mBArBnB,aAAa;QACb,mBAAmB;QACnB,mBAAmB;QACnB,kBAAkB;QAClB,oBAAoB;QACpB,kBAAkB;QAClB,mBAAmB;AACnB,QAAA,iBAAiB,aAKb,WAAW;QACX,YAAY;QACZ,kBAAkB;QAClB,WAAW;AACX,QAAA,kBAAkB,aAhBtB,aAAa;QACb,mBAAmB;QACnB,mBAAmB;QACnB,kBAAkB;QAClB,oBAAoB;QACpB,kBAAkB;QAClB,mBAAmB;QACnB,iBAAiB,CAAA,EAAA,CAAA,CAAA,EAAA,GAAA;;ACzBrB;;AAEG;;;;"}
|
1
|
+
{"version":3,"file":"index.mjs","sources":["../../../../../projects/components/widgets/data/form/src/form.props.ts","../../../../../projects/components/widgets/data/form/src/form.component.html","../../../../../projects/components/widgets/data/form/src/form.component.ts","../../../../../projects/components/widgets/data/form/src/form-widget.directive.ts","../../../../../projects/components/widgets/data/form/src/form-action/form-action.props.ts","../../../../../projects/components/widgets/data/form/src/form-action/form-action.directive.ts","../../../../../projects/components/widgets/data/form/src/form-field/form-field.props.ts","../../../../../projects/components/widgets/data/form/src/form-field/form-field.directive.ts","../../../../../projects/components/widgets/data/form/src/live-actions/live-actions.directive.ts","../../../../../projects/components/widgets/data/form/src/live-actions/dependson.directive.ts","../../../../../projects/components/widgets/data/form/src/live-filter/live-filter.directive.ts","../../../../../projects/components/widgets/data/form/src/live-form/live-form.directive.ts","../../../../../projects/components/widgets/data/form/src/form.module.ts","../../../../../projects/components/widgets/data/form/src/index.ts"],"sourcesContent":["import { isMobileApp } from '@wm/core';\n\nimport { PROP_ANY, PROP_BOOLEAN, PROP_NUMBER, PROP_STRING, register } from '@wm/components/base';\n\nconst propsMap = new Map(\n [\n ['autocomplete', {value: false, ...PROP_BOOLEAN}],\n ['captionalign', {value: 'left', ...PROP_STRING}],\n ['captionposition', {value: 'left', ...PROP_STRING}],\n ['captionsize', PROP_STRING],\n ['captionwidth', {value: 'xs-12 sm-3 md-3 lg-3', ...PROP_STRING}],\n ['class', PROP_STRING],\n ['collapsible', PROP_BOOLEAN],\n ['dataset', PROP_ANY],\n ['datasource', PROP_STRING],\n ['expanded', {value: true, ...PROP_BOOLEAN}],\n ['formdatasource', PROP_STRING],\n ['name', PROP_STRING],\n ['numberOfFields', PROP_NUMBER],\n ['show', {value: true, ...PROP_BOOLEAN}],\n ['showindevice', {displayType: 'inline-block', value: 'all', ...PROP_STRING}],\n ['subheading', PROP_STRING],\n ['tabindex', {value: 0, ...PROP_NUMBER}],\n ['title', PROP_STRING]\n ]\n);\n\n\nexport const registerFormProps = () => {\n if (isMobileApp()) {\n propsMap.set('captionwidth', {value: 'xs-4 sm-4 md-4 lg-4', ...PROP_STRING});\n }\n const formMap = new Map(propsMap);\n formMap.set('action', PROP_STRING);\n formMap.set('defaultmode', {value: 'Edit', ...PROP_STRING});\n formMap.set('metadata', PROP_STRING);\n formMap.set('method', PROP_STRING);\n formMap.set('postmessage', {value: 'Data posted successfully', ...PROP_STRING});\n formMap.set('target', PROP_STRING);\n formMap.set('enctype', PROP_STRING);\n formMap.set('errormessage', {value: 'An error occured. Please try again!', ...PROP_STRING});\n formMap.set('messagelayout', {value: 'Inline', ...PROP_STRING});\n formMap.set('formdata', PROP_STRING);\n formMap.set('novalidate', PROP_BOOLEAN);\n formMap.set('validationtype', {value: 'default', ...PROP_STRING});\n formMap.set('iconclass', PROP_STRING);\n\n register(\n 'wm-form',\n formMap\n );\n};\n\nexport const registerLiveFormProps = () => {\n if (isMobileApp()) {\n propsMap.set('captionwidth', {value: 'xs-4 sm-4 md-4 lg-4', ...PROP_STRING});\n }\n const liveFormMap = new Map(propsMap);\n liveFormMap.set('defaultmode', {value: 'View', ...PROP_STRING});\n liveFormMap.set('formlayout', {value: 'inline', ...PROP_STRING});\n liveFormMap.set('insertmessage', {value: 'Record added successfully', ...PROP_STRING});\n liveFormMap.set('updatemessage', {value: 'Record updated successfully', ...PROP_STRING});\n liveFormMap.set('deletemessage', {value: 'Record deleted successfully', ...PROP_STRING});\n liveFormMap.set('errormessage', {value: 'An error occured. Please try again!', ...PROP_STRING});\n liveFormMap.set('messagelayout', {value: 'Toaster', ...PROP_STRING});\n liveFormMap.set('formdata', PROP_STRING);\n liveFormMap.set('novalidate', PROP_BOOLEAN);\n liveFormMap.set('validationtype', {value: 'default', ...PROP_STRING});\n liveFormMap.set('iconclass', PROP_STRING);\n\n register(\n 'wm-liveform',\n liveFormMap\n );\n};\n\nexport const registerLiveFilterProps = () => {\n if (isMobileApp()) {\n propsMap.set('captionwidth', {value: 'xs-4 sm-4 md-4 lg-4', ...PROP_STRING});\n }\n const liveFilterMap = new Map(propsMap);\n liveFilterMap.set('autoupdate', PROP_BOOLEAN);\n liveFilterMap.set('enableemptyfilter', {value: ' ', ...PROP_STRING});\n liveFilterMap.set('pagesize', {value: 20, ...PROP_NUMBER});\n liveFilterMap.set('iconclass', {value: 'wi wi-filter-list', ...PROP_STRING});\n\n register(\n 'wm-livefilter',\n liveFilterMap\n );\n};\n","<ng-template #content><ng-content></ng-content></ng-template>\n\n<ng-container *ngIf=\"formlayout === 'page'; then pageLayoutTemplate else defaultTemplate\">\n</ng-container>\n\n<ng-template #defaultTemplate>\n <div class=\"panel-heading\" *ngIf=\"!isLayoutDialog && (title || subheading || iconclass || showButtons('header'))\">\n <h3 class=\"panel-title\">\n <div class=\"pull-left\">\n <i class=\"app-icon panel-icon\" aria-hidden=\"true\" [ngClass]=\"iconclass\" *ngIf=\"iconclass\"></i>\n </div>\n <div class=\"pull-left\">\n <div class=\"heading\" [innerHTML]=\"title\"></div>\n <div class=\"description\" [innerHTML]=\"subheading\"></div>\n </div>\n <div class=\"form-action panel-actions basic-btn-grp\">\n <ng-container *ngFor=\"let btn of buttonArray | filter : 'position' : 'header'; let index = index\"\n [ngTemplateOutlet]=\"btn.widgetType === 'button' ? buttonRef : anchorRef\"\n [ngTemplateOutletContext]=\"{btn:btn}\"\n [ngTemplateOutletInjector]=\"createCustomInjector('action_header_' + index, {btn:btn})\">\n </ng-container>\n <button type=\"button\" class=\"app-icon wi panel-action\" *ngIf=\"collapsible\" title=\"Collapse/Expand\"\n [ngClass]=\"expanded ? 'wi-minus': 'wi-plus'\" (click)=\"expandCollapsePanel();\"></button>\n </div>\n </h3>\n </div>\n <div class=\"panel-body\" [ngClass]=\"{'form-elements': isLayoutDialog, 'form-body': !isLayoutDialog}\" [class.hidden]=\"!expanded\">\n <p wmMessage *ngIf=\"!!statusMessage.caption\" [attr.aria-hidden]=\"!statusMessage.caption\" [attr.aria-label]=\"statusMessage.caption\" caption.bind=\"statusMessage.caption\" type.bind=\"statusMessage.type\"></p>\n <div [ngClass]=\"{'form-elements': !isLayoutDialog, 'form-content': isLayoutDialog}\">\n <ng-container *ngTemplateOutlet=\"content\"></ng-container>\n </div>\n <div class=\"basic-btn-grp form-action panel-footer clearfix\" [ngClass]=\"{'modal-footer': isLayoutDialog}\" [class.hidden]=\"!expanded || !showButtons('footer')\">\n <ng-container *ngFor=\"let btn of buttonArray | filter : 'position' : 'footer'; let index = index\"\n [ngTemplateOutlet]=\"btn.widgetType === 'button' ? buttonRef : anchorRef\"\n [ngTemplateOutletContext]=\"{btn:btn}\"\n [ngTemplateOutletInjector]=\"createCustomInjector('action_footer_' + index, {btn:btn})\">\n </ng-container>\n </div>\n </div>\n</ng-template>\n\n<ng-template #pageLayoutTemplate>\n <ng-container *ngTemplateOutlet=\"content\"></ng-container>\n</ng-template>\n\n<ng-template #buttonRef let-btn=\"btn\">\n <button wmButton name=\"{{btn.key}}\" caption.bind=\"btn.displayName\" class.bind=\"btn.class\" iconclass.bind=\"btn.iconclass\" show.bind=\"btn.show\"\n (click)=\"invokeActionEvent($event, btn.action)\" type.bind=\"btn.type\" hint.bind=\"btn.title\" shortcutkey.bind=\"btn.shortcutkey\" disabled.bind=\"ngform.status === 'PENDING' || btn.disabled\"\n tabindex.bind=\"btn.tabindex\" [attr.aria-label]=\"btn.displayName\" [class.hidden]=\"btn.updateMode ? !isUpdateMode : isUpdateMode\"></button>\n</ng-template>\n\n<ng-template #anchorRef let-btn=\"btn\">\n <a wmAnchor name=\"{{btn.key}}\" caption.bind=\"btn.displayName\" class.bind=\"btn.class\" iconclass.bind=\"btn.iconclass\" show.bind=\"btn.show\"\n (click)=\"invokeActionEvent($event, btn.action)\" hint.bind=\"btn.title\" shortcutkey.bind=\"btn.shortcutkey\"\n hyperlink.bind=\"btn.hyperlink\" target.bind=\"btn.target\"\n tabindex.bind=\"btn.tabindex\" [class.hidden]=\"btn.updateMode ? !isUpdateMode : isUpdateMode\"></a>\n</ng-template>\n\n<ng-container #dynamicForm></ng-container>\n","import {\n AfterContentInit,\n AfterViewInit,\n Attribute,\n Component,\n ContentChildren,\n HostBinding,\n HostListener, Inject,\n Injector,\n NgZone,\n OnDestroy,\n Optional,\n SkipSelf,\n ViewChild,\n ViewContainerRef\n} from '@angular/core';\nimport {FormArray, FormBuilder, FormGroup} from '@angular/forms';\n\nimport {\n $appDigest,\n $invokeWatchers,\n $parseEvent,\n AbstractDialogService,\n App,\n DataSource,\n DataType,\n debounce,\n DynamicComponentRefProvider,\n extendProto,\n getClonedObject,\n getFiles,\n getValidJSON,\n isDefined,\n isElementInViewport,\n removeAttr,\n removeClass,\n scrollToElement,\n} from '@wm/core';\nimport {\n getFieldLayoutConfig,\n Live_Operations,\n MessageComponent,\n parseValueByType,\n PartialDirective,\n performDataOperation,\n provideAsWidgetRef,\n StylableComponent,\n styler,\n WidgetRef\n} from '@wm/components/base';\nimport {PrefabDirective} from '@wm/components/prefab';\nimport {ListComponent} from '@wm/components/data/list';\n\nimport {registerFormProps} from './form.props';\nimport {\n debounce as _debounce,\n filter,\n find, findIndex,\n forEach,\n get,\n includes,\n isArray,\n isEmpty, isEqual,\n isUndefined,\n keys,\n last,\n set,\n some,\n split\n} from \"lodash-es\";\n\nconst WIDGET_CONFIG = {widgetType: 'wm-form', hostClass: 'panel app-panel app-form'};\nconst LOGIN_FORM_CONFIG = {widgetType: 'wm-form', hostClass: 'app-form app-login-form'};\nconst LIVE_FORM_CONFIG = {widgetType: 'wm-liveform', hostClass: 'panel app-panel app-liveform liveform-inline'};\nconst LIVE_FILTER_CONFIG = {widgetType: 'wm-livefilter', hostClass: 'panel app-panel app-livefilter clearfix liveform-inline'};\n\nconst getWidgetConfig = (isLiveForm, isLiveFilter, role) => {\n let config = WIDGET_CONFIG;\n if (isLiveForm !== null) {\n config = LIVE_FORM_CONFIG;\n } else if (isLiveFilter !== null) {\n config = LIVE_FILTER_CONFIG;\n } else if (role === 'app-login') {\n config = LOGIN_FORM_CONFIG;\n }\n return config;\n};\n\n// Generate the form field with given field definition. Add a grid column wrapper around the form field.\nconst setMarkupForFormField = (field, columnWidth) => {\n let propsTmpl = '';\n forEach(field, (value, key) => {\n propsTmpl = `${propsTmpl} ${key}=\"${value}\"`;\n });\n return `<wm-gridcolumn columnwidth=\"${columnWidth}\">\n <wm-form-field ${propsTmpl}></wm-form-field>\n </wm-gridcolumn>`;\n};\n\n// Function to find out the first invalid element in form\nconst findInvalidElement = ($formEle, ngForm) => {\n const $ele = $formEle.find('form.ng-invalid:visible, [formControlName].ng-invalid:visible').first();\n let formObj = ngForm;\n // If element is form, find out the first invalid element in this form\n if ($ele.is('form')) {\n formObj = ngForm && ngForm.controls[$ele.attr('formControlName') || $ele.attr('name')];\n if (formObj) {\n return findInvalidElement($ele, formObj);\n }\n }\n return {\n ngForm: formObj,\n $ele: $ele\n };\n};\n\n// Function to get the active element markup based on widget type\nconst getActiveElement = (element) => {\n const widgetType = element.getAttribute('widgettype');\n switch (widgetType) {\n case 'select':\n return element.querySelector('select');\n break;\n case 'textarea':\n return element.querySelector('textarea');\n break;\n default:\n return element.querySelector('input');\n }\n}\nconst setTouchedState = (self, ngForm, fieldName) => {\n if (ngForm.valid) {\n return;\n }\n if (ngForm.controls) {\n forEach(ngForm.controls, (ctrl, fieldName) => {\n setTouchedState(self, ctrl, fieldName);\n });\n } else {\n let element = self.$element.find(`[wmformfield][key=\"${fieldName}\"]`);\n if (!element.length) {\n element = self.$element.find(`[wmformfield][name=\"${fieldName}\"]`);\n }\n element[0].setAttribute('__errormsg', element[0].getAttribute('__validationId'));\n let activeElement = getActiveElement(element[0]);\n activeElement?.setAttribute('aria-invalid', ngForm.invalid);\n activeElement?.setAttribute('aria-describedby', element[0].getAttribute('__validationId'));\n ngForm.markAsTouched();\n }\n};\n\n@Component({\n selector: 'form[wmForm]',\n templateUrl: './form.component.html',\n providers: [\n provideAsWidgetRef(FormComponent)\n ]\n})\nexport class FormComponent extends StylableComponent implements OnDestroy, AfterContentInit, AfterViewInit {\n static initializeProps = registerFormProps();\n @ViewChild('dynamicForm', { static: true, read: ViewContainerRef }) dynamicFormRef: ViewContainerRef;\n @ViewChild(MessageComponent) messageRef;\n // this is the reference to the component refs inside the form-group\n @ContentChildren(WidgetRef, {descendants: true}) componentRefs;\n\n autoupdate;\n public formlayout: any;\n public isDataSourceUpdated: boolean;\n captionAlignClass: string;\n validationtype: string;\n captionalign: string;\n captionposition: string;\n captionsize;\n collapsible: boolean;\n expanded: boolean;\n elScope;\n _widgetClass = '';\n captionwidth: string;\n _captionClass = '';\n ngform: FormGroup;\n formFields = [];\n formfields = {};\n formWidgets = {};\n filterWidgets = {};\n buttonArray = [];\n dataoutput = {};\n datasource;\n formdatasource;\n formdata = {};\n isSelected;\n prevDataValues;\n prevDataObject;\n prevformFields;\n statusMessage = {\n caption: '',\n type: ''\n };\n messagelayout;\n metadata;\n errormessage;\n onError;\n onSuccess;\n primaryKey = [];\n postmessage;\n _liveTableParent;\n updateMode;\n name;\n // Live Form Methods\n clearData: Function;\n cancel: Function;\n delete: Function;\n save: Function;\n saveAndNew: Function;\n saveAndView: Function;\n setPrimaryKey: () => {};\n dialogId: string;\n // Live Filter\n enableemptyfilter;\n pagesize;\n result;\n pagination;\n clearFilter: Function;\n applyFilter: Function;\n filter: Function;\n filterOnDefault: Function;\n onMaxDefaultValueChange: Function;\n numberOfFields: number;\n\n private _debouncedUpdateFieldSource: Function = _debounce(this.updateFieldSource, 350);\n private operationType;\n private _isLayoutDialog;\n private _dynamicContext;\n private _isGridLayoutPresent;\n private validationMessages = [];\n private formGroupName;\n private formArrayIndex;\n private bindingValue;\n private _formIsInList;\n private _triggeredByUser: boolean;\n\n\n private _debouncedSubmitForm = debounce(($event) => {\n // calling submit event in ngZone as change detection is not triggered post the submit callback and actions like notification are not shown\n this.ngZone.run(() => {\n this.submitForm($event);\n });\n }, 250);\n\n set isLayoutDialog(nv) {\n if (nv) {\n removeClass(this.nativeElement, 'panel app-panel liveform-inline');\n }\n this._isLayoutDialog = nv;\n }\n\n get isLayoutDialog() {\n return this._isLayoutDialog;\n }\n\n private _isUpdateMode;\n set isUpdateMode(nv) {\n this._isUpdateMode = nv;\n this.formFields.forEach(field => {\n field.setReadOnlyState(nv);\n });\n }\n\n get isUpdateMode() {\n return this._isUpdateMode;\n }\n\n @HostBinding('action') action: string;\n\n @HostListener('submit', ['$event']) submit($event) {\n this._debouncedSubmitForm($event);\n }\n\n @HostListener('reset') onReset() {\n this.reset();\n }\n\n @HostListener('keydown', ['$event']) onKeydownHandler(event: KeyboardEvent) {\n this._triggeredByUser = true;\n }\n // returns the formArray control on the parentForm.\n get parentFormArray(): FormArray {\n return this.parentForm && this.isParentList && this.parentForm.ngform.get(this.parentList.name) as FormArray;\n }\n\n // returns true only when closest livelist is the immediate parent of the form.\n // checks for livelist having any form elements with parentForm name.\n // If livelist is not containing any parentForm elements then it returns true.\n get isParentList() {\n if (this.parentList && this.parentForm && !isDefined(this._formIsInList)) {\n const formEle = this.$element;\n const listEle = formEle.closest('.app-livelist[name=\"' + this.parentList.name + '\"]');\n if (listEle.length) {\n this._formIsInList = !(listEle.find('form[widget-id=\"' + this.parentForm.widgetId + '\"]')).length;\n }\n }\n return isDefined(this._formIsInList) ? this._formIsInList : this.parentList;\n }\n\n constructor(\n inj: Injector,\n private fb: FormBuilder,\n private app: App,\n private dialogService: AbstractDialogService,\n private dynamicComponentProvider: DynamicComponentRefProvider,\n private ngZone: NgZone,\n @Optional() public parentList: ListComponent,\n @SkipSelf() @Optional() public parentForm: FormComponent,\n @SkipSelf() @Optional() public parentPrefab: PrefabDirective,\n @SkipSelf() @Optional() public parentPartial: PartialDirective,\n @Attribute('beforesubmit.event') public onBeforeSubmitEvt,\n @Attribute('submit.event') public onSubmitEvt,\n @Attribute('beforerender.event') public onBeforeRenderEvt,\n @Attribute('dataset.bind') public binddataset,\n @Attribute('formdata.bind') private bindformdata,\n @Attribute('wmLiveForm') isLiveForm,\n @Attribute('wmLiveFilter') isLiveFilter,\n @Attribute('data-role') role,\n @Attribute('key') key,\n @Attribute('name') name,\n @Inject('EXPLICIT_CONTEXT') @Optional() explicitContext: any\n ) {\n super(inj, getWidgetConfig(isLiveForm, isLiveFilter, role), explicitContext);\n\n styler(this.nativeElement, this);\n\n // remove title property as attribute as it is causing unnecessary tooltip\n removeAttr(this.nativeElement, 'title');\n this.isUpdateMode = true;\n this.dialogId = this.nativeElement.getAttribute('dialogId');\n this.ngform = fb.group({});\n this.bindingValue = key || name;\n\n // On value change in form, update the dataoutput\n const onValueChangeSubscription = this.ngform.valueChanges\n .subscribe(this.updateDataOutput.bind(this));\n this.registerDestroyListener(() => onValueChangeSubscription.unsubscribe());\n this.elScope = this;\n\n this.addEventsToContext(this.context);\n }\n\n ngAfterContentInit() {\n setTimeout(() => {\n this.componentRefs.forEach(componentRef => {\n if (componentRef.name) {\n // Register widgets inside form with formWidgets\n this.formWidgets[componentRef.name] = componentRef;\n }\n });\n }, 250);\n }\n\n ngAfterViewInit() {\n if (this.parentForm && this.parentForm.ngform && this.isParentList) {\n // setting formArray control on ngform.\n if (!get(this.parentForm.ngform.controls, this.parentList.name)) {\n this.parentForm.ngform.setControl(this.parentList.name, new FormArray([]));\n }\n // pushing the ngform to formArray.\n this.parentFormArray.push(this.ngform);\n this.formArrayIndex = this.parentFormArray.length - 1;\n }\n this.addInnerNgFormToForm(this.bindingValue);\n }\n\n findOperationType() {}\n\n private addInnerNgFormToForm(binding) {\n if (this.parentForm && this.parentForm.ngform) {\n // handling as formArray when parent is list. Hence returning here from adding to parentForm again.\n if (this.isParentList) {\n return;\n }\n // assigning the control name of the form inside the prefab with the prefab name.\n // This will happen only when there is only one form inside prefab.\n // We do not support changing this when multiple forms are inside prefab.\n // This scenario has to be handled by end user by changing form names in prefab according to the datamodel binding.\n const parentContainer = this.parentPrefab || this.parentPartial;\n if (parentContainer) {\n let parentContentEl;\n if (this.parentPrefab) {\n parentContentEl = parentContainer.$element.find('[wmprefabcontainer]');\n } else {\n parentContentEl = parentContainer.$element;\n }\n /**\n * assigning the form name to the parentContainer name i.e. partial name or perfab name by following\n * 1. retrieving all the forms in the parentContainer\n * 2. consider the first form\n * 3. if this form is inside list i.e. also find if this list is also inside the parentContainer (prefab / partial)\n * 4. then do not change the form name when form is inside list and also when there are siblings to the form\n * 5. this means form name change applies only when there is single form (immediate child) inside the parentContainer.\n */\n const prefabInnerForm = parentContentEl.find('form').first();\n if (get(prefabInnerForm[0], 'widget.widgetId') === this.widgetId) {\n // check whether form inside prefab container is inside the list. If true, do not change the name.\n if (!prefabInnerForm.isParentList && !prefabInnerForm.siblings('form').length) {\n binding = get(parentContainer, 'name');\n }\n }\n }\n let counter = 1;\n let innerBinding = binding;\n // Inner forms may have same names. If same name is present, append unqiue identifier\n while (this.parentForm.ngform.controls.hasOwnProperty(innerBinding)) {\n innerBinding = `${binding}_${counter}`;\n counter++;\n }\n this.formGroupName = innerBinding;\n // If parent form is present, add the current form as as formGroup for parent form\n this.parentForm.ngform.addControl(innerBinding, this.ngform);\n }\n }\n\n // Expose the events on context so that they can be accessed by form actions\n private addEventsToContext(context) {\n context.cancel = () => this.cancel();\n context.reset = () => this.reset();\n context.save = evt => this.save(evt);\n context.saveAndNew = () => this.saveAndNew();\n context.saveAndView = () => this.saveAndView();\n context.delete = () => this.delete();\n context.new = () => this.new();\n context.edit = () => this.edit();\n context.highlightInvalidFields = () => this.highlightInvalidFields();\n context.filter = () => this.filter();\n context.clearFilter = () => this.clearFilter();\n context.submit = evt => this.submit(evt);\n }\n\n // This method gets all the inner forms and validates each form.\n private setValidationOnInnerForms(validateTouch) {\n const formEle = this.getNativeElement();\n const formObjs = formEle.querySelectorAll('.app-form');\n const validationMsgs = [];\n forEach(formObjs, e => {\n const formInstance = (e as any).widget;\n // differentiating the validationMessages prefix based on the formGroupName\n // as the formName's are same when forms are in list\n let formName = get(formInstance, 'formGroupName') || formInstance.name;\n if (isDefined(formInstance.formArrayIndex)) {\n formName = formName + '[' + formInstance.formArrayIndex + ']';\n }\n let current = formInstance;\n while (get(current, 'parentForm')) {\n let parentName = current.parentForm.formGroupName || current.parentForm.name;\n if (current.parentForm.parentFormArray) {\n parentName = parentName + '[' + current.parentForm.formArrayIndex + ']';\n }\n formName = parentName + '.' + formName;\n current = current.parentForm;\n }\n this.setValidationOnFields(formInstance, formName, validateTouch);\n });\n }\n\n /**\n * This method sets validation on formFields.\n * Applies to innerform and also sets innerform validation on parent form.\n * @param prefix contains the form name, which also includes its parents form name\n * @param {boolean} validateTouch\n */\n private setValidationOnFields(form: FormComponent, prefix: string, validateTouch?: boolean) {\n const controls = form.ngform.controls;\n const formFields = form.formFields;\n if (!formFields) {\n return;\n }\n forEach(controls, (v, k) => {\n const field = formFields.find(e => e.key === k);\n if (!field || (validateTouch && !v.touched)) {\n return;\n }\n field.nativeElement.querySelector('input')?.setAttribute('aria-invalid', v.invalid);\n // invoking the prepareValidation on both parent form and current form.\n this.prepareValidationObj(v, k, field, prefix);\n this.prepareValidationObj.call(form, v, k, field, prefix);\n });\n }\n\n // Assigns / updates validationMessages based on angular errors on field\n private prepareValidationObj(v, k, field, prefix) {\n const index = this.validationMessages.findIndex(e => (e.field === k && e.fullyQualifiedFormName === prefix));\n if (v.invalid) {\n if (index === -1) {\n /**\n * field contains the fieldName\n * value contains the field value\n * errorType contains the list of errors\n * message contains the validation message\n * getElement returns the element having focus-target\n * formName returns the name of the form\n */\n this.validationMessages.push({\n field: k,\n value: field.value,\n errorType: keys(v.errors),\n message: field.validationmessage || '',\n getElement: () => {\n return field.$element.find('[focus-target]');\n },\n formName: last(prefix.split('.')),\n fullyQualifiedFormName: prefix\n });\n } else {\n this.validationMessages[index].value = field.value;\n this.validationMessages[index].errorType = keys(v.errors);\n }\n } else if (v.valid && index > -1) {\n this.validationMessages.splice(index, 1);\n }\n }\n\n // This will return a object containing the error details from the list of formFields that are invalid\n private setValidationMsgs(validateTouch?: boolean) {\n if (!this.formFields.length && isEmpty(this.ngform.controls)) {\n return;\n }\n this.setValidationOnFields(this, this.name, validateTouch);\n this.setValidationOnInnerForms(validateTouch);\n }\n\n // change and blur events are added from the template\n protected handleEvent(node: HTMLElement, eventName: string, callback: Function, locals: any) {\n if (eventName !== 'submit') {\n super.handleEvent(this.nativeElement, eventName, callback, locals);\n }\n }\n\n private updateFieldSource() {\n if (this.formdatasource && this.formdatasource.execute(DataSource.Operation.IS_API_AWARE)) {\n return;\n } else if (this.formdatasource && !this.formdatasource.twoWayBinding) {\n return;\n }\n this.formFields.forEach(formField => {\n formField.setFormWidget('datavaluesource', this.formdatasource);\n formField.setFormWidget('binddatavalue', `${this.bindformdata}.${formField.key}`);\n });\n }\n\n // This method loops through the form fields and highlights the invalid fields by setting state to touched\n highlightInvalidFields() {\n setTouchedState(this, this.ngform, '');\n }\n\n // Disable the form submit if form is in invalid state. Highlight all the invalid fields if validation type is default\n validateFieldsOnSubmit() {\n this.setValidationMsgs();\n // Disable the form submit if form is in invalid state. For delete operation, do not check the validation.\n if (this.operationType !== 'delete' && (this.validationtype === 'html' || this.validationtype === 'default')\n && this.ngform && this.ngform.invalid) {\n\n if (this.ngform.invalid) {\n if (this.validationtype === 'default') {\n this.highlightInvalidFields();\n }\n // Find the first invalid untoched element and set it to touched.\n // Safari does not form validations. this will ensure that error is shown for user\n const eleForm = findInvalidElement(this.$element, this.ngform);\n const $invalidForm = eleForm.ngForm;\n let $invalidEle = eleForm.$ele;\n $invalidEle = $invalidEle.parent().find('[focus-target]');\n if ($invalidEle.length) {\n // on save click in page layout liveform, focus of autocomplete widget opens full-screen search.\n if (!$invalidEle.hasClass('app-search-input')) {\n $invalidEle.focus();\n }\n const ngEle = $invalidForm && $invalidForm.controls[$invalidEle.attr('formControlName') || $invalidEle.attr('name')];\n if (ngEle && ngEle.markAsTouched) {\n ngEle.markAsTouched();\n }\n $appDigest();\n return true;\n }\n return true;\n }\n return false;\n }\n return false;\n }\n\n onPropertyChange(key, nv, ov?) {\n switch (key) {\n case 'captionalign':\n this.captionAlignClass = 'align-' + nv;\n break;\n case 'captionposition':\n this.setLayoutConfig();\n break;\n case 'captionwidth':\n this.setLayoutConfig();\n break;\n case 'captionsize':\n this.captionsize = nv;\n break;\n case 'novalidate':\n // Set validation type based on the novalidate property\n this.widget.validationtype = (nv === true || nv === 'true') ? 'none' : 'default';\n break;\n case 'formdata':\n // For livelist when multiselect is enabled, formdata will be array of objects. In this case consider the last object as formdata.\n if (isEqual(nv, ov)) {\n break;\n }\n isArray(nv) ? this.setFormData(last(nv)) : this.setFormData(nv);\n // if dataset on the formFields are not set as the datasourceChange is triggered before the formFields are registered.\n if (!this.isDataSourceUpdated && this.datasource) {\n this.onDataSourceChange();\n }\n break;\n case 'defaultmode':\n if (!this.isLayoutDialog) {\n if (nv && nv === 'Edit') {\n this.updateMode = true;\n } else {\n this.updateMode = false;\n }\n this.isUpdateMode = this.updateMode;\n }\n break;\n case 'datasource':\n this.onDataSourceChange();\n break;\n case 'formdatasource':\n this.onFormDataSourceChange();\n break;\n case 'metadata':\n this.generateFormFields();\n break;\n case 'dataset':\n const formFields = this.getFormFields();\n formFields.forEach(field => {\n // notifying the dataset change to the form-field widget.\n if (!field.isDataSetBound && get(field.formWidget, 'dataset$')) {\n field.formWidget.dataset$.next();\n }\n });\n break;\n default:\n super.onPropertyChange(key, nv, ov);\n }\n }\n\n // Event callbacks on success/error\n onResultCb(data, status, event?) {\n const params = {$event: event, $data: data, $operation: this.operationType};\n // whether service call success or failure call this method\n this.invokeEventCallback('result', params);\n if (status) {\n // if service call is success call this method\n this.invokeEventCallback('success', params);\n } else {\n // if service call fails call this method\n this.invokeEventCallback('error', params);\n }\n }\n\n // Display or hide the inline message/ toaster\n toggleMessage(show: boolean, msg?: string, type?: string, header?: string) {\n let template;\n if (show && msg) {\n template = (type === 'error' && this.errormessage) ? this.errormessage : msg;\n if (this.messagelayout === 'Inline') {\n template = this.checkAppServiceErrorMsg(type) || template;\n this.statusMessage = {'caption': template || '', type: type};\n if (this.messageRef) {\n this.messageRef.showMessage(this.statusMessage.caption, this.statusMessage.type);\n }\n // when message layout is inline on save, scroll the view to top of the form to see the status of the operation\n if (!isElementInViewport(this.$element[0])) {\n scrollToElement(this.$element[0]);\n }\n } else {\n this.app.notifyApp(template, type, header);\n }\n } else {\n this.statusMessage.caption = '';\n }\n }\n\n // if there is an App.onServiceError handler for the app, that message should be used instead of server returned error message\n checkAppServiceErrorMsg(type) {\n const notificationAction = get(this.app, 'Actions.appNotification');\n if (notificationAction && type === 'error') {\n return notificationAction.getMessage();\n }\n return;\n }\n\n // Hide the inline message/ toaster\n clearMessage() {\n this.toggleMessage(false);\n }\n\n // Set the classes on the form based on the captionposition and captionwidth properties\n private setLayoutConfig() {\n let layoutConfig;\n layoutConfig = getFieldLayoutConfig(this.captionwidth, this.captionposition, get(this.app.selectedViewPort, 'os'));\n this._widgetClass = layoutConfig.widgetCls;\n this._captionClass = layoutConfig.captionCls;\n\n $appDigest();\n }\n\n registerFormWidget(widget) {\n const name = widget.name || widget.key;\n this.formWidgets[name] = widget;\n }\n\n registerFormFields(formField) {\n const fieldCount = this.formFields.push(formField);\n this.formfields[formField.key] = formField;\n this.registerFormWidget(formField);\n this._debouncedUpdateFieldSource();\n if (this.parentForm) {\n this.parentForm.formFields.push(formField);\n this.parentForm.formfields[formField.key] = formField;\n // inner formfields are pushed to parentForm, passing current innerForm's formdata to set innerFormdata to these innerFormFields\n this.parentForm.setFormData(this.parentForm.formdata, this.formFields, this.formdata || {});\n }\n // WMS-18967: Applying formadata after formfields are ready\n if (fieldCount === this.numberOfFields && !isEmpty(this.formdata)) {\n this.onDataSourceChange();\n isArray(this.formdata) ? this.setFormData(last(this.formdata)) : this.setFormData(this.formdata);\n }\n }\n\n registerActions(formAction) {\n this.buttonArray.push(formAction);\n }\n\n // Update the dataoutput whenever there is a change in inside form widget value\n updateFormDataOutput(dataObject) {\n // Set the values of the widgets inside the live form (other than form fields) in form data\n forEach(this.ngform.value, (val, key) => {\n if (!find(this.formFields, {key})) {\n dataObject[key] = val;\n }\n });\n this.dataoutput = dataObject;\n }\n\n // Construct the data object merging the form fields and custom widgets data\n constructDataObject() {\n const formData = {};\n const formFields = this.getFormFields();\n // Get all form fields and prepare form data as key value pairs\n formFields.forEach(field => {\n let fieldName,\n fieldValue;\n fieldValue = field.datavalue || field._control.value;\n fieldValue = (fieldValue === null || fieldValue === '') ? undefined : fieldValue;\n\n if (field.type === 'file') {\n fieldValue = getFiles(this.name, field.key + '_formWidget', field.multiple);\n }\n\n fieldName = field.key || field.target || field.name;\n\n // on current Form, when field is innerForm field then we group these fields under new object using formGroupName as key\n // For suppose, applicantName, applicantID are formfields in currentForm\n // This form is having innerform i.e. address, these fields are listed as\n // {\"applicantName\": \"\", \"applicantID\": \"\", \"address\": {\"street\": \"\"}}\n if (field.form.widgetId !== this.widgetId && field.form.formGroupName) {\n const fd = get(formData, field.form.formGroupName, {});\n fd[fieldName] = fieldValue;\n set(formData, field.form.formGroupName, fd);\n } else if ((typeof field.form.formArrayIndex === 'number') && field.form.isParentList && !this.parentForm) { // Fix for [WMS-25806]: use formArrayIndex only if form has a parent form\n // setting formdata based on formArrayIndex\n const fd = get(formData, field.form.parentList.name, []);\n fd[field.form.formArrayIndex] = fd[field.form.formArrayIndex] || {};\n fd[field.form.formArrayIndex][fieldName] = fieldValue;\n set(formData, field.form.parentList.name, fd);\n } else {\n // In case of update the field will be already present in form data\n set(formData, fieldName, fieldValue);\n }\n });\n this.updateFormDataOutput(formData);\n return this.dataoutput;\n }\n\n updateDataOutput() {\n this.constructDataObject();\n if (this.ngform.touched) {\n this.setValidationMsgs(true);\n }\n }\n\n // FormFields will contain all the fields in parent and inner form also.\n // This returns the formFields in the form based on the form name.\n getFormFields() {\n return filter(this.formFields, formField => {\n return formField.form.name === this.name;\n });\n }\n\n setFieldValue(field, data, innerFormdata?) {\n const key = field.key || field.name;\n // if customfield param value is not in the formdata then do not assign field value\n // as it can contain default value which will again be overridden by undefined.\n const fd = innerFormdata ? innerFormdata : data;\n if (fd) {\n if (fd.hasOwnProperty(key)) {\n field.value = get(fd, key);\n } else if (includes(key, '.')) {\n // key contains '.' when mapping the fields to child reference i.e. childCol is having key as \"parent.childCol\"\n if (fd.hasOwnProperty(split(key, '.')[0])) {\n field.value = get(fd, key);\n }\n }\n // WMS-18906: For default value, do not mark the form as dirty.\n if (this.dirty && !this._triggeredByUser) {\n this.markAsPristine();\n }\n }\n const formGroupName = field.form.formGroupName;\n /**\n * if formGroupName is defined which means field is inside the inner form\n * then set the formdata on the field's form using formGroupName\n */\n if (formGroupName && get(data, formGroupName)) {\n this.setFormData.call(field.form, data[formGroupName]);\n }\n // if formdata is assigned later then on propertyChangeHandler, even inner forms data also needs to be updated.\n if (get(field.form, 'parentFormArray')) {\n this.setFormDataFromParentFormData.call(field.form, data);\n }\n }\n\n setFormData(data, innerFormFields?, innerFormdata?) {\n // whereas formFields explicitly passed can contain innerform fields also.\n const formFields = innerFormFields || this.formFields;\n formFields.forEach(field => {\n this.setFieldValue(field, data, innerFormdata);\n if (field.fieldValidations) {\n field.fieldValidations.setCustomValidationMessage();\n }\n });\n this.constructDataObject();\n }\n\n resetFormState() {\n // clearing the validationMessages on reset.\n if (this.validationMessages.length) {\n this.validationMessages = [];\n }\n if (!this.ngform) {\n return;\n }\n this.ngform.markAsUntouched();\n this.ngform.markAsPristine();\n }\n\n reset() {\n this.resetFormState();\n this.formFields.forEach(field => {\n field.value = '';\n if (field.widgettype === 'upload' || field.type === DataType.BLOB) {\n this.resetFileUploadWidget(field, true);\n }\n field.nativeElement.querySelector('input')?.removeAttribute('aria-invalid');\n });\n this.constructDataObject();\n this.clearMessage();\n }\n\n savePrevformFields() {\n this.prevformFields = getClonedObject(this.formFields.map(field => {\n return {\n 'key': field.key,\n 'type': field.type,\n 'widgettype': field.widgettype,\n 'outputformat': field.outputformat,\n 'value': field.value\n };\n }));\n }\n\n savePrevDataValues() {\n this.prevDataValues = this.formFields.map((obj) => {\n return {'key': obj.key, 'value': obj.value};\n });\n }\n\n setReadonlyFields() {\n this.formFields.forEach(field => {\n field.setReadOnlyState();\n });\n }\n\n resetFileUploadWidget(field, skipValueSet?) {\n const $formEle = this.$element;\n $formEle.find('[name=\"' + field.key + '_formWidget\"]').val('');\n field._control.reset();\n if (!skipValueSet) {\n field.href = '';\n field.value = null;\n }\n }\n\n emptyDataModel() {\n this.formFields.forEach(field => {\n if (isDefined(field)) {\n if (field.type === DataType.BLOB) {\n this.resetFileUploadWidget(field);\n } else {\n field.datavalue = '';\n }\n }\n });\n }\n\n setDefaultValues() {\n this.formFields.forEach(field => {\n this.onFieldDefaultValueChange(field, field.defaultvalue);\n });\n }\n\n setOperationType(mode) {\n this.operationType = mode || 'insert';\n }\n\n new() {\n this.resetFormState();\n this.operationType = Live_Operations.INSERT;\n this.clearMessage();\n if (this.isSelected) {\n this.savePrevformFields();\n }\n this.emptyDataModel();\n setTimeout(() => {\n this.setDefaultValues();\n this.savePrevDataValues();\n this.constructDataObject();\n });\n this.isUpdateMode = true;\n }\n\n edit() {\n this.resetFormState();\n this.clearMessage();\n\n this.operationType = Live_Operations.UPDATE;\n\n if (this.isSelected) {\n this.savePrevformFields();\n this.savePrevDataValues();\n }\n this.prevDataObject = getClonedObject(this.formdata || {});\n\n this.setReadonlyFields();\n this.isUpdateMode = true;\n\n $appDigest();\n }\n\n private triggerWMEvent(eventName) {\n const tableId = this.nativeElement.getAttribute('dependsontable');\n if (!tableId) {\n return;\n }\n $invokeWatchers(true);\n this.app.notify('wm-event', {eventName, widgetName: tableId});\n }\n\n submitForm($event) {\n let template, formData, result;\n const dataSource = this.datasource;\n // Disable the form submit if form is in invalid state.\n if (this.validateFieldsOnSubmit()) {\n return;\n }\n\n formData = getClonedObject(this.constructDataObject());\n\n const getParams = () => {\n return {$event, $formData: formData, $data: formData};\n };\n\n\n if (this.onBeforeSubmitEvt) {\n if (this.invokeEventCallback('beforesubmit', getParams()) === false) {\n return;\n } else {\n this.resetFormState();\n }\n } else {\n this.resetFormState();\n }\n\n if (this.onSubmitEvt || dataSource) {\n // If on submit is there execute it and if it returns true do service variable invoke else return\n // If its a service variable call setInput and assign form data and invoke the service\n if (dataSource) {\n const currentPageNum = dataSource.pagination && dataSource.pagination.number + 1;\n const operationType = this.operationType ? this.operationType : 'insert';\n performDataOperation(dataSource, formData, {operationType: operationType})\n .then((data) => {\n if (dataSource.category === 'wm.CrudVariable') {\n this.triggerWMEvent('resetEditMode');\n this.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true,\n 'operation': 'list',\n 'page': currentPageNum,\n 'preventMissingOpMsg': true\n });\n if (this.dialogId) {\n this.closeDialog();\n }\n }\n if (isDefined(data.body)) {\n result = getValidJSON(data.body);\n result = isDefined(result) ? result : data.body;\n } else {\n result = data;\n }\n return {\n 'result': result,\n 'status': true,\n 'message': this.postmessage,\n 'type': 'success'\n };\n }, (error) => {\n template = this.errormessage || error.error || error;\n $appDigest();\n return {\n 'result': get(error, 'error') || error,\n 'status': false,\n 'message': template,\n 'type': 'error'\n };\n }).then(response => {\n if ((response.type === 'error' && !this.onError) || (response.type === 'success' && !this.onSuccess)) {\n this.toggleMessage(true, response.message, response.type);\n }\n this.invokeEventCallback('submit', getParams());\n this.onResultCb(response.result, response.status, $event);\n });\n } else {\n this.invokeEventCallback('submit', getParams());\n this.onResultCb({}, true, $event);\n }\n } else {\n this.onResultCb({}, true, $event);\n }\n }\n\n closeDialog() {\n this.dialogService.close(this.dialogId);\n }\n\n // Method to show/hide the panel header or footer based on the buttons\n showButtons(position) {\n return some(this.buttonArray, btn => {\n return includes(btn.position, position) && btn.updateMode === this.isUpdateMode;\n });\n }\n\n // Expand or collapse the panel\n expandCollapsePanel() {\n if (this.collapsible) {\n // flip the active flag\n this.expanded = !this.expanded;\n }\n }\n\n onDataSourceUpdate(response, newForm, updateMode) {\n if (newForm) {\n this.new();\n } else {\n this.setFormData(response);\n this.closeDialog();\n }\n this.isUpdateMode = isDefined(updateMode) ? updateMode : true;\n }\n\n /**\n * This method tranverses through the parent containing formdata and returns the parent formdata.\n * @param form, represents the current form instance\n * @returns {any}\n */\n getNearestParentFormData(form) {\n if (!form.parentForm) {\n return {};\n }\n if (!form.bindformdata && get(form.parentForm, 'formdata') && !isEmpty(form.parentForm.formdata)) {\n return form.parentForm.formdata;\n }\n return this.getNearestParentFormData(form.parentForm);\n }\n\n setFormDataFromParentFormData(formdata: any) {\n if (isEmpty(this.formdata) && this.parentForm && formdata) {\n /**\n * If form is inside list,\n * 1. directly applying the formdata to the formArray to update the formdata on list of forms using patchValue.\n * 2. and also setting individual formdata to the form inside each item based on formArrayIndex, when form is not bound to formdata.\n * 3. explicitly invoking formdata as formFields will contain all the formfields including innerForm's fields\n * (if we do not invoke explicitly then formFields will just contain the fields inside current form and not inner form fields)\n * 4. if childFormArrayData is not available we will check for inner form data using \"formGroupName\" and will set the innerform data\n * If not inside list, just set the formdata on all the formfields including innerForm fields\n */\n if (this.parentFormArray) {\n let childFormArrayData = get(formdata, this.parentList.name);\n if (childFormArrayData) {\n if (!isArray(childFormArrayData)) {\n childFormArrayData = [childFormArrayData];\n }\n this.parentFormArray.patchValue(childFormArrayData);\n if (!this.bindformdata) {\n this.formdata = childFormArrayData[this.formArrayIndex];\n }\n this.setFormData(this.formdata);\n } else if (this.isParentList && this.parentForm.formGroupName) {\n const parentFormData = get(formdata, this.parentForm.formGroupName);\n this.setFormDataFromParentFormData(parentFormData);\n }\n } else {\n this.setFormData(formdata);\n }\n }\n }\n\n // On form data source change. This method is overridden by live form and live filter\n onDataSourceChange() {\n if (get(this.formFields, 'length') && !this.bindformdata) {\n this.isDataSourceUpdated = true;\n /**\n * formdata on the parent form will be set before the inner forms are rendered.\n * Hence handling formdata on the innerForms, which might be rendered slowly (suppose prefab with form)\n * setting inner form's formdata obtained from parent formdata\n * this applies only when formdata is not given on the inner form.\n */\n const formdata = this.getNearestParentFormData(this);\n this.setFormDataFromParentFormData(formdata);\n }\n }\n\n // On form data source change. This method is overridden by live form and live filter\n onFormDataSourceChange() {\n this.updateFieldSource();\n }\n\n // On form field default value change. This method is overridden by live form and live filter\n onFieldDefaultValueChange(field, nv) {\n field.value = parseValueByType(nv, undefined, field.widgettype, field.trailingzero);\n // WMS-22434: For default value set on individual form fields, do not mark the form as dirty.\n if (this.dirty && !this._triggeredByUser) {\n this.markAsPristine();\n }\n }\n\n // On form field value change. This method is overridden by live form and live filter\n onFieldValueChange() {\n }\n\n // Function to generate and compile the form fields from the metadata\n async generateFormFields() {\n let noOfColumns;\n let $gridLayout;\n // Check if grid layout is present or not for first time\n if (isUndefined(this._isGridLayoutPresent)) {\n this._isGridLayoutPresent = this.$element.find('.panel-body [wmlayoutgrid]').length > 0;\n }\n if (this._isGridLayoutPresent) {\n $gridLayout = this.$element.find('.form-elements [wmlayoutgrid]').first();\n noOfColumns = Number($gridLayout.attr('columns')) || 1;\n } else {\n $gridLayout = this.$element.find('.form-elements .dynamic-form-container');\n if (!$gridLayout.length) {\n this.$element.find('.form-elements').prepend('<div class=\"dynamic-form-container\"></div>');\n $gridLayout = this.$element.find('.form-elements .dynamic-form-container');\n }\n noOfColumns = 1;\n }\n const columnWidth = 12 / noOfColumns;\n let fieldTemplate = '';\n let colCount = 0;\n let index;\n let userFields;\n let fields = this.metadata ? this.metadata.data || this.metadata : [];\n\n this.formFields = []; // empty the form fields\n\n if (isEmpty(fields)) {\n return;\n }\n\n if (this.onBeforeRenderEvt) {\n userFields = this.invokeEventCallback('beforerender', {$metadata: fields});\n if (userFields) {\n fields = userFields;\n }\n }\n\n if (!isArray(fields)) {\n return;\n }\n\n while (fields[colCount]) {\n let colTmpl = '';\n for (index = 0; index < noOfColumns; index++) {\n if (fields[colCount]) {\n colTmpl += setMarkupForFormField(fields[colCount], columnWidth);\n }\n colCount++;\n }\n fieldTemplate += `<wm-gridrow>${colTmpl}</wm-gridrow>`;\n }\n\n if (!this._isGridLayoutPresent) {\n fieldTemplate = `<wm-layoutgrid>${fieldTemplate}</wm-layoutgrid>`;\n }\n\n this.dynamicFormRef.clear();\n\n if (!this._dynamicContext) {\n this._dynamicContext = Object.create(this.viewParent);\n this._dynamicContext.form = this;\n }\n const componentFactoryRef = await this.dynamicComponentProvider.getComponentFactoryRef(\n 'app-form-dynamic-' + this.widgetId,\n fieldTemplate,\n {\n noCache: true,\n transpile: true\n });\n const component = this.dynamicFormRef.createComponent(componentFactoryRef, 0, this.inj);\n extendProto(component.instance, this._dynamicContext);\n $gridLayout[0].appendChild(component.location.nativeElement);\n this.setFormData(this.formdata);\n }\n\n get mode() {\n return this.operationType || this.findOperationType();\n }\n\n get dirty() {\n return this.ngform && this.ngform.dirty;\n }\n\n /**\n * This method sets the form state to pristine by internally calling angular markAsPristine method on the form\n * @param value, When true, mark only this control. When false or not supplied, marks all direct ancestors. Default is false\n * @returns {void}\n */\n markAsPristine(value: boolean = false) {\n this.ngform.markAsPristine({ onlySelf: value });\n }\n\n /**\n * This method sets the form state to dirty by internally calling angular markAsDirty method on the form\n * @param value, When true, mark only this control. When false or not supplied, marks all direct ancestors. Default is false\n * @returns {void}\n */\n markAsDirty(value: boolean = false) {\n this.ngform.markAsDirty({ onlySelf: value });\n }\n\n get invalid() {\n return this.ngform && this.ngform.invalid;\n }\n\n get touched() {\n return this.ngform && this.ngform.touched;\n }\n\n get valid() {\n return this.ngform && this.ngform.valid;\n }\n\n get pristine() {\n return this.ngform && this.ngform.pristine;\n }\n\n /**\n * This method sets the form state to touched by internally calling angular markAsTouched method on the form\n * @param value, When true, mark only this control. When false or not supplied, marks all direct ancestors. Default is false\n * @returns {void}\n */\n markAsTouched(value: boolean = false) {\n this.ngform.markAsTouched({ onlySelf: value });\n }\n\n /**\n * This method sets the form state to untouched by internally calling angular markAsUntouched method on the form\n * @param value, When true, mark only this control. When false or not supplied, marks all direct ancestors. Default is false\n * @returns {void}\n */\n markAsUntouched(value: boolean = false) {\n this.ngform.markAsUntouched({ onlySelf: value });\n }\n\n invokeActionEvent($event, expression: string) {\n const fn = $parseEvent(expression);\n fn(this.viewParent, Object.assign(this.context, {$event}));\n }\n\n ngOnDestroy() {\n // on form destroy, removing this form from the parentForm too.\n const controls = this.parentForm && get(this.parentForm, 'ngform.controls');\n if (controls) {\n // when current form is inside the list (i.e. incase of formArray).\n if (get(this.parentList, 'name') && controls.hasOwnProperty(this.parentList.name)) {\n //get the index of current form in the list and remove the FormControl from FormArray\n const index = findIndex(this.parentList.getWidgets(this.name), {widgetId: this.widgetId});\n (<FormArray>this.parentForm.ngform.controls[this.parentList.name]).removeAt(index);\n }\n // when we have formGroupName set i.e. multiple formInstance with counter appended to formName\n if (this.formGroupName && controls.hasOwnProperty(this.formGroupName)) {\n this.parentForm.ngform.removeControl(this.formGroupName);\n } else {\n this.parentForm.ngform.removeControl(this.name);\n }\n }\n super.ngOnDestroy();\n }\n}\n","import { Attribute, Directive, Inject, OnInit, Self, Optional } from '@angular/core';\nimport { FormBuilder, FormGroup } from '@angular/forms';\n\nimport { WidgetRef } from '@wm/components/base';\nimport { TableComponent } from '@wm/components/data/table';\n\nimport { FormComponent } from './form.component';\n\n@Directive({\n selector: '[wmFormWidget]'\n})\nexport class FormWidgetDirective implements OnInit {\n\n ngform: FormGroup;\n fb;\n parent;\n\n constructor(\n @Optional() @Inject(FormComponent) form,\n @Optional() @Inject(TableComponent) table,\n @Self() @Inject(WidgetRef) public componentInstance,\n fb: FormBuilder,\n @Attribute('name') public name,\n @Attribute('key') public key) {\n this.fb = fb;\n this.parent = form || table;\n this.ngform = this.parent.ngform;\n\n this.componentInstance.registerPropertyChangeListener((k, nv) => {\n if (k === 'datavalue' && this._control) {\n this._control.setValue(nv);\n } else if (k === 'name' && !this._control) {\n this.addControl(this.key || nv);\n }\n });\n }\n\n get _control() {\n const fieldName = this.key || this.name;\n if (!fieldName) {\n return undefined;\n }\n return this.ngform && this.ngform.controls[fieldName];\n }\n\n addControl(fieldName) {\n this.ngform.addControl(fieldName, this.createControl());\n }\n\n createControl() {\n return this.fb.control(this.componentInstance.datavalue);\n }\n\n ngOnInit() {\n const fieldName = this.key || this.name;\n\n if (fieldName && !this._control) {\n this.addControl(fieldName);\n this.parent.registerFormWidget(this.componentInstance);\n }\n }\n}\n","import { PROP_BOOLEAN, PROP_NUMBER, PROP_STRING, register } from '@wm/components/base';\n\nexport const registerProps = () => {\n register(\n 'wm-form-action',\n new Map(\n [\n ['accessroles', PROP_STRING],\n ['action', PROP_STRING],\n ['class', PROP_STRING],\n ['binding', PROP_STRING],\n ['disabled', PROP_BOOLEAN],\n ['display-name', PROP_STRING],\n ['hyperlink', PROP_STRING],\n ['iconclass', PROP_STRING],\n ['iconname', PROP_STRING],\n ['key', PROP_STRING],\n ['position', {value: 'footer', ...PROP_STRING}],\n ['shortcutkey', PROP_STRING],\n ['show', {value: true, ...PROP_BOOLEAN}],\n ['tabindex', {value: 0, ...PROP_NUMBER}],\n ['target', PROP_STRING],\n ['title', PROP_STRING],\n ['type', {value: 'button', ...PROP_STRING}],\n ['update-mode', {value: true, ...PROP_BOOLEAN}],\n ['widget-type', {value: 'button', ...PROP_STRING}]\n ]\n )\n );\n};\n","import {Directive, Inject, Injector, OnInit, Optional} from '@angular/core';\n\nimport { BaseComponent, provideAsWidgetRef } from '@wm/components/base';\n\nimport { registerProps } from './form-action.props';\nimport { FormComponent } from '../form.component';\nimport {isUndefined} from \"lodash-es\";\n\nconst WIDGET_CONFIG = {widgetType: 'wm-form-action', hostClass: ''};\n\n@Directive({\n selector: '[wmFormAction]',\n providers: [\n provideAsWidgetRef(FormActionDirective)\n ]\n})\nexport class FormActionDirective extends BaseComponent implements OnInit {\n static initializeProps = registerProps();\n\n accessroles;\n action;\n binding;\n class;\n disabled;\n displayName;\n iconclass;\n iconname;\n key;\n position;\n shortcutkey;\n show;\n tabindex;\n title;\n type;\n updateMode;\n buttonDef;\n hyperlink;\n target;\n\n private _propsInitialized: boolean;\n\n constructor(inj: Injector, @Optional() public form: FormComponent, @Inject('EXPLICIT_CONTEXT') @Optional() explicitContext: any) {\n super(inj, WIDGET_CONFIG, explicitContext);\n }\n\n populateAction() {\n this.buttonDef = {\n key: this.key || this.binding,\n displayName: this['display-name'],\n show: this.show,\n class: this.class ? this.class : (this['widget-type'] === 'button' ? 'btn-secondary' : ''),\n iconclass: this.iconclass || '',\n title: isUndefined(this.title) ? (this['display-name'] || '') : this.title,\n action: this.action,\n accessroles: this.accessroles,\n shortcutkey: this.shortcutkey,\n disabled: this.disabled,\n tabindex: this.tabindex,\n iconname: this.iconname,\n type: this.type,\n updateMode: this['update-mode'],\n position: this.position,\n widgetType: this['widget-type'],\n hyperlink: this.hyperlink,\n target: this.target\n };\n this._propsInitialized = true;\n }\n\n ngOnInit() {\n super.ngOnInit();\n this.populateAction();\n this.form.registerActions(this.buttonDef);\n }\n\n onPropertyChange(key, nv, ov) {\n if (!this._propsInitialized) {\n return;\n }\n switch (key) {\n case 'display-name':\n this.buttonDef.displayName = nv;\n default:\n this.buttonDef[key] = nv;\n break;\n }\n }\n}\n","import { FormWidgetType } from '@wm/core';\n\nimport { PROP_BOOLEAN, PROP_NUMBER, PROP_STRING, getWidgetPropsByType } from '@wm/components/base';\n\nexport const registerProps = () => {\n const formFieldMap = new Map(\n [\n ['dataentrymode', {value: 'default', ...PROP_STRING}],\n ['debouncetime', {value: 250, ...PROP_NUMBER}],\n ['defaultvalue', PROP_STRING],\n ['displayname', PROP_STRING],\n ['display-name', PROP_STRING],\n ['field', PROP_STRING],\n ['filterexpressions', PROP_STRING],\n ['filter-on', PROP_STRING],\n ['generator', PROP_STRING],\n ['hint', PROP_STRING],\n ['inputtype', PROP_STRING],\n ['is-primary-key', PROP_BOOLEAN],\n ['is-range', PROP_BOOLEAN],\n ['is-related', PROP_BOOLEAN],\n ['isformfield', {value: true}],\n ['key', PROP_STRING],\n ['limit', PROP_NUMBER],\n ['lookup-type', PROP_STRING],\n ['lookup-field', PROP_STRING],\n ['name', PROP_STRING],\n ['matchmode', PROP_STRING],\n ['maxdefaultvalue', PROP_STRING],\n ['maxplaceholder', PROP_STRING],\n ['mobile-display', {value: true, ...PROP_BOOLEAN}],\n ['period', PROP_BOOLEAN],\n ['pc-display', {value: true, ...PROP_BOOLEAN}],\n ['placeholder', PROP_STRING],\n ['primary-key', PROP_BOOLEAN],\n ['related-entity-name', PROP_STRING],\n ['required', PROP_BOOLEAN],\n ['show', {value: true, ...PROP_BOOLEAN}],\n ['tablet-display', {value: true, ...PROP_BOOLEAN}],\n ['type', PROP_STRING],\n ['validationmessage', PROP_STRING],\n ['viewmodewidget', PROP_STRING],\n ['widgettype', PROP_STRING]\n ]\n );\n\n for (const key in FormWidgetType) {\n const widgetName = 'wm-form-field-' + FormWidgetType[key];\n const widgetProps = getWidgetPropsByType(widgetName);\n formFieldMap.forEach((v, k: string) => {\n if (widgetProps.get(k) == undefined) {\n widgetProps.set(k, v);\n }\n });\n }\n};\n","import {\n AfterContentInit,\n Attribute,\n ContentChild,\n Directive,\n HostListener,\n Inject,\n Injector,\n OnInit,\n Optional,\n Self\n} from '@angular/core';\nimport {FormBuilder, FormGroup, NG_VALUE_ACCESSOR} from '@angular/forms';\n\nimport {debounceTime} from 'rxjs/operators';\n\nimport {\n addForIdAttributes,\n App,\n debounce,\n FormWidgetType,\n isDateTimeType,\n isDefined,\n isMobile,\n noop,\n Viewport\n} from '@wm/core';\nimport {\n BaseFieldValidations,\n Context,\n getDefaultViewModeWidget,\n getEvaluatedData,\n provideAs,\n provideAsWidgetRef,\n StylableComponent\n} from '@wm/components/base';\nimport {ListComponent} from '@wm/components/data/list';\n\nimport {registerProps} from './form-field.props';\nimport {FormComponent} from '../form.component';\nimport {forEach, get, isArray, isObject, join} from \"lodash-es\";\n\ndeclare const $;\n\n// Custom validator to show validation error, if setValidationMessage method is used\nconst customValidatorFn = () => {\n return { custom: true };\n};\n\nconst FILE_TYPES = {\n 'image' : 'image/*',\n 'video' : 'video/*',\n 'audio' : 'audio/*'\n};\n\n@Directive({\n selector: '[wmFormField]',\n exportAs: 'wmFormField',\n providers: [\n provideAsWidgetRef(FormFieldDirective),\n provideAs(FormFieldDirective, NG_VALUE_ACCESSOR, true),\n {provide: Context, useFactory: () => { return {} }, multi: true}\n ]\n})\nexport class FormFieldDirective extends StylableComponent implements OnInit, AfterContentInit {\n static initializeProps = registerProps();\n\n @ContentChild('formWidget', {static: true}) formWidget;\n @ContentChild('formWidgetMax') formWidgetMax;\n\n private fb;\n private viewport;\n\n // excludeProps is used to store the props that should not be applied on inner widget\n private excludeProps;\n private _validators;\n private _oldUploadVal;\n\n ngform: FormGroup;\n defaultvalue;\n displayexpression;\n displayfield;\n displaylabel;\n displayname;\n generator;\n key;\n target;\n binding;\n widgettype;\n class;\n readonly;\n show;\n type;\n isDataSetBound;\n viewmodewidget;\n binddataset;\n binddisplayexpression;\n bindChipclass;\n displayimagesrc: string;\n binddisplayimagesrc;\n binddisplaylabel;\n form;\n filetype;\n extensions;\n permitted;\n period;\n isRange;\n name;\n // Validation properties\n required;\n maxchars;\n minvalue;\n maxvalue;\n regexp;\n fieldDefConfig;\n placeholder;\n inputtype;\n validationmessage;\n\n public _fieldName;\n\n private _debounceSetUpValidators;\n private _initPropsRes;\n private parentList;\n private showPendingSpinner: boolean;\n private _activeField: boolean;\n private notifyForFields: any;\n private fieldValidations;\n private _triggeredByUser: boolean;\n private _clicktriggeredByUser: boolean;\n private app: App;\n\n @HostListener('keydown', ['$event']) onKeydownHandler(event: KeyboardEvent) {\n this._triggeredByUser = true;\n }\n\n @HostListener('click', ['$event']) handleClick(event) {\n this._clicktriggeredByUser = true;\n }\n\n private isFocused;\n constructor(\n inj: Injector,\n form: FormComponent,\n fb: FormBuilder,\n viewport: Viewport,\n app: App,\n @Optional() parentList: ListComponent,\n @Attribute('chipclass.bind') bindChipclass: string,\n @Attribute('dataset.bind') binddataset,\n @Attribute('displayexpression.bind') binddisplayexpression: string,\n @Attribute('displaylabel.bind') binddisplaylabel: string,\n @Attribute('widgettype') _widgetType,\n @Attribute('name') name,\n @Attribute('displayimagesrc.bind') binddisplayimagesrc: String,\n @Attribute('key') key,\n @Attribute('is-range') isRange,\n @Attribute('pc-display') pcDisplay,\n @Attribute('mobile-display') mobileDisplay,\n @Attribute('tablet-display') tabletDisplay,\n @Self() @Inject(Context) contexts: Array<any>,\n @Inject('EXPLICIT_CONTEXT') @Optional() explicitContext: any\n ) {\n const WIDGET_CONFIG = {\n widgetType: 'wm-form-field',\n hostClass: '',\n widgetSubType: 'wm-form-field-' + (_widgetType || FormWidgetType.TEXT).trim()\n };\n let resolveFn: Function = noop;\n\n super(inj, WIDGET_CONFIG, explicitContext, new Promise(res => resolveFn = res));\n this._initPropsRes = resolveFn;\n this.app = app;\n this.fieldDefConfig = {};\n this.class = '';\n this.binddataset = binddataset;\n this.binddisplayimagesrc = binddisplayimagesrc;\n this.binddisplayexpression = binddisplayexpression;\n this.bindChipclass = bindChipclass;\n this.binddisplaylabel = binddisplaylabel;\n this.form = form;\n this.fb = fb;\n this.viewport = viewport;\n this._fieldName = key || name;\n this.isRange = isRange;\n this.excludeProps = new Set(['type', 'name']);\n this.widgettype = _widgetType;\n this.parentList = parentList;\n this.notifyForFields = [];\n\n if (this.binddataset || this.$element.attr('dataset')) {\n this.isDataSetBound = true;\n }\n\n contexts[0]._onFocusField = this._onFocusField.bind(this);\n contexts[0]._onBlurField = this._onBlurField.bind(this);\n\n this._debounceSetUpValidators = debounce(() => this.setUpValidators(), 500);\n }\n\n _onFocusField($evt) {\n this._activeField = true;\n $($evt.target).closest('.live-field').addClass('active');\n\n }\n\n // Function to get the active element markup based on widget type\n getActiveElement() {\n const widgetType = this.nativeElement.getAttribute('widgettype');\n switch (widgetType) {\n case 'select':\n return this.nativeElement.querySelector('select');\n case 'textarea':\n return this.nativeElement.querySelector('textarea');\n default:\n return this.nativeElement.querySelector('input');\n }\n }\n\n setAriaAttributes() {\n const element = this.getActiveElement();\n if (this.ngform.controls[this._fieldName].invalid && this.ngform.controls[this._fieldName].touched && this.form.isUpdateMode) {\n this.nativeElement.setAttribute('__errormsg', `${this.nativeElement.getAttribute('__validationId')}`);\n element?.setAttribute('aria-invalid', `${this.ngform.controls[this._fieldName].invalid}`);\n element?.setAttribute('aria-describedby', `${this.nativeElement.getAttribute('__validationId')}`);\n } else {\n this.nativeElement.removeAttribute('__errormsg');\n element?.removeAttribute('aria-invalid');\n element?.removeAttribute('aria-describedby');\n }\n }\n\n _onBlurField($evt) {\n $($evt.target).closest('.live-field').removeClass('active');\n const ele = this.nativeElement.querySelector('p.text-danger');\n // Fix for [WMS-23959]: ADA issue - adding aria-describedby, aria-invalid, __errormsg attributes only when the form field is invalid , else removing the attributes\n this.setAriaAttributes();\n this._activeField = false;\n this._triggeredByUser = false;\n this._clicktriggeredByUser = false;\n }\n\n // Expression to be evaluated in view mode of form field\n evaluateExpr(object, displayField, displayExpr) {\n if (!displayExpr || !displayField) {\n displayField = Object.keys(object)[0];\n // If dataset is not ready, display expression will not be defined\n if (!displayField) {\n return;\n }\n }\n return getEvaluatedData(object, {\n field: displayField,\n expression: displayExpr\n }, this.viewParent);\n }\n\n // Expression to be evaluated in view mode of form field\n getDisplayExpr() {\n const caption = [];\n const value = this.value;\n const displayField = this.displayfield || this.displaylabel\n const displayExpr = this.displayexpression;\n if (isObject(value)) {\n if (isArray(value)) {\n forEach(value, obj => {\n if (isObject(obj)) {\n caption.push(this.evaluateExpr(obj, displayField, displayExpr));\n }\n });\n } else {\n caption.push(this.evaluateExpr(value, displayField, displayExpr));\n }\n return join(caption, ',');\n }\n return (value === undefined || value === null) ? '' : this.value;\n }\n\n getCaption() {\n return (this.value === undefined || this.value === null) ? (get(this.form.dataoutput, this._fieldName) || '') : this.value;\n }\n\n // Notifies changes to observing validation fields\n notifyChanges() {\n forEach(this.notifyForFields, field => {\n field.fieldValidations.validate();\n });\n }\n\n // Registers observer of validation fields\n observeOn(fields) {\n this.fieldValidations.observeOn(fields, 'formfields');\n }\n\n // Method to setup validators for reactive form control\n setUpValidators(customValidator?) {\n this.fieldValidations.setUpValidators(customValidator);\n }\n\n // sets the custom async validation on the form field\n setAsyncValidators(validators) {\n this.fieldValidations.setAsyncValidators(validators);\n }\n\n // sets the default and custom sync validation on the form field\n setValidators(validators) {\n this.fieldValidations.setValidators(validators);\n }\n\n // Method to set the properties on inner form widget\n setFormWidget(key, val) {\n if (this.formWidget && this.formWidget.widget) {\n this.formWidget.widget[key] = val;\n }\n }\n\n boundFn(fn) {\n return fn();\n }\n\n // Method to set the properties on inner max form widget (when range is selected)\n setMaxFormWidget(key, val) {\n if (this.formWidgetMax) {\n this.formWidgetMax.widget[key] = val;\n }\n }\n\n onPropertyChange(key, nv, ov?) {\n const isFormDirty = this.form.dirty;\n\n if (key !== 'tabindex') {\n super.onPropertyChange(key, nv, ov);\n }\n\n if (this.excludeProps.has(key)) {\n return;\n }\n\n // As upload widget is an HTML widget, only required property is setup\n if (this.widgettype === FormWidgetType.UPLOAD) {\n if (key === 'required') {\n this._debounceSetUpValidators();\n }\n super.onPropertyChange(key, nv, ov);\n return;\n }\n\n this.setFormWidget(key, nv);\n\n // Placeholder should not be setup on max widget\n if (key !== 'placeholder') {\n this.setMaxFormWidget(key, nv);\n }\n\n switch (key) {\n case 'defaultvalue':\n this.form.onFieldDefaultValueChange(this, nv);\n break;\n case 'maxdefaultvalue':\n this.maxValue = nv;\n this.setMaxFormWidget('datavalue', nv);\n this.form.onMaxDefaultValueChange();\n break;\n case 'maxplaceholder':\n this.setMaxFormWidget('placeholder', nv);\n break;\n case 'required':\n // WMS-18906 : Do not make form as dirty during required prop initialization\n if (isFormDirty !== this.form.dirty) {\n this.form.markAsPristine();\n }\n case 'maxchars':\n case 'minvalue':\n case 'maxvalue':\n case 'regexp':\n case 'show':\n this._debounceSetUpValidators();\n break;\n case 'primary-key':\n if (nv) {\n this.form.setPrimaryKey(this._fieldName);\n }\n break;\n case 'display-name':\n this.displayname = nv;\n break;\n case 'readonly':\n this.setReadOnlyState();\n break;\n }\n }\n\n onStyleChange(key, nv, ov?) {\n this.setFormWidget(key, nv);\n this.setMaxFormWidget(key, nv);\n super.onStyleChange(key, nv, ov);\n }\n\n get datavalue() {\n return this.formWidget && this.formWidget.datavalue;\n }\n\n set datavalue(val) {\n if (this._control && this.widgettype !== FormWidgetType.UPLOAD) {\n this._control.setValue(val);\n }\n }\n\n get value() {\n return this.datavalue;\n }\n\n set value(val) {\n this.datavalue = val;\n }\n\n get maxValue() {\n return this.formWidgetMax && this.formWidgetMax.datavalue;\n }\n\n set maxValue(val) {\n if (this._maxControl) {\n this._maxControl.setValue(val);\n }\n }\n\n get minValue() {\n return this.value;\n }\n\n set minValue(val) {\n this.value = val;\n }\n\n // Get the reactive form control\n get _control() {\n return this.ngform && this.ngform.controls[this._fieldName];\n }\n\n // Get the reactive max form control\n get _maxControl() {\n return this.ngform && this.ngform.controls[this._fieldName + '_max'];\n }\n\n // Get the displayValue\n get displayValue() {\n return this.formWidget && this.formWidget.displayValue;\n }\n\n //Get the timestamp\n get timestamp(){\n return this.formWidget && this.formWidget.timestamp;\n }\n\n //Get the charlength\n get charlength(){\n return this.formWidget && this.formWidget.charlength;\n }\n\n // Create the reactive form control\n createControl() {\n return this.fb.control(undefined, {\n validators: this._validators\n });\n }\n\n // On field value change, propagate event to parent form\n onValueChange(val) {\n if (!this.isDestroyed) {\n const captionEl = $(this.nativeElement).find('.caption-floating');\n if (captionEl.length > 0) {\n // hasValue check whether form-field has a value from passed val attribute\n // Added sanity check on val to support values liked 0, false etc as input val - WMS-20084\n // explicitly checking for input value or -webkit-autofill to see whether there are any autofilled fields - WMS-20141\n\n const hasValue = ((isDefined(val) && val !== '' && val !== null) || captionEl.find('input').val()) || captionEl.find('input:-webkit-autofill').length;\n\n this.app.notify('captionPositionAnimate', {\n displayVal: hasValue,\n nativeEl: captionEl,\n isSelectMultiple: this.formWidget && this.formWidget.multiple,\n isFocused: this._activeField\n });\n }\n // Fix for [WMS-23959]: ADA issue - adding aria-describedby, aria-invalid, __errormsg attributes only when the form field is invalid , else removing the attributes\n this.setAriaAttributes();\n this.form.onFieldValueChange(this, val);\n this.notifyChanges();\n // Do mark as touched, only incase when user has entered an input but not through the script. Hence added mousedown event check\n // active class checks whether user is on the current field, if so marking the field as touched. And form field validation happens once a field is touched\n // _triggeredByUser checks whether the field is touched by the user or triggered from external script\n // WMS-22456: _clicktriggeredByUser checks when user selects datetimetype from picker, mark the field as touched to show validation errors in mobile\n\n if (this.$element.find('.active').length > 0 || this.form.touched) {\n if (this._triggeredByUser || (isMobile() && this._clicktriggeredByUser && isDateTimeType(this.widgettype))) {\n this.ngform.controls[this._fieldName].markAsTouched();\n }\n this.fieldValidations.setCustomValidationMessage();\n }\n }\n }\n\n onStatusChange(status) {\n if (!this.isDestroyed) {\n this.showPendingSpinner = (status === 'PENDING');\n // while running validation, widget is disabled and spinner is shown\n // otherwise formWidget disabled state is reset to the state of the formField.\n if (status === 'PENDING') {\n this.formWidget.disabled = true;\n } else if (this.formWidget.disabled !== (this as any).disabled) {\n this.formWidget.disabled = (this as any).disabled;\n }\n }\n }\n\n // Method to expose validation message and set control to invalid\n setValidationMessage(val) {\n setTimeout(() => {\n this.validationmessage = val;\n this.setUpValidators(customValidatorFn);\n });\n }\n\n setReadOnlyState() {\n let readOnly;\n if (this.form.isUpdateMode) {\n if (this['primary-key'] && !this['is-related'] && !this.period) {\n /*If the field is primary but is assigned set readonly false.\n Assigned is where the user inputs the value while a new entry.\n This is not editable(in update mode) once entry is successful*/\n readOnly = !(this.generator === 'assigned' && this.form.operationType !== 'update');\n } else {\n readOnly = this.readonly;\n }\n } else {\n // In view mode, set widget state to readonly always\n readOnly = true;\n }\n this.setFormWidget('readonly', readOnly);\n }\n\n resetDisplayInput() {\n if ((!isDefined(this.value) || this.value === '')) {\n this.formWidget && this.formWidget.resetDisplayInput && this.formWidget.resetDisplayInput();\n }\n }\n\n triggerUploadEvent($event, eventName) {\n const params: any = { $event };\n if (eventName === 'change') {\n params.newVal = $event.target.files;\n params.oldVal = this._oldUploadVal;\n this._oldUploadVal = params.newVal;\n }\n this.invokeEventCallback(eventName, params);\n }\n\n private registerFormField() {\n\n const fieldName = this._fieldName;\n\n if (this.parentList && !(this.form.parentList === this.parentList)) {\n let counter = 1;\n let _fieldName = fieldName;\n while (this.ngform.controls.hasOwnProperty(_fieldName)) {\n _fieldName = `${fieldName}_${counter}`;\n counter++;\n }\n this.ngform.addControl(_fieldName, this.createControl());\n this._fieldName = _fieldName;\n } else {\n this.ngform.addControl(fieldName, this.createControl());\n }\n const onValueChangeSubscription = this._control.valueChanges\n .pipe(debounceTime(200))\n .subscribe(this.onValueChange.bind(this));\n this.registerDestroyListener(() => onValueChangeSubscription.unsubscribe());\n\n const onStatusChangeSubscription = this._control.statusChanges\n .pipe(debounceTime(100))\n .subscribe(this.onStatusChange.bind(this));\n this.registerDestroyListener(() => onStatusChangeSubscription.unsubscribe());\n\n if (this.isRange === 'true') {\n this.ngform.addControl(fieldName + '_max', this.createControl());\n // registering for valueChanges on MaxformWidget\n const onMaxValueChangeSubscription = this._maxControl.valueChanges\n .pipe(debounceTime(200))\n .subscribe(this.onValueChange.bind(this));\n this.registerDestroyListener(() => onMaxValueChangeSubscription.unsubscribe());\n }\n this.value = get(this.form.formdata, this._fieldName);\n }\n\n ngOnInit() {\n this.ngform = this.form.ngform;\n this.registerFormField();\n // Instantiate custom validators class for form field\n this.fieldValidations = new BaseFieldValidations(this, this.formWidget, this.widgettype, this._control, this.form);\n super.ngOnInit();\n }\n\n ngAfterContentInit() {\n super.ngAfterContentInit();\n\n if (this.formWidget) {\n this._initPropsRes();\n\n // setting displayExpressions on the formwidget explicitly as expr was evaluated to \"\".\n this.setFormWidget('binddisplaylabel', this.binddisplaylabel);\n this.setFormWidget('binddisplayexpression', this.binddisplayexpression);\n this.setFormWidget('binddisplayimagesrc', this.binddisplayimagesrc);\n this.setFormWidget('bindChipclass', this.bindChipclass);\n this.setFormWidget('binddataset', this.binddataset);\n }\n\n this.registerReadyStateListener(() => {\n this.key = this._fieldName || this.target || this.binding;\n this.viewmodewidget = this.viewmodewidget || getDefaultViewModeWidget(this.widgettype);\n\n // For upload widget, generate the permitted field\n if (this.widgettype === FormWidgetType.UPLOAD) {\n let fileType;\n // Create the accepts string from file type and extensions\n fileType = this.filetype ? FILE_TYPES[this.filetype] : '';\n this.permitted = fileType + (this.extensions ? (fileType ? ',' : '') + this.extensions : '');\n }\n if (isMobile() && this.viewport.isMobileType) {\n if (!this['mobile-display']) {\n this.widget.show = false;\n }\n } else if (this.viewport.isTabletType) {\n if (!this['tablet-display']) {\n this.widget.show = false;\n }\n } else {\n if (!this['pc-display']) {\n this.widget.show = false;\n }\n }\n\n this.fieldDefConfig.displaname = this.displayname;\n this.fieldDefConfig.show = this.show;\n this.fieldDefConfig.isRelated = this['is-related'];\n this.fieldDefConfig.inputtype = this.inputtype;\n this.fieldDefConfig.generator = this.generator;\n this.fieldDefConfig.placeholder = this.placeholder;\n this.fieldDefConfig.primaryKey = this['primary-key'];\n this.fieldDefConfig.required = this.required;\n this.fieldDefConfig._readonly = this.readonly;\n this.fieldDefConfig.regexp = this.regexp;\n this.fieldDefConfig.type = this.type;\n this.fieldDefConfig.key = this.key;\n this.fieldDefConfig.mobileDisplay = this['mobile-display'];\n this.fieldDefConfig.name = this.name;\n this.fieldDefConfig.pcDisplay = this['pc-display'];\n this.fieldDefConfig.tabletDisplay = this['tablet-display'];\n this.fieldDefConfig.validationmessage = this.validationmessage;\n this.fieldDefConfig.viewmodewidget = this.viewmodewidget;\n this.fieldDefConfig.widget = this.widgettype;\n\n // Register the form field with parent form\n this.form.registerFormFields(this.widget);\n\n addForIdAttributes(this.nativeElement);\n\n this.setReadOnlyState();\n });\n }\n}\n","import { Directive, Inject, Self } from '@angular/core';\n\nimport { AbstractDialogService, App, DataSource, triggerFn } from '@wm/core';\nimport { Live_Operations, performDataOperation } from '@wm/components/base';\nimport { ListComponent } from '@wm/components/data/list';\n\n@Directive({\n selector: '[wmLiveActions]'\n})\nexport class LiveActionsDirective {\n\n constructor(\n @Self() @Inject(ListComponent) private subscribedWidget,\n private app: App,\n private dialogService: AbstractDialogService\n ) {\n subscribedWidget.addRow = this.addRow.bind(this);\n subscribedWidget.updateRow = this.updateRow.bind(this);\n subscribedWidget.deleteRow = this.deleteRow.bind(this);\n subscribedWidget.call = this.call.bind(this);\n }\n\n public addRow() {\n this.app.notify('wm-event', {eventName: Live_Operations.INSERT, widgetName: this.subscribedWidget.name, row: this.subscribedWidget.selecteditem});\n }\n\n public updateRow() {\n this.app.notify('wm-event', {eventName: Live_Operations.UPDATE, widgetName: this.subscribedWidget.name, row: this.subscribedWidget.selecteditem});\n }\n\n public deleteRow() {\n this.app.notify('wm-event', {eventName: Live_Operations.DELETE, widgetName: this.subscribedWidget.name, row: this.subscribedWidget.selecteditem});\n }\n\n private successHandler(options, response) {\n triggerFn(options.success, response);\n }\n\n private errorHandler(options, error) {\n this.app.notifyApp(error, 'error', 'ERROR');\n triggerFn(options.error, error);\n }\n\n public getRecords(options, operation) {\n let index;\n let dataNavigator;\n\n if (this.subscribedWidget.navigation !== 'None' && this.subscribedWidget.dataNavigator) {\n dataNavigator = this.subscribedWidget.dataNavigator;\n\n // If operation is delete, decrease the data size and check if navigation to previous page is required\n if (operation === Live_Operations.DELETE) {\n dataNavigator.dataSize -= 1;\n dataNavigator.calculatePagingValues();\n index = dataNavigator.pageCount < dataNavigator.dn.currentPage ? 'prev' : undefined;\n } else {\n // If operation is insert, go to last page. If update operation, stay on current page\n index = operation === Live_Operations.INSERT ? 'last' : 'current';\n if (index === 'last') {\n dataNavigator.dataSize += 1;\n }\n dataNavigator.calculatePagingValues();\n }\n\n dataNavigator.navigatePage(index, null, true, response => {\n this.successHandler(options, response);\n });\n } else {\n this.subscribedWidget.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true\n }).then(response => {\n this.successHandler(options, response);\n }, err => {\n this.errorHandler(options, err);\n });\n }\n }\n\n private performCUDOperation(requestData, operation, options) {\n performDataOperation(this.subscribedWidget.datasource, requestData, {\n operationType: operation\n }).then(response => {\n if (response.error) {\n this.errorHandler(options, response.error);\n return;\n }\n if (this.subscribedWidget.datasource.category === 'wm.CrudVariable' && operation === 'delete') {\n this.subscribedWidget.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true\n }).then(response => {\n this.successHandler(options, response);\n }, err => {\n this.errorHandler(options, err);\n });\n } else {\n this.getRecords(options, operation);\n }\n // show delete success toaster\n if (operation === 'delete') {\n this.app.notifyApp(this.app.appLocale.MESSAGE_DELETE_RECORD_SUCCESS, 'success');\n }\n }, (error) => {\n this.errorHandler(options, error);\n });\n }\n\n private insertRecord(requestData, operation, options) {\n this.performCUDOperation(requestData, operation, options);\n }\n\n private updateRecord(requestData, operation, options) {\n this.performCUDOperation(requestData, operation, options);\n }\n\n private deleteRecord(requestData, operation, options) {\n // Show the delete confirmation dialog. On Ok, delete the record.\n this.dialogService.showAppConfirmDialog({\n title: this.app.appLocale.MESSAGE_DELETE_RECORD || 'Delete Record',\n iconclass: 'wi wi-delete fa-lg',\n message: this.subscribedWidget.confirmdelete || 'Are you sure you want to delete this?',\n oktext: this.subscribedWidget.deleteoktext || 'Ok',\n canceltext: this.subscribedWidget.deletecanceltext || 'Cancel',\n onOk: () => {\n this.performCUDOperation(requestData, operation, options);\n this.dialogService.closeAppConfirmDialog();\n },\n onCancel: () => {\n triggerFn(options.cancelDeleteCallback);\n this.dialogService.closeAppConfirmDialog();\n }\n });\n }\n\n private performOperation(operation, options) {\n const requestData = {\n row: options.row,\n prevData: {},\n rowData: {},\n transform: true,\n skipNotification: true\n };\n\n if (operation === Live_Operations.UPDATE) {\n requestData.rowData = options.rowData;\n requestData.prevData = options.prevData;\n }\n\n /* decide routine based on CRUD operation to be performed */\n switch (operation) {\n case Live_Operations.INSERT:\n this.insertRecord(requestData, operation, options);\n break;\n case Live_Operations.UPDATE:\n this.updateRecord(requestData, operation, options);\n break;\n case Live_Operations.DELETE:\n this.deleteRecord(requestData, operation, options);\n break;\n case Live_Operations.READ:\n this.getRecords(options, operation);\n break;\n }\n }\n\n // API exposed to make CRUD operations\n public call(operation, options, success?, error?) {\n options.success = success;\n options.error = error;\n\n this.performOperation(operation, options);\n }\n}\n","import { Directive, Attribute, ContentChildren, AfterContentInit, OnDestroy } from '@angular/core';\n\nimport { AbstractDialogService, App, DataSource } from '@wm/core';\nimport { Live_Operations } from '@wm/components/base';\nimport { FormComponent } from '../form.component';\n\n@Directive({\n selector: '[dependson]'\n})\nexport class DependsonDirective implements AfterContentInit, OnDestroy {\n\n @ContentChildren(FormComponent, {descendants: true}) formChildren;\n\n private dialogId;\n private dependson;\n private isLayoutDialog;\n private form;\n private editMode;\n private currentOp;\n private currentFormData;\n private formSubscription;\n private eventSubscription;\n\n constructor(\n @Attribute('dialogid') dialogId: string,\n @Attribute('dependson') dependson: string,\n private dialogService: AbstractDialogService,\n private app: App\n ) {\n // If dialogId is present, form is in dialog mode\n if (dialogId) {\n this.isLayoutDialog = true;\n this.dialogId = dialogId;\n }\n this.dependson = dependson;\n // Listen to the wm-event called from subscribed widgets\n this.eventSubscription = this.app.subscribe('wm-event', this.handleEvent.bind(this));\n }\n\n private openFormDialog() {\n this.dialogService.open(this.dialogId);\n }\n\n private onUpdate(newValue?, table?, editClicked?) {\n this.editMode = editClicked || this.editMode ;\n this.form.operationType = Live_Operations.UPDATE;\n this.form.isSelected = true;\n let rowData = this.currentFormData;\n if (newValue && table) {\n if (table.multiselect) {\n rowData = newValue[0];\n } else {\n rowData = newValue[newValue.length - 1];\n }\n }\n this.form.setFormData(rowData);\n this.form.edit();\n if (!this.editMode) {\n this.form.isUpdateMode = false;\n }\n }\n private onInsert() {\n this.form.operationType = Live_Operations.INSERT;\n this.form.isSelected = true;\n this.form.setFormData({});\n this.form.new();\n }\n\n private handleEvent(options) {\n if (this.dependson !== options.widgetName) {\n return;\n }\n this.currentOp = options.eventName;\n switch (options.eventName) {\n case Live_Operations.UPDATE:\n this.currentFormData = options.row;\n if (this.isLayoutDialog) {\n this.openFormDialog();\n } else {\n this.onUpdate(undefined,undefined, true);\n }\n break;\n case Live_Operations.INSERT:\n if (this.isLayoutDialog) {\n this.openFormDialog();\n } else {\n this.onInsert();\n }\n break;\n case Live_Operations.DELETE:\n (<any>this.app).Widgets[this.dependson].call('delete', {row: options.row});\n break;\n case Live_Operations.READ:\n if (!this.isLayoutDialog) {\n this.form.isUpdateMode = false;\n }\n break;\n case 'rerender':\n if (options.dataSource) {\n options.dataSource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true,\n 'operation': 'list'\n });\n }\n break;\n case 'selectedItemChange':\n if (options.table) {\n this.onUpdate(options.row, options.table);\n }\n break;\n case 'resetEditMode':\n this.editMode = false;\n }\n }\n\n private onFormRender() {\n // On opening the form in dialog mode, complete the pending operations\n if (this.form && this.isLayoutDialog) {\n this.form.isLayoutDialog = true;\n setTimeout(() => {\n if (this.currentOp === Live_Operations.UPDATE) {\n this.onUpdate(undefined, undefined, true);\n } else if (this.currentOp === Live_Operations.INSERT) {\n this.onInsert();\n }\n }, 250);\n }\n }\n\n ngAfterContentInit() {\n // If form instance is present, form is in inline mode. Else, it is in dialog mode and listen to form instance changes\n if (this.formChildren.first) {\n this.form = this.formChildren.first;\n } else {\n this.formSubscription = this.formChildren.changes.subscribe((val) => {\n this.form = val.first;\n this.onFormRender();\n });\n }\n\n // find the dependent widget (table/list)\n this.app.notify('setup-cud-listener', this.dependson);\n }\n\n ngOnDestroy() {\n if (this.formSubscription) {\n this.formSubscription.unsubscribe();\n }\n if (this.eventSubscription) {\n this.eventSubscription();\n }\n }\n}\n","import { Directive, Inject, Self } from '@angular/core';\nimport { $appDigest, DataSource, DataType, debounce, FormWidgetType, getClonedObject, isDefined } from '@wm/core';\nimport { applyFilterOnField, fetchDistinctValues, getDistinctValuesForField, getEmptyMatchMode, getEnableEmptyFilter, getRangeFieldValue, getRangeMatchMode, isDataSetWidget } from '@wm/components/base';\n\nimport { FormComponent } from '../form.component';\nimport { registerLiveFilterProps } from '../form.props';\nimport {find} from \"lodash-es\";\n\nconst FILTER_CONSTANTS = {\n 'EMPTY_KEY' : 'EMPTY_NULL_FILTER'\n};\nconst noop = () => {};\n\n@Directive({\n selector: '[wmLiveFilter]'\n})\nexport class LiveFilterDirective {\n static initializeProps = registerLiveFilterProps();\n private _options;\n\n orderBy;\n\n // debounce the filter function. If multiple filter calls are made at same time, calls will be delayed and last call is fired\n _filter = debounce(options => {\n this.filter(options);\n }, 250);\n\n constructor(@Self() @Inject(FormComponent) private form) {\n form.clearFilter = this.clearFilter.bind(this);\n form.applyFilter = this.applyFilter.bind(this);\n form.filter = this.filter.bind(this);\n form.filterOnDefault = this.filterOnDefault.bind(this);\n form.execute = this.execute.bind(this);\n form.onFieldDefaultValueChange = this.onFieldDefaultValueChange.bind(this);\n form.onMaxDefaultValueChange = this.onMaxDefaultValueChange.bind(this);\n form.onDataSourceChange = this.onDataSourceChange.bind(this);\n form.onFieldValueChange = this.onFieldValueChange.bind(this);\n form.submitForm = this.submitForm.bind(this);\n form.registerFormWidget = this.registerFormWidget.bind(this);\n }\n\n execute(operation, options) {\n if (operation === DataSource.Operation.LIST_RECORDS || operation === DataSource.Operation.DOWNLOAD) {\n return this.applyFilter(options);\n }\n if (operation === DataSource.Operation.GET_OPTIONS) {\n return this._options || {};\n }\n if (operation === DataSource.Operation.GET_PAGING_OPTIONS) {\n return this.form.pagination;\n }\n if (!this.form.datasource) {\n return {};\n }\n if (operation === DataSource.Operation.FETCH_DISTINCT_VALUES) {\n return fetchDistinctValues(this.form.datasource, this.form.formFields, {\n widget: 'widgettype',\n enableemptyfilter: this.form.enableemptyfilter,\n EMPTY_VALUE: this.form.appLocale.LABEL_NO_VALUE\n });\n }\n return this.form.datasource.execute(operation, options);\n }\n\n onFieldDefaultValueChange(field, nv) {\n field.minValue = nv;\n field.value = nv;\n this.filterOnDefault();\n }\n\n onFieldValueChange(field, nv) {\n applyFilterOnField(this.form.datasource, field.widget, this.form.formFields, nv, {\n EMPTY_VALUE: this.form.appLocale.LABEL_NO_VALUE\n });\n if (this.form.autoupdate && isDefined(nv)) {\n this._filter();\n }\n }\n\n onMaxDefaultValueChange() {\n setTimeout(() => {\n this.filterOnDefault();\n });\n }\n\n onDataSourceChange() {\n const dataSource = this.form.datasource;\n\n if (!dataSource) {\n return;\n }\n\n this.form.formFields.forEach(field => {\n if (isDataSetWidget(field.widgettype)) {\n getDistinctValuesForField(dataSource, field.widget, {\n widget: 'widgettype',\n enableemptyfilter: this.form.enableemptyfilter,\n EMPTY_VALUE: this.form.appLocale.LABEL_NO_VALUE\n });\n applyFilterOnField(dataSource, field.widget, this.form.formFields, field.value, {\n isFirst: true,\n EMPTY_VALUE: this.form.appLocale.LABEL_NO_VALUE\n });\n }\n });\n\n // On load check if default value exists and apply filter, Call the filter with the result options\n this._filter(this._options);\n }\n\n clearFilter() {\n this.form.resetFormState();\n this.form.formFields.forEach(filterField => {\n // Added check for range field\n if (!filterField.readonly && filterField.show) {\n if (filterField.widgettype === FormWidgetType.AUTOCOMPLETE || filterField.widgettype === FormWidgetType.TYPEAHEAD) {\n this.form.$element.find('div[name=' + filterField.name + '] input').val('');\n }\n if (filterField['is-range']) {\n filterField.minValue = '';\n filterField.maxValue = '';\n } else {\n filterField.value = '';\n filterField.resetDisplayInput();\n }\n }\n });\n // If variable has any bindings, wait for the bindings to be updated\n setTimeout(() => {\n // Setting result to the default data\n this._filter();\n });\n }\n\n submitForm() {\n this.filter();\n }\n\n applyFilter(options) {\n options = options ? (options.data || options) : {};\n options.page = options.page || 1;\n options.orderBy = isDefined(options.orderBy) ? options.orderBy : this.orderBy;\n return this.filter(options);\n }\n\n filter(options?) {\n if (!this.form.datasource) {\n return;\n }\n const filterFields = {};\n const dataModel = {};\n let page = 1,\n orderBy,\n isValid;\n options = options || {};\n page = options.page || page;\n orderBy = isDefined(options.orderBy) ? options.orderBy : (this.orderBy || '');\n this.orderBy = orderBy; // Store the order by in scope. This can be used to retain the sort after filtering\n // Copy the values to be sent to the user as '$data' before servicecall\n this.form.formFields.forEach(field => {\n const fieldSelector = 'div[name=' + field.name + '] input';\n const $el = this.form.$element;\n let fieldEle;\n if ((field.widgettype === FormWidgetType.AUTOCOMPLETE || field.widgettype === FormWidgetType.TYPEAHEAD) && $el) {\n fieldEle = $el.find(fieldSelector);\n if (!field['is-range']) {\n dataModel[field.field] = {\n 'value': isDefined(field.value) ? field.value : fieldEle.val() // For autocomplete, set the datavalue. If not present, set query value\n };\n } else {\n dataModel[field.field] = {\n 'minValue': isDefined(field.minValue) ? field.minValue : fieldEle.first().val(),\n 'maxValue': isDefined(field.maxValue) ? field.maxValue : fieldEle.last().val()\n };\n }\n return;\n }\n if (!field['is-range']) {\n dataModel[field.field] = {\n 'value': field.value\n };\n } else {\n dataModel[field.field] = {\n 'minValue': field.minValue,\n 'maxValue': field.maxValue\n };\n }\n });\n /*Perform this function for the event onBeforeservicecall*/\n try {\n isValid = this.form.invokeEventCallback('beforeservicecall', {$data: dataModel});\n if (isValid === false) {\n return;\n }\n if (isValid && isValid.error) {\n this.form.toggleMessage(true, isValid.error, 'error', 'ERROR');\n return;\n }\n /*Update these values in the formFields with new reference, inorder to maintain the UI values*/\n this.form.formFields.forEach(filterField => {\n if (!filterField['is-range']) {\n filterField._value = dataModel[filterField.field].value;\n } else {\n filterField._minValue = dataModel[filterField.field].minValue;\n filterField._maxValue = dataModel[filterField.field].maxValue;\n }\n });\n } catch (err) {\n if (err.message === 'Abort') {\n return;\n }\n }\n /* Construct the formFields Variable to send it to the queryBuilder */\n this.form.formFields.forEach(filterField => {\n let fieldValue;\n let matchMode;\n let colName = filterField.field;\n const minValue = filterField._minValue;\n const maxvalue = filterField._maxValue;\n /* if field is part of a related entity, column name will be 'entity.fieldName' */\n if (filterField['is-related']) {\n colName += '.' + filterField['lookup-field'];\n }\n if (filterField['is-range']) {\n /*Based on the min and max values, decide the matchmode condition*/\n fieldValue = getRangeFieldValue(minValue, maxvalue);\n matchMode = getRangeMatchMode(minValue, maxvalue);\n if (isDefined(fieldValue)) {\n filterFields[colName] = {\n 'value' : fieldValue,\n 'matchMode' : matchMode,\n 'logicalOp' : 'AND'\n };\n }\n } else {\n switch (filterField.widgettype) {\n case FormWidgetType.SELECT:\n case FormWidgetType.RADIOSET:\n if (getEnableEmptyFilter(this.form.enableemptyfilter) && filterField._value === FILTER_CONSTANTS.EMPTY_KEY) {\n matchMode = getEmptyMatchMode(this.form.enableemptyfilter);\n fieldValue = filterField._value;\n } else {\n if (filterField.type === DataType.BOOLEAN) {\n if (isDefined(filterField._value) && filterField._value !== '') {\n fieldValue = JSON.parse(filterField._value);\n }\n } else {\n fieldValue = filterField._value;\n }\n }\n break;\n case FormWidgetType.CHECKBOXSET:\n case FormWidgetType.CHIPS:\n if (filterField._value && filterField._value.length) {\n fieldValue = filterField._value;\n }\n break;\n case FormWidgetType.CHECKBOX:\n case FormWidgetType.TOGGLE:\n if (isDefined(filterField._value) && filterField._value !== '') {\n fieldValue = filterField.type === DataType.BOOLEAN ? JSON.parse(filterField._value) : filterField._value;\n }\n break;\n default:\n fieldValue = filterField._value;\n break;\n }\n if (isDefined(fieldValue) && fieldValue !== '' && fieldValue !== null) {\n filterFields[colName] = {};\n if (matchMode) {\n filterFields[colName].matchMode = matchMode;\n fieldValue = undefined;\n } else if (filterField.type === DataType.STRING || filterField.isRelated) { // Only for string types and related fields, custom match modes are enabled.\n filterFields[colName].matchMode = matchMode || filterField.matchmode ||\n this.form.datasource.execute(DataSource.Operation.GET_MATCH_MODE);\n }\n filterFields[colName].value = fieldValue;\n filterFields[colName].logicalOp = 'AND';\n filterFields[colName].type = filterField.type;\n }\n }\n });\n\n if (options.exportType) {\n return this.form.datasource.execute(DataSource.Operation.DOWNLOAD, {\n data: {\n matchMode : 'anywhereignorecase',\n filterFields : filterFields,\n orderBy : orderBy,\n exportType : options.exportType,\n logicalOp : 'AND',\n exportSize : options.exportSize,\n fields : options.fields,\n fileName: options.fileName\n }\n });\n }\n return this.form.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n filterFields : filterFields,\n orderBy : orderBy,\n page : page,\n pagesize : this.form.pagesize || 20,\n skipDataSetUpdate : true, // dont update the actual variable dataset,\n inFlightBehavior : 'executeAll'\n }).then(response => {\n const data = response.data;\n this.form.pagination = response.pagination;\n\n if (data.error) {\n // disable readonly and show the appropriate error\n this.form.toggleMessage(true, data.error, 'error', 'ERROR');\n this.form.onResultCb(data, false);\n } else {\n this._options = {\n 'page': page,\n 'orderBy': orderBy\n };\n this.form.result = getClonedObject(data);\n this.form.onResultCb(data, true);\n }\n $appDigest();\n return this.form.result;\n }, error => {\n this.form.toggleMessage(true, error, 'error', 'ERROR');\n this.form.onResultCb(error, false);\n return error;\n });\n }\n\n // Calls the filter function if default values are present\n filterOnDefault() {\n /*Check if default value is present for any filter field*/\n const defaultObj = find(this.form.formFields, obj => {\n return isDefined(obj.value) || isDefined(obj.minValue) || isDefined(obj.maxValue);\n });\n /*If default value exists and data is loaded, apply the filter*/\n if (defaultObj) {\n this._filter(this._options);\n }\n }\n\n registerFormWidget(widget) {\n const name = widget.key || widget.name;\n this.form.filterWidgets[name] = widget;\n }\n}\n","import { Directive, Inject, Optional, Self, Attribute, HostListener } from '@angular/core';\n\nimport { $appDigest, AbstractDialogService, DataSource, DataType, debounce, getClonedObject, getFiles, getValidDateObject, isDateTimeType, isDefined, isEmptyObject } from '@wm/core';\nimport { ALLFIELDS, applyFilterOnField, fetchRelatedFieldData, getDistinctValuesForField, isDataSetWidget, Live_Operations, parseValueByType, performDataOperation, ToDatePipe } from '@wm/components/base';\nimport { LiveTableComponent } from '@wm/components/data/live-table';\n\nimport { registerLiveFormProps } from '../form.props';\nimport { FormComponent } from '../form.component';\nimport {forEach, fromPairs, get, isEmpty, isEqual, isString, map, some, split} from \"lodash-es\";\n\nconst isTimeType = field => field.widgettype === DataType.TIME || (field.type === DataType.TIME && !field.widgettype);\nconst getValidTime = val => {\n if (val) {\n const date = (new Date()).toDateString();\n return (new Date(`${date} ${val}`)).getTime();\n }\n return undefined;\n};\n\n@Directive({\n selector: '[wmLiveForm]'\n})\nexport class LiveFormDirective {\n static initializeProps = registerLiveFormProps();\n private _triggeredByUser: boolean;\n private _debouncedSavePrevDataValues = debounce(() => {\n this.savePrevDataValues();\n }, 250);\n\n @HostListener('keydown', ['$event']) onKeydownHandler(event: KeyboardEvent) {\n this._triggeredByUser = true;\n }\n\n constructor(\n @Self() @Inject(FormComponent) private form,\n @Optional() liveTable: LiveTableComponent,\n public datePipe: ToDatePipe,\n private dialogService: AbstractDialogService,\n @Attribute('formlayout') formlayout: string\n ) {\n // If parent live table is present and this form is first child of live table, set this form instance on livetable\n if (liveTable) {\n if (!this.form.parentForm) {\n this.form._liveTableParent = liveTable;\n }\n this.form.isLayoutDialog = liveTable.isLayoutDialog;\n liveTable.onFormReady(this.form);\n } else {\n this.form.isLayoutDialog = formlayout === 'dialog';\n }\n // CUD operations\n form.cancel = this.cancel.bind(this);\n form.reset = this.reset.bind(this);\n form.delete = this.delete.bind(this);\n form.save = this.save.bind(this);\n form.saveAndNew = this.saveAndNew.bind(this);\n form.saveAndView = this.saveAndView.bind(this);\n\n form.setPrimaryKey = this.setPrimaryKey.bind(this);\n form.constructDataObject = this.constructDataObject.bind(this);\n form.changeDataObject = this.setFormData.bind(this);\n form.setFormData = this.setFormData.bind(this);\n form.findOperationType = this.findOperationType.bind(this);\n form.clearData = this.clearData.bind(this);\n form.onFieldDefaultValueChange = this.onFieldDefaultValueChange.bind(this);\n form.onDataSourceChange = this.onDataSourceChange.bind(this);\n form.onFieldValueChange = this.onFieldValueChange.bind(this);\n form.submitForm = this.submitForm.bind(this);\n form.form_registerFormFields = form.registerFormFields;\n form.registerFormFields = this.registerFormFields.bind(this);\n }\n\n /*\n WMS:18583\n Overriding 'registerFormFields' for liveForms,\n On Each field added, check if the dataSource is updated or not\n if the field is added after the dataSource is updated at LiveForm, retrigger\n */\n registerFormFields(formField) {\n const formFields = this.form.getFormFields();\n this.form.form_registerFormFields(formField);\n if (this.form.isDataSourceUpdated) {\n this._updateFieldOnDataSourceChange(formField, formFields);\n }\n }\n private _updateFieldOnDataSourceChange(field, formFields) {\n if (!field.isDataSetBound && isDataSetWidget(field.widgettype)) {\n if (field['is-related']) {\n field.isDataSetBound = true;\n fetchRelatedFieldData(this.form.datasource, field.widget, {\n relatedField: field.key,\n datafield: ALLFIELDS,\n widget: 'widgettype',\n });\n } else {\n getDistinctValuesForField(this.form.datasource, field.widget, {\n widget: 'widgettype',\n enableemptyfilter: this.form.enableemptyfilter\n });\n applyFilterOnField(this.form.datasource, field.widget, formFields, field.value, {isFirst: true});\n }\n }\n }\n onDataSourceChange() {\n if (get(this.form.formFields, 'length')) {\n this.form.isDataSourceUpdated = true;\n }\n const formFields = this.form.getFormFields();\n formFields.forEach(field => {\n this._updateFieldOnDataSourceChange(field, formFields);\n });\n }\n\n onFieldDefaultValueChange(field, nv) {\n // In Edit, do not set default values\n if (this.form.operationType === 'update') {\n return;\n }\n // Set the default value only if it exists.\n if (isDefined(nv) && nv !== null && nv !== '' && nv !== 'null') {\n field.value = parseValueByType(nv, field.type, field.widgettype, field.trailingzero);\n } else {\n field.value = undefined;\n }\n\n // WMS-22434: For default value set on individual form fields, do not mark the form as dirty.\n if (this.form.dirty && !this._triggeredByUser) {\n this.form.markAsPristine();\n }\n this._debouncedSavePrevDataValues();\n }\n\n onFieldValueChange(field, nv) {\n applyFilterOnField(this.form.datasource, field.widget, this.form.formFields, nv);\n }\n\n getBlobURL(dataObj, key, value) {\n let href = '';\n let primaryKeys;\n let primaryKey;\n if (value === null || value === undefined || !this.form.datasource) {\n return href;\n }\n primaryKeys = this.form.datasource.execute(DataSource.Operation.GET_PRIMARY_KEY) || [];\n primaryKey = dataObj[primaryKeys[0]];\n // TODO: Handle mobile case\n // if (CONSTANTS.hasCordova && CONSTANTS.isRunMode) {\n // href += $rootScope.project.deployedUrl;\n // }\n href += this.form.datasource.execute(DataSource.Operation.GET_BLOB_URL, {\n primaryValue: primaryKey,\n columnName: key\n });\n href += '?' + Math.random();\n return href;\n }\n\n setFormData(dataObj, formFields?) {\n if (!dataObj) {\n return;\n }\n formFields = formFields || this.form.formFields;\n formFields.forEach(field => {\n const value = get(dataObj, field.key || field.name);\n if (isTimeType(field)) {\n field.value = getValidTime(value);\n } else if (field.type === DataType.BLOB) {\n this.form.resetFileUploadWidget(field, true);\n field.href = this.getBlobURL(dataObj, field.key, value);\n field.value = isString(value) ? '' : value;\n } else {\n this.form.setFieldValue(field, dataObj);\n }\n });\n this.savePrevDataValues();\n this.form.constructDataObject();\n }\n\n onDataSourceUpdate(response, newForm, updateMode) {\n if (newForm) {\n this.form.new();\n } else {\n this.form.setFormData(response);\n this.closeDialog();\n }\n this.form.isUpdateMode = isDefined(updateMode) ? updateMode : true;\n }\n\n savePrevformFields() {\n this.form.prevformFields = getClonedObject(this.form.formFields.map(field => {\n return {\n 'key': field.key,\n 'type': field.type,\n 'widgettype': field.widgettype,\n 'outputformat': field.outputformat,\n 'value': field.value\n };\n }));\n }\n\n getPrevformFields() {\n this.form.formFields.map(field => {\n const prevField = this.form.prevformFields.find(pField => pField.key === field.key);\n field.value = prevField.value;\n });\n }\n\n getDataObject() {\n if (this.form.operationType === Live_Operations.INSERT) {\n return {};\n }\n if (isDefined(this.form.prevDataObject) && !isEmptyObject(this.form.prevDataObject)) {\n return getClonedObject(this.form.prevDataObject);\n }\n return getClonedObject(this.form.formdata || {});\n }\n\n constructDataObject(isPreviousData?) {\n const dataObject = this.getDataObject();\n const formName = this.form.name;\n let formFields;\n formFields = isPreviousData ? this.form.prevformFields : this.form.getFormFields();\n formFields.forEach(field => {\n let dateTime,\n fieldValue;\n const fieldTarget = split(field.key, '.');\n const fieldName = fieldTarget[0] || field.key;\n\n /*collect the values from the fields and construct the object*/\n /*Format the output of date time widgets to the given output format*/\n if ((field.widgettype && isDateTimeType(field.widgettype)) || isDateTimeType(field.type)) {\n if (field.value) {\n dateTime = getValidDateObject(field.value);\n if (field.outputformat === DataType.TIMESTAMP || field.type === DataType.TIMESTAMP) {\n fieldValue = field.value ? dateTime : null;\n } else if (field.outputformat) {\n fieldValue = this.datePipe.transform(dateTime, field.outputformat);\n } else {\n fieldValue = field.value;\n }\n } else {\n fieldValue = undefined;\n }\n } else if (field.type === DataType.BLOB) {\n fieldValue = getFiles(formName, fieldName + '_formWidget', field.multiple);\n } else if (field.type === DataType.LIST) {\n fieldValue = field.value || undefined;\n } else {\n fieldValue = (field.value === null || field.value === '') ? undefined : field.value;\n }\n\n if (fieldTarget.length === 1) {\n dataObject[fieldName] = fieldValue;\n } else {\n dataObject[fieldName] = dataObject[fieldName] || {};\n dataObject[fieldName][fieldTarget[1]] = fieldValue;\n }\n });\n if (!isPreviousData) {\n this.form.updateFormDataOutput(dataObject);\n return this.form.dataoutput;\n }\n return dataObject;\n }\n\n setPrimaryKey(fieldName) {\n /*Store the primary key of data*/\n this.form.primaryKey = this.form.primaryKey || [];\n if (this.form.primaryKey.indexOf(fieldName) === -1) {\n this.form.primaryKey.push(fieldName);\n }\n }\n\n findOperationType() {\n let operation;\n let isPrimary = false;\n const sourceOperation = this.form.datasource && this.form.datasource.execute(DataSource.Operation.GET_OPERATION_TYPE);\n if (sourceOperation && sourceOperation !== 'read') {\n return sourceOperation;\n }\n /*If OperationType is not set then based on the formdata object return the operation type,\n this case occurs only if the form is outside a livegrid*/\n /*If the formdata object has primary key value then return update else insert*/\n if (this.form.primaryKey && !isEmpty(this.form.formdata)) {\n /*If only one column is primary key*/\n if (this.form.primaryKey.length === 1) {\n if (this.form.formdata[this.form.primaryKey[0]]) {\n operation = Live_Operations.UPDATE;\n }\n /*If only no column is primary key*/\n } else if (this.form.primaryKey.length === 0) {\n forEach(this.form.formdata, (value) => {\n if (value) {\n isPrimary = true;\n }\n });\n if (isPrimary) {\n operation = Live_Operations.UPDATE;\n }\n /*If multiple columns are primary key*/\n } else {\n isPrimary = some(this.form.primaryKey, (primaryKey) => {\n if (this.form.formdata[primaryKey]) {\n return true;\n }\n });\n if (isPrimary) {\n operation = Live_Operations.UPDATE;\n }\n }\n }\n return operation || Live_Operations.INSERT;\n }\n\n getPrevDataValues() {\n const prevDataValues = fromPairs(map(this.form.prevDataValues, (item) => {\n return [item.key, item.value];\n })); // Convert of array of values to an object\n this.form.formFields.forEach(field => {\n field.value = prevDataValues[field.key] || '';\n field.resetDisplayInput();\n });\n return prevDataValues;\n }\n\n savePrevDataValues() {\n this.form.prevDataValues = this.form.formFields.map((obj) => {\n return {'key': obj.key, 'value': obj.value};\n });\n }\n\n clearData() {\n this.form.toggleMessage(false);\n this.form.emptyDataModel();\n }\n\n setReadonlyFields() {\n this.form.formFields.forEach(field => {\n field.setReadOnlyState();\n });\n }\n\n reset() {\n let prevDataValues;\n this.form.resetFormState();\n prevDataValues = this.getPrevDataValues();\n this.form.formFields.forEach(field => {\n if (field.type === DataType.BLOB || field.widgettype === 'upload') {\n this.form.resetFileUploadWidget(field, true);\n field.href = this.getBlobURL(prevDataValues, field.key, field.value);\n }\n field.nativeElement.querySelector('input')?.removeAttribute('aria-invalid');\n });\n this.form.constructDataObject();\n }\n\n closeDialog() {\n if (this.form.isLayoutDialog) {\n this.dialogService.close(this.form.dialogId);\n }\n }\n\n cancel() {\n this.form.clearMessage();\n this.form.isUpdateMode = false;\n\n this.form.reset();\n /*Show the previous selected data*/\n if (this.form.isSelected) {\n this.getPrevformFields();\n }\n this.form.isUpdateMode = false;\n if (this.form._liveTableParent) {\n this.form._liveTableParent.onCancel();\n } else {\n /*\n WMS-18759: dialog close is calling twice and dialog onHidden subscription is calling once from the library\n due to this if we have another dialog inside liveform and if we click on cancel of second dialog the library\n subscription is calling for both the dialogs.\n */\n this.closeDialog();\n }\n $appDigest();\n }\n\n\n\n delete(callBackFn) {\n this.form.resetFormState();\n this.form.operationType = Live_Operations.DELETE;\n this.form.prevDataObject = getClonedObject(this.form.formdata || {});\n this.form.save(undefined, undefined, undefined, callBackFn);\n }\n\n // Function use to save the form and open new form after save\n saveAndNew() {\n this.save(undefined, true, true);\n }\n // Function use to save the form and open new form after save\n saveAndView() {\n this.save(undefined, false);\n }\n\n submitForm($event) {\n this.save($event);\n }\n\n save(event?, updateMode?, newForm?) {\n if (!this.form.datasource) {\n return;\n }\n let data, prevData, operationType, isValid;\n const requestData: any = {};\n\n operationType = this.form.operationType = this.form.operationType || this.findOperationType();\n\n // Disable the form submit if form is in invalid state.\n if (this.form.validateFieldsOnSubmit()) {\n return;\n }\n\n data = getClonedObject(this.form.constructDataObject());\n prevData = this.form.prevformFields ? this.form.constructDataObject(true) : data;\n\n try {\n isValid = this.form.invokeEventCallback('beforeservicecall', {$event: event, $operation: this.form.operationType, $data: data, options: requestData});\n if (isValid === false) {\n return;\n }\n if (isValid && isValid.error) {\n this.form.toggleMessage(true, isValid.error, 'error');\n return;\n }\n } catch (err) {\n if (err.message === 'Abort') {\n return;\n }\n }\n\n // If operation is update, form is not touched and current data and previous data is same, Show no changes detected message\n if (this.form.operationType === Live_Operations.UPDATE && this.form.ngform && this.form.ngform.pristine &&\n (this.form.isSelected && isEqual(data, prevData))) {\n this.form.toggleMessage(true, this.form.appLocale.MESSAGE_NO_CHANGES, 'info', '');\n $appDigest();\n return;\n }\n\n requestData.row = data;\n requestData.transform = true;\n requestData.skipNotification = true;\n\n if (operationType === Live_Operations.UPDATE) {\n requestData.rowData = this.form.formdata;\n requestData.prevData = prevData;\n }\n\n performDataOperation(this.form.datasource, requestData, {\n operationType: operationType\n }).then((response) => {\n const msg = operationType === Live_Operations.INSERT ? this.form.insertmessage : (operationType === Live_Operations.UPDATE ?\n this.form.updatemessage : this.form.deletemessage);\n let result;\n\n if (operationType === Live_Operations.DELETE) {\n result = requestData.row;\n this.form.emptyDataModel();\n this.form.prevDataValues = [];\n this.form.isSelected = false;\n } else {\n result = response;\n }\n if (!this.form.onSuccess) {\n this.form.toggleMessage(true, msg, 'success');\n }\n if (this.form._liveTableParent) {\n // highlight the current updated row\n this.form._liveTableParent.onResult(operationType, response, newForm, updateMode);\n } else {\n /*get updated data without refreshing page*/\n this.form.datasource.execute(DataSource.Operation.LIST_RECORDS, {\n 'skipToggleState': true\n });\n this.onDataSourceUpdate(response, newForm, updateMode);\n }\n return {\n 'result': result,\n 'status': true\n };\n }, (error) => {\n if (!this.form.onError) {\n this.form.toggleMessage(true, error, 'error');\n }\n $appDigest();\n return {\n 'result': error,\n 'status': false\n };\n }).then(response => {\n // reset the form to pristine state\n this.form.resetFormState();\n this.form.onResultCb(response.result, response.status, event);\n });\n\n\n }\n}\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\n\nimport { WmComponentsModule } from '@wm/components/base';\nimport { BasicModule } from '@wm/components/basic';\nimport { InputModule } from '@wm/components/input';\nimport { DesignDialogModule } from '@wm/components/dialogs/design-dialog';\n\nimport { FormComponent } from './form.component';\nimport { FormWidgetDirective } from './form-widget.directive';\nimport { FormActionDirective } from './form-action/form-action.directive';\nimport { FormFieldDirective } from './form-field/form-field.directive';\nimport { LiveActionsDirective } from './live-actions/live-actions.directive';\nimport { DependsonDirective } from './live-actions/dependson.directive';\nimport { LiveFilterDirective } from './live-filter/live-filter.directive';\nimport { LiveFormDirective } from './live-form/live-form.directive';\n\nconst components = [\n FormComponent,\n FormWidgetDirective,\n FormActionDirective,\n FormFieldDirective,\n LiveActionsDirective,\n DependsonDirective,\n LiveFilterDirective,\n LiveFormDirective\n];\n\n@NgModule({\n imports: [\n BasicModule,\n CommonModule,\n DesignDialogModule,\n InputModule,\n WmComponentsModule\n ],\n declarations: [...components],\n exports: [...components]\n})\nexport class FormModule {\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public_api';\n"],"names":["WIDGET_CONFIG","_debounce","debounce","i2","_c1","registerProps","noop","i1.FormComponent","i3","i4","i1"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAIA,MAAM,QAAQ,GAAG,IAAI,GAAG,CACpB;IACI,CAAC,cAAc,EAAE,EAAC,KAAK,EAAE,KAAK,EAAE,GAAG,YAAY,EAAC,CAAC;IACjD,CAAC,cAAc,EAAE,EAAC,KAAK,EAAE,MAAM,EAAE,GAAG,WAAW,EAAC,CAAC;IACjD,CAAC,iBAAiB,EAAE,EAAC,KAAK,EAAE,MAAM,EAAE,GAAG,WAAW,EAAC,CAAC;IACpD,CAAC,aAAa,EAAE,WAAW,CAAC;IAC5B,CAAC,cAAc,EAAE,EAAC,KAAK,EAAE,sBAAsB,EAAE,GAAG,WAAW,EAAC,CAAC;IACjE,CAAC,OAAO,EAAE,WAAW,CAAC;IACtB,CAAC,aAAa,EAAE,YAAY,CAAC;IAC7B,CAAC,SAAS,EAAE,QAAQ,CAAC;IACrB,CAAC,YAAY,EAAE,WAAW,CAAC;IAC3B,CAAC,UAAU,EAAE,EAAC,KAAK,EAAE,IAAI,EAAE,GAAG,YAAY,EAAC,CAAC;IAC5C,CA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