chore: lint
This commit is contained in:
@@ -20,9 +20,9 @@ interface RobotMeta {
|
|||||||
|
|
||||||
interface RobotWorkflow {
|
interface RobotWorkflow {
|
||||||
workflow: WhereWhatPair[];
|
workflow: WhereWhatPair[];
|
||||||
}
|
}
|
||||||
|
|
||||||
interface ScheduleConfig {
|
interface ScheduleConfig {
|
||||||
runEvery: number;
|
runEvery: number;
|
||||||
runEveryUnit: 'MINUTES' | 'HOURS' | 'DAYS' | 'WEEKS' | 'MONTHS';
|
runEveryUnit: 'MINUTES' | 'HOURS' | 'DAYS' | 'WEEKS' | 'MONTHS';
|
||||||
startFrom: 'SUNDAY' | 'MONDAY' | 'TUESDAY' | 'WEDNESDAY' | 'THURSDAY' | 'FRIDAY' | 'SATURDAY';
|
startFrom: 'SUNDAY' | 'MONDAY' | 'TUESDAY' | 'WEDNESDAY' | 'THURSDAY' | 'FRIDAY' | 'SATURDAY';
|
||||||
@@ -32,26 +32,26 @@ interface RobotWorkflow {
|
|||||||
lastRunAt?: Date;
|
lastRunAt?: Date;
|
||||||
nextRunAt?: Date;
|
nextRunAt?: Date;
|
||||||
cronExpression?: string;
|
cronExpression?: string;
|
||||||
}
|
}
|
||||||
|
|
||||||
interface RobotSettings {
|
interface RobotSettings {
|
||||||
id: string;
|
id: string;
|
||||||
userId?: number;
|
userId?: number;
|
||||||
recording_meta: RobotMeta;
|
recording_meta: RobotMeta;
|
||||||
recording: RobotWorkflow;
|
recording: RobotWorkflow;
|
||||||
google_sheet_email?: string | null;
|
google_sheet_email?: string | null;
|
||||||
google_sheet_name?: string | null;
|
google_sheet_name?: string | null;
|
||||||
google_sheet_id?: string | null;
|
google_sheet_id?: string | null;
|
||||||
google_access_token?: string | null;
|
google_access_token?: string | null;
|
||||||
google_refresh_token?: string | null;
|
google_refresh_token?: string | null;
|
||||||
schedule?: ScheduleConfig | null;
|
schedule?: ScheduleConfig | null;
|
||||||
}
|
}
|
||||||
|
|
||||||
interface RobotSettingsProps {
|
interface RobotSettingsProps {
|
||||||
isOpen: boolean;
|
isOpen: boolean;
|
||||||
handleStart: (settings: RobotSettings) => void;
|
handleStart: (settings: RobotSettings) => void;
|
||||||
handleClose: () => void;
|
handleClose: () => void;
|
||||||
initialSettings?: RobotSettings | null;
|
initialSettings?: RobotSettings | null;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -77,29 +77,29 @@ export const RobotSettingsModal = ({ isOpen, handleStart, handleClose, initialSe
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<GenericModal
|
<GenericModal
|
||||||
isOpen={isOpen}
|
isOpen={isOpen}
|
||||||
onClose={handleClose}
|
onClose={handleClose}
|
||||||
modalStyle={modalStyle}
|
modalStyle={modalStyle}
|
||||||
>
|
>
|
||||||
<>
|
<>
|
||||||
<Typography variant="h5" style={{ marginBottom: '20px' }}>Robot Settings</Typography>
|
<Typography variant="h5" style={{ marginBottom: '20px' }}>Robot Settings</Typography>
|
||||||
<Box style={{ display: 'flex', flexDirection: 'column' }}>
|
<Box style={{ display: 'flex', flexDirection: 'column' }}>
|
||||||
{
|
{
|
||||||
robot && (
|
robot && (
|
||||||
<>
|
<>
|
||||||
<TextField
|
<TextField
|
||||||
label="Robot URL"
|
label="Robot URL"
|
||||||
value={robot.recording.workflow[0].where.url}
|
value={robot.recording.workflow[0].where.url}
|
||||||
disabled
|
disabled
|
||||||
style={{ marginBottom: '20px' }}
|
style={{ marginBottom: '20px' }}
|
||||||
/>
|
/>
|
||||||
</>
|
</>
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
</Box>
|
</Box>
|
||||||
</>
|
</>
|
||||||
</GenericModal>
|
</GenericModal>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
|
|||||||
Reference in New Issue
Block a user