mirror of
https://github.com/portainer/portainer.git
synced 2025-07-22 06:49:40 +02:00
fix(k8s/storage): missing endpoint id in storage patch request (#4174)
This commit is contained in:
parent
26ee78e1e7
commit
e7a33347c6
2 changed files with 7 additions and 6 deletions
|
@ -57,7 +57,7 @@ class KubernetesConfigureController {
|
|||
const storagePromises = _.map(classes, (storageClass) => {
|
||||
const oldStorageClass = _.find(this.oldStorageClasses, { Name: storageClass.Name });
|
||||
if (oldStorageClass) {
|
||||
return this.KubernetesStorageService.patch(oldStorageClass, storageClass);
|
||||
return this.KubernetesStorageService.patch(this.state.endpointId, oldStorageClass, storageClass);
|
||||
}
|
||||
});
|
||||
|
||||
|
@ -89,6 +89,7 @@ class KubernetesConfigureController {
|
|||
actionInProgress: false,
|
||||
displayConfigureClassPanel: {},
|
||||
viewReady: false,
|
||||
endpointId: this.$stateParams.id,
|
||||
};
|
||||
|
||||
this.formValues = {
|
||||
|
@ -97,8 +98,7 @@ class KubernetesConfigureController {
|
|||
};
|
||||
|
||||
try {
|
||||
const endpointId = this.$stateParams.id;
|
||||
[this.StorageClasses, this.endpoint] = await Promise.all([this.KubernetesStorageService.get(endpointId), this.EndpointService.endpoint(endpointId)]);
|
||||
[this.StorageClasses, this.endpoint] = await Promise.all([this.KubernetesStorageService.get(this.state.endpointId), this.EndpointService.endpoint(this.state.endpointId)]);
|
||||
_.forEach(this.StorageClasses, (item) => {
|
||||
item.availableAccessModes = new KubernetesStorageClassAccessPolicies();
|
||||
const storage = _.find(this.endpoint.Kubernetes.Configuration.StorageClasses, (sc) => sc.Name === item.Name);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue