| @@ -63,6 +63,7 @@ export interface CreateProjectInputs { | |||||
| // Miscellaneous | // Miscellaneous | ||||
| expectedProjectFee: number; | expectedProjectFee: number; | ||||
| subContractFee?: number; | |||||
| } | } | ||||
| export interface ManhourAllocation { | export interface ManhourAllocation { | ||||
| @@ -36,6 +36,7 @@ export interface MainProject { | |||||
| clientContactId: number; | clientContactId: number; | ||||
| clientSubsidiaryId: number; | clientSubsidiaryId: number; | ||||
| expectedProjectFee: number; | expectedProjectFee: number; | ||||
| subContractFee: number; | |||||
| } | } | ||||
| export interface ProjectCategory { | export interface ProjectCategory { | ||||
| @@ -280,6 +280,7 @@ const CreateProject: React.FC<Props> = ({ | |||||
| projectName: mainProjects !== undefined ? mainProjects[0].projectName : undefined, | projectName: mainProjects !== undefined ? mainProjects[0].projectName : undefined, | ||||
| projectDescription: mainProjects !== undefined ? mainProjects[0].projectDescription : undefined, | projectDescription: mainProjects !== undefined ? mainProjects[0].projectDescription : undefined, | ||||
| expectedProjectFee: mainProjects !== undefined ? mainProjects[0].expectedProjectFee : undefined, | expectedProjectFee: mainProjects !== undefined ? mainProjects[0].expectedProjectFee : undefined, | ||||
| subContractFee: mainProjects !== undefined ? mainProjects[0].subContractFee : undefined, | |||||
| clientId: allCustomers !== undefined ? allCustomers[0].id : undefined, | clientId: allCustomers !== undefined ? allCustomers[0].id : undefined, | ||||
| ...defaultInputs, | ...defaultInputs, | ||||
| @@ -330,6 +330,16 @@ const ProjectClientDetails: React.FC<Props> = ({ | |||||
| /> | /> | ||||
| </Grid> | </Grid> | ||||
| <Grid item xs={6}> | |||||
| <TextField | |||||
| label={t("Sub-Contract Fee")} | |||||
| fullWidth | |||||
| type="number" | |||||
| inputProps={{ step: "0.01" }} | |||||
| {...register("subContractFee", { valueAsNumber: true })} | |||||
| /> | |||||
| </Grid> | |||||
| <Grid item xs={6}> | <Grid item xs={6}> | ||||
| <Checkbox | <Checkbox | ||||
| {...register("isClpProject")} | {...register("isClpProject")} | ||||
| @@ -137,7 +137,7 @@ const TaskSetup: React.FC<Props> = ({ | |||||
| disableClearable | disableClearable | ||||
| // disablePortal | // disablePortal | ||||
| noOptionsText={t("No Task List Source")} | noOptionsText={t("No Task List Source")} | ||||
| value={taskTemplates.find(taskTemplate => taskTemplate.id === selectedTaskTemplateId)} | |||||
| value={taskTemplates.find(taskTemplate => taskTemplate.id === selectedTaskTemplateId) ?? {id: "All", name: t("All tasks")}} | |||||
| options={[{id: "All", name: t("All tasks")}, ...taskTemplates.map(taskTemplate => ({id: taskTemplate.id, name: taskTemplate.name}))]} | options={[{id: "All", name: t("All tasks")}, ...taskTemplates.map(taskTemplate => ({id: taskTemplate.id, name: taskTemplate.name}))]} | ||||
| getOptionLabel={(taskTemplate) => taskTemplate.name} | getOptionLabel={(taskTemplate) => taskTemplate.name} | ||||
| isOptionEqualToValue={(option, value) => option?.id === value?.id} | isOptionEqualToValue={(option, value) => option?.id === value?.id} | ||||