dashboard-shell-shell 3.0.5-test.2 → 3.0.5-test.21
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.
- package/assets/icons/iconfont.css +4 -1
- package/assets/images/pl/dark/logo.png +0 -0
- package/assets/styles/all.scss +3 -1
- package/assets/styles/base/_variables.scss +5 -5
- package/assets/styles/global/_button.scss +8 -8
- package/assets/styles/global/_select.scss +1 -1
- package/assets/styles/global/_tooltip.scss +9 -5
- package/assets/styles/themes/_light.scss +3 -1
- package/assets/styles/vendor/vue-select.scss +2 -1
- package/assets/translations/zh-hans.yaml +140 -11
- package/components/ActionDropdown.vue +1 -1
- package/components/ButtonDropdown.vue +3 -1
- package/components/CodeMirror.vue +6 -4
- package/components/ContainerResourceLimit.vue +2 -2
- package/components/CopyToClipboard.vue +15 -0
- package/components/Drawer/Chrome.vue +2 -2
- package/components/Drawer/ResourceDetailDrawer/ConfigTab.vue +30 -27
- package/components/Drawer/ResourceDetailDrawer/YamlTab.vue +1 -1
- package/components/Drawer/ResourceDetailDrawer/index.vue +5 -4
- package/components/ExplorerMembers.vue +28 -4
- package/components/GlobalRoleBindings.vue +48 -112
- package/components/PodSecurityAdmission.vue +1 -1
- package/components/Resource/Detail/Metadata/IdentifyingInformation/index.vue +1 -3
- package/components/Resource/Detail/Metadata/KeyValue.vue +8 -4
- package/components/Resource/Detail/Metadata/index.vue +3 -1
- package/components/Resource/Detail/TitleBar/Title.vue +4 -3
- package/components/Resource/Detail/TitleBar/Top.vue +2 -0
- package/components/Resource/Detail/TitleBar/composables.ts +16 -1
- package/components/Resource/Detail/TitleBar/index.vue +113 -25
- package/components/ResourceDetail/Masthead/index.vue +1 -1
- package/components/ResourceDetail/Masthead/latest.vue +1 -1
- package/components/ResourceDetail/Masthead/legacy.vue +236 -165
- package/components/ResourceDetail/legacy.vue +44 -28
- package/components/ResourceList/Masthead.vue +11 -15
- package/components/SideNav.vue +1 -1
- package/components/SortableTable/index.vue +9 -4
- package/components/Tabbed/index.vue +6 -1
- package/components/auth/Principal.vue +42 -13
- package/components/auth/RoleDetailEdit.vue +11 -7
- package/components/breadcrumb/index.vue +124 -0
- package/components/form/ArrayList.vue +164 -147
- package/components/form/ArrayListGrouped.vue +3 -1
- package/components/form/ChangePassword.vue +1 -1
- package/components/form/Command.vue +4 -5
- package/components/form/Footer.vue +1 -0
- package/components/form/HealthCheck.vue +0 -2
- package/components/form/HookOption.vue +87 -58
- package/components/form/InputWithSelect.vue +8 -7
- package/components/form/KeyValue.vue +20 -2
- package/components/form/LabeledSelect.vue +6 -3
- package/components/form/Labels.vue +2 -2
- package/components/form/MatchExpressions.vue +3 -4
- package/components/form/Members/ClusterMembershipEditor.vue +1 -1
- package/components/form/Members/ClusterPermissionsEditor.vue +5 -5
- package/components/form/Members/MembershipEditor.vue +2 -2
- package/components/form/NameNsDescription.vue +1 -1
- package/components/form/Networking.vue +6 -9
- package/components/form/NodeAffinity.vue +29 -28
- package/components/form/PodAffinity.vue +23 -23
- package/components/form/Probe.vue +15 -11
- package/components/form/ResourceQuota/Namespace.vue +4 -4
- package/components/form/ResourceQuota/NamespaceRow.vue +11 -9
- package/components/form/ResourceQuota/Project.vue +4 -4
- package/components/form/ResourceQuota/ProjectRow.vue +36 -30
- package/components/form/ResourceSelector.vue +1 -1
- package/components/form/Security.vue +1 -3
- package/components/form/Select.vue +6 -1
- package/components/form/ServiceNameSelect.vue +2 -5
- package/components/form/ServicePorts.vue +149 -75
- package/components/form/Taints.vue +2 -1
- package/components/form/Tolerations.vue +12 -9
- package/components/form/ValueFromResource.vue +110 -96
- package/components/form/WorkloadPorts.vue +143 -123
- package/components/nav/Header.vue +3 -4
- package/components/nav/NamespaceFilter.vue +15 -21
- package/components/nav/TopLevelMenu.vue +99 -125
- package/components/nav/Type.vue +3 -3
- package/config/product/explorer.js +4 -1
- package/config/router/navigation-guards/index.js +52 -3
- package/detail/node.vue +28 -23
- package/dialog/AddCustomBadgeDialog.vue +17 -9
- package/edit/autoscaling.horizontalpodautoscaler/external-metric.vue +1 -1
- package/edit/autoscaling.horizontalpodautoscaler/hpa-scaling-rule.vue +9 -6
- package/edit/autoscaling.horizontalpodautoscaler/index.vue +3 -1
- package/edit/autoscaling.horizontalpodautoscaler/metric-identifier.vue +2 -2
- package/edit/autoscaling.horizontalpodautoscaler/metric-object-reference.vue +7 -5
- package/edit/autoscaling.horizontalpodautoscaler/metric-target.vue +5 -3
- package/edit/autoscaling.horizontalpodautoscaler/metrics-row.vue +2 -2
- package/edit/autoscaling.horizontalpodautoscaler/object-metric.vue +2 -2
- package/edit/autoscaling.horizontalpodautoscaler/pod-metric.vue +1 -1
- package/edit/autoscaling.horizontalpodautoscaler/resource-metric.vue +2 -2
- package/edit/networking.k8s.io.ingress/Certificate.vue +7 -5
- package/edit/networking.k8s.io.ingress/DefaultBackend.vue +2 -2
- package/edit/networking.k8s.io.ingress/Rule.vue +5 -11
- package/edit/networking.k8s.io.ingress/RulePath.vue +105 -96
- package/edit/networking.k8s.io.networkpolicy/PolicyRule.vue +3 -3
- package/edit/networking.k8s.io.networkpolicy/PolicyRulePort.vue +4 -2
- package/edit/networking.k8s.io.networkpolicy/PolicyRuleTarget.vue +12 -11
- package/edit/networking.k8s.io.networkpolicy/index.vue +1 -1
- package/edit/persistentvolume/index.vue +3 -1
- package/edit/persistentvolumeclaim.vue +2 -0
- package/edit/secret/index.vue +2 -2
- package/edit/service.vue +4 -1
- package/edit/storage.k8s.io.storageclass/index.vue +10 -8
- package/edit/storage.k8s.io.storageclass/provisioners/kubernetes.io/aws-ebs.vue +34 -27
- package/edit/storage.k8s.io.storageclass/provisioners/kubernetes.io/gce-pd.vue +15 -13
- package/edit/storage.k8s.io.storageclass/provisioners/kubernetes.io/vsphere-volume.vue +41 -39
- package/edit/workload/Job.vue +31 -34
- package/edit/workload/Upgrading.vue +5 -5
- package/edit/workload/index.vue +21 -17
- package/edit/workload/storage/Mount.vue +1 -0
- package/edit/workload/storage/awsElasticBlockStore.vue +9 -7
- package/edit/workload/storage/azureDisk.vue +14 -10
- package/edit/workload/storage/azureFile.vue +9 -7
- package/edit/workload/storage/csi/index.vue +6 -9
- package/edit/workload/storage/emptyDir.vue +7 -5
- package/edit/workload/storage/gcePersistentDisk.vue +9 -7
- package/edit/workload/storage/hostPath.vue +7 -5
- package/edit/workload/storage/nfs.vue +8 -6
- package/edit/workload/storage/persistentVolumeClaim/index.vue +12 -10
- package/edit/workload/storage/persistentVolumeClaim/persistentvolumeclaim.vue +20 -15
- package/edit/workload/storage/secret.vue +9 -6
- package/edit/workload/storage/vsphereVolume.vue +11 -7
- package/initialize/app-extended.js +7 -1
- package/package.json +1 -1
- package/pages/account/index.vue +95 -115
- package/pages/auth/setup.vue +35 -16
- package/pages/c/_cluster/auth/roles/index.vue +38 -5
- package/pages/c/_cluster/explorer/ConfigBadge.vue +1 -1
- package/pages/c/_cluster/explorer/tools/index.vue +6 -6
- package/pages/home.vue +3 -4
- package/pkg/tsconfig.json +9 -9
- package/pkg/vue.config.js +1 -1
- package/plugins/dashboard-store/resource-class.js +28 -27
- package/rancher-components/BadgeState/BadgeState.vue +33 -52
- package/rancher-components/Banner/Banner.vue +6 -3
- package/rancher-components/LabeledTooltip/LabeledTooltip.vue +31 -2
- package/rancher-components/RcDropdown/RcDropdownMenu.vue +8 -7
- package/scripts/publish-shell.sh +1 -1
- package/store/i18n.js +4 -0
- package/store/type-map.js +1 -1
- package/types/shell/index.d.ts +4 -30
- package/utils/error.js +3 -1
- package/utils/errorTranslate.json +247 -2
- package/vue.config.js +1 -1
|
@@ -284,128 +284,141 @@ export default {
|
|
|
284
284
|
|
|
285
285
|
<template>
|
|
286
286
|
<div class="var-row">
|
|
287
|
-
<div class="
|
|
288
|
-
<
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
/>
|
|
299
|
-
</div>
|
|
300
|
-
|
|
301
|
-
<div
|
|
302
|
-
v-if="!hideVariableName"
|
|
303
|
-
class="name"
|
|
304
|
-
>
|
|
305
|
-
<LabeledInput
|
|
306
|
-
v-model:value="name"
|
|
307
|
-
:label="nameLabel"
|
|
308
|
-
:placeholder="t('workload.container.command.fromResource.name.placeholder')"
|
|
309
|
-
:mode="mode"
|
|
310
|
-
@update:value="updateRow"
|
|
311
|
-
/>
|
|
312
|
-
</div>
|
|
313
|
-
|
|
314
|
-
<div
|
|
315
|
-
v-if="type==='simple'"
|
|
316
|
-
class="single-value"
|
|
317
|
-
>
|
|
318
|
-
<LabeledInput
|
|
319
|
-
v-model:value="valStr"
|
|
320
|
-
:label="t('workload.container.command.fromResource.value.label')"
|
|
321
|
-
:placeholder="t('workload.container.command.fromResource.value.placeholder')"
|
|
322
|
-
:mode="mode"
|
|
323
|
-
@update:value="updateRow"
|
|
324
|
-
/>
|
|
287
|
+
<div class="row">
|
|
288
|
+
<div class="remove">
|
|
289
|
+
<button
|
|
290
|
+
v-if="!isView"
|
|
291
|
+
type="button"
|
|
292
|
+
class="btn role-link"
|
|
293
|
+
@click.stop="$emit('remove')"
|
|
294
|
+
>
|
|
295
|
+
{{ t('generic.remove') }}
|
|
296
|
+
</button>
|
|
297
|
+
</div>
|
|
325
298
|
</div>
|
|
326
299
|
|
|
327
|
-
<
|
|
328
|
-
<div
|
|
300
|
+
<div class="row">
|
|
301
|
+
<div class="type span-6 col">
|
|
329
302
|
<LabeledSelect
|
|
330
|
-
v-model:value="
|
|
331
|
-
:options="sourceOptions"
|
|
332
|
-
:multiple="false"
|
|
333
|
-
:get-option-label="opt=>get(opt, 'metadata.name') || opt"
|
|
334
|
-
:get-option-key="opt=>opt.id|| opt"
|
|
303
|
+
v-model:value="type"
|
|
335
304
|
:mode="mode"
|
|
336
|
-
:label="sourceLabel"
|
|
337
|
-
:loading="loading"
|
|
338
|
-
/>
|
|
339
|
-
</div>
|
|
340
|
-
<div v-if="type!=='secretRef' && type!== 'configMapRef'">
|
|
341
|
-
<LabeledSelect
|
|
342
|
-
v-model:value="key"
|
|
343
305
|
:multiple="false"
|
|
344
|
-
:options="
|
|
345
|
-
:mode="mode"
|
|
306
|
+
:options="options"
|
|
346
307
|
option-label="label"
|
|
347
|
-
:
|
|
348
|
-
:
|
|
308
|
+
:searchable="false"
|
|
309
|
+
:reduce="e=>e.value"
|
|
310
|
+
:label="t('workload.container.command.fromResource.type')"
|
|
349
311
|
@update:value="updateRow"
|
|
350
312
|
/>
|
|
351
313
|
</div>
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
314
|
+
|
|
315
|
+
<div
|
|
316
|
+
v-if="!hideVariableName"
|
|
317
|
+
class="name span-6 col"
|
|
318
|
+
>
|
|
356
319
|
<LabeledInput
|
|
357
|
-
v-model:value="
|
|
358
|
-
:label="
|
|
359
|
-
:placeholder="t('workload.container.command.fromResource.
|
|
320
|
+
v-model:value="name"
|
|
321
|
+
:label="nameLabel"
|
|
322
|
+
:placeholder="t('workload.container.command.fromResource.name.placeholder')"
|
|
360
323
|
:mode="mode"
|
|
361
324
|
@update:value="updateRow"
|
|
362
325
|
/>
|
|
363
326
|
</div>
|
|
364
|
-
|
|
365
|
-
<LabeledSelect
|
|
366
|
-
v-model:value="key"
|
|
367
|
-
:label="t('workload.container.command.fromResource.key.label')"
|
|
368
|
-
:multiple="false"
|
|
369
|
-
:options="resourceKeyOpts"
|
|
370
|
-
:mode="mode"
|
|
371
|
-
:searchable="false"
|
|
372
|
-
:placeholder="t('workload.container.command.fromResource.key.placeholder', null, true)"
|
|
373
|
-
@update:value="updateRow"
|
|
374
|
-
/>
|
|
375
|
-
</div>
|
|
376
|
-
</template>
|
|
327
|
+
</div>
|
|
377
328
|
|
|
378
|
-
<
|
|
379
|
-
<div
|
|
329
|
+
<div class="row">
|
|
330
|
+
<div
|
|
331
|
+
v-if="type==='simple'"
|
|
332
|
+
class="single-value span-6 col"
|
|
333
|
+
>
|
|
380
334
|
<LabeledInput
|
|
381
|
-
v-model:value="
|
|
382
|
-
:
|
|
383
|
-
:
|
|
335
|
+
v-model:value="valStr"
|
|
336
|
+
:label="t('workload.container.command.fromResource.value.label')"
|
|
337
|
+
:placeholder="t('workload.container.command.fromResource.value.placeholder')"
|
|
384
338
|
:mode="mode"
|
|
385
339
|
@update:value="updateRow"
|
|
386
340
|
/>
|
|
387
341
|
</div>
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
342
|
+
|
|
343
|
+
<template v-else-if="needsSource">
|
|
344
|
+
<div
|
|
345
|
+
:class="{'single-value': type === 'configMapRef' || type === 'secretRef'}"
|
|
346
|
+
class="span-6 col"
|
|
347
|
+
>
|
|
348
|
+
<LabeledSelect
|
|
349
|
+
v-model:value="referenced"
|
|
350
|
+
:options="sourceOptions"
|
|
351
|
+
:multiple="false"
|
|
352
|
+
:get-option-label="opt=>get(opt, 'metadata.name') || opt"
|
|
353
|
+
:get-option-key="opt=>opt.id|| opt"
|
|
354
|
+
:mode="mode"
|
|
355
|
+
:label="sourceLabel"
|
|
356
|
+
:loading="loading"
|
|
357
|
+
/>
|
|
358
|
+
</div>
|
|
359
|
+
<div
|
|
360
|
+
v-if="type!=='secretRef' && type!== 'configMapRef'"
|
|
361
|
+
class="span-6 col"
|
|
362
|
+
>
|
|
363
|
+
<LabeledSelect
|
|
364
|
+
v-model:value="key"
|
|
365
|
+
:multiple="false"
|
|
366
|
+
:options="keys"
|
|
367
|
+
:mode="mode"
|
|
368
|
+
option-label="label"
|
|
369
|
+
:label="t('workload.container.command.fromResource.key.label')"
|
|
370
|
+
:loading="loading"
|
|
371
|
+
@update:value="updateRow"
|
|
372
|
+
/>
|
|
373
|
+
</div>
|
|
374
|
+
</template>
|
|
375
|
+
|
|
376
|
+
<template v-else-if="type==='resourceFieldRef'">
|
|
377
|
+
<div class="span-6 col">
|
|
378
|
+
<LabeledInput
|
|
379
|
+
v-model:value="refName"
|
|
380
|
+
:label="t('workload.container.command.fromResource.containerName')"
|
|
381
|
+
:placeholder="t('workload.container.command.fromResource.source.placeholder')"
|
|
382
|
+
:mode="mode"
|
|
383
|
+
@update:value="updateRow"
|
|
384
|
+
/>
|
|
385
|
+
</div>
|
|
386
|
+
<div class="span-6 col">
|
|
387
|
+
<LabeledSelect
|
|
388
|
+
v-model:value="key"
|
|
389
|
+
:label="t('workload.container.command.fromResource.key.label')"
|
|
390
|
+
:multiple="false"
|
|
391
|
+
:options="resourceKeyOpts"
|
|
392
|
+
:mode="mode"
|
|
393
|
+
:searchable="false"
|
|
394
|
+
:placeholder="t('workload.container.command.fromResource.key.placeholder', null, true)"
|
|
395
|
+
@update:value="updateRow"
|
|
396
|
+
/>
|
|
397
|
+
</div>
|
|
398
|
+
</template>
|
|
399
|
+
|
|
400
|
+
<template v-else>
|
|
401
|
+
<div class="single-value span-6 col">
|
|
402
|
+
<LabeledInput
|
|
403
|
+
v-model:value="fieldPath"
|
|
404
|
+
:placeholder="t('workload.container.command.fromResource.key.placeholder', null, true)"
|
|
405
|
+
:label="t('workload.container.command.fromResource.key.label')"
|
|
406
|
+
:mode="mode"
|
|
407
|
+
@update:value="updateRow"
|
|
408
|
+
/>
|
|
409
|
+
</div>
|
|
410
|
+
</template>
|
|
398
411
|
</div>
|
|
399
412
|
</div>
|
|
400
413
|
</template>
|
|
401
414
|
|
|
402
415
|
<style lang='scss' scoped>
|
|
403
416
|
.var-row{
|
|
404
|
-
display: grid;
|
|
405
|
-
grid-template-columns: 1fr 1fr 1fr 1fr 100px;
|
|
406
|
-
grid-column-gap: 20px;
|
|
407
|
-
margin-bottom: 10px;
|
|
408
|
-
align-items: center;
|
|
417
|
+
// display: grid;
|
|
418
|
+
// grid-template-columns: 1fr 1fr 1fr 1fr 100px;
|
|
419
|
+
// grid-column-gap: 20px;
|
|
420
|
+
// margin-bottom: 10px;
|
|
421
|
+
// align-items: center;
|
|
409
422
|
|
|
410
423
|
.single-value {
|
|
411
424
|
grid-column: span 2;
|
|
@@ -413,6 +426,7 @@ export default {
|
|
|
413
426
|
|
|
414
427
|
.remove BUTTON {
|
|
415
428
|
padding: 0px;
|
|
429
|
+
min-width: auto;
|
|
416
430
|
}
|
|
417
431
|
}
|
|
418
432
|
|
|
@@ -280,145 +280,163 @@ export default {
|
|
|
280
280
|
'show-ipam': showIpam,
|
|
281
281
|
}"
|
|
282
282
|
>
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
v-model:value="row.name"
|
|
299
|
-
:mode="mode"
|
|
300
|
-
:label="t('workload.container.ports.name')"
|
|
301
|
-
@update:value="queueUpdate"
|
|
302
|
-
/>
|
|
303
|
-
</div>
|
|
283
|
+
|
|
284
|
+
<div class="row mt-20">
|
|
285
|
+
<div
|
|
286
|
+
v-if="!row._showHost && row._serviceType !== 'LoadBalancer' && row._serviceType !== 'NodePort'"
|
|
287
|
+
class="add-host col"
|
|
288
|
+
>
|
|
289
|
+
<button
|
|
290
|
+
:disabled="mode==='view'"
|
|
291
|
+
type="button"
|
|
292
|
+
class="btn btn-sm role-tertiary"
|
|
293
|
+
@click="row._showHost = true"
|
|
294
|
+
>
|
|
295
|
+
{{ t('workloadPorts.addHost') }}
|
|
296
|
+
</button>
|
|
297
|
+
</div>
|
|
304
298
|
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
</div>
|
|
299
|
+
<div
|
|
300
|
+
v-if="showRemove"
|
|
301
|
+
class="remove"
|
|
302
|
+
>
|
|
303
|
+
<button
|
|
304
|
+
type="button"
|
|
305
|
+
class="btn role-link"
|
|
306
|
+
@click="remove(idx)"
|
|
307
|
+
>
|
|
308
|
+
{{ t('workloadPorts.remove') }}
|
|
309
|
+
</button>
|
|
310
|
+
</div>
|
|
318
311
|
|
|
319
|
-
<div class="protocol col">
|
|
320
|
-
<LabeledSelect
|
|
321
|
-
v-model:value="row.protocol"
|
|
322
|
-
:mode="mode"
|
|
323
|
-
:options="workloadPortOptions"
|
|
324
|
-
:multiple="false"
|
|
325
|
-
:label="t('workload.container.ports.protocol')"
|
|
326
|
-
@update:value="queueUpdate"
|
|
327
|
-
/>
|
|
328
312
|
</div>
|
|
329
313
|
|
|
330
|
-
<div
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
314
|
+
<div class="row">
|
|
315
|
+
<div class="service-type col span-6">
|
|
316
|
+
<LabeledSelect
|
|
317
|
+
v-model:value="row._serviceType"
|
|
318
|
+
:mode="mode"
|
|
319
|
+
:label="t('workload.container.ports.createService')"
|
|
320
|
+
:options="serviceTypes"
|
|
321
|
+
:disabled="canNotAccessService"
|
|
322
|
+
:tooltip="serviceTypeTooltip"
|
|
323
|
+
@update:value="queueUpdate"
|
|
324
|
+
/>
|
|
325
|
+
</div>
|
|
326
|
+
|
|
327
|
+
<div class="portName col span-6">
|
|
328
|
+
<LabeledInput
|
|
329
|
+
ref="name"
|
|
330
|
+
v-model:value="row.name"
|
|
331
|
+
:mode="mode"
|
|
332
|
+
:label="t('workload.container.ports.name')"
|
|
333
|
+
@update:value="queueUpdate"
|
|
334
|
+
/>
|
|
335
|
+
</div>
|
|
345
336
|
</div>
|
|
346
337
|
|
|
347
|
-
<div
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
338
|
+
<div class="row">
|
|
339
|
+
<div class="port col span-6">
|
|
340
|
+
<LabeledInput
|
|
341
|
+
v-model:value.number="row.containerPort"
|
|
342
|
+
:mode="mode"
|
|
343
|
+
type="number"
|
|
344
|
+
min="1"
|
|
345
|
+
max="65535"
|
|
346
|
+
placeholder="e.g. 8080"
|
|
347
|
+
:label="t('workload.container.ports.containerPort')"
|
|
348
|
+
:required="row._serviceType === 'LoadBalancer' "
|
|
349
|
+
@update:value="queueUpdate"
|
|
350
|
+
/>
|
|
351
|
+
</div>
|
|
352
|
+
|
|
353
|
+
<div class="protocol col span-6">
|
|
354
|
+
<LabeledSelect
|
|
355
|
+
v-model:value="row.protocol"
|
|
356
|
+
:mode="mode"
|
|
357
|
+
:options="workloadPortOptions"
|
|
358
|
+
:multiple="false"
|
|
359
|
+
:label="t('workload.container.ports.protocol')"
|
|
360
|
+
@update:value="queueUpdate"
|
|
361
|
+
/>
|
|
362
|
+
</div>
|
|
359
363
|
</div>
|
|
360
364
|
|
|
361
|
-
<div
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
<button
|
|
366
|
-
:disabled="mode==='view'"
|
|
367
|
-
type="button"
|
|
368
|
-
class="btn btn-sm role-tertiary"
|
|
369
|
-
@click="row._showHost = true"
|
|
365
|
+
<div class="row">
|
|
366
|
+
<div
|
|
367
|
+
v-if="row._showHost"
|
|
368
|
+
class="targetPort col span-6"
|
|
370
369
|
>
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
<div v-if="row._serviceType === 'LoadBalancer' || row._serviceType === 'NodePort'">
|
|
376
|
-
<LabeledInput
|
|
377
|
-
ref="port"
|
|
378
|
-
v-model:value.number="row._listeningPort"
|
|
379
|
-
type="number"
|
|
380
|
-
:mode="mode"
|
|
381
|
-
:label="t('workload.container.ports.listeningPort')"
|
|
382
|
-
:required="row._serviceType === 'LoadBalancer' "
|
|
383
|
-
@update:value="queueUpdate"
|
|
384
|
-
/>
|
|
385
|
-
</div>
|
|
386
|
-
|
|
387
|
-
<div v-if="showIpam && row._serviceType === 'LoadBalancer' && row.protocol === 'TCP'">
|
|
388
|
-
<div v-if="idx === ipamIndex">
|
|
389
|
-
<LabeledSelect
|
|
390
|
-
v-model:value="row._ipam"
|
|
370
|
+
<LabeledInput
|
|
371
|
+
ref="port"
|
|
372
|
+
v-model:value.number="row.hostPort"
|
|
391
373
|
:mode="mode"
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
374
|
+
type="number"
|
|
375
|
+
min="1"
|
|
376
|
+
max="65535"
|
|
377
|
+
placeholder="e.g. 80"
|
|
378
|
+
:label="t('workload.container.ports.hostPort')"
|
|
395
379
|
@update:value="queueUpdate"
|
|
396
380
|
/>
|
|
397
381
|
</div>
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
382
|
+
|
|
383
|
+
<div
|
|
384
|
+
v-if="row._showHost"
|
|
385
|
+
class="hostip col span-6"
|
|
386
|
+
>
|
|
387
|
+
<LabeledInput
|
|
388
|
+
ref="port"
|
|
389
|
+
v-model:value="row.hostIP"
|
|
401
390
|
:mode="mode"
|
|
402
|
-
|
|
403
|
-
:label="t('
|
|
404
|
-
:disabled="true"
|
|
391
|
+
placeholder="e.g. 1.1.1.1"
|
|
392
|
+
:label="t('workload.container.ports.hostIP')"
|
|
405
393
|
@update:value="queueUpdate"
|
|
406
394
|
/>
|
|
407
395
|
</div>
|
|
408
396
|
</div>
|
|
409
397
|
|
|
410
|
-
<div
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
<button
|
|
415
|
-
type="button"
|
|
416
|
-
class="btn role-link"
|
|
417
|
-
@click="remove(idx)"
|
|
398
|
+
<div class="row">
|
|
399
|
+
<div
|
|
400
|
+
v-if="row._serviceType === 'LoadBalancer' || row._serviceType === 'NodePort'"
|
|
401
|
+
class="col"
|
|
418
402
|
>
|
|
419
|
-
|
|
420
|
-
|
|
403
|
+
<LabeledInput
|
|
404
|
+
ref="port"
|
|
405
|
+
v-model:value.number="row._listeningPort"
|
|
406
|
+
type="number"
|
|
407
|
+
:mode="mode"
|
|
408
|
+
:label="t('workload.container.ports.listeningPort')"
|
|
409
|
+
:required="row._serviceType === 'LoadBalancer' "
|
|
410
|
+
@update:value="queueUpdate"
|
|
411
|
+
/>
|
|
412
|
+
</div>
|
|
421
413
|
</div>
|
|
414
|
+
|
|
415
|
+
<div class="row">
|
|
416
|
+
<div v-if="showIpam && row._serviceType === 'LoadBalancer' && row.protocol === 'TCP'">
|
|
417
|
+
<div v-if="idx === ipamIndex">
|
|
418
|
+
<LabeledSelect
|
|
419
|
+
v-model:value="row._ipam"
|
|
420
|
+
:mode="mode"
|
|
421
|
+
:options="ipamOptions"
|
|
422
|
+
:label="t('servicesPage.harvester.ipam.label')"
|
|
423
|
+
:disabled="mode === 'edit'"
|
|
424
|
+
@update:value="queueUpdate"
|
|
425
|
+
/>
|
|
426
|
+
</div>
|
|
427
|
+
<div v-else>
|
|
428
|
+
<LabeledSelect
|
|
429
|
+
v-model:value="rows[ipamIndex]._ipam"
|
|
430
|
+
:mode="mode"
|
|
431
|
+
:options="ipamOptions"
|
|
432
|
+
:label="t('servicesPage.harvester.ipam.label')"
|
|
433
|
+
:disabled="true"
|
|
434
|
+
@update:value="queueUpdate"
|
|
435
|
+
/>
|
|
436
|
+
</div>
|
|
437
|
+
</div>
|
|
438
|
+
</div>
|
|
439
|
+
|
|
422
440
|
</div>
|
|
423
441
|
<div
|
|
424
442
|
v-if="showAdd"
|
|
@@ -447,11 +465,11 @@ $checkbox: 75;
|
|
|
447
465
|
}
|
|
448
466
|
}
|
|
449
467
|
.ports-headers, .ports-row{
|
|
450
|
-
display: grid;
|
|
451
|
-
grid-template-columns: 28% 28% 15% 10% 75px 0.5fr;
|
|
452
|
-
grid-column-gap: $column-gutter;
|
|
453
|
-
margin-bottom:
|
|
454
|
-
align-items: center;
|
|
468
|
+
// display: grid;
|
|
469
|
+
// grid-template-columns: 28% 28% 15% 10% 75px 0.5fr;
|
|
470
|
+
// grid-column-gap: $column-gutter;
|
|
471
|
+
// margin-bottom: 20px;
|
|
472
|
+
// align-items: center;
|
|
455
473
|
& .port{
|
|
456
474
|
display: flex;
|
|
457
475
|
justify-content: space-between;
|
|
@@ -475,6 +493,7 @@ $checkbox: 75;
|
|
|
475
493
|
}
|
|
476
494
|
|
|
477
495
|
.add-host {
|
|
496
|
+
margin-right: 20px;
|
|
478
497
|
justify-self: center;
|
|
479
498
|
}
|
|
480
499
|
|
|
@@ -492,6 +511,7 @@ $checkbox: 75;
|
|
|
492
511
|
|
|
493
512
|
.remove BUTTON {
|
|
494
513
|
padding: 0px;
|
|
514
|
+
min-width: auto;
|
|
495
515
|
}
|
|
496
516
|
|
|
497
517
|
.ports-row INPUT {
|
|
@@ -80,7 +80,7 @@ export default {
|
|
|
80
80
|
ctx: this,
|
|
81
81
|
showImportModal: false,
|
|
82
82
|
showSearchModal: false,
|
|
83
|
-
userIcon: require('
|
|
83
|
+
userIcon: require('@shell/assets/images/logo.png'),
|
|
84
84
|
};
|
|
85
85
|
},
|
|
86
86
|
|
|
@@ -548,7 +548,6 @@ export default {
|
|
|
548
548
|
|
|
549
549
|
<!-- ===== 左侧 logo 区域 ===== -->
|
|
550
550
|
<div class="menu-spacer">
|
|
551
|
-
|
|
552
551
|
<!-- 如果是单产品模式且不是 RancherInHarvester,就显示 logo 路由跳转 -->
|
|
553
552
|
<router-link
|
|
554
553
|
v-if="isSingleProduct && !isRancherInHarvester"
|
|
@@ -556,9 +555,9 @@ export default {
|
|
|
556
555
|
>
|
|
557
556
|
|
|
558
557
|
<!-- 显示用户头像或 logo 图片 -->
|
|
559
|
-
|
|
558
|
+
<img
|
|
560
559
|
:src="userIcon"
|
|
561
|
-
>
|
|
560
|
+
>
|
|
562
561
|
</router-link>
|
|
563
562
|
</div>
|
|
564
563
|
|