@hed-hog/operations 0.0.327 → 0.0.329
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/controllers/operations-tasks.controller.d.ts +3 -3
- package/dist/operations.service.d.ts +3 -3
- package/hedhog/frontend/app/_components/collaborator-form-screen.tsx.ejs +7 -7
- package/hedhog/frontend/app/_components/department-picker.tsx.ejs +125 -0
- package/hedhog/frontend/app/_components/department-select-with-create.tsx.ejs +64 -325
- package/hedhog/frontend/app/_components/project-form-screen.tsx.ejs +16 -16
- package/hedhog/frontend/app/_components/system-user-picker.tsx.ejs +198 -0
- package/hedhog/frontend/app/_components/system-user-select-with-create.tsx.ejs +107 -569
- package/hedhog/frontend/messages/en.json +79 -10
- package/hedhog/frontend/messages/operations/en.json +67 -3
- package/hedhog/frontend/messages/operations/pt.json +67 -3
- package/hedhog/frontend/messages/pt.json +77 -8
- package/package.json +5 -5
- package/hedhog/frontend/app/_components/collaborator-details-screen.tsx.ejs +0 -476
- package/hedhog/frontend/app/_components/collaborator-select-with-create.tsx.ejs +0 -261
- package/hedhog/frontend/app/_components/contract-content-editor.tsx.ejs +0 -258
- package/hedhog/frontend/app/_components/person-select-with-create.tsx.ejs +0 -1
- package/hedhog/frontend/messages/en.json.ejs +0 -2060
- package/hedhog/frontend/messages/operations/operations/en.json +0 -2102
- package/hedhog/frontend/messages/operations/operations/pt.json +0 -2111
- package/hedhog/frontend/messages/pt.json.ejs +0 -2067
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/async-options-combobox.d.ts +0 -29
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/async-options-combobox.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/async-options-combobox.js +0 -95
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/async-options-combobox.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/async-options-combobox.tsx +0 -233
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-costs-section.d.ts +0 -10
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-costs-section.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-costs-section.js +0 -577
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-costs-section.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-costs-section.tsx +0 -868
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-details-screen.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-details-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-details-screen.js +0 -337
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-details-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-details-screen.tsx +0 -476
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-form-screen.d.ts +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-form-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-form-screen.js +0 -1348
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-form-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-form-screen.tsx +0 -2233
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-select-with-create.d.ts +0 -12
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-select-with-create.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-select-with-create.js +0 -162
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-select-with-create.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/collaborator-select-with-create.tsx +0 -261
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-content-editor.d.ts +0 -18
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-content-editor.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-content-editor.js +0 -145
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-content-editor.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-content-editor.tsx +0 -258
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-details-screen.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-details-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-details-screen.js +0 -223
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-details-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-details-screen.tsx +0 -342
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-form-screen.d.ts +0 -58
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-form-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-form-screen.js +0 -438
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-form-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/contract-form-screen.tsx +0 -698
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/department-select-with-create.d.ts +0 -20
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/department-select-with-create.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/department-select-with-create.js +0 -233
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/department-select-with-create.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/department-select-with-create.tsx +0 -392
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/my-project-summary-screen.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/my-project-summary-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/my-project-summary-screen.js +0 -814
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/my-project-summary-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/my-project-summary-screen.tsx +0 -1288
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-calendar-view.d.ts +0 -21
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-calendar-view.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-calendar-view.js +0 -174
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-calendar-view.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-calendar-view.tsx +0 -306
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-header.d.ts +0 -10
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-header.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-header.js +0 -12
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-header.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/operations-header.tsx +0 -29
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/person-select-with-create.d.ts +0 -15
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/person-select-with-create.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/person-select-with-create.js +0 -501
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/person-select-with-create.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/person-select-with-create.tsx +0 -853
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-costs-section.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-costs-section.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-costs-section.js +0 -847
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-costs-section.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-costs-section.tsx +0 -1340
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-details-screen.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-details-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-details-screen.js +0 -2930
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-details-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-details-screen.tsx +0 -4378
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-form-screen.d.ts +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-form-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-form-screen.js +0 -1013
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-form-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/project-form-screen.tsx +0 -1745
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/section-card.d.ts +0 -13
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/section-card.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/section-card.js +0 -38
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/section-card.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/section-card.tsx +0 -74
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/status-badge.d.ts +0 -7
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/status-badge.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/status-badge.js +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/status-badge.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/status-badge.tsx +0 -15
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/system-user-select-with-create.d.ts +0 -18
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/system-user-select-with-create.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/system-user-select-with-create.js +0 -406
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/system-user-select-with-create.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/system-user-select-with-create.tsx +0 -660
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-detail-sheet.d.ts +0 -26
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-detail-sheet.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-detail-sheet.js +0 -332
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-detail-sheet.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-detail-sheet.tsx +0 -518
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-file-attachments.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-file-attachments.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-file-attachments.js +0 -255
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-file-attachments.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/task-file-attachments.tsx +0 -388
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/timesheet-task-create-sheet.d.ts +0 -10
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/timesheet-task-create-sheet.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/timesheet-task-create-sheet.js +0 -131
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/timesheet-task-create-sheet.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_components/timesheet-task-create-sheet.tsx +0 -214
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/api.d.ts +0 -108
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/api.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/api.js +0 -162
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/api.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/api.ts +0 -428
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/hooks/use-operations-access.d.ts +0 -8
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/hooks/use-operations-access.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/hooks/use-operations-access.js +0 -36
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/hooks/use-operations-access.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/hooks/use-operations-access.ts +0 -44
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/types.d.ts +0 -837
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/types.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/types.js +0 -3
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/types.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/types.ts +0 -861
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/format.d.ts +0 -16
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/format.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/format.js +0 -182
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/format.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/format.ts +0 -250
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/forms.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/forms.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/forms.js +0 -51
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/forms.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/_lib/utils/forms.ts +0 -61
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/approvals/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/approvals/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/approvals/page.js +0 -954
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/approvals/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/approvals/page.tsx +0 -1277
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborator-types/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborator-types/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborator-types/page.js +0 -488
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborator-types/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborator-types/page.tsx +0 -805
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/edit/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/edit/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/edit/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/edit/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/edit/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/[id]/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/new/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/new/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/new/page.js +0 -8
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/new/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/new/page.tsx +0 -5
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/page.js +0 -612
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/collaborators/page.tsx +0 -939
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/edit/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/edit/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/edit/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/edit/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/edit/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/[id]/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/new/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/new/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/new/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/new/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/new/page.tsx +0 -17
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/page.js +0 -348
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/contracts/page.tsx +0 -536
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/departments/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/departments/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/departments/page.js +0 -401
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/departments/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/departments/page.tsx +0 -607
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/layout.d.ts +0 -5
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/layout.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/layout.js +0 -7
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/layout.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/layout.tsx +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/[id]/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/[id]/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/[id]/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/[id]/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/[id]/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/page.js +0 -321
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-projects/page.tsx +0 -440
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-tasks/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-tasks/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-tasks/page.js +0 -939
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-tasks/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/my-tasks/page.tsx +0 -1499
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/async-options-combobox.d.ts +0 -29
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/async-options-combobox.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/async-options-combobox.js +0 -95
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/async-options-combobox.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/async-options-combobox.tsx +0 -233
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-costs-section.d.ts +0 -10
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-costs-section.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-costs-section.js +0 -577
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-costs-section.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-costs-section.tsx +0 -868
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-details-screen.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-details-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-details-screen.js +0 -337
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-details-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-details-screen.tsx +0 -476
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-form-screen.d.ts +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-form-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-form-screen.js +0 -1348
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-form-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-form-screen.tsx +0 -2233
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-select-with-create.d.ts +0 -12
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-select-with-create.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-select-with-create.js +0 -162
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-select-with-create.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/collaborator-select-with-create.tsx +0 -261
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-content-editor.d.ts +0 -18
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-content-editor.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-content-editor.js +0 -145
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-content-editor.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-content-editor.tsx +0 -258
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-details-screen.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-details-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-details-screen.js +0 -223
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-details-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-details-screen.tsx +0 -342
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-form-screen.d.ts +0 -58
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-form-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-form-screen.js +0 -438
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-form-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/contract-form-screen.tsx +0 -698
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/department-select-with-create.d.ts +0 -20
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/department-select-with-create.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/department-select-with-create.js +0 -233
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/department-select-with-create.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/department-select-with-create.tsx +0 -392
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/my-project-summary-screen.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/my-project-summary-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/my-project-summary-screen.js +0 -814
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/my-project-summary-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/my-project-summary-screen.tsx +0 -1288
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-calendar-view.d.ts +0 -21
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-calendar-view.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-calendar-view.js +0 -174
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-calendar-view.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-calendar-view.tsx +0 -306
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-header.d.ts +0 -10
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-header.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-header.js +0 -12
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-header.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/operations-header.tsx +0 -29
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/person-select-with-create.d.ts +0 -15
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/person-select-with-create.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/person-select-with-create.js +0 -501
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/person-select-with-create.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/person-select-with-create.tsx +0 -853
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-cost-report-screen.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-cost-report-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-cost-report-screen.js +0 -459
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-cost-report-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-cost-report-screen.tsx +0 -598
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-costs-section.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-costs-section.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-costs-section.js +0 -876
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-costs-section.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-costs-section.tsx +0 -1368
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-details-screen.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-details-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-details-screen.js +0 -2930
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-details-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-details-screen.tsx +0 -4378
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-form-screen.d.ts +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-form-screen.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-form-screen.js +0 -1013
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-form-screen.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/project-form-screen.tsx +0 -1745
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/section-card.d.ts +0 -13
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/section-card.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/section-card.js +0 -38
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/section-card.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/section-card.tsx +0 -74
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/status-badge.d.ts +0 -7
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/status-badge.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/status-badge.js +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/status-badge.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/status-badge.tsx +0 -15
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/system-user-select-with-create.d.ts +0 -18
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/system-user-select-with-create.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/system-user-select-with-create.js +0 -406
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/system-user-select-with-create.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/system-user-select-with-create.tsx +0 -660
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-detail-sheet.d.ts +0 -26
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-detail-sheet.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-detail-sheet.js +0 -332
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-detail-sheet.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-detail-sheet.tsx +0 -518
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-file-attachments.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-file-attachments.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-file-attachments.js +0 -255
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-file-attachments.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/task-file-attachments.tsx +0 -388
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/timesheet-task-create-sheet.d.ts +0 -10
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/timesheet-task-create-sheet.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/timesheet-task-create-sheet.js +0 -131
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/timesheet-task-create-sheet.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_components/timesheet-task-create-sheet.tsx +0 -214
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/api.d.ts +0 -108
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/api.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/api.js +0 -162
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/api.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/api.ts +0 -428
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/hooks/use-operations-access.d.ts +0 -8
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/hooks/use-operations-access.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/hooks/use-operations-access.js +0 -36
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/hooks/use-operations-access.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/hooks/use-operations-access.ts +0 -44
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/types.d.ts +0 -837
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/types.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/types.js +0 -3
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/types.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/types.ts +0 -861
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/format.d.ts +0 -16
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/format.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/format.js +0 -182
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/format.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/format.ts +0 -250
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/forms.d.ts +0 -4
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/forms.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/forms.js +0 -51
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/forms.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/_lib/utils/forms.ts +0 -61
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/approvals/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/approvals/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/approvals/page.js +0 -954
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/approvals/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/approvals/page.tsx +0 -1277
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborator-types/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborator-types/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborator-types/page.js +0 -488
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborator-types/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborator-types/page.tsx +0 -805
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/edit/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/edit/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/edit/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/edit/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/edit/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/[id]/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/new/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/new/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/new/page.js +0 -8
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/new/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/new/page.tsx +0 -5
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/page.js +0 -612
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/collaborators/page.tsx +0 -939
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/edit/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/edit/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/edit/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/edit/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/edit/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/[id]/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/new/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/new/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/new/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/new/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/new/page.tsx +0 -17
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/page.js +0 -348
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/contracts/page.tsx +0 -536
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/departments/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/departments/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/departments/page.js +0 -401
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/departments/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/departments/page.tsx +0 -607
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/layout.d.ts +0 -5
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/layout.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/layout.js +0 -7
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/layout.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/layout.tsx +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/[id]/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/[id]/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/[id]/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/[id]/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/[id]/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/page.js +0 -321
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-projects/page.tsx +0 -440
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-tasks/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-tasks/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-tasks/page.js +0 -939
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-tasks/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/my-tasks/page.tsx +0 -1499
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/page.js +0 -8
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/page.tsx +0 -5
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-categories/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-categories/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-categories/page.js +0 -436
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-categories/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-categories/page.tsx +0 -675
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-types/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-types/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-types/page.js +0 -563
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-types/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-types/page.tsx +0 -846
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/costs-report/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/costs-report/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/costs-report/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/costs-report/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/costs-report/page.tsx +0 -10
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/edit/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/edit/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/edit/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/edit/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/edit/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/[id]/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/new/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/new/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/new/page.js +0 -8
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/new/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/new/page.tsx +0 -5
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/page.js +0 -492
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/projects/page.tsx +0 -757
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/collaborators/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/collaborators/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/collaborators/page.js +0 -342
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/collaborators/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/collaborators/page.tsx +0 -430
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/projects/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/projects/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/projects/page.js +0 -338
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/projects/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/reports/projects/page.tsx +0 -428
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/schedule-adjustments/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/schedule-adjustments/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/schedule-adjustments/page.js +0 -660
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/schedule-adjustments/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/schedule-adjustments/page.tsx +0 -992
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/time-off/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/time-off/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/time-off/page.js +0 -515
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/time-off/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/time-off/page.tsx +0 -707
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/timesheets/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/timesheets/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/timesheets/page.js +0 -1141
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/timesheets/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/timesheets/page.tsx +0 -1705
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/page.js +0 -8
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/page.tsx +0 -5
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-categories/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-categories/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-categories/page.js +0 -436
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-categories/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-categories/page.tsx +0 -675
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-types/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-types/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-types/page.js +0 -563
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-types/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/project-cost-types/page.tsx +0 -846
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/edit/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/edit/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/edit/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/edit/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/edit/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/page.d.ts +0 -6
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/page.js +0 -9
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/[id]/page.tsx +0 -11
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/new/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/new/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/new/page.js +0 -8
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/new/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/new/page.tsx +0 -5
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/page.js +0 -492
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/projects/page.tsx +0 -757
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/collaborators/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/collaborators/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/collaborators/page.js +0 -342
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/collaborators/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/collaborators/page.tsx +0 -430
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/projects/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/projects/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/projects/page.js +0 -338
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/projects/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/reports/projects/page.tsx +0 -428
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/schedule-adjustments/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/schedule-adjustments/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/schedule-adjustments/page.js +0 -660
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/schedule-adjustments/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/schedule-adjustments/page.tsx +0 -992
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/time-off/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/time-off/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/time-off/page.js +0 -515
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/time-off/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/time-off/page.tsx +0 -707
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/timesheets/page.d.ts +0 -2
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/timesheets/page.d.ts.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/timesheets/page.js +0 -1141
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/timesheets/page.js.map +0 -1
- package/hedhog/frontend/src/app/(app)/(libraries)/operations/timesheets/page.tsx +0 -1705
package/hedhog/frontend/src/app/(app)/(libraries)/operations/operations/project-cost-types/page.tsx
DELETED
|
@@ -1,846 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
|
|
3
|
-
import {
|
|
4
|
-
EmptyState,
|
|
5
|
-
Page,
|
|
6
|
-
PaginationFooter,
|
|
7
|
-
SearchBar,
|
|
8
|
-
} from '@/components/entity-list';
|
|
9
|
-
import {
|
|
10
|
-
AlertDialog,
|
|
11
|
-
AlertDialogAction,
|
|
12
|
-
AlertDialogCancel,
|
|
13
|
-
AlertDialogContent,
|
|
14
|
-
AlertDialogDescription,
|
|
15
|
-
AlertDialogFooter,
|
|
16
|
-
AlertDialogHeader,
|
|
17
|
-
AlertDialogTitle,
|
|
18
|
-
} from '@/components/ui/alert-dialog';
|
|
19
|
-
import { Badge } from '@/components/ui/badge';
|
|
20
|
-
import { Button } from '@/components/ui/button';
|
|
21
|
-
import { Card, CardContent } from '@/components/ui/card';
|
|
22
|
-
import { Input } from '@/components/ui/input';
|
|
23
|
-
import { KpiCardsGrid } from '@/components/ui/kpi-cards-grid';
|
|
24
|
-
import { Label } from '@/components/ui/label';
|
|
25
|
-
import {
|
|
26
|
-
Select,
|
|
27
|
-
SelectContent,
|
|
28
|
-
SelectItem,
|
|
29
|
-
SelectTrigger,
|
|
30
|
-
SelectValue,
|
|
31
|
-
} from '@/components/ui/select';
|
|
32
|
-
import {
|
|
33
|
-
Sheet,
|
|
34
|
-
SheetContent,
|
|
35
|
-
SheetDescription,
|
|
36
|
-
SheetHeader,
|
|
37
|
-
SheetTitle,
|
|
38
|
-
} from '@/components/ui/sheet';
|
|
39
|
-
import { Switch } from '@/components/ui/switch';
|
|
40
|
-
import {
|
|
41
|
-
Table,
|
|
42
|
-
TableBody,
|
|
43
|
-
TableCell,
|
|
44
|
-
TableHead,
|
|
45
|
-
TableHeader,
|
|
46
|
-
TableRow,
|
|
47
|
-
} from '@/components/ui/table';
|
|
48
|
-
import { Textarea } from '@/components/ui/textarea';
|
|
49
|
-
import { ToggleGroup, ToggleGroupItem } from '@/components/ui/toggle-group';
|
|
50
|
-
import { useApp, useQuery } from '@hed-hog/next-app-provider';
|
|
51
|
-
import { Layers, LayoutGrid, List, Pencil, Trash2 } from 'lucide-react';
|
|
52
|
-
import { useTranslations } from 'next-intl';
|
|
53
|
-
import Link from 'next/link';
|
|
54
|
-
import { useMemo, useState } from 'react';
|
|
55
|
-
import { OperationsHeader } from '../_components/operations-header';
|
|
56
|
-
import {
|
|
57
|
-
createProjectCostType,
|
|
58
|
-
deleteProjectCostType,
|
|
59
|
-
listProjectCostCategories,
|
|
60
|
-
listProjectCostTypes,
|
|
61
|
-
updateProjectCostType,
|
|
62
|
-
} from '../_lib/api';
|
|
63
|
-
import { useOperationsAccess } from '../_lib/hooks/use-operations-access';
|
|
64
|
-
import type {
|
|
65
|
-
PaginatedResponse,
|
|
66
|
-
ProjectCostCategory,
|
|
67
|
-
ProjectCostType,
|
|
68
|
-
} from '../_lib/types';
|
|
69
|
-
import { formatEnumLabel } from '../_lib/utils/format';
|
|
70
|
-
|
|
71
|
-
const CALCULATION_TYPE_OPTIONS = [
|
|
72
|
-
'fixed',
|
|
73
|
-
'unit',
|
|
74
|
-
'hourly',
|
|
75
|
-
'monthly',
|
|
76
|
-
'percentage',
|
|
77
|
-
] as const;
|
|
78
|
-
|
|
79
|
-
type CostTypeFormState = {
|
|
80
|
-
category_id: string;
|
|
81
|
-
slug: string;
|
|
82
|
-
code: string;
|
|
83
|
-
name: string;
|
|
84
|
-
description: string;
|
|
85
|
-
default_unit: string;
|
|
86
|
-
default_calculation_type: string;
|
|
87
|
-
is_recurring_allowed: boolean;
|
|
88
|
-
is_active: boolean;
|
|
89
|
-
sort_order: string;
|
|
90
|
-
};
|
|
91
|
-
|
|
92
|
-
const EMPTY_FORM: CostTypeFormState = {
|
|
93
|
-
category_id: 'none',
|
|
94
|
-
slug: '',
|
|
95
|
-
code: '',
|
|
96
|
-
name: '',
|
|
97
|
-
description: '',
|
|
98
|
-
default_unit: '',
|
|
99
|
-
default_calculation_type: 'fixed',
|
|
100
|
-
is_recurring_allowed: true,
|
|
101
|
-
is_active: true,
|
|
102
|
-
sort_order: '0',
|
|
103
|
-
};
|
|
104
|
-
|
|
105
|
-
export default function ProjectCostTypesPage() {
|
|
106
|
-
const t = useTranslations('operations.ProjectCostTypesPage');
|
|
107
|
-
const commonT = useTranslations('operations.Common');
|
|
108
|
-
const { request, showToastHandler, currentLocaleCode } = useApp();
|
|
109
|
-
const access = useOperationsAccess();
|
|
110
|
-
|
|
111
|
-
const [search, setSearch] = useState('');
|
|
112
|
-
const [categoryFilter, setCategoryFilter] = useState<string>('all');
|
|
113
|
-
const [calcTypeFilter, setCalcTypeFilter] = useState<string>('all');
|
|
114
|
-
const [page, setPage] = useState(1);
|
|
115
|
-
const [pageSize, setPageSize] = useState(12);
|
|
116
|
-
const [viewMode, setViewMode] = useState<'table' | 'cards'>(() => {
|
|
117
|
-
if (typeof window === 'undefined') return 'table';
|
|
118
|
-
const saved = window.localStorage.getItem(
|
|
119
|
-
'operations-project-cost-types-view-mode'
|
|
120
|
-
);
|
|
121
|
-
return saved === 'cards' ? 'cards' : 'table';
|
|
122
|
-
});
|
|
123
|
-
const [isSheetOpen, setIsSheetOpen] = useState(false);
|
|
124
|
-
const [isSaving, setIsSaving] = useState(false);
|
|
125
|
-
const [editingItem, setEditingItem] = useState<ProjectCostType | null>(null);
|
|
126
|
-
const [form, setForm] = useState<CostTypeFormState>(EMPTY_FORM);
|
|
127
|
-
const [deleteTarget, setDeleteTarget] = useState<ProjectCostType | null>(
|
|
128
|
-
null
|
|
129
|
-
);
|
|
130
|
-
const [isDeleting, setIsDeleting] = useState(false);
|
|
131
|
-
|
|
132
|
-
const { data: categoriesRaw } = useQuery<ProjectCostCategory[]>({
|
|
133
|
-
queryKey: ['operations-project-cost-categories-all', currentLocaleCode],
|
|
134
|
-
enabled: access.isDirector,
|
|
135
|
-
queryFn: () =>
|
|
136
|
-
listProjectCostCategories(request, {
|
|
137
|
-
pageSize: '200',
|
|
138
|
-
}) as Promise<ProjectCostCategory[]>,
|
|
139
|
-
});
|
|
140
|
-
|
|
141
|
-
// The API may return a paginated response or a flat array.
|
|
142
|
-
const categories: ProjectCostCategory[] = Array.isArray(categoriesRaw)
|
|
143
|
-
? categoriesRaw
|
|
144
|
-
: ((categoriesRaw as PaginatedResponse<ProjectCostCategory> | undefined)
|
|
145
|
-
?.data ?? []);
|
|
146
|
-
|
|
147
|
-
const {
|
|
148
|
-
data: response,
|
|
149
|
-
isLoading,
|
|
150
|
-
refetch,
|
|
151
|
-
} = useQuery<PaginatedResponse<ProjectCostType>>({
|
|
152
|
-
queryKey: [
|
|
153
|
-
'operations-project-cost-types',
|
|
154
|
-
currentLocaleCode,
|
|
155
|
-
search,
|
|
156
|
-
categoryFilter,
|
|
157
|
-
calcTypeFilter,
|
|
158
|
-
page,
|
|
159
|
-
pageSize,
|
|
160
|
-
],
|
|
161
|
-
enabled: access.isDirector,
|
|
162
|
-
queryFn: () => {
|
|
163
|
-
const params: Record<string, string> = {
|
|
164
|
-
page: String(page),
|
|
165
|
-
pageSize: String(pageSize),
|
|
166
|
-
};
|
|
167
|
-
if (search.trim()) params.search = search.trim();
|
|
168
|
-
if (categoryFilter !== 'all') params.category_id = categoryFilter;
|
|
169
|
-
if (calcTypeFilter !== 'all') params.default_calculation_type = calcTypeFilter;
|
|
170
|
-
return listProjectCostTypes(request, params) as Promise<
|
|
171
|
-
PaginatedResponse<ProjectCostType>
|
|
172
|
-
>;
|
|
173
|
-
},
|
|
174
|
-
placeholderData: (previous) => previous,
|
|
175
|
-
});
|
|
176
|
-
|
|
177
|
-
const items = response?.data ?? [];
|
|
178
|
-
|
|
179
|
-
const statsCards = useMemo(
|
|
180
|
-
() => [
|
|
181
|
-
{
|
|
182
|
-
key: 'total',
|
|
183
|
-
title: t('cards.total'),
|
|
184
|
-
value: response?.total ?? items.length,
|
|
185
|
-
icon: Layers,
|
|
186
|
-
},
|
|
187
|
-
{
|
|
188
|
-
key: 'active',
|
|
189
|
-
title: t('cards.active'),
|
|
190
|
-
value: items.filter((i) => i.is_active).length,
|
|
191
|
-
icon: Layers,
|
|
192
|
-
},
|
|
193
|
-
{
|
|
194
|
-
key: 'inactive',
|
|
195
|
-
title: t('cards.inactive'),
|
|
196
|
-
value: items.filter((i) => !i.is_active).length,
|
|
197
|
-
icon: Layers,
|
|
198
|
-
},
|
|
199
|
-
],
|
|
200
|
-
[items, response?.total, t]
|
|
201
|
-
);
|
|
202
|
-
|
|
203
|
-
const updateForm = <K extends keyof CostTypeFormState>(
|
|
204
|
-
field: K,
|
|
205
|
-
value: CostTypeFormState[K]
|
|
206
|
-
) => {
|
|
207
|
-
setForm((current) => ({ ...current, [field]: value }));
|
|
208
|
-
};
|
|
209
|
-
|
|
210
|
-
const openCreateSheet = () => {
|
|
211
|
-
setEditingItem(null);
|
|
212
|
-
setForm(EMPTY_FORM);
|
|
213
|
-
setIsSheetOpen(true);
|
|
214
|
-
};
|
|
215
|
-
|
|
216
|
-
const openEditSheet = (item: ProjectCostType) => {
|
|
217
|
-
setEditingItem(item);
|
|
218
|
-
setForm({
|
|
219
|
-
category_id: item.category_id ? String(item.category_id) : 'none',
|
|
220
|
-
slug: item.slug ?? '',
|
|
221
|
-
code: item.code ?? '',
|
|
222
|
-
name: item.name ?? '',
|
|
223
|
-
description: item.description ?? '',
|
|
224
|
-
default_unit: item.default_unit ?? '',
|
|
225
|
-
default_calculation_type: item.default_calculation_type ?? 'fixed',
|
|
226
|
-
is_recurring_allowed: item.is_recurring_allowed ?? true,
|
|
227
|
-
is_active: item.is_active ?? true,
|
|
228
|
-
sort_order: String(item.sort_order ?? 0),
|
|
229
|
-
});
|
|
230
|
-
setIsSheetOpen(true);
|
|
231
|
-
};
|
|
232
|
-
|
|
233
|
-
const saveItem = async () => {
|
|
234
|
-
if (!form.name.trim() || !form.code.trim()) {
|
|
235
|
-
showToastHandler?.('error', t('messages.requiredFields'));
|
|
236
|
-
return;
|
|
237
|
-
}
|
|
238
|
-
|
|
239
|
-
setIsSaving(true);
|
|
240
|
-
try {
|
|
241
|
-
const payload = {
|
|
242
|
-
category_id:
|
|
243
|
-
form.category_id !== 'none' ? Number(form.category_id) : null,
|
|
244
|
-
slug: form.slug.trim() || null,
|
|
245
|
-
code: form.code.trim(),
|
|
246
|
-
name: form.name.trim(),
|
|
247
|
-
description: form.description.trim() || null,
|
|
248
|
-
default_unit: form.default_unit.trim() || null,
|
|
249
|
-
default_calculation_type: form.default_calculation_type,
|
|
250
|
-
is_recurring_allowed: form.is_recurring_allowed,
|
|
251
|
-
is_active: form.is_active,
|
|
252
|
-
sort_order: parseInt(form.sort_order, 10) || 0,
|
|
253
|
-
};
|
|
254
|
-
|
|
255
|
-
if (editingItem) {
|
|
256
|
-
await updateProjectCostType(request, editingItem.id, payload);
|
|
257
|
-
} else {
|
|
258
|
-
await createProjectCostType(request, payload);
|
|
259
|
-
}
|
|
260
|
-
|
|
261
|
-
showToastHandler?.('success', t('messages.saveSuccess'));
|
|
262
|
-
setIsSheetOpen(false);
|
|
263
|
-
setEditingItem(null);
|
|
264
|
-
setForm(EMPTY_FORM);
|
|
265
|
-
await refetch();
|
|
266
|
-
} catch {
|
|
267
|
-
showToastHandler?.('error', t('messages.saveError'));
|
|
268
|
-
} finally {
|
|
269
|
-
setIsSaving(false);
|
|
270
|
-
}
|
|
271
|
-
};
|
|
272
|
-
|
|
273
|
-
const confirmDelete = async () => {
|
|
274
|
-
if (!deleteTarget) return;
|
|
275
|
-
setIsDeleting(true);
|
|
276
|
-
try {
|
|
277
|
-
await deleteProjectCostType(request, deleteTarget.id);
|
|
278
|
-
showToastHandler?.('success', t('messages.deleteSuccess'));
|
|
279
|
-
setDeleteTarget(null);
|
|
280
|
-
await refetch();
|
|
281
|
-
} catch {
|
|
282
|
-
showToastHandler?.('error', t('messages.deleteError'));
|
|
283
|
-
} finally {
|
|
284
|
-
setIsDeleting(false);
|
|
285
|
-
}
|
|
286
|
-
};
|
|
287
|
-
|
|
288
|
-
const handleViewModeChange = (value: string) => {
|
|
289
|
-
if (value !== 'table' && value !== 'cards') return;
|
|
290
|
-
setViewMode(value as 'table' | 'cards');
|
|
291
|
-
if (typeof window !== 'undefined') {
|
|
292
|
-
window.localStorage.setItem(
|
|
293
|
-
'operations-project-cost-types-view-mode',
|
|
294
|
-
value
|
|
295
|
-
);
|
|
296
|
-
}
|
|
297
|
-
};
|
|
298
|
-
|
|
299
|
-
const getCategoryName = (id?: number) => {
|
|
300
|
-
if (!id) return null;
|
|
301
|
-
return categories.find((c) => c.id === id)?.name ?? null;
|
|
302
|
-
};
|
|
303
|
-
|
|
304
|
-
const getCategoryColor = (id?: number) => {
|
|
305
|
-
if (!id) return undefined;
|
|
306
|
-
return categories.find((c) => c.id === id)?.color;
|
|
307
|
-
};
|
|
308
|
-
|
|
309
|
-
const getItemCategoryId = (item: ProjectCostType) => item.category_id;
|
|
310
|
-
|
|
311
|
-
const calculationTypeLabel = (value: string) => {
|
|
312
|
-
const map: Record<string, string> = {
|
|
313
|
-
fixed: t('calculationType.fixed'),
|
|
314
|
-
unit: t('calculationType.unit'),
|
|
315
|
-
hourly: t('calculationType.hourly'),
|
|
316
|
-
monthly: t('calculationType.monthly'),
|
|
317
|
-
percentage: t('calculationType.percentage'),
|
|
318
|
-
};
|
|
319
|
-
return map[value] ?? formatEnumLabel(value);
|
|
320
|
-
};
|
|
321
|
-
|
|
322
|
-
if (!access.isLoading && !access.isDirector) {
|
|
323
|
-
return (
|
|
324
|
-
<Page>
|
|
325
|
-
<OperationsHeader
|
|
326
|
-
title={t('title')}
|
|
327
|
-
description={t('description')}
|
|
328
|
-
current={t('breadcrumb')}
|
|
329
|
-
actions={
|
|
330
|
-
<Button variant="outline" size="sm" asChild>
|
|
331
|
-
<Link href="/operations">{commonT('actions.back')}</Link>
|
|
332
|
-
</Button>
|
|
333
|
-
}
|
|
334
|
-
/>
|
|
335
|
-
<EmptyState
|
|
336
|
-
icon={<Layers className="size-12" />}
|
|
337
|
-
title={commonT('states.noAccessTitle')}
|
|
338
|
-
description={t('noAccessDescription')}
|
|
339
|
-
actionLabel={commonT('actions.back')}
|
|
340
|
-
onAction={() => {
|
|
341
|
-
window.location.href = '/operations';
|
|
342
|
-
}}
|
|
343
|
-
/>
|
|
344
|
-
</Page>
|
|
345
|
-
);
|
|
346
|
-
}
|
|
347
|
-
|
|
348
|
-
return (
|
|
349
|
-
<Page>
|
|
350
|
-
<OperationsHeader
|
|
351
|
-
title={t('title')}
|
|
352
|
-
description={t('description')}
|
|
353
|
-
current={t('breadcrumb')}
|
|
354
|
-
actions={
|
|
355
|
-
<div className="flex flex-wrap gap-2">
|
|
356
|
-
<Button variant="outline" size="sm" asChild>
|
|
357
|
-
<Link href="/operations">{commonT('actions.back')}</Link>
|
|
358
|
-
</Button>
|
|
359
|
-
<Button size="sm" onClick={openCreateSheet}>
|
|
360
|
-
{commonT('actions.create')}
|
|
361
|
-
</Button>
|
|
362
|
-
</div>
|
|
363
|
-
}
|
|
364
|
-
/>
|
|
365
|
-
|
|
366
|
-
<KpiCardsGrid items={statsCards} columns={3} />
|
|
367
|
-
|
|
368
|
-
<div className="flex min-w-0 flex-col gap-4 xl:flex-row xl:items-center">
|
|
369
|
-
<div className="flex flex-1 flex-wrap items-center gap-3">
|
|
370
|
-
<div className="flex-1">
|
|
371
|
-
<SearchBar
|
|
372
|
-
searchQuery={search}
|
|
373
|
-
onSearchChange={(value) => {
|
|
374
|
-
setSearch(value);
|
|
375
|
-
setPage(1);
|
|
376
|
-
}}
|
|
377
|
-
showSearchButton={false}
|
|
378
|
-
debounceMs={500}
|
|
379
|
-
placeholder={t('searchPlaceholder')}
|
|
380
|
-
/>
|
|
381
|
-
</div>
|
|
382
|
-
<Select
|
|
383
|
-
value={categoryFilter}
|
|
384
|
-
onValueChange={(value) => {
|
|
385
|
-
setCategoryFilter(value);
|
|
386
|
-
setPage(1);
|
|
387
|
-
}}
|
|
388
|
-
>
|
|
389
|
-
<SelectTrigger className="w-52">
|
|
390
|
-
<SelectValue placeholder={t('filters.allCategories')} />
|
|
391
|
-
</SelectTrigger>
|
|
392
|
-
<SelectContent>
|
|
393
|
-
<SelectItem value="all">{t('filters.allCategories')}</SelectItem>
|
|
394
|
-
{categories.map((cat) => (
|
|
395
|
-
<SelectItem key={cat.id} value={String(cat.id)}>
|
|
396
|
-
{cat.name}
|
|
397
|
-
</SelectItem>
|
|
398
|
-
))}
|
|
399
|
-
</SelectContent>
|
|
400
|
-
</Select>
|
|
401
|
-
<Select
|
|
402
|
-
value={calcTypeFilter}
|
|
403
|
-
onValueChange={(value) => {
|
|
404
|
-
setCalcTypeFilter(value);
|
|
405
|
-
setPage(1);
|
|
406
|
-
}}
|
|
407
|
-
>
|
|
408
|
-
<SelectTrigger className="w-44">
|
|
409
|
-
<SelectValue placeholder={t('filters.allCalculationTypes')} />
|
|
410
|
-
</SelectTrigger>
|
|
411
|
-
<SelectContent>
|
|
412
|
-
<SelectItem value="all">{t('filters.allCalculationTypes')}</SelectItem>
|
|
413
|
-
{CALCULATION_TYPE_OPTIONS.map((ct) => (
|
|
414
|
-
<SelectItem key={ct} value={ct}>
|
|
415
|
-
{calculationTypeLabel(ct)}
|
|
416
|
-
</SelectItem>
|
|
417
|
-
))}
|
|
418
|
-
</SelectContent>
|
|
419
|
-
</Select>
|
|
420
|
-
</div>
|
|
421
|
-
<div className="shrink-0">
|
|
422
|
-
<ToggleGroup
|
|
423
|
-
type="single"
|
|
424
|
-
value={viewMode}
|
|
425
|
-
onValueChange={handleViewModeChange}
|
|
426
|
-
>
|
|
427
|
-
<ToggleGroupItem value="table" aria-label={t('viewModeTable')}>
|
|
428
|
-
<List className="size-4" />
|
|
429
|
-
</ToggleGroupItem>
|
|
430
|
-
<ToggleGroupItem value="cards" aria-label={t('viewModeCards')}>
|
|
431
|
-
<LayoutGrid className="size-4" />
|
|
432
|
-
</ToggleGroupItem>
|
|
433
|
-
</ToggleGroup>
|
|
434
|
-
</div>
|
|
435
|
-
</div>
|
|
436
|
-
|
|
437
|
-
{isLoading ? (
|
|
438
|
-
<div className="flex h-40 items-center justify-center text-muted-foreground">
|
|
439
|
-
{commonT('states.loading')}
|
|
440
|
-
</div>
|
|
441
|
-
) : items.length === 0 ? (
|
|
442
|
-
<EmptyState
|
|
443
|
-
icon={<Layers className="size-12" />}
|
|
444
|
-
title={commonT('states.emptyTitle')}
|
|
445
|
-
description={t('emptyDescription')}
|
|
446
|
-
actionLabel={commonT('actions.create')}
|
|
447
|
-
onAction={openCreateSheet}
|
|
448
|
-
/>
|
|
449
|
-
) : viewMode === 'table' ? (
|
|
450
|
-
<div className="overflow-hidden rounded-xl border bg-card shadow-sm">
|
|
451
|
-
<Table>
|
|
452
|
-
<TableHeader>
|
|
453
|
-
<TableRow>
|
|
454
|
-
<TableHead>{t('columns.code')}</TableHead>
|
|
455
|
-
<TableHead>{t('columns.name')}</TableHead>
|
|
456
|
-
<TableHead>{t('columns.category')}</TableHead>
|
|
457
|
-
<TableHead>{t('columns.defaultCalculationType')}</TableHead>
|
|
458
|
-
<TableHead>{t('columns.active')}</TableHead>
|
|
459
|
-
<TableHead className="text-right">
|
|
460
|
-
{commonT('labels.actions')}
|
|
461
|
-
</TableHead>
|
|
462
|
-
</TableRow>
|
|
463
|
-
</TableHeader>
|
|
464
|
-
<TableBody>
|
|
465
|
-
{items.map((item) => (
|
|
466
|
-
<TableRow
|
|
467
|
-
key={item.id}
|
|
468
|
-
className="cursor-pointer"
|
|
469
|
-
onClick={() => openEditSheet(item)}
|
|
470
|
-
>
|
|
471
|
-
<TableCell>
|
|
472
|
-
<code className="rounded bg-muted px-1.5 py-0.5 text-xs font-mono">
|
|
473
|
-
{item.code}
|
|
474
|
-
</code>
|
|
475
|
-
</TableCell>
|
|
476
|
-
<TableCell className="font-medium">{item.name}</TableCell>
|
|
477
|
-
<TableCell>
|
|
478
|
-
{getItemCategoryId(item) ? (
|
|
479
|
-
<Badge
|
|
480
|
-
variant="outline"
|
|
481
|
-
className="gap-1.5"
|
|
482
|
-
style={{
|
|
483
|
-
borderColor: getCategoryColor(
|
|
484
|
-
getItemCategoryId(item)
|
|
485
|
-
),
|
|
486
|
-
}}
|
|
487
|
-
>
|
|
488
|
-
{getCategoryColor(getItemCategoryId(item)) ? (
|
|
489
|
-
<span
|
|
490
|
-
className="inline-block size-2 rounded-full"
|
|
491
|
-
style={{
|
|
492
|
-
backgroundColor: getCategoryColor(
|
|
493
|
-
getItemCategoryId(item)
|
|
494
|
-
),
|
|
495
|
-
}}
|
|
496
|
-
/>
|
|
497
|
-
) : null}
|
|
498
|
-
{item.category?.name ??
|
|
499
|
-
getCategoryName(getItemCategoryId(item)) ??
|
|
500
|
-
'-'}
|
|
501
|
-
</Badge>
|
|
502
|
-
) : (
|
|
503
|
-
<span className="text-muted-foreground">-</span>
|
|
504
|
-
)}
|
|
505
|
-
</TableCell>
|
|
506
|
-
<TableCell>
|
|
507
|
-
<Badge variant="secondary">
|
|
508
|
-
{calculationTypeLabel(item.default_calculation_type)}
|
|
509
|
-
</Badge>
|
|
510
|
-
</TableCell>
|
|
511
|
-
<TableCell>
|
|
512
|
-
<Badge
|
|
513
|
-
variant={item.is_active ? 'default' : 'secondary'}
|
|
514
|
-
className={
|
|
515
|
-
item.is_active
|
|
516
|
-
? 'bg-emerald-500/15 text-emerald-700'
|
|
517
|
-
: ''
|
|
518
|
-
}
|
|
519
|
-
>
|
|
520
|
-
{item.is_active
|
|
521
|
-
? t('columns.activeYes')
|
|
522
|
-
: t('columns.activeNo')}
|
|
523
|
-
</Badge>
|
|
524
|
-
</TableCell>
|
|
525
|
-
<TableCell
|
|
526
|
-
className="text-right"
|
|
527
|
-
onClick={(e) => e.stopPropagation()}
|
|
528
|
-
>
|
|
529
|
-
<div className="flex justify-end gap-1">
|
|
530
|
-
<Button
|
|
531
|
-
variant="ghost"
|
|
532
|
-
size="icon"
|
|
533
|
-
className="size-8"
|
|
534
|
-
onClick={() => openEditSheet(item)}
|
|
535
|
-
>
|
|
536
|
-
<Pencil className="size-3.5" />
|
|
537
|
-
</Button>
|
|
538
|
-
<Button
|
|
539
|
-
variant="ghost"
|
|
540
|
-
size="icon"
|
|
541
|
-
className="size-8 text-destructive hover:text-destructive"
|
|
542
|
-
onClick={() => setDeleteTarget(item)}
|
|
543
|
-
>
|
|
544
|
-
<Trash2 className="size-3.5" />
|
|
545
|
-
</Button>
|
|
546
|
-
</div>
|
|
547
|
-
</TableCell>
|
|
548
|
-
</TableRow>
|
|
549
|
-
))}
|
|
550
|
-
</TableBody>
|
|
551
|
-
</Table>
|
|
552
|
-
</div>
|
|
553
|
-
) : (
|
|
554
|
-
<div className="grid gap-4 sm:grid-cols-2 lg:grid-cols-3">
|
|
555
|
-
{items.map((item) => (
|
|
556
|
-
<Card
|
|
557
|
-
key={item.id}
|
|
558
|
-
className="cursor-pointer transition-shadow hover:shadow-md"
|
|
559
|
-
onClick={() => openEditSheet(item)}
|
|
560
|
-
>
|
|
561
|
-
<CardContent className="p-4">
|
|
562
|
-
<div className="flex items-start justify-between gap-2">
|
|
563
|
-
<div className="min-w-0">
|
|
564
|
-
<div className="flex items-center gap-2">
|
|
565
|
-
<code className="rounded bg-muted px-1.5 py-0.5 text-xs font-mono">
|
|
566
|
-
{item.code}
|
|
567
|
-
</code>
|
|
568
|
-
<Badge
|
|
569
|
-
variant={item.is_active ? 'default' : 'secondary'}
|
|
570
|
-
className={
|
|
571
|
-
item.is_active
|
|
572
|
-
? 'bg-emerald-500/15 text-emerald-700'
|
|
573
|
-
: ''
|
|
574
|
-
}
|
|
575
|
-
>
|
|
576
|
-
{item.is_active
|
|
577
|
-
? t('columns.activeYes')
|
|
578
|
-
: t('columns.activeNo')}
|
|
579
|
-
</Badge>
|
|
580
|
-
</div>
|
|
581
|
-
<p className="mt-1 font-medium">{item.name}</p>
|
|
582
|
-
{getItemCategoryId(item) ? (
|
|
583
|
-
<Badge
|
|
584
|
-
variant="outline"
|
|
585
|
-
className="mt-1 gap-1.5"
|
|
586
|
-
style={{
|
|
587
|
-
borderColor: getCategoryColor(
|
|
588
|
-
getItemCategoryId(item)
|
|
589
|
-
),
|
|
590
|
-
}}
|
|
591
|
-
>
|
|
592
|
-
{getCategoryColor(getItemCategoryId(item)) ? (
|
|
593
|
-
<span
|
|
594
|
-
className="inline-block size-2 rounded-full"
|
|
595
|
-
style={{
|
|
596
|
-
backgroundColor: getCategoryColor(
|
|
597
|
-
getItemCategoryId(item)
|
|
598
|
-
),
|
|
599
|
-
}}
|
|
600
|
-
/>
|
|
601
|
-
) : null}
|
|
602
|
-
{item.category?.name ??
|
|
603
|
-
getCategoryName(getItemCategoryId(item)) ??
|
|
604
|
-
'-'}
|
|
605
|
-
</Badge>
|
|
606
|
-
) : null}
|
|
607
|
-
<Badge variant="secondary" className="mt-1">
|
|
608
|
-
{calculationTypeLabel(item.default_calculation_type)}
|
|
609
|
-
</Badge>
|
|
610
|
-
</div>
|
|
611
|
-
<div className="flex shrink-0 gap-1">
|
|
612
|
-
<Button
|
|
613
|
-
variant="ghost"
|
|
614
|
-
size="icon"
|
|
615
|
-
className="size-8"
|
|
616
|
-
onClick={(e) => {
|
|
617
|
-
e.stopPropagation();
|
|
618
|
-
openEditSheet(item);
|
|
619
|
-
}}
|
|
620
|
-
>
|
|
621
|
-
<Pencil className="size-3.5" />
|
|
622
|
-
</Button>
|
|
623
|
-
<Button
|
|
624
|
-
variant="ghost"
|
|
625
|
-
size="icon"
|
|
626
|
-
className="size-8 text-destructive hover:text-destructive"
|
|
627
|
-
onClick={(e) => {
|
|
628
|
-
e.stopPropagation();
|
|
629
|
-
setDeleteTarget(item);
|
|
630
|
-
}}
|
|
631
|
-
>
|
|
632
|
-
<Trash2 className="size-3.5" />
|
|
633
|
-
</Button>
|
|
634
|
-
</div>
|
|
635
|
-
</div>
|
|
636
|
-
</CardContent>
|
|
637
|
-
</Card>
|
|
638
|
-
))}
|
|
639
|
-
</div>
|
|
640
|
-
)}
|
|
641
|
-
|
|
642
|
-
{response && response.lastPage > 1 ? (
|
|
643
|
-
<PaginationFooter
|
|
644
|
-
page={page}
|
|
645
|
-
pageSize={pageSize}
|
|
646
|
-
total={response.total}
|
|
647
|
-
lastPage={response.lastPage}
|
|
648
|
-
onPageChange={setPage}
|
|
649
|
-
onPageSizeChange={(size) => {
|
|
650
|
-
setPageSize(size);
|
|
651
|
-
setPage(1);
|
|
652
|
-
}}
|
|
653
|
-
/>
|
|
654
|
-
) : null}
|
|
655
|
-
|
|
656
|
-
{/* Create / Edit Sheet */}
|
|
657
|
-
<Sheet open={isSheetOpen} onOpenChange={setIsSheetOpen}>
|
|
658
|
-
<SheetContent className="flex w-full flex-col overflow-hidden sm:max-w-lg">
|
|
659
|
-
<SheetHeader>
|
|
660
|
-
<SheetTitle>
|
|
661
|
-
{editingItem ? t('sheet.editTitle') : t('sheet.createTitle')}
|
|
662
|
-
</SheetTitle>
|
|
663
|
-
<SheetDescription>{t('sheet.description')}</SheetDescription>
|
|
664
|
-
</SheetHeader>
|
|
665
|
-
|
|
666
|
-
<div className="flex-1 space-y-4 overflow-y-auto px-4 py-4">
|
|
667
|
-
<div className="space-y-1.5">
|
|
668
|
-
<Label htmlFor="ct-category">{t('form.category')}</Label>
|
|
669
|
-
<Select
|
|
670
|
-
value={form.category_id}
|
|
671
|
-
onValueChange={(value) => updateForm('category_id', value)}
|
|
672
|
-
>
|
|
673
|
-
<SelectTrigger id="ct-category" className="w-full">
|
|
674
|
-
<SelectValue placeholder={t('form.categoryPlaceholder')} />
|
|
675
|
-
</SelectTrigger>
|
|
676
|
-
<SelectContent>
|
|
677
|
-
<SelectItem value="none">{t('form.categoryNone')}</SelectItem>
|
|
678
|
-
{categories.map((cat) => (
|
|
679
|
-
<SelectItem key={cat.id} value={String(cat.id)}>
|
|
680
|
-
{cat.name}
|
|
681
|
-
</SelectItem>
|
|
682
|
-
))}
|
|
683
|
-
</SelectContent>
|
|
684
|
-
</Select>
|
|
685
|
-
</div>
|
|
686
|
-
|
|
687
|
-
<div className="grid grid-cols-2 gap-4">
|
|
688
|
-
<div className="space-y-1.5">
|
|
689
|
-
<Label htmlFor="ct-code">
|
|
690
|
-
{t('form.code')} <span className="text-destructive">*</span>
|
|
691
|
-
</Label>
|
|
692
|
-
<Input
|
|
693
|
-
id="ct-code"
|
|
694
|
-
value={form.code}
|
|
695
|
-
onChange={(e) => updateForm('code', e.target.value)}
|
|
696
|
-
placeholder={t('form.codePlaceholder')}
|
|
697
|
-
/>
|
|
698
|
-
</div>
|
|
699
|
-
<div className="space-y-1.5">
|
|
700
|
-
<Label htmlFor="ct-slug">{t('form.slug')}</Label>
|
|
701
|
-
<Input
|
|
702
|
-
id="ct-slug"
|
|
703
|
-
value={form.slug}
|
|
704
|
-
onChange={(e) => updateForm('slug', e.target.value)}
|
|
705
|
-
placeholder={t('form.slugPlaceholder')}
|
|
706
|
-
/>
|
|
707
|
-
</div>
|
|
708
|
-
</div>
|
|
709
|
-
|
|
710
|
-
<div className="space-y-1.5">
|
|
711
|
-
<Label htmlFor="ct-name">
|
|
712
|
-
{t('form.name')} <span className="text-destructive">*</span>
|
|
713
|
-
</Label>
|
|
714
|
-
<Input
|
|
715
|
-
id="ct-name"
|
|
716
|
-
value={form.name}
|
|
717
|
-
onChange={(e) => updateForm('name', e.target.value)}
|
|
718
|
-
placeholder={t('form.namePlaceholder')}
|
|
719
|
-
/>
|
|
720
|
-
</div>
|
|
721
|
-
|
|
722
|
-
<div className="space-y-1.5">
|
|
723
|
-
<Label htmlFor="ct-description">{t('form.description')}</Label>
|
|
724
|
-
<Textarea
|
|
725
|
-
id="ct-description"
|
|
726
|
-
value={form.description}
|
|
727
|
-
onChange={(e) => updateForm('description', e.target.value)}
|
|
728
|
-
placeholder={t('form.descriptionPlaceholder')}
|
|
729
|
-
rows={3}
|
|
730
|
-
/>
|
|
731
|
-
</div>
|
|
732
|
-
|
|
733
|
-
<div className="space-y-1.5">
|
|
734
|
-
<Label htmlFor="ct-default-unit">{t('form.defaultUnit')}</Label>
|
|
735
|
-
<Input
|
|
736
|
-
id="ct-default-unit"
|
|
737
|
-
value={form.default_unit}
|
|
738
|
-
onChange={(e) => updateForm('default_unit', e.target.value)}
|
|
739
|
-
placeholder={t('form.defaultUnitPlaceholder')}
|
|
740
|
-
/>
|
|
741
|
-
</div>
|
|
742
|
-
|
|
743
|
-
<div className="space-y-1.5">
|
|
744
|
-
<Label htmlFor="ct-calc-type">
|
|
745
|
-
{t('form.defaultCalculationType')}
|
|
746
|
-
</Label>
|
|
747
|
-
<Select
|
|
748
|
-
value={form.default_calculation_type}
|
|
749
|
-
onValueChange={(value) =>
|
|
750
|
-
updateForm('default_calculation_type', value)
|
|
751
|
-
}
|
|
752
|
-
>
|
|
753
|
-
<SelectTrigger id="ct-calc-type" className="w-full">
|
|
754
|
-
<SelectValue />
|
|
755
|
-
</SelectTrigger>
|
|
756
|
-
<SelectContent>
|
|
757
|
-
{CALCULATION_TYPE_OPTIONS.map((ct) => (
|
|
758
|
-
<SelectItem key={ct} value={ct}>
|
|
759
|
-
{calculationTypeLabel(ct)}
|
|
760
|
-
</SelectItem>
|
|
761
|
-
))}
|
|
762
|
-
</SelectContent>
|
|
763
|
-
</Select>
|
|
764
|
-
</div>
|
|
765
|
-
|
|
766
|
-
<div className="flex items-center gap-3">
|
|
767
|
-
<Switch
|
|
768
|
-
id="ct-is-recurring-allowed"
|
|
769
|
-
checked={form.is_recurring_allowed}
|
|
770
|
-
onCheckedChange={(checked) =>
|
|
771
|
-
updateForm('is_recurring_allowed', checked)
|
|
772
|
-
}
|
|
773
|
-
/>
|
|
774
|
-
<Label htmlFor="ct-is-recurring-allowed">
|
|
775
|
-
{t('form.isRecurringAllowed')}
|
|
776
|
-
</Label>
|
|
777
|
-
</div>
|
|
778
|
-
|
|
779
|
-
<div className="space-y-1.5">
|
|
780
|
-
<Label htmlFor="ct-sort-order">{t('form.sortOrder')}</Label>
|
|
781
|
-
<Input
|
|
782
|
-
id="ct-sort-order"
|
|
783
|
-
type="number"
|
|
784
|
-
min="0"
|
|
785
|
-
step="1"
|
|
786
|
-
value={form.sort_order}
|
|
787
|
-
onChange={(e) => updateForm('sort_order', e.target.value)}
|
|
788
|
-
/>
|
|
789
|
-
</div>
|
|
790
|
-
|
|
791
|
-
<div className="flex items-center gap-3">
|
|
792
|
-
<Switch
|
|
793
|
-
id="ct-is-active"
|
|
794
|
-
checked={form.is_active}
|
|
795
|
-
onCheckedChange={(checked) => updateForm('is_active', checked)}
|
|
796
|
-
/>
|
|
797
|
-
<Label htmlFor="ct-is-active">{t('form.isActive')}</Label>
|
|
798
|
-
</div>
|
|
799
|
-
</div>
|
|
800
|
-
|
|
801
|
-
<div className="flex justify-end gap-2 border-t p-4">
|
|
802
|
-
<Button
|
|
803
|
-
variant="outline"
|
|
804
|
-
onClick={() => setIsSheetOpen(false)}
|
|
805
|
-
disabled={isSaving}
|
|
806
|
-
>
|
|
807
|
-
{commonT('actions.cancel')}
|
|
808
|
-
</Button>
|
|
809
|
-
<Button onClick={saveItem} disabled={isSaving}>
|
|
810
|
-
{isSaving ? t('messages.saving') : commonT('actions.save')}
|
|
811
|
-
</Button>
|
|
812
|
-
</div>
|
|
813
|
-
</SheetContent>
|
|
814
|
-
</Sheet>
|
|
815
|
-
|
|
816
|
-
{/* Delete Confirmation */}
|
|
817
|
-
<AlertDialog
|
|
818
|
-
open={deleteTarget !== null}
|
|
819
|
-
onOpenChange={(open) => {
|
|
820
|
-
if (!open) setDeleteTarget(null);
|
|
821
|
-
}}
|
|
822
|
-
>
|
|
823
|
-
<AlertDialogContent>
|
|
824
|
-
<AlertDialogHeader>
|
|
825
|
-
<AlertDialogTitle>{t('deleteDialog.title')}</AlertDialogTitle>
|
|
826
|
-
<AlertDialogDescription>
|
|
827
|
-
{t('deleteDialog.description')}
|
|
828
|
-
</AlertDialogDescription>
|
|
829
|
-
</AlertDialogHeader>
|
|
830
|
-
<AlertDialogFooter>
|
|
831
|
-
<AlertDialogCancel disabled={isDeleting}>
|
|
832
|
-
{commonT('actions.cancel')}
|
|
833
|
-
</AlertDialogCancel>
|
|
834
|
-
<AlertDialogAction
|
|
835
|
-
onClick={confirmDelete}
|
|
836
|
-
disabled={isDeleting}
|
|
837
|
-
className="bg-destructive text-destructive-foreground hover:bg-destructive/90"
|
|
838
|
-
>
|
|
839
|
-
{isDeleting ? t('messages.deleting') : commonT('actions.delete')}
|
|
840
|
-
</AlertDialogAction>
|
|
841
|
-
</AlertDialogFooter>
|
|
842
|
-
</AlertDialogContent>
|
|
843
|
-
</AlertDialog>
|
|
844
|
-
</Page>
|
|
845
|
-
);
|
|
846
|
-
}
|