base structure for list printing with custom template
This commit is contained in:
parent
e2a916f37d
commit
a085de6e2f
19 changed files with 279 additions and 98 deletions
25
src/migrations/1742311486232-listprinting.ts
Normal file
25
src/migrations/1742311486232-listprinting.ts
Normal file
|
@ -0,0 +1,25 @@
|
|||
import { MigrationInterface, QueryRunner } from "typeorm";
|
||||
import { templateUsage } from "../entity/configuration/templateUsage";
|
||||
|
||||
export class Listprinting1742311486232 implements MigrationInterface {
|
||||
name = "Listprinting1742311486232";
|
||||
|
||||
public async up(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.manager
|
||||
.createQueryBuilder()
|
||||
.delete()
|
||||
.from(templateUsage)
|
||||
.where({ scope: "member.list" })
|
||||
.execute();
|
||||
}
|
||||
|
||||
public async down(queryRunner: QueryRunner): Promise<void> {
|
||||
await queryRunner.manager
|
||||
.createQueryBuilder()
|
||||
.insert()
|
||||
.into(templateUsage)
|
||||
.values([{ scope: "member.list" }])
|
||||
.orUpdate(["headerId", "bodyId", "footerId", "headerHeight", "footerHeight"], ["scope"])
|
||||
.execute();
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue