copyOnMoveAccount -> preserveAssignmentOnMoveAccount
This commit is contained in:
parent
b6c5678b0e
commit
a720475d7a
|
@ -7362,13 +7362,13 @@ export interface Locale extends ILocale {
|
|||
*/
|
||||
"descriptionOfDisplayOrder": string;
|
||||
/**
|
||||
* アカウント移行時にコピーする
|
||||
* アサイン状態を移行先アカウントにも引き継ぐ
|
||||
*/
|
||||
"copyOnMoveAccount": string;
|
||||
"preserveAssignmentOnMoveAccount": string;
|
||||
/**
|
||||
* オンにすると、アカウントの移行が行われた際にロールを下のユーザから新しいユーザにコピーするようになります。サイレンスなどを引き継ぎたい場合に使用できます。
|
||||
* オンにすると、このロールが付与されたアカウントが移行された際に、移行先アカウントにもこのロールが引き継がれるようになります。
|
||||
*/
|
||||
"descriptionOfCopyOnMoveAccount": string;
|
||||
"preserveAssignmentOnMoveAccount_description": string;
|
||||
/**
|
||||
* モデレーターのメンバー編集を許可
|
||||
*/
|
||||
|
|
|
@ -1907,8 +1907,8 @@ _role:
|
|||
descriptionOfIsExplorable: "オンにすると、「みつける」でメンバー一覧が公開されるほか、ロールのタイムラインが利用可能になります。"
|
||||
displayOrder: "表示順"
|
||||
descriptionOfDisplayOrder: "数値が大きいほどUI上で先頭に表示されます。"
|
||||
copyOnMoveAccount: "アカウント移行時にコピーする"
|
||||
descriptionOfCopyOnMoveAccount: "オンにすると、アカウントの移行が行われた際にロールを元のユーザから新しいユーザに引き継ぐようになります。"
|
||||
preserveAssignmentOnMoveAccount: "アサイン状態を移行先アカウントにも引き継ぐ"
|
||||
preserveAssignmentOnMoveAccount_description: "オンにすると、このロールが付与されたアカウントが移行された際に、移行先アカウントにもこのロールが引き継がれるようになります。"
|
||||
canEditMembersByModerator: "モデレーターのメンバー編集を許可"
|
||||
descriptionOfCanEditMembersByModerator: "オンにすると、管理者に加えてモデレーターもこのロールへユーザーをアサイン/アサイン解除できるようになります。オフにすると管理者のみが行えます。"
|
||||
priority: "優先度"
|
||||
|
|
|
@ -7,12 +7,10 @@ export class RoleCopyOnMoveAccount1743558299182 {
|
|||
name = 'RoleCopyOnMoveAccount1743558299182'
|
||||
|
||||
async up(queryRunner) {
|
||||
await queryRunner.query(`ALTER TABLE "role" ADD "copyOnMoveAccount" boolean NOT NULL DEFAULT false`);
|
||||
await queryRunner.query(`COMMENT ON COLUMN "role"."copyOnMoveAccount" IS 'If true, the role will be copied to moved to the new user on moving a user.'`);
|
||||
await queryRunner.query(`ALTER TABLE "role" ADD "preserveAssignmentOnMoveAccount" boolean NOT NULL DEFAULT false`);
|
||||
}
|
||||
|
||||
async down(queryRunner) {
|
||||
await queryRunner.query(`COMMENT ON COLUMN "role"."copyOnMoveAccount" IS 'If true, the role will be copied to moved to the new user on moving a user.'`);
|
||||
await queryRunner.query(`ALTER TABLE "role" DROP COLUMN "copyOnMoveAccount"`);
|
||||
await queryRunner.query(`ALTER TABLE "role" DROP COLUMN "preserveAssignmentOnMoveAccount"`);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -630,7 +630,7 @@ export class RoleService implements OnApplicationShutdown, OnModuleInit {
|
|||
isModerator: values.isModerator,
|
||||
isExplorable: values.isExplorable,
|
||||
asBadge: values.asBadge,
|
||||
copyOnMoveAccount: values.copyOnMoveAccount,
|
||||
preserveAssignmentOnMoveAccount: values.preserveAssignmentOnMoveAccount,
|
||||
canEditMembersByModerator: values.canEditMembersByModerator,
|
||||
displayOrder: values.displayOrder,
|
||||
policies: values.policies,
|
||||
|
|
|
@ -68,7 +68,7 @@ export class RoleEntityService {
|
|||
isModerator: role.isModerator,
|
||||
isExplorable: role.isExplorable,
|
||||
asBadge: role.asBadge,
|
||||
copyOnMoveAccount: role.copyOnMoveAccount,
|
||||
preserveAssignmentOnMoveAccount: role.preserveAssignmentOnMoveAccount,
|
||||
canEditMembersByModerator: role.canEditMembersByModerator,
|
||||
displayOrder: role.displayOrder,
|
||||
policies: policies,
|
||||
|
|
|
@ -250,9 +250,8 @@ export class MiRole {
|
|||
|
||||
@Column('boolean', {
|
||||
default: false,
|
||||
comment: 'If true, the role will be copied to moved to the new user on moving a user.',
|
||||
})
|
||||
public copyOnMoveAccount: boolean;
|
||||
public preserveAssignmentOnMoveAccount: boolean;
|
||||
|
||||
@Column('boolean', {
|
||||
default: false,
|
||||
|
|
|
@ -389,9 +389,8 @@ export const packedRoleSchema = {
|
|||
optional: false, nullable: false,
|
||||
example: false,
|
||||
},
|
||||
copyOnMoveAccount: {
|
||||
preserveAssignmentOnMoveAccount: {
|
||||
type: 'boolean',
|
||||
description: 'True if the role is going to be copied to dest account on account move.',
|
||||
optional: false, nullable: false,
|
||||
example: false,
|
||||
},
|
||||
|
|
|
@ -36,7 +36,7 @@ export const paramDef = {
|
|||
isAdministrator: { type: 'boolean' },
|
||||
isExplorable: { type: 'boolean', default: false }, // optional for backward compatibility
|
||||
asBadge: { type: 'boolean' },
|
||||
copyOnMoveAccount: { type: 'boolean' },
|
||||
preserveAssignmentOnMoveAccount: { type: 'boolean' },
|
||||
canEditMembersByModerator: { type: 'boolean' },
|
||||
displayOrder: { type: 'number' },
|
||||
policies: {
|
||||
|
|
|
@ -41,7 +41,7 @@ export const paramDef = {
|
|||
isAdministrator: { type: 'boolean' },
|
||||
isExplorable: { type: 'boolean' },
|
||||
asBadge: { type: 'boolean' },
|
||||
copyOnMoveAccount: { type: 'boolean' },
|
||||
preserveAssignmentOnMoveAccount: { type: 'boolean' },
|
||||
canEditMembersByModerator: { type: 'boolean' },
|
||||
displayOrder: { type: 'number' },
|
||||
policies: {
|
||||
|
@ -79,7 +79,7 @@ export default class extends Endpoint<typeof meta, typeof paramDef> { // eslint-
|
|||
isAdministrator: ps.isAdministrator,
|
||||
isExplorable: ps.isExplorable,
|
||||
asBadge: ps.asBadge,
|
||||
copyOnMoveAccount: ps.copyOnMoveAccount,
|
||||
preserveAssignmentOnMoveAccount: ps.preserveAssignmentOnMoveAccount,
|
||||
canEditMembersByModerator: ps.canEditMembersByModerator,
|
||||
displayOrder: ps.displayOrder,
|
||||
policies: ps.policies,
|
||||
|
|
|
@ -52,9 +52,9 @@ SPDX-License-Identifier: AGPL-3.0-only
|
|||
</div>
|
||||
</MkFolder>
|
||||
|
||||
<MkSwitch v-model="role.copyOnMoveAccount" :readonly="readonly">
|
||||
<template #label>{{ i18n.ts._role.copyOnMoveAccount }}</template>
|
||||
<template #caption>{{ i18n.ts._role.descriptionOfCopyOnMoveAccount }}</template>
|
||||
<MkSwitch v-model="role.preserveAssignmentOnMoveAccount" :readonly="readonly">
|
||||
<template #label>{{ i18n.ts._role.preserveAssignmentOnMoveAccount }}</template>
|
||||
<template #caption>{{ i18n.ts._role.preserveAssignmentOnMoveAccount_description }}</template>
|
||||
</MkSwitch>
|
||||
|
||||
<MkSwitch v-model="role.canEditMembersByModerator" :readonly="readonly">
|
||||
|
|
|
@ -5134,11 +5134,8 @@ export type components = {
|
|||
isExplorable: boolean;
|
||||
/** @example false */
|
||||
asBadge: boolean;
|
||||
/**
|
||||
* @description True if the role is going to be copied to dest account on account move.
|
||||
* @example false
|
||||
*/
|
||||
copyOnMoveAccount: boolean;
|
||||
/** @example false */
|
||||
preserveAssignmentOnMoveAccount: boolean;
|
||||
/** @example false */
|
||||
canEditMembersByModerator: boolean;
|
||||
policies: {
|
||||
|
@ -9397,7 +9394,7 @@ export type operations = {
|
|||
/** @default false */
|
||||
isExplorable?: boolean;
|
||||
asBadge: boolean;
|
||||
copyOnMoveAccount?: boolean;
|
||||
preserveAssignmentOnMoveAccount?: boolean;
|
||||
canEditMembersByModerator: boolean;
|
||||
displayOrder: number;
|
||||
policies: Record<string, never>;
|
||||
|
@ -9673,7 +9670,7 @@ export type operations = {
|
|||
isAdministrator?: boolean;
|
||||
isExplorable?: boolean;
|
||||
asBadge?: boolean;
|
||||
copyOnMoveAccount?: boolean;
|
||||
preserveAssignmentOnMoveAccount?: boolean;
|
||||
canEditMembersByModerator?: boolean;
|
||||
displayOrder?: number;
|
||||
policies?: Record<string, never>;
|
||||
|
|
Loading…
Reference in New Issue