Merge branch 'master-beta' into master-AIO
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
import {DeleteFilled} from "@ant-design/icons";
|
||||
import {Button, Form, Input, InputNumber, Select, Switch, Typography,} from "antd";
|
||||
import {Button, Form, Input, InputNumber, Select, Space, Switch, Typography,} from "antd";
|
||||
import React, {useState} from "react";
|
||||
import {useTranslation} from "react-i18next";
|
||||
import styled from "styled-components";
|
||||
@@ -11,6 +11,7 @@ import {createStructuredSelector} from "reselect";
|
||||
import {useSplitTreatments} from "@splitsoftware/splitio-react";
|
||||
import ShopInfoResponsibilitycentersTaxesComponent from "./shop-info.responsibilitycenters.taxes.component";
|
||||
import InstanceRenderManager from '../../utils/instanceRenderMgr';
|
||||
import FormListMoveArrows from "../form-list-move-arrows/form-list-move-arrows.component";
|
||||
|
||||
const SelectorDiv = styled.div`
|
||||
.ant-form-item .ant-select {
|
||||
@@ -182,7 +183,7 @@ export function ShopInfoResponsibilityCenterComponent({bodyshop, form}) {
|
||||
</LayoutFormRow>
|
||||
<LayoutFormRow header={t("bodyshop.labels.dms.cdk.payers")}>
|
||||
<Form.List name={["cdk_configuration", "payers"]}>
|
||||
{(fields, {add, remove}) => {
|
||||
{(fields, {add, remove, move}) => {
|
||||
return (
|
||||
<div>
|
||||
{fields.map((field, index) => (
|
||||
@@ -240,11 +241,18 @@ export function ShopInfoResponsibilityCenterComponent({bodyshop, form}) {
|
||||
</Select>
|
||||
</Form.Item>
|
||||
|
||||
<DeleteFilled
|
||||
onClick={() => {
|
||||
remove(field.name);
|
||||
}}
|
||||
/>
|
||||
<Space align="center">
|
||||
d
|
||||
onClick={() => {
|
||||
remove(field.name);
|
||||
}}
|
||||
/>
|
||||
<FormListMoveArrows
|
||||
move={move}
|
||||
index={index}
|
||||
total={fields.length}
|
||||
/>
|
||||
</Space>
|
||||
</LayoutFormRow>
|
||||
</Form.Item>
|
||||
))}
|
||||
@@ -336,7 +344,7 @@ export function ShopInfoResponsibilityCenterComponent({bodyshop, form}) {
|
||||
id="costs"
|
||||
>
|
||||
<Form.List name={["md_responsibility_centers", "costs"]}>
|
||||
{(fields, {add, remove}) => {
|
||||
{(fields, {add, remove, move}) => {
|
||||
return (
|
||||
<div>
|
||||
{fields.map((field, index) => (
|
||||
@@ -453,12 +461,18 @@ export function ShopInfoResponsibilityCenterComponent({bodyshop, form}) {
|
||||
<Input onBlur={handleBlur}/>
|
||||
</Form.Item>
|
||||
)}
|
||||
|
||||
<DeleteFilled
|
||||
onClick={() => {
|
||||
remove(field.name);
|
||||
}}
|
||||
/>
|
||||
<Space align="center">
|
||||
<DeleteFilled
|
||||
onClick={() => {
|
||||
remove(field.name);
|
||||
}}
|
||||
/>
|
||||
<FormListMoveArrows
|
||||
move={move}
|
||||
index={index}
|
||||
total={fields.length}
|
||||
/>
|
||||
</Space>
|
||||
</LayoutFormRow>
|
||||
</Form.Item>
|
||||
))}
|
||||
@@ -484,7 +498,7 @@ export function ShopInfoResponsibilityCenterComponent({bodyshop, form}) {
|
||||
id="profits"
|
||||
>
|
||||
<Form.List name={["md_responsibility_centers", "profits"]}>
|
||||
{(fields, {add, remove}) => {
|
||||
{(fields, {add, remove, move}) => {
|
||||
return (
|
||||
<div>
|
||||
{fields.map((field, index) => (
|
||||
@@ -586,11 +600,18 @@ export function ShopInfoResponsibilityCenterComponent({bodyshop, form}) {
|
||||
<Input onBlur={handleBlur}/>
|
||||
</Form.Item>
|
||||
)}
|
||||
<DeleteFilled
|
||||
onClick={() => {
|
||||
remove(field.name);
|
||||
}}
|
||||
/>
|
||||
<Space align="center">
|
||||
<DeleteFilled
|
||||
onClick={() => {
|
||||
remove(field.name);
|
||||
}}
|
||||
/>
|
||||
<FormListMoveArrows
|
||||
move={move}
|
||||
index={index}
|
||||
total={fields.length}
|
||||
/>
|
||||
</Space>
|
||||
</LayoutFormRow>
|
||||
</Form.Item>
|
||||
))}
|
||||
@@ -615,7 +636,7 @@ export function ShopInfoResponsibilityCenterComponent({bodyshop, form}) {
|
||||
{(bodyshop.cdk_dealerid || bodyshop.pbs_serialnumber) && (
|
||||
<>
|
||||
<Form.List name={["md_responsibility_centers", "dms_defaults"]}>
|
||||
{(fields, {add, remove}) => {
|
||||
{(fields, {add, remove, move}) => {
|
||||
return (
|
||||
<div>
|
||||
{fields.map((field, index) => (
|
||||
|
||||
Reference in New Issue
Block a user