Skip to content

Commit 094568c

Browse files
committed
feat(create): copy from existing entry
1 parent 014e0e1 commit 094568c

83 files changed

Lines changed: 1981 additions & 48 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

apps/keira/src/app/routes.ts

Lines changed: 103 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { DashboardComponent } from '@keira/features/dashboard';
44

55
import { ConditionsComponent, ConditionsHandlerService, SelectConditionsComponent } from '@keira/features/conditions';
66
import {
7+
CreatureCopyComponent,
78
CreatureEquipTemplateComponent,
89
CreatureFormationsComponent,
910
CreatureHandlerService,
@@ -28,6 +29,7 @@ import {
2829
} from '@keira/features/creature';
2930
import {
3031
GameobjectHandlerService,
32+
GameobjectCopyComponent,
3133
GameobjectLootTemplateComponent,
3234
GameobjectQuestitemComponent,
3335
GameobjectSpawnAddonComponent,
@@ -37,11 +39,18 @@ import {
3739
SaiGameobjectComponent,
3840
SelectGameobjectComponent,
3941
} from '@keira/features/gameobject';
40-
import { GossipHandlerService, GossipMenuComponent, GossipMenuOptionComponent, SelectGossipComponent } from '@keira/features/gossip';
42+
import {
43+
GossipHandlerService,
44+
GossipMenuComponent,
45+
GossipMenuOptionComponent,
46+
SelectGossipComponent,
47+
GossipCopyComponent,
48+
} from '@keira/features/gossip';
4149
import {
4250
DisenchantLootTemplateComponent,
4351
ItemEnchantmentTemplateComponent,
4452
ItemHandlerService,
53+
ItemCopyComponent,
4554
ItemLootTemplateComponent,
4655
ItemTemplateComponent,
4756
MillingLootTemplateComponent,
@@ -53,6 +62,10 @@ import {
5362
FishingLootTemplateComponent,
5463
MailLootHandlerService,
5564
MailLootTemplateComponent,
65+
FishingLootCopyComponent,
66+
SpellLootCopyComponent,
67+
MailLootCopyComponent,
68+
ReferenceLootCopyComponent,
5669
ReferenceLootHandlerService,
5770
ReferenceLootTemplateComponent,
5871
SelectFishingLootComponent,
@@ -74,9 +87,10 @@ import {
7487
QuestTemplateLocaleComponent,
7588
QuestTemplateComponent,
7689
SelectQuestComponent,
90+
QuestCopyComponent,
7791
} from '@keira/features/quest';
7892
import { SaiFullEditorComponent, SaiSearchEntityComponent, SaiSearchExistingComponent } from '@keira/features/smart-scripts';
79-
import { SelectSpellComponent, SpellDbcComponent } from '@keira/features/spell';
93+
import { SelectSpellComponent, SpellDbcComponent, SpellCopyComponent, SpellHandlerService } from '@keira/features/spell';
8094
import { SqlEditorComponent } from '@keira/features/sql-editor';
8195
import { SaiHandlerService } from '@keira/shared/sai-editor';
8296
import {
@@ -86,15 +100,25 @@ import {
86100
NpcTextHandlerService,
87101
PageTextComponent,
88102
PageTextHandlerService,
103+
PageTextCopyComponent,
104+
NpcTextCopyComponent,
89105
SelectBroadcastTextComponent,
90106
SelectNpcTextComponent,
91107
SelectPageTextComponent,
92108
AcoreStringComponent,
93109
AcoreStringHandlerService,
110+
AcoreStringCopyComponent,
94111
SelectAcoreStringComponent,
95112
} from 'texts';
96-
import { GameTeleComponent, GameTeleHandlerService, SelectGameTeleComponent } from '@keira/features/game-tele';
97-
import { SelectTrainerComponent, TrainerComponent, TrainerHandlerService, TrainerSpellComponent } from '@keira/features/trainer';
113+
import {
114+
SelectTrainerComponent,
115+
TrainerCopyComponent,
116+
TrainerComponent,
117+
TrainerHandlerService,
118+
TrainerSpellComponent,
119+
} from '@keira/features/trainer';
120+
import { GameTeleComponent, GameTeleHandlerService, SelectGameTeleComponent, GameTeleCopyComponent } from '@keira/features/game-tele';
121+
98122
import { UnusedGuidSearchComponent } from '@keira/features/unused-guid-search';
99123

100124
export const KEIRA_ROUTES: Routes = [
@@ -113,6 +137,11 @@ export const KEIRA_ROUTES: Routes = [
113137
path: 'select',
114138
component: SelectCreatureComponent,
115139
},
140+
{
141+
path: 'copy',
142+
component: CreatureCopyComponent,
143+
canActivate: [CreatureHandlerService],
144+
},
116145
{
117146
path: 'creature-template',
118147
component: CreatureTemplateComponent,
@@ -223,6 +252,11 @@ export const KEIRA_ROUTES: Routes = [
223252
component: QuestTemplateComponent,
224253
canActivate: [QuestHandlerService],
225254
},
255+
{
256+
path: 'copy',
257+
component: QuestCopyComponent,
258+
canActivate: [QuestHandlerService],
259+
},
226260
{
227261
path: 'quest-template-addon',
228262
component: QuestTemplateAddonComponent,
@@ -277,6 +311,11 @@ export const KEIRA_ROUTES: Routes = [
277311
component: GameobjectTemplateComponent,
278312
canActivate: [GameobjectHandlerService],
279313
},
314+
{
315+
path: 'copy',
316+
component: GameobjectCopyComponent,
317+
canActivate: [GameobjectHandlerService],
318+
},
280319
{
281320
path: 'gameobject-template-addon',
282321
component: GameobjectTemplateAddonComponent,
@@ -321,6 +360,11 @@ export const KEIRA_ROUTES: Routes = [
321360
component: ItemTemplateComponent,
322361
canActivate: [ItemHandlerService],
323362
},
363+
{
364+
path: 'copy',
365+
component: ItemCopyComponent,
366+
canActivate: [ItemHandlerService],
367+
},
324368
{
325369
path: 'item-enchantment-template',
326370
component: ItemEnchantmentTemplateComponent,
@@ -360,6 +404,16 @@ export const KEIRA_ROUTES: Routes = [
360404
component: ReferenceLootTemplateComponent,
361405
canActivate: [ReferenceLootHandlerService],
362406
},
407+
{
408+
path: 'reference-copy',
409+
component: ReferenceLootCopyComponent,
410+
canActivate: [ReferenceLootHandlerService],
411+
},
412+
{
413+
path: 'spell-copy',
414+
component: SpellLootCopyComponent,
415+
canActivate: [SpellLootHandlerService],
416+
},
363417
{
364418
path: 'select-spell',
365419
component: SelectSpellLootComponent,
@@ -378,6 +432,11 @@ export const KEIRA_ROUTES: Routes = [
378432
component: FishingLootTemplateComponent,
379433
canActivate: [FishingLootHandlerService],
380434
},
435+
{
436+
path: 'fishing-copy',
437+
component: FishingLootCopyComponent,
438+
canActivate: [FishingLootHandlerService],
439+
},
381440
{
382441
path: 'select-mail',
383442
component: SelectMailLootComponent,
@@ -387,6 +446,11 @@ export const KEIRA_ROUTES: Routes = [
387446
component: MailLootTemplateComponent,
388447
canActivate: [MailLootHandlerService],
389448
},
449+
{
450+
path: 'mail-copy',
451+
component: MailLootCopyComponent,
452+
canActivate: [MailLootHandlerService],
453+
},
390454
],
391455
},
392456
{
@@ -396,6 +460,11 @@ export const KEIRA_ROUTES: Routes = [
396460
path: 'select-page-text',
397461
component: SelectPageTextComponent,
398462
},
463+
{
464+
path: 'page-text-copy',
465+
component: PageTextCopyComponent,
466+
canActivate: [PageTextHandlerService],
467+
},
399468
{
400469
path: 'page-text',
401470
component: PageTextComponent,
@@ -414,6 +483,11 @@ export const KEIRA_ROUTES: Routes = [
414483
path: 'select-npc-text',
415484
component: SelectNpcTextComponent,
416485
},
486+
{
487+
path: 'npc-text-copy',
488+
component: NpcTextCopyComponent,
489+
canActivate: [NpcTextHandlerService],
490+
},
417491
{
418492
path: 'npc-text',
419493
component: NpcTextComponent,
@@ -424,6 +498,11 @@ export const KEIRA_ROUTES: Routes = [
424498
component: AcoreStringComponent,
425499
canActivate: [AcoreStringHandlerService],
426500
},
501+
{
502+
path: 'acore-string-copy',
503+
component: AcoreStringCopyComponent,
504+
canActivate: [AcoreStringHandlerService],
505+
},
427506
{
428507
path: 'select-acore-string',
429508
component: SelectAcoreStringComponent,
@@ -437,6 +516,11 @@ export const KEIRA_ROUTES: Routes = [
437516
path: 'select',
438517
component: SelectGossipComponent,
439518
},
519+
{
520+
path: 'copy',
521+
component: GossipCopyComponent,
522+
canActivate: [GossipHandlerService],
523+
},
440524
{
441525
path: 'gossip-menu',
442526
component: GossipMenuComponent,
@@ -492,6 +576,11 @@ export const KEIRA_ROUTES: Routes = [
492576
path: 'spell-dbc',
493577
component: SpellDbcComponent,
494578
},
579+
{
580+
path: 'copy',
581+
component: SpellCopyComponent,
582+
canActivate: [SpellHandlerService],
583+
},
495584
],
496585
},
497586
{
@@ -501,6 +590,11 @@ export const KEIRA_ROUTES: Routes = [
501590
path: 'select',
502591
component: SelectGameTeleComponent,
503592
},
593+
{
594+
path: 'copy',
595+
component: GameTeleCopyComponent,
596+
canActivate: [GameTeleHandlerService],
597+
},
504598
{
505599
path: 'tele',
506600
component: GameTeleComponent,
@@ -515,6 +609,11 @@ export const KEIRA_ROUTES: Routes = [
515609
path: 'select',
516610
component: SelectTrainerComponent,
517611
},
612+
{
613+
path: 'copy',
614+
component: TrainerCopyComponent,
615+
canActivate: [TrainerHandlerService],
616+
},
518617
{
519618
path: 'trainer',
520619
component: TrainerComponent,

apps/keira/src/assets/i18n/en.json

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,12 @@
1414
"CREATE_A_NEW": "Create a new <strong>{{ ENTITY_TABLE }}</strong> by selecting an empty <strong>{{ ENTITY_ID_FIELD }}</strong>:",
1515
"FREE_ENTRY": "The {{ ENTITY_ID_FIELD }} is",
1616
"FREE": "free",
17-
"ALREADY_USE": "already in use"
17+
"ALREADY_USE": "already in use",
18+
"SOURCE_ENTRY": "The {{ ENTITY_ID_FIELD }}",
19+
"EXISTS": "exists",
20+
"DOES_NOT_EXIST": "does not exist",
21+
"START_FROM_BLANK": "Start from blank",
22+
"COPY_FROM_EXISTING": "Copy from existing"
1823
},
1924
"CONNECTED": "Connected",
2025
"SEARCH": "Search",
@@ -205,6 +210,19 @@
205210
"LEARN_SQL": "learn the SQL language",
206211
"AFFECTED_ROWS": "Affected rows:"
207212
},
213+
"COPY_OUTPUT": {
214+
"TITLE": "Copy Entry SQL",
215+
"DESCRIPTION": "Review and execute the SQL below to copy the entry. You can copy the query to execute it manually, or use the Execute button to run it directly.",
216+
"COPY": "Copy",
217+
"COPY_TOOLTIP": "Copy SQL query to clipboard",
218+
"EXECUTE": "Execute",
219+
"EXECUTE_TOOLTIP": "Execute the SQL query and create the new entry",
220+
"EXECUTED": "Executed",
221+
"CONTINUE": "Continue to Editor",
222+
"CONTINUE_TOOLTIP": "Navigate to the editor for the new entry",
223+
"SELECT_ALL": "Select All",
224+
"SELECT_NONE": "Select None"
225+
},
208226
"CREATURE": {
209227
"TEMPLATE": {
210228
"BASE": "Base",

apps/keira/src/assets/i18n/es.json

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,12 @@
1414
"CREATE_A_NEW": "Crear nuevo <strong>{{ ENTITY_TABLE }}</strong> seleccionando un <strong>{{ ENTITY_ID_FIELD }}</strong>:",
1515
"FREE_ENTRY": "El o La {{ ENTITY_ID_FIELD }} es",
1616
"FREE": "Libre",
17-
"ALREADY_USE": "Está en uso"
17+
"ALREADY_USE": "Está en uso",
18+
"SOURCE_ENTRY": "The {{ ENTITY_ID_FIELD }}",
19+
"EXISTS": "exists",
20+
"DOES_NOT_EXIST": "does not exist",
21+
"START_FROM_BLANK": "Start from blank",
22+
"COPY_FROM_EXISTING": "Copy from existing"
1823
},
1924
"CONNECTED": "Conectado",
2025
"SEARCH": "Buscar",
@@ -205,6 +210,19 @@
205210
"LEARN_SQL": "Aprenda el Lenguaje SQL",
206211
"AFFECTED_ROWS": "Líneas afectadas:"
207212
},
213+
"COPY_OUTPUT": {
214+
"TITLE": "Copy Entry SQL",
215+
"DESCRIPTION": "Review and execute the SQL below to copy the entry. You can copy the query to execute it manually, or use the Execute button to run it directly.",
216+
"COPY": "Copy",
217+
"COPY_TOOLTIP": "Copy SQL query to clipboard",
218+
"EXECUTE": "Execute",
219+
"EXECUTE_TOOLTIP": "Execute the SQL query and create the new entry",
220+
"EXECUTED": "Executed",
221+
"CONTINUE": "Continue to Editor",
222+
"CONTINUE_TOOLTIP": "Navigate to the editor for the new entry",
223+
"SELECT_ALL": "Select All",
224+
"SELECT_NONE": "Select None"
225+
},
208226
"CREATURE": {
209227
"TEMPLATE": {
210228
"BASE": "Base",

apps/keira/src/assets/i18n/ru.json

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,12 @@
1414
"CREATE_A_NEW": "Создать новый <strong>{{ ENTITY_TABLE }}</strong> выбрав пустой <strong>{{ ENTITY_ID_FIELD }}</strong>:",
1515
"FREE_ENTRY": "Значение {{ ENTITY_ID_FIELD }}",
1616
"FREE": "свободно",
17-
"ALREADY_USE": "уже используется"
17+
"ALREADY_USE": "уже используется",
18+
"SOURCE_ENTRY": "The {{ ENTITY_ID_FIELD }}",
19+
"EXISTS": "exists",
20+
"DOES_NOT_EXIST": "does not exist",
21+
"START_FROM_BLANK": "Start from blank",
22+
"COPY_FROM_EXISTING": "Copy from existing"
1823
},
1924
"CONNECTED": "Connected",
2025
"SEARCH": "Поиск",
@@ -205,6 +210,19 @@
205210
"LEARN_SQL": "изучить язык SQL",
206211
"AFFECTED_ROWS": "Затронутые строки:"
207212
},
213+
"COPY_OUTPUT": {
214+
"TITLE": "Copy Entry SQL",
215+
"DESCRIPTION": "Review and execute the SQL below to copy the entry. You can copy the query to execute it manually, or use the Execute button to run it directly.",
216+
"COPY": "Copy",
217+
"COPY_TOOLTIP": "Copy SQL query to clipboard",
218+
"EXECUTE": "Execute",
219+
"EXECUTE_TOOLTIP": "Execute the SQL query and create the new entry",
220+
"EXECUTED": "Executed",
221+
"CONTINUE": "Continue to Editor",
222+
"CONTINUE_TOOLTIP": "Navigate to the editor for the new entry",
223+
"SELECT_ALL": "Select All",
224+
"SELECT_NONE": "Select None"
225+
},
208226
"CREATURE": {
209227
"TEMPLATE": {
210228
"BASE": "Base",

apps/keira/src/assets/i18n/zh.json

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,12 @@
1414
"CREATE_A_NEW": "新建一个 <strong>{{ ENTITY_TABLE }}</strong>,选择一个未使用的 <strong>{{ ENTITY_ID_FIELD }}</strong>:",
1515
"FREE_ENTRY": "{{ ENTITY_ID_FIELD }}是",
1616
"FREE": "可用的",
17-
"ALREADY_USE": "已在使用中"
17+
"ALREADY_USE": "已在使用中",
18+
"SOURCE_ENTRY": "The {{ ENTITY_ID_FIELD }}",
19+
"EXISTS": "exists",
20+
"DOES_NOT_EXIST": "does not exist",
21+
"START_FROM_BLANK": "Start from blank",
22+
"COPY_FROM_EXISTING": "Copy from existing"
1823
},
1924
"CONNECTED": "连接",
2025
"SEARCH": "搜索",
@@ -205,6 +210,19 @@
205210
"LEARN_SQL": "学习SQL语言",
206211
"AFFECTED_ROWS": "受影响的行:"
207212
},
213+
"COPY_OUTPUT": {
214+
"TITLE": "Copy Entry SQL",
215+
"DESCRIPTION": "Review and execute the SQL below to copy the entry. You can copy the query to execute it manually, or use the Execute button to run it directly.",
216+
"COPY": "Copy",
217+
"COPY_TOOLTIP": "Copy SQL query to clipboard",
218+
"EXECUTE": "Execute",
219+
"EXECUTE_TOOLTIP": "Execute the SQL query and create the new entry",
220+
"EXECUTED": "Executed",
221+
"CONTINUE": "Continue to Editor",
222+
"CONTINUE_TOOLTIP": "Navigate to the editor for the new entry",
223+
"SELECT_ALL": "Select All",
224+
"SELECT_NONE": "Select None"
225+
},
208226
"CREATURE": {
209227
"TEMPLATE": {
210228
"BASE": "基础",

0 commit comments

Comments
 (0)