@burdenoff/microfe-crewfoundry 2026.626.1 → 2026.703.2

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.
Files changed (82) hide show
  1. package/dist/crewfoundry/components/forms/ConfirmDialog.js +43 -0
  2. package/dist/crewfoundry/components/forms/ConfirmDialog.js.map +1 -0
  3. package/dist/crewfoundry/components/forms/FormModal.js +220 -0
  4. package/dist/crewfoundry/components/forms/FormModal.js.map +1 -0
  5. package/dist/crewfoundry/components/forms/formValues.js +20 -0
  6. package/dist/crewfoundry/components/forms/formValues.js.map +1 -0
  7. package/dist/crewfoundry/pages/CommunicationsAnnouncementsPagePage.js +255 -65
  8. package/dist/crewfoundry/pages/CommunicationsAnnouncementsPagePage.js.map +1 -1
  9. package/dist/crewfoundry/pages/CommunicationsCallsPagePage.js +28 -17
  10. package/dist/crewfoundry/pages/CommunicationsCallsPagePage.js.map +1 -1
  11. package/dist/crewfoundry/pages/CommunicationsFilesPagePage.js +57 -53
  12. package/dist/crewfoundry/pages/CommunicationsFilesPagePage.js.map +1 -1
  13. package/dist/crewfoundry/pages/CommunicationsMessagesPagePage.js +32 -23
  14. package/dist/crewfoundry/pages/CommunicationsMessagesPagePage.js.map +1 -1
  15. package/dist/crewfoundry/pages/CommunicationsVideoCallsPagePage.js +44 -29
  16. package/dist/crewfoundry/pages/CommunicationsVideoCallsPagePage.js.map +1 -1
  17. package/dist/crewfoundry/pages/CompanyClientManagementPagePage.js +183 -57
  18. package/dist/crewfoundry/pages/CompanyClientManagementPagePage.js.map +1 -1
  19. package/dist/crewfoundry/pages/CompanyCompanyDashboardPagePage.js.map +1 -1
  20. package/dist/crewfoundry/pages/CompanyVendorManagementPagePage.js +214 -92
  21. package/dist/crewfoundry/pages/CompanyVendorManagementPagePage.js.map +1 -1
  22. package/dist/crewfoundry/pages/DashboardDashboardPagePage.js +165 -131
  23. package/dist/crewfoundry/pages/DashboardDashboardPagePage.js.map +1 -1
  24. package/dist/crewfoundry/pages/DashboardEnhancedDashboardPagePage.js +163 -133
  25. package/dist/crewfoundry/pages/DashboardEnhancedDashboardPagePage.js.map +1 -1
  26. package/dist/crewfoundry/pages/HiringCandidatesPagePage.js +269 -54
  27. package/dist/crewfoundry/pages/HiringCandidatesPagePage.js.map +1 -1
  28. package/dist/crewfoundry/pages/HiringCreateJobPagePage.js +225 -78
  29. package/dist/crewfoundry/pages/HiringCreateJobPagePage.js.map +1 -1
  30. package/dist/crewfoundry/pages/HiringInterviewsPagePage.js +213 -59
  31. package/dist/crewfoundry/pages/HiringInterviewsPagePage.js.map +1 -1
  32. package/dist/crewfoundry/pages/HiringJobDetailsPagePage.js +287 -90
  33. package/dist/crewfoundry/pages/HiringJobDetailsPagePage.js.map +1 -1
  34. package/dist/crewfoundry/pages/HiringJobsPagePage.js +49 -47
  35. package/dist/crewfoundry/pages/HiringJobsPagePage.js.map +1 -1
  36. package/dist/crewfoundry/pages/HrDepartmentsPagePage.js +166 -59
  37. package/dist/crewfoundry/pages/HrDepartmentsPagePage.js.map +1 -1
  38. package/dist/crewfoundry/pages/HrEmployeesPagePage.js +274 -83
  39. package/dist/crewfoundry/pages/HrEmployeesPagePage.js.map +1 -1
  40. package/dist/crewfoundry/pages/HrLeaveManagementPagePage.js +198 -88
  41. package/dist/crewfoundry/pages/HrLeaveManagementPagePage.js.map +1 -1
  42. package/dist/crewfoundry/pages/HrPayrollPagePage.js +216 -88
  43. package/dist/crewfoundry/pages/HrPayrollPagePage.js.map +1 -1
  44. package/dist/crewfoundry/pages/HrTimeTrackingPagePage.js +216 -66
  45. package/dist/crewfoundry/pages/HrTimeTrackingPagePage.js.map +1 -1
  46. package/dist/crewfoundry/pages/LearningAssessmentsPagePage.js +6 -7
  47. package/dist/crewfoundry/pages/LearningAssessmentsPagePage.js.map +1 -1
  48. package/dist/crewfoundry/pages/LearningCourseDetailsPagePage.js +83 -68
  49. package/dist/crewfoundry/pages/LearningCourseDetailsPagePage.js.map +1 -1
  50. package/dist/crewfoundry/pages/LearningCoursesPagePage.js +167 -46
  51. package/dist/crewfoundry/pages/LearningCoursesPagePage.js.map +1 -1
  52. package/dist/crewfoundry/pages/LearningLearningPagePage.js.map +1 -1
  53. package/dist/crewfoundry/pages/LearningLearningPathDetailPagePage.js +75 -55
  54. package/dist/crewfoundry/pages/LearningLearningPathDetailPagePage.js.map +1 -1
  55. package/dist/crewfoundry/pages/LearningLearningPathsPagePage.js +152 -79
  56. package/dist/crewfoundry/pages/LearningLearningPathsPagePage.js.map +1 -1
  57. package/dist/crewfoundry/pages/LearningMyLearningPagePage.js +75 -63
  58. package/dist/crewfoundry/pages/LearningMyLearningPagePage.js.map +1 -1
  59. package/dist/crewfoundry/pages/MarketplaceBookingManagementPagePage.js +3 -1
  60. package/dist/crewfoundry/pages/MarketplaceBookingManagementPagePage.js.map +1 -1
  61. package/dist/crewfoundry/pages/MarketplaceMarketplacePagePage.js.map +1 -1
  62. package/dist/crewfoundry/pages/MarketplaceMyServicesPagePage.js +235 -87
  63. package/dist/crewfoundry/pages/MarketplaceMyServicesPagePage.js.map +1 -1
  64. package/dist/crewfoundry/pages/PaymentsInvoicesPagePage.js +199 -86
  65. package/dist/crewfoundry/pages/PaymentsInvoicesPagePage.js.map +1 -1
  66. package/dist/crewfoundry/pages/PaymentsPaymentDashboardPagePage.js.map +1 -1
  67. package/dist/crewfoundry/pages/PaymentsPaymentMethodsPagePage.js +21 -40
  68. package/dist/crewfoundry/pages/PaymentsPaymentMethodsPagePage.js.map +1 -1
  69. package/dist/crewfoundry/pages/ProjectsCreateProjectPagePage.js +117 -45
  70. package/dist/crewfoundry/pages/ProjectsCreateProjectPagePage.js.map +1 -1
  71. package/dist/crewfoundry/pages/ProjectsProjectDetailsPagePage.js +249 -90
  72. package/dist/crewfoundry/pages/ProjectsProjectDetailsPagePage.js.map +1 -1
  73. package/dist/crewfoundry/pages/ProjectsProjectsPagePage.js +47 -45
  74. package/dist/crewfoundry/pages/ProjectsProjectsPagePage.js.map +1 -1
  75. package/dist/crewfoundry/pages/TeamsTeamAnalyticsPagePage.js.map +1 -1
  76. package/dist/crewfoundry/pages/TeamsTeamSettingsPagePage.js +262 -133
  77. package/dist/crewfoundry/pages/TeamsTeamSettingsPagePage.js.map +1 -1
  78. package/dist/crewfoundry/pages/TeamsTeamsPagePage.js +144 -77
  79. package/dist/crewfoundry/pages/TeamsTeamsPagePage.js.map +1 -1
  80. package/dist/crewfoundry/store/crewfoundryStore.js +339 -52
  81. package/dist/crewfoundry/store/crewfoundryStore.js.map +1 -1
  82. package/package.json +1 -1
@@ -1,22 +1,22 @@
1
1
  import { create as e } from "zustand";
2
2
  import { graphqlFetch as t } from "@burdenoff/fe-libs/shared/graphql";
3
3
  //#region src/crewfoundry/store/crewfoundryStore.ts
4
- var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n employees { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore }\n departments { id name headId headName employeeCount budget location status }\n jobPostings { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits }\n candidates { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes }\n interviews { id candidateId candidateName position interviewerName date time type status feedback rating }\n courses { id title category instructor duration level enrolled completed rating status thumbnail description modules skills }\n learningPaths { id title description courses duration level enrolled completionRate }\n marketplaceServices { id title provider category price priceType rating reviews description deliveryTime status skills }\n announcements { id title content author authorRole category priority isPinned createdAt viewCount tags }\n teams { id name description leadId leadName members memberCount department status projectCount createdAt }\n projects { id name description status priority startDate endDate progress budget spent teamId teamName managerId managerName tasks completedTasks }\n payrollRecords { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod }\n leaveRequests { id employeeId employeeName department type startDate endDate days status reason approverName }\n timeEntries { id employeeId employeeName date clockIn clockOut totalHours overtime project status }\n notifications { id title message type category read createdAt actionUrl }\n invoices { id number clientName amount status issueDate dueDate items }\n vendors { id name category contactPerson email phone status contractValue rating }\n clients { id name industry contactPerson email phone status revenue projects since }\n }\n }\n", r = "\n query CrewfoundryWorkspaceBootstrapWithOverlap(\n $workspaceId: ID!\n $projectPagination: PaginationInput\n $groupFirst: Int\n $conversationFirst: Int\n ) {\n crewfoundryBootstrap {\n employees { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore }\n departments { id name headId headName employeeCount budget location status }\n jobPostings { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits }\n candidates { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes }\n interviews { id candidateId candidateName position interviewerName date time type status feedback rating }\n courses { id title category instructor duration level enrolled completed rating status thumbnail description modules skills }\n learningPaths { id title description courses duration level enrolled completionRate }\n marketplaceServices { id title provider category price priceType rating reviews description deliveryTime status skills }\n announcements { id title content author authorRole category priority isPinned createdAt viewCount tags }\n teams { id name description leadId leadName members memberCount department status projectCount createdAt }\n projects { id name description status priority startDate endDate progress budget spent teamId teamName managerId managerName tasks completedTasks }\n payrollRecords { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod }\n leaveRequests { id employeeId employeeName department type startDate endDate days status reason approverName }\n timeEntries { id employeeId employeeName date clockIn clockOut totalHours overtime project status }\n notifications { id title message type category read createdAt actionUrl }\n invoices { id number clientName amount status issueDate dueDate items }\n vendors { id name category contactPerson email phone status contractValue rating }\n clients { id name industry contactPerson email phone status revenue projects since }\n }\n projects(filter: { workspaceId: $workspaceId }, pagination: $projectPagination) {\n items {\n id\n name\n key\n creatorId\n status\n config\n archived\n createdAt\n updatedAt\n }\n }\n groups(first: $groupFirst) {\n edges {\n node {\n id\n name\n description\n groupType\n status\n memberCount\n ownerId\n createdAt\n }\n }\n }\n conversations(first: $conversationFirst) {\n edges {\n node {\n id\n title\n description\n state\n unreadCount\n memberCount\n updatedAt\n }\n }\n }\n }\n", i = "\n query CrewfoundryOverlapBilling {\n getBillingAccountsByOrg {\n id\n name\n isDefault\n paymentMethods {\n id\n type\n brand\n last4\n isDefault\n expiryMonth\n expiryYear\n }\n }\n }\n", a = "mutation CreateCrewEmployee($input: CreateCrewEmployeeInput!) { createCrewEmployee(input: $input) { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore } }", o = "mutation UpdateCrewEmployee($id: ID!, $input: UpdateCrewEmployeeInput!) { updateCrewEmployee(id: $id, input: $input) { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore } }", s = "mutation RemoveCrewEmployee($id: ID!) { removeCrewEmployee(id: $id) }", c = "mutation CreateCrewJobPosting($input: CreateCrewJobPostingInput!) { createCrewJobPosting(input: $input) { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits } }", l = "mutation UpdateCrewJobPosting($id: ID!, $input: UpdateCrewJobPostingInput!) { updateCrewJobPosting(id: $id, input: $input) { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits } }", u = "mutation CreateCrewCandidate($input: CreateCrewCandidateInput!) { createCrewCandidate(input: $input) { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes } }", d = "mutation UpdateCrewCandidate($id: ID!, $input: UpdateCrewCandidateInput!) { updateCrewCandidate(id: $id, input: $input) { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes } }", f = "mutation CreateCrewAnnouncement($input: CreateCrewAnnouncementInput!) { createCrewAnnouncement(input: $input) { id title content author authorRole category priority isPinned createdAt viewCount tags } }", p = "mutation CreateCrewLeaveRequest($input: CreateCrewLeaveRequestInput!) { createCrewLeaveRequest(input: $input) { id employeeId employeeName department type startDate endDate days status reason approverName } }", m = "mutation UpdateCrewLeaveRequest($id: ID!, $input: UpdateCrewLeaveRequestInput!) { updateCrewLeaveRequest(id: $id, input: $input) { id employeeId employeeName department type startDate endDate days status reason approverName } }", h = "mutation MarkCrewNotificationRead($id: ID!) { markCrewNotificationRead(id: $id) }", g = "mutation MarkAllCrewNotificationsRead { markAllCrewNotificationsRead }", _ = (e) => e.toUpperCase().replaceAll("-", "_"), v = (e) => e ? e.slice(0, 10) : "TBD", y = (e) => !e || typeof e != "object" || Array.isArray(e) ? null : e, b = (e) => typeof e == "number" ? e : null, x = (e) => typeof e == "string" ? e : null, S = (e) => {
4
+ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n employees { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore }\n departments { id name headId headName employeeCount budget location status }\n jobPostings { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits }\n candidates { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes }\n interviews { id candidateId candidateName position interviewerName date time type status feedback rating }\n courses { id title category instructor duration level enrolled completed rating status thumbnail description modules skills }\n learningPaths { id title description courses duration level enrolled completionRate }\n marketplaceServices { id title provider category price priceType rating reviews description deliveryTime status skills }\n announcements { id title content author authorRole category priority isPinned createdAt viewCount tags }\n teams { id name description leadId leadName members memberCount department status projectCount createdAt }\n projects { id name description status priority startDate endDate progress budget spent teamId teamName managerId managerName tasks completedTasks }\n payrollRecords { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod }\n leaveRequests { id employeeId employeeName department type startDate endDate days status reason approverName }\n timeEntries { id employeeId employeeName date clockIn clockOut totalHours overtime project status }\n notifications { id title message type category read createdAt actionUrl }\n invoices { id number clientName amount status issueDate dueDate items }\n vendors { id name category contactPerson email phone status contractValue rating }\n clients { id name industry contactPerson email phone status revenue projects since }\n }\n }\n", r = "\n query CrewfoundryWorkspaceBootstrapWithOverlap(\n $workspaceId: ID!\n $projectPagination: PaginationInput\n $groupFirst: Int\n $conversationFirst: Int\n ) {\n crewfoundryBootstrap {\n employees { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore }\n departments { id name headId headName employeeCount budget location status }\n jobPostings { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits }\n candidates { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes }\n interviews { id candidateId candidateName position interviewerName date time type status feedback rating }\n courses { id title category instructor duration level enrolled completed rating status thumbnail description modules skills }\n learningPaths { id title description courses duration level enrolled completionRate }\n marketplaceServices { id title provider category price priceType rating reviews description deliveryTime status skills }\n announcements { id title content author authorRole category priority isPinned createdAt viewCount tags }\n teams { id name description leadId leadName members memberCount department status projectCount createdAt }\n projects { id name description status priority startDate endDate progress budget spent teamId teamName managerId managerName tasks completedTasks }\n payrollRecords { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod }\n leaveRequests { id employeeId employeeName department type startDate endDate days status reason approverName }\n timeEntries { id employeeId employeeName date clockIn clockOut totalHours overtime project status }\n notifications { id title message type category read createdAt actionUrl }\n invoices { id number clientName amount status issueDate dueDate items }\n vendors { id name category contactPerson email phone status contractValue rating }\n clients { id name industry contactPerson email phone status revenue projects since }\n }\n projects(filter: { workspaceId: $workspaceId }, pagination: $projectPagination) {\n items {\n id\n name\n key\n creatorId\n status\n config\n archived\n createdAt\n updatedAt\n }\n }\n groups(first: $groupFirst) {\n edges {\n node {\n id\n name\n description\n groupType\n status\n memberCount\n ownerId\n createdAt\n }\n }\n }\n conversations(first: $conversationFirst) {\n edges {\n node {\n id\n title\n description\n state\n unreadCount\n memberCount\n updatedAt\n }\n }\n }\n }\n", i = "\n query CrewfoundryOverlapBilling {\n getBillingAccountsByOrg {\n id\n name\n isDefault\n paymentMethods {\n id\n type\n brand\n last4\n isDefault\n expiryMonth\n expiryYear\n }\n }\n }\n", a = "mutation CreateCrewEmployee($input: CreateCrewEmployeeInput!) { createCrewEmployee(input: $input) { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore } }", o = "mutation UpdateCrewEmployee($id: ID!, $input: UpdateCrewEmployeeInput!) { updateCrewEmployee(id: $id, input: $input) { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore } }", s = "mutation RemoveCrewEmployee($id: ID!) { removeCrewEmployee(id: $id) }", c = "mutation CreateCrewJobPosting($input: CreateCrewJobPostingInput!) { createCrewJobPosting(input: $input) { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits } }", l = "mutation UpdateCrewJobPosting($id: ID!, $input: UpdateCrewJobPostingInput!) { updateCrewJobPosting(id: $id, input: $input) { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits } }", u = "mutation CreateCrewCandidate($input: CreateCrewCandidateInput!) { createCrewCandidate(input: $input) { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes } }", d = "mutation UpdateCrewCandidate($id: ID!, $input: UpdateCrewCandidateInput!) { updateCrewCandidate(id: $id, input: $input) { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes } }", f = "mutation CreateCrewAnnouncement($input: CreateCrewAnnouncementInput!) { createCrewAnnouncement(input: $input) { id title content author authorRole category priority isPinned createdAt viewCount tags } }", p = "mutation CreateCrewLeaveRequest($input: CreateCrewLeaveRequestInput!) { createCrewLeaveRequest(input: $input) { id employeeId employeeName department type startDate endDate days status reason approverName } }", m = "mutation UpdateCrewLeaveRequest($id: ID!, $input: UpdateCrewLeaveRequestInput!) { updateCrewLeaveRequest(id: $id, input: $input) { id employeeId employeeName department type startDate endDate days status reason approverName } }", h = "mutation MarkCrewNotificationRead($id: ID!) { markCrewNotificationRead(id: $id) }", ee = "mutation MarkAllCrewNotificationsRead { markAllCrewNotificationsRead }", te = "mutation RemoveCrewJobPosting($id: ID!) { removeCrewJobPosting(id: $id) }", ne = "mutation RemoveCrewCandidate($id: ID!) { removeCrewCandidate(id: $id) }", re = "mutation UpdateCrewAnnouncement($id: ID!, $input: UpdateCrewAnnouncementInput!) { updateCrewAnnouncement(id: $id, input: $input) { id title content author authorRole category priority isPinned createdAt viewCount tags } }", ie = "mutation RemoveCrewAnnouncement($id: ID!) { removeCrewAnnouncement(id: $id) }", ae = "mutation CreateCrewInterview($input: CreateCrewInterviewInput!) { createCrewInterview(input: $input) { id candidateId candidateName position interviewerName date time type status feedback rating } }", oe = "mutation UpdateCrewInterview($id: ID!, $input: UpdateCrewInterviewInput!) { updateCrewInterview(id: $id, input: $input) { id candidateId candidateName position interviewerName date time type status feedback rating } }", se = "mutation RemoveCrewInterview($id: ID!) { removeCrewInterview(id: $id) }", g = "mutation CreateCrewInvoice($input: CreateCrewInvoiceInput!) { createCrewInvoice(input: $input) { id number clientName amount status issueDate dueDate items } }", _ = "mutation UpdateCrewInvoice($id: ID!, $input: UpdateCrewInvoiceInput!) { updateCrewInvoice(id: $id, input: $input) { id number clientName amount status issueDate dueDate items } }", v = "mutation RemoveCrewInvoice($id: ID!) { removeCrewInvoice(id: $id) }", y = "mutation CreateCrewVendor($input: CreateCrewVendorInput!) { createCrewVendor(input: $input) { id name category contactPerson email phone status contractValue rating } }", b = "mutation UpdateCrewVendor($id: ID!, $input: UpdateCrewVendorInput!) { updateCrewVendor(id: $id, input: $input) { id name category contactPerson email phone status contractValue rating } }", x = "mutation RemoveCrewVendor($id: ID!) { removeCrewVendor(id: $id) }", S = "mutation CreateCrewClient($input: CreateCrewClientInput!) { createCrewClient(input: $input) { id name industry contactPerson email phone status revenue projects since } }", C = "mutation UpdateCrewClient($id: ID!, $input: UpdateCrewClientInput!) { updateCrewClient(id: $id, input: $input) { id name industry contactPerson email phone status revenue projects since } }", w = "mutation RemoveCrewClient($id: ID!) { removeCrewClient(id: $id) }", T = "mutation CreateCrewTeam($input: CreateCrewTeamInput!) { createCrewTeam(input: $input) { id name description leadId leadName members memberCount department status projectCount createdAt } }", E = "mutation UpdateCrewTeam($id: ID!, $input: UpdateCrewTeamInput!) { updateCrewTeam(id: $id, input: $input) { id name description leadId leadName members memberCount department status projectCount createdAt } }", D = "mutation RemoveCrewTeam($id: ID!) { removeCrewTeam(id: $id) }", O = "mutation CreateCrewProject($input: CreateCrewProjectInput!) { createCrewProject(input: $input) { id name description status priority startDate endDate progress budget spent teamId teamName managerId managerName tasks completedTasks } }", k = "mutation UpdateCrewProject($id: ID!, $input: UpdateCrewProjectInput!) { updateCrewProject(id: $id, input: $input) { id name description status priority startDate endDate progress budget spent teamId teamName managerId managerName tasks completedTasks } }", A = "mutation RemoveCrewProject($id: ID!) { removeCrewProject(id: $id) }", j = "mutation CreateCrewMarketplaceService($input: CreateCrewMarketplaceServiceInput!) { createCrewMarketplaceService(input: $input) { id title provider category price priceType rating reviews description deliveryTime status skills } }", M = "mutation UpdateCrewMarketplaceService($id: ID!, $input: UpdateCrewMarketplaceServiceInput!) { updateCrewMarketplaceService(id: $id, input: $input) { id title provider category price priceType rating reviews description deliveryTime status skills } }", N = "mutation RemoveCrewMarketplaceService($id: ID!) { removeCrewMarketplaceService(id: $id) }", P = "mutation CreateCrewDepartment($input: CreateCrewDepartmentInput!) { createCrewDepartment(input: $input) { id name headId headName employeeCount budget location status } }", F = "mutation UpdateCrewDepartment($id: ID!, $input: UpdateCrewDepartmentInput!) { updateCrewDepartment(id: $id, input: $input) { id name headId headName employeeCount budget location status } }", I = "mutation RemoveCrewDepartment($id: ID!) { removeCrewDepartment(id: $id) }", L = "id title category instructor duration level enrolled completed rating status thumbnail description modules skills", R = `mutation CreateCrewCourse($input: CreateCrewCourseInput!) { createCrewCourse(input: $input) { ${L} } }`, z = `mutation UpdateCrewCourse($id: ID!, $input: UpdateCrewCourseInput!) { updateCrewCourse(id: $id, input: $input) { ${L} } }`, ce = "mutation RemoveCrewCourse($id: ID!) { removeCrewCourse(id: $id) }", B = `mutation EnrollCrewCourse($id: ID!) { enrollCrewCourse(id: $id) { ${L} } }`, V = "mutation CreateCrewLearningPath($input: CreateCrewLearningPathInput!) { createCrewLearningPath(input: $input) { id title description courses duration level enrolled completionRate } }", H = "mutation UpdateCrewLearningPath($id: ID!, $input: UpdateCrewLearningPathInput!) { updateCrewLearningPath(id: $id, input: $input) { id title description courses duration level enrolled completionRate } }", U = "mutation RemoveCrewLearningPath($id: ID!) { removeCrewLearningPath(id: $id) }", W = "mutation CreateCrewPayrollRecord($input: CreateCrewPayrollRecordInput!) { createCrewPayrollRecord(input: $input) { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod } }", G = "mutation UpdateCrewPayrollRecord($id: ID!, $input: UpdateCrewPayrollRecordInput!) { updateCrewPayrollRecord(id: $id, input: $input) { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod } }", le = "mutation RemoveCrewPayrollRecord($id: ID!) { removeCrewPayrollRecord(id: $id) }", ue = "mutation CreateCrewTimeEntry($input: CreateCrewTimeEntryInput!) { createCrewTimeEntry(input: $input) { id employeeId employeeName date clockIn clockOut totalHours overtime project status } }", de = "mutation UpdateCrewTimeEntry($id: ID!, $input: UpdateCrewTimeEntryInput!) { updateCrewTimeEntry(id: $id, input: $input) { id employeeId employeeName date clockIn clockOut totalHours overtime project status } }", fe = "mutation RemoveCrewTimeEntry($id: ID!) { removeCrewTimeEntry(id: $id) }", K = (e) => e.toUpperCase().replaceAll("-", "_"), q = (e) => e ? e.slice(0, 10) : "TBD", pe = (e) => !e || typeof e != "object" || Array.isArray(e) ? null : e, J = (e) => typeof e == "number" ? e : null, Y = (e) => typeof e == "string" ? e : null, me = (e) => {
5
5
  let t = e.toLowerCase();
6
6
  return t === "active" ? "active" : t === "completed" ? "completed" : t === "cancelled" ? "cancelled" : t === "archived" ? "on_hold" : "planning";
7
- }, C = (e) => {
7
+ }, he = (e) => {
8
8
  let t = e.toLowerCase();
9
9
  return t === "active" ? "active" : t === "inactive" || t === "archived" || t === "deleted" ? "disbanded" : "forming";
10
- }, w = (e, t) => e.map((e, n) => {
11
- let r = y(e.config), i = b(r?.budget) ?? 25e3 + n * 2500, a = b(r?.spent) ?? Math.round(i * (e.status === "COMPLETED" ? 1 : .62)), o = b(r?.progress) ?? (e.status === "COMPLETED" ? 100 : 58), s = b(r?.tasks) ?? 20 + n % 9, c = b(r?.completedTasks) ?? Math.round(o / 100 * s), l = t[n % Math.max(t.length, 1)];
10
+ }, ge = (e, t) => e.map((e, n) => {
11
+ let r = pe(e.config), i = J(r?.budget) ?? 25e3 + n * 2500, a = J(r?.spent) ?? Math.round(i * (e.status === "COMPLETED" ? 1 : .62)), o = J(r?.progress) ?? (e.status === "COMPLETED" ? 100 : 58), s = J(r?.tasks) ?? 20 + n % 9, c = J(r?.completedTasks) ?? Math.round(o / 100 * s), l = t[n % Math.max(t.length, 1)];
12
12
  return {
13
13
  id: e.id,
14
14
  name: e.name,
15
- description: x(r?.description) || `${e.key} delivery plan`,
16
- status: S(e.status),
17
- priority: x(r?.priority)?.toLowerCase() || "medium",
18
- startDate: v(e.createdAt),
19
- endDate: v(e.updatedAt),
15
+ description: Y(r?.description) || `${e.key} delivery plan`,
16
+ status: me(e.status),
17
+ priority: Y(r?.priority)?.toLowerCase() || "medium",
18
+ startDate: q(e.createdAt),
19
+ endDate: q(e.updatedAt),
20
20
  progress: o,
21
21
  budget: i,
22
22
  spent: a,
@@ -27,7 +27,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
27
27
  tasks: s,
28
28
  completedTasks: c
29
29
  };
30
- }), T = (e) => e.map(({ node: e }) => ({
30
+ }), _e = (e) => e.map(({ node: e }) => ({
31
31
  id: e.id,
32
32
  name: e.name,
33
33
  description: e.description || `${e.name} team workspace`,
@@ -36,10 +36,10 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
36
36
  members: [],
37
37
  memberCount: e.memberCount,
38
38
  department: e.groupType?.toLowerCase().replaceAll("_", " ") || "operations",
39
- status: C(e.status),
39
+ status: he(e.status),
40
40
  projectCount: 0,
41
- createdAt: v(e.createdAt)
42
- })), E = (e) => e.filter(({ node: e }) => e.unreadCount > 0).map(({ node: e }) => ({
41
+ createdAt: q(e.createdAt)
42
+ })), ve = (e) => e.filter(({ node: e }) => e.unreadCount > 0).map(({ node: e }) => ({
43
43
  id: `conversation-${e.id}`,
44
44
  title: e.title || "Conversation update",
45
45
  message: `${e.unreadCount} unread in ${e.memberCount}-member channel`,
@@ -48,10 +48,10 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
48
48
  read: !1,
49
49
  createdAt: e.updatedAt,
50
50
  actionUrl: "/crewfoundry/communications/messages-page"
51
- })), D = (e, t) => {
51
+ })), ye = (e, t) => {
52
52
  let n = new Set(e.map((e) => e.id));
53
53
  return [...t.filter((e) => !n.has(e.id)), ...e];
54
- }, O = (e) => {
54
+ }, X = (e) => {
55
55
  let t = e.getBillingAccountsByOrg.find((e) => e?.isDefault && e?.id) || e.getBillingAccountsByOrg.find((e) => e?.id);
56
56
  return t?.id ? (t.paymentMethods || []).filter((e) => !!e).map((e) => {
57
57
  let n = e.expiryMonth ? String(e.expiryMonth).padStart(2, "0") : void 0, r = e.expiryYear ? String(e.expiryYear) : void 0, i = e.type === "BANK_TRANSFER" || e.type === "NETBANKING";
@@ -65,18 +65,56 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
65
65
  expiry: n && r ? `${n}/${r}` : void 0
66
66
  };
67
67
  }) : [];
68
- }, k = (e, t) => {
68
+ }, be = (e, t) => {
69
69
  if (e.errors?.length) throw Error(e.errors[0]?.message || t);
70
70
  if (!e.data) throw Error(t);
71
71
  return e.data;
72
- }, A = async (e, n, r, i) => k(await t({
73
- gateway: "workspace",
72
+ }, xe = new Set([
73
+ "id",
74
+ "createdAt",
75
+ "createdOn",
76
+ "updatedAt",
77
+ "deletedAt",
78
+ "employeeCount",
79
+ "memberCount",
80
+ "projectCount",
81
+ "enrolled",
82
+ "completed",
83
+ "completionRate",
84
+ "reviews",
85
+ "rating",
86
+ "tasks",
87
+ "completedTasks",
88
+ "spent",
89
+ "progress",
90
+ "applicants",
91
+ "viewCount",
92
+ "revenue",
93
+ "projects"
94
+ ]), Se = (e) => {
95
+ if (!e) return e;
96
+ let t = e.input;
97
+ if (!t || typeof t != "object" || Array.isArray(t)) return e;
98
+ let n = {};
99
+ for (let [e, r] of Object.entries(t)) xe.has(e) || (n[e] = r);
100
+ return {
101
+ ...e,
102
+ input: n
103
+ };
104
+ }, Z = async (e, n, r, i, a = "workspace") => be(await t({
105
+ gateway: a,
74
106
  query: e,
75
- variables: n,
107
+ variables: Se(n),
76
108
  authToken: r.authToken,
77
- baseUrl: r.apiGatewayUrl,
78
- extraHeaders: { ...r.workspaceId ? { "x-workspace-id": r.workspaceId } : {} }
79
- }), i), j = e((e) => ({
109
+ baseUrl: a === "workspace" ? r.apiGatewayUrl : void 0,
110
+ extraHeaders: { ...a === "workspace" && r.workspaceId ? { "x-workspace-id": r.workspaceId } : {} }
111
+ }), i), Ce = () => !1, Q = async (e, t, n, r, i = "workspace") => {
112
+ try {
113
+ return await Z(e, t, n, r, i);
114
+ } catch (e) {
115
+ return Ce() && console.warn(`[crewfoundry] overlap query skipped: ${r}`, e), null;
116
+ }
117
+ }, $ = e((e) => ({
80
118
  metrics: [
81
119
  {
82
120
  label: "Total Employees",
@@ -161,7 +199,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
161
199
  initParams: t
162
200
  });
163
201
  try {
164
- let [a, o] = await Promise.all([A(r, {
202
+ let [a, o] = await Promise.all([Q(r, {
165
203
  workspaceId: t.workspaceId,
166
204
  projectPagination: {
167
205
  limit: 50,
@@ -169,7 +207,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
169
207
  },
170
208
  groupFirst: 30,
171
209
  conversationFirst: 30
172
- }, t, "Unable to load workspace bootstrap with overlap data").catch(() => null), A(i, void 0, t, "Unable to load overlap billing data").catch(() => null)]), s = a ? a.crewfoundryBootstrap : (await A(n, void 0, t, "Unable to load CrewFoundry data")).crewfoundryBootstrap, c = a ? T(a.groups.edges) : [], l = a ? w(a.projects.items, c) : [], u = a ? E(a.conversations.edges) : [], d = c.length > 0 ? c : s.teams, f = l.length > 0 ? l : s.projects, p = u.length > 0 ? D(s.notifications, u) : s.notifications, m = o ? O(o) : [];
210
+ }, t, "Unable to load workspace bootstrap with overlap data"), Q(i, void 0, t, "Unable to load overlap billing data", "global")]), s = a ? a.crewfoundryBootstrap : (await Z(n, void 0, t, "Unable to load CrewFoundry data")).crewfoundryBootstrap, c = a ? _e(a.groups.edges) : [], l = a ? ge(a.projects.items, c) : [], u = a ? ve(a.conversations.edges) : [], d = c.length > 0 ? c : s.teams, f = l.length > 0 ? l : s.projects, p = u.length > 0 ? ye(s.notifications, u) : s.notifications, m = o ? X(o) : [];
173
211
  e({
174
212
  employees: s.employees,
175
213
  departments: s.departments,
@@ -226,101 +264,350 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
226
264
  setSelectedView: (t) => e({ selectedView: t }),
227
265
  setWorkItems: (t) => e({ workItems: t }),
228
266
  addEmployee: async (t) => {
229
- let n = j.getState().initParams, r = await A(a, { input: {
267
+ let n = $.getState().initParams, r = await Z(a, { input: {
230
268
  ...t,
231
- status: _(t.status),
232
- type: _(t.type)
269
+ status: K(t.status),
270
+ type: K(t.type)
233
271
  } }, n, "Unable to create employee");
234
272
  e((e) => ({ employees: [r.createCrewEmployee, ...e.employees] }));
235
273
  },
236
274
  updateEmployee: async (t, n) => {
237
- let r = j.getState().initParams, i = await A(o, {
275
+ let r = $.getState().initParams, i = await Z(o, {
238
276
  id: t,
239
277
  input: {
240
278
  ...n,
241
- ...n.status ? { status: _(n.status) } : {},
242
- ...n.type ? { type: _(n.type) } : {}
279
+ ...n.status ? { status: K(n.status) } : {},
280
+ ...n.type ? { type: K(n.type) } : {}
243
281
  }
244
282
  }, r, "Unable to update employee");
245
283
  e((e) => ({ employees: e.employees.map((e) => e.id === t ? i.updateCrewEmployee : e) }));
246
284
  },
247
285
  removeEmployee: async (t) => {
248
- let n = j.getState().initParams;
249
- await A(s, { id: t }, n, "Unable to remove employee"), e((e) => ({ employees: e.employees.filter((e) => e.id !== t) }));
286
+ let n = $.getState().initParams;
287
+ await Z(s, { id: t }, n, "Unable to remove employee"), e((e) => ({ employees: e.employees.filter((e) => e.id !== t) }));
250
288
  },
251
289
  addJobPosting: async (t) => {
252
- let n = j.getState().initParams, r = await A(c, { input: {
290
+ let n = $.getState().initParams, r = await Z(c, { input: {
253
291
  ...t,
254
- status: _(t.status)
292
+ status: K(t.status)
255
293
  } }, n, "Unable to create job posting");
256
294
  e((e) => ({ jobPostings: [r.createCrewJobPosting, ...e.jobPostings] }));
257
295
  },
258
296
  updateJobPosting: async (t, n) => {
259
- let r = j.getState().initParams, i = await A(l, {
297
+ let r = $.getState().initParams, i = await Z(l, {
260
298
  id: t,
261
299
  input: {
262
300
  ...n,
263
- ...n.status ? { status: _(n.status) } : {}
301
+ ...n.status ? { status: K(n.status) } : {}
264
302
  }
265
303
  }, r, "Unable to update job posting");
266
304
  e((e) => ({ jobPostings: e.jobPostings.map((e) => e.id === t ? i.updateCrewJobPosting : e) }));
267
305
  },
268
306
  addCandidate: async (t) => {
269
- let n = j.getState().initParams, r = await A(u, { input: {
307
+ let n = $.getState().initParams, r = await Z(u, { input: {
270
308
  ...t,
271
- status: _(t.status)
309
+ status: K(t.status)
272
310
  } }, n, "Unable to create candidate");
273
311
  e((e) => ({ candidates: [r.createCrewCandidate, ...e.candidates] }));
274
312
  },
275
313
  updateCandidate: async (t, n) => {
276
- let r = j.getState().initParams, i = await A(d, {
314
+ let r = $.getState().initParams, i = await Z(d, {
277
315
  id: t,
278
316
  input: {
279
317
  ...n,
280
- ...n.status ? { status: _(n.status) } : {}
318
+ ...n.status ? { status: K(n.status) } : {}
281
319
  }
282
320
  }, r, "Unable to update candidate");
283
321
  e((e) => ({ candidates: e.candidates.map((e) => e.id === t ? i.updateCrewCandidate : e) }));
284
322
  },
285
323
  addAnnouncement: async (t) => {
286
- let n = j.getState().initParams, r = await A(f, { input: t }, n, "Unable to create announcement");
324
+ let n = $.getState().initParams, r = await Z(f, { input: t }, n, "Unable to create announcement");
287
325
  e((e) => ({ announcements: [r.createCrewAnnouncement, ...e.announcements] }));
288
326
  },
289
327
  addLeaveRequest: async (t) => {
290
- let n = j.getState().initParams, r = await A(p, { input: {
328
+ let n = $.getState().initParams, r = await Z(p, { input: {
291
329
  ...t,
292
- type: _(t.type),
293
- status: _(t.status)
330
+ type: K(t.type),
331
+ status: K(t.status)
294
332
  } }, n, "Unable to create leave request");
295
333
  e((e) => ({ leaveRequests: [r.createCrewLeaveRequest, ...e.leaveRequests] }));
296
334
  },
297
335
  updateLeaveRequest: async (t, n) => {
298
- let r = j.getState().initParams, i = await A(m, {
336
+ let r = $.getState().initParams, i = await Z(m, {
299
337
  id: t,
300
338
  input: {
301
339
  ...n,
302
- ...n.type ? { type: _(n.type) } : {},
303
- ...n.status ? { status: _(n.status) } : {}
340
+ ...n.type ? { type: K(n.type) } : {},
341
+ ...n.status ? { status: K(n.status) } : {}
304
342
  }
305
343
  }, r, "Unable to update leave request");
306
344
  e((e) => ({ leaveRequests: e.leaveRequests.map((e) => e.id === t ? i.updateCrewLeaveRequest : e) }));
307
345
  },
308
346
  markNotificationRead: async (t) => {
309
- let n = j.getState().initParams;
310
- await A(h, { id: t }, n, "Unable to update notification"), e((e) => ({ notifications: e.notifications.map((e) => e.id === t ? {
347
+ let n = $.getState().initParams;
348
+ await Z(h, { id: t }, n, "Unable to update notification"), e((e) => ({ notifications: e.notifications.map((e) => e.id === t ? {
311
349
  ...e,
312
350
  read: !0
313
351
  } : e) }));
314
352
  },
315
353
  markAllNotificationsRead: async () => {
316
- let t = j.getState().initParams;
317
- await A(g, void 0, t, "Unable to update notifications"), e((e) => ({ notifications: e.notifications.map((e) => ({
354
+ let t = $.getState().initParams;
355
+ await Z(ee, void 0, t, "Unable to update notifications"), e((e) => ({ notifications: e.notifications.map((e) => ({
318
356
  ...e,
319
357
  read: !0
320
358
  })) }));
359
+ },
360
+ removeJobPosting: async (t) => {
361
+ let n = $.getState().initParams;
362
+ await Z(te, { id: t }, n, "Unable to remove job posting"), e((e) => ({ jobPostings: e.jobPostings.filter((e) => e.id !== t) }));
363
+ },
364
+ removeCandidate: async (t) => {
365
+ let n = $.getState().initParams;
366
+ await Z(ne, { id: t }, n, "Unable to remove candidate"), e((e) => ({ candidates: e.candidates.filter((e) => e.id !== t) }));
367
+ },
368
+ updateAnnouncement: async (t, n) => {
369
+ let r = $.getState().initParams, i = await Z(re, {
370
+ id: t,
371
+ input: n
372
+ }, r, "Unable to update announcement");
373
+ e((e) => ({ announcements: e.announcements.map((e) => e.id === t ? i.updateCrewAnnouncement : e) }));
374
+ },
375
+ removeAnnouncement: async (t) => {
376
+ let n = $.getState().initParams;
377
+ await Z(ie, { id: t }, n, "Unable to remove announcement"), e((e) => ({ announcements: e.announcements.filter((e) => e.id !== t) }));
378
+ },
379
+ addInterview: async (t) => {
380
+ let n = $.getState().initParams, r = await Z(ae, { input: {
381
+ ...t,
382
+ type: K(t.type),
383
+ status: K(t.status)
384
+ } }, n, "Unable to schedule interview");
385
+ e((e) => ({ interviews: [r.createCrewInterview, ...e.interviews] }));
386
+ },
387
+ updateInterview: async (t, n) => {
388
+ let r = $.getState().initParams, i = await Z(oe, {
389
+ id: t,
390
+ input: {
391
+ ...n,
392
+ ...n.type ? { type: K(n.type) } : {},
393
+ ...n.status ? { status: K(n.status) } : {}
394
+ }
395
+ }, r, "Unable to update interview");
396
+ e((e) => ({ interviews: e.interviews.map((e) => e.id === t ? i.updateCrewInterview : e) }));
397
+ },
398
+ removeInterview: async (t) => {
399
+ let n = $.getState().initParams;
400
+ await Z(se, { id: t }, n, "Unable to remove interview"), e((e) => ({ interviews: e.interviews.filter((e) => e.id !== t) }));
401
+ },
402
+ addInvoice: async (t) => {
403
+ let n = $.getState().initParams, r = await Z(g, { input: {
404
+ ...t,
405
+ status: K(t.status)
406
+ } }, n, "Unable to create invoice");
407
+ e((e) => ({ invoices: [r.createCrewInvoice, ...e.invoices] }));
408
+ },
409
+ updateInvoice: async (t, n) => {
410
+ let r = $.getState().initParams, i = await Z(_, {
411
+ id: t,
412
+ input: {
413
+ ...n,
414
+ ...n.status ? { status: K(n.status) } : {}
415
+ }
416
+ }, r, "Unable to update invoice");
417
+ e((e) => ({ invoices: e.invoices.map((e) => e.id === t ? i.updateCrewInvoice : e) }));
418
+ },
419
+ removeInvoice: async (t) => {
420
+ let n = $.getState().initParams;
421
+ await Z(v, { id: t }, n, "Unable to remove invoice"), e((e) => ({ invoices: e.invoices.filter((e) => e.id !== t) }));
422
+ },
423
+ addVendor: async (t) => {
424
+ let n = $.getState().initParams, r = await Z(y, { input: {
425
+ ...t,
426
+ status: K(t.status)
427
+ } }, n, "Unable to create vendor");
428
+ e((e) => ({ vendors: [r.createCrewVendor, ...e.vendors] }));
429
+ },
430
+ updateVendor: async (t, n) => {
431
+ let r = $.getState().initParams, i = await Z(b, {
432
+ id: t,
433
+ input: {
434
+ ...n,
435
+ ...n.status ? { status: K(n.status) } : {}
436
+ }
437
+ }, r, "Unable to update vendor");
438
+ e((e) => ({ vendors: e.vendors.map((e) => e.id === t ? i.updateCrewVendor : e) }));
439
+ },
440
+ removeVendor: async (t) => {
441
+ let n = $.getState().initParams;
442
+ await Z(x, { id: t }, n, "Unable to remove vendor"), e((e) => ({ vendors: e.vendors.filter((e) => e.id !== t) }));
443
+ },
444
+ addClient: async (t) => {
445
+ let n = $.getState().initParams, r = await Z(S, { input: {
446
+ ...t,
447
+ status: K(t.status)
448
+ } }, n, "Unable to create client");
449
+ e((e) => ({ clients: [r.createCrewClient, ...e.clients] }));
450
+ },
451
+ updateClient: async (t, n) => {
452
+ let r = $.getState().initParams, i = await Z(C, {
453
+ id: t,
454
+ input: {
455
+ ...n,
456
+ ...n.status ? { status: K(n.status) } : {}
457
+ }
458
+ }, r, "Unable to update client");
459
+ e((e) => ({ clients: e.clients.map((e) => e.id === t ? i.updateCrewClient : e) }));
460
+ },
461
+ removeClient: async (t) => {
462
+ let n = $.getState().initParams;
463
+ await Z(w, { id: t }, n, "Unable to remove client"), e((e) => ({ clients: e.clients.filter((e) => e.id !== t) }));
464
+ },
465
+ addTeam: async (t) => {
466
+ let n = $.getState().initParams, r = await Z(T, { input: t }, n, "Unable to create team");
467
+ e((e) => ({ teams: [r.createCrewTeam, ...e.teams] }));
468
+ },
469
+ updateTeam: async (t, n) => {
470
+ let r = $.getState().initParams, i = await Z(E, {
471
+ id: t,
472
+ input: n
473
+ }, r, "Unable to update team");
474
+ e((e) => ({ teams: e.teams.map((e) => e.id === t ? i.updateCrewTeam : e) }));
475
+ },
476
+ removeTeam: async (t) => {
477
+ let n = $.getState().initParams;
478
+ await Z(D, { id: t }, n, "Unable to remove team"), e((e) => ({ teams: e.teams.filter((e) => e.id !== t) }));
479
+ },
480
+ addProject: async (t) => {
481
+ let n = $.getState().initParams, r = await Z(O, { input: {
482
+ ...t,
483
+ status: K(t.status),
484
+ priority: K(t.priority)
485
+ } }, n, "Unable to create project");
486
+ e((e) => ({ projects: [r.createCrewProject, ...e.projects] }));
487
+ },
488
+ updateProject: async (t, n) => {
489
+ let r = $.getState().initParams, i = await Z(k, {
490
+ id: t,
491
+ input: {
492
+ ...n,
493
+ ...n.status ? { status: K(n.status) } : {},
494
+ ...n.priority ? { priority: K(n.priority) } : {}
495
+ }
496
+ }, r, "Unable to update project");
497
+ e((e) => ({ projects: e.projects.map((e) => e.id === t ? i.updateCrewProject : e) }));
498
+ },
499
+ removeProject: async (t) => {
500
+ let n = $.getState().initParams;
501
+ await Z(A, { id: t }, n, "Unable to remove project"), e((e) => ({ projects: e.projects.filter((e) => e.id !== t) }));
502
+ },
503
+ addMarketplaceService: async (t) => {
504
+ let n = $.getState().initParams, r = await Z(j, { input: {
505
+ ...t,
506
+ status: K(t.status)
507
+ } }, n, "Unable to create service");
508
+ e((e) => ({ marketplaceServices: [r.createCrewMarketplaceService, ...e.marketplaceServices] }));
509
+ },
510
+ updateMarketplaceService: async (t, n) => {
511
+ let r = $.getState().initParams, i = await Z(M, {
512
+ id: t,
513
+ input: {
514
+ ...n,
515
+ ...n.status ? { status: K(n.status) } : {}
516
+ }
517
+ }, r, "Unable to update service");
518
+ e((e) => ({ marketplaceServices: e.marketplaceServices.map((e) => e.id === t ? i.updateCrewMarketplaceService : e) }));
519
+ },
520
+ removeMarketplaceService: async (t) => {
521
+ let n = $.getState().initParams;
522
+ await Z(N, { id: t }, n, "Unable to remove service"), e((e) => ({ marketplaceServices: e.marketplaceServices.filter((e) => e.id !== t) }));
523
+ },
524
+ addDepartment: async (t) => {
525
+ let n = $.getState().initParams, r = await Z(P, { input: t }, n, "Unable to create department");
526
+ e((e) => ({ departments: [r.createCrewDepartment, ...e.departments] }));
527
+ },
528
+ updateDepartment: async (t, n) => {
529
+ let r = $.getState().initParams, i = await Z(F, {
530
+ id: t,
531
+ input: n
532
+ }, r, "Unable to update department");
533
+ e((e) => ({ departments: e.departments.map((e) => e.id === t ? i.updateCrewDepartment : e) }));
534
+ },
535
+ removeDepartment: async (t) => {
536
+ let n = $.getState().initParams;
537
+ await Z(I, { id: t }, n, "Unable to remove department"), e((e) => ({ departments: e.departments.filter((e) => e.id !== t) }));
538
+ },
539
+ addCourse: async (t) => {
540
+ let n = $.getState().initParams, r = await Z(R, { input: t }, n, "Unable to create course");
541
+ e((e) => ({ courses: [r.createCrewCourse, ...e.courses] }));
542
+ },
543
+ updateCourse: async (t, n) => {
544
+ let r = $.getState().initParams, i = await Z(z, {
545
+ id: t,
546
+ input: n
547
+ }, r, "Unable to update course");
548
+ e((e) => ({ courses: e.courses.map((e) => e.id === t ? i.updateCrewCourse : e) }));
549
+ },
550
+ removeCourse: async (t) => {
551
+ let n = $.getState().initParams;
552
+ await Z(ce, { id: t }, n, "Unable to remove course"), e((e) => ({ courses: e.courses.filter((e) => e.id !== t) }));
553
+ },
554
+ enrollCourse: async (t) => {
555
+ let n = $.getState().initParams, r = await Z(B, { id: t }, n, "Unable to enroll in course");
556
+ e((e) => ({ courses: e.courses.map((e) => e.id === t ? r.enrollCrewCourse : e) }));
557
+ },
558
+ addLearningPath: async (t) => {
559
+ let n = $.getState().initParams, r = await Z(V, { input: t }, n, "Unable to create learning path");
560
+ e((e) => ({ learningPaths: [r.createCrewLearningPath, ...e.learningPaths] }));
561
+ },
562
+ updateLearningPath: async (t, n) => {
563
+ let r = $.getState().initParams, i = await Z(H, {
564
+ id: t,
565
+ input: n
566
+ }, r, "Unable to update learning path");
567
+ e((e) => ({ learningPaths: e.learningPaths.map((e) => e.id === t ? i.updateCrewLearningPath : e) }));
568
+ },
569
+ removeLearningPath: async (t) => {
570
+ let n = $.getState().initParams;
571
+ await Z(U, { id: t }, n, "Unable to remove learning path"), e((e) => ({ learningPaths: e.learningPaths.filter((e) => e.id !== t) }));
572
+ },
573
+ addPayrollRecord: async (t) => {
574
+ let n = $.getState().initParams, r = await Z(W, { input: {
575
+ ...t,
576
+ status: K(t.status)
577
+ } }, n, "Unable to create payroll record");
578
+ e((e) => ({ payrollRecords: [r.createCrewPayrollRecord, ...e.payrollRecords] }));
579
+ },
580
+ updatePayrollRecord: async (t, n) => {
581
+ let r = $.getState().initParams, i = await Z(G, {
582
+ id: t,
583
+ input: {
584
+ ...n,
585
+ ...n.status ? { status: K(n.status) } : {}
586
+ }
587
+ }, r, "Unable to update payroll record");
588
+ e((e) => ({ payrollRecords: e.payrollRecords.map((e) => e.id === t ? i.updateCrewPayrollRecord : e) }));
589
+ },
590
+ removePayrollRecord: async (t) => {
591
+ let n = $.getState().initParams;
592
+ await Z(le, { id: t }, n, "Unable to remove payroll record"), e((e) => ({ payrollRecords: e.payrollRecords.filter((e) => e.id !== t) }));
593
+ },
594
+ addTimeEntry: async (t) => {
595
+ let n = $.getState().initParams, r = await Z(ue, { input: t }, n, "Unable to create time entry");
596
+ e((e) => ({ timeEntries: [r.createCrewTimeEntry, ...e.timeEntries] }));
597
+ },
598
+ updateTimeEntry: async (t, n) => {
599
+ let r = $.getState().initParams, i = await Z(de, {
600
+ id: t,
601
+ input: n
602
+ }, r, "Unable to update time entry");
603
+ e((e) => ({ timeEntries: e.timeEntries.map((e) => e.id === t ? i.updateCrewTimeEntry : e) }));
604
+ },
605
+ removeTimeEntry: async (t) => {
606
+ let n = $.getState().initParams;
607
+ await Z(fe, { id: t }, n, "Unable to remove time entry"), e((e) => ({ timeEntries: e.timeEntries.filter((e) => e.id !== t) }));
321
608
  }
322
609
  }));
323
610
  //#endregion
324
- export { j as useCrewFoundryStore };
611
+ export { $ as useCrewFoundryStore };
325
612
 
326
613
  //# sourceMappingURL=crewfoundryStore.js.map