merge release/dyn-686:
telematic_min-price_products-by-users
This commit is contained in:
parent
f211dd2377
commit
129ab75840
@ -3,7 +3,7 @@ module.exports = {
|
||||
service: {
|
||||
name: 'crmgraphql',
|
||||
url: 'http://localhost/crmgraphql/',
|
||||
localSchemaFile: 'src/core/graphql/schemas/crm.graphql',
|
||||
// localSchemaFile: 'src/core/graphql/schemas/crm.graphql',
|
||||
},
|
||||
excludes: ['src/core/graphql/schemas/**/*.*'],
|
||||
},
|
||||
|
||||
@ -12,7 +12,6 @@
|
||||
"babel-plugin-transform-imports": "^2.0.0",
|
||||
"craco-less": "^2.0.0",
|
||||
"dayjs": "^1.10.4",
|
||||
"graphql": "^16.2.0",
|
||||
"graphql.macro": "^1.4.2",
|
||||
"lodash": "^4.17.21",
|
||||
"mobx": "^6.1.8",
|
||||
|
||||
@ -468,6 +468,7 @@ const sections: ISection[] = [
|
||||
// {
|
||||
// elements: [
|
||||
// // 'cbxInsDecentral',
|
||||
// 'tbxMinPriceChange',
|
||||
// 'tbxMaxPriceChange',
|
||||
// 'tbxImporterRewardPerc',
|
||||
// 'tbxImporterRewardRub',
|
||||
|
||||
@ -175,6 +175,7 @@ const elementsComponents: TElements<Component> = {
|
||||
selectSubsidy: Select,
|
||||
selectFuelCard: Select,
|
||||
labelSubsidySum: Label,
|
||||
tbxMinPriceChange: InputNumber,
|
||||
};
|
||||
|
||||
const tablesComponents: StoreTables<Component> = {
|
||||
|
||||
@ -457,6 +457,14 @@ const elementsProps: TElements<ElementProps> = {
|
||||
radioInfuranceOPF: {
|
||||
style: 'button',
|
||||
},
|
||||
selectHighSeasonStart: {
|
||||
tooltip: {
|
||||
Component: buildTooltip({
|
||||
title: 'С какого платежа начинается полный высокий сезон',
|
||||
placement: 'topLeft',
|
||||
}),
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
export const numberElementsProps: TElements<ElementProps> = Object.keys(
|
||||
|
||||
@ -40,7 +40,7 @@ export const elementsTitles: TElements<string> = {
|
||||
radioGraphType: 'Вид графика',
|
||||
tbxParmentsDecreasePercent: 'Процент убывания платежей',
|
||||
selectSeasonType: 'Тип дегрессии/сезонности',
|
||||
selectHighSeasonStart: 'С какого платежа начинается высокий сезон',
|
||||
selectHighSeasonStart: 'Смещение сезонности',
|
||||
tbxComissionPerc: 'Комиссия, %',
|
||||
tbxComissionRub: 'Комиссия, руб.',
|
||||
tbxSaleBonus: 'Размер бонуса МПЛ',
|
||||
@ -140,6 +140,7 @@ export const elementsTitles: TElements<string> = {
|
||||
selectSubsidy: 'Субсидия',
|
||||
labelSubsidySum: 'Сумма субсидии с НДС',
|
||||
selectFuelCard: 'Топливная карта',
|
||||
tbxMinPriceChange: 'Мин. возможное изменение стоимости ПЛ',
|
||||
};
|
||||
|
||||
const resultsTitles: TElements<string> = {
|
||||
|
||||
@ -139,6 +139,7 @@ export const elementsValues: TElements<ValuesNames> = {
|
||||
selectSubsidy: 'subsidy',
|
||||
labelSubsidySum: 'subsidySum',
|
||||
selectFuelCard: 'fuelCard',
|
||||
tbxMinPriceChange: 'minPriceChange',
|
||||
};
|
||||
|
||||
const resultElementsValues: TElements<ResultValuesNames> = {
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
import { getValueName } from 'client/Containers/Calculation/lib/elements/tools';
|
||||
import initialFilters, {
|
||||
noResetValueElements,
|
||||
noResetValueElements
|
||||
} from 'client/stores/CalculationStore/config/initialFilters';
|
||||
import initialStatuses from 'client/stores/CalculationStore/config/initialStatuses';
|
||||
import { isNil, mergeWith, pick } from 'lodash';
|
||||
@ -66,11 +66,17 @@ const valuesActions = {
|
||||
);
|
||||
});
|
||||
},
|
||||
getOptions(elementName, fields) {
|
||||
if (!this.options[elementName]) {
|
||||
getOptions(elementName, fields, filtered = false) {
|
||||
let options = this.options[elementName];
|
||||
const filter = this.filters[elementName];
|
||||
if (filtered && filter) {
|
||||
options = filter(options);
|
||||
}
|
||||
|
||||
if (!options) {
|
||||
return;
|
||||
}
|
||||
if (!fields) return this.options[elementName];
|
||||
if (!fields) return options;
|
||||
return this.options[elementName].filter(option => {
|
||||
return Object.keys(fields).every(
|
||||
fieldName => option[fieldName] === fields[fieldName],
|
||||
|
||||
@ -352,6 +352,7 @@ const gibddReactions: IReactionEffect[] = [
|
||||
'regionRegistration',
|
||||
'typePTS',
|
||||
'leaseObjectCategory',
|
||||
'leaseObjectType',
|
||||
]),
|
||||
};
|
||||
},
|
||||
@ -361,9 +362,18 @@ const gibddReactions: IReactionEffect[] = [
|
||||
regionRegistration,
|
||||
typePTS,
|
||||
leaseObjectCategory,
|
||||
leaseObjectType,
|
||||
}) => {
|
||||
calculationStore.setFilter('selectRegistration', options =>
|
||||
options.filter(x => {
|
||||
if (
|
||||
!x.evo_leasingobject_types?.find(
|
||||
x => x.evo_leasingobject_typeid === leaseObjectType,
|
||||
)
|
||||
) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (!objectRegionRegistration && !regionRegistration) {
|
||||
return false;
|
||||
}
|
||||
|
||||
@ -3,7 +3,7 @@ import { resetIns } from 'client/Components/Calculation/ELT/Content/lib/resetIns
|
||||
import { numberElementsProps } from 'client/Containers/Calculation/lib/elements/elementsProps';
|
||||
import {
|
||||
getTitle,
|
||||
getValueName,
|
||||
getValueName
|
||||
} from 'client/Containers/Calculation/lib/elements/tools';
|
||||
import { elementsValues } from 'client/Containers/Calculation/lib/elements/values';
|
||||
import { openNotification } from 'client/Elements/Notification';
|
||||
@ -12,9 +12,10 @@ import {
|
||||
getMainOptionsForQuote,
|
||||
getQuoteQuery,
|
||||
getSecondaryOptionsForQuote,
|
||||
getSingleOptionsForQuote,
|
||||
getSingleOptionsForQuote
|
||||
} from 'core/graphql/query/crm/quote';
|
||||
import CrmService from 'core/services/CrmService';
|
||||
import { TOptionizedEntity } from 'core/services/CrmService/types/common';
|
||||
import { currentISODate } from 'core/tools/date';
|
||||
import { NIL } from 'core/tools/uuid';
|
||||
import { IReactionEffect } from 'core/types/Calculation/Store/effect';
|
||||
@ -26,7 +27,7 @@ import {
|
||||
IEvoGraph,
|
||||
IEvoTown,
|
||||
IQuote,
|
||||
TCRMEntity,
|
||||
TCRMEntity
|
||||
} from 'core/types/Entities/crmEntities';
|
||||
import { ElementStatus } from 'core/types/statuses';
|
||||
import { get, invert, isEqual, isNil } from 'lodash';
|
||||
@ -72,13 +73,10 @@ const loadKpReaction: IReactionEffect = calculationStore => ({
|
||||
opportunity,
|
||||
recalcWithRevision,
|
||||
calcType,
|
||||
indAgent,
|
||||
INNForCalc,
|
||||
creditRate,
|
||||
rate,
|
||||
infuranceOPF,
|
||||
calcBroker,
|
||||
calcFinDepartment,
|
||||
balanceHolder,
|
||||
} = calculationStore.values;
|
||||
|
||||
@ -129,25 +127,74 @@ const loadKpReaction: IReactionEffect = calculationStore => ({
|
||||
evo_gps_brandid: quote.evo_gps_brandid || NIL,
|
||||
evo_regionid: quote.evo_regionid || NIL,
|
||||
evo_legal_regionid: quote.evo_legal_regionid || NIL,
|
||||
evo_agency_agreementid_param: { has: true },
|
||||
},
|
||||
});
|
||||
|
||||
const { selectDealerBroker } = await CrmService.getCRMOptions<
|
||||
// selectDealerBroker query
|
||||
let selectDealerBroker: TOptionizedEntity<IAccount>[] = [];
|
||||
const dealer_broker_accountid =
|
||||
mainOptions?.selectDealerPerson &&
|
||||
mainOptions?.selectDealerPerson?.length > 0 &&
|
||||
mainOptions.selectDealerPerson[0].evo_broker_accountid;
|
||||
if (dealer_broker_accountid) {
|
||||
const selectDealerBrokerRes = await CrmService.getCRMOptions<
|
||||
'selectDealerBroker',
|
||||
IAccount
|
||||
>({
|
||||
query: getSingleOptionsForQuote,
|
||||
variables: {
|
||||
dealer_broker_accountid: quote.evo_dealer_broker_accountid || NIL,
|
||||
hasDealerBroker: quote.evo_dealer_broker_accountid ? true : false,
|
||||
dealer_broker_accountid,
|
||||
},
|
||||
});
|
||||
if (selectDealerBrokerRes?.selectDealerBroker)
|
||||
selectDealerBroker = selectDealerBrokerRes.selectDealerBroker;
|
||||
}
|
||||
// selectDealerBroker query
|
||||
|
||||
calculationStore.applyOptions({
|
||||
...mainOptions,
|
||||
selectDealerBroker,
|
||||
selectDealerBroker: selectDealerBroker,
|
||||
});
|
||||
|
||||
// agents
|
||||
//TODO: refactor
|
||||
const { indAgent, calcBroker, calcFinDepartment } =
|
||||
calculationStore.values;
|
||||
let {
|
||||
indAgentRewardCondition,
|
||||
indAgentRewardSumm,
|
||||
calcBrokerRewardCondition,
|
||||
calcBrokerRewardSum,
|
||||
finDepartmentRewardCondtion,
|
||||
finDepartmentRewardSumm,
|
||||
} = calculationStore.values;
|
||||
if (indAgent === quote.evo_agent_accountid) {
|
||||
indAgentRewardCondition = quote.evo_agent_reward_conditionid;
|
||||
indAgentRewardSumm = quote.evo_agent_reward_total;
|
||||
}
|
||||
|
||||
if (calcBroker === quote.evo_broker_accountid) {
|
||||
calcBrokerRewardCondition = quote.evo_broker_reward_conditionid;
|
||||
calcBrokerRewardSum = quote.evo_broker_reward_total;
|
||||
}
|
||||
|
||||
if (calcFinDepartment === quote.evo_fin_department_accountid) {
|
||||
finDepartmentRewardCondtion =
|
||||
quote.evo_fin_department_reward_conditionid;
|
||||
finDepartmentRewardSumm = quote.evo_fin_department_reward_total;
|
||||
}
|
||||
|
||||
const agentsValues = {
|
||||
indAgentRewardCondition,
|
||||
indAgentRewardSumm,
|
||||
calcBrokerRewardCondition,
|
||||
calcBrokerRewardSum,
|
||||
finDepartmentRewardCondtion,
|
||||
finDepartmentRewardSumm,
|
||||
};
|
||||
// agents
|
||||
|
||||
// fill insurance table
|
||||
calculationStore.setTableRows(
|
||||
'tableInsurance',
|
||||
@ -519,6 +566,7 @@ const loadKpReaction: IReactionEffect = calculationStore => ({
|
||||
requirementTelematic,
|
||||
balanceHolder,
|
||||
redemptionPaymentSum,
|
||||
...agentsValues,
|
||||
};
|
||||
|
||||
// check min max number values
|
||||
|
||||
@ -48,17 +48,17 @@ const mapKPtoValues: Partial<Record<ValuesNames, keyof IQuote | string>> = {
|
||||
dealerBrokerRewardCondition: 'evo_dealer_broker_reward_conditionid',
|
||||
dealerBrokerRewardSumm: 'evo_dealer_broker_reward_total',
|
||||
// indAgent: 'evo_agent_accountid',
|
||||
indAgentRewardCondition: 'evo_agent_reward_conditionid',
|
||||
indAgentRewardSumm: 'evo_agent_reward_total',
|
||||
// indAgentRewardCondition: 'evo_agent_reward_conditionid',
|
||||
// indAgentRewardSumm: 'evo_agent_reward_total',
|
||||
calcDoubleAgent: 'evo_double_agent_accountid',
|
||||
calcDoubleAgentRewardCondition: 'evo_double_agent_reward_conditionid',
|
||||
calcDoubleAgentRewardSumm: 'evo_double_agent_reward_total',
|
||||
// calcBroker: 'evo_broker_accountid',
|
||||
calcBrokerRewardCondition: 'evo_broker_reward_conditionid',
|
||||
calcBrokerRewardSum: 'evo_broker_reward_total',
|
||||
// calcBrokerRewardCondition: 'evo_broker_reward_conditionid',
|
||||
// calcBrokerRewardSum: 'evo_broker_reward_total',
|
||||
// calcFinDepartment: 'evo_fin_department_accountid',
|
||||
finDepartmentRewardCondtion: 'evo_fin_department_reward_conditionid',
|
||||
finDepartmentRewardSumm: 'evo_fin_department_reward_total',
|
||||
// finDepartmentRewardCondtion: 'evo_fin_department_reward_conditionid',
|
||||
// finDepartmentRewardSumm: 'evo_fin_department_reward_total',
|
||||
GPSBrand: 'evo_gps_brandid',
|
||||
GPSModel: 'evo_gps_modelid',
|
||||
infuranceOPF: 'evo_ins_legal_form',
|
||||
@ -80,6 +80,7 @@ const mapKPtoValues: Partial<Record<ValuesNames, keyof IQuote | string>> = {
|
||||
quoteName: 'evo_contact_name',
|
||||
quoteContactGender: 'evo_gender',
|
||||
quoteRedemptionGraph: 'evo_redemption_graph',
|
||||
minPriceChange: 'evo_min_change_price',
|
||||
maxPriceChange: 'evo_max_price_change',
|
||||
importerRewardPerc: 'evo_importer_reward_perc',
|
||||
importerRewardRub: 'evo_importer_reward_rub',
|
||||
|
||||
@ -169,7 +169,7 @@ const reactionEffects: IReactionEffect[] = [
|
||||
},
|
||||
effect: indAgentRewardConditionId => {
|
||||
if (!indAgentRewardConditionId) {
|
||||
calculationStore.setValue('indAgentRewardSumm', null);
|
||||
calculationStore.setValue('indAgentRewardSumm', 0);
|
||||
calculationStore.setStatus(
|
||||
'tbxIndAgentRewardSumm',
|
||||
ElementStatus.Disabled,
|
||||
@ -657,11 +657,8 @@ const reactionEffects: IReactionEffect[] = [
|
||||
|
||||
calculationStore => ({
|
||||
expression: () => {
|
||||
const {
|
||||
lastPaymentRub,
|
||||
lastPaymentPerc,
|
||||
insNSIB,
|
||||
} = calculationStore.values;
|
||||
const { lastPaymentRub, lastPaymentPerc, insNSIB } =
|
||||
calculationStore.values;
|
||||
return { lastPaymentRub, lastPaymentPerc, insNSIB };
|
||||
},
|
||||
effect: ({ lastPaymentRub, insNSIB }) => {
|
||||
@ -794,26 +791,14 @@ const reactionEffects: IReactionEffect[] = [
|
||||
}),
|
||||
|
||||
calculationStore => ({
|
||||
expression: () => {
|
||||
const { seasonType } = calculationStore.values;
|
||||
return seasonType;
|
||||
},
|
||||
effect: seasonType => {
|
||||
if (seasonType) {
|
||||
switch (seasonType) {
|
||||
case 100000001:
|
||||
case 100000002: {
|
||||
calculationStore.setFilter('selectHighSeasonStart', seasons => {
|
||||
return seasons.filter(
|
||||
season => season.value && season.value <= 100000004,
|
||||
expression: () => calculationStore.getOption('selectSeasonType'),
|
||||
effect: ({ forbiddenHighSeasonStart }) => {
|
||||
if (forbiddenHighSeasonStart) {
|
||||
calculationStore.setFilter('selectHighSeasonStart', seasonStart =>
|
||||
seasonStart.filter(s => !forbiddenHighSeasonStart.includes(s.name)),
|
||||
);
|
||||
});
|
||||
break;
|
||||
}
|
||||
default:
|
||||
} else {
|
||||
calculationStore.setFilter('selectHighSeasonStart', undefined);
|
||||
break;
|
||||
}
|
||||
}
|
||||
},
|
||||
options: {
|
||||
@ -1495,12 +1480,10 @@ const reactionEffects: IReactionEffect[] = [
|
||||
|
||||
const fuelCard = calculationStore.getOption('selectFuelCard');
|
||||
if (fuelCard) {
|
||||
const selectFuelCard_filter = calculationStore.getFilter(
|
||||
'selectFuelCard',
|
||||
);
|
||||
const selectFueldCard_options = calculationStore.getOptions(
|
||||
'selectFuelCard',
|
||||
);
|
||||
const selectFuelCard_filter =
|
||||
calculationStore.getFilter('selectFuelCard');
|
||||
const selectFueldCard_options =
|
||||
calculationStore.getOptions('selectFuelCard');
|
||||
|
||||
if (selectFuelCard_filter && selectFueldCard_options) {
|
||||
const filtered_technicalCards = selectFuelCard_filter(
|
||||
|
||||
@ -1,9 +1,12 @@
|
||||
import { getFieldName } from 'client/Containers/Calculation/lib/elements/tools';
|
||||
import { openNotification } from 'client/Elements/Notification';
|
||||
import valuesConstants from 'core/constants/values';
|
||||
import { pipe } from 'core/tools/func';
|
||||
import { IReactionEffect } from 'core/types/Calculation/Store/effect';
|
||||
import { ElementsNames } from 'core/types/Calculation/Store/elements';
|
||||
import { Process } from 'core/types/Calculation/Store/process';
|
||||
import { TableNames } from 'core/types/Calculation/Store/tables';
|
||||
import { ValuesNames } from 'core/types/Calculation/Store/values';
|
||||
import { ElementStatus } from 'core/types/statuses';
|
||||
import { convertPrice } from '../lib/tools';
|
||||
import { getPrice } from './priceReactions/calculate';
|
||||
@ -42,12 +45,17 @@ const reactionEffects: IReactionEffect[] = [
|
||||
calculationStore,
|
||||
);
|
||||
|
||||
const maxPriceChange =
|
||||
const maxPriceChangeValue =
|
||||
price - supplierDiscountRub < 800000
|
||||
? price - supplierDiscountRub + 50000
|
||||
: (price - supplierDiscountRub) * 1.05;
|
||||
calculationStore.setValue('maxPriceChange', maxPriceChangeValue);
|
||||
|
||||
calculationStore.setValue('maxPriceChange', maxPriceChange);
|
||||
const minPriceChangeValue =
|
||||
price - supplierDiscountRub < 800000
|
||||
? price - supplierDiscountRub - 50000
|
||||
: (price - supplierDiscountRub) * 0.95;
|
||||
calculationStore.setValue('minPriceChange', minPriceChangeValue);
|
||||
},
|
||||
options: {
|
||||
fireImmediately: true,
|
||||
@ -119,7 +127,7 @@ const reactionEffects: IReactionEffect[] = [
|
||||
);
|
||||
|
||||
const quote = calculationStore.getOption('selectQuote');
|
||||
if (quote && quote.evo_max_price_change) {
|
||||
if (quote?.evo_max_price_change) {
|
||||
if (price - supplierDiscountRub > quote.evo_max_price_change) {
|
||||
calculationStore.setValidation('tbxLeaseObjectPrice', false);
|
||||
openNotification({
|
||||
@ -133,6 +141,21 @@ const reactionEffects: IReactionEffect[] = [
|
||||
calculationStore.setValidation('tbxLeaseObjectPrice', undefined);
|
||||
}
|
||||
}
|
||||
|
||||
if (quote?.evo_min_change_price) {
|
||||
if (price - supplierDiscountRub < quote.evo_min_change_price) {
|
||||
calculationStore.setValidation('tbxLeaseObjectPrice', false);
|
||||
openNotification({
|
||||
type: 'error',
|
||||
title: 'Ошибка',
|
||||
description:
|
||||
'Указанная стоимость предмета лизинга меньше возмножного изменения стоимости предмета лизинга при пересчете без пересмотра. ' +
|
||||
'Увеличьте стоимость предмета лизинга',
|
||||
})();
|
||||
} else {
|
||||
calculationStore.setValidation('tbxLeaseObjectPrice', undefined);
|
||||
}
|
||||
}
|
||||
},
|
||||
}),
|
||||
|
||||
@ -345,7 +368,9 @@ const reactionEffects: IReactionEffect[] = [
|
||||
return;
|
||||
}
|
||||
if (!recalcWithRevision) {
|
||||
const allowedReqTelematicValues = [100000000, 100000001];
|
||||
const allowedReqTelematicValues = [
|
||||
100000000, 100000001, 100000002, 100000003,
|
||||
];
|
||||
calculationStore.setFilter('radioRequirementTelematic', options =>
|
||||
options.filter(
|
||||
x =>
|
||||
@ -429,32 +454,41 @@ const reactionEffects: IReactionEffect[] = [
|
||||
|
||||
(calculationStore, calculationProcess) => ({
|
||||
expression: () => {
|
||||
return calculationStore.getValue('requirementTelematic');
|
||||
},
|
||||
effect: requirementTelematic => {
|
||||
if (calculationProcess.hasProcess(Process.LoadKp)) {
|
||||
return;
|
||||
}
|
||||
const recalcWithRevision = calculationStore.getValue(
|
||||
return calculationStore.getValues([
|
||||
'requirementTelematic',
|
||||
'recalcWithRevision',
|
||||
);
|
||||
if (!recalcWithRevision) {
|
||||
calculationStore.setValue('telematic', null);
|
||||
]);
|
||||
},
|
||||
effect: ({ requirementTelematic, recalcWithRevision }) => {
|
||||
(['tracker', 'telematic'] as ValuesNames[]).forEach(valueName => {
|
||||
const elementName = getFieldName(valueName);
|
||||
|
||||
const addProducts = calculationStore.getStaticData(
|
||||
'evo_addproduct_type',
|
||||
);
|
||||
let tracker = addProducts.find(x =>
|
||||
x.evo_controls_program?.includes(requirementTelematic),
|
||||
calculationStore.setFilter(elementName, options =>
|
||||
options.filter(
|
||||
pipe(
|
||||
x => {
|
||||
if (x.evo_controls_program?.includes(requirementTelematic))
|
||||
return x;
|
||||
},
|
||||
x => {
|
||||
if (recalcWithRevision) return x;
|
||||
if (x?.evo_visible_calc === true) return x;
|
||||
},
|
||||
),
|
||||
),
|
||||
);
|
||||
|
||||
calculationStore.setValue('tracker', tracker?.evo_addproduct_typeid);
|
||||
} else {
|
||||
calculationStore.setStatus(
|
||||
'radioRequirementTelematic',
|
||||
ElementStatus.Disabled,
|
||||
if (!calculationProcess.hasProcess(Process.LoadKp)) {
|
||||
const elementOptions = calculationStore.getOptions(
|
||||
elementName,
|
||||
undefined,
|
||||
true,
|
||||
);
|
||||
//TODO: удалить после рефактора CalculationStore
|
||||
if (elementOptions?.length === 1)
|
||||
calculationStore.setValue(valueName, elementOptions[0].value);
|
||||
}
|
||||
});
|
||||
},
|
||||
options: {
|
||||
fireImmediately: true,
|
||||
|
||||
@ -306,18 +306,21 @@ export default [
|
||||
$statecode: Int
|
||||
$currentDate: DateTime
|
||||
$evo_agent_accountid: Uuid
|
||||
$evo_agency_agreementid_param: GuidParamInput
|
||||
) {
|
||||
evo_reward_conditions(
|
||||
evo_agent_accountid: $evo_agent_accountid
|
||||
evo_datefrom_param: { lte: $currentDate }
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
statecode: $statecode
|
||||
evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
) {
|
||||
evo_reward_conditionid
|
||||
evo_name
|
||||
evo_double_agent_accountid
|
||||
evo_reward_summ
|
||||
evo_reduce_reward
|
||||
evo_agency_agreementid
|
||||
}
|
||||
}
|
||||
`,
|
||||
@ -325,6 +328,7 @@ export default [
|
||||
evo_agent_accountid: indAgentId,
|
||||
currentDate: currentISODate,
|
||||
statecode: 0,
|
||||
evo_agency_agreementid_param: { has: true },
|
||||
},
|
||||
}).then(({ evo_reward_conditions }) => {
|
||||
if (evo_reward_conditions)
|
||||
@ -369,17 +373,20 @@ export default [
|
||||
$statecode: Int
|
||||
$currentDate: DateTime
|
||||
$evo_agent_accountid: Uuid
|
||||
$evo_agency_agreementid_param: GuidParamInput
|
||||
) {
|
||||
evo_reward_conditions(
|
||||
evo_agent_accountid: $evo_agent_accountid
|
||||
evo_datefrom_param: { lte: $currentDate }
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
statecode: $statecode
|
||||
evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
) {
|
||||
evo_reward_conditionid
|
||||
evo_name
|
||||
evo_reward_summ
|
||||
evo_reduce_reward
|
||||
evo_agency_agreementid
|
||||
}
|
||||
}
|
||||
`,
|
||||
@ -387,6 +394,7 @@ export default [
|
||||
evo_agent_accountid: doubleAgentId,
|
||||
currentDate: currentISODate,
|
||||
statecode: 0,
|
||||
evo_agency_agreementid_param: { has: true },
|
||||
},
|
||||
}).then(({ evo_reward_conditions }) => {
|
||||
if (evo_reward_conditions)
|
||||
@ -433,17 +441,20 @@ export default [
|
||||
$statecode: Int
|
||||
$currentDate: DateTime
|
||||
$evo_agent_accountid: Uuid
|
||||
$evo_agency_agreementid_param: GuidParamInput
|
||||
) {
|
||||
evo_reward_conditions(
|
||||
evo_agent_accountid: $evo_agent_accountid
|
||||
evo_datefrom_param: { lte: $currentDate }
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
statecode: $statecode
|
||||
evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
) {
|
||||
evo_reward_conditionid
|
||||
evo_name
|
||||
evo_reward_summ
|
||||
evo_reduce_reward
|
||||
evo_agency_agreementid
|
||||
}
|
||||
}
|
||||
`,
|
||||
@ -451,6 +462,7 @@ export default [
|
||||
evo_agent_accountid: calcFinDepartmentId,
|
||||
currentDate: currentISODate,
|
||||
statecode: 0,
|
||||
evo_agency_agreementid_param: { has: true },
|
||||
},
|
||||
}).then(({ evo_reward_conditions }) => {
|
||||
if (evo_reward_conditions)
|
||||
@ -495,17 +507,20 @@ export default [
|
||||
$statecode: Int
|
||||
$currentDate: DateTime
|
||||
$evo_agent_accountid: Uuid
|
||||
$evo_agency_agreementid_param: GuidParamInput
|
||||
) {
|
||||
evo_reward_conditions(
|
||||
evo_agent_accountid: $evo_agent_accountid
|
||||
evo_datefrom_param: { lte: $currentDate }
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
statecode: $statecode
|
||||
evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
) {
|
||||
evo_reward_conditionid
|
||||
evo_name
|
||||
evo_reward_summ
|
||||
evo_reduce_reward
|
||||
evo_agency_agreementid
|
||||
}
|
||||
}
|
||||
`,
|
||||
@ -513,6 +528,7 @@ export default [
|
||||
evo_agent_accountid: calcBrokerId,
|
||||
currentDate: currentISODate,
|
||||
statecode: 0,
|
||||
evo_agency_agreementid_param: { has: true },
|
||||
},
|
||||
}).then(({ evo_reward_conditions }) => {
|
||||
if (evo_reward_conditions)
|
||||
@ -669,17 +685,20 @@ export default [
|
||||
$statecode: Int
|
||||
$currentDate: DateTime
|
||||
$evo_agent_accountid: Uuid
|
||||
$evo_agency_agreementid_param: GuidParamInput
|
||||
) {
|
||||
evo_reward_conditions(
|
||||
evo_agent_accountid: $evo_agent_accountid
|
||||
evo_datefrom_param: { lte: $currentDate }
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
statecode: $statecode
|
||||
evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
) {
|
||||
evo_reward_conditionid
|
||||
evo_name
|
||||
evo_reward_summ
|
||||
evo_reduce_reward
|
||||
evo_agency_agreementid
|
||||
}
|
||||
}
|
||||
`,
|
||||
@ -687,6 +706,7 @@ export default [
|
||||
evo_agent_accountid: dealerBrokerId,
|
||||
currentDate: currentISODate,
|
||||
statecode: 0,
|
||||
evo_agency_agreementid_param: { has: true },
|
||||
},
|
||||
}).then(({ evo_reward_conditions }) => {
|
||||
if (evo_reward_conditions)
|
||||
@ -730,17 +750,20 @@ export default [
|
||||
$statecode: Int
|
||||
$currentDate: DateTime
|
||||
$evo_agent_accountid: Uuid
|
||||
$evo_agency_agreementid_param: GuidParamInput
|
||||
) {
|
||||
evo_reward_conditions(
|
||||
evo_agent_accountid: $evo_agent_accountid
|
||||
evo_datefrom_param: { lte: $currentDate }
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
statecode: $statecode
|
||||
evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
) {
|
||||
evo_reward_conditionid
|
||||
evo_name
|
||||
evo_reward_summ
|
||||
evo_reduce_reward
|
||||
evo_agency_agreementid
|
||||
}
|
||||
}
|
||||
`,
|
||||
@ -748,6 +771,7 @@ export default [
|
||||
evo_agent_accountid: dealerPersonId,
|
||||
currentDate: currentISODate,
|
||||
statecode: 0,
|
||||
evo_agency_agreementid_param: { has: true },
|
||||
},
|
||||
}).then(({ evo_reward_conditions }) => {
|
||||
if (evo_reward_conditions)
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
/* eslint-disable @typescript-eslint/ban-ts-comment */
|
||||
import { openNotification } from 'client/Elements/Notification';
|
||||
import {
|
||||
insuranceKaskoDefaultFilter,
|
||||
insuranceOsagoDefaultFilter,
|
||||
singleValueFilter,
|
||||
} from 'core/constants/stores/Calculation/filters';
|
||||
@ -808,4 +809,44 @@ export default [
|
||||
}
|
||||
},
|
||||
}),
|
||||
(calculationStore, calculationProcess) => ({
|
||||
expression: () => calculationStore.getOption('selectBrand'),
|
||||
effect: brand => {
|
||||
if (calculationProcess.hasProcess(Process.LoadKp)) {
|
||||
return;
|
||||
}
|
||||
if (brand?.evo_id === 'BRAND49') {
|
||||
const { tableInsurance } = calculationStore.tables;
|
||||
// ПАО "ГРУППА РЕНЕССАНС СТРАХОВАНИЕ"
|
||||
const targetInsuranceCompany =
|
||||
tableInsurance.options?.insuranceCompany?.find(
|
||||
x => x.evo_inn === '7725497022',
|
||||
);
|
||||
if (targetInsuranceCompany) {
|
||||
const targetInsuranceFilter = singleValueFilter(
|
||||
targetInsuranceCompany.value,
|
||||
);
|
||||
calculationStore.setTableRow('tableInsurance', rows =>
|
||||
rows.findIndex(x => x.policyType?.value === 'КАСКО'),
|
||||
)({
|
||||
insuranceCompany: {
|
||||
filter: targetInsuranceFilter,
|
||||
value: targetInsuranceCompany.value,
|
||||
status: ElementStatus.Disabled,
|
||||
},
|
||||
});
|
||||
}
|
||||
} else {
|
||||
calculationStore.setTableRow('tableInsurance', rows =>
|
||||
rows.findIndex(x => x.policyType?.value === 'КАСКО'),
|
||||
)({
|
||||
insuranceCompany: {
|
||||
filter: insuranceKaskoDefaultFilter,
|
||||
status: ElementStatus.Default,
|
||||
value: null,
|
||||
},
|
||||
});
|
||||
}
|
||||
},
|
||||
}),
|
||||
] as IReactionEffect[];
|
||||
|
||||
@ -89,6 +89,7 @@ const initialOptions: TElements<IBaseOption[]> = {
|
||||
startPositions: [0, 6],
|
||||
paymentsInStep: [6, 6],
|
||||
stepsValues: [100, 50],
|
||||
forbiddenHighSeasonStart: ['9', '10'],
|
||||
},
|
||||
{
|
||||
name: '8/4',
|
||||
@ -96,6 +97,7 @@ const initialOptions: TElements<IBaseOption[]> = {
|
||||
startPositions: [0, 8],
|
||||
paymentsInStep: [8, 4],
|
||||
stepsValues: [100, 50],
|
||||
forbiddenHighSeasonStart: ['7', '8', '9'],
|
||||
},
|
||||
{
|
||||
name: '4/4/4',
|
||||
@ -103,6 +105,7 @@ const initialOptions: TElements<IBaseOption[]> = {
|
||||
startPositions: [0, 4, 8],
|
||||
paymentsInStep: [4, 4, 4],
|
||||
stepsValues: [100, 75, 50],
|
||||
forbiddenHighSeasonStart: ['11'],
|
||||
},
|
||||
{
|
||||
name: '100.50.25',
|
||||
@ -126,36 +129,10 @@ const initialOptions: TElements<IBaseOption[]> = {
|
||||
},
|
||||
],
|
||||
|
||||
selectHighSeasonStart: [
|
||||
{
|
||||
name: '2',
|
||||
value: 100000000,
|
||||
},
|
||||
{
|
||||
name: '3',
|
||||
value: 100000001,
|
||||
},
|
||||
{
|
||||
name: '4',
|
||||
value: 100000002,
|
||||
},
|
||||
{
|
||||
name: '5',
|
||||
value: 100000003,
|
||||
},
|
||||
{
|
||||
name: '6',
|
||||
value: 100000004,
|
||||
},
|
||||
{
|
||||
name: '7',
|
||||
value: 100000005,
|
||||
},
|
||||
{
|
||||
name: '8',
|
||||
value: 100000006,
|
||||
},
|
||||
],
|
||||
selectHighSeasonStart: Array.from({ length: 12 }, (_, i) => ({
|
||||
name: `${i + 2}`,
|
||||
value: 100000000 + i,
|
||||
})),
|
||||
|
||||
radioDeliveryTime: [
|
||||
{
|
||||
@ -269,8 +246,7 @@ const initialOptions: TElements<IBaseOption[]> = {
|
||||
value: 100000012,
|
||||
},
|
||||
{
|
||||
name:
|
||||
'Для экскурсионных перевозок в т.ч. на торжества; трансфер в аэропорт и пр.',
|
||||
name: 'Для экскурсионных перевозок в т.ч. на торжества; трансфер в аэропорт и пр.',
|
||||
value: 100000013,
|
||||
},
|
||||
{
|
||||
|
||||
@ -9,7 +9,7 @@ const initialStatuses: TElements<ElementStatus> = {
|
||||
selectCalcDoubleAgent: ElementStatus.Disabled,
|
||||
tbxInsKaskoPriceLeasePeriod: ElementStatus.Disabled,
|
||||
selectClientType: ElementStatus.Disabled,
|
||||
selectTelematic: ElementStatus.Disabled,
|
||||
// selectTelematic: ElementStatus.Disabled,
|
||||
tbxImporterRewardRub: ElementStatus.Disabled,
|
||||
tbxImporterRewardPerc: ElementStatus.Disabled,
|
||||
tbxMaxPriceChange: ElementStatus.Disabled,
|
||||
@ -34,7 +34,7 @@ const initialStatuses: TElements<ElementStatus> = {
|
||||
tbxCommentLead: ElementStatus.Disabled,
|
||||
btnCreateLead: ElementStatus.Disabled,
|
||||
|
||||
selectTracker: ElementStatus.Disabled,
|
||||
// selectTracker: ElementStatus.Disabled,
|
||||
|
||||
tbxVehicleTaxInLeasingPeriod: ElementStatus.Disabled,
|
||||
selectObjectTypeTax: ElementStatus.Disabled,
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
import { ICalculationStore } from 'core/types/Calculation/Store';
|
||||
import { Process } from 'core/types/Calculation/Store/process';
|
||||
import { isEmpty } from 'lodash';
|
||||
import initialOptions from '../config/initialOptions';
|
||||
import initialValues from '../config/initialValues';
|
||||
import { composeRequests } from './requests';
|
||||
@ -16,13 +17,23 @@ export default async function (this: ICalculationStore) {
|
||||
insuranceRequest,
|
||||
} = composeRequests();
|
||||
|
||||
const ownerOptions = await ownerOptionsRequest;
|
||||
const mainOptions = await mainOptionsRequest;
|
||||
this.applyOptions(Object.assign(initialOptions, ownerOptions, mainOptions));
|
||||
|
||||
const systemuser = await systemUserRequest;
|
||||
const { systemuser } = await systemUserRequest;
|
||||
const staticEntities = await staticDataRequest;
|
||||
this.applyStaticData(Object.assign({ systemuser }, staticEntities));
|
||||
this.applyStaticData(
|
||||
Object.assign({ systemuser: [systemuser] }, staticEntities),
|
||||
);
|
||||
|
||||
const ownerOptions = await ownerOptionsRequest;
|
||||
|
||||
const mainOptions = await mainOptionsRequest;
|
||||
let selectProduct = mainOptions?.selectProduct?.filter(
|
||||
x =>
|
||||
isEmpty(x.systemusers) ||
|
||||
x?.systemusers?.some(u => u?.systemuserid === systemuser?.systemuserid),
|
||||
);
|
||||
this.applyOptions(
|
||||
Object.assign(initialOptions, ownerOptions, mainOptions, { selectProduct }),
|
||||
);
|
||||
|
||||
const insuranceData = await insuranceRequest;
|
||||
this.setTableColumns('tableInsurance')({
|
||||
@ -36,13 +47,14 @@ export default async function (this: ICalculationStore) {
|
||||
);
|
||||
this.setValue('supplierCurrency', supplierCurrency?.transactioncurrencyid);
|
||||
|
||||
const evo_sot_coefficient_type = staticEntities?.evo_sot_coefficient_type?.find(
|
||||
const evo_sot_coefficient_type =
|
||||
staticEntities?.evo_sot_coefficient_type?.find(
|
||||
x => x.evo_id === 'BONUS_LEASING',
|
||||
);
|
||||
|
||||
const evo_coefficient_bonus = staticEntities?.evo_coefficient?.find(
|
||||
x =>
|
||||
x.evo_job_titleid === systemuser[0]?.evo_job_titleid &&
|
||||
x.evo_job_titleid === systemuser?.evo_job_titleid &&
|
||||
x.evo_sot_coefficient_typeid ===
|
||||
evo_sot_coefficient_type?.evo_sot_coefficient_typeid,
|
||||
);
|
||||
|
||||
@ -45,7 +45,7 @@ export function composeRequests() {
|
||||
const domainname = UserStore.getDomainName();
|
||||
|
||||
const systemUserRequest = CrmService.getCRMEntities<
|
||||
CRMEntityNames,
|
||||
'systemuser',
|
||||
ISystemUser
|
||||
>({
|
||||
query: getSystemUserQuery,
|
||||
|
||||
@ -10,5 +10,6 @@ query GetInsuranceOptions($evo_account_type: [Int!], $statecode: Int) {
|
||||
evo_id_elt_smr
|
||||
evo_id_elt_osago
|
||||
evo_legal_region_calc
|
||||
evo_inn
|
||||
}
|
||||
}
|
||||
|
||||
@ -92,6 +92,9 @@ query GetMainOptions(
|
||||
evo_name
|
||||
evo_brandid
|
||||
}
|
||||
systemusers {
|
||||
systemuserid
|
||||
}
|
||||
}
|
||||
selectRegistration: evo_addproduct_types(
|
||||
statecode: $statecode
|
||||
@ -105,6 +108,9 @@ query GetMainOptions(
|
||||
evo_description
|
||||
evo_gibdd_region
|
||||
evo_whom_register
|
||||
evo_leasingobject_types {
|
||||
evo_leasingobject_typeid
|
||||
}
|
||||
}
|
||||
selectInsNSIB: evo_addproduct_types(
|
||||
statecode: $statecode
|
||||
@ -121,6 +127,7 @@ query GetMainOptions(
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
) {
|
||||
...evo_addproduct_types_fields
|
||||
evo_visible_calc
|
||||
evo_planpayments {
|
||||
evo_name
|
||||
evo_cost_equipment_withoutnds
|
||||
@ -135,6 +142,7 @@ query GetMainOptions(
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
) {
|
||||
...evo_addproduct_types_fields
|
||||
evo_visible_calc
|
||||
evo_planpayments {
|
||||
evo_name
|
||||
evo_cost_equipment_withoutnds
|
||||
|
||||
@ -90,6 +90,8 @@ fragment quoteFields on quote {
|
||||
evo_modelid
|
||||
evo_equipmentid
|
||||
evo_engine_type
|
||||
evo_category
|
||||
|
||||
evo_power
|
||||
evo_engine_volume
|
||||
evo_use_for
|
||||
|
||||
@ -9,6 +9,7 @@ fragment quoteFieldsLite on quote {
|
||||
evo_statuscode: evo_statuscodeidData {
|
||||
evo_id
|
||||
}
|
||||
evo_min_change_price
|
||||
evo_max_price_change
|
||||
evo_max_mass
|
||||
evo_seats
|
||||
|
||||
@ -11,6 +11,7 @@ query GetMainOptionsForKP(
|
||||
# $broker_accountid: Uuid!
|
||||
# $findepartment_accountid: Uuid!
|
||||
$evo_gps_brandid: Uuid!
|
||||
$evo_agency_agreementid_param: GuidParamInput
|
||||
) {
|
||||
selectModel: evo_models(statecode: $statecode, evo_brandid: $evo_brandid) {
|
||||
evo_id
|
||||
@ -52,6 +53,7 @@ query GetMainOptionsForKP(
|
||||
evo_datefrom_param: { lte: $currentDate }
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
statecode: $statecode
|
||||
evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
) {
|
||||
evo_reward_conditionid
|
||||
evo_name
|
||||
@ -63,6 +65,7 @@ query GetMainOptionsForKP(
|
||||
evo_datefrom_param: { lte: $currentDate }
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
statecode: $statecode
|
||||
evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
) {
|
||||
evo_reward_conditionid
|
||||
evo_name
|
||||
@ -74,6 +77,7 @@ query GetMainOptionsForKP(
|
||||
# evo_datefrom_param: { lte: $currentDate }
|
||||
# evo_dateto_param: { gte: $currentDate }
|
||||
# statecode: $statecode
|
||||
# evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
# ) {
|
||||
# evo_reward_conditionid
|
||||
# evo_name
|
||||
@ -86,6 +90,7 @@ query GetMainOptionsForKP(
|
||||
evo_datefrom_param: { lte: $currentDate }
|
||||
evo_dateto_param: { gte: $currentDate }
|
||||
statecode: $statecode
|
||||
evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
) {
|
||||
evo_reward_conditionid
|
||||
evo_name
|
||||
@ -97,6 +102,7 @@ query GetMainOptionsForKP(
|
||||
# evo_datefrom_param: { lte: $currentDate }
|
||||
# evo_dateto_param: { gte: $currentDate }
|
||||
# statecode: $statecode
|
||||
# evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
# ) {
|
||||
# evo_reward_conditionid
|
||||
# evo_name
|
||||
@ -108,6 +114,7 @@ query GetMainOptionsForKP(
|
||||
# evo_datefrom_param: { lte: $currentDate }
|
||||
# evo_dateto_param: { gte: $currentDate }
|
||||
# statecode: $statecode
|
||||
# evo_agency_agreementid_param: $evo_agency_agreementid_param
|
||||
# ) {
|
||||
# evo_reward_conditionid
|
||||
# evo_name
|
||||
|
||||
@ -1,9 +1,5 @@
|
||||
query GetSingleOptionsForKP(
|
||||
$dealer_broker_accountid: Uuid!
|
||||
$hasDealerBroker: Boolean!
|
||||
) {
|
||||
selectDealerBroker: account(accountid: $dealer_broker_accountid)
|
||||
@include(if: $hasDealerBroker) {
|
||||
query GetSingleOptionsForKP($dealer_broker_accountid: Uuid!) {
|
||||
selectDealerBroker: account(accountid: $dealer_broker_accountid) {
|
||||
accountid
|
||||
name
|
||||
}
|
||||
|
||||
@ -5,5 +5,6 @@ query GetSystemUser($domainname: String) {
|
||||
firstname
|
||||
lastname
|
||||
fullname
|
||||
systemuserid
|
||||
}
|
||||
}
|
||||
|
||||
@ -105,7 +105,7 @@ type Query {
|
||||
evo_request_payment(evo_request_paymentid: Uuid!): evo_request_payment
|
||||
evo_request_payments(evo_id: String, evo_name: String, statecode: Int): [evo_request_payment]
|
||||
evo_reward_condition(evo_reward_conditionid: Uuid!): evo_reward_condition
|
||||
evo_reward_conditions(evo_agent_accountid: Uuid, evo_datefrom_param: DateParamInput, evo_dateto_param: DateParamInput, statecode: Int): [evo_reward_condition]
|
||||
evo_reward_conditions(evo_agency_agreementid_param: GuidParamInput, evo_agent_accountid: Uuid, evo_datefrom_param: DateParamInput, evo_dateto_param: DateParamInput, statecode: Int): [evo_reward_condition]
|
||||
evo_sot_coefficient_types(statecode: Int): [evo_sot_coefficient_type]
|
||||
evo_statuscode(evo_id: String, evo_statuscodeid: Uuid): evo_statuscode
|
||||
evo_statuscodes(statecode: Int): [evo_statuscode]
|
||||
@ -258,6 +258,11 @@ input ConditionInput {
|
||||
logicoperation: LogicOperation!
|
||||
}
|
||||
|
||||
input GuidParamInput {
|
||||
eq: Uuid
|
||||
has: Boolean
|
||||
}
|
||||
|
||||
"""The built-in `Decimal` scalar type."""
|
||||
scalar Decimal
|
||||
|
||||
@ -334,6 +339,7 @@ type evo_addproduct_type {
|
||||
evo_towtruck: Boolean
|
||||
evo_visible_calc: Boolean
|
||||
evo_whom_register: Int
|
||||
evo_who_register: Int
|
||||
modifiedon: DateTime
|
||||
statecode: Int
|
||||
toObjectString: String
|
||||
@ -1350,6 +1356,8 @@ type evo_contract {
|
||||
evo_ns_bonus_summ: Decimal
|
||||
evo_number_dkp: String
|
||||
evo_paymentorders(evo_name: String, statecode: Int): [evo_paymentorder]
|
||||
evo_payment_redemption_sum: Decimal
|
||||
evo_payment_redemption_sum_without_nds: Decimal
|
||||
evo_period: Int
|
||||
evo_price_without_discount: Decimal
|
||||
evo_price_without_discount_supplier_currency: Decimal
|
||||
@ -1445,6 +1453,7 @@ type evo_paymentorder {
|
||||
evo_dds_1c: String
|
||||
evo_inn_text: String
|
||||
evo_insurance_periodid: Uuid
|
||||
evo_money_transfer_paymentorderid: Uuid
|
||||
evo_name: String
|
||||
evo_paydate: DateTime
|
||||
evo_paydate_fact: DateTime
|
||||
@ -1904,6 +1913,7 @@ type evo_addcontract {
|
||||
evo_insurer_kasko_accountid_new: Uuid
|
||||
evo_insurer_osago_accountid: Uuid
|
||||
evo_insurer_osago_accountid_new: Uuid
|
||||
evo_ins_period_kasko_date: DateTime
|
||||
evo_ins_period_kasko_number: Int
|
||||
evo_ins_period_osago_date: DateTime
|
||||
evo_ins_period_osago_number: Int
|
||||
@ -2002,6 +2012,7 @@ type evo_addcontract {
|
||||
evo_registration_new: Int
|
||||
evo_registration_regionid: Uuid
|
||||
evo_registration_regionid_new: Uuid
|
||||
evo_remove_restrictions: Boolean
|
||||
evo_seats: Int
|
||||
evo_seats_new: Int
|
||||
evo_signatory_evo_systemuserid: Uuid
|
||||
|
||||
@ -149,7 +149,8 @@ export type ElementsNames =
|
||||
| 'selectLegalClientTown'
|
||||
| 'selectSubsidy'
|
||||
| 'labelSubsidySum'
|
||||
| 'selectFuelCard';
|
||||
| 'selectFuelCard'
|
||||
| 'tbxMinPriceChange';
|
||||
|
||||
export type LinkElementsNames = 'linkDownloadKp';
|
||||
|
||||
|
||||
@ -41,6 +41,7 @@ interface ICalculationValues {
|
||||
getOptions: (
|
||||
elementName: ElementsNames,
|
||||
fields?: { [field in keyof (IBaseOption & TCRMEntity)]?: any },
|
||||
filtered?: boolean,
|
||||
) => (IBaseOption & TCRMEntity)[] | undefined;
|
||||
setOptions: (
|
||||
elementName: ElementsNames,
|
||||
|
||||
@ -1,6 +1,5 @@
|
||||
export enum Process {
|
||||
Init,
|
||||
LoadKp,
|
||||
RecalcWithoutRevision,
|
||||
ELT,
|
||||
}
|
||||
|
||||
@ -135,7 +135,8 @@ export type ValuesNames =
|
||||
| 'legalClientTown'
|
||||
| 'subsidy'
|
||||
| 'subsidySum'
|
||||
| 'fuelCard';
|
||||
| 'fuelCard'
|
||||
| 'minPriceChange';
|
||||
|
||||
export type ComputedValuesNames =
|
||||
| 'leaseObjectRiskName'
|
||||
|
||||
@ -106,6 +106,7 @@ export interface IQuote extends BaseEntity {
|
||||
evo_period?: number;
|
||||
evo_first_payment_perc?: number;
|
||||
evo_last_payment_perc?: number;
|
||||
evo_min_change_price?: number;
|
||||
evo_max_price_change?: number;
|
||||
evo_max_mass?: number;
|
||||
evo_seats?: number;
|
||||
@ -125,6 +126,15 @@ export interface IQuote extends BaseEntity {
|
||||
evo_req_telematic_accept?: number;
|
||||
evo_one_year_insurance?: boolean;
|
||||
evo_payment_redemption_sum?: number;
|
||||
evo_agent_accountid?: string;
|
||||
evo_agent_reward_conditionid?: string;
|
||||
evo_agent_reward_total?: number;
|
||||
evo_broker_accountid?: string;
|
||||
evo_fin_department_reward_total?: number;
|
||||
evo_fin_department_reward_conditionid?: string;
|
||||
evo_fin_department_accountid?: string;
|
||||
evo_broker_reward_total?: number;
|
||||
evo_broker_reward_conditionid?: string;
|
||||
}
|
||||
|
||||
export interface IEvoGraph extends BaseEntity {
|
||||
@ -153,6 +163,7 @@ export interface IEvoBaseproduct extends BaseEntity {
|
||||
evo_dateto_param?: Date;
|
||||
evo_leasingobject_types?: IEvoLeasingObjectType[];
|
||||
evo_brands?: IEvoBrand[];
|
||||
systemusers?: ISystemUser[];
|
||||
}
|
||||
|
||||
export interface IEvoLeasingObjectType extends BaseEntity {
|
||||
@ -212,6 +223,7 @@ export interface IEvoRewardCondition extends BaseEntity {
|
||||
evo_double_agent_accountid?: string;
|
||||
evo_reward_summ?: number;
|
||||
evo_reduce_reward?: boolean;
|
||||
evo_agency_agreementid?: string;
|
||||
}
|
||||
|
||||
export interface IEvoGPSBrand extends BaseEntity {
|
||||
@ -318,6 +330,7 @@ export interface IEvoAddproductType extends BaseEntity {
|
||||
evo_cost_price_telematics?: number;
|
||||
evo_cost_equipment?: number;
|
||||
evo_controls_program?: number[];
|
||||
evo_visible_calc?: boolean;
|
||||
evo_helpcard_type?: number;
|
||||
evo_towtruck?: boolean;
|
||||
evo_pts_type?: number[];
|
||||
|
||||
Reference in New Issue
Block a user