@colijnit/sharedcomponents 1.0.23 → 1.0.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.browserslistrc +16 -0
- package/.editorconfig +16 -0
- package/.vscode/extensions.json +4 -0
- package/.vscode/launch.json +20 -0
- package/.vscode/tasks.json +42 -0
- package/README.md +11 -8
- package/Sharedcomponents.iml +11 -0
- package/angular.json +133 -0
- package/karma.conf.js +44 -0
- package/move-assets.js +14 -0
- package/package.json +74 -26
- package/projects/sharedcomponents/.browserslistrc +16 -0
- package/projects/sharedcomponents/README.md +24 -0
- package/projects/sharedcomponents/karma.conf.js +44 -0
- package/projects/sharedcomponents/ng-package.json +17 -0
- package/projects/sharedcomponents/package.json +18 -0
- package/projects/sharedcomponents/src/lib/assets/dictionary/text.properties.ts +8 -0
- package/projects/sharedcomponents/src/lib/assets/icons/angle_left_solid.svg +1 -0
- package/projects/sharedcomponents/src/lib/assets/icons/angle_right_solid.svg +1 -0
- package/projects/sharedcomponents/src/lib/assets/icons/arrow_fat_right.svg +1 -0
- package/projects/sharedcomponents/src/lib/assets/icons/arrow_point_left.svg +8 -0
- package/projects/sharedcomponents/src/lib/assets/icons/arrow_point_right.svg +4 -0
- package/projects/sharedcomponents/src/lib/assets/icons/bring_forward_regular.svg +1 -0
- package/projects/sharedcomponents/src/lib/assets/icons/check_round.svg +1 -0
- package/projects/sharedcomponents/src/lib/assets/icons/delete_left_regular.svg +1 -0
- package/projects/sharedcomponents/src/lib/assets/icons/delivery_truck.svg +12 -0
- package/projects/sharedcomponents/src/lib/assets/icons/email.svg +5 -0
- package/projects/sharedcomponents/src/lib/assets/icons/pdf.svg +15 -0
- package/projects/sharedcomponents/src/lib/assets/icons/print.svg +10 -0
- package/projects/sharedcomponents/src/lib/assets/icons/signature_field.svg +9 -0
- package/projects/sharedcomponents/src/lib/assets/icons/xml.svg +9 -0
- package/projects/sharedcomponents/src/lib/components/circular-gauge/co-circular-gauge.component.ts +139 -0
- package/projects/sharedcomponents/src/lib/components/circular-gauge/co-circular-gauge.module.ts +19 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/circular-gauge/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/circular-gauge/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/circular-gauge/style/_theme.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/circular-gauge/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-base-view.component.ts +68 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-day-view.component.ts +31 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-event.component.ts +67 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-events.component.ts +48 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-half-hour-cell.component.ts +81 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-header.component.ts +265 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-hour-cell.component.ts +38 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-hour-view-labels.component.ts +50 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-hour-view.component.ts +46 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-month-view.component.ts +65 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-view.component.ts +38 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-week-select-view.component.ts +63 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/agenda-week-view.component.ts +46 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/style/_layout.scss +443 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/style/_material-definition.scss +11 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/agenda/style/_theme.scss +7 -0
- package/{lib/components/layout-switcher → projects/sharedcomponents/src/lib/components/date-planning/component/agenda}/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/calendar/calendar-all-months.component.ts +37 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/calendar/calendar-all-years.component.ts +52 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/calendar/calendar-header.component.ts +124 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/calendar/calendar-view.component.ts +201 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/calendar/calendar.component.ts +35 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/calendar/style/_layout.scss +167 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/calendar/style/_material-definition.scss +7 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/component/calendar/style/_theme.scss +7 -0
- package/{lib/components/linear-gauge → projects/sharedcomponents/src/lib/components/date-planning/component/calendar}/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/date-planning.component.ts +133 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/date-planning.module.ts +56 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/style/_layout.scss +47 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/style/_material-definition.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/style/_theme.scss +7 -0
- package/projects/sharedcomponents/src/lib/components/date-planning/style/material.scss +5 -0
- package/projects/sharedcomponents/src/lib/components/docsign/component/signature/signature.component.ts +82 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/component/signature/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/component/signature/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/component/signature/style/_theme.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/component/signature/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/docsign/component/signatures/signatures.component.ts +50 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/component/signatures/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/component/signatures/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/component/signatures/style/_theme.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/component/signatures/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/docsign/docsign.component.ts +252 -0
- package/projects/sharedcomponents/src/lib/components/docsign/docsign.module.ts +22 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/style/_theme.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/docsign/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/key-pad/key-pad.component.ts +205 -0
- package/projects/sharedcomponents/src/lib/components/key-pad/key-pad.module.ts +19 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/key-pad/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/key-pad/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/key-pad/style/_theme.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/key-pad/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/layout-switcher/layout-switcher.component.ts +98 -0
- package/projects/sharedcomponents/src/lib/components/layout-switcher/layout-switcher.module.ts +21 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/layout-switcher/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/layout-switcher/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/layout-switcher/style/_theme.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/layout-switcher/style/material.scss +5 -0
- package/projects/sharedcomponents/src/lib/components/linear-gauge/co-linear-gauge.component.ts +56 -0
- package/projects/sharedcomponents/src/lib/components/linear-gauge/co-linear-gauge.module.ts +17 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/linear-gauge/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/linear-gauge/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/linear-gauge/style/_theme.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/linear-gauge/style/material.scss +5 -0
- package/projects/sharedcomponents/src/lib/components/send-method-dialog/enums/send-option.ts +6 -0
- package/projects/sharedcomponents/src/lib/components/send-method-dialog/send-method-dialog.component.ts +342 -0
- package/projects/sharedcomponents/src/lib/components/send-method-dialog/send-method-dialog.module.ts +33 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/send-method-dialog/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/send-method-dialog/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/send-method-dialog/style/_theme.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/send-method-dialog/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/statusbar/statusbar.component.ts +97 -0
- package/projects/sharedcomponents/src/lib/components/statusbar/statusbar.module.ts +21 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/statusbar/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/statusbar/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/statusbar/style/_theme.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/statusbar/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/components/stock/stock-in-order/stock-in-order.component.ts +0 -0
- package/projects/sharedcomponents/src/lib/components/stock/stock-information/stock-information.component.ts +64 -0
- package/projects/sharedcomponents/src/lib/components/stock/stock-information-grid/stock-information-grid.component.ts +384 -0
- package/projects/sharedcomponents/src/lib/components/stock/stock-location/stock-location.component.ts +84 -0
- package/{lib/components/stock/stock-transfer/co-drop-down-list-fields.interface.d.ts → projects/sharedcomponents/src/lib/components/stock/stock-transfer/co-drop-down-list-fields.interface.ts} +2 -2
- package/projects/sharedcomponents/src/lib/components/stock/stock-transfer/stock-change-amount.component.ts +73 -0
- package/projects/sharedcomponents/src/lib/components/stock/stock-transfer/stock-transfer.component.ts +153 -0
- package/projects/sharedcomponents/src/lib/components/stock/stock.component.ts +165 -0
- package/projects/sharedcomponents/src/lib/components/stock/stock.module.ts +51 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/stock/style/_layout.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/stock/style/_material-definition.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/stock/style/_theme.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/components/stock/style/material.scss +0 -0
- package/projects/sharedcomponents/src/lib/enum/calendar-view.enum.ts +6 -0
- package/{lib/enum/icon.enum.d.ts → projects/sharedcomponents/src/lib/enum/icon.enum.ts} +5 -2
- package/projects/sharedcomponents/src/lib/enum/keyboard-code.enum.ts +30 -0
- package/projects/sharedcomponents/src/lib/enum/language-code.enum.ts +6 -0
- package/projects/sharedcomponents/src/lib/enum/month.enum.ts +15 -0
- package/projects/sharedcomponents/src/lib/enum/time-period.enum.ts +9 -0
- package/projects/sharedcomponents/src/lib/factory/business-object-factory.ts +120 -0
- package/projects/sharedcomponents/src/lib/factory/decorators/boolean.decorator.ts +113 -0
- package/projects/sharedcomponents/src/lib/factory/decorators/complex-array.decorator.ts +61 -0
- package/projects/sharedcomponents/src/lib/factory/decorators/complex-field.decorator.ts +63 -0
- package/projects/sharedcomponents/src/lib/factory/decorators/date-field.decorator.ts +41 -0
- package/projects/sharedcomponents/src/lib/factory/decorators/string-number.decorator.ts +48 -0
- package/projects/sharedcomponents/src/lib/model/agenda-event-per-day.model.ts +6 -0
- package/projects/sharedcomponents/src/lib/model/agenda-event.model.ts +17 -0
- package/projects/sharedcomponents/src/lib/model/agenda-null-objects.ts +11 -0
- package/projects/sharedcomponents/src/lib/model/business-object.ts +85 -0
- package/projects/sharedcomponents/src/lib/model/constant/all-months.ts +17 -0
- package/projects/sharedcomponents/src/lib/model/date-range.ts +10 -0
- package/projects/sharedcomponents/src/lib/model/day.model.ts +9 -0
- package/projects/sharedcomponents/src/lib/model/icon-svg.ts +18 -0
- package/projects/sharedcomponents/src/lib/model/month.model.ts +11 -0
- package/projects/sharedcomponents/src/lib/model/time-window.bo.ts +21 -0
- package/projects/sharedcomponents/src/lib/model/week.model.ts +5 -0
- package/projects/sharedcomponents/src/lib/model/weekday.model.ts +17 -0
- package/projects/sharedcomponents/src/lib/pipe/array-number.pipe.ts +14 -0
- package/projects/sharedcomponents/src/lib/pipe/master-pipes.ts +7 -0
- package/projects/sharedcomponents/src/lib/pipe/ucfirst.pipe.ts +14 -0
- package/projects/sharedcomponents/src/lib/service/dictionary.service.ts +86 -0
- package/projects/sharedcomponents/src/lib/service/icon-cache.service.ts +51 -0
- package/projects/sharedcomponents/src/lib/service/options.service.ts +66 -0
- package/projects/sharedcomponents/src/lib/service/shared-connector.service.ts +258 -0
- package/projects/sharedcomponents/src/lib/service/shared-initializer.service.ts +29 -0
- package/projects/sharedcomponents/src/lib/service/shared.service.ts +21 -0
- package/projects/sharedcomponents/src/lib/service/stock.service.ts +95 -0
- package/{lib → projects/sharedcomponents/src/lib}/style/_mixin.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/style/_variables.scss +0 -0
- package/{lib → projects/sharedcomponents/src/lib}/style/sharedcomponents-globals.scss +0 -0
- package/projects/sharedcomponents/src/lib/utils/array-utils.ts +202 -0
- package/projects/sharedcomponents/src/lib/utils/calendar.utils.ts +75 -0
- package/projects/sharedcomponents/src/lib/utils/date-utils.ts +302 -0
- package/projects/sharedcomponents/src/lib/utils/function/not-nill.function.ts +4 -0
- package/projects/sharedcomponents/src/lib/utils/is-nill.function.ts +4 -0
- package/projects/sharedcomponents/src/lib/utils/string-utils.ts +67 -0
- package/{public-api.d.ts → projects/sharedcomponents/src/public-api.ts} +5 -0
- package/projects/sharedcomponents/src/test.ts +27 -0
- package/projects/sharedcomponents/tsconfig.lib.json +18 -0
- package/projects/sharedcomponents/tsconfig.lib.prod.json +10 -0
- package/projects/sharedcomponents/tsconfig.spec.json +17 -0
- package/script/merge-icons.js +39 -0
- package/src/app/app.component.scss +9 -0
- package/src/app/app.component.spec.ts +31 -0
- package/src/app/app.component.ts +156 -0
- package/src/app/app.module.ts +60 -0
- package/src/assets/.gitkeep +0 -0
- package/src/environments/environment.prod.ts +3 -0
- package/src/environments/environment.ts +16 -0
- package/src/favicon.ico +0 -0
- package/src/index.html +13 -0
- package/src/main.ts +12 -0
- package/src/polyfills.ts +53 -0
- package/src/styles.scss +40 -0
- package/src/test.ts +26 -0
- package/tsconfig.app.json +15 -0
- package/tsconfig.json +65 -0
- package/tsconfig.spec.json +18 -0
- package/bundles/colijnit-sharedcomponents.umd.js +0 -3701
- package/bundles/colijnit-sharedcomponents.umd.js.map +0 -1
- package/colijnit-sharedcomponents-1.0.23.tgz +0 -0
- package/colijnit-sharedcomponents.d.ts +0 -16
- package/colijnit-sharedcomponents.metadata.json +0 -1
- package/esm2015/colijnit-sharedcomponents.js +0 -17
- package/esm2015/lib/assets/dictionary/text.properties.js +0 -11
- package/esm2015/lib/components/circular-gauge/co-circular-gauge.component.js +0 -125
- package/esm2015/lib/components/circular-gauge/co-circular-gauge.module.js +0 -21
- package/esm2015/lib/components/docsign/component/signature/signature.component.js +0 -75
- package/esm2015/lib/components/docsign/component/signatures/signatures.component.js +0 -44
- package/esm2015/lib/components/docsign/docsign.component.js +0 -225
- package/esm2015/lib/components/docsign/docsign.module.js +0 -23
- package/esm2015/lib/components/key-pad/key-pad.component.js +0 -191
- package/esm2015/lib/components/key-pad/key-pad.module.js +0 -21
- package/esm2015/lib/components/layout-switcher/layout-switcher.component.js +0 -74
- package/esm2015/lib/components/layout-switcher/layout-switcher.module.js +0 -21
- package/esm2015/lib/components/linear-gauge/co-linear-gauge.component.js +0 -55
- package/esm2015/lib/components/linear-gauge/co-linear-gauge.module.js +0 -19
- package/esm2015/lib/components/send-method-dialog/enums/send-option.js +0 -8
- package/esm2015/lib/components/send-method-dialog/send-method-dialog.component.js +0 -309
- package/esm2015/lib/components/send-method-dialog/send-method-dialog.module.js +0 -31
- package/esm2015/lib/components/statusbar/statusbar.component.js +0 -81
- package/esm2015/lib/components/statusbar/statusbar.module.js +0 -23
- package/esm2015/lib/components/stock/stock-information/stock-information.component.js +0 -54
- package/esm2015/lib/components/stock/stock-information-grid/stock-information-grid.component.js +0 -350
- package/esm2015/lib/components/stock/stock-location/stock-location.component.js +0 -62
- package/esm2015/lib/components/stock/stock-transfer/co-drop-down-list-fields.interface.js +0 -2
- package/esm2015/lib/components/stock/stock-transfer/stock-change-amount.component.js +0 -68
- package/esm2015/lib/components/stock/stock-transfer/stock-transfer.component.js +0 -130
- package/esm2015/lib/components/stock/stock.component.js +0 -140
- package/esm2015/lib/components/stock/stock.module.js +0 -48
- package/esm2015/lib/enum/icon.enum.js +0 -17
- package/esm2015/lib/enum/keyboard-code.enum.js +0 -32
- package/esm2015/lib/enum/language-code.enum.js +0 -8
- package/esm2015/lib/factory/business-object-factory.js +0 -120
- package/esm2015/lib/factory/decorators/boolean.decorator.js +0 -102
- package/esm2015/lib/factory/decorators/complex-array.decorator.js +0 -55
- package/esm2015/lib/factory/decorators/complex-field.decorator.js +0 -57
- package/esm2015/lib/factory/decorators/date-field.decorator.js +0 -36
- package/esm2015/lib/factory/decorators/string-number.decorator.js +0 -43
- package/esm2015/lib/model/business-object.js +0 -81
- package/esm2015/lib/model/icon-svg.js +0 -16
- package/esm2015/lib/service/dictionary.service.js +0 -76
- package/esm2015/lib/service/icon-cache.service.js +0 -51
- package/esm2015/lib/service/options.service.js +0 -71
- package/esm2015/lib/service/shared-connector.service.js +0 -278
- package/esm2015/lib/service/shared.service.js +0 -30
- package/esm2015/lib/service/stock.service.js +0 -95
- package/esm2015/lib/utils/array-utils.js +0 -183
- package/esm2015/lib/utils/is-nill.function.js +0 -5
- package/esm2015/lib/utils/string-utils.js +0 -64
- package/esm2015/public-api.js +0 -21
- package/fesm2015/colijnit-sharedcomponents.js +0 -3511
- package/fesm2015/colijnit-sharedcomponents.js.map +0 -1
- package/lib/assets/dictionary/text.properties.d.ts +0 -3
- package/lib/components/circular-gauge/co-circular-gauge.component.d.ts +0 -20
- package/lib/components/circular-gauge/co-circular-gauge.module.d.ts +0 -2
- package/lib/components/docsign/component/signature/signature.component.d.ts +0 -16
- package/lib/components/docsign/component/signatures/signatures.component.d.ts +0 -12
- package/lib/components/docsign/docsign.component.d.ts +0 -92
- package/lib/components/docsign/docsign.module.d.ts +0 -2
- package/lib/components/key-pad/key-pad.component.d.ts +0 -36
- package/lib/components/key-pad/key-pad.module.d.ts +0 -2
- package/lib/components/layout-switcher/layout-switcher.component.d.ts +0 -16
- package/lib/components/layout-switcher/layout-switcher.module.d.ts +0 -2
- package/lib/components/linear-gauge/co-linear-gauge.component.d.ts +0 -16
- package/lib/components/linear-gauge/co-linear-gauge.module.d.ts +0 -2
- package/lib/components/send-method-dialog/enums/send-option.d.ts +0 -6
- package/lib/components/send-method-dialog/send-method-dialog.component.d.ts +0 -62
- package/lib/components/send-method-dialog/send-method-dialog.module.d.ts +0 -2
- package/lib/components/statusbar/statusbar.component.d.ts +0 -23
- package/lib/components/statusbar/statusbar.module.d.ts +0 -2
- package/lib/components/stock/stock-information/stock-information.component.d.ts +0 -10
- package/lib/components/stock/stock-information-grid/stock-information-grid.component.d.ts +0 -60
- package/lib/components/stock/stock-location/stock-location.component.d.ts +0 -15
- package/lib/components/stock/stock-transfer/stock-change-amount.component.d.ts +0 -18
- package/lib/components/stock/stock-transfer/stock-transfer.component.d.ts +0 -36
- package/lib/components/stock/stock.component.d.ts +0 -42
- package/lib/components/stock/stock.module.d.ts +0 -2
- package/lib/enum/keyboard-code.enum.d.ts +0 -30
- package/lib/enum/language-code.enum.d.ts +0 -6
- package/lib/factory/business-object-factory.d.ts +0 -23
- package/lib/factory/decorators/boolean.decorator.d.ts +0 -43
- package/lib/factory/decorators/complex-array.decorator.d.ts +0 -25
- package/lib/factory/decorators/complex-field.decorator.d.ts +0 -25
- package/lib/factory/decorators/date-field.decorator.d.ts +0 -17
- package/lib/factory/decorators/string-number.decorator.d.ts +0 -22
- package/lib/model/business-object.d.ts +0 -7
- package/lib/model/icon-svg.d.ts +0 -4
- package/lib/service/dictionary.service.d.ts +0 -21
- package/lib/service/icon-cache.service.d.ts +0 -18
- package/lib/service/options.service.d.ts +0 -13
- package/lib/service/shared-connector.service.d.ts +0 -43
- package/lib/service/shared.service.d.ts +0 -8
- package/lib/service/stock.service.d.ts +0 -38
- package/lib/utils/array-utils.d.ts +0 -57
- package/lib/utils/is-nill.function.d.ts +0 -1
- package/lib/utils/string-utils.d.ts +0 -22
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
import {GetYesNoDbBooleanValue} from "@colijnit/articleapi/build/enum/yes-no-db-type.enum";
|
|
2
|
+
import {GetTrueFalseDbBooleanValue} from "@colijnit/articleapi/build/enum/true-false-db-type.enum";
|
|
3
|
+
import {GetOneZeroDbBooleanValue} from "@colijnit/articleapi/build/enum/one-zero-bool-db-type.enum";
|
|
4
|
+
import {DbBooleanValueType, GetLogicalBooleanValue} from "@colijnit/articleapi/build/enum/db-boolean-value-type.enum";
|
|
5
|
+
|
|
6
|
+
const PROP_META_KEY_JN: string = "booleanTextJN";
|
|
7
|
+
const PROP_META_KEY_TF: string = "booleanTextTF";
|
|
8
|
+
const PROP_META_KEY_10: string = "booleanText10";
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* There are 'J', 'T', 'N', 'F', 0 and 1 'boolean values' in the database. These should be translated to true and false boolean values in
|
|
12
|
+
* our client application.
|
|
13
|
+
*
|
|
14
|
+
* The values 'J' and 'N' seem to be most commonly used. This is the default setting when using this decorator.
|
|
15
|
+
* You can pass 'T' or 1 for the other variants as follows:
|
|
16
|
+
*
|
|
17
|
+
* Usage:
|
|
18
|
+
*
|
|
19
|
+
* @BooleanText() or @BooleanText("J") (the default, uses YesNoDbType char values)
|
|
20
|
+
* public foo: boolean // 'J' and 'N' become true and false after BusinessObjectFactoryService and -SerializerService processing
|
|
21
|
+
*
|
|
22
|
+
* @BooleanText('T') (uses TrueFalseDbType char values)
|
|
23
|
+
* public bar: boolean // 'T' and 'F' become true and false after BusinessObjectFactoryService and -SerializerService processing
|
|
24
|
+
*
|
|
25
|
+
* @BooleanText(1)
|
|
26
|
+
* public baz: boolean // 1 and 0 become true and false after BusinessObjectFactoryService and -SerializerService processing
|
|
27
|
+
*/
|
|
28
|
+
export function BooleanText(type?: "J" | "T" | 1): PropertyDecorator {
|
|
29
|
+
return function (target: any, propertyKey: string): void {
|
|
30
|
+
if (!target || !propertyKey) {
|
|
31
|
+
return;
|
|
32
|
+
}
|
|
33
|
+
// by default, it's a J N boolean text
|
|
34
|
+
if (!type || type === "J") {
|
|
35
|
+
Reflect.defineMetadata(PROP_META_KEY_JN, true, target, propertyKey);
|
|
36
|
+
} else if (type === "T") {
|
|
37
|
+
Reflect.defineMetadata(PROP_META_KEY_TF, true, target, propertyKey);
|
|
38
|
+
} else if (type === 1) {
|
|
39
|
+
Reflect.defineMetadata(PROP_META_KEY_10, true, target, propertyKey);
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
|
|
44
|
+
// Utility function holder of the BooleanTextDecorator decorator.
|
|
45
|
+
export class BooleanTextDecorator {
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Returns whether given property (as a string) on given object is a boolean text field. That is, it's a field that is decorated
|
|
49
|
+
* with the @BooleanText decorator.
|
|
50
|
+
*/
|
|
51
|
+
public static IsBooleanTextField(target: Object, propertyKey: string): boolean {
|
|
52
|
+
if (!target || !propertyKey || typeof target !== "object") {
|
|
53
|
+
return false;
|
|
54
|
+
}
|
|
55
|
+
return (
|
|
56
|
+
Reflect.getMetadata(PROP_META_KEY_JN, target, propertyKey) === true
|
|
57
|
+
||
|
|
58
|
+
Reflect.getMetadata(PROP_META_KEY_TF, target, propertyKey) === true
|
|
59
|
+
||
|
|
60
|
+
Reflect.getMetadata(PROP_META_KEY_10, target, propertyKey) === true
|
|
61
|
+
);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
/**
|
|
65
|
+
* Returns the logical true or false value of given character ('J', 'N', 'T' or 'F') or number (0 or 1).
|
|
66
|
+
* Returns UNDEFINED if given boolChar was not recognised as a boolean text.
|
|
67
|
+
*/
|
|
68
|
+
public static GetLogicalBooleanValue(dbBoolChar: DbBooleanValueType | string): boolean {
|
|
69
|
+
return GetLogicalBooleanValue(dbBoolChar);
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
/**
|
|
73
|
+
* Returns the boolean character / number of given logical bool property on target object. Uses its @BooleanText() annotation to decide
|
|
74
|
+
* what character / number to return.
|
|
75
|
+
* Used in BusinessObjectSerializerServiceService to convert logical bools to their original boolean character.
|
|
76
|
+
* @returns {string|number} The original, reverse-engineered boolean character (or number) of given object property, or undefined.
|
|
77
|
+
*/
|
|
78
|
+
public static GetDbBooleanValue(target: Object, propertyKey: string): DbBooleanValueType {
|
|
79
|
+
if (!target || !propertyKey || typeof target !== "object") {
|
|
80
|
+
return undefined;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
let dbBoolVal: any = undefined;
|
|
84
|
+
|
|
85
|
+
const curBoolVal: boolean = target[propertyKey];
|
|
86
|
+
|
|
87
|
+
if (BooleanTextDecorator._IsJaNeeProp(target, propertyKey)) {
|
|
88
|
+
dbBoolVal = GetYesNoDbBooleanValue(curBoolVal);
|
|
89
|
+
} else if (BooleanTextDecorator._IsTrueFalseProp(target, propertyKey)) {
|
|
90
|
+
dbBoolVal = GetTrueFalseDbBooleanValue(curBoolVal);
|
|
91
|
+
} else if (BooleanTextDecorator._IsZeroOneProp(target, propertyKey)) {
|
|
92
|
+
dbBoolVal = GetOneZeroDbBooleanValue(curBoolVal);
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
return dbBoolVal as any as DbBooleanValueType;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
private static _IsJaNeeProp(target: Object, propertyKey: string): boolean {
|
|
99
|
+
return BooleanTextDecorator._IsProp(PROP_META_KEY_JN, target, propertyKey);
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
private static _IsTrueFalseProp(target: Object, propertyKey: string): boolean {
|
|
103
|
+
return BooleanTextDecorator._IsProp(PROP_META_KEY_TF, target, propertyKey);
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
private static _IsZeroOneProp(target: Object, propertyKey: string): boolean {
|
|
107
|
+
return BooleanTextDecorator._IsProp(PROP_META_KEY_10, target, propertyKey);
|
|
108
|
+
}
|
|
109
|
+
|
|
110
|
+
private static _IsProp(prop: string, target: Object, propertyKey: string): boolean {
|
|
111
|
+
return !!target && !!propertyKey && typeof target === "object" && Reflect.hasMetadata(prop, target, propertyKey);
|
|
112
|
+
}
|
|
113
|
+
}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import {notNill} from "@colijnit/articleapi/build/utils/function/not-nill.function";
|
|
2
|
+
import {ObjectUtils} from "@colijnit/articleapi/build/utils/object-utils";
|
|
3
|
+
|
|
4
|
+
const PROP_META_KEY: string = "complexArray";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* !! just a TAG DECORATOR for now, there is no code that uses this meta data within the ione connector lib itself.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Property decorator for properties of businessobject classes that are an array of other strongly typed businessobjects.
|
|
12
|
+
* Ensures that the BusinessObjectFactoryService makes properly typed objects from incoming raw persistence data. Otherwise we couldn't add methods
|
|
13
|
+
* to our own businessobjects and use them, since all fields would be flat data without methods after BusinessObjectFactoryService creation.
|
|
14
|
+
*
|
|
15
|
+
* Usage:
|
|
16
|
+
*
|
|
17
|
+
* @ComplexArray(TransactionLine)
|
|
18
|
+
* public transactionLines: TransactionLine[]
|
|
19
|
+
*/
|
|
20
|
+
export function ComplexArray(type: any): PropertyDecorator {
|
|
21
|
+
return function (target: any, propertyKey: string): void {
|
|
22
|
+
if (!target || !propertyKey || typeof target !== "object") {
|
|
23
|
+
return;
|
|
24
|
+
}
|
|
25
|
+
// warn the programmer if given type was undefined; it's probably an import order glitch that caused this, because decorators seem
|
|
26
|
+
// to be immediately processed when a class is first imported
|
|
27
|
+
if (!type) {
|
|
28
|
+
console.warn(`@ComplexArray(type): type was UNDEFINED. Called on prop (${ObjectUtils.GetClassName(target)}, ${propertyKey}). ` +
|
|
29
|
+
`Class will not properly serialize and deserialize now. We've always been able to fix this by CHANGING IMPORT ORDERS ` +
|
|
30
|
+
`where both classes and their dependencies are used, e.g. factory, repository or models..`);
|
|
31
|
+
return;
|
|
32
|
+
}
|
|
33
|
+
Reflect.defineMetadata(PROP_META_KEY, type, target, propertyKey);
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
// Utility function holder of the ComplexArrayDecorator decorator.
|
|
38
|
+
export class ComplexArrayDecorator {
|
|
39
|
+
/**
|
|
40
|
+
* Returns whether given property (as a string) on given object is a complex array. A complex array is an array field that is decorated
|
|
41
|
+
* with the @ComplexArray decorator.
|
|
42
|
+
*/
|
|
43
|
+
public static IsComplexArray(target: Object, propertyKey: string): boolean {
|
|
44
|
+
if (!target || !propertyKey || typeof target !== "object") {
|
|
45
|
+
return false;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
return (notNill(Reflect.getMetadata(PROP_META_KEY, target, propertyKey)));
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
/**
|
|
52
|
+
* Returns the VALUE of the @ComplexArray(VALUE) property decorator on the given propertyKey on the given modelobject.
|
|
53
|
+
*/
|
|
54
|
+
public static GetComplexArrayType(target: Object, propertyKey: string): any {
|
|
55
|
+
if (!target || !propertyKey || typeof target !== "object") {
|
|
56
|
+
return undefined;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
return Reflect.getMetadata(PROP_META_KEY, target, propertyKey);
|
|
60
|
+
}
|
|
61
|
+
}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import {notNill} from "@colijnit/articleapi/build/utils/function/not-nill.function";
|
|
2
|
+
import {ObjectUtils} from "@colijnit/articleapi/build/utils/object-utils";
|
|
3
|
+
|
|
4
|
+
const PROP_META_KEY: string = "complexField";
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* !! just a TAG DECORATOR for now, there is no code that uses this meta data within the ione connector lib itself.
|
|
8
|
+
*/
|
|
9
|
+
|
|
10
|
+
/**
|
|
11
|
+
* Property decorator for properties of businessobject classes that are other strongly typed businessobjects.
|
|
12
|
+
* Ensures that the BusinessObjectFactoryService makes properly typed objects from incoming raw persistence data. Otherwise we couldn't add methods
|
|
13
|
+
* to our own businessobjects and use them, since all fields would be flat data without methods after BusinessObjectFactoryService creation.
|
|
14
|
+
*
|
|
15
|
+
* Usage:
|
|
16
|
+
*
|
|
17
|
+
* @ComplexField(Transaction)
|
|
18
|
+
* public transaction: Transaction
|
|
19
|
+
*
|
|
20
|
+
* Also keeps track of a "complexFieldProps" metadata on the class-level, as a reflect-metadata workaround to be able to
|
|
21
|
+
* retrieve all properties that have the @ComplexField(..) decorator (impossible with current Reflect API).
|
|
22
|
+
*/
|
|
23
|
+
export function ComplexField(type: any): PropertyDecorator {
|
|
24
|
+
return function (target: any, propertyKey: string): void {
|
|
25
|
+
if (!target || !propertyKey) {
|
|
26
|
+
return;
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
// warn the programmer if given type was undefined; it's probably an import order glitch that caused this, because decorators seem
|
|
30
|
+
// to be immediately processed when a class is first imported
|
|
31
|
+
if (!type) {
|
|
32
|
+
// eslint-disable-next-line no-console
|
|
33
|
+
console.warn(`@ComplexField(type): type was UNDEFINED. Called on prop (${ObjectUtils.GetClassName(target)}, ${propertyKey}). ` +
|
|
34
|
+
`Class will not properly serialize and deserialize now. We've always been able to fix this by CHANGING IMPORT ORDERS ` +
|
|
35
|
+
`where both classes and their dependencies are used, e.g. factory, repository or models..`);
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
Reflect.defineMetadata(PROP_META_KEY, type, target, propertyKey);
|
|
39
|
+
};
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
// Utility function holder of the ComplexFieldDecorator decorator.
|
|
43
|
+
export class ComplexFieldDecorator {
|
|
44
|
+
|
|
45
|
+
/**
|
|
46
|
+
* Returns whether given property (as a string) on given object is a complex field. A complex field is a field that is decorated
|
|
47
|
+
* with the @ComplexField decorator.
|
|
48
|
+
*/
|
|
49
|
+
public static IsComplexField(target: Object, propertyKey: string): boolean {
|
|
50
|
+
if (!target || !propertyKey || typeof target !== "object") {
|
|
51
|
+
return false;
|
|
52
|
+
}
|
|
53
|
+
return (notNill(Reflect.getMetadata(PROP_META_KEY, target, propertyKey)));
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
// Returns the VALUE of the @ComplexField(VALUE) property decorator on the given propertyKey on the given modelObject.
|
|
57
|
+
public static GetComplexFieldType(target: Object, propertyKey: string): any {
|
|
58
|
+
if (!target || !propertyKey || typeof target !== "object") {
|
|
59
|
+
return undefined;
|
|
60
|
+
}
|
|
61
|
+
return Reflect.getMetadata(PROP_META_KEY, target, propertyKey);
|
|
62
|
+
}
|
|
63
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import {DateUtils} from "@colijnit/articleapi/build/utils/date-utils";
|
|
2
|
+
|
|
3
|
+
const PROP_META_KEY: string = "dateField";
|
|
4
|
+
|
|
5
|
+
/**
|
|
6
|
+
* !! just a TAG DECORATOR for now, there is no code that uses this meta data within the ione connector lib itself.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Property decorator for properties of businessobject classes that are of type Date, but are sent to us as strings.
|
|
11
|
+
* Ensures that the BusinessObjectFactory makes proper JavaScript Date objects from incoming strings for @DateField() decorated properties.
|
|
12
|
+
*
|
|
13
|
+
* Usage:
|
|
14
|
+
*
|
|
15
|
+
* @DateField()
|
|
16
|
+
* public expectedDeliveryDate: Date
|
|
17
|
+
*/
|
|
18
|
+
export function DateField(): PropertyDecorator {
|
|
19
|
+
return function (target: any, propertyKey: string): void {
|
|
20
|
+
if (!target || !propertyKey) {
|
|
21
|
+
return;
|
|
22
|
+
}
|
|
23
|
+
Reflect.defineMetadata(PROP_META_KEY, undefined, target, propertyKey);
|
|
24
|
+
};
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
// Utility function holder of the @DateField() decorator.
|
|
28
|
+
export class DateFieldFieldDecorator {
|
|
29
|
+
|
|
30
|
+
// Returns whether given property (as a string) on given object is decorated with @DateField().
|
|
31
|
+
public static IsDateField(target: Object, propertyKey: string): boolean {
|
|
32
|
+
if (!target || !propertyKey || typeof target !== "object") {
|
|
33
|
+
return false;
|
|
34
|
+
}
|
|
35
|
+
return Reflect.hasMetadata(PROP_META_KEY, target, propertyKey);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
public static StringAsDate(str: string): Date {
|
|
39
|
+
return DateUtils.StringAsDate(str);
|
|
40
|
+
}
|
|
41
|
+
}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import {NumberUtils} from "@colijnit/articleapi/build/utils/number-utils";
|
|
2
|
+
|
|
3
|
+
const PROP_META_KEY: string = "stringNumber";
|
|
4
|
+
/**
|
|
5
|
+
* !! just a TAG DECORATOR for now, there is no code that uses this meta data within the ione connector lib itself.
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* Decorator for properties of businessobjects that are sent to us as strings from the database, but which we want to use as a number in the client.
|
|
10
|
+
*
|
|
11
|
+
* Can be handy for incongruent backend api cases, where id data types are communicated wrongly via strings instead of numbers
|
|
12
|
+
* (e.g. on EmployeeFullObject.district, points to a District which has a number id, but in employee it's a string representation of that number...)
|
|
13
|
+
*
|
|
14
|
+
* Used by business object factory and -serializer.
|
|
15
|
+
*
|
|
16
|
+
* Usage:
|
|
17
|
+
*
|
|
18
|
+
* @StringNumber()
|
|
19
|
+
* public rights: UserRightType
|
|
20
|
+
*/
|
|
21
|
+
export function StringNumber(): PropertyDecorator {
|
|
22
|
+
return function (target: any, propertyKey: string): void {
|
|
23
|
+
if (!target || !propertyKey) {
|
|
24
|
+
return;
|
|
25
|
+
}
|
|
26
|
+
Reflect.defineMetadata(PROP_META_KEY, undefined, target, propertyKey);
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
// Utility function holder of the @StringNumber() decorator.
|
|
31
|
+
export class StringNumberDecorator {
|
|
32
|
+
|
|
33
|
+
// Returns whether given property (as a string) on given object is decorated with @StringNumber().
|
|
34
|
+
public static IsStringNumber(target: Object, propertyKey: string): boolean {
|
|
35
|
+
if (!target || !propertyKey || typeof target !== "object") {
|
|
36
|
+
return false;
|
|
37
|
+
}
|
|
38
|
+
return Reflect.hasMetadata(PROP_META_KEY, target, propertyKey);
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
public static StringAsNumber(str: string): number {
|
|
42
|
+
return NumberUtils.ParseFloatKeepPrecision(str);
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
public static NumberAsString(nr: number): string {
|
|
46
|
+
return "" + nr;
|
|
47
|
+
}
|
|
48
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import {TimeWindow} from "./time-window.bo";
|
|
2
|
+
|
|
3
|
+
export class AgendaEvent {
|
|
4
|
+
public id: number;
|
|
5
|
+
public description: string;
|
|
6
|
+
public checked: boolean = false;
|
|
7
|
+
public showCheckbox: boolean = false;
|
|
8
|
+
public draggable: boolean = false;
|
|
9
|
+
public from: Date;
|
|
10
|
+
public to: Date;
|
|
11
|
+
public date: Date;
|
|
12
|
+
public dayPartNo: number;
|
|
13
|
+
public fromString: string;
|
|
14
|
+
public toString: string;
|
|
15
|
+
public fromToRepresentation: string;
|
|
16
|
+
public timeWindow: TimeWindow;
|
|
17
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import {AgendaEvent} from "./agenda-event.model";
|
|
2
|
+
import {AgendaEventPerDay} from "./agenda-event-per-day.model";
|
|
3
|
+
import {Month} from "./month.model";
|
|
4
|
+
import {Week} from "./week.model";
|
|
5
|
+
import {Day} from "./day.model";
|
|
6
|
+
|
|
7
|
+
export const NULL_AGENDA_EVENT: AgendaEvent = new AgendaEvent();
|
|
8
|
+
export const NULL_AGENDA_EVENT_PER_DAY: AgendaEventPerDay = new AgendaEventPerDay();
|
|
9
|
+
export const NULL_MONTH: Month = new Month();
|
|
10
|
+
export const NULL_WEEK: Week = new Week();
|
|
11
|
+
export const NULL_DAY: Day = new Day();
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This type represents the concept of a business object ID type. ID's of business objects can be a primary number, a simple string or a
|
|
3
|
+
* object for a composite key.
|
|
4
|
+
*
|
|
5
|
+
* Simply to prevent type declarations of 'number | string | Object' for BO ID data all over the application.
|
|
6
|
+
*/
|
|
7
|
+
import {MapPropertyDecorator} from "@colijnit/articleapi/build/factory/decorators/map-property.decorator";
|
|
8
|
+
import {BooleanTextDecorator} from "@colijnit/articleapi/build/factory/decorators/boolean.decorator";
|
|
9
|
+
import {JsonFieldFieldDecorator} from "@colijnit/articleapi/build/factory/decorators/json.decorator";
|
|
10
|
+
import {ComplexArrayDecorator} from "@colijnit/articleapi/build/factory/decorators/complex-array.decorator";
|
|
11
|
+
|
|
12
|
+
export type BusinessObjectIDType = number | string | Object;
|
|
13
|
+
|
|
14
|
+
export abstract class BusinessObject {
|
|
15
|
+
// The ID of the model.
|
|
16
|
+
public id: BusinessObjectIDType;
|
|
17
|
+
|
|
18
|
+
// Overridable. Returns the ID of the model. Concrete model classes often override this method to provide their specific ID getter.
|
|
19
|
+
public getId(): BusinessObjectIDType {
|
|
20
|
+
return this.id;
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
constructor() {
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
protected setOwnMappedPropsFromRawData(rawData: any = {}): void {
|
|
27
|
+
if (!rawData) {
|
|
28
|
+
return;
|
|
29
|
+
}
|
|
30
|
+
Object.keys(this).forEach((key) => {
|
|
31
|
+
// check if property needs to be mapped
|
|
32
|
+
if (MapPropertyDecorator.IsMapProperty(this, key)) {
|
|
33
|
+
const mapKeys: string[] = MapPropertyDecorator.GetMapProperty(this, key).split(",");
|
|
34
|
+
const len: number = mapKeys.length;
|
|
35
|
+
for (let i: number = 0; i < len; i++) {
|
|
36
|
+
// eslint-disable-next-line
|
|
37
|
+
const mapKey = mapKeys[i].trim();
|
|
38
|
+
const objProp: any = rawData[mapKey];
|
|
39
|
+
let decorated: boolean = false;
|
|
40
|
+
if (rawData.hasOwnProperty(mapKey)) {
|
|
41
|
+
if (BooleanTextDecorator.IsBooleanTextField(this, key)) {
|
|
42
|
+
this[key] = BooleanTextDecorator.GetLogicalBooleanValue(objProp);
|
|
43
|
+
decorated = true;
|
|
44
|
+
}
|
|
45
|
+
if (JsonFieldFieldDecorator.IsJsonField(this, key)) {
|
|
46
|
+
this[key] = JsonFieldFieldDecorator.StringAsJson(objProp);
|
|
47
|
+
decorated = true;
|
|
48
|
+
}
|
|
49
|
+
if (ComplexArrayDecorator.IsComplexArray(this, key)) {
|
|
50
|
+
const arrayClass: any = ComplexArrayDecorator.GetComplexArrayType(this, key);
|
|
51
|
+
// eslint-disable-next-line
|
|
52
|
+
const origArray = this[key];
|
|
53
|
+
// eslint-disable-next-line
|
|
54
|
+
const newArray = [];
|
|
55
|
+
// eslint-disable-next-line @typescript-eslint/prefer-for-of
|
|
56
|
+
for (let j = 0; j < origArray.length; j++) {
|
|
57
|
+
// eslint-disable-next-line
|
|
58
|
+
const item = new arrayClass(origArray[j]);
|
|
59
|
+
newArray.push(item);
|
|
60
|
+
}
|
|
61
|
+
this[key] = newArray;
|
|
62
|
+
} else {
|
|
63
|
+
if (!decorated) {
|
|
64
|
+
this[key] = objProp;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
break;
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
} else {
|
|
71
|
+
if (rawData.hasOwnProperty(key)) {
|
|
72
|
+
const objProp: any = rawData[key];
|
|
73
|
+
if (BooleanTextDecorator.IsBooleanTextField(this, key)) {
|
|
74
|
+
this[key] = BooleanTextDecorator.GetLogicalBooleanValue(objProp);
|
|
75
|
+
} else if (JsonFieldFieldDecorator.IsJsonField(this, key)) {
|
|
76
|
+
this[key] = JsonFieldFieldDecorator.StringAsJson(objProp);
|
|
77
|
+
} else {
|
|
78
|
+
this[key] = objProp;
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
});
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import {Month} from "../../enum/month.enum";
|
|
2
|
+
|
|
3
|
+
// All the months in a year. The order is important, and should remain January - to December!
|
|
4
|
+
export const ALL_MONTHS: Month[] = [
|
|
5
|
+
Month.January,
|
|
6
|
+
Month.Februrary,
|
|
7
|
+
Month.March,
|
|
8
|
+
Month.April,
|
|
9
|
+
Month.May,
|
|
10
|
+
Month.June,
|
|
11
|
+
Month.July,
|
|
12
|
+
Month.August,
|
|
13
|
+
Month.September,
|
|
14
|
+
Month.October,
|
|
15
|
+
Month.November,
|
|
16
|
+
Month.December
|
|
17
|
+
];
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/** AUTO GENERATED FILE. DO NOT CHANGE.. OR YOU WILL SUFFER THE CONSEQUENCES OF YOUR ACTIONS **/
|
|
2
|
+
|
|
3
|
+
export const IconSvg: {[iconName: string]: string} = {
|
|
4
|
+
"angle_left_solid": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 320 512\"><path fill=\"#183153\" d=\"M41.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l160 160c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L109.3 256 246.6 118.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-160 160z\"/></svg>",
|
|
5
|
+
"angle_right_solid": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 320 512\"><path fill=\"#183153\" d=\"M278.6 233.4c12.5 12.5 12.5 32.8 0 45.3l-160 160c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L210.7 256 73.4 118.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l160 160z\"/></svg>",
|
|
6
|
+
"arrow_fat_right": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><polygon points=\"37.5 25 25.2 12.7 25.2 20.35 12.5 20.35 12.5 29.66 25.2 29.66 25.2 37.3 37.5 25\" fill=\"#484f60\"/></svg>",
|
|
7
|
+
"arrow_point_left": "<svg version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" x=\"0px\" y=\"0px\" viewBox=\"0 0 51 51\" enable-background=\"new 0 0 51 51\" ><path fill=\"#484F5F\" d=\"M31.9,36.7l-14.7-9.6C17.1,27,17,26.9,17,26.7v-2.4c0-0.2,0.1-0.3,0.2-0.4l14.7-9.6c0.2-0.2,0.5-0.1,0.7,0.1l1.4,2.1c0.2,0.2,0.1,0.5-0.1,0.7l-12,7.8c-0.3,0.2-0.3,0.6,0,0.8l12,7.8c0.2,0.2,0.3,0.5,0.1,0.7l-1.4,2.1C32.4,36.8,32.1,36.8,31.9,36.7z\"/></svg>",
|
|
8
|
+
"arrow_point_right": "<svg version=\"1.1\" xmlns=\"http://www.w3.org/2000/svg\" x=\"0px\" y=\"0px\" viewBox=\"0 0 51 51\" enable-background=\"new 0 0 51 51\"><path fill=\"#484F5F\" d=\"M19.1,14.3l14.7,9.6c0.1,0.1,0.2,0.2,0.2,0.4v2.4c0,0.2-0.1,0.3-0.2,0.4l-14.7,9.6c-0.2,0.2-0.5,0.1-0.7-0.1l-1.4-2.1c-0.2-0.2-0.1-0.5,0.1-0.7l12-7.8c0.3-0.2,0.3-0.6,0-0.8l-12-7.8c-0.2-0.2-0.3-0.5-0.1-0.7l1.4-2.1C18.6,14.2,18.9,14.2,19.1,14.3z\"/></svg>",
|
|
9
|
+
"bring_forward_regular": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 512 512\"><path fill=\"#183153\" d=\"M224 464H448C456.8 464 464 456.8 464 448V224C464 215.2 456.8 208 448 208H384V160H448C483.3 160 512 188.7 512 224V448C512 483.3 483.3 512 448 512H224C188.7 512 160 483.3 160 448V384H208V448C208 456.8 215.2 464 224 464zM64 352C28.65 352 0 323.3 0 288V64C0 28.65 28.65 0 64 0H288C323.3 0 352 28.65 352 64V288C352 323.3 323.3 352 288 352H64z\"/></svg>",
|
|
10
|
+
"check_round": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M25,10A15,15,0,1,0,40,25,15,15,0,0,0,25,10ZM23,34l-6.24-9.09,2.81-3.59L23,26.45,27.66,16h5.58Z\" fill=\"#484f60\"/></svg>",
|
|
11
|
+
"delete_left_regular": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 576 512\"><path d=\"M432.1 208.1L385.9 256L432.1 303C442.3 312.4 442.3 327.6 432.1 336.1C423.6 346.3 408.4 346.3 399 336.1L352 289.9L304.1 336.1C295.6 346.3 280.4 346.3 271 336.1C261.7 327.6 261.7 312.4 271 303L318.1 256L271 208.1C261.7 199.6 261.7 184.4 271 175C280.4 165.7 295.6 165.7 304.1 175L352 222.1L399 175C408.4 165.7 423.6 165.7 432.1 175C442.3 184.4 442.3 199.6 432.1 208.1V208.1zM512 64C547.3 64 576 92.65 576 128V384C576 419.3 547.3 448 512 448H205.3C188.3 448 172 441.3 160 429.3L9.372 278.6C3.371 272.6 0 264.5 0 256C0 247.5 3.372 239.4 9.372 233.4L160 82.75C172 70.74 188.3 64 205.3 64L512 64zM528 128C528 119.2 520.8 112 512 112H205.3C201 112 196.9 113.7 193.9 116.7L54.63 256L193.9 395.3C196.9 398.3 201 400 205.3 400H512C520.8 400 528 392.8 528 384V128z\"/></svg>",
|
|
12
|
+
"delivery_truck": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><rect x=\"15.35\" y=\"16.56\" width=\"15.14\" height=\"10.94\" transform=\"translate(-1.83 2.08) rotate(-5)\" fill=\"#484f60\"/><path d=\"M38.5,18.1l-6.9.61L32.41,28l-7.63.67a3.76,3.76,0,0,1,1.43,2.25l7.25-.63A3.83,3.83,0,0,1,41,29.6l1-.1-.52-6Zm.29,5.84-3.91.34a.51.51,0,0,1-.55-.46L34,20.1a.49.49,0,0,1,.45-.54l2.27-.2a.5.5,0,0,1,.48.25l2,3.59A.5.5,0,0,1,38.79,23.94Z\" fill=\"#484f60\"/><path d=\"M19.66,29.09a3.8,3.8,0,0,0-1,2.46l-.74.07-1.82-.94L16,29.41Z\" fill=\"#484f60\"/><path d=\"M34.56,30.62a2.74,2.74,0,1,0,2.49-3A2.73,2.73,0,0,0,34.56,30.62Z\" fill=\"#484f60\"/><path d=\"M19.74,31.91a2.74,2.74,0,1,0,2.49-3A2.74,2.74,0,0,0,19.74,31.91Z\" fill=\"#484f60\"/><rect x=\"7.96\" y=\"17.63\" width=\"5\" height=\"1\" transform=\"translate(-1.54 0.98) rotate(-5)\" fill=\"#484f60\"/><rect x=\"11.02\" y=\"29.71\" width=\"3\" height=\"1\" transform=\"translate(-2.59 1.21) rotate(-5)\" fill=\"#484f60\"/><rect x=\"9.48\" y=\"23.53\" width=\"4\" height=\"1\" transform=\"matrix(1, -0.09, 0.09, 1, -2.05, 1.09)\" fill=\"#484f60\"/></svg>",
|
|
13
|
+
"email": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M31.79,38.45A17.82,17.82,0,0,1,23.86,40,13.09,13.09,0,0,1,10.41,26.42C10.41,17.63,16.83,10,26.53,10c7.63,0,13.06,5.21,13.06,12.46,0,6.33-3.53,10.3-8.19,10.3a3.42,3.42,0,0,1-3.71-3.32h-.08A6.5,6.5,0,0,1,22,32.76c-2.75,0-4.82-2.11-4.82-5.65a9.85,9.85,0,0,1,10.13-10,12.89,12.89,0,0,1,5.13,1l-1.3,8c-.43,2.54-.13,3.71,1.08,3.75,1.85.09,4.18-2.28,4.18-7.28,0-5.65-3.62-10-10.3-10S13.73,17.76,13.73,26c0,7.25,4.57,11.3,11,11.3A14.81,14.81,0,0,0,31,36ZM28,20.65a5.34,5.34,0,0,0-1.33-.18c-2.85,0-5.09,2.81-5.09,6.12,0,1.64.73,2.68,2.16,2.68,1.59,0,3.27-2,3.66-4.53Z\" fill=\"#484f60\"/></svg>",
|
|
14
|
+
"pdf": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M31.42,40.17H13.88c-2.16,0-2.72-.56-2.72-2.72V12.88c0-2.15.56-2.71,2.72-2.71h11.6l8.66,8.88v3.43H32.8V19.6l-7.88-8.09h-11c-1.38,0-1.38,0-1.38,1.37V37.45c0,1.37,0,1.37,1.38,1.37H31.42c1.38,0,1.38,0,1.38-1.37V35h1.34v2.43C34.14,39.61,33.58,40.17,31.42,40.17Z\" fill=\"#484f60\"/><path d=\"M27.83,26.63v4.24h1a3.57,3.57,0,0,0,.78-.06,1.22,1.22,0,0,0,.52-.26,1.44,1.44,0,0,0,.34-.62,4.13,4.13,0,0,0,.13-1.18,3.79,3.79,0,0,0-.13-1.14,1.51,1.51,0,0,0-.37-.62,1.14,1.14,0,0,0-.6-.3,5.93,5.93,0,0,0-1.06-.06Z\" fill=\"#484f60\"/><path d=\"M21.86,26.63v1.82h.71a3.57,3.57,0,0,0,1-.1A.88.88,0,0,0,24,28a.84.84,0,0,0,.14-.5.8.8,0,0,0-.2-.57.88.88,0,0,0-.52-.29,6.36,6.36,0,0,0-.93,0Z\" fill=\"#484f60\"/><path d=\"M19.14,24.27v9h19.7v-9Zm6.12,4.24a1.68,1.68,0,0,1-.54.63,1.9,1.9,0,0,1-.67.3,6.57,6.57,0,0,1-1.34.1h-.85V32H20.57V25.54h2.07a7.75,7.75,0,0,1,1.54.1,1.73,1.73,0,0,1,.93.63,2,2,0,0,1,.37,1.25A2,2,0,0,1,25.26,28.51Zm6.45,1.66A2.91,2.91,0,0,1,31,31.31a2.28,2.28,0,0,1-.91.51A4,4,0,0,1,29,32H26.54V25.54H28.9a4.21,4.21,0,0,1,1.22.13,2.08,2.08,0,0,1,1,.59,2.79,2.79,0,0,1,.61,1,4.76,4.76,0,0,1,.21,1.52A4.19,4.19,0,0,1,31.71,30.17Zm5.7-3.54h-3.1v1.52H37v1.08H34.31V32H33V25.54h4.39Z\" fill=\"#484f60\"/><path d=\"M25.2,10.84v6.44c0,1.78.27,2,2,2h6.23Z\" fill=\"#484f60\"/></svg>",
|
|
15
|
+
"print": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M38,16.5H12a2,2,0,0,0-2,2v9a2,2,0,0,0,2,2h2v-5H36v5h2a2,2,0,0,0,2-2v-9A2,2,0,0,0,38,16.5ZM37,21a1.5,1.5,0,1,1,1.5-1.5A1.5,1.5,0,0,1,37,21Z\" fill=\"#484f60\"/><path d=\"M35,11.5v5H15v-5H35m1-1H14v7H36v-7Z\" fill=\"#484f60\"/><path d=\"M35,25.5v13H15v-13H35m1-1H14v15H36v-15Z\" fill=\"#484f60\"/><rect x=\"17\" y=\"28.3\" width=\"16\" height=\"0.8\" fill=\"#484f60\"/><rect x=\"17\" y=\"31.5\" width=\"16\" height=\"0.8\" fill=\"#484f60\"/><rect x=\"17\" y=\"34.7\" width=\"16\" height=\"0.8\" fill=\"#484f60\"/></svg>",
|
|
16
|
+
"signature_field": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M20.1,25.42a1.1,1.1,0,1,1,1.27,1.45l-3.3,9.07A63.13,63.13,0,0,1,28,28.3l1.26-12-8.26-3-6.77,10A62.4,62.4,0,0,1,17,35.54l3.3-9.07A1.12,1.12,0,0,1,20.1,25.42Z\" fill=\"#484f60\"/><rect x=\"21.62\" y=\"11.43\" width=\"8.79\" height=\"2.34\" transform=\"translate(5.88 -8.14) rotate(20)\" fill=\"#484f60\"/><path d=\"M18.11,37.48c1.44,2.65,4.58,2.94,7.23,2.1,1.41-.44,2.2-1.49,3.44-2.06,2.42-1.1,3.13,1.2,5.36,1.37.42,0,2-.65,1.54-.68-2.55-.19-2.93-3.13-5.51-2.65a4.9,4.9,0,0,0-1.64.71c-.77.49-1.31,1.62-2.07,2l-4.61.56A3.38,3.38,0,0,1,20,37c-.22-.41-2,.28-1.85.5Z\" fill=\"#484f60\"/></svg>",
|
|
17
|
+
"xml": "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 50 50\"><path d=\"M31.42,40.17H13.87c-2.15,0-2.71-.56-2.71-2.72V12.88c0-2.15.56-2.71,2.71-2.71H25.48l8.66,8.88v3.43H32.8V19.6l-7.88-8.09H13.87c-1.37,0-1.37,0-1.37,1.37V37.45c0,1.37,0,1.37,1.37,1.37H31.42c1.38,0,1.38,0,1.38-1.37V35h1.34v2.43C34.14,39.61,33.58,40.17,31.42,40.17Z\" fill=\"#484f60\"/><path d=\"M25.2,10.84v6.44c0,1.78.27,2,2,2h6.23Z\" fill=\"#484f60\"/><path d=\"M19.14,24.27v9h19.7v-9Zm5.36,7.41-1.3-2-1.3,2H20.48l2-3.06-1.81-2.8h1.38l1.18,1.88,1.15-1.88h1.37l-1.83,2.85,2,3Zm7.67,0h-1.1V27.07l-1.16,4.61H28.77l-1.16-4.61v4.61H26.52V25.82h1.76l1.07,4,1-4h1.77Zm5.33,0H33.38V25.87h1.18v4.82H37.5Z\" fill=\"#484f60\"/></svg>"
|
|
18
|
+
};
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import {BusinessObject} from "./business-object";
|
|
2
|
+
import {ComplexArray} from "../factory/decorators/complex-array.decorator";
|
|
3
|
+
import {DateField} from "../factory/decorators/date-field.decorator";
|
|
4
|
+
|
|
5
|
+
export class TimeWindow extends BusinessObject {
|
|
6
|
+
public id: string;
|
|
7
|
+
public key: string;
|
|
8
|
+
@DateField()
|
|
9
|
+
public dateTimeFrom: Date;
|
|
10
|
+
@DateField()
|
|
11
|
+
public dateTimeTo: Date;
|
|
12
|
+
@DateField()
|
|
13
|
+
public proposedPlanDateTimeFrom: Date;
|
|
14
|
+
@DateField()
|
|
15
|
+
public proposedPlanDateTimeTo: Date;
|
|
16
|
+
public proposedDriver: any; // Serializable type
|
|
17
|
+
public impact: string;
|
|
18
|
+
@ComplexArray(TimeWindow)
|
|
19
|
+
public followUpTimeSlots: TimeWindow[] = [];
|
|
20
|
+
public additionalProperties: any; // HashMap type
|
|
21
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import {AgendaEvent} from "./agenda-event.model";
|
|
2
|
+
|
|
3
|
+
export class Weekday {
|
|
4
|
+
public inView: boolean = true;
|
|
5
|
+
public weekdayDay: number;
|
|
6
|
+
public weekdayMonthShort: string;
|
|
7
|
+
public weekdayMonthLong: string;
|
|
8
|
+
public weekdayYear: number;
|
|
9
|
+
public date: Date;
|
|
10
|
+
public weekdayShort: string;
|
|
11
|
+
public weekdayLong: string;
|
|
12
|
+
public description: string;
|
|
13
|
+
public newMonth: boolean = false;
|
|
14
|
+
public weekdaySelected: boolean = false;
|
|
15
|
+
public datesByTheHour: Date[] = [];
|
|
16
|
+
public events: AgendaEvent[] = [];
|
|
17
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import {Pipe, PipeTransform} from "@angular/core";
|
|
2
|
+
|
|
3
|
+
@Pipe({
|
|
4
|
+
name: "arrayNumber"
|
|
5
|
+
})
|
|
6
|
+
export class ArrayNumberPipe implements PipeTransform {
|
|
7
|
+
|
|
8
|
+
transform(length: number, offset: number = 0): number[] {
|
|
9
|
+
if (!length || length < 0) {
|
|
10
|
+
return [];
|
|
11
|
+
}
|
|
12
|
+
return Array.from({length: Math.round(length)}, (x, i) => i + offset);
|
|
13
|
+
}
|
|
14
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import {Pipe, PipeTransform} from "@angular/core";
|
|
2
|
+
|
|
3
|
+
@Pipe({
|
|
4
|
+
name: "ucfirst"
|
|
5
|
+
})
|
|
6
|
+
// Pipe capable of transforming the first character of a string-value to upper case.
|
|
7
|
+
export class UCfirstPipe implements PipeTransform {
|
|
8
|
+
transform(value: string): string {
|
|
9
|
+
if (typeof value === "string") {
|
|
10
|
+
return value.charAt(0).toUpperCase() + value.slice(1);
|
|
11
|
+
}
|
|
12
|
+
return value;
|
|
13
|
+
}
|
|
14
|
+
}
|