Further UI Updates
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
import { Button, Form, Input } from "antd";
|
||||
import { Form, Input } from "antd";
|
||||
import React from "react";
|
||||
import { useTranslation } from "react-i18next";
|
||||
import FormDatePicker from "../form-date-picker/form-date-picker.component";
|
||||
@@ -10,20 +10,7 @@ export default function VehicleDetailFormComponent({ form, loading }) {
|
||||
|
||||
return (
|
||||
<div>
|
||||
<div className="imex-flex-row imex-flex-row__flex-space-around">
|
||||
<Button
|
||||
className="imex-flex-row__margin-large"
|
||||
type="primary"
|
||||
key="submit"
|
||||
htmlType="submit"
|
||||
loading={loading}
|
||||
>
|
||||
{t("general.actions.save")}
|
||||
</Button>
|
||||
<div className="imex-flex-row__grow imex-flex-row__margin-large">
|
||||
<FormFieldsChanged form={form} />
|
||||
</div>
|
||||
</div>
|
||||
<FormFieldsChanged form={form} />
|
||||
|
||||
<LayoutFormRow header={t("vehicles.forms.detail")}>
|
||||
<Form.Item
|
||||
@@ -136,7 +123,6 @@ export default function VehicleDetailFormComponent({ form, loading }) {
|
||||
<FormDatePicker />
|
||||
</Form.Item>
|
||||
{
|
||||
|
||||
//Removed as a part of IO-446.
|
||||
//No values have been captured in this field as of yet.
|
||||
// <Form.Item
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import React, { useState } from "react";
|
||||
import { Form, notification } from "antd";
|
||||
import { Button, Form, notification, PageHeader } from "antd";
|
||||
import { useMutation } from "@apollo/client";
|
||||
import VehicleDetailFormComponent from "./vehicle-detail-form.component";
|
||||
import { useTranslation } from "react-i18next";
|
||||
@@ -37,18 +37,32 @@ function VehicleDetailFormContainer({ vehicle, refetch }) {
|
||||
};
|
||||
|
||||
return (
|
||||
<Form
|
||||
onFinish={handleFinish}
|
||||
form={form}
|
||||
autoComplete="off"
|
||||
layout="vertical"
|
||||
initialValues={{
|
||||
...vehicle,
|
||||
v_prod_dt: vehicle.v_prod_dt ? moment(vehicle.v_prod_dt) : null,
|
||||
}}
|
||||
>
|
||||
<VehicleDetailFormComponent form={form} loading={loading} />
|
||||
</Form>
|
||||
<>
|
||||
<PageHeader
|
||||
title={t("menus.header.owners")}
|
||||
extra={
|
||||
<Button
|
||||
type="primary"
|
||||
loading={loading}
|
||||
onClick={() => form.submit()}
|
||||
>
|
||||
{t("general.actions.save")}
|
||||
</Button>
|
||||
}
|
||||
/>
|
||||
<Form
|
||||
onFinish={handleFinish}
|
||||
form={form}
|
||||
autoComplete="off"
|
||||
layout="vertical"
|
||||
initialValues={{
|
||||
...vehicle,
|
||||
v_prod_dt: vehicle.v_prod_dt ? moment(vehicle.v_prod_dt) : null,
|
||||
}}
|
||||
>
|
||||
<VehicleDetailFormComponent form={form} loading={loading} />
|
||||
</Form>
|
||||
</>
|
||||
);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user