@things-factory/compliance 0.0.0-stage → 10.1.255
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/dist-client/bootstrap.d.ts +2 -0
- package/dist-client/bootstrap.js +28 -0
- package/dist-client/bootstrap.js.map +1 -0
- package/dist-client/components/compliance-case-form.d.ts +42 -0
- package/dist-client/components/compliance-case-form.js +313 -0
- package/dist-client/components/compliance-case-form.js.map +1 -0
- package/dist-client/components/compliance-case-sheet.d.ts +35 -0
- package/dist-client/components/compliance-case-sheet.js +335 -0
- package/dist-client/components/compliance-case-sheet.js.map +1 -0
- package/dist-client/components/compliance-my-inventions.d.ts +17 -0
- package/dist-client/components/compliance-my-inventions.js +133 -0
- package/dist-client/components/compliance-my-inventions.js.map +1 -0
- package/dist-client/components/compliance-my-privacy-requests.d.ts +34 -0
- package/dist-client/components/compliance-my-privacy-requests.js +232 -0
- package/dist-client/components/compliance-my-privacy-requests.js.map +1 -0
- package/dist-client/components/compliance-my-reports.d.ts +19 -0
- package/dist-client/components/compliance-my-reports.js +137 -0
- package/dist-client/components/compliance-my-reports.js.map +1 -0
- package/dist-client/components/guide-link.d.ts +13 -0
- package/dist-client/components/guide-link.js +55 -0
- package/dist-client/components/guide-link.js.map +1 -0
- package/dist-client/components/invention-report-form.d.ts +30 -0
- package/dist-client/components/invention-report-form.js +188 -0
- package/dist-client/components/invention-report-form.js.map +1 -0
- package/dist-client/components/legal-todo.d.ts +10 -0
- package/dist-client/components/legal-todo.js +43 -0
- package/dist-client/components/legal-todo.js.map +1 -0
- package/dist-client/components/my-trainings.d.ts +18 -0
- package/dist-client/components/my-trainings.js +149 -0
- package/dist-client/components/my-trainings.js.map +1 -0
- package/dist-client/components/regulation-form.d.ts +26 -0
- package/dist-client/components/regulation-form.js +161 -0
- package/dist-client/components/regulation-form.js.map +1 -0
- package/dist-client/components/seal-use-form.d.ts +47 -0
- package/dist-client/components/seal-use-form.js +300 -0
- package/dist-client/components/seal-use-form.js.map +1 -0
- package/dist-client/components/training-attendance-form.d.ts +37 -0
- package/dist-client/components/training-attendance-form.js +186 -0
- package/dist-client/components/training-attendance-form.js.map +1 -0
- package/dist-client/components/training-certificate-form.d.ts +41 -0
- package/dist-client/components/training-certificate-form.js +198 -0
- package/dist-client/components/training-certificate-form.js.map +1 -0
- package/dist-client/components/training-session-form.d.ts +39 -0
- package/dist-client/components/training-session-form.js +270 -0
- package/dist-client/components/training-session-form.js.map +1 -0
- package/dist-client/components/training-setting-form.d.ts +45 -0
- package/dist-client/components/training-setting-form.js +175 -0
- package/dist-client/components/training-setting-form.js.map +1 -0
- package/dist-client/index.d.ts +4 -0
- package/dist-client/index.js +8 -0
- package/dist-client/index.js.map +1 -0
- package/dist-client/legal-record/dispute-calendar-source.d.ts +1 -0
- package/dist-client/legal-record/dispute-calendar-source.js +51 -0
- package/dist-client/legal-record/dispute-calendar-source.js.map +1 -0
- package/dist-client/legal-record/legal-child-grid.d.ts +31 -0
- package/dist-client/legal-record/legal-child-grid.js +76 -0
- package/dist-client/legal-record/legal-child-grid.js.map +1 -0
- package/dist-client/legal-record/legal-codes.d.ts +3 -0
- package/dist-client/legal-record/legal-codes.js +5 -0
- package/dist-client/legal-record/legal-codes.js.map +1 -0
- package/dist-client/legal-record/legal-grid.d.ts +59 -0
- package/dist-client/legal-record/legal-grid.js +68 -0
- package/dist-client/legal-record/legal-grid.js.map +1 -0
- package/dist-client/legal-record/legal-record-files.d.ts +26 -0
- package/dist-client/legal-record/legal-record-files.js +162 -0
- package/dist-client/legal-record/legal-record-files.js.map +1 -0
- package/dist-client/pages/compliance-case-list.d.ts +35 -0
- package/dist-client/pages/compliance-case-list.js +112 -0
- package/dist-client/pages/compliance-case-list.js.map +1 -0
- package/dist-client/pages/dispute-list.d.ts +57 -0
- package/dist-client/pages/dispute-list.js +156 -0
- package/dist-client/pages/dispute-list.js.map +1 -0
- package/dist-client/pages/invention-list.d.ts +57 -0
- package/dist-client/pages/invention-list.js +166 -0
- package/dist-client/pages/invention-list.js.map +1 -0
- package/dist-client/pages/legal-registration-list.d.ts +63 -0
- package/dist-client/pages/legal-registration-list.js +206 -0
- package/dist-client/pages/legal-registration-list.js.map +1 -0
- package/dist-client/pages/privacy-record-list.d.ts +52 -0
- package/dist-client/pages/privacy-record-list.js +225 -0
- package/dist-client/pages/privacy-record-list.js.map +1 -0
- package/dist-client/pages/regulation-detail.d.ts +43 -0
- package/dist-client/pages/regulation-detail.js +370 -0
- package/dist-client/pages/regulation-detail.js.map +1 -0
- package/dist-client/pages/regulation-list.d.ts +52 -0
- package/dist-client/pages/regulation-list.js +144 -0
- package/dist-client/pages/regulation-list.js.map +1 -0
- package/dist-client/pages/regulations.d.ts +49 -0
- package/dist-client/pages/regulations.js +412 -0
- package/dist-client/pages/regulations.js.map +1 -0
- package/dist-client/pages/seal-use-list.d.ts +57 -0
- package/dist-client/pages/seal-use-list.js +168 -0
- package/dist-client/pages/seal-use-list.js.map +1 -0
- package/dist-client/pages/training-list.d.ts +51 -0
- package/dist-client/pages/training-list.js +333 -0
- package/dist-client/pages/training-list.js.map +1 -0
- package/dist-client/regulation/regulation-fragments.d.ts +1 -0
- package/dist-client/regulation/regulation-fragments.js +37 -0
- package/dist-client/regulation/regulation-fragments.js.map +1 -0
- package/dist-client/regulation/regulation-guide.d.ts +19 -0
- package/dist-client/regulation/regulation-guide.js +48 -0
- package/dist-client/regulation/regulation-guide.js.map +1 -0
- package/dist-client/route.d.ts +1 -0
- package/dist-client/route.js +36 -0
- package/dist-client/route.js.map +1 -0
- package/dist-client/training-words.d.ts +11 -0
- package/dist-client/training-words.js +11 -0
- package/dist-client/training-words.js.map +1 -0
- package/dist-client/tsconfig.tsbuildinfo +1 -0
- package/dist-client/words.d.ts +15 -0
- package/dist-client/words.js +20 -0
- package/dist-client/words.js.map +1 -0
- package/dist-server/activities/index.d.ts +6 -0
- package/dist-server/activities/index.js +37 -0
- package/dist-server/activities/index.js.map +1 -0
- package/dist-server/activities/legal-todo-activity-names.d.ts +1 -0
- package/dist-server/activities/legal-todo-activity-names.js +5 -0
- package/dist-server/activities/legal-todo-activity-names.js.map +1 -0
- package/dist-server/activities/legal-todo-activity.d.ts +37 -0
- package/dist-server/activities/legal-todo-activity.js +41 -0
- package/dist-server/activities/legal-todo-activity.js.map +1 -0
- package/dist-server/activities/regulation-activity-names.d.ts +1 -0
- package/dist-server/activities/regulation-activity-names.js +5 -0
- package/dist-server/activities/regulation-activity-names.js.map +1 -0
- package/dist-server/activities/regulation-activity.d.ts +48 -0
- package/dist-server/activities/regulation-activity.js +47 -0
- package/dist-server/activities/regulation-activity.js.map +1 -0
- package/dist-server/activities/seal-use-activity-names.d.ts +2 -0
- package/dist-server/activities/seal-use-activity-names.js +6 -0
- package/dist-server/activities/seal-use-activity-names.js.map +1 -0
- package/dist-server/activities/seal-use-activity.d.ts +48 -0
- package/dist-server/activities/seal-use-activity.js +47 -0
- package/dist-server/activities/seal-use-activity.js.map +1 -0
- package/dist-server/index.d.ts +2 -0
- package/dist-server/index.js +21 -0
- package/dist-server/index.js.map +1 -0
- package/dist-server/role-tasks.d.ts +2 -0
- package/dist-server/role-tasks.js +28 -0
- package/dist-server/role-tasks.js.map +1 -0
- package/dist-server/service/common/correction.d.ts +32 -0
- package/dist-server/service/common/correction.js +98 -0
- package/dist-server/service/common/correction.js.map +1 -0
- package/dist-server/service/common/employee-reader.d.ts +11 -0
- package/dist-server/service/common/employee-reader.js +46 -0
- package/dist-server/service/common/employee-reader.js.map +1 -0
- package/dist-server/service/common/legal-todo.d.ts +19 -0
- package/dist-server/service/common/legal-todo.js +37 -0
- package/dist-server/service/common/legal-todo.js.map +1 -0
- package/dist-server/service/compliance-case/compliance-case-mutation.d.ts +9 -0
- package/dist-server/service/compliance-case/compliance-case-mutation.js +73 -0
- package/dist-server/service/compliance-case/compliance-case-mutation.js.map +1 -0
- package/dist-server/service/compliance-case/compliance-case-query.d.ts +28 -0
- package/dist-server/service/compliance-case/compliance-case-query.js +212 -0
- package/dist-server/service/compliance-case/compliance-case-query.js.map +1 -0
- package/dist-server/service/compliance-case/compliance-case-rules.d.ts +71 -0
- package/dist-server/service/compliance-case/compliance-case-rules.js +111 -0
- package/dist-server/service/compliance-case/compliance-case-rules.js.map +1 -0
- package/dist-server/service/compliance-case/compliance-case-service.d.ts +76 -0
- package/dist-server/service/compliance-case/compliance-case-service.js +425 -0
- package/dist-server/service/compliance-case/compliance-case-service.js.map +1 -0
- package/dist-server/service/compliance-case/compliance-case-type.d.ts +56 -0
- package/dist-server/service/compliance-case/compliance-case-type.js +200 -0
- package/dist-server/service/compliance-case/compliance-case-type.js.map +1 -0
- package/dist-server/service/compliance-case/compliance-case.d.ts +76 -0
- package/dist-server/service/compliance-case/compliance-case.js +260 -0
- package/dist-server/service/compliance-case/compliance-case.js.map +1 -0
- package/dist-server/service/compliance-case/index.d.ts +7 -0
- package/dist-server/service/compliance-case/index.js +17 -0
- package/dist-server/service/compliance-case/index.js.map +1 -0
- package/dist-server/service/dispute/dispute-mutation.d.ts +9 -0
- package/dist-server/service/dispute/dispute-mutation.js +64 -0
- package/dist-server/service/dispute/dispute-mutation.js.map +1 -0
- package/dist-server/service/dispute/dispute-query.d.ts +16 -0
- package/dist-server/service/dispute/dispute-query.js +124 -0
- package/dist-server/service/dispute/dispute-query.js.map +1 -0
- package/dist-server/service/dispute/dispute-rules.d.ts +20 -0
- package/dist-server/service/dispute/dispute-rules.js +42 -0
- package/dist-server/service/dispute/dispute-rules.js.map +1 -0
- package/dist-server/service/dispute/dispute-service.d.ts +17 -0
- package/dist-server/service/dispute/dispute-service.js +96 -0
- package/dist-server/service/dispute/dispute-service.js.map +1 -0
- package/dist-server/service/dispute/dispute-type.d.ts +39 -0
- package/dist-server/service/dispute/dispute-type.js +149 -0
- package/dist-server/service/dispute/dispute-type.js.map +1 -0
- package/dist-server/service/dispute/dispute.d.ts +48 -0
- package/dist-server/service/dispute/dispute.js +198 -0
- package/dist-server/service/dispute/dispute.js.map +1 -0
- package/dist-server/service/dispute/index.d.ts +5 -0
- package/dist-server/service/dispute/index.js +9 -0
- package/dist-server/service/dispute/index.js.map +1 -0
- package/dist-server/service/index.d.ts +46 -0
- package/dist-server/service/index.js +112 -0
- package/dist-server/service/index.js.map +1 -0
- package/dist-server/service/invention/index.d.ts +5 -0
- package/dist-server/service/invention/index.js +9 -0
- package/dist-server/service/invention/index.js.map +1 -0
- package/dist-server/service/invention/invention-mutation.d.ts +10 -0
- package/dist-server/service/invention/invention-mutation.js +79 -0
- package/dist-server/service/invention/invention-mutation.js.map +1 -0
- package/dist-server/service/invention/invention-query.d.ts +18 -0
- package/dist-server/service/invention/invention-query.js +141 -0
- package/dist-server/service/invention/invention-query.js.map +1 -0
- package/dist-server/service/invention/invention-rules.d.ts +28 -0
- package/dist-server/service/invention/invention-rules.js +54 -0
- package/dist-server/service/invention/invention-rules.js.map +1 -0
- package/dist-server/service/invention/invention-service.d.ts +25 -0
- package/dist-server/service/invention/invention-service.js +176 -0
- package/dist-server/service/invention/invention-service.js.map +1 -0
- package/dist-server/service/invention/invention-type.d.ts +34 -0
- package/dist-server/service/invention/invention-type.js +129 -0
- package/dist-server/service/invention/invention-type.js.map +1 -0
- package/dist-server/service/invention/invention.d.ts +55 -0
- package/dist-server/service/invention/invention.js +214 -0
- package/dist-server/service/invention/invention.js.map +1 -0
- package/dist-server/service/legal-record/attachment-readers.d.ts +1 -0
- package/dist-server/service/legal-record/attachment-readers.js +27 -0
- package/dist-server/service/legal-record/attachment-readers.js.map +1 -0
- package/dist-server/service/legal-record/days.d.ts +7 -0
- package/dist-server/service/legal-record/days.js +26 -0
- package/dist-server/service/legal-record/days.js.map +1 -0
- package/dist-server/service/legal-record/legal-record-support.d.ts +24 -0
- package/dist-server/service/legal-record/legal-record-support.js +51 -0
- package/dist-server/service/legal-record/legal-record-support.js.map +1 -0
- package/dist-server/service/legal-registration/centre-change-subscriber.d.ts +9 -0
- package/dist-server/service/legal-registration/centre-change-subscriber.js +50 -0
- package/dist-server/service/legal-registration/centre-change-subscriber.js.map +1 -0
- package/dist-server/service/legal-registration/index.d.ts +7 -0
- package/dist-server/service/legal-registration/index.js +11 -0
- package/dist-server/service/legal-registration/index.js.map +1 -0
- package/dist-server/service/legal-registration/legal-registration-mutation.d.ts +10 -0
- package/dist-server/service/legal-registration/legal-registration-mutation.js +77 -0
- package/dist-server/service/legal-registration/legal-registration-mutation.js.map +1 -0
- package/dist-server/service/legal-registration/legal-registration-query.d.ts +26 -0
- package/dist-server/service/legal-registration/legal-registration-query.js +199 -0
- package/dist-server/service/legal-registration/legal-registration-query.js.map +1 -0
- package/dist-server/service/legal-registration/legal-registration-rules.d.ts +80 -0
- package/dist-server/service/legal-registration/legal-registration-rules.js +106 -0
- package/dist-server/service/legal-registration/legal-registration-rules.js.map +1 -0
- package/dist-server/service/legal-registration/legal-registration-service.d.ts +37 -0
- package/dist-server/service/legal-registration/legal-registration-service.js +248 -0
- package/dist-server/service/legal-registration/legal-registration-service.js.map +1 -0
- package/dist-server/service/legal-registration/legal-registration-type.d.ts +55 -0
- package/dist-server/service/legal-registration/legal-registration-type.js +207 -0
- package/dist-server/service/legal-registration/legal-registration-type.js.map +1 -0
- package/dist-server/service/legal-registration/legal-registration.d.ts +76 -0
- package/dist-server/service/legal-registration/legal-registration.js +311 -0
- package/dist-server/service/legal-registration/legal-registration.js.map +1 -0
- package/dist-server/service/privacy-record/index.d.ts +5 -0
- package/dist-server/service/privacy-record/index.js +9 -0
- package/dist-server/service/privacy-record/index.js.map +1 -0
- package/dist-server/service/privacy-record/privacy-record-mutation.d.ts +7 -0
- package/dist-server/service/privacy-record/privacy-record-mutation.js +56 -0
- package/dist-server/service/privacy-record/privacy-record-mutation.js.map +1 -0
- package/dist-server/service/privacy-record/privacy-record-query.d.ts +18 -0
- package/dist-server/service/privacy-record/privacy-record-query.js +131 -0
- package/dist-server/service/privacy-record/privacy-record-query.js.map +1 -0
- package/dist-server/service/privacy-record/privacy-record-rules.d.ts +52 -0
- package/dist-server/service/privacy-record/privacy-record-rules.js +91 -0
- package/dist-server/service/privacy-record/privacy-record-rules.js.map +1 -0
- package/dist-server/service/privacy-record/privacy-record-service.d.ts +33 -0
- package/dist-server/service/privacy-record/privacy-record-service.js +133 -0
- package/dist-server/service/privacy-record/privacy-record-service.js.map +1 -0
- package/dist-server/service/privacy-record/privacy-record-type.d.ts +40 -0
- package/dist-server/service/privacy-record/privacy-record-type.js +153 -0
- package/dist-server/service/privacy-record/privacy-record-type.js.map +1 -0
- package/dist-server/service/privacy-record/privacy-record.d.ts +69 -0
- package/dist-server/service/privacy-record/privacy-record.js +245 -0
- package/dist-server/service/privacy-record/privacy-record.js.map +1 -0
- package/dist-server/service/regulation/index.d.ts +5 -0
- package/dist-server/service/regulation/index.js +9 -0
- package/dist-server/service/regulation/index.js.map +1 -0
- package/dist-server/service/regulation/regulation-mutation.d.ts +15 -0
- package/dist-server/service/regulation/regulation-mutation.js +152 -0
- package/dist-server/service/regulation/regulation-mutation.js.map +1 -0
- package/dist-server/service/regulation/regulation-query.d.ts +10 -0
- package/dist-server/service/regulation/regulation-query.js +109 -0
- package/dist-server/service/regulation/regulation-query.js.map +1 -0
- package/dist-server/service/regulation/regulation-read.d.ts +21 -0
- package/dist-server/service/regulation/regulation-read.js +111 -0
- package/dist-server/service/regulation/regulation-read.js.map +1 -0
- package/dist-server/service/regulation/regulation-rules.d.ts +83 -0
- package/dist-server/service/regulation/regulation-rules.js +170 -0
- package/dist-server/service/regulation/regulation-rules.js.map +1 -0
- package/dist-server/service/regulation/regulation-service.d.ts +63 -0
- package/dist-server/service/regulation/regulation-service.js +365 -0
- package/dist-server/service/regulation/regulation-service.js.map +1 -0
- package/dist-server/service/regulation/regulation-type.d.ts +61 -0
- package/dist-server/service/regulation/regulation-type.js +226 -0
- package/dist-server/service/regulation/regulation-type.js.map +1 -0
- package/dist-server/service/regulation/regulation.d.ts +113 -0
- package/dist-server/service/regulation/regulation.js +382 -0
- package/dist-server/service/regulation/regulation.js.map +1 -0
- package/dist-server/service/seal-use/index.d.ts +5 -0
- package/dist-server/service/seal-use/index.js +9 -0
- package/dist-server/service/seal-use/index.js.map +1 -0
- package/dist-server/service/seal-use/seal-use-mutation.d.ts +8 -0
- package/dist-server/service/seal-use/seal-use-mutation.js +69 -0
- package/dist-server/service/seal-use/seal-use-mutation.js.map +1 -0
- package/dist-server/service/seal-use/seal-use-query.d.ts +14 -0
- package/dist-server/service/seal-use/seal-use-query.js +100 -0
- package/dist-server/service/seal-use/seal-use-query.js.map +1 -0
- package/dist-server/service/seal-use/seal-use-rules.d.ts +35 -0
- package/dist-server/service/seal-use/seal-use-rules.js +64 -0
- package/dist-server/service/seal-use/seal-use-rules.js.map +1 -0
- package/dist-server/service/seal-use/seal-use-service.d.ts +20 -0
- package/dist-server/service/seal-use/seal-use-service.js +168 -0
- package/dist-server/service/seal-use/seal-use-service.js.map +1 -0
- package/dist-server/service/seal-use/seal-use-type.d.ts +24 -0
- package/dist-server/service/seal-use/seal-use-type.js +93 -0
- package/dist-server/service/seal-use/seal-use-type.js.map +1 -0
- package/dist-server/service/seal-use/seal-use.d.ts +57 -0
- package/dist-server/service/seal-use/seal-use.js +181 -0
- package/dist-server/service/seal-use/seal-use.js.map +1 -0
- package/dist-server/service/training/index.d.ts +5 -0
- package/dist-server/service/training/index.js +9 -0
- package/dist-server/service/training/index.js.map +1 -0
- package/dist-server/service/training/training-checks.d.ts +20 -0
- package/dist-server/service/training/training-checks.js +56 -0
- package/dist-server/service/training/training-checks.js.map +1 -0
- package/dist-server/service/training/training-kinds.d.ts +24 -0
- package/dist-server/service/training/training-kinds.js +42 -0
- package/dist-server/service/training/training-kinds.js.map +1 -0
- package/dist-server/service/training/training-mutation.d.ts +14 -0
- package/dist-server/service/training/training-mutation.js +140 -0
- package/dist-server/service/training/training-mutation.js.map +1 -0
- package/dist-server/service/training/training-query.d.ts +21 -0
- package/dist-server/service/training/training-query.js +196 -0
- package/dist-server/service/training/training-query.js.map +1 -0
- package/dist-server/service/training/training-read.d.ts +5 -0
- package/dist-server/service/training/training-read.js +35 -0
- package/dist-server/service/training/training-read.js.map +1 -0
- package/dist-server/service/training/training-register.d.ts +1 -0
- package/dist-server/service/training/training-register.js +27 -0
- package/dist-server/service/training/training-register.js.map +1 -0
- package/dist-server/service/training/training-rules.d.ts +72 -0
- package/dist-server/service/training/training-rules.js +143 -0
- package/dist-server/service/training/training-rules.js.map +1 -0
- package/dist-server/service/training/training-service.d.ts +98 -0
- package/dist-server/service/training/training-service.js +455 -0
- package/dist-server/service/training/training-service.js.map +1 -0
- package/dist-server/service/training/training-type.d.ts +94 -0
- package/dist-server/service/training/training-type.js +352 -0
- package/dist-server/service/training/training-type.js.map +1 -0
- package/dist-server/service/training/training.d.ts +127 -0
- package/dist-server/service/training/training.js +448 -0
- package/dist-server/service/training/training.js.map +1 -0
- package/dist-server/tsconfig.tsbuildinfo +1 -0
- package/package.json +61 -4
- package/things-factory.config.js +19 -0
- package/translations/en.json +612 -0
- package/translations/es.json +612 -0
- package/translations/ja.json +612 -0
- package/translations/ko.json +612 -0
- package/translations/ms.json +612 -0
- package/translations/zh.json +612 -0
- package/README.md +0 -3
|
@@ -0,0 +1,248 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.centreEmployeeStateOf = exports.LEGAL_REGISTRATION_REF_TYPE = exports.LEGAL_REGISTRATION_CATEGORY = void 0;
|
|
4
|
+
exports.saveLegalRegistrations = saveLegalRegistrations;
|
|
5
|
+
exports.saveLegalResearchers = saveLegalResearchers;
|
|
6
|
+
exports.fileCentreChanges = fileCentreChanges;
|
|
7
|
+
exports.noteCentreEmployeeChange = noteCentreEmployeeChange;
|
|
8
|
+
exports.legalRegistrationsExpiring = legalRegistrationsExpiring;
|
|
9
|
+
exports.legalRegistrationsInRenewalWindow = legalRegistrationsInRenewalWindow;
|
|
10
|
+
exports.legalRegistrationFeesDue = legalRegistrationFeesDue;
|
|
11
|
+
exports.legalCentreChangesNotFiled = legalCentreChangesNotFiled;
|
|
12
|
+
const typeorm_1 = require("typeorm");
|
|
13
|
+
const organization_1 = require("@things-factory/organization");
|
|
14
|
+
const shell_1 = require("@things-factory/shell");
|
|
15
|
+
const correction_1 = require("../common/correction");
|
|
16
|
+
const employee_reader_1 = require("../common/employee-reader");
|
|
17
|
+
const legal_todo_1 = require("../common/legal-todo");
|
|
18
|
+
const days_1 = require("../legal-record/days");
|
|
19
|
+
const legal_record_support_1 = require("../legal-record/legal-record-support");
|
|
20
|
+
const legal_registration_1 = require("./legal-registration");
|
|
21
|
+
const legal_registration_rules_1 = require("./legal-registration-rules");
|
|
22
|
+
/*
|
|
23
|
+
* The ledger of registrations (ADR-0187 decision 23): rows written and corrected, never deleted; a research centre's
|
|
24
|
+
* researchers; the changes organization makes it file, each a to-do closed by writing the day it was filed.
|
|
25
|
+
*/
|
|
26
|
+
exports.LEGAL_REGISTRATION_CATEGORY = 'legal-registration';
|
|
27
|
+
exports.LEGAL_REGISTRATION_REF_TYPE = 'compliance-legal-registration';
|
|
28
|
+
const RESEARCH_KINDS = legal_registration_rules_1.LEGAL_REGISTRATION_KINDS.filter(one => one.researchers).map(one => one.code);
|
|
29
|
+
const REASON_WORDS = { LEFT: '퇴사', MOVED_OUT: '부서 이동(연구소 밖)', JOINED: '입사 · 이동(연구소)' };
|
|
30
|
+
const WRITABLE = ['kind', 'title', 'number', 'authority', 'grantedOn', 'expiresOn', 'renewalFromOn', 'nextFeeDueOn', 'endedOn', 'notes'];
|
|
31
|
+
const notFound = () => new shell_1.Refusal('legal-registration-not-found', {}, 'the record was not found. reload and try again.');
|
|
32
|
+
const notDeletable = () => new shell_1.Refusal('legal-record-not-deletable', {}, 'a legal record is never deleted - end it, or correct it');
|
|
33
|
+
async function employeeOf(tx, domain, id, field) {
|
|
34
|
+
if (!id)
|
|
35
|
+
return null;
|
|
36
|
+
const one = await tx.getRepository(organization_1.Employee).findOne({ where: { id, domain: { id: domain.id } } });
|
|
37
|
+
if (!one)
|
|
38
|
+
throw new shell_1.Refusal('legal-registration-employee-unknown', { field }, `${field} must be an employee of this domain`);
|
|
39
|
+
return one;
|
|
40
|
+
}
|
|
41
|
+
/** Writes the ledger's new and changed rows - a deleted one is refused. */
|
|
42
|
+
async function saveLegalRegistrations(patches, context) {
|
|
43
|
+
const { domain, user, tx } = context.state;
|
|
44
|
+
const repository = tx.getRepository(legal_registration_1.LegalRegistration);
|
|
45
|
+
const saved = [];
|
|
46
|
+
for (const patch of patches) {
|
|
47
|
+
if (patch.cuFlag === '-')
|
|
48
|
+
throw notDeletable();
|
|
49
|
+
const row = patch.id ? await repository.findOne({ where: { id: patch.id, domain: { id: domain.id } } }) : repository.create({ domain, creator: user });
|
|
50
|
+
if (!row)
|
|
51
|
+
throw notFound();
|
|
52
|
+
const before = { ...row };
|
|
53
|
+
const given = new Set((0, legal_record_support_1.fieldsOf)(patch));
|
|
54
|
+
for (const field of WRITABLE)
|
|
55
|
+
if (given.has(field))
|
|
56
|
+
row[field] = (0, legal_record_support_1.text)(patch[field]);
|
|
57
|
+
if (given.has('inChargeId'))
|
|
58
|
+
row.inCharge = await employeeOf(tx, domain, (0, legal_record_support_1.text)(patch.inChargeId), 'inCharge');
|
|
59
|
+
if (given.has('departmentId')) {
|
|
60
|
+
const id = (0, legal_record_support_1.text)(patch.departmentId);
|
|
61
|
+
row.department = id ? await tx.getRepository(organization_1.Department).findOne({ where: { id, domain: { id: domain.id } } }) : null;
|
|
62
|
+
if (id && !row.department)
|
|
63
|
+
throw new shell_1.Refusal('legal-registration-department-unknown', {}, 'the department must be of this domain');
|
|
64
|
+
}
|
|
65
|
+
if (given.has('assetId'))
|
|
66
|
+
row.assetId = (0, legal_record_support_1.text)(patch.assetId);
|
|
67
|
+
/* A day the kind counts is counted when nobody wrote it - and again when what it is counted from changes. */
|
|
68
|
+
const counted = given.has('kind') || given.has('grantedOn');
|
|
69
|
+
if (!given.has('expiresOn') && counted)
|
|
70
|
+
row.expiresOn = (0, legal_registration_rules_1.expiresOnOf)(row.kind, row.grantedOn) ?? row.expiresOn;
|
|
71
|
+
if (!given.has('renewalFromOn') && (counted || given.has('expiresOn')))
|
|
72
|
+
row.renewalFromOn = (0, legal_registration_rules_1.renewalFromOnOf)(row.kind, row.expiresOn) ?? row.renewalFromOn;
|
|
73
|
+
const refusal = (0, legal_registration_rules_1.legalRegistrationRefusal)(row);
|
|
74
|
+
if (refusal)
|
|
75
|
+
throw refusal;
|
|
76
|
+
if (row.department && !(0, legal_registration_rules_1.legalRegistrationKindOf)(row.kind)?.researchers)
|
|
77
|
+
throw new shell_1.Refusal('legal-registration-department-of-centre', {}, 'only a research centre or an R&D department has a department');
|
|
78
|
+
row.updater = user;
|
|
79
|
+
saved.push(await repository.save(row));
|
|
80
|
+
const after = {
|
|
81
|
+
...row,
|
|
82
|
+
inChargeId: given.has('inChargeId') ? (row.inCharge?.id ?? null) : row.inChargeId,
|
|
83
|
+
departmentId: given.has('departmentId') ? (row.department?.id ?? null) : row.departmentId
|
|
84
|
+
};
|
|
85
|
+
await (0, correction_1.recordCorrections)(tx, domain, user, { kind: 'LegalRegistration', id: row.id }, before, after, [...WRITABLE, 'inChargeId', 'departmentId', 'assetId']);
|
|
86
|
+
}
|
|
87
|
+
return saved;
|
|
88
|
+
}
|
|
89
|
+
/** A research centre of the domain, refused for another kind. */
|
|
90
|
+
async function centreOf(tx, domain, id) {
|
|
91
|
+
const centre = await tx.getRepository(legal_registration_1.LegalRegistration).findOne({ where: { id, domain: { id: domain.id } } });
|
|
92
|
+
if (!centre)
|
|
93
|
+
throw notFound();
|
|
94
|
+
if (!(0, legal_registration_rules_1.legalRegistrationKindOf)(centre.kind)?.researchers)
|
|
95
|
+
throw new shell_1.Refusal('legal-registration-not-a-centre', {}, 'only a research centre or an R&D department lists researchers');
|
|
96
|
+
return centre;
|
|
97
|
+
}
|
|
98
|
+
/** Writes a centre's researchers - listed from a day, ended on a day; a row is never deleted. */
|
|
99
|
+
async function saveLegalResearchers(registrationId, patches, context) {
|
|
100
|
+
const { domain, user, tx } = context.state;
|
|
101
|
+
const centre = await centreOf(tx, domain, registrationId);
|
|
102
|
+
const repository = tx.getRepository(legal_registration_1.LegalResearcher);
|
|
103
|
+
const saved = [];
|
|
104
|
+
for (const patch of patches) {
|
|
105
|
+
if (patch.cuFlag === '-')
|
|
106
|
+
throw notDeletable();
|
|
107
|
+
let row;
|
|
108
|
+
if (patch.id) {
|
|
109
|
+
row = await repository.findOne({ where: { id: patch.id, registration: { id: centre.id } } });
|
|
110
|
+
if (!row)
|
|
111
|
+
throw notFound();
|
|
112
|
+
if (patch.employeeId && patch.employeeId !== row.employeeId)
|
|
113
|
+
throw new shell_1.Refusal('legal-researcher-employee-fixed', {}, 'the researcher of a row stays - end it and add another');
|
|
114
|
+
}
|
|
115
|
+
else {
|
|
116
|
+
const employee = await employeeOf(tx, domain, (0, legal_record_support_1.text)(patch.employeeId), 'employee');
|
|
117
|
+
if (!employee)
|
|
118
|
+
throw new shell_1.Refusal('legal-researcher-employee-required', {}, 'pick the employee');
|
|
119
|
+
const listed = await repository.count({ where: { registration: { id: centre.id }, employee: { id: employee.id }, toOn: (0, typeorm_1.IsNull)() } });
|
|
120
|
+
if (listed)
|
|
121
|
+
throw new shell_1.Refusal('legal-researcher-listed', { name: employee.name }, `${employee.name} is listed already`);
|
|
122
|
+
row = repository.create({ domain, registration: centre, employee, creator: user });
|
|
123
|
+
}
|
|
124
|
+
const before = { ...row };
|
|
125
|
+
if (patch.fromOn !== undefined)
|
|
126
|
+
row.fromOn = (0, legal_record_support_1.text)(patch.fromOn);
|
|
127
|
+
if (patch.toOn !== undefined)
|
|
128
|
+
row.toOn = (0, legal_record_support_1.text)(patch.toOn);
|
|
129
|
+
for (const field of ['fromOn', 'toOn'])
|
|
130
|
+
if (row[field] && !(0, days_1.isDay)(row[field]))
|
|
131
|
+
throw new shell_1.Refusal('legal-registration-day-invalid', { field }, `${field} is a day, YYYY-MM-DD`);
|
|
132
|
+
if (row.fromOn && row.toOn && row.toOn < row.fromOn)
|
|
133
|
+
throw new shell_1.Refusal('legal-researcher-to-before-from', {}, 'listed until is on or after listed from');
|
|
134
|
+
row.updater = user;
|
|
135
|
+
saved.push(await repository.save(row));
|
|
136
|
+
await (0, correction_1.recordCorrections)(tx, domain, user, { kind: 'LegalResearcher', id: row.id }, before, row, ['fromOn', 'toOn']);
|
|
137
|
+
}
|
|
138
|
+
return saved;
|
|
139
|
+
}
|
|
140
|
+
/** Writes the day a centre's change was filed - which closes its to-do. A change is never deleted. */
|
|
141
|
+
async function fileCentreChanges(patches, context) {
|
|
142
|
+
const { domain, user, tx } = context.state;
|
|
143
|
+
const repository = tx.getRepository(legal_registration_1.LegalCentreChange);
|
|
144
|
+
const saved = [];
|
|
145
|
+
for (const patch of patches) {
|
|
146
|
+
if (patch.cuFlag === '-' || patch.cuFlag === '+')
|
|
147
|
+
throw new shell_1.Refusal('legal-centre-change-written', {}, 'a change is written by the organization - only the day it was filed and the notes are written here');
|
|
148
|
+
const row = await repository.findOne({ where: { id: patch.id, domain: { id: domain.id } } });
|
|
149
|
+
if (!row)
|
|
150
|
+
throw notFound();
|
|
151
|
+
const before = { ...row };
|
|
152
|
+
if (patch.filedOn !== undefined) {
|
|
153
|
+
const day = (0, legal_record_support_1.text)(patch.filedOn);
|
|
154
|
+
if (day && (!(0, days_1.isDay)(day) || day < row.aroseOn))
|
|
155
|
+
throw new shell_1.Refusal('legal-centre-change-filed-invalid', { aroseOn: row.aroseOn }, `it is filed on or after ${row.aroseOn}, YYYY-MM-DD`);
|
|
156
|
+
row.filedOn = day;
|
|
157
|
+
}
|
|
158
|
+
if (patch.notes !== undefined)
|
|
159
|
+
row.notes = (0, legal_record_support_1.text)(patch.notes);
|
|
160
|
+
row.updater = user;
|
|
161
|
+
saved.push(await repository.save(row));
|
|
162
|
+
await (0, correction_1.recordCorrections)(tx, domain, user, { kind: 'LegalCentreChange', id: row.id }, before, row, ['filedOn', 'notes']);
|
|
163
|
+
if (row.filedOn)
|
|
164
|
+
for (const id of row.todoInstanceIds ?? [])
|
|
165
|
+
await (0, legal_todo_1.closeLegalTodo)(tx, domain, id, user, '신고함');
|
|
166
|
+
}
|
|
167
|
+
return saved;
|
|
168
|
+
}
|
|
169
|
+
/** Who a centre's to-do goes to: the employee in charge, else every holder of the ledger. */
|
|
170
|
+
async function askedFor(tx, domain, centre) {
|
|
171
|
+
if (centre.inChargeId) {
|
|
172
|
+
const inCharge = await tx.getRepository(organization_1.Employee).findOne({ where: { id: centre.inChargeId }, relations: ['user'] });
|
|
173
|
+
if (inCharge?.user)
|
|
174
|
+
return [inCharge.user];
|
|
175
|
+
}
|
|
176
|
+
return await (0, legal_record_support_1.holdersOf)(tx, domain, exports.LEGAL_REGISTRATION_CATEGORY);
|
|
177
|
+
}
|
|
178
|
+
/** An employee as the centre change is judged by, or null where there is none. */
|
|
179
|
+
const centreEmployeeStateOf = (one) => one ? { departmentId: one.departmentId ?? null, hiredOn: one.hiredOn ?? null, retiredOn: one.retiredOn ?? null, active: one.active ?? null } : null;
|
|
180
|
+
exports.centreEmployeeStateOf = centreEmployeeStateOf;
|
|
181
|
+
/**
|
|
182
|
+
* What an employee's change makes the research centres file (organization saves it; the subscriber calls this in the
|
|
183
|
+
* same transaction). One change per centre, employee and reason stays open until filed; a researcher who left or moved
|
|
184
|
+
* out is ended on the centre's list.
|
|
185
|
+
*/
|
|
186
|
+
async function noteCentreEmployeeChange(tx, employeeId, before) {
|
|
187
|
+
const employee = await tx.getRepository(organization_1.Employee).findOne({ where: { id: employeeId }, relations: ['domain'] });
|
|
188
|
+
const domain = employee?.domain;
|
|
189
|
+
if (!domain)
|
|
190
|
+
return [];
|
|
191
|
+
const centres = await tx.getRepository(legal_registration_1.LegalRegistration).find({ where: { domain: { id: domain.id }, kind: (0, typeorm_1.In)(RESEARCH_KINDS), endedOn: (0, typeorm_1.IsNull)() } });
|
|
192
|
+
if (!centres.length)
|
|
193
|
+
return [];
|
|
194
|
+
const listings = await tx.getRepository(legal_registration_1.LegalResearcher).find({ where: { registration: { id: (0, typeorm_1.In)(centres.map(one => one.id)) }, employee: { id: employeeId }, toOn: (0, typeorm_1.IsNull)() } });
|
|
195
|
+
const today = (0, employee_reader_1.todayIn)(domain);
|
|
196
|
+
const changes = (0, legal_registration_rules_1.centreChangesOf)(employeeId, before, (0, exports.centreEmployeeStateOf)(employee), centres.map(one => ({ id: one.id, departmentId: one.departmentId, researcherIds: listings.some(listing => listing.registrationId === one.id) ? [employeeId] : [] })), today);
|
|
197
|
+
const repository = tx.getRepository(legal_registration_1.LegalCentreChange);
|
|
198
|
+
const written = [];
|
|
199
|
+
for (const change of changes) {
|
|
200
|
+
const open = await repository.count({ where: { registration: { id: change.centreId }, employee: { id: employeeId }, reason: change.reason, filedOn: (0, typeorm_1.IsNull)() } });
|
|
201
|
+
if (open)
|
|
202
|
+
continue;
|
|
203
|
+
const centre = centres.find(one => one.id === change.centreId);
|
|
204
|
+
if (change.reason !== legal_registration_rules_1.CentreChangeReason.JOINED)
|
|
205
|
+
for (const listing of listings.filter(one => one.registrationId === centre.id))
|
|
206
|
+
await tx.getRepository(legal_registration_1.LegalResearcher).save(Object.assign(listing, { toOn: change.aroseOn }));
|
|
207
|
+
const row = await repository.save(repository.create({ domain, registration: centre, employee, reason: change.reason, aroseOn: change.aroseOn, dueOn: change.dueOn }));
|
|
208
|
+
const ids = [];
|
|
209
|
+
for (const assignee of await askedFor(tx, domain, centre)) {
|
|
210
|
+
const id = await (0, legal_todo_1.issueLegalTodo)(tx, domain, {
|
|
211
|
+
assignee,
|
|
212
|
+
name: `연구소 변경 신고 — ${employee.name} ${REASON_WORDS[change.reason]}`,
|
|
213
|
+
headline: `${centre.title ?? '연구소'} · ${employee.name} ${REASON_WORDS[change.reason]} ${change.aroseOn} · ${change.dueOn} 까지 신고`,
|
|
214
|
+
address: 'legal-registration-list',
|
|
215
|
+
subjectKind: 'LegalCentreChange',
|
|
216
|
+
subjectId: row.id,
|
|
217
|
+
/* Noon UTC of the due day falls on that day from UTC-12 to UTC+11 - a day, not an hour, is what the law counts. */
|
|
218
|
+
dueAt: new Date(`${change.dueOn}T12:00:00Z`)
|
|
219
|
+
});
|
|
220
|
+
if (id)
|
|
221
|
+
ids.push(id);
|
|
222
|
+
}
|
|
223
|
+
row.todoInstanceIds = ids;
|
|
224
|
+
written.push(await repository.save(row));
|
|
225
|
+
}
|
|
226
|
+
return written;
|
|
227
|
+
}
|
|
228
|
+
/* The ledger's part of an application's management check (ADR-0146) - judged here, counted there. */
|
|
229
|
+
async function liveRegistrations(tx, domain) {
|
|
230
|
+
return await tx.getRepository(legal_registration_1.LegalRegistration).find({ where: { domain: { id: domain.id }, endedOn: (0, typeorm_1.IsNull)() }, order: { expiresOn: 'ASC' } });
|
|
231
|
+
}
|
|
232
|
+
/** Registrations expiring within 90 days, or past their expiry. */
|
|
233
|
+
async function legalRegistrationsExpiring(tx, domain, today) {
|
|
234
|
+
return (await liveRegistrations(tx, domain)).filter(one => (0, legal_registration_rules_1.registrationExpiringSoon)(one, today));
|
|
235
|
+
}
|
|
236
|
+
/** Registrations inside their renewal window. */
|
|
237
|
+
async function legalRegistrationsInRenewalWindow(tx, domain, today) {
|
|
238
|
+
return (await liveRegistrations(tx, domain)).filter(one => (0, legal_registration_rules_1.registrationInRenewalWindow)(one, today));
|
|
239
|
+
}
|
|
240
|
+
/** Registrations with a fee due within 30 days, or past its day. */
|
|
241
|
+
async function legalRegistrationFeesDue(tx, domain, today) {
|
|
242
|
+
return (await liveRegistrations(tx, domain)).filter(one => (0, legal_registration_rules_1.registrationFeeDueSoon)(one, today));
|
|
243
|
+
}
|
|
244
|
+
/** Research centre changes not filed - past their due day first. `today` is the check's; every one unfiled is raised. */
|
|
245
|
+
async function legalCentreChangesNotFiled(tx, domain, _today) {
|
|
246
|
+
return await tx.getRepository(legal_registration_1.LegalCentreChange).find({ where: { domain: { id: domain.id }, filedOn: (0, typeorm_1.IsNull)() }, order: { dueOn: 'ASC' } });
|
|
247
|
+
}
|
|
248
|
+
//# sourceMappingURL=legal-registration-service.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"legal-registration-service.js","sourceRoot":"","sources":["../../../server/service/legal-registration/legal-registration-service.ts"],"names":[],"mappings":";;;AAiDA,wDAqCC;AAWD,oDA6BC;AAGD,8CAqBC;AAoBD,4DA0CC;AASD,gEAEC;AAGD,8EAEC;AAGD,4DAEC;AAGD,gEAEC;AA9OD,qCAAmD;AAGnD,+DAAmE;AACnE,iDAA+C;AAE/C,qDAAwD;AACxD,+DAAmD;AACnD,qDAAqE;AACrE,+CAA4C;AAC5C,+EAAgF;AAChF,6DAA4F;AAC5F,yEAYmC;AAGnC;;;GAGG;AAEU,QAAA,2BAA2B,GAAG,oBAAoB,CAAA;AAClD,QAAA,2BAA2B,GAAG,+BAA+B,CAAA;AAC1E,MAAM,cAAc,GAAG,mDAAwB,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,CAAC,IAAI,CAAC,CAAA;AACnG,MAAM,YAAY,GAAuC,EAAE,IAAI,EAAE,IAAI,EAAE,SAAS,EAAE,cAAc,EAAE,MAAM,EAAE,cAAc,EAAE,CAAA;AAC1H,MAAM,QAAQ,GAAG,CAAC,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,WAAW,EAAE,WAAW,EAAE,WAAW,EAAE,eAAe,EAAE,cAAc,EAAE,SAAS,EAAE,OAAO,CAAU,CAAA;AAEjJ,MAAM,QAAQ,GAAG,GAAG,EAAE,CAAC,IAAI,eAAO,CAAC,8BAA8B,EAAE,EAAE,EAAE,iDAAiD,CAAC,CAAA;AACzH,MAAM,YAAY,GAAG,GAAG,EAAE,CAAC,IAAI,eAAO,CAAC,4BAA4B,EAAE,EAAE,EAAE,yDAAyD,CAAC,CAAA;AAEnI,KAAK,UAAU,UAAU,CAAC,EAAiB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AC7D,KAAK,UAAU,wBAAwB,CAAC,EAAiB,EAAE,MAAsB,EAAE,KAAa;IACrG,OAAO,CAAC,MAAM,iBAAiB,CAAC,EAAE,EAAE,MAAM,CAAC,CAAC,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,CAAC,IAAA,iDAAsB,EAAC,GAAG,EAAE,KAAK,CAAC,CAAC,CAAA;AAChG,CAAC;AAED,yHAAyH;AAClH,KAAK,UAAU,0BAA0B,CAAC,EAAiB,EAAE,MAAsB,EAAE,MAAc;IACxG,OAAO,MAAM,EAAE,CAAC,aAAa,CAAC,sCAAiB,CAAC,CAAC,IAAI,CAAC,EAAE,KAAK,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE,EAAE,MAAM,CAAC,EAAE,EAAE,EAAE,OAAO,EAAE,IAAA,gBAAM,GAAE,EAAS,EAAE,KAAK,EAAE,EAAE,KAAK,EAAE,KAAK,EAAS,EAAE,CAAC,CAAA;AAC3J,CAAC","sourcesContent":["import { EntityManager, In, IsNull } from 'typeorm'\n\nimport { User } from '@things-factory/auth-base'\nimport { Department, Employee } from '@things-factory/organization'\nimport { Refusal } from '@things-factory/shell'\n\nimport { recordCorrections } from '../common/correction'\nimport { todayIn } from '../common/employee-reader'\nimport { closeLegalTodo, issueLegalTodo } from '../common/legal-todo'\nimport { isDay } from '../legal-record/days'\nimport { fieldsOf, holdersOf, text } from '../legal-record/legal-record-support'\nimport { LegalCentreChange, LegalRegistration, LegalResearcher } from './legal-registration'\nimport {\n CentreChangeReason,\n centreChangesOf,\n CentreEmployeeState,\n expiresOnOf,\n registrationExpiringSoon,\n registrationFeeDueSoon,\n registrationInRenewalWindow,\n legalRegistrationKindOf,\n LEGAL_REGISTRATION_KINDS,\n legalRegistrationRefusal,\n renewalFromOnOf\n} from './legal-registration-rules'\nimport { LegalCentreChangePatch, LegalRegistrationPatch, LegalResearcherPatch } from './legal-registration-type'\n\n/*\n * The ledger of registrations (ADR-0187 decision 23): rows written and corrected, never deleted; a research centre's\n * researchers; the changes organization makes it file, each a to-do closed by writing the day it was filed.\n */\n\nexport const LEGAL_REGISTRATION_CATEGORY = 'legal-registration'\nexport const LEGAL_REGISTRATION_REF_TYPE = 'compliance-legal-registration'\nconst RESEARCH_KINDS = LEGAL_REGISTRATION_KINDS.filter(one => one.researchers).map(one => one.code)\nconst REASON_WORDS: Record<CentreChangeReason, string> = { LEFT: '퇴사', MOVED_OUT: '부서 이동(연구소 밖)', JOINED: '입사 · 이동(연구소)' }\nconst WRITABLE = ['kind', 'title', 'number', 'authority', 'grantedOn', 'expiresOn', 'renewalFromOn', 'nextFeeDueOn', 'endedOn', 'notes'] as const\n\nconst notFound = () => new Refusal('legal-registration-not-found', {}, 'the record was not found. reload and try again.')\nconst notDeletable = () => new Refusal('legal-record-not-deletable', {}, 'a legal record is never deleted - end it, or correct it')\n\nasync function employeeOf(tx: EntityManager, domain: any, id: string | null | undefined, field: string): Promise<Employee | null> {\n if (!id) return null\n const one = await tx.getRepository(Employee).findOne({ where: { id, domain: { id: domain.id } } as any })\n if (!one) throw new Refusal('legal-registration-employee-unknown', { field }, `${field} must be an employee of this domain`)\n return one\n}\n\n/** Writes the ledger's new and changed rows - a deleted one is refused. */\nexport async function saveLegalRegistrations(patches: LegalRegistrationPatch[], context: ResolverContext): Promise<LegalRegistration[]> {\n const { domain, user, tx } = context.state\n const repository = tx.getRepository(LegalRegistration)\n const saved: LegalRegistration[] = []\n for (const patch of patches) {\n if (patch.cuFlag === '-') throw notDeletable()\n const row: LegalRegistration = patch.id ? await repository.findOne({ where: { id: patch.id, domain: { id: domain.id } } as any }) : (repository.create({ domain, creator: user } as any) as any)\n if (!row) throw notFound()\n const before = { ...row }\n const given = new Set(fieldsOf(patch))\n for (const field of WRITABLE) if (given.has(field)) (row as any)[field] = text((patch as any)[field])\n if (given.has('inChargeId')) row.inCharge = await employeeOf(tx, domain, text(patch.inChargeId), 'inCharge')\n if (given.has('departmentId')) {\n const id = text(patch.departmentId)\n row.department = id ? await tx.getRepository(Department).findOne({ where: { id, domain: { id: domain.id } } as any }) : null\n if (id && !row.department) throw new Refusal('legal-registration-department-unknown', {}, 'the department must be of this domain')\n }\n if (given.has('assetId')) row.assetId = text(patch.assetId)\n\n /* A day the kind counts is counted when nobody wrote it - and again when what it is counted from changes. */\n const counted = given.has('kind') || given.has('grantedOn')\n if (!given.has('expiresOn') && counted) row.expiresOn = expiresOnOf(row.kind, row.grantedOn) ?? row.expiresOn\n if (!given.has('renewalFromOn') && (counted || given.has('expiresOn'))) row.renewalFromOn = renewalFromOnOf(row.kind, row.expiresOn) ?? row.renewalFromOn\n\n const refusal = legalRegistrationRefusal(row)\n if (refusal) throw refusal\n if (row.department && !legalRegistrationKindOf(row.kind)?.researchers) throw new Refusal('legal-registration-department-of-centre', {}, 'only a research centre or an R&D department has a department')\n row.updater = user\n saved.push(await repository.save(row))\n const after = {\n ...row,\n inChargeId: given.has('inChargeId') ? (row.inCharge?.id ?? null) : row.inChargeId,\n departmentId: given.has('departmentId') ? (row.department?.id ?? null) : row.departmentId\n }\n await recordCorrections(tx, domain, user, { kind: 'LegalRegistration', id: row.id }, before, after, [...WRITABLE, 'inChargeId', 'departmentId', 'assetId'])\n }\n return saved\n}\n\n/** A research centre of the domain, refused for another kind. */\nasync function centreOf(tx: EntityManager, domain: any, id: string): Promise<LegalRegistration> {\n const centre = await tx.getRepository(LegalRegistration).findOne({ where: { id, domain: { id: domain.id } } as any })\n if (!centre) throw notFound()\n if (!legalRegistrationKindOf(centre.kind)?.researchers) throw new Refusal('legal-registration-not-a-centre', {}, 'only a research centre or an R&D department lists researchers')\n return centre\n}\n\n/** Writes a centre's researchers - listed from a day, ended on a day; a row is never deleted. */\nexport async function saveLegalResearchers(registrationId: string, patches: LegalResearcherPatch[], context: ResolverContext): Promise<LegalResearcher[]> {\n const { domain, user, tx } = context.state\n const centre = await centreOf(tx, domain, registrationId)\n const repository = tx.getRepository(LegalResearcher)\n const saved: LegalResearcher[] = []\n for (const patch of patches) {\n if (patch.cuFlag === '-') throw notDeletable()\n let row: LegalResearcher\n if (patch.id) {\n row = await repository.findOne({ where: { id: patch.id, registration: { id: centre.id } } as any })\n if (!row) throw notFound()\n if (patch.employeeId && patch.employeeId !== row.employeeId) throw new Refusal('legal-researcher-employee-fixed', {}, 'the researcher of a row stays - end it and add another')\n } else {\n const employee = await employeeOf(tx, domain, text(patch.employeeId), 'employee')\n if (!employee) throw new Refusal('legal-researcher-employee-required', {}, 'pick the employee')\n const listed = await repository.count({ where: { registration: { id: centre.id }, employee: { id: employee.id }, toOn: IsNull() } as any })\n if (listed) throw new Refusal('legal-researcher-listed', { name: employee.name }, `${employee.name} is listed already`)\n row = repository.create({ domain, registration: centre, employee, creator: user } as any) as any\n }\n const before = { ...row }\n if (patch.fromOn !== undefined) row.fromOn = text(patch.fromOn)\n if (patch.toOn !== undefined) row.toOn = text(patch.toOn)\n for (const field of ['fromOn', 'toOn'] as const) if (row[field] && !isDay(row[field])) throw new Refusal('legal-registration-day-invalid', { field }, `${field} is a day, YYYY-MM-DD`)\n if (row.fromOn && row.toOn && row.toOn < row.fromOn) throw new Refusal('legal-researcher-to-before-from', {}, 'listed until is on or after listed from')\n row.updater = user\n saved.push(await repository.save(row))\n await recordCorrections(tx, domain, user, { kind: 'LegalResearcher', id: row.id }, before, row, ['fromOn', 'toOn'])\n }\n return saved\n}\n\n/** Writes the day a centre's change was filed - which closes its to-do. A change is never deleted. */\nexport async function fileCentreChanges(patches: LegalCentreChangePatch[], context: ResolverContext): Promise<LegalCentreChange[]> {\n const { domain, user, tx } = context.state\n const repository = tx.getRepository(LegalCentreChange)\n const saved: LegalCentreChange[] = []\n for (const patch of patches) {\n if (patch.cuFlag === '-' || patch.cuFlag === '+') throw new Refusal('legal-centre-change-written', {}, 'a change is written by the organization - only the day it was filed and the notes are written here')\n const row = await repository.findOne({ where: { id: patch.id, domain: { id: domain.id } } as any })\n if (!row) throw notFound()\n const before = { ...row }\n if (patch.filedOn !== undefined) {\n const day = text(patch.filedOn)\n if (day && (!isDay(day) || day < row.aroseOn)) throw new Refusal('legal-centre-change-filed-invalid', { aroseOn: row.aroseOn }, `it is filed on or after ${row.aroseOn}, YYYY-MM-DD`)\n row.filedOn = day\n }\n if (patch.notes !== undefined) row.notes = text(patch.notes)\n row.updater = user\n saved.push(await repository.save(row))\n await recordCorrections(tx, domain, user, { kind: 'LegalCentreChange', id: row.id }, before, row, ['filedOn', 'notes'])\n if (row.filedOn) for (const id of row.todoInstanceIds ?? []) await closeLegalTodo(tx, domain, id, user, '신고함')\n }\n return saved\n}\n\n/** Who a centre's to-do goes to: the employee in charge, else every holder of the ledger. */\nasync function askedFor(tx: EntityManager, domain: any, centre: LegalRegistration): Promise<User[]> {\n if (centre.inChargeId) {\n const inCharge = await tx.getRepository(Employee).findOne({ where: { id: centre.inChargeId } as any, relations: ['user'] })\n if (inCharge?.user) return [inCharge.user]\n }\n return await holdersOf(tx, domain, LEGAL_REGISTRATION_CATEGORY)\n}\n\n/** An employee as the centre change is judged by, or null where there is none. */\nexport const centreEmployeeStateOf = (one: Employee | null | undefined): CentreEmployeeState | null =>\n one ? { departmentId: one.departmentId ?? null, hiredOn: one.hiredOn ?? null, retiredOn: one.retiredOn ?? null, active: one.active ?? null } : null\n\n/**\n * What an employee's change makes the research centres file (organization saves it; the subscriber calls this in the\n * same transaction). One change per centre, employee and reason stays open until filed; a researcher who left or moved\n * out is ended on the centre's list.\n */\nexport async function noteCentreEmployeeChange(tx: EntityManager, employeeId: string, before: CentreEmployeeState | null): Promise<LegalCentreChange[]> {\n const employee = await tx.getRepository(Employee).findOne({ where: { id: employeeId } as any, relations: ['domain'] })\n const domain = employee?.domain as any\n if (!domain) return []\n const centres = await tx.getRepository(LegalRegistration).find({ where: { domain: { id: domain.id }, kind: In(RESEARCH_KINDS), endedOn: IsNull() } as any })\n if (!centres.length) return []\n const listings = await tx.getRepository(LegalResearcher).find({ where: { registration: { id: In(centres.map(one => one.id)) }, employee: { id: employeeId }, toOn: IsNull() } as any })\n const today = todayIn(domain)\n const changes = centreChangesOf(\n employeeId,\n before,\n centreEmployeeStateOf(employee)!,\n centres.map(one => ({ id: one.id, departmentId: one.departmentId, researcherIds: listings.some(listing => listing.registrationId === one.id) ? [employeeId] : [] })),\n today\n )\n const repository = tx.getRepository(LegalCentreChange)\n const written: LegalCentreChange[] = []\n for (const change of changes) {\n const open = await repository.count({ where: { registration: { id: change.centreId }, employee: { id: employeeId }, reason: change.reason, filedOn: IsNull() } as any })\n if (open) continue\n const centre = centres.find(one => one.id === change.centreId)!\n if (change.reason !== CentreChangeReason.JOINED)\n for (const listing of listings.filter(one => one.registrationId === centre.id)) await tx.getRepository(LegalResearcher).save(Object.assign(listing, { toOn: change.aroseOn }))\n const row = await repository.save(repository.create({ domain, registration: centre, employee, reason: change.reason, aroseOn: change.aroseOn, dueOn: change.dueOn } as any) as any)\n const ids: string[] = []\n for (const assignee of await askedFor(tx, domain, centre)) {\n const id = await issueLegalTodo(tx, domain, {\n assignee,\n name: `연구소 변경 신고 — ${employee.name} ${REASON_WORDS[change.reason]}`,\n headline: `${centre.title ?? '연구소'} · ${employee.name} ${REASON_WORDS[change.reason]} ${change.aroseOn} · ${change.dueOn} 까지 신고`,\n address: 'legal-registration-list',\n subjectKind: 'LegalCentreChange',\n subjectId: row.id,\n /* Noon UTC of the due day falls on that day from UTC-12 to UTC+11 - a day, not an hour, is what the law counts. */\n dueAt: new Date(`${change.dueOn}T12:00:00Z`)\n })\n if (id) ids.push(id)\n }\n row.todoInstanceIds = ids\n written.push(await repository.save(row))\n }\n return written\n}\n\n/* The ledger's part of an application's management check (ADR-0146) - judged here, counted there. */\n\nasync function liveRegistrations(tx: EntityManager, domain: { id: string }): Promise<LegalRegistration[]> {\n return await tx.getRepository(LegalRegistration).find({ where: { domain: { id: domain.id }, endedOn: IsNull() } as any, order: { expiresOn: 'ASC' } as any })\n}\n\n/** Registrations expiring within 90 days, or past their expiry. */\nexport async function legalRegistrationsExpiring(tx: EntityManager, domain: { id: string }, today: string): Promise<LegalRegistration[]> {\n return (await liveRegistrations(tx, domain)).filter(one => registrationExpiringSoon(one, today))\n}\n\n/** Registrations inside their renewal window. */\nexport async function legalRegistrationsInRenewalWindow(tx: EntityManager, domain: { id: string }, today: string): Promise<LegalRegistration[]> {\n return (await liveRegistrations(tx, domain)).filter(one => registrationInRenewalWindow(one, today))\n}\n\n/** Registrations with a fee due within 30 days, or past its day. */\nexport async function legalRegistrationFeesDue(tx: EntityManager, domain: { id: string }, today: string): Promise<LegalRegistration[]> {\n return (await liveRegistrations(tx, domain)).filter(one => registrationFeeDueSoon(one, today))\n}\n\n/** Research centre changes not filed - past their due day first. `today` is the check's; every one unfiled is raised. */\nexport async function legalCentreChangesNotFiled(tx: EntityManager, domain: { id: string }, _today: string): Promise<LegalCentreChange[]> {\n return await tx.getRepository(LegalCentreChange).find({ where: { domain: { id: domain.id }, filedOn: IsNull() } as any, order: { dueOn: 'ASC' } as any })\n}\n"]}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { LegalCentreChange, LegalRegistration, LegalResearcher } from './legal-registration';
|
|
2
|
+
export declare class LegalRegistrationPatch {
|
|
3
|
+
id?: string;
|
|
4
|
+
kind?: string;
|
|
5
|
+
title?: string;
|
|
6
|
+
number?: string;
|
|
7
|
+
authority?: string;
|
|
8
|
+
grantedOn?: string;
|
|
9
|
+
expiresOn?: string;
|
|
10
|
+
renewalFromOn?: string;
|
|
11
|
+
nextFeeDueOn?: string;
|
|
12
|
+
endedOn?: string;
|
|
13
|
+
inChargeId?: string;
|
|
14
|
+
departmentId?: string;
|
|
15
|
+
assetId?: string;
|
|
16
|
+
notes?: string;
|
|
17
|
+
cuFlag?: string;
|
|
18
|
+
}
|
|
19
|
+
export declare class LegalResearcherPatch {
|
|
20
|
+
id?: string;
|
|
21
|
+
employeeId?: string;
|
|
22
|
+
fromOn?: string;
|
|
23
|
+
toOn?: string;
|
|
24
|
+
cuFlag?: string;
|
|
25
|
+
}
|
|
26
|
+
export declare class LegalCentreChangePatch {
|
|
27
|
+
id: string;
|
|
28
|
+
filedOn?: string;
|
|
29
|
+
notes?: string;
|
|
30
|
+
cuFlag?: string;
|
|
31
|
+
}
|
|
32
|
+
export declare class LegalRegistrationKind {
|
|
33
|
+
code: string;
|
|
34
|
+
validYears?: number;
|
|
35
|
+
renewFromMonths?: number;
|
|
36
|
+
yearlyFee: boolean;
|
|
37
|
+
researchers: boolean;
|
|
38
|
+
}
|
|
39
|
+
export declare class LinkedAsset {
|
|
40
|
+
id: string;
|
|
41
|
+
name: string;
|
|
42
|
+
kind?: string;
|
|
43
|
+
}
|
|
44
|
+
export declare class LegalRegistrationList {
|
|
45
|
+
items: LegalRegistration[];
|
|
46
|
+
total: number;
|
|
47
|
+
}
|
|
48
|
+
export declare class LegalResearcherList {
|
|
49
|
+
items: LegalResearcher[];
|
|
50
|
+
total: number;
|
|
51
|
+
}
|
|
52
|
+
export declare class LegalCentreChangeList {
|
|
53
|
+
items: LegalCentreChange[];
|
|
54
|
+
total: number;
|
|
55
|
+
}
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.LegalCentreChangeList = exports.LegalResearcherList = exports.LegalRegistrationList = exports.LinkedAsset = exports.LegalRegistrationKind = exports.LegalCentreChangePatch = exports.LegalResearcherPatch = exports.LegalRegistrationPatch = void 0;
|
|
4
|
+
const tslib_1 = require("tslib");
|
|
5
|
+
const type_graphql_1 = require("type-graphql");
|
|
6
|
+
const legal_registration_1 = require("./legal-registration");
|
|
7
|
+
let LegalRegistrationPatch = class LegalRegistrationPatch {
|
|
8
|
+
};
|
|
9
|
+
exports.LegalRegistrationPatch = LegalRegistrationPatch;
|
|
10
|
+
tslib_1.__decorate([
|
|
11
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.ID, { nullable: true, description: 'Its id - empty for a new row' }),
|
|
12
|
+
tslib_1.__metadata("design:type", String)
|
|
13
|
+
], LegalRegistrationPatch.prototype, "id", void 0);
|
|
14
|
+
tslib_1.__decorate([
|
|
15
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'The kind, of those the module declares' }),
|
|
16
|
+
tslib_1.__metadata("design:type", String)
|
|
17
|
+
], LegalRegistrationPatch.prototype, "kind", void 0);
|
|
18
|
+
tslib_1.__decorate([
|
|
19
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'What it is called' }),
|
|
20
|
+
tslib_1.__metadata("design:type", String)
|
|
21
|
+
], LegalRegistrationPatch.prototype, "title", void 0);
|
|
22
|
+
tslib_1.__decorate([
|
|
23
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Its number' }),
|
|
24
|
+
tslib_1.__metadata("design:type", String)
|
|
25
|
+
], LegalRegistrationPatch.prototype, "number", void 0);
|
|
26
|
+
tslib_1.__decorate([
|
|
27
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Who granted it' }),
|
|
28
|
+
tslib_1.__metadata("design:type", String)
|
|
29
|
+
], LegalRegistrationPatch.prototype, "authority", void 0);
|
|
30
|
+
tslib_1.__decorate([
|
|
31
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'YYYY-MM-DD granted' }),
|
|
32
|
+
tslib_1.__metadata("design:type", String)
|
|
33
|
+
], LegalRegistrationPatch.prototype, "grantedOn", void 0);
|
|
34
|
+
tslib_1.__decorate([
|
|
35
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'YYYY-MM-DD it expires - counted from the kind when empty' }),
|
|
36
|
+
tslib_1.__metadata("design:type", String)
|
|
37
|
+
], LegalRegistrationPatch.prototype, "expiresOn", void 0);
|
|
38
|
+
tslib_1.__decorate([
|
|
39
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'YYYY-MM-DD its renewal may be asked from - counted from the kind when empty' }),
|
|
40
|
+
tslib_1.__metadata("design:type", String)
|
|
41
|
+
], LegalRegistrationPatch.prototype, "renewalFromOn", void 0);
|
|
42
|
+
tslib_1.__decorate([
|
|
43
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'YYYY-MM-DD its next fee is due' }),
|
|
44
|
+
tslib_1.__metadata("design:type", String)
|
|
45
|
+
], LegalRegistrationPatch.prototype, "nextFeeDueOn", void 0);
|
|
46
|
+
tslib_1.__decorate([
|
|
47
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'YYYY-MM-DD it ended' }),
|
|
48
|
+
tslib_1.__metadata("design:type", String)
|
|
49
|
+
], LegalRegistrationPatch.prototype, "endedOn", void 0);
|
|
50
|
+
tslib_1.__decorate([
|
|
51
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'The employee in charge' }),
|
|
52
|
+
tslib_1.__metadata("design:type", String)
|
|
53
|
+
], LegalRegistrationPatch.prototype, "inChargeId", void 0);
|
|
54
|
+
tslib_1.__decorate([
|
|
55
|
+
(0, type_graphql_1.Field)({ nullable: true, description: "A research centre's department" }),
|
|
56
|
+
tslib_1.__metadata("design:type", String)
|
|
57
|
+
], LegalRegistrationPatch.prototype, "departmentId", void 0);
|
|
58
|
+
tslib_1.__decorate([
|
|
59
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'The asset register row it is' }),
|
|
60
|
+
tslib_1.__metadata("design:type", String)
|
|
61
|
+
], LegalRegistrationPatch.prototype, "assetId", void 0);
|
|
62
|
+
tslib_1.__decorate([
|
|
63
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Notes' }),
|
|
64
|
+
tslib_1.__metadata("design:type", String)
|
|
65
|
+
], LegalRegistrationPatch.prototype, "notes", void 0);
|
|
66
|
+
tslib_1.__decorate([
|
|
67
|
+
(0, type_graphql_1.Field)({ nullable: true, description: '+ new, M changed - a row is never deleted' }),
|
|
68
|
+
tslib_1.__metadata("design:type", String)
|
|
69
|
+
], LegalRegistrationPatch.prototype, "cuFlag", void 0);
|
|
70
|
+
exports.LegalRegistrationPatch = LegalRegistrationPatch = tslib_1.__decorate([
|
|
71
|
+
(0, type_graphql_1.InputType)({ description: 'A registration of the ledger as the grid writes it - all fields of a new row, the changed ones otherwise' })
|
|
72
|
+
], LegalRegistrationPatch);
|
|
73
|
+
let LegalResearcherPatch = class LegalResearcherPatch {
|
|
74
|
+
};
|
|
75
|
+
exports.LegalResearcherPatch = LegalResearcherPatch;
|
|
76
|
+
tslib_1.__decorate([
|
|
77
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.ID, { nullable: true, description: 'Its id - empty for a new row' }),
|
|
78
|
+
tslib_1.__metadata("design:type", String)
|
|
79
|
+
], LegalResearcherPatch.prototype, "id", void 0);
|
|
80
|
+
tslib_1.__decorate([
|
|
81
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'The employee - a new row only' }),
|
|
82
|
+
tslib_1.__metadata("design:type", String)
|
|
83
|
+
], LegalResearcherPatch.prototype, "employeeId", void 0);
|
|
84
|
+
tslib_1.__decorate([
|
|
85
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'YYYY-MM-DD listed from' }),
|
|
86
|
+
tslib_1.__metadata("design:type", String)
|
|
87
|
+
], LegalResearcherPatch.prototype, "fromOn", void 0);
|
|
88
|
+
tslib_1.__decorate([
|
|
89
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'YYYY-MM-DD listed until' }),
|
|
90
|
+
tslib_1.__metadata("design:type", String)
|
|
91
|
+
], LegalResearcherPatch.prototype, "toOn", void 0);
|
|
92
|
+
tslib_1.__decorate([
|
|
93
|
+
(0, type_graphql_1.Field)({ nullable: true, description: '+ new, M changed - a row is never deleted' }),
|
|
94
|
+
tslib_1.__metadata("design:type", String)
|
|
95
|
+
], LegalResearcherPatch.prototype, "cuFlag", void 0);
|
|
96
|
+
exports.LegalResearcherPatch = LegalResearcherPatch = tslib_1.__decorate([
|
|
97
|
+
(0, type_graphql_1.InputType)({ description: 'A researcher of a research centre as the grid writes it' })
|
|
98
|
+
], LegalResearcherPatch);
|
|
99
|
+
let LegalCentreChangePatch = class LegalCentreChangePatch {
|
|
100
|
+
};
|
|
101
|
+
exports.LegalCentreChangePatch = LegalCentreChangePatch;
|
|
102
|
+
tslib_1.__decorate([
|
|
103
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.ID, { description: 'The change' }),
|
|
104
|
+
tslib_1.__metadata("design:type", String)
|
|
105
|
+
], LegalCentreChangePatch.prototype, "id", void 0);
|
|
106
|
+
tslib_1.__decorate([
|
|
107
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'YYYY-MM-DD it was filed' }),
|
|
108
|
+
tslib_1.__metadata("design:type", String)
|
|
109
|
+
], LegalCentreChangePatch.prototype, "filedOn", void 0);
|
|
110
|
+
tslib_1.__decorate([
|
|
111
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Notes' }),
|
|
112
|
+
tslib_1.__metadata("design:type", String)
|
|
113
|
+
], LegalCentreChangePatch.prototype, "notes", void 0);
|
|
114
|
+
tslib_1.__decorate([
|
|
115
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'M changed' }),
|
|
116
|
+
tslib_1.__metadata("design:type", String)
|
|
117
|
+
], LegalCentreChangePatch.prototype, "cuFlag", void 0);
|
|
118
|
+
exports.LegalCentreChangePatch = LegalCentreChangePatch = tslib_1.__decorate([
|
|
119
|
+
(0, type_graphql_1.InputType)({ description: 'The filing of a research centre change - the day it was filed and the notes' })
|
|
120
|
+
], LegalCentreChangePatch);
|
|
121
|
+
let LegalRegistrationKind = class LegalRegistrationKind {
|
|
122
|
+
};
|
|
123
|
+
exports.LegalRegistrationKind = LegalRegistrationKind;
|
|
124
|
+
tslib_1.__decorate([
|
|
125
|
+
(0, type_graphql_1.Field)({ description: 'The code - VENTURE, PATENT ...' }),
|
|
126
|
+
tslib_1.__metadata("design:type", String)
|
|
127
|
+
], LegalRegistrationKind.prototype, "code", void 0);
|
|
128
|
+
tslib_1.__decorate([
|
|
129
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.Int, { nullable: true, description: 'Years a grant stands' }),
|
|
130
|
+
tslib_1.__metadata("design:type", Number)
|
|
131
|
+
], LegalRegistrationKind.prototype, "validYears", void 0);
|
|
132
|
+
tslib_1.__decorate([
|
|
133
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.Int, { nullable: true, description: 'Months before expiry a renewal may be asked' }),
|
|
134
|
+
tslib_1.__metadata("design:type", Number)
|
|
135
|
+
], LegalRegistrationKind.prototype, "renewFromMonths", void 0);
|
|
136
|
+
tslib_1.__decorate([
|
|
137
|
+
(0, type_graphql_1.Field)({ description: 'Kept by a fee due every year' }),
|
|
138
|
+
tslib_1.__metadata("design:type", Boolean)
|
|
139
|
+
], LegalRegistrationKind.prototype, "yearlyFee", void 0);
|
|
140
|
+
tslib_1.__decorate([
|
|
141
|
+
(0, type_graphql_1.Field)({ description: 'Lists researchers and files their changes' }),
|
|
142
|
+
tslib_1.__metadata("design:type", Boolean)
|
|
143
|
+
], LegalRegistrationKind.prototype, "researchers", void 0);
|
|
144
|
+
exports.LegalRegistrationKind = LegalRegistrationKind = tslib_1.__decorate([
|
|
145
|
+
(0, type_graphql_1.ObjectType)({ description: 'A kind of registration the module declares, with its deadline rule' })
|
|
146
|
+
], LegalRegistrationKind);
|
|
147
|
+
let LinkedAsset = class LinkedAsset {
|
|
148
|
+
};
|
|
149
|
+
exports.LinkedAsset = LinkedAsset;
|
|
150
|
+
tslib_1.__decorate([
|
|
151
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.ID, { description: 'Its id' }),
|
|
152
|
+
tslib_1.__metadata("design:type", String)
|
|
153
|
+
], LinkedAsset.prototype, "id", void 0);
|
|
154
|
+
tslib_1.__decorate([
|
|
155
|
+
(0, type_graphql_1.Field)({ description: 'Its name' }),
|
|
156
|
+
tslib_1.__metadata("design:type", String)
|
|
157
|
+
], LinkedAsset.prototype, "name", void 0);
|
|
158
|
+
tslib_1.__decorate([
|
|
159
|
+
(0, type_graphql_1.Field)({ nullable: true, description: 'Its kind' }),
|
|
160
|
+
tslib_1.__metadata("design:type", String)
|
|
161
|
+
], LinkedAsset.prototype, "kind", void 0);
|
|
162
|
+
exports.LinkedAsset = LinkedAsset = tslib_1.__decorate([
|
|
163
|
+
(0, type_graphql_1.ObjectType)({ description: 'The asset register row a registration is - which one, nothing of its amounts' })
|
|
164
|
+
], LinkedAsset);
|
|
165
|
+
let LegalRegistrationList = class LegalRegistrationList {
|
|
166
|
+
};
|
|
167
|
+
exports.LegalRegistrationList = LegalRegistrationList;
|
|
168
|
+
tslib_1.__decorate([
|
|
169
|
+
(0, type_graphql_1.Field)(type => [legal_registration_1.LegalRegistration], { description: 'The rows' }),
|
|
170
|
+
tslib_1.__metadata("design:type", Array)
|
|
171
|
+
], LegalRegistrationList.prototype, "items", void 0);
|
|
172
|
+
tslib_1.__decorate([
|
|
173
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.Int, { description: 'How many there are' }),
|
|
174
|
+
tslib_1.__metadata("design:type", Number)
|
|
175
|
+
], LegalRegistrationList.prototype, "total", void 0);
|
|
176
|
+
exports.LegalRegistrationList = LegalRegistrationList = tslib_1.__decorate([
|
|
177
|
+
(0, type_graphql_1.ObjectType)({ description: 'A page of the ledger' })
|
|
178
|
+
], LegalRegistrationList);
|
|
179
|
+
let LegalResearcherList = class LegalResearcherList {
|
|
180
|
+
};
|
|
181
|
+
exports.LegalResearcherList = LegalResearcherList;
|
|
182
|
+
tslib_1.__decorate([
|
|
183
|
+
(0, type_graphql_1.Field)(type => [legal_registration_1.LegalResearcher], { description: 'The rows' }),
|
|
184
|
+
tslib_1.__metadata("design:type", Array)
|
|
185
|
+
], LegalResearcherList.prototype, "items", void 0);
|
|
186
|
+
tslib_1.__decorate([
|
|
187
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.Int, { description: 'How many there are' }),
|
|
188
|
+
tslib_1.__metadata("design:type", Number)
|
|
189
|
+
], LegalResearcherList.prototype, "total", void 0);
|
|
190
|
+
exports.LegalResearcherList = LegalResearcherList = tslib_1.__decorate([
|
|
191
|
+
(0, type_graphql_1.ObjectType)({ description: 'The researchers of a centre' })
|
|
192
|
+
], LegalResearcherList);
|
|
193
|
+
let LegalCentreChangeList = class LegalCentreChangeList {
|
|
194
|
+
};
|
|
195
|
+
exports.LegalCentreChangeList = LegalCentreChangeList;
|
|
196
|
+
tslib_1.__decorate([
|
|
197
|
+
(0, type_graphql_1.Field)(type => [legal_registration_1.LegalCentreChange], { description: 'The rows' }),
|
|
198
|
+
tslib_1.__metadata("design:type", Array)
|
|
199
|
+
], LegalCentreChangeList.prototype, "items", void 0);
|
|
200
|
+
tslib_1.__decorate([
|
|
201
|
+
(0, type_graphql_1.Field)(type => type_graphql_1.Int, { description: 'How many there are' }),
|
|
202
|
+
tslib_1.__metadata("design:type", Number)
|
|
203
|
+
], LegalCentreChangeList.prototype, "total", void 0);
|
|
204
|
+
exports.LegalCentreChangeList = LegalCentreChangeList = tslib_1.__decorate([
|
|
205
|
+
(0, type_graphql_1.ObjectType)({ description: 'The changes of a centre to file' })
|
|
206
|
+
], LegalCentreChangeList);
|
|
207
|
+
//# sourceMappingURL=legal-registration-type.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"legal-registration-type.js","sourceRoot":"","sources":["../../../server/service/legal-registration/legal-registration-type.ts"],"names":[],"mappings":";;;;AAAA,+CAAoE;AAEpE,6DAA4F;AAGrF,IAAM,sBAAsB,GAA5B,MAAM,sBAAsB;CAgBlC,CAAA;AAhBY,wDAAsB;AACmD;IAAnF,IAAA,oBAAK,EAAC,IAAI,CAAC,EAAE,CAAC,iBAAE,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,8BAA8B,EAAE,CAAC;;kDAAY;AACb;IAAjF,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,wCAAwC,EAAE,CAAC;;oDAAc;AAClC;IAA5D,IAAA,oBAAK,EAAC,EAAE,QAAQ,EAAE,IAAI,EAAE,WAAW,EAAE,mBAAmB,EAAE,CAAC;;qDAAe;AACrB;IAArD,IAAA,o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,WAAW,EAAE,oBAAoB,EAAE,CAAC;;oDAAc;gCAF7D,qBAAqB;IADjC,IAAA,yBAAU,EAAC,EAAE,WAAW,EAAE,iCAAiC,EAAE,CAAC;GAClD,qBAAqB,CAGjC","sourcesContent":["import { Field, ID, InputType, Int, ObjectType } from 'type-graphql'\n\nimport { LegalCentreChange, LegalRegistration, LegalResearcher } from './legal-registration'\n\n@InputType({ description: 'A registration of the ledger as the grid writes it - all fields of a new row, the changed ones otherwise' })\nexport class LegalRegistrationPatch {\n @Field(type => ID, { nullable: true, description: 'Its id - empty for a new row' }) id?: string\n @Field({ nullable: true, description: 'The kind, of those the module declares' }) kind?: string\n @Field({ nullable: true, description: 'What it is called' }) title?: string\n @Field({ nullable: true, description: 'Its number' }) number?: string\n @Field({ nullable: true, description: 'Who granted it' }) authority?: string\n @Field({ nullable: true, description: 'YYYY-MM-DD granted' }) grantedOn?: string\n @Field({ nullable: true, description: 'YYYY-MM-DD it expires - counted from the kind when empty' }) expiresOn?: string\n @Field({ nullable: true, description: 'YYYY-MM-DD its renewal may be asked from - counted from the kind when empty' }) renewalFromOn?: string\n @Field({ nullable: true, description: 'YYYY-MM-DD its next fee is due' }) nextFeeDueOn?: string\n @Field({ nullable: true, description: 'YYYY-MM-DD it ended' }) endedOn?: string\n @Field({ nullable: true, description: 'The employee in charge' }) inChargeId?: string\n @Field({ nullable: true, description: \"A research centre's department\" }) departmentId?: string\n @Field({ nullable: true, description: 'The asset register row it is' }) assetId?: string\n @Field({ nullable: true, description: 'Notes' }) notes?: string\n @Field({ nullable: true, description: '+ new, M changed - a row is never deleted' }) cuFlag?: string\n}\n\n@InputType({ description: 'A researcher of a research centre as the grid writes it' })\nexport class LegalResearcherPatch {\n @Field(type => ID, { nullable: true, description: 'Its id - empty for a new row' }) id?: string\n @Field({ nullable: true, description: 'The employee - a new row only' }) employeeId?: string\n @Field({ nullable: true, description: 'YYYY-MM-DD listed from' }) fromOn?: string\n @Field({ nullable: true, description: 'YYYY-MM-DD listed until' }) toOn?: string\n @Field({ nullable: true, description: '+ new, M changed - a row is never deleted' }) cuFlag?: string\n}\n\n@InputType({ description: 'The filing of a research centre change - the day it was filed and the notes' })\nexport class LegalCentreChangePatch {\n @Field(type => ID, { description: 'The change' }) id: string\n @Field({ nullable: true, description: 'YYYY-MM-DD it was filed' }) filedOn?: string\n @Field({ nullable: true, description: 'Notes' }) notes?: string\n @Field({ nullable: true, description: 'M changed' }) cuFlag?: string\n}\n\n@ObjectType({ description: 'A kind of registration the module declares, with its deadline rule' })\nexport class LegalRegistrationKind {\n @Field({ description: 'The code - VENTURE, PATENT ...' }) code: string\n @Field(type => Int, { nullable: true, description: 'Years a grant stands' }) validYears?: number\n @Field(type => Int, { nullable: true, description: 'Months before expiry a renewal may be asked' }) renewFromMonths?: number\n @Field({ description: 'Kept by a fee due every year' }) yearlyFee: boolean\n @Field({ description: 'Lists researchers and files their changes' }) researchers: boolean\n}\n\n@ObjectType({ description: 'The asset register row a registration is - which one, nothing of its amounts' })\nexport class LinkedAsset {\n @Field(type => ID, { description: 'Its id' }) id: string\n @Field({ description: 'Its name' }) name: string\n @Field({ nullable: true, description: 'Its kind' }) kind?: string\n}\n\n@ObjectType({ description: 'A page of the ledger' })\nexport class LegalRegistrationList {\n @Field(type => [LegalRegistration], { description: 'The rows' }) items: LegalRegistration[]\n @Field(type => Int, { description: 'How many there are' }) total: number\n}\n\n@ObjectType({ description: 'The researchers of a centre' })\nexport class LegalResearcherList {\n @Field(type => [LegalResearcher], { description: 'The rows' }) items: LegalResearcher[]\n @Field(type => Int, { description: 'How many there are' }) total: number\n}\n\n@ObjectType({ description: 'The changes of a centre to file' })\nexport class LegalCentreChangeList {\n @Field(type => [LegalCentreChange], { description: 'The rows' }) items: LegalCentreChange[]\n @Field(type => Int, { description: 'How many there are' }) total: number\n}\n"]}
|