UI fixes for manual job creation + owners pages + vehicles pages + all jobs BOD-155

This commit is contained in:
Patrick Fic
2020-06-12 17:54:20 -07:00
parent a88785fc43
commit 05bf94e808
37 changed files with 1339 additions and 972 deletions

View File

@@ -11,12 +11,12 @@ function OwnerDetailFormContainer({ owner, refetch }) {
const [updateOwner] = useMutation(UPDATE_OWNER);
const handleFinish = values => {
const handleFinish = (values) => {
updateOwner({
variables: { ownerId: owner.id, owner: values }
}).then(r => {
variables: { ownerId: owner.id, owner: values },
}).then((r) => {
notification["success"]({
message: t("owners.successes.save")
message: t("owners.successes.save"),
});
//TODO Better way to reset the field decorators?
if (refetch) refetch().then();
@@ -28,9 +28,9 @@ function OwnerDetailFormContainer({ owner, refetch }) {
<Form
form={form}
onFinish={handleFinish}
autoComplete="off"
initialValues={owner}
>
autoComplete='off'
layout='vertical'
initialValues={owner}>
<OwnerDetailFormComponent form={form} />
</Form>
);