Skip to content

Commit

Permalink
two windings and three windings transformers have only one site in ex… (
Browse files Browse the repository at this point in the history
#639)

* two windings and three windings transformers have only one site in expert filter

Co-authored-by: basseche <[email protected]>
Co-authored-by: Mathieu Deharbe <[email protected]>
  • Loading branch information
basseche and Mathieu-Deharbe authored Nov 27, 2024
1 parent e1ca4ca commit dd1f0ee
Show file tree
Hide file tree
Showing 5 changed files with 3 additions and 23 deletions.
1 change: 0 additions & 1 deletion src/components/filter/expert/expertFilter.type.ts
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,6 @@ export enum FieldType {
SUBSTATION_PROPERTY = 'SUBSTATION_PROPERTIES',
SUBSTATION_PROPERTY_1 = 'SUBSTATION_PROPERTIES_1',
SUBSTATION_PROPERTY_2 = 'SUBSTATION_PROPERTIES_2',
SUBSTATION_PROPERTY_3 = 'SUBSTATION_PROPERTIES_3',
VOLTAGE_LEVEL_PROPERTY = 'VOLTAGE_LEVEL_PROPERTIES',
VOLTAGE_LEVEL_PROPERTY_1 = 'VOLTAGE_LEVEL_PROPERTIES_1',
VOLTAGE_LEVEL_PROPERTY_2 = 'VOLTAGE_LEVEL_PROPERTIES_2',
Expand Down
20 changes: 2 additions & 18 deletions src/components/filter/expert/expertFilterConstants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -851,13 +851,6 @@ export const FIELDS_OPTIONS = {
valueEditorType: 'select',
defaultValue: '',
},
SUBSTATION_PROPERTY_3: {
name: FieldType.SUBSTATION_PROPERTY_3,
label: 'substationProperty3Twt',
dataType: DataType.PROPERTY,
valueEditorType: 'select',
defaultValue: '',
},
VOLTAGE_LEVEL_PROPERTY: {
name: FieldType.VOLTAGE_LEVEL_PROPERTY,
label: 'voltageLevelProperty',
Expand Down Expand Up @@ -1117,8 +1110,7 @@ export const EXPERT_FILTER_FIELDS: Record<string, Field[]> = {
FIELDS_OPTIONS.PHASE_REGULATION_MODE,
FIELDS_OPTIONS.PHASE_REGULATION_VALUE,
FIELDS_OPTIONS.PROPERTY,
FIELDS_OPTIONS.SUBSTATION_PROPERTY_1,
FIELDS_OPTIONS.SUBSTATION_PROPERTY_2,
FIELDS_OPTIONS.SUBSTATION_PROPERTY,
FIELDS_OPTIONS.VOLTAGE_LEVEL_PROPERTY_1,
FIELDS_OPTIONS.VOLTAGE_LEVEL_PROPERTY_2,
],
Expand Down Expand Up @@ -1200,15 +1192,7 @@ export const EXPERT_FILTER_FIELDS: Record<string, Field[]> = {
FIELDS_OPTIONS.PHASE_REGULATION_MODE_2,
FIELDS_OPTIONS.PHASE_REGULATION_MODE_3,
FIELDS_OPTIONS.PROPERTY,
{
...FIELDS_OPTIONS.SUBSTATION_PROPERTY_1,
label: `${FIELDS_OPTIONS.SUBSTATION_PROPERTY_1.label}Twt`,
},
{
...FIELDS_OPTIONS.SUBSTATION_PROPERTY_2,
label: `${FIELDS_OPTIONS.SUBSTATION_PROPERTY_2.label}Twt`,
},
FIELDS_OPTIONS.SUBSTATION_PROPERTY_3,
FIELDS_OPTIONS.SUBSTATION_PROPERTY,
{
...FIELDS_OPTIONS.VOLTAGE_LEVEL_PROPERTY_1,
label: `${FIELDS_OPTIONS.VOLTAGE_LEVEL_PROPERTY_1.label}Twt`,
Expand Down
3 changes: 1 addition & 2 deletions src/components/inputs/reactQueryBuilder/ValueEditor.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,7 @@ export function ValueEditor(props: ValueEditorProps) {
if (
field === FieldType.SUBSTATION_PROPERTY ||
field === FieldType.SUBSTATION_PROPERTY_1 ||
field === FieldType.SUBSTATION_PROPERTY_2 ||
field === FieldType.SUBSTATION_PROPERTY_3
field === FieldType.SUBSTATION_PROPERTY_2
) {
equipmentType = Substation.type;
} else if (
Expand Down
1 change: 0 additions & 1 deletion src/translations/en/filterExpertEn.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@ export const filterExpertEn = {
substationProperty2: 'Substation property 2',
substationProperty1Twt: 'Substation property 1',
substationProperty2Twt: 'Substation property 2',
substationProperty3Twt: 'Substation property 3',
ratedVoltage1KV: 'Rated Voltage 1 (kV)',
ratedVoltage2KV: 'Rated Voltage 2 (kV)',
ratedVoltage0KVTwt: 'Rated Voltage 0 (kV)',
Expand Down
1 change: 0 additions & 1 deletion src/translations/fr/filterExpertFr.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,6 @@ export const filterExpertFr = {
substationProperty2: 'Propriété site 2',
substationProperty1Twt: 'Propriété site 1',
substationProperty2Twt: 'Propriété site 2',
substationProperty3Twt: 'Propriété site 3',
ratedVoltage1KV: "Tension d'enroulement 1 (kV)",
ratedVoltage2KV: "Tension d'enroulement 2 (kV)",
ratedVoltage0KVTwt: "Tension d'enroulement 0 (kV)",
Expand Down

0 comments on commit dd1f0ee

Please sign in to comment.