web: add description form field
This commit is contained in:
parent
b1de5eac81
commit
a93c72e205
@ -11,6 +11,7 @@ import "./(styles)/page.scss"
|
|||||||
interface MapfixPayload {
|
interface MapfixPayload {
|
||||||
AssetID: number;
|
AssetID: number;
|
||||||
TargetAssetID: number;
|
TargetAssetID: number;
|
||||||
|
Description: string;
|
||||||
}
|
}
|
||||||
interface IdResponse {
|
interface IdResponse {
|
||||||
OperationID: number;
|
OperationID: number;
|
||||||
@ -28,6 +29,7 @@ export default function MapfixInfoPage() {
|
|||||||
const payload: MapfixPayload = {
|
const payload: MapfixPayload = {
|
||||||
AssetID: Number((formData.get("asset-id") as string) ?? "0"),
|
AssetID: Number((formData.get("asset-id") as string) ?? "0"),
|
||||||
TargetAssetID: Number(dynamicId.mapId),
|
TargetAssetID: Number(dynamicId.mapId),
|
||||||
|
Description: (formData.get("description") as string) ?? "unknown", // TEMPORARY! TODO: Change
|
||||||
};
|
};
|
||||||
|
|
||||||
console.log(payload)
|
console.log(payload)
|
||||||
@ -70,6 +72,7 @@ export default function MapfixInfoPage() {
|
|||||||
<form onSubmit={handleSubmit}>
|
<form onSubmit={handleSubmit}>
|
||||||
{/* TODO: Add form data for mapfixes, such as changes they did, and any times that need to be deleted & what styles */}
|
{/* TODO: Add form data for mapfixes, such as changes they did, and any times that need to be deleted & what styles */}
|
||||||
<TextField className="form-field" id="asset-id" name="asset-id" label="Asset ID" variant="outlined"/>
|
<TextField className="form-field" id="asset-id" name="asset-id" label="Asset ID" variant="outlined"/>
|
||||||
|
<TextField className="form-field" id="description" name="description" label="Describe the Mapfix" variant="outlined"/>
|
||||||
<span className="spacer form-spacer"></span>
|
<span className="spacer form-spacer"></span>
|
||||||
<Button type="submit" variant="contained" startIcon={<SendIcon/>} sx={{
|
<Button type="submit" variant="contained" startIcon={<SendIcon/>} sx={{
|
||||||
width: "400px",
|
width: "400px",
|
||||||
|
Loading…
x
Reference in New Issue
Block a user