bfg-common 1.5.211 → 1.5.212

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.
Files changed (192) hide show
  1. package/CODE_STYLE.md +109 -109
  2. package/assets/img/icons/icons-sprite-dark-3.svg +227 -227
  3. package/assets/img/icons/icons-sprite-dark-5.svg +488 -488
  4. package/assets/img/icons/icons-sprite-light-3.svg +227 -227
  5. package/assets/img/icons/icons-sprite-light-5.svg +488 -488
  6. package/components/atoms/TheIcon3.vue +50 -50
  7. package/components/atoms/perPage/PerPage.vue +58 -58
  8. package/components/atoms/table/dataGrid/lib/config/settingsTable.ts +94 -94
  9. package/components/atoms/table/dataGrid/lib/utils/export.ts +16 -16
  10. package/components/atoms/tabs/VerticalTabs.vue +105 -105
  11. package/components/common/backup/lib/utils/getBackupOrBackupStorageId.ts +29 -0
  12. package/components/common/backup/storage/actions/add/Add.vue +36 -0
  13. package/components/common/backup/storage/actions/add/temp/Add.vue +508 -0
  14. package/components/common/backup/storage/actions/add/temp/lib/config/stepItems.ts +203 -0
  15. package/components/common/backup/storage/actions/add/temp/lib/models/interfaces.ts +58 -0
  16. package/components/common/backup/storage/actions/add/temp/lib/models/types.ts +14 -0
  17. package/components/common/backup/storage/actions/add/temp/lib/utils.ts +70 -0
  18. package/components/common/backup/storage/actions/add/temp/local/Local.vue +65 -0
  19. package/components/common/backup/storage/actions/add/temp/local/createName/CreateName.vue +158 -0
  20. package/components/common/backup/storage/actions/add/temp/local/createName/lib/config/defaultForm.ts +15 -0
  21. package/components/common/backup/storage/actions/add/temp/nfs/Nfs.vue +106 -0
  22. package/components/common/backup/storage/actions/add/temp/nfs/accessibility/Accessibility.vue +104 -0
  23. package/components/common/backup/storage/actions/add/temp/nfs/accessibility/lib/config/tabsPannel.ts +25 -0
  24. package/components/common/backup/storage/actions/add/temp/nfs/accessibility/lib/models/interfaces.ts +9 -0
  25. package/components/common/backup/storage/actions/add/temp/nfs/accessibility/lib/models/types.ts +5 -0
  26. package/components/common/backup/storage/actions/add/temp/nfs/accessibility/tablesView/TablesView.vue +141 -0
  27. package/components/common/backup/storage/actions/add/temp/nfs/accessibility/tablesView/lib/config/compatibleTable.ts +62 -0
  28. package/components/common/backup/storage/actions/add/temp/nfs/accessibility/tablesView/lib/config/hostsTableItems.ts +53 -0
  29. package/components/common/backup/storage/actions/add/temp/nfs/accessibility/tablesView/lib/config/incompatibleTable.ts +68 -0
  30. package/components/common/backup/storage/actions/add/temp/nfs/accessibility/tablesView/lib/config/tableKeys.ts +15 -0
  31. package/components/common/backup/storage/actions/add/temp/nfs/configuration/Configuration.vue +469 -0
  32. package/components/common/backup/storage/actions/add/temp/nfs/configuration/lib/config/defaultForm.ts +51 -0
  33. package/components/common/backup/storage/actions/add/temp/nfs/configuration/lib/models/interfaces.ts +14 -0
  34. package/components/common/backup/storage/actions/add/temp/nfs/configuration/serversList/DeletePopover.vue +99 -0
  35. package/components/common/backup/storage/actions/add/temp/nfs/configuration/serversList/ServersList.vue +125 -0
  36. package/components/common/backup/storage/actions/add/temp/nfs/configuration/serversList/lib/config/serversListConfig.ts +40 -0
  37. package/components/common/backup/storage/actions/add/temp/nfs/configuration/serversList/lib/config/tableKeys.ts +3 -0
  38. package/components/common/backup/storage/actions/add/temp/nfs/configuration/serversList/lib/models/interfaces.ts +13 -0
  39. package/components/common/backup/storage/actions/add/temp/nfs/configuration/serversList/lib/models/types.ts +1 -0
  40. package/components/common/backup/storage/actions/add/temp/nfs/kerberosAuthentication/KerberosAuthentication.vue +55 -0
  41. package/components/common/backup/storage/actions/add/temp/nfs/kerberosAuthentication/lib/config/radioOptions.ts +27 -0
  42. package/components/common/backup/storage/actions/add/temp/nfs/version/Version.vue +42 -0
  43. package/components/common/backup/storage/actions/add/temp/nfs/version/lib/config/versionOptions.ts +22 -0
  44. package/components/common/backup/storage/actions/add/temp/readyComplete/ReadyComplete.vue +85 -0
  45. package/components/common/backup/storage/actions/add/temp/readyComplete/lib/config/propertiesDetails.ts +139 -0
  46. package/components/common/backup/storage/actions/add/temp/readyComplete/lib/models/interfaces.ts +4 -0
  47. package/components/common/backup/storage/actions/add/temp/samba/Samba.vue +95 -0
  48. package/components/common/backup/storage/actions/add/temp/samba/accessibility/Accessibility.vue +104 -0
  49. package/components/common/backup/storage/actions/add/temp/samba/accessibility/lib/config/tabsPannel.ts +25 -0
  50. package/components/common/backup/storage/actions/add/temp/samba/accessibility/lib/models/interfaces.ts +9 -0
  51. package/components/common/backup/storage/actions/add/temp/samba/accessibility/lib/models/types.ts +5 -0
  52. package/components/common/backup/storage/actions/add/temp/samba/accessibility/tablesView/TablesView.vue +141 -0
  53. package/components/common/backup/storage/actions/add/temp/samba/accessibility/tablesView/lib/config/compatibleTable.ts +62 -0
  54. package/components/common/backup/storage/actions/add/temp/samba/accessibility/tablesView/lib/config/hostsTableItems.ts +53 -0
  55. package/components/common/backup/storage/actions/add/temp/samba/accessibility/tablesView/lib/config/incompatibleTable.ts +68 -0
  56. package/components/common/backup/storage/actions/add/temp/samba/accessibility/tablesView/lib/config/tableKeys.ts +15 -0
  57. package/components/common/backup/storage/actions/add/temp/samba/configuration/Configuration.vue +470 -0
  58. package/components/common/backup/storage/actions/add/temp/samba/configuration/lib/config/defaultForm.ts +51 -0
  59. package/components/common/backup/storage/actions/add/temp/samba/configuration/lib/models/interfaces.ts +14 -0
  60. package/components/common/backup/storage/actions/add/temp/samba/configuration/serversList/DeletePopover.vue +99 -0
  61. package/components/common/backup/storage/actions/add/temp/samba/configuration/serversList/ServersList.vue +124 -0
  62. package/components/common/backup/storage/actions/add/temp/samba/configuration/serversList/lib/config/serversListConfig.ts +40 -0
  63. package/components/common/backup/storage/actions/add/temp/samba/configuration/serversList/lib/config/tableKeys.ts +3 -0
  64. package/components/common/backup/storage/actions/add/temp/samba/configuration/serversList/lib/models/interfaces.ts +13 -0
  65. package/components/common/backup/storage/actions/add/temp/samba/configuration/serversList/lib/models/types.ts +1 -0
  66. package/components/common/backup/storage/actions/add/temp/samba/kerberosAuthentication/KerberosAuthentication.vue +55 -0
  67. package/components/common/backup/storage/actions/add/temp/samba/kerberosAuthentication/lib/config/radioOptions.ts +27 -0
  68. package/components/common/backup/storage/actions/add/temp/sharedStorm/SharedStorm.vue +80 -0
  69. package/components/common/backup/storage/actions/add/temp/sharedStorm/createName/CreateName.vue +156 -0
  70. package/components/common/backup/storage/actions/add/temp/sharedStorm/createName/lib/config/defaultForm.ts +15 -0
  71. package/components/common/backup/storage/actions/add/temp/sharedStorm/storage/Storage.vue +71 -0
  72. package/components/common/backup/storage/actions/add/temp/sharedStorm/storage/lib/config/defaultForm.ts +15 -0
  73. package/components/common/backup/storage/actions/add/temp/types/Types.vue +78 -0
  74. package/components/common/backup/storage/actions/add/temp/types/lib/config/typeOptions.ts +52 -0
  75. package/components/common/backup/storage/actions/delete/Delete.vue +65 -0
  76. package/components/common/backup/storage/actions/delete/lib/models/interfaces.ts +5 -0
  77. package/components/common/browse/blocks/contents/filesNew/Skeleton.vue +18 -18
  78. package/components/common/context/lib/models/interfaces.ts +31 -31
  79. package/components/common/diagramMain/DiagramMain.vue +897 -897
  80. package/components/common/diagramMain/Header.vue +214 -214
  81. package/components/common/layout/theHeader/helpMenu/About.vue +82 -82
  82. package/components/common/layout/theHeader/userMenu/modals/preferences/view/ViewOld.vue +112 -112
  83. package/components/common/monitor/overview/OverviewOld.vue +139 -139
  84. package/components/common/pages/home/headline/Headline.vue +45 -45
  85. package/components/common/pages/home/headline/HeadlineOld.vue +42 -42
  86. package/components/common/pages/home/lib/models/interfaces.ts +48 -48
  87. package/components/common/pages/home/widgets/Widgets.vue +49 -49
  88. package/components/common/pages/home/widgets/WidgetsNew.vue +86 -86
  89. package/components/common/pages/home/widgets/WidgetsOld.vue +34 -34
  90. package/components/common/pages/home/widgets/hosts/Hosts.vue +27 -27
  91. package/components/common/pages/home/widgets/hosts/lib/config/items.ts +23 -23
  92. package/components/common/pages/home/widgets/vms/Vms.vue +26 -26
  93. package/components/common/pages/home/widgets/vms/VmsOld.vue +35 -35
  94. package/components/common/pages/home/widgets/vms/lib/config/items.ts +19 -19
  95. package/components/common/pages/packages/Packages.vue +208 -208
  96. package/components/common/pages/shortcuts/block/BlockNew.vue +2 -7
  97. package/components/common/pages/shortcuts/block/BlockOld.vue +68 -68
  98. package/components/common/readyToComplete/ReadyToComplete.vue +17 -17
  99. package/components/common/recursionTree/RecursionTree.vue +223 -223
  100. package/components/common/select/button/ButtonDropdown.vue +108 -108
  101. package/components/common/spiceConsole/Drawer.vue +377 -377
  102. package/components/common/spiceConsole/lib/models/interfaces.ts +5 -5
  103. package/components/common/vm/actions/add/folderTreeView/FolderTreeView.vue +72 -72
  104. package/components/common/vm/actions/add/folderTreeView/New.vue +40 -40
  105. package/components/common/vm/actions/add/folderTreeView/Old.vue +50 -50
  106. package/components/common/vm/actions/add/lib/config/steps.ts +263 -263
  107. package/components/common/vm/actions/clone/lib/config/steps.ts +291 -291
  108. package/components/common/vm/actions/clone/toTemplate/lib/config/steps.ts +116 -116
  109. package/components/common/vm/actions/common/customizeHardware/CustomizeHardwareNew.vue +337 -337
  110. package/components/common/vm/actions/common/customizeHardware/virtualHardware/VirtualHardwareNew.vue +480 -480
  111. package/components/common/vm/actions/common/customizeHardware/virtualHardware/VirtualHardwareOld.vue +319 -319
  112. package/components/common/vm/actions/common/customizeHardware/virtualHardware/browseView/BrowseView.vue +219 -219
  113. package/components/common/vm/actions/common/customizeHardware/virtualHardware/bus/Bus.vue +100 -100
  114. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/CdDvdDrive.vue +232 -232
  115. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/CdDvdDriveOld.vue +168 -168
  116. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/media/Media.vue +25 -25
  117. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/media/MediaNew.vue +78 -78
  118. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cdDvdDrive/media/MediaOld.vue +50 -50
  119. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/CpuNew.vue +190 -190
  120. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/model/ModelNew.vue +237 -237
  121. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/shares/Shares.vue +140 -140
  122. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/shares/lib/config/options.ts +28 -28
  123. package/components/common/vm/actions/common/customizeHardware/virtualHardware/cpu/tooltip/TooltipNew.vue +154 -154
  124. package/components/common/vm/actions/common/customizeHardware/virtualHardware/limit/Limit.vue +220 -220
  125. package/components/common/vm/actions/common/customizeHardware/virtualHardware/memory/Memory.vue +307 -307
  126. package/components/common/vm/actions/common/customizeHardware/virtualHardware/memory/MemoryNew.vue +154 -154
  127. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/NewHardDisk.vue +382 -382
  128. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/location/Location.vue +151 -151
  129. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/location/LocationNew.vue +73 -73
  130. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newHardDisk/location/LocationOld.vue +83 -83
  131. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newNetwork/NewNetwork.vue +288 -288
  132. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newNetwork/location/new/table/lib/config/config.ts +94 -94
  133. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newNetwork/macAddress/MacAddress.vue +119 -119
  134. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/NewPciDevice.vue +205 -205
  135. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/directPathIo/DirectPathIoNew.vue +66 -66
  136. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/directPathIo/DirectPathIoOld.vue +62 -62
  137. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/dynamicDirectPathIo/DynamicDirectPathIo.vue +31 -31
  138. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/dynamicDirectPathIo/DynamicDirectPathIoOld.vue +76 -76
  139. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/note/Note.vue +15 -15
  140. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/note/NoteNew.vue +42 -42
  141. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/note/NoteOld.vue +30 -30
  142. package/components/common/vm/actions/common/customizeHardware/virtualHardware/newPciDevice/nvidiaGrid/NvidiaGridOld.vue +84 -84
  143. package/components/common/vm/actions/common/customizeHardware/virtualHardware/other/Other.vue +16 -16
  144. package/components/common/vm/actions/common/customizeHardware/virtualHardware/other/OtherNew.vue +30 -30
  145. package/components/common/vm/actions/common/customizeHardware/virtualHardware/other/inputDevices/InputDevicesNew.vue +40 -40
  146. package/components/common/vm/actions/common/customizeHardware/vmoptions/Vmoptions.vue +145 -145
  147. package/components/common/vm/actions/common/customizeHardware/vmoptions/VmoptionsNew.vue +106 -106
  148. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/BootOptionsNew.vue +81 -81
  149. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/delay/Delay.vue +32 -32
  150. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/firmware/Firmware.vue +60 -60
  151. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/order/Order.vue +174 -174
  152. package/components/common/vm/actions/common/customizeHardware/vmoptions/bootOptions/order/OrderNew.vue +67 -67
  153. package/components/common/vm/actions/common/customizeHardware/vmoptions/generalOptions/GeneralOptionsNew.vue +149 -149
  154. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/New.vue +140 -140
  155. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/copyPaste/CopyPasteNew.vue +31 -31
  156. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/fileTransfer/FileTransferNew.vue +31 -31
  157. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/keymap/Keymap.vue +32 -32
  158. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/Password.vue +103 -103
  159. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/password/PasswordNew.vue +128 -128
  160. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/usbRedirection/UsbRedirection.vue +28 -28
  161. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/usbRedirection/UsbRedirectionNew.vue +39 -39
  162. package/components/common/vm/actions/common/customizeHardware/vmoptions/remoteConsoleOptions/usbRedirection/UsbRedirectionOld.vue +44 -44
  163. package/components/common/vm/actions/common/lib/utils/capabilities.ts +52 -52
  164. package/components/common/vm/actions/common/select/compatibility/Old.vue +107 -107
  165. package/components/common/vm/actions/common/select/computeResource/ComputeResource.vue +134 -134
  166. package/components/common/vm/actions/common/select/computeResource/treeView/New.vue +44 -44
  167. package/components/common/vm/actions/common/select/computeResource/treeView/TreeView.vue +118 -118
  168. package/components/common/vm/actions/common/select/createType/CreateType.vue +38 -38
  169. package/components/common/vm/actions/common/select/createType/New.vue +84 -84
  170. package/components/common/vm/actions/common/select/createType/lib/models/interfaces.ts +5 -5
  171. package/components/common/vm/actions/common/select/name/Name.vue +167 -167
  172. package/components/common/vm/actions/common/select/os/New.vue +122 -122
  173. package/components/common/vm/actions/common/select/os/Old.vue +152 -152
  174. package/components/common/vm/actions/common/select/os/Os.vue +139 -139
  175. package/components/common/vm/actions/common/select/storage/new/lib/models/interfaces.ts +5 -5
  176. package/components/common/vm/actions/common/select/storage/new/lib/utils/utils.ts +21 -21
  177. package/components/common/vm/actions/editSettings/new/Skeleton.vue +88 -88
  178. package/components/common/wizards/vm/migrate/lib/config/constructDataReady.ts +220 -220
  179. package/components/common/wizards/vm/migrate/lib/config/steps.ts +157 -157
  180. package/components/common/wizards/vm/migrate/lib/validations.ts +68 -68
  181. package/components/common/wizards/vm/migrate/select/computeResource/tableView/TableView.vue +137 -137
  182. package/components/common/wizards/vm/migrate/select/network/Network.vue +103 -103
  183. package/components/common/wizards/vm/migrate/select/network/table/network/lib/config/advancedTable.ts +91 -91
  184. package/composables/productNameLocal.ts +30 -30
  185. package/composables/useAppVersion.ts +21 -21
  186. package/package.json +1 -1
  187. package/plugins/date.ts +233 -233
  188. package/public/spice-console/lib/images/bitmap.js +203 -203
  189. package/public/spice-console/network/spicechannel.js +387 -387
  190. package/store/main/mutations.ts +7 -7
  191. package/store/main/state.ts +7 -7
  192. package/store/tasks/mappers/recentTasks.ts +64 -64
@@ -0,0 +1,469 @@
1
+ <template>
2
+ <div class="configuration flex flex-col justify-between h-full">
3
+ <div>
4
+ <atoms-alert
5
+ v-show="errors.length"
6
+ test-id="configuration-error"
7
+ status="alert-danger"
8
+ :items="errors"
9
+ @remove="onCloseAlertDanger"
10
+ />
11
+
12
+ <atoms-alert
13
+ v-show="alertInfo"
14
+ test-id="configuration-info"
15
+ status="alert-info"
16
+ :items="[localization.common.nameAndConfigurationAlertInfo]"
17
+ @remove="alertInfo = false"
18
+ />
19
+ <h6 class="nd-mt-0">{{ localization.common.nfsShareDetails }}</h6>
20
+
21
+ <div class="clr-form-control clr-row flex flex-row">
22
+ <label for="" class="clr-control-label clr-col-md-2">{{
23
+ localization.common.name
24
+ }}</label>
25
+
26
+ <div
27
+ class="clr-control-container"
28
+ :class="nameErrorText && 'clr-error'"
29
+ >
30
+ <div class="flex-align-center">
31
+ <input
32
+ id="configuration-name-input"
33
+ v-model="form.name.value"
34
+ data-id="configuration-name-input"
35
+ type="text"
36
+ class="clr-input"
37
+ @blur="onBlurInputName"
38
+ @input="onInputName"
39
+ />
40
+ <atoms-the-icon class="error-icon" name="info-circle" />
41
+ </div>
42
+
43
+ <div class="clr-subtext ng-star-inserted">
44
+ {{ nameErrorText }}
45
+ </div>
46
+ </div>
47
+ </div>
48
+
49
+ <div class="clr-form-control clr-row flex flex-row">
50
+ <label class="clr-control-label clr-col-md-2">{{
51
+ localization.common.folder
52
+ }}</label>
53
+
54
+ <div
55
+ class="clr-control-container"
56
+ :class="folderErrorText && 'clr-error'"
57
+ >
58
+ <div class="flex-align-center">
59
+ <input
60
+ id="configuration-folder-input"
61
+ v-model="form.folder.value"
62
+ data-id="configuration-folder-input"
63
+ type="text"
64
+ class="clr-input"
65
+ @blur="onBlurInputFolder"
66
+ @input="onInputFolder"
67
+ />
68
+ <atoms-the-icon class="error-icon" name="info-circle" />
69
+ </div>
70
+
71
+ <div v-if="folderErrorText" class="clr-subtext">
72
+ {{ folderErrorText }}
73
+ </div>
74
+ <div v-else class="clr-subtext">E.g: /vols/vol0/datastore-001</div>
75
+ </div>
76
+ </div>
77
+
78
+ <div class="nd-mt-0 clr-form-control clr-row flex flex-row">
79
+ <label class="clr-control-label clr-col-md-2">{{
80
+ localization.common.server
81
+ }}</label>
82
+
83
+ <div
84
+ class="clr-control-container"
85
+ :class="serverErrorText && 'clr-error'"
86
+ >
87
+ <div class="flex-align-center input-action-wrapper">
88
+ <input
89
+ id="configuration-server-input"
90
+ v-model="form.server.value"
91
+ data-id="configuration-server-input"
92
+ type="text"
93
+ class="clr-input"
94
+ @blur="onBlurInputServer"
95
+ @input="onInputServer"
96
+ />
97
+ <atoms-the-icon class="error-icon" name="info-circle" />
98
+ </div>
99
+ <div v-if="serverErrorText" class="clr-subtext">
100
+ {{ serverErrorText }}
101
+ </div>
102
+ <div v-else class="clr-subtext">
103
+ E.g: nas, nas.it.com or 192.168.0.1
104
+ </div>
105
+ </div>
106
+
107
+ <!-- <button-->
108
+ <!-- v-show="props.nfsVersion === 'nfs-4.1' && false"-->
109
+ <!-- class="btn btn-sm nd-mt-0"-->
110
+ <!-- @click="onAddServerToList"-->
111
+ <!-- >-->
112
+ <!-- {{ localization.common.add }}-->
113
+ <!-- </button>-->
114
+ </div>
115
+ <div class="clr-form-control clr-row flex flex-row">
116
+ <label class="clr-control-label clr-col-md-2">{{
117
+ localization.auth.username
118
+ }}</label>
119
+
120
+ <div
121
+ class="clr-control-container"
122
+ :class="usernameErrorText && 'clr-error'"
123
+ >
124
+ <div class="flex-align-center input-action-wrapper">
125
+ <input
126
+ id="configuration-username-input"
127
+ v-model="form.username.value"
128
+ data-id="configuration-username-input"
129
+ type="text"
130
+ class="clr-input"
131
+ @blur="onBlurInputUsername"
132
+ @input="onInputUsername"
133
+ />
134
+ <atoms-the-icon class="error-icon" name="info-circle" />
135
+ </div>
136
+ <div v-if="usernameErrorText" class="clr-subtext">
137
+ {{ usernameErrorText }}
138
+ </div>
139
+ </div>
140
+ </div>
141
+
142
+ <div class="clr-form-control clr-row flex flex-row">
143
+ <label class="clr-control-label clr-col-md-2">{{
144
+ localization.auth.password
145
+ }}</label>
146
+
147
+ <div
148
+ class="clr-control-container"
149
+ :class="passwordErrorText && 'clr-error'"
150
+ >
151
+ <div class="flex-align-center input-action-wrapper">
152
+ <input
153
+ id="configuration-password-input"
154
+ v-model="form.password.value"
155
+ data-id="configuration-password-input"
156
+ type="password"
157
+ class="clr-input"
158
+ @blur="onBlurInputPassword"
159
+ @input="onInputPassword"
160
+ />
161
+ <atoms-the-icon class="error-icon" name="info-circle" />
162
+ </div>
163
+ <div v-if="passwordErrorText" class="clr-subtext">
164
+ {{ passwordErrorText }}
165
+ </div>
166
+ </div>
167
+ </div>
168
+
169
+ <div
170
+ v-show="props.nfsVersion === 'nfs-4.1' && false"
171
+ class="configuration__servers-list"
172
+ >
173
+ <common-backup-storage-actions-add-temp-configuration-servers-list
174
+ v-model:data-table="dataServers"
175
+ />
176
+ </div>
177
+ </div>
178
+
179
+ <div v-if="false" class="clr-form-control clr-row mt-1 flex flex-row">
180
+ <label for="" class="clr-control-label clr-col-md-2">{{
181
+ localization.common.accessMode
182
+ }}</label>
183
+
184
+ <div class="clr-col-md-10 clr-col-12 clr-checkbox-wrapper">
185
+ <input
186
+ id="playback-compression"
187
+ v-model="accessMode"
188
+ data-id="playback-compression-checkbox"
189
+ type="checkbox"
190
+ />
191
+ <label for="playback-compression" class="clr-control-label">{{
192
+ localization.common.mountNfsReadOnly
193
+ }}</label>
194
+ </div>
195
+ </div>
196
+ </div>
197
+ </template>
198
+
199
+ <script lang="ts" setup>
200
+ import type { UI_I_ValidationTouchResult } from '~/lib/models/plugins/validation/interfaces'
201
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
202
+ import type {
203
+ UI_T_NfsType,
204
+ UI_T_WizardDatastoreMode,
205
+ } from '~/components/common/backup/storage/actions/add/temp/lib/models/types'
206
+ import type {
207
+ UI_I_DataServersListItem,
208
+ UI_I_FormValidationConfiguration,
209
+ } from '~/components/common/backup/storage/actions/add/temp/nfs/configuration/serversList/lib/models/interfaces'
210
+ import type { UI_I_ConfigurationSendDataNfs } from '~/components/common/backup/storage/actions/add/temp/nfs/configuration/lib/models/interfaces'
211
+ import { defaultFormFunc } from '~/components/common/backup/storage/actions/add/temp/nfs/configuration/lib/config/defaultForm'
212
+ import { checkValidityName } from '~/components/common/backup/storage/actions/add/temp/lib/utils'
213
+
214
+ const props = defineProps<{
215
+ mode: UI_T_WizardDatastoreMode
216
+ nfsVersion: UI_T_NfsType
217
+ nfsConfigurationSubmit: number
218
+ }>()
219
+ const localization = computed<UI_I_Localization>(() => useLocal())
220
+ const emits = defineEmits<{
221
+ (event: 'loading', value: boolean): void
222
+ (event: 'next', value: UI_I_ConfigurationSendDataNfs): void
223
+ }>()
224
+ const { $validation } = useNuxtApp()
225
+
226
+ const validation = $validation.call({})
227
+ const defaultForm: UI_I_FormValidationConfiguration = defaultFormFunc(
228
+ localization.value
229
+ )
230
+ const form = ref<UI_I_FormValidationConfiguration>(useDeepCopy(defaultForm))
231
+ const setForm = (): void => {
232
+ form.value = useDeepCopy(defaultForm)
233
+ validation.setForm(form)
234
+ }
235
+ setForm()
236
+
237
+ const validForm = ref<UI_I_ValidationTouchResult | null>(null)
238
+
239
+ /* Validation for Name input */
240
+ const isInitNameValidation = ref<boolean>(false)
241
+ const onBlurInputName = (): void => {
242
+ validForm.value = validation.touch()
243
+ isInitNameValidation.value = true
244
+ }
245
+ const onInputName = (): void => {
246
+ validForm.value = validation.touch()
247
+ }
248
+
249
+ const nameErrorText = computed<string>(() => {
250
+ if (!isInitNameValidation.value) return ''
251
+ return validForm.value?.errors?.name?.[0] || ''
252
+ })
253
+ /* Validation Name input end */
254
+
255
+ /* Validation for Folder input */
256
+ const isInitFolderValidation = ref<boolean>(false)
257
+ const onBlurInputFolder = (): void => {
258
+ validForm.value = validation.touch()
259
+ isInitFolderValidation.value = true
260
+ }
261
+ const onInputFolder = (): void => {
262
+ validForm.value = validation.touch()
263
+ }
264
+
265
+ const folderErrorText = computed<string>(() => {
266
+ if (!isInitFolderValidation.value) return ''
267
+ return validForm.value?.errors?.folder?.[0] || ''
268
+ })
269
+ /* Validation Folder input end */
270
+
271
+ /* Validation for Server input */
272
+ const isInitServerValidation = ref<boolean>(false)
273
+ const onBlurInputServer = (): void => {
274
+ validForm.value = validation.touch()
275
+ isInitServerValidation.value = true
276
+ }
277
+ const onInputServer = (): void => {
278
+ validForm.value = validation.touch()
279
+ isInitServerValidation.value = true
280
+ }
281
+
282
+ const serverErrorText = computed<string>(() => {
283
+ // if (!isInitServerValidation.value || dataServers.value.length) return ''
284
+ if (!isInitServerValidation.value) return ''
285
+ return validForm.value?.errors?.server?.[0] || ''
286
+ })
287
+
288
+ /* Validation Folder Server end */
289
+
290
+ /* Validation for Username input */
291
+ const isInitUsernameValidation = ref<boolean>(false)
292
+ const onBlurInputUsername = (): void => {
293
+ validForm.value = validation.touch()
294
+ isInitUsernameValidation.value = true
295
+ }
296
+ const onInputUsername = (): void => {
297
+ validForm.value = validation.touch()
298
+ isInitUsernameValidation.value = true
299
+ }
300
+
301
+ const usernameErrorText = computed<string>(() => {
302
+ if (!isInitUsernameValidation.value) return ''
303
+ return validForm.value?.errors?.username?.[0] || ''
304
+ })
305
+ /* Validation Username end */
306
+
307
+ /* Validation for Password input */
308
+ const isInitPasswordValidation = ref<boolean>(false)
309
+ const onBlurInputPassword = (): void => {
310
+ validForm.value = validation.touch()
311
+ isInitPasswordValidation.value = true
312
+ }
313
+ const onInputPassword = (): void => {
314
+ validForm.value = validation.touch()
315
+ isInitPasswordValidation.value = true
316
+ }
317
+
318
+ const passwordErrorText = computed<string>(() => {
319
+ if (!isInitPasswordValidation.value) return ''
320
+ return validForm.value?.errors?.password?.[0] || ''
321
+ })
322
+ /* Validation Password end */
323
+
324
+ const accessMode = ref<boolean>(false)
325
+
326
+ const dataServers = ref<UI_I_DataServersListItem[]>([])
327
+ // const onAddServerToList = (): void => {
328
+ // const { server } = form.value
329
+ // // const { nfsVersion } = props
330
+ //
331
+ // if (!dataServers.value.length && !server.value) {
332
+ // validForm.value = validation.touch()
333
+ // isInitServerValidation.value = true
334
+ //
335
+ // return
336
+ // }
337
+ //
338
+ // // if (dataServers.value.length && !server.value) return
339
+ //
340
+ // const data: UI_I_DataServersListItem = {
341
+ // server_name: server.value,
342
+ // }
343
+ //
344
+ // const hasEqualItem = !!dataServers.value.find(
345
+ // (server: UI_I_DataServersListItem) => server.server_name === data.server_name
346
+ // )
347
+ //
348
+ // !hasEqualItem && dataServers.value.push(data)
349
+ //
350
+ // // if (nfsVersion === 'nfs-4.1') server.value = ''
351
+ // }
352
+
353
+ const alertInfo = ref<boolean>(props.mode === 'procurator')
354
+
355
+ const resetValidation = (): void => {
356
+ isInitNameValidation.value =
357
+ isInitFolderValidation.value =
358
+ isInitServerValidation.value =
359
+ false
360
+ validForm.value = null
361
+ errors.value = []
362
+ }
363
+
364
+ watch(
365
+ () => props.nfsConfigurationSubmit,
366
+ () => {
367
+ submit()
368
+ }
369
+ )
370
+ const submit = async (): Promise<void> => {
371
+ const { name, server, folder, username, password } = form.value
372
+
373
+ validForm.value = validation.touch()
374
+ isInitNameValidation.value =
375
+ isInitFolderValidation.value =
376
+ isInitServerValidation.value =
377
+ true
378
+
379
+ if (nameErrorText.value || folderErrorText.value || serverErrorText.value) {
380
+ return
381
+ }
382
+
383
+ emits('loading', true)
384
+
385
+ const { valid, msg } = await checkValidityName(name.value, props.mode)
386
+
387
+ emits('loading', false)
388
+
389
+ if (!valid) {
390
+ showValidationErrors(msg)
391
+ return
392
+ }
393
+
394
+ // if (server.value) onAddServerToList()
395
+
396
+ resetValidation()
397
+
398
+ const configurationData: UI_I_ConfigurationSendDataNfs = {
399
+ name: name.value,
400
+ folder: folder.value,
401
+ server: server.value,
402
+ user: username.value,
403
+ password: password.value,
404
+ }
405
+
406
+ emits('next', configurationData)
407
+ // if (props.nfsVersion !== 'nfs-4.1') {
408
+ // dataServers.value = []
409
+ // }
410
+ }
411
+
412
+ const errors = ref<string[]>([])
413
+
414
+ const showValidationErrors = (errorText: string): void => {
415
+ errors.value = [errorText]
416
+ }
417
+ const onCloseAlertDanger = (): void => {
418
+ errors.value = []
419
+ }
420
+ </script>
421
+
422
+ <style lang="scss" scoped>
423
+ .configuration {
424
+ & > h6 {
425
+ font-weight: 500;
426
+ font-size: 14px;
427
+ padding-top: 6px;
428
+ }
429
+
430
+ &__alert-info {
431
+ :deep(.alert-text) {
432
+ font-size: 11px;
433
+ letter-spacing: normal;
434
+ }
435
+ }
436
+ .clr-form-control {
437
+ margin-top: 0;
438
+
439
+ .clr-control-container {
440
+ min-height: 48px;
441
+ &.clr-error {
442
+ .clr-subtext,
443
+ .error-icon {
444
+ display: block;
445
+ }
446
+ }
447
+ .error-icon {
448
+ display: none;
449
+ }
450
+ .error-icon {
451
+ fill: #db2100;
452
+ width: 24px;
453
+ height: 24px;
454
+ }
455
+ }
456
+ }
457
+ &__servers-list {
458
+ height: 170px;
459
+ }
460
+ }
461
+ .flex-align-center {
462
+ &.input-action-wrapper {
463
+ width: 260px;
464
+ }
465
+ input {
466
+ width: 210px;
467
+ }
468
+ }
469
+ </style>
@@ -0,0 +1,51 @@
1
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
2
+
3
+ export const defaultFormFunc = (localization: UI_I_Localization): any => {
4
+ return {
5
+ name: {
6
+ value: 'Datastore',
7
+ validations: [
8
+ {
9
+ value: 'required',
10
+ errorText: localization.common.specifyDatastoreName,
11
+ },
12
+ ],
13
+ },
14
+ folder: {
15
+ value: '',
16
+ validations: [
17
+ {
18
+ value: 'required',
19
+ errorText: localization.common.specifyFolderName,
20
+ },
21
+ ],
22
+ },
23
+ server: {
24
+ value: '',
25
+ validations: [
26
+ {
27
+ value: 'required',
28
+ errorText: localization.common.specifyServerName,
29
+ },
30
+ ],
31
+ },
32
+ username: {
33
+ value: '',
34
+ validations: [
35
+ {
36
+ value: 'required',
37
+ errorText: localization.common.usernameIsRequired,
38
+ },
39
+ ],
40
+ },
41
+ password: {
42
+ value: '',
43
+ validations: [
44
+ {
45
+ value: 'required',
46
+ errorText: localization.common.passwordIsRequired,
47
+ },
48
+ ],
49
+ },
50
+ }
51
+ }
@@ -0,0 +1,14 @@
1
+ import type { UI_I_DataServersListItem } from '~/components/common/backup/storage/actions/add/temp/nfs/configuration/serversList/lib/models/interfaces'
2
+
3
+ // export interface I_ServerNfs {
4
+ // server_name: string
5
+ // }
6
+ export interface UI_I_ConfigurationSendDataNfs {
7
+ name: string
8
+ folder: string
9
+ server: UI_I_DataServersListItem[]
10
+ user: string
11
+ password: string
12
+
13
+ // readonly: boolean
14
+ }
@@ -0,0 +1,99 @@
1
+ <template>
2
+ <div class="popover flex items-center justify-between">
3
+ <slot>
4
+ <span
5
+ class="popover__item"
6
+ data-id="delete-popover-text"
7
+ @click="onClickItem"
8
+ >{{ localization.common.removeMember }}</span
9
+ >
10
+ </slot>
11
+ </div>
12
+ </template>
13
+
14
+ <script lang="ts" setup>
15
+ import type { UI_I_Localization } from '~/lib/models/interfaces'
16
+
17
+ const emits = defineEmits<{
18
+ (event: 'hide'): void
19
+ (event: 'click-item'): void
20
+ }>()
21
+
22
+ const localization = computed<UI_I_Localization>(() => useLocal())
23
+ const onClickItem = (): void => {
24
+ emits('click-item')
25
+ }
26
+ const hide = (): void => {
27
+ emits('hide')
28
+ }
29
+ const windowClick = (): void => {
30
+ hide()
31
+ }
32
+
33
+ onMounted(() => {
34
+ setTimeout(() => {
35
+ window.addEventListener('click', windowClick)
36
+ })
37
+ })
38
+ onUnmounted(() => {
39
+ window.removeEventListener('click', windowClick)
40
+ })
41
+ </script>
42
+
43
+ <style lang="scss" scoped>
44
+ @import '~/assets/scss/common/mixins.scss';
45
+
46
+ .popover {
47
+ height: 38px;
48
+ background: var(--block-view-bg-color2);
49
+ padding: 0.3rem;
50
+ margin-left: 0.3rem;
51
+ border: 0.05rem solid var(--block-border-color);
52
+ box-shadow: 0 0.05rem 0.15rem hsl(0deg 0% 55% / 25%);
53
+ transform: translateY(-50%);
54
+ border-radius: 0.15rem;
55
+ font-weight: 400;
56
+ white-space: nowrap;
57
+ z-index: var(--z-popover);
58
+ &:before,
59
+ &:after {
60
+ content: '';
61
+ position: absolute;
62
+ top: 50%;
63
+ right: 100%;
64
+ width: 0;
65
+ height: 0;
66
+ }
67
+ &:before {
68
+ margin-top: -0.3rem;
69
+ border-bottom: 0.3rem solid transparent;
70
+ border-top: 0.3rem solid transparent;
71
+ border-left: 0;
72
+ border-right: 0.3rem solid var(--block-border-color);
73
+ }
74
+ &:after {
75
+ margin-top: -0.25rem;
76
+ border-right: 0.25rem solid var(--block-view-bg-color2);
77
+ border-top: 0.25rem solid transparent;
78
+ border-bottom: 0.25rem solid transparent;
79
+ }
80
+ &__item {
81
+ @include text($fs: 14px, $c: var(--global-font-color3));
82
+ line-height: 1.15rem;
83
+ padding: 0.05rem 1.2rem 0;
84
+ &:hover {
85
+ background-color: var(--popover-hover-bg-color);
86
+ cursor: pointer;
87
+ }
88
+ }
89
+ }
90
+ </style>
91
+
92
+ <style>
93
+ :root {
94
+ --popover-hover-bg-color: #e8e8e8;
95
+ }
96
+ :root.dark-theme {
97
+ --popover-hover-bg-color: #28404d;
98
+ }
99
+ </style>