Calculation/Form: add Insurance tab

This commit is contained in:
Chika 2022-06-14 13:28:07 +03:00
parent 6264a94df3
commit 362ecff603
3 changed files with 38 additions and 1 deletions

View File

@ -0,0 +1,15 @@
import type { FormComponentConfig } from '../../lib/renderFormComponent';
const config: FormComponentConfig = {
id: 'insurance',
title: 'Страхование',
rows: [
[['tbxLeaseObjectYear', 'selectLeaseObjectUseFor', 'selectLegalClientRegion']],
[['selectEngineType', 'tbxInsFranchise', 'selectLegalClientTown']],
[['selectLeaseObjectCategory', 'tbxMileage', 'tbxINNForCalc']],
[['tbxLeaseObjectMotorPower', 'cbxWithTrailer', 'selectGPSBrand']],
[['tbxEngineVolume', 'cbxInsDecentral', 'selectGPSModel']],
],
};
export default config;

View File

@ -0,0 +1,21 @@
import renderFormComponent from 'Components/Calculation/lib/renderFormComponent';
import { Flex } from 'UIKit/grid';
import config from './config';
function Insurance() {
const rows = renderFormComponent(config);
return (
<Flex flexDirection="column">
{rows}
{/* TODO: add Insurance Table */}
{/* TODO: add FinGAP Table */}
</Flex>
);
}
export default {
id: config.id,
title: config.title,
Component: Insurance,
};

View File

@ -1,11 +1,12 @@
import Background from 'Elements/layout/Background';
import { Tabs, Wrapper } from 'Elements/layout/Tabs';
import Insurance from './Insurance';
import Leasing from './Leasing';
import LeasingObject from './LeasingObject';
import Payments from './Payments';
import SupplierAgent from './SupplierAgent';
const formTabs = [Leasing, Payments, LeasingObject, SupplierAgent];
const formTabs = [Leasing, Payments, LeasingObject, SupplierAgent, Insurance];
function Form() {
return (