Skip to content

Commit 9febec7

Browse files
committed
fix(pages): fix group list initiation
1 parent d57bf7a commit 9febec7

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

apps/client/src/layouts/PagesLayout/RightSidebar/NoteProperties/NewPageDialog.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,6 +172,7 @@ const groupOptions = computed(() => [
172172
}
173173
174174
if (
175+
groupId !== page.value.react.groupId &&
175176
!rolesMap()[groupMemberRoles.value[groupIndex]]?.permissions
176177
.editGroupPages
177178
) {
@@ -204,6 +205,7 @@ const groupMemberName = ref('');
204205
onMounted(async () => {
205206
// Initialize group IDs
206207
208+
destGroupId.value = page.value.react.groupId;
207209
groupIds.value = [page.value.react.groupId];
208210
209211
// Focus page title
@@ -241,8 +243,6 @@ onMounted(async () => {
241243
).text;
242244
})(),
243245
]);
244-
245-
destGroupId.value = page.value.react.groupId;
246246
});
247247
248248
async function _createPage() {

apps/client/src/layouts/PagesLayout/RightSidebar/PageProperties/MovePageDialog.vue

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,7 @@ const groupOptions = computed(() => [
160160
}
161161
162162
if (
163+
groupId !== internals.pages.react.page.react.groupId &&
163164
!rolesMap()[groupMemberRoles.value[groupIndex]]?.permissions
164165
.editGroupPages
165166
) {
@@ -176,6 +177,7 @@ const groupOptions = computed(() => [
176177
]);
177178
178179
onMounted(async () => {
180+
destGroupId.value = props.groupId;
179181
groupIds.value = [props.groupId];
180182
181183
await Promise.all([
@@ -201,8 +203,6 @@ onMounted(async () => {
201203
groupMemberName.value = await selfUserName().getAsync();
202204
})(),
203205
]);
204-
205-
destGroupId.value = props.groupId;
206206
});
207207
208208
async function _movePage() {

0 commit comments

Comments
 (0)