storing changes, starting history list
This commit is contained in:
@@ -1,12 +1,14 @@
|
||||
import { Formik, Field, Form } from "formik";
|
||||
import FormGroup from "../components/FormGroup";
|
||||
import { handleSoftReboot, handleHardReboot } from "./Reboots";
|
||||
import { handleSystemSave } from "./SettingSaveRecall";
|
||||
import { timezones } from "./timezones";
|
||||
import SystemFileUpload from "./SystemFileUpload";
|
||||
import type { SystemValues, SystemValuesErrors } from "../../../types/types";
|
||||
import { useSystemConfig } from "../../../hooks/useSystemConfig";
|
||||
|
||||
const SystemConfigFields = () => {
|
||||
const { saveSystemSettings, getSystemSettingsData } = useSystemConfig();
|
||||
console.log(getSystemSettingsData);
|
||||
const initialvalues: SystemValues = {
|
||||
deviceName: "",
|
||||
timeZone: "",
|
||||
@@ -15,7 +17,7 @@ const SystemConfigFields = () => {
|
||||
softwareUpdate: null,
|
||||
};
|
||||
|
||||
const handleSubmit = (values: SystemValues) => handleSystemSave(values);
|
||||
const handleSubmit = (values: SystemValues) => saveSystemSettings(values);
|
||||
const validateValues = (values: SystemValues) => {
|
||||
const errors: SystemValuesErrors = {};
|
||||
const interval = Number(values.sntpInterval);
|
||||
|
||||
Reference in New Issue
Block a user