disable tableInsurance reaction while loading kp
This commit is contained in:
parent
aceea7c3f6
commit
1d1c4129fa
@ -88,29 +88,21 @@ const validateInsuranceTable = () => {
|
||||
{
|
||||
insuranceCompany: {
|
||||
validation: !isNil(
|
||||
CalculationStore.tables.tableInsurance.rows[osagoRowIndex]
|
||||
.insuranceCompany?.value,
|
||||
tableInsurance.rows[osagoRowIndex].insuranceCompany?.value,
|
||||
),
|
||||
},
|
||||
insured: {
|
||||
validation: !isNil(
|
||||
CalculationStore.tables.tableInsurance.rows[osagoRowIndex].insured
|
||||
?.value,
|
||||
),
|
||||
validation: !isNil(tableInsurance.rows[osagoRowIndex].insured?.value),
|
||||
},
|
||||
},
|
||||
{
|
||||
insuranceCompany: {
|
||||
validation: !isNil(
|
||||
CalculationStore.tables.tableInsurance.rows[kaskoRowIndex]
|
||||
.insuranceCompany?.value,
|
||||
tableInsurance.rows[kaskoRowIndex].insuranceCompany?.value,
|
||||
),
|
||||
},
|
||||
insured: {
|
||||
validation: !isNil(
|
||||
CalculationStore.tables.tableInsurance.rows[kaskoRowIndex].insured
|
||||
?.value,
|
||||
),
|
||||
validation: !isNil(tableInsurance.rows[kaskoRowIndex].insured?.value),
|
||||
},
|
||||
},
|
||||
]);
|
||||
|
||||
@ -2,7 +2,7 @@
|
||||
import { openNotification } from 'client/Elements/Notification';
|
||||
import {
|
||||
insuranceOsagoDefaultFilter,
|
||||
singleValueFilter
|
||||
singleValueFilter,
|
||||
} from 'core/constants/stores/Calculation/filters';
|
||||
import valuesConstants from 'core/constants/values';
|
||||
import { shift, shiftRight } from 'core/tools/array';
|
||||
@ -748,12 +748,15 @@ export default [
|
||||
},
|
||||
}),
|
||||
|
||||
calculationStore => ({
|
||||
(calculationStore, calculationProcess) => ({
|
||||
expression: () => {
|
||||
const { leaseObjectCategory } = calculationStore.values;
|
||||
return leaseObjectCategory;
|
||||
},
|
||||
effect: (nextLeaseObjectCategory, prevLeaseObjectCategory) => {
|
||||
if (calculationProcess.process === Process.LoadKp) {
|
||||
return;
|
||||
}
|
||||
const nextIsTrailer = nextLeaseObjectCategory === 100000004;
|
||||
const prevIsTrailer = prevLeaseObjectCategory === 100000004;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user