bfg-common 1.2.208 → 1.2.210

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -981,8 +981,8 @@
981
981
  "ms": "Спадарыня",
982
982
  "mtu": "MTU",
983
983
  "mtuBytes": "MTU (байты)",
984
- "mtuInvalidError": "Значэнне MTU павінна быць у дыяпазоне ад 1280 да 9000.",
985
- "mtuInvalidMessage": "MTU павінна быць цэлым лікам ад 1280 да 9000.",
984
+ "mtuInvalidError": "Значэнне MTU павінна быць у дыяпазоне ад 1280 да 65535.",
985
+ "mtuInvalidMessage": "MTU павінна быць цэлым лікам ад 1280 да 65535.",
986
986
  "multiPathingPolicies": "Палітыкі шматшляхоў",
987
987
  "multipleItemsSelected": "Абрана некалькі элементаў",
988
988
  "multiWriter": "Мультыпісьменнік",
@@ -981,8 +981,8 @@
981
981
  "ms": "ms",
982
982
  "mtu": "MTU",
983
983
  "mtuBytes": "MTU (Bytes)",
984
- "mtuInvalidError": "The MTU value must be between 1280 and 9000.",
985
- "mtuInvalidMessage": "The MTU must be an integer number between 1280 and 9000.",
984
+ "mtuInvalidError": "The MTU value must be between 1280 and 65535.",
985
+ "mtuInvalidMessage": "The MTU must be an integer number between 1280 and 65535.",
986
986
  "multiPathingPolicies": "Multipathing Policies",
987
987
  "multipleItemsSelected": "Multiple items selected",
988
988
  "multiWriter": "Multi-writer",
@@ -981,8 +981,8 @@
981
981
  "ms": "մվ",
982
982
  "mtu": "MTU",
983
983
  "mtuBytes": "MTU (Բայթ)",
984
- "mtuInvalidError": "MTU արժեքը պետք է լինի 1280-ից 9000 միջակայքում:",
985
- "mtuInvalidMessage": "MTU-ն պետք է լինի ամբողջ թիվ 1280-ից 9000-ի սահմաններում:",
984
+ "mtuInvalidError": "MTU արժեքը պետք է լինի 1280-ից 65535 միջակայքում:",
985
+ "mtuInvalidMessage": "MTU-ն պետք է լինի ամբողջ թիվ 1280-ից 65535-ի սահմաններում:",
986
986
  "multiPathingPolicies": "Բազմակողմանի քաղաքականություն",
987
987
  "multipleItemsSelected": "Ընտրված մի քանի տարրեր",
988
988
  "multiWriter": "Բազմագիր",
@@ -981,8 +981,8 @@
981
981
  "ms": "Ханым",
982
982
  "mtu": "MTU",
983
983
  "mtuBytes": "MTU (байттар)",
984
- "mtuInvalidError": "MTU мәні 1280-ден 9000-ға дейін болуы керек.",
985
- "mtuInvalidMessage": "MTU 1280-ден 9000-ға дейінгі бүтін сан болуы керек.",
984
+ "mtuInvalidError": "MTU мәні 1280-ден 65535-ға дейін болуы керек.",
985
+ "mtuInvalidMessage": "MTU 1280-ден 65535-ға дейінгі бүтін сан болуы керек.",
986
986
  "multiPathingPolicies": "Көпжолды саясаттар",
987
987
  "multipleItemsSelected": "Бірнеше элементтер таңдалды",
988
988
  "multiWriter": "Көп жазушы",
@@ -981,8 +981,8 @@
981
981
  "ms": "мс",
982
982
  "mtu": "MTU",
983
983
  "mtuBytes": "MTU (байты)",
984
- "mtuInvalidError": "Значение MTU должно быть между 1280 и 9000.",
985
- "mtuInvalidMessage": "MTU должно быть целым числом в диапазоне от 1280 до 9000.",
984
+ "mtuInvalidError": "Значение MTU должно быть между 1280 и 65535.",
985
+ "mtuInvalidMessage": "MTU должно быть целым числом в диапазоне от 1280 до 65535.",
986
986
  "multiPathingPolicies": "Политики многопутевого доступа",
987
987
  "multipleItemsSelected": "Выбрано несколько элементов",
988
988
  "multiWriter": "Мульти-писатель",
@@ -981,8 +981,8 @@
981
981
  "ms": "多发性硬化症",
982
982
  "mtu": "MTU",
983
983
  "mtuBytes": "MTU(字节)",
984
- "mtuInvalidError": "MTU值必须在1280和9000之间。",
985
- "mtuInvalidMessage": "MTU必须是介于1280和9000之间的整数。",
984
+ "mtuInvalidError": "MTU值必须在1280和65535之间。",
985
+ "mtuInvalidMessage": "MTU必须是介于1280和65535之间的整数。",
986
986
  "multiPathingPolicies": "多路径策略",
987
987
  "multipleItemsSelected": "选择了多个项目",
988
988
  "multiWriter": "多作者",
@@ -90,7 +90,7 @@ export default class Wizard {
90
90
  setLoader(status: boolean, messages?: string[]): void {
91
91
  this._wizardLoader.value.status = status
92
92
 
93
- if (!messages && this._wizardLoader.value?.messages.length > 0) {
93
+ if (!messages && !!this._wizardLoader.value?.messages?.length) {
94
94
  this._wizardLoader.value.messages = []
95
95
  return
96
96
  }
@@ -537,11 +537,11 @@ export default class Wizard {
537
537
  }
538
538
 
539
539
  validateFieldLocal(
540
- stepId: number,
541
- field: string,
542
- rule: boolean | boolean[],
543
- fieldMessage: string | string[],
544
- alertMessage: string | string[]
540
+ stepId: number,
541
+ field: string,
542
+ rule: boolean | boolean[],
543
+ fieldMessage: string | string[],
544
+ alertMessage: string | string[]
545
545
  ): void {
546
546
  if (typeof rule === 'boolean') {
547
547
  if (rule) {
@@ -21,14 +21,13 @@
21
21
  <template #modalBody="{ selectedStep }">
22
22
  <common-wizards-network-add-steps-select-connection-type
23
23
  v-if="selectedStep.id === 0"
24
- :connection-type="connectionType"
25
- @change-connection-type="onChangeConnectionType"
24
+ v-model="connectionTypeLocal"
26
25
  />
27
26
  <common-wizards-network-add-steps-selected-target-device
28
27
  v-if="selectedStep.id === 1"
29
28
  :wizard="wizard"
30
29
  :target-device="targetDevice"
31
- :connection-type="connectionType"
30
+ :connection-type="connectionTypeLocal"
32
31
  :standard-switches-initial="props.standardSwitchesInitial"
33
32
  :messages-fields="selectedStep.fields"
34
33
  :alert-messages="alertMessages[1]"
@@ -182,12 +181,17 @@ const readyCompleteFields = ref<UI_I_ReadyCompleteFields[]>([])
182
181
  // Step's content data (connectionType)
183
182
  const connectionType = ref<string>('0')
184
183
 
185
- const onChangeConnectionType = (newConnectionType: string): void => {
186
- wizard.resetAfterSelected()
187
- connectionType.value = newConnectionType
188
- targetDevice.value.standardSwitch =
189
- props.standardSwitchesInitial?.[0]?.name || ''
190
- }
184
+ const connectionTypeLocal = computed<string>({
185
+ get() {
186
+ return connectionType.value
187
+ },
188
+ set(newValue: string) {
189
+ wizard.resetAfterSelected()
190
+ connectionType.value = newValue
191
+ targetDevice.value.standardSwitch =
192
+ props.standardSwitchesInitial?.[0]?.name || ''
193
+ },
194
+ })
191
195
 
192
196
  // Step's content data (createStandardSwitch)
193
197
  const addedAdapters = ref<string[]>([])
@@ -261,7 +265,7 @@ const onHideAlert = (stepId: number): void => {
261
265
 
262
266
  // Choosing Scheme
263
267
  watch(
264
- [connectionType, targetDevice],
268
+ [connectionTypeLocal, targetDevice],
265
269
  (newValues, oldValue) => {
266
270
  const newCT = newValues[0] // -> newConnectionType
267
271
  const oldCT = oldValue[0] // -> oldConnectionType
@@ -347,7 +351,7 @@ watch(
347
351
  // Reset data
348
352
  const reset = (): void => {
349
353
  wizard.reset()
350
- connectionType.value = '0'
354
+ connectionTypeLocal.value = '0'
351
355
  targetDevice.value = useDeepCopy(targetDeviceInitial)
352
356
  connectionSettings.value = useDeepCopy(connectionSettingsInitial)
353
357
  portProperties.value = useDeepCopy(portPropertiesInitial)
@@ -603,6 +607,7 @@ const onSubmit = async (): Promise<void> => {
603
607
  let sendData:
604
608
  | UI_I_AddNetworkingZeroOrFirstSchemeDataSend
605
609
  | UI_I_AddNetworkingSecondOrThirdSchemeDataSend
610
+ | null = null
606
611
  let type: 'network' | 'vmkernel' = 'network'
607
612
 
608
613
  if (wizard.isSelectedScheme(0) || wizard.isSelectedScheme(1)) {
@@ -630,13 +635,14 @@ const onSubmit = async (): Promise<void> => {
630
635
  )
631
636
  }
632
637
 
633
- emits(
634
- 'send-add-networking-data',
635
- sendData,
636
- type,
637
- () => wizard.setLoader(false),
638
- onHideAddNetworkingModal
639
- )
638
+ sendData &&
639
+ emits(
640
+ 'send-add-networking-data',
641
+ sendData,
642
+ type,
643
+ () => wizard.setLoader(false),
644
+ onHideAddNetworkingModal
645
+ )
640
646
  }
641
647
 
642
648
  onMounted(() => {
@@ -1,14 +1,14 @@
1
1
  <template>
2
2
  <div class="wizard-content-container add-networking-step">
3
3
  <div class="wizard-content">
4
- <form @change="onChangeConnectionType">
4
+ <form>
5
5
  <div class="radio">
6
6
  <input
7
7
  id="vmkernel-adapter"
8
8
  type="radio"
9
9
  value="0"
10
10
  name="connection-type"
11
- :checked="props.connectionType === '0'"
11
+ v-model="connectionTypeLocal"
12
12
  />
13
13
  <label for="vmkernel-adapter">
14
14
  {{ localization.vmKernelNetworkAdapter }}
@@ -23,7 +23,7 @@
23
23
  type="radio"
24
24
  value="1"
25
25
  name="connection-type"
26
- :checked="props.connectionType === '1'"
26
+ v-model="connectionTypeLocal"
27
27
  />
28
28
  <label for="virtual">
29
29
  {{ localization.virtualMachinePortGroupStandardSwitch }}
@@ -38,7 +38,7 @@
38
38
  type="radio"
39
39
  value="2"
40
40
  name="connection-type"
41
- :checked="props.connectionType === '2'"
41
+ v-model="connectionTypeLocal"
42
42
  />
43
43
  <label for="physical-adapter">
44
44
  {{ localization.physicalNetworkAdapter }}
@@ -56,18 +56,23 @@
56
56
  import { UI_I_Localization } from '~/models/interfaces'
57
57
 
58
58
  const props = defineProps<{
59
- connectionType: string
59
+ modelValue: string
60
60
  }>()
61
61
 
62
62
  const localization = computed<UI_I_Localization>(() => useLocal())
63
63
 
64
64
  const emits = defineEmits<{
65
- (event: 'change-connection-type', connectionType: string): void
65
+ (event: 'update:model-value', connectionType: string): void
66
66
  }>()
67
- const onChangeConnectionType = (newConnectionType: Event): void => {
68
- const target = newConnectionType.target as HTMLFormElement
69
- emits('change-connection-type', target?.value)
70
- }
67
+
68
+ const connectionTypeLocal = computed<string>({
69
+ get() {
70
+ return props.modelValue
71
+ },
72
+ set(newValue: string) {
73
+ emits('update:model-value', newValue)
74
+ },
75
+ })
71
76
  </script>
72
77
 
73
78
  <style scoped lang="scss">
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "bfg-common",
3
3
  "private": false,
4
- "version": "1.2.208",
4
+ "version": "1.2.210",
5
5
  "scripts": {
6
6
  "build": "nuxt build",
7
7
  "dev": "nuxt dev --port=3002",