Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2020-10-07 09:09:03 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2020-10-07 09:09:03 +0300
commitb6724a211e047c35f3ba4c294997fba14bf42445 (patch)
tree219e1dd7ceb45b1b1fb915fa92a3123b979d2e56 /app/assets/javascripts/registry
parent3c33a3d566614d2589e832c32337efc122e9e2df (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'app/assets/javascripts/registry')
-rw-r--r--app/assets/javascripts/registry/explorer/components/list_page/image_list_row.vue15
-rw-r--r--app/assets/javascripts/registry/explorer/constants/expiration_policies.js3
2 files changed, 15 insertions, 3 deletions
diff --git a/app/assets/javascripts/registry/explorer/components/list_page/image_list_row.vue b/app/assets/javascripts/registry/explorer/components/list_page/image_list_row.vue
index 29ce9150c89..cfd787b3f52 100644
--- a/app/assets/javascripts/registry/explorer/components/list_page/image_list_row.vue
+++ b/app/assets/javascripts/registry/explorer/components/list_page/image_list_row.vue
@@ -10,6 +10,7 @@ import {
LIST_DELETE_BUTTON_DISABLED,
REMOVE_REPOSITORY_LABEL,
ROW_SCHEDULED_FOR_DELETION,
+ CLEANUP_TIMED_OUT_ERROR_MESSAGE,
} from '../../constants/index';
export default {
@@ -34,7 +35,6 @@ export default {
LIST_DELETE_BUTTON_DISABLED,
REMOVE_REPOSITORY_LABEL,
ROW_SCHEDULED_FOR_DELETION,
- ASYNC_DELETE_IMAGE_ERROR_MESSAGE,
},
computed: {
encodedItem() {
@@ -56,6 +56,14 @@ export default {
this.item.tags_count,
);
},
+ warningIconText() {
+ if (this.item.failedDelete) {
+ return ASYNC_DELETE_IMAGE_ERROR_MESSAGE;
+ } else if (this.item.cleanup_policy_started_at) {
+ return CLEANUP_TIMED_OUT_ERROR_MESSAGE;
+ }
+ return null;
+ },
},
};
</script>
@@ -86,8 +94,9 @@ export default {
category="tertiary"
/>
<gl-icon
- v-if="item.failedDelete"
- v-gl-tooltip="{ title: $options.i18n.ASYNC_DELETE_IMAGE_ERROR_MESSAGE }"
+ v-if="warningIconText"
+ v-gl-tooltip="{ title: warningIconText }"
+ data-testid="warning-icon"
name="warning"
class="gl-text-orange-500"
/>
diff --git a/app/assets/javascripts/registry/explorer/constants/expiration_policies.js b/app/assets/javascripts/registry/explorer/constants/expiration_policies.js
index 5f73834d995..48a6a015461 100644
--- a/app/assets/javascripts/registry/explorer/constants/expiration_policies.js
+++ b/app/assets/javascripts/registry/explorer/constants/expiration_policies.js
@@ -13,3 +13,6 @@ export const DELETE_ALERT_TITLE = s__('ContainerRegistry|Some tags were not dele
export const DELETE_ALERT_LINK_TEXT = s__(
'ContainerRegistry|The cleanup policy timed out before it could delete all tags. An administrator can %{adminLinkStart}manually run cleanup now%{adminLinkEnd} or you can wait for the cleanup policy to automatically run again. %{docLinkStart}More information%{docLinkEnd}',
);
+export const CLEANUP_TIMED_OUT_ERROR_MESSAGE = s__(
+ 'ContainerRegistry|Cleanup timed out before it could delete all tags',
+);