11
This commit is contained in:
@@ -21,6 +21,7 @@ const scheduleDate = ref(null);
|
||||
const accountDialogVisible = ref(false);
|
||||
const activePlatformKey = ref("douyin");
|
||||
const checkingAccountId = ref(null);
|
||||
const openingAccountId = ref(null);
|
||||
|
||||
const hasVideo = computed(
|
||||
() => Boolean(processedVideoPath.value || generatedVideoPath.value),
|
||||
@@ -133,6 +134,13 @@ async function onTestAccount(platform, account) {
|
||||
showFeedback(result);
|
||||
}
|
||||
|
||||
async function onOpenAccount(platform, account) {
|
||||
openingAccountId.value = account.id;
|
||||
const result = await workflow.openPublishAccount(platform.key, account.id);
|
||||
openingAccountId.value = null;
|
||||
showFeedback(result);
|
||||
}
|
||||
|
||||
function onDeleteAccount(platform, account) {
|
||||
platform.accounts = (platform.accounts || []).filter((a) => a.id !== account.id);
|
||||
if (platform.accountId === account.id) {
|
||||
@@ -337,6 +345,14 @@ function formatUpdateTime(account) {
|
||||
:loading="checkingAccountId === account.id"
|
||||
@click="onTestAccount(activePlatform, account)"
|
||||
/>
|
||||
<Button
|
||||
label="打开"
|
||||
size="small"
|
||||
severity="secondary"
|
||||
outlined
|
||||
:loading="openingAccountId === account.id"
|
||||
@click="onOpenAccount(activePlatform, account)"
|
||||
/>
|
||||
<Button
|
||||
label="删除"
|
||||
size="small"
|
||||
|
||||
Reference in New Issue
Block a user