@burdenoff/microfe-crewfoundry 2026.723.2 → 2026.731.1

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.
@@ -1,7 +1,7 @@
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 skills terminationDate }\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 hiredDate }\n interviews { id candidateId candidateName position interviewerName date time type status feedback rating }\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 leaveRequests { id employeeId employeeName department type startDate endDate days status reason approverName }\n timeEntries { id employeeId employeeName date clockIn clockOut totalHours overtime project status billable }\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 CrewPayrollRecords {\n crewPayrollRecords { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod }\n }\n", i = "\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 skills terminationDate }\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 hiredDate }\n interviews { id candidateId candidateName position interviewerName date time type status feedback rating }\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 leaveRequests { id employeeId employeeName department type startDate endDate days status reason approverName }\n timeEntries { id employeeId employeeName date clockIn clockOut totalHours overtime project status billable }\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", a = "\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", o = "mutation CreateCrewEmployee($input: CreateCrewEmployeeInput!) { createCrewEmployee(input: $input) { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore skills terminationDate } }", s = "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 skills terminationDate } }", c = "mutation RemoveCrewEmployee($id: ID!) { removeCrewEmployee(id: $id) }", l = "mutation CreateCrewJobPosting($input: CreateCrewJobPostingInput!) { createCrewJobPosting(input: $input) { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits } }", u = "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 } }", d = "mutation CreateCrewCandidate($input: CreateCrewCandidateInput!) { createCrewCandidate(input: $input) { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes hiredDate } }", f = "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 hiredDate } }", p = "mutation CreateCrewAnnouncement($input: CreateCrewAnnouncementInput!) { createCrewAnnouncement(input: $input) { id title content author authorRole category priority isPinned createdAt viewCount tags } }", m = "mutation CreateCrewLeaveRequest($input: CreateCrewLeaveRequestInput!) { createCrewLeaveRequest(input: $input) { id employeeId employeeName department type startDate endDate days status reason approverName } }", h = "mutation UpdateCrewLeaveRequest($id: ID!, $input: UpdateCrewLeaveRequestInput!) { updateCrewLeaveRequest(id: $id, input: $input) { id employeeId employeeName department type startDate endDate days status reason approverName } }", g = "mutation RemoveCrewJobPosting($id: ID!) { removeCrewJobPosting(id: $id) }", _ = "mutation RemoveCrewCandidate($id: ID!) { removeCrewCandidate(id: $id) }", v = "mutation UpdateCrewAnnouncement($id: ID!, $input: UpdateCrewAnnouncementInput!) { updateCrewAnnouncement(id: $id, input: $input) { id title content author authorRole category priority isPinned createdAt viewCount tags } }", y = "mutation RemoveCrewAnnouncement($id: ID!) { removeCrewAnnouncement(id: $id) }", b = "mutation CreateCrewInterview($input: CreateCrewInterviewInput!) { createCrewInterview(input: $input) { id candidateId candidateName position interviewerName date time type status feedback rating } }", x = "mutation UpdateCrewInterview($id: ID!, $input: UpdateCrewInterviewInput!) { updateCrewInterview(id: $id, input: $input) { id candidateId candidateName position interviewerName date time type status feedback rating } }", S = "mutation RemoveCrewInterview($id: ID!) { removeCrewInterview(id: $id) }", C = "mutation CreateCrewVendor($input: CreateCrewVendorInput!) { createCrewVendor(input: $input) { id name category contactPerson email phone status contractValue rating } }", w = "mutation UpdateCrewVendor($id: ID!, $input: UpdateCrewVendorInput!) { updateCrewVendor(id: $id, input: $input) { id name category contactPerson email phone status contractValue rating } }", T = "mutation RemoveCrewVendor($id: ID!) { removeCrewVendor(id: $id) }", E = "mutation CreateCrewClient($input: CreateCrewClientInput!) { createCrewClient(input: $input) { id name industry contactPerson email phone status revenue projects since } }", ee = "mutation UpdateCrewClient($id: ID!, $input: UpdateCrewClientInput!) { updateCrewClient(id: $id, input: $input) { id name industry contactPerson email phone status revenue projects since } }", te = "mutation RemoveCrewClient($id: ID!) { removeCrewClient(id: $id) }", ne = "mutation CreateCrewTeam($input: CreateCrewTeamInput!) { createCrewTeam(input: $input) { id name description leadId leadName members memberCount department status projectCount createdAt } }", re = "mutation UpdateCrewTeam($id: ID!, $input: UpdateCrewTeamInput!) { updateCrewTeam(id: $id, input: $input) { id name description leadId leadName members memberCount department status projectCount createdAt } }", ie = "mutation RemoveCrewTeam($id: ID!) { removeCrewTeam(id: $id) }", ae = "mutation CreateCrewProject($input: CreateCrewProjectInput!) { createCrewProject(input: $input) { id name description status priority startDate endDate progress budget spent teamId teamName managerId managerName tasks completedTasks } }", oe = "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 } }", se = "mutation RemoveCrewProject($id: ID!) { removeCrewProject(id: $id) }", ce = "mutation CreateCrewDepartment($input: CreateCrewDepartmentInput!) { createCrewDepartment(input: $input) { id name headId headName employeeCount budget location status } }", le = "mutation UpdateCrewDepartment($id: ID!, $input: UpdateCrewDepartmentInput!) { updateCrewDepartment(id: $id, input: $input) { id name headId headName employeeCount budget location status } }", ue = "mutation RemoveCrewDepartment($id: ID!) { removeCrewDepartment(id: $id) }", de = "mutation CreateCrewPayrollRecord($input: CreateCrewPayrollRecordInput!) { createCrewPayrollRecord(input: $input) { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod } }", fe = "mutation UpdateCrewPayrollRecord($id: ID!, $input: UpdateCrewPayrollRecordInput!) { updateCrewPayrollRecord(id: $id, input: $input) { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod } }", D = "mutation RemoveCrewPayrollRecord($id: ID!) { removeCrewPayrollRecord(id: $id) }", O = "mutation CreateCrewTimeEntry($input: CreateCrewTimeEntryInput!) { createCrewTimeEntry(input: $input) { id employeeId employeeName date clockIn clockOut totalHours overtime project status billable } }", k = "mutation UpdateCrewTimeEntry($id: ID!, $input: UpdateCrewTimeEntryInput!) { updateCrewTimeEntry(id: $id, input: $input) { id employeeId employeeName date clockIn clockOut totalHours overtime project status billable } }", A = "mutation RemoveCrewTimeEntry($id: ID!) { removeCrewTimeEntry(id: $id) }", j = "query EmployeeDocuments($employeeId: ID!) { employeeDocuments(employeeId: $employeeId) { id employeeId fileId title category uploadedBy uploadedAt } }", M = "mutation AttachEmployeeDocument($input: AttachCrewEmployeeDocumentInput!) { attachEmployeeDocument(input: $input) { id employeeId fileId title category uploadedBy uploadedAt } }", N = "mutation DetachEmployeeDocument($id: ID!) { detachEmployeeDocument(id: $id) }", P = "mutation EnsureFolderByPath($path: String!) { ensureFolderByPath(path: $path) { id } }", F = "mutation InitiateUpload($input: InitiateUploadInput!) { initiateUpload(input: $input) { session { id } uploadUrl } }", I = "mutation CompleteUpload($input: CompleteUploadInput!) { completeUpload(input: $input) { file { id } } }", L = "query CrewOnboardings { crewOnboardings { id candidateId employeeId fullName position department startDate status currentStage createdAt totalTaskCount completedTaskCount progressPercent tasks { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } } }", R = "mutation CreateCrewOnboarding($input: CreateCrewOnboardingInput!) { createCrewOnboarding(input: $input) { id candidateId employeeId fullName position department startDate status currentStage createdAt totalTaskCount completedTaskCount progressPercent tasks { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } } }", z = "mutation UpdateCrewOnboarding($id: ID!, $input: UpdateCrewOnboardingInput!) { updateCrewOnboarding(id: $id, input: $input) { id candidateId employeeId fullName position department startDate status currentStage createdAt totalTaskCount completedTaskCount progressPercent tasks { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } } }", B = "mutation RemoveCrewOnboarding($id: ID!) { removeCrewOnboarding(id: $id) }", V = "mutation CreateCrewOnboardingTask($input: CreateCrewOnboardingTaskInput!) { createCrewOnboardingTask(input: $input) { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } }", pe = "mutation UpdateCrewOnboardingTask($id: ID!, $input: UpdateCrewOnboardingTaskInput!) { updateCrewOnboardingTask(id: $id, input: $input) { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } }", me = "mutation RemoveCrewOnboardingTask($id: ID!) { removeCrewOnboardingTask(id: $id) }", he = "mutation ToggleCrewOnboardingTask($id: ID!, $completed: Boolean!) { toggleCrewOnboardingTask(id: $id, completed: $completed) { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } }", H = (e) => e.toUpperCase().replaceAll("-", "_"), U = (e) => /* @__PURE__ */ Error(`${e} isn't available in CrewFoundry.`), W = {
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 skills terminationDate }\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 hiredDate }\n interviews { id candidateId candidateName position interviewerName date time type status feedback rating }\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 leaveRequests { id employeeId employeeName department type startDate endDate days status reason approverName }\n timeEntries { id employeeId employeeName date clockIn clockOut totalHours overtime project status billable }\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 CrewPayrollRecords {\n crewPayrollRecords { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod }\n }\n", i = "\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 skills terminationDate }\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 hiredDate }\n interviews { id candidateId candidateName position interviewerName date time type status feedback rating }\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 leaveRequests { id employeeId employeeName department type startDate endDate days status reason approverName }\n timeEntries { id employeeId employeeName date clockIn clockOut totalHours overtime project status billable }\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", a = "\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", o = "mutation CreateCrewEmployee($input: CreateCrewEmployeeInput!) { createCrewEmployee(input: $input) { id firstName lastName email department position status type salary startDate avatar location managerId phone performanceScore skills terminationDate } }", s = "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 skills terminationDate } }", c = "mutation RemoveCrewEmployee($id: ID!) { removeCrewEmployee(id: $id) }", l = "mutation CreateCrewJobPosting($input: CreateCrewJobPostingInput!) { createCrewJobPosting(input: $input) { id title department location type experienceLevel salaryMin salaryMax status applicants postedDate deadline description requirements benefits } }", u = "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 } }", d = "mutation CreateCrewCandidate($input: CreateCrewCandidateInput!) { createCrewCandidate(input: $input) { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes hiredDate } }", f = "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 hiredDate } }", p = "mutation CreateCrewAnnouncement($input: CreateCrewAnnouncementInput!) { createCrewAnnouncement(input: $input) { id title content author authorRole category priority isPinned createdAt viewCount tags } }", m = "mutation CreateCrewLeaveRequest($input: CreateCrewLeaveRequestInput!) { createCrewLeaveRequest(input: $input) { id employeeId employeeName department type startDate endDate days status reason approverName } }", h = "mutation UpdateCrewLeaveRequest($id: ID!, $input: UpdateCrewLeaveRequestInput!) { updateCrewLeaveRequest(id: $id, input: $input) { id employeeId employeeName department type startDate endDate days status reason approverName } }", g = "mutation RemoveCrewJobPosting($id: ID!) { removeCrewJobPosting(id: $id) }", _ = "mutation RemoveCrewCandidate($id: ID!) { removeCrewCandidate(id: $id) }", v = "mutation UpdateCrewAnnouncement($id: ID!, $input: UpdateCrewAnnouncementInput!) { updateCrewAnnouncement(id: $id, input: $input) { id title content author authorRole category priority isPinned createdAt viewCount tags } }", y = "mutation RemoveCrewAnnouncement($id: ID!) { removeCrewAnnouncement(id: $id) }", b = "mutation CreateCrewInterview($input: CreateCrewInterviewInput!) { createCrewInterview(input: $input) { id candidateId candidateName position interviewerName date time type status feedback rating } }", x = "mutation UpdateCrewInterview($id: ID!, $input: UpdateCrewInterviewInput!) { updateCrewInterview(id: $id, input: $input) { id candidateId candidateName position interviewerName date time type status feedback rating } }", S = "mutation RemoveCrewInterview($id: ID!) { removeCrewInterview(id: $id) }", C = "mutation CreateCrewVendor($input: CreateCrewVendorInput!) { createCrewVendor(input: $input) { id name category contactPerson email phone status contractValue rating } }", w = "mutation UpdateCrewVendor($id: ID!, $input: UpdateCrewVendorInput!) { updateCrewVendor(id: $id, input: $input) { id name category contactPerson email phone status contractValue rating } }", T = "mutation RemoveCrewVendor($id: ID!) { removeCrewVendor(id: $id) }", E = "mutation CreateCrewClient($input: CreateCrewClientInput!) { createCrewClient(input: $input) { id name industry contactPerson email phone status revenue projects since } }", D = "mutation UpdateCrewClient($id: ID!, $input: UpdateCrewClientInput!) { updateCrewClient(id: $id, input: $input) { id name industry contactPerson email phone status revenue projects since } }", ee = "mutation RemoveCrewClient($id: ID!) { removeCrewClient(id: $id) }", te = "mutation CreateCrewTeam($input: CreateCrewTeamInput!) { createCrewTeam(input: $input) { id name description leadId leadName members memberCount department status projectCount createdAt } }", ne = "mutation UpdateCrewTeam($id: ID!, $input: UpdateCrewTeamInput!) { updateCrewTeam(id: $id, input: $input) { id name description leadId leadName members memberCount department status projectCount createdAt } }", re = "mutation RemoveCrewTeam($id: ID!) { removeCrewTeam(id: $id) }", ie = "mutation CreateCrewProject($input: CreateCrewProjectInput!) { createCrewProject(input: $input) { id name description status priority startDate endDate progress budget spent teamId teamName managerId managerName tasks completedTasks } }", ae = "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 } }", oe = "mutation RemoveCrewProject($id: ID!) { removeCrewProject(id: $id) }", se = "mutation CreateCrewDepartment($input: CreateCrewDepartmentInput!) { createCrewDepartment(input: $input) { id name headId headName employeeCount budget location status } }", ce = "mutation UpdateCrewDepartment($id: ID!, $input: UpdateCrewDepartmentInput!) { updateCrewDepartment(id: $id, input: $input) { id name headId headName employeeCount budget location status } }", le = "mutation RemoveCrewDepartment($id: ID!) { removeCrewDepartment(id: $id) }", ue = "mutation CreateCrewPayrollRecord($input: CreateCrewPayrollRecordInput!) { createCrewPayrollRecord(input: $input) { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod } }", de = "mutation UpdateCrewPayrollRecord($id: ID!, $input: UpdateCrewPayrollRecordInput!) { updateCrewPayrollRecord(id: $id, input: $input) { id employeeId employeeName department period grossPay deductions netPay status payDate paymentMethod } }", fe = "mutation RemoveCrewPayrollRecord($id: ID!) { removeCrewPayrollRecord(id: $id) }", O = "id country currency period payDate status employeeCount totalGrossPay totalNetPay calculatedAt approvedAt approvedBy notes", k = `query CrewPayrollRuns { crewPayrollRuns { ${O} } }`, A = `mutation CreateCrewPayrollRun($input: CreateCrewPayrollRunInput!) { createCrewPayrollRun(input: $input) { ${O} } }`, j = `mutation CalculateCrewPayrollRun($id: ID!) { calculateCrewPayrollRun(id: $id) { ${O} } }`, M = `mutation ApproveCrewPayrollRun($id: ID!) { approveCrewPayrollRun(id: $id) { ${O} } }`, N = "mutation RemoveCrewPayrollRun($id: ID!) { removeCrewPayrollRun(id: $id) }", P = "query CrewPayslips($filter: CrewPayslipFilterInput) { crewPayslips(filter: $filter) { id payrollRunId employeeId employeeName country currency period annualGrossSalary grossPay taxableIncome incomeTax employeeSocialContrib employerSocialContrib otherDeductions netPay incomeTaxBrackets { label rate bandFrom bandTo taxableInBand taxOnBand } employeeContributions { label rate base amount } employerContributions { label rate base amount } otherDeductionLines { label rate base amount } assumptions } }", F = "mutation CreateCrewTimeEntry($input: CreateCrewTimeEntryInput!) { createCrewTimeEntry(input: $input) { id employeeId employeeName date clockIn clockOut totalHours overtime project status billable } }", I = "mutation UpdateCrewTimeEntry($id: ID!, $input: UpdateCrewTimeEntryInput!) { updateCrewTimeEntry(id: $id, input: $input) { id employeeId employeeName date clockIn clockOut totalHours overtime project status billable } }", L = "mutation RemoveCrewTimeEntry($id: ID!) { removeCrewTimeEntry(id: $id) }", R = "query CrewJobPostingMatches($jobPostingId: ID!, $filter: CrewCandidateMatchFilterInput, $limit: Int) { crewJobPostingMatches(jobPostingId: $jobPostingId, filter: $filter, limit: $limit) { candidateId jobPostingId score skillScore experienceScore matchedSkills missingSkills rationale candidate { id firstName lastName email phone position status appliedDate resumeUrl rating source experience skills currentCompany notes hiredDate } } }", z = "query EmployeeDocuments($employeeId: ID!) { employeeDocuments(employeeId: $employeeId) { id employeeId fileId title category uploadedBy uploadedAt } }", B = "mutation AttachEmployeeDocument($input: AttachCrewEmployeeDocumentInput!) { attachEmployeeDocument(input: $input) { id employeeId fileId title category uploadedBy uploadedAt } }", V = "mutation DetachEmployeeDocument($id: ID!) { detachEmployeeDocument(id: $id) }", pe = "mutation EnsureFolderByPath($path: String!) { ensureFolderByPath(path: $path) { id } }", me = "mutation InitiateUpload($input: InitiateUploadInput!) { initiateUpload(input: $input) { session { id } uploadUrl } }", he = "mutation CompleteUpload($input: CompleteUploadInput!) { completeUpload(input: $input) { file { id } } }", ge = "query CrewOnboardings { crewOnboardings { id candidateId employeeId fullName position department startDate status currentStage createdAt totalTaskCount completedTaskCount progressPercent tasks { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } } }", _e = "mutation CreateCrewOnboarding($input: CreateCrewOnboardingInput!) { createCrewOnboarding(input: $input) { id candidateId employeeId fullName position department startDate status currentStage createdAt totalTaskCount completedTaskCount progressPercent tasks { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } } }", ve = "mutation UpdateCrewOnboarding($id: ID!, $input: UpdateCrewOnboardingInput!) { updateCrewOnboarding(id: $id, input: $input) { id candidateId employeeId fullName position department startDate status currentStage createdAt totalTaskCount completedTaskCount progressPercent tasks { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } } }", ye = "mutation RemoveCrewOnboarding($id: ID!) { removeCrewOnboarding(id: $id) }", be = "mutation CreateCrewOnboardingTask($input: CreateCrewOnboardingTaskInput!) { createCrewOnboardingTask(input: $input) { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } }", xe = "mutation UpdateCrewOnboardingTask($id: ID!, $input: UpdateCrewOnboardingTaskInput!) { updateCrewOnboardingTask(id: $id, input: $input) { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } }", Se = "mutation RemoveCrewOnboardingTask($id: ID!) { removeCrewOnboardingTask(id: $id) }", Ce = "mutation ToggleCrewOnboardingTask($id: ID!, $completed: Boolean!) { toggleCrewOnboardingTask(id: $id, completed: $completed) { id onboardingId stage title assigneeActorId assigneeName dueDate completedAt sortOrder } }", H = (e) => e.toUpperCase().replaceAll("-", "_"), U = (e) => /* @__PURE__ */ Error(`${e} isn't available in CrewFoundry.`), W = {
5
5
  employee: ["status", "type"],
6
6
  department: ["status"],
7
7
  jobPosting: [
@@ -37,19 +37,19 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
37
37
  }, K = (e) => ({
38
38
  ...G(e, W.onboarding),
39
39
  tasks: (e.tasks ?? []).map((e) => G(e, W.onboardingTask))
40
- }), q = (e) => e ? e.slice(0, 10) : "TBD", ge = (e) => !e || typeof e != "object" || Array.isArray(e) ? null : e, J = (e) => typeof e == "number" ? e : null, Y = (e) => typeof e == "string" ? e : null, _e = (e) => {
40
+ }), q = (e) => e ? e.slice(0, 10) : "TBD", we = (e) => !e || typeof e != "object" || Array.isArray(e) ? null : e, J = (e) => typeof e == "number" ? e : null, Y = (e) => typeof e == "string" ? e : null, Te = (e) => {
41
41
  let t = e.toLowerCase();
42
42
  return t === "active" ? "active" : t === "completed" ? "completed" : t === "cancelled" ? "cancelled" : t === "archived" ? "on_hold" : "planning";
43
- }, ve = (e) => {
43
+ }, Ee = (e) => {
44
44
  let t = e.toLowerCase();
45
45
  return t === "active" ? "active" : t === "inactive" || t === "archived" || t === "deleted" ? "disbanded" : "forming";
46
- }, ye = (e, t) => e.map((e, n) => {
47
- let r = ge(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)];
46
+ }, De = (e, t) => e.map((e, n) => {
47
+ let r = we(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)];
48
48
  return {
49
49
  id: e.id,
50
50
  name: e.name,
51
51
  description: Y(r?.description) || `${e.key} delivery plan`,
52
- status: _e(e.status),
52
+ status: Te(e.status),
53
53
  priority: Y(r?.priority)?.toLowerCase() || "medium",
54
54
  startDate: q(e.createdAt),
55
55
  endDate: q(e.updatedAt),
@@ -63,7 +63,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
63
63
  tasks: s,
64
64
  completedTasks: c
65
65
  };
66
- }), be = (e) => e.map(({ node: e }) => ({
66
+ }), Oe = (e) => e.map(({ node: e }) => ({
67
67
  id: e.id,
68
68
  name: e.name,
69
69
  description: e.description || `${e.name} team workspace`,
@@ -72,10 +72,10 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
72
72
  members: [],
73
73
  memberCount: e.memberCount,
74
74
  department: e.groupType?.toLowerCase().replaceAll("_", " ") || "operations",
75
- status: ve(e.status),
75
+ status: Ee(e.status),
76
76
  projectCount: 0,
77
77
  createdAt: q(e.createdAt)
78
- })), xe = (e) => e.filter(({ node: e }) => e.unreadCount > 0).map(({ node: e }) => ({
78
+ })), ke = (e) => e.filter(({ node: e }) => e.unreadCount > 0).map(({ node: e }) => ({
79
79
  id: `conversation-${e.id}`,
80
80
  title: e.title || "Conversation update",
81
81
  message: `${e.unreadCount} unread in ${e.memberCount}-member channel`,
@@ -84,7 +84,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
84
84
  read: !1,
85
85
  createdAt: e.updatedAt,
86
86
  actionUrl: "/crewfoundry/communications/messages-page"
87
- })), Se = (e) => {
87
+ })), Ae = (e) => {
88
88
  let t = e.getBillingAccountsByOrg.find((e) => e?.isDefault && e?.id) || e.getBillingAccountsByOrg.find((e) => e?.id);
89
89
  return t?.id ? (t.paymentMethods || []).filter((e) => !!e).map((e) => {
90
90
  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";
@@ -98,11 +98,11 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
98
98
  expiry: n && r ? `${n}/${r}` : void 0
99
99
  };
100
100
  }) : [];
101
- }, Ce = (e, t) => {
101
+ }, X = (e, t) => {
102
102
  if (e.errors?.length) throw Error(e.errors[0]?.message || t);
103
103
  if (!e.data) throw Error(t);
104
104
  return e.data;
105
- }, X = new Set([
105
+ }, je = new Set([
106
106
  "id",
107
107
  "createdAt",
108
108
  "createdOn",
@@ -124,28 +124,28 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
124
124
  "viewCount",
125
125
  "revenue",
126
126
  "projects"
127
- ]), we = (e) => {
127
+ ]), Me = (e) => {
128
128
  if (!e) return e;
129
129
  let t = e.input;
130
130
  if (!t || typeof t != "object" || Array.isArray(t)) return e;
131
131
  let n = {};
132
- for (let [e, r] of Object.entries(t)) X.has(e) || (n[e] = r);
132
+ for (let [e, r] of Object.entries(t)) je.has(e) || (n[e] = r);
133
133
  return {
134
134
  ...e,
135
135
  input: n
136
136
  };
137
- }, Z = async (e, n, r, i, a = "workspace") => Ce(await t({
137
+ }, Z = async (e, n, r, i, a = "workspace") => X(await t({
138
138
  gateway: a,
139
139
  query: e,
140
- variables: we(n),
140
+ variables: Me(n),
141
141
  authToken: r.authToken,
142
142
  baseUrl: a === "workspace" ? r.apiGatewayUrl : void 0,
143
143
  extraHeaders: { ...a === "workspace" && r.workspaceId ? { "x-workspace-id": r.workspaceId } : {} }
144
- }), i), Te = () => !1, Q = async (e, t, n, r, i = "workspace") => {
144
+ }), i), Ne = () => !1, Q = async (e, t, n, r, i = "workspace") => {
145
145
  try {
146
146
  return await Z(e, t, n, r, i);
147
147
  } catch (e) {
148
- return Te() && console.warn(`[crewfoundry] overlap query skipped: ${r}`, e), null;
148
+ return Ne() && console.warn(`[crewfoundry] overlap query skipped: ${r}`, e), null;
149
149
  }
150
150
  }, $ = e((e) => ({
151
151
  metrics: [
@@ -227,6 +227,13 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
227
227
  employeeDocuments: [],
228
228
  onboardings: [],
229
229
  onboardingsLoaded: !1,
230
+ jobPostingMatches: {},
231
+ jobPostingMatchesLoading: !1,
232
+ payrollRuns: [],
233
+ payrollRunsLoaded: !1,
234
+ payrollRunsLoading: !1,
235
+ payslipsByRun: {},
236
+ payslipsLoading: !1,
230
237
  initializeData: async (t) => {
231
238
  if (t.workspaceId) {
232
239
  e({
@@ -247,7 +254,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
247
254
  }, t, "Unable to load workspace bootstrap with overlap data"),
248
255
  Q(a, void 0, t, "Unable to load overlap billing data", "global"),
249
256
  Q(r, void 0, t, "Unable to load payroll records")
250
- ]), l = o ? o.crewfoundryBootstrap : (await Z(n, void 0, t, "Unable to load CrewFoundry data")).crewfoundryBootstrap, u = o ? be(o.groups.edges) : [], d = o ? ye(o.projects.items, u) : [], f = o ? xe(o.conversations.edges) : [], p = u.length > 0 ? u : l.teams, m = d.length > 0 ? d : l.projects, h = f, g = s ? Se(s) : [], _ = l.employees.map((e) => G(e, W.employee)), v = l.departments.map((e) => G(e, W.department)), y = l.jobPostings.map((e) => G(e, W.jobPosting)), b = l.candidates.map((e) => G(e, W.candidate)), x = l.interviews.map((e) => G(e, W.interview)), S = [], C = [], w = l.announcements.map((e) => G(e, W.announcement)), T = p.map((e) => G(e, W.team)), E = m.map((e) => G(e, W.project));
257
+ ]), l = o ? o.crewfoundryBootstrap : (await Z(n, void 0, t, "Unable to load CrewFoundry data")).crewfoundryBootstrap, u = o ? Oe(o.groups.edges) : [], d = o ? De(o.projects.items, u) : [], f = o ? ke(o.conversations.edges) : [], p = u.length > 0 ? u : l.teams, m = d.length > 0 ? d : l.projects, h = f, g = s ? Ae(s) : [], _ = l.employees.map((e) => G(e, W.employee)), v = l.departments.map((e) => G(e, W.department)), y = l.jobPostings.map((e) => G(e, W.jobPosting)), b = l.candidates.map((e) => G(e, W.candidate)), x = l.interviews.map((e) => G(e, W.interview)), S = [], C = [], w = l.announcements.map((e) => G(e, W.announcement)), T = p.map((e) => G(e, W.team)), E = m.map((e) => G(e, W.project));
251
258
  e({
252
259
  employees: _,
253
260
  departments: v,
@@ -475,7 +482,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
475
482
  e((e) => ({ clients: [G(r.createCrewClient, W.client), ...e.clients] }));
476
483
  },
477
484
  updateClient: async (t, n) => {
478
- let r = $.getState().initParams, i = await Z(ee, {
485
+ let r = $.getState().initParams, i = await Z(D, {
479
486
  id: t,
480
487
  input: {
481
488
  ...n,
@@ -486,14 +493,14 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
486
493
  },
487
494
  removeClient: async (t) => {
488
495
  let n = $.getState().initParams;
489
- await Z(te, { id: t }, n, "Unable to remove client"), e((e) => ({ clients: e.clients.filter((e) => e.id !== t) }));
496
+ await Z(ee, { id: t }, n, "Unable to remove client"), e((e) => ({ clients: e.clients.filter((e) => e.id !== t) }));
490
497
  },
491
498
  addTeam: async (t) => {
492
- let n = $.getState().initParams, r = await Z(ne, { input: t }, n, "Unable to create team");
499
+ let n = $.getState().initParams, r = await Z(te, { input: t }, n, "Unable to create team");
493
500
  e((e) => ({ teams: [G(r.createCrewTeam, W.team), ...e.teams] }));
494
501
  },
495
502
  updateTeam: async (t, n) => {
496
- let r = $.getState().initParams, i = await Z(re, {
503
+ let r = $.getState().initParams, i = await Z(ne, {
497
504
  id: t,
498
505
  input: n
499
506
  }, r, "Unable to update team");
@@ -501,10 +508,10 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
501
508
  },
502
509
  removeTeam: async (t) => {
503
510
  let n = $.getState().initParams;
504
- await Z(ie, { id: t }, n, "Unable to remove team"), e((e) => ({ teams: e.teams.filter((e) => e.id !== t) }));
511
+ await Z(re, { id: t }, n, "Unable to remove team"), e((e) => ({ teams: e.teams.filter((e) => e.id !== t) }));
505
512
  },
506
513
  addProject: async (t) => {
507
- let n = $.getState().initParams, r = await Z(ae, { input: {
514
+ let n = $.getState().initParams, r = await Z(ie, { input: {
508
515
  ...t,
509
516
  status: H(t.status),
510
517
  priority: H(t.priority)
@@ -512,7 +519,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
512
519
  e((e) => ({ projects: [G(r.createCrewProject, W.project), ...e.projects] }));
513
520
  },
514
521
  updateProject: async (t, n) => {
515
- let r = $.getState().initParams, i = await Z(oe, {
522
+ let r = $.getState().initParams, i = await Z(ae, {
516
523
  id: t,
517
524
  input: {
518
525
  ...n,
@@ -524,7 +531,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
524
531
  },
525
532
  removeProject: async (t) => {
526
533
  let n = $.getState().initParams;
527
- await Z(se, { id: t }, n, "Unable to remove project"), e((e) => ({ projects: e.projects.filter((e) => e.id !== t) }));
534
+ await Z(oe, { id: t }, n, "Unable to remove project"), e((e) => ({ projects: e.projects.filter((e) => e.id !== t) }));
528
535
  },
529
536
  addMarketplaceService: async () => {
530
537
  throw U("Marketplace services");
@@ -536,11 +543,11 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
536
543
  throw U("Marketplace services");
537
544
  },
538
545
  addDepartment: async (t) => {
539
- let n = $.getState().initParams, r = await Z(ce, { input: t }, n, "Unable to create department");
546
+ let n = $.getState().initParams, r = await Z(se, { input: t }, n, "Unable to create department");
540
547
  e((e) => ({ departments: [G(r.createCrewDepartment, W.department), ...e.departments] }));
541
548
  },
542
549
  updateDepartment: async (t, n) => {
543
- let r = $.getState().initParams, i = await Z(le, {
550
+ let r = $.getState().initParams, i = await Z(ce, {
544
551
  id: t,
545
552
  input: n
546
553
  }, r, "Unable to update department");
@@ -548,7 +555,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
548
555
  },
549
556
  removeDepartment: async (t) => {
550
557
  let n = $.getState().initParams;
551
- await Z(ue, { id: t }, n, "Unable to remove department"), e((e) => ({ departments: e.departments.filter((e) => e.id !== t) }));
558
+ await Z(le, { id: t }, n, "Unable to remove department"), e((e) => ({ departments: e.departments.filter((e) => e.id !== t) }));
552
559
  },
553
560
  addCourse: async () => {
554
561
  throw U("Courses");
@@ -572,14 +579,14 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
572
579
  throw U("Learning paths");
573
580
  },
574
581
  addPayrollRecord: async (t) => {
575
- let n = $.getState().initParams, r = await Z(de, { input: {
582
+ let n = $.getState().initParams, r = await Z(ue, { input: {
576
583
  ...t,
577
584
  status: H(t.status)
578
585
  } }, n, "Unable to create payroll record");
579
586
  e((e) => ({ payrollRecords: [G(r.createCrewPayrollRecord, W.payrollRecord), ...e.payrollRecords] }));
580
587
  },
581
588
  updatePayrollRecord: async (t, n) => {
582
- let r = $.getState().initParams, i = await Z(fe, {
589
+ let r = $.getState().initParams, i = await Z(de, {
583
590
  id: t,
584
591
  input: {
585
592
  ...n,
@@ -590,14 +597,14 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
590
597
  },
591
598
  removePayrollRecord: async (t) => {
592
599
  let n = $.getState().initParams;
593
- await Z(D, { id: t }, n, "Unable to remove payroll record"), e((e) => ({ payrollRecords: e.payrollRecords.filter((e) => e.id !== t) }));
600
+ await Z(fe, { id: t }, n, "Unable to remove payroll record"), e((e) => ({ payrollRecords: e.payrollRecords.filter((e) => e.id !== t) }));
594
601
  },
595
602
  addTimeEntry: async (t) => {
596
- let n = $.getState().initParams, r = await Z(O, { input: t }, n, "Unable to create time entry");
603
+ let n = $.getState().initParams, r = await Z(F, { input: t }, n, "Unable to create time entry");
597
604
  e((e) => ({ timeEntries: [G(r.createCrewTimeEntry, W.timeEntry), ...e.timeEntries] }));
598
605
  },
599
606
  updateTimeEntry: async (t, n) => {
600
- let r = $.getState().initParams, i = await Z(k, {
607
+ let r = $.getState().initParams, i = await Z(I, {
601
608
  id: t,
602
609
  input: n
603
610
  }, r, "Unable to update time entry");
@@ -605,14 +612,84 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
605
612
  },
606
613
  removeTimeEntry: async (t) => {
607
614
  let n = $.getState().initParams;
608
- await Z(A, { id: t }, n, "Unable to remove time entry"), e((e) => ({ timeEntries: e.timeEntries.filter((e) => e.id !== t) }));
615
+ await Z(L, { id: t }, n, "Unable to remove time entry"), e((e) => ({ timeEntries: e.timeEntries.filter((e) => e.id !== t) }));
616
+ },
617
+ fetchJobPostingMatches: async (t) => {
618
+ let n = $.getState().initParams;
619
+ e({ jobPostingMatchesLoading: !0 });
620
+ try {
621
+ let r = (await Z(R, { jobPostingId: t }, n, "Unable to load candidate matches")).crewJobPostingMatches.map((e) => ({
622
+ ...e,
623
+ candidate: G(e.candidate, W.candidate)
624
+ }));
625
+ e((e) => ({
626
+ jobPostingMatches: {
627
+ ...e.jobPostingMatches,
628
+ [t]: r
629
+ },
630
+ jobPostingMatchesLoading: !1
631
+ }));
632
+ } catch (t) {
633
+ throw e({ jobPostingMatchesLoading: !1 }), t;
634
+ }
635
+ },
636
+ fetchPayrollRuns: async () => {
637
+ let t = $.getState().initParams;
638
+ e({ payrollRunsLoading: !0 });
639
+ try {
640
+ e({
641
+ payrollRuns: (await Z(k, void 0, t, "Unable to load payroll runs")).crewPayrollRuns,
642
+ payrollRunsLoaded: !0,
643
+ payrollRunsLoading: !1
644
+ });
645
+ } catch (t) {
646
+ throw e({ payrollRunsLoading: !1 }), t;
647
+ }
648
+ },
649
+ createPayrollRun: async (t) => {
650
+ let n = $.getState().initParams, r = await Z(A, { input: t }, n, "Unable to create payroll run");
651
+ e((e) => ({ payrollRuns: [r.createCrewPayrollRun, ...e.payrollRuns] }));
652
+ },
653
+ calculatePayrollRun: async (t) => {
654
+ let n = $.getState().initParams, r = await Z(j, { id: t }, n, "Unable to calculate payroll run");
655
+ e((e) => ({
656
+ payrollRuns: e.payrollRuns.map((e) => e.id === t ? r.calculateCrewPayrollRun : e),
657
+ payslipsByRun: Object.fromEntries(Object.entries(e.payslipsByRun).filter(([e]) => e !== t))
658
+ }));
659
+ },
660
+ approvePayrollRun: async (t) => {
661
+ let n = $.getState().initParams, r = await Z(M, { id: t }, n, "Unable to approve payroll run");
662
+ e((e) => ({ payrollRuns: e.payrollRuns.map((e) => e.id === t ? r.approveCrewPayrollRun : e) }));
663
+ },
664
+ removePayrollRun: async (t) => {
665
+ let n = $.getState().initParams;
666
+ await Z(N, { id: t }, n, "Unable to remove payroll run"), e((e) => ({
667
+ payrollRuns: e.payrollRuns.filter((e) => e.id !== t),
668
+ payslipsByRun: Object.fromEntries(Object.entries(e.payslipsByRun).filter(([e]) => e !== t))
669
+ }));
670
+ },
671
+ fetchPayslipsForRun: async (t) => {
672
+ let n = $.getState().initParams;
673
+ e({ payslipsLoading: !0 });
674
+ try {
675
+ let r = await Z(P, { filter: { payrollRunId: t } }, n, "Unable to load payslips");
676
+ e((e) => ({
677
+ payslipsByRun: {
678
+ ...e.payslipsByRun,
679
+ [t]: r.crewPayslips
680
+ },
681
+ payslipsLoading: !1
682
+ }));
683
+ } catch (t) {
684
+ throw e({ payslipsLoading: !1 }), t;
685
+ }
609
686
  },
610
687
  fetchEmployeeDocuments: async (t) => {
611
- let n = $.getState().initParams, r = await Z(j, { employeeId: t }, n, "Unable to load employee documents");
688
+ let n = $.getState().initParams, r = await Z(z, { employeeId: t }, n, "Unable to load employee documents");
612
689
  e((e) => ({ employeeDocuments: [...e.employeeDocuments.filter((e) => e.employeeId !== t), ...r.employeeDocuments] }));
613
690
  },
614
691
  uploadEmployeeDocument: async ({ employeeId: t, file: n, title: r, category: i }) => {
615
- let a = $.getState().initParams, o = await Z(P, { path: "/CrewFoundry/Employee Documents" }, a, "Unable to resolve the employee documents folder"), s = n.name.includes(".") ? n.name.substring(n.name.lastIndexOf(".") + 1) : "", c = await Z(F, { input: {
692
+ let a = $.getState().initParams, o = await Z(pe, { path: "/CrewFoundry/Employee Documents" }, a, "Unable to resolve the employee documents folder"), s = n.name.includes(".") ? n.name.substring(n.name.lastIndexOf(".") + 1) : "", c = await Z(me, { input: {
616
693
  fileName: n.name,
617
694
  fileSize: String(n.size),
618
695
  mimeType: n.type || "application/octet-stream",
@@ -627,9 +704,9 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
627
704
  });
628
705
  if (!e.ok) throw Error(`Failed to upload file bytes (status ${e.status})`);
629
706
  }
630
- let l = await Z(M, { input: {
707
+ let l = await Z(B, { input: {
631
708
  employeeId: t,
632
- fileId: (await Z(I, { input: {
709
+ fileId: (await Z(he, { input: {
633
710
  sessionId: c.initiateUpload.session.id,
634
711
  fileSize: String(n.size),
635
712
  folderId: o.ensureFolderByPath.id
@@ -641,21 +718,21 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
641
718
  },
642
719
  detachEmployeeDocument: async (t) => {
643
720
  let n = $.getState().initParams;
644
- await Z(N, { id: t }, n, "Unable to remove this document"), e((e) => ({ employeeDocuments: e.employeeDocuments.filter((e) => e.id !== t) }));
721
+ await Z(V, { id: t }, n, "Unable to remove this document"), e((e) => ({ employeeDocuments: e.employeeDocuments.filter((e) => e.id !== t) }));
645
722
  },
646
723
  fetchOnboardings: async () => {
647
724
  let t = $.getState().initParams;
648
725
  e({
649
- onboardings: (await Z(L, {}, t, "Unable to load onboarding")).crewOnboardings.map(K),
726
+ onboardings: (await Z(ge, {}, t, "Unable to load onboarding")).crewOnboardings.map(K),
650
727
  onboardingsLoaded: !0
651
728
  });
652
729
  },
653
730
  createOnboarding: async (t) => {
654
- let n = $.getState().initParams, r = await Z(R, { input: t }, n, "Unable to start onboarding");
731
+ let n = $.getState().initParams, r = await Z(_e, { input: t }, n, "Unable to start onboarding");
655
732
  e((e) => ({ onboardings: [K(r.createCrewOnboarding), ...e.onboardings] }));
656
733
  },
657
734
  updateOnboarding: async (t, n) => {
658
- let r = $.getState().initParams, i = await Z(z, {
735
+ let r = $.getState().initParams, i = await Z(ve, {
659
736
  id: t,
660
737
  input: n
661
738
  }, r, "Unable to update onboarding");
@@ -663,10 +740,10 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
663
740
  },
664
741
  removeOnboarding: async (t) => {
665
742
  let n = $.getState().initParams;
666
- await Z(B, { id: t }, n, "Unable to remove onboarding"), e((e) => ({ onboardings: e.onboardings.filter((e) => e.id !== t) }));
743
+ await Z(ye, { id: t }, n, "Unable to remove onboarding"), e((e) => ({ onboardings: e.onboardings.filter((e) => e.id !== t) }));
667
744
  },
668
745
  createOnboardingTask: async (t) => {
669
- let n = $.getState().initParams, r = G((await Z(V, { input: t }, n, "Unable to create onboarding task")).createCrewOnboardingTask, W.onboardingTask);
746
+ let n = $.getState().initParams, r = G((await Z(be, { input: t }, n, "Unable to create onboarding task")).createCrewOnboardingTask, W.onboardingTask);
670
747
  e((e) => ({ onboardings: e.onboardings.map((e) => e.id === r.onboardingId ? {
671
748
  ...e,
672
749
  tasks: [...e.tasks, r],
@@ -674,7 +751,7 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
674
751
  } : e) }));
675
752
  },
676
753
  updateOnboardingTask: async (t, n) => {
677
- let r = $.getState().initParams, i = G((await Z(pe, {
754
+ let r = $.getState().initParams, i = G((await Z(xe, {
678
755
  id: t,
679
756
  input: n
680
757
  }, r, "Unable to update onboarding task")).updateCrewOnboardingTask, W.onboardingTask);
@@ -685,14 +762,14 @@ var n = "\n query CrewfoundryBootstrap {\n crewfoundryBootstrap {\n emp
685
762
  },
686
763
  removeOnboardingTask: async (t) => {
687
764
  let n = $.getState().initParams;
688
- await Z(me, { id: t }, n, "Unable to remove onboarding task"), e((e) => ({ onboardings: e.onboardings.map((e) => e.tasks.some((e) => e.id === t) ? {
765
+ await Z(Se, { id: t }, n, "Unable to remove onboarding task"), e((e) => ({ onboardings: e.onboardings.map((e) => e.tasks.some((e) => e.id === t) ? {
689
766
  ...e,
690
767
  tasks: e.tasks.filter((e) => e.id !== t),
691
768
  totalTaskCount: Math.max(0, e.totalTaskCount - 1)
692
769
  } : e) }));
693
770
  },
694
771
  toggleOnboardingTask: async (t, n) => {
695
- let r = $.getState().initParams, i = G((await Z(he, {
772
+ let r = $.getState().initParams, i = G((await Z(Ce, {
696
773
  id: t,
697
774
  completed: n
698
775
  }, r, "Unable to update onboarding task")).toggleCrewOnboardingTask, W.onboardingTask);