feat: queue force promote (#10370)
* feat: queue force promote * Update CHANGELOG.md * small fix
This commit is contained in:
@@ -4,6 +4,8 @@
|
||||
<MkSpacer :content-max="800">
|
||||
<XQueue v-if="tab === 'deliver'" domain="deliver"/>
|
||||
<XQueue v-else-if="tab === 'inbox'" domain="inbox"/>
|
||||
<br>
|
||||
<MkButton @click="promoteAllQueues"><i class="ti ti-reload"></i> {{ i18n.ts.retryAllQueuesNow }}</MkButton>
|
||||
</MkSpacer>
|
||||
</MkStickyContainer>
|
||||
</template>
|
||||
@@ -15,6 +17,7 @@ import * as os from '@/os';
|
||||
import * as config from '@/config';
|
||||
import { i18n } from '@/i18n';
|
||||
import { definePageMetadata } from '@/scripts/page-metadata';
|
||||
import MkButton from '@/components/MkButton.vue';
|
||||
|
||||
let tab = $ref('deliver');
|
||||
|
||||
@@ -30,6 +33,18 @@ function clear() {
|
||||
});
|
||||
}
|
||||
|
||||
function promoteAllQueues() {
|
||||
os.confirm({
|
||||
type: 'warning',
|
||||
title: i18n.ts.retryAllQueuesConfirmTitle,
|
||||
text: i18n.ts.retryAllQueuesConfirmText,
|
||||
}).then(({ canceled }) => {
|
||||
if (canceled) return;
|
||||
|
||||
os.apiWithDialog('admin/queue/promote', { type: tab });
|
||||
});
|
||||
}
|
||||
|
||||
const headerActions = $computed(() => [{
|
||||
asFullButton: true,
|
||||
icon: 'ti ti-external-link',
|
||||
|
Reference in New Issue
Block a user