add bg type
deploy to danak / build_and_deploy (push) Has been cancelled

This commit is contained in:
2026-06-22 11:36:05 +03:30
parent d357dcd224
commit 7ce2ddfe5d
4 changed files with 68 additions and 0 deletions
+50
View File
@@ -1025,6 +1025,16 @@
"length": 6,
"mappedType": "datetime"
},
"bg_type": {
"name": "bg_type",
"type": "varchar(255)",
"unsigned": false,
"autoincrement": false,
"primary": false,
"nullable": true,
"length": 255,
"mappedType": "string"
},
"bg_url": {
"name": "bg_url",
"type": "varchar(255)",
@@ -1246,6 +1256,26 @@
"length": 255,
"mappedType": "string"
},
"card_number2": {
"name": "card_number2",
"type": "varchar(255)",
"unsigned": false,
"autoincrement": false,
"primary": false,
"nullable": true,
"length": 255,
"mappedType": "string"
},
"card_number3": {
"name": "card_number3",
"type": "varchar(255)",
"unsigned": false,
"autoincrement": false,
"primary": false,
"nullable": true,
"length": 255,
"mappedType": "string"
},
"card_owner": {
"name": "card_owner",
"type": "varchar(255)",
@@ -1256,6 +1286,26 @@
"length": 255,
"mappedType": "string"
},
"card_owner2": {
"name": "card_owner2",
"type": "varchar(255)",
"unsigned": false,
"autoincrement": false,
"primary": false,
"nullable": true,
"length": 255,
"mappedType": "string"
},
"card_owner3": {
"name": "card_owner3",
"type": "varchar(255)",
"unsigned": false,
"autoincrement": false,
"primary": false,
"nullable": true,
"length": 255,
"mappedType": "string"
},
"enabled": {
"name": "enabled",
"type": "boolean",
@@ -0,0 +1,10 @@
import { Migration } from '@mikro-orm/migrations';
export class Migration20260622080529 extends Migration {
override async up(): Promise<void> {
this.addSql(`alter table "restaurants" add column "bg_type" varchar(255) null;`);
}
}
@@ -2,6 +2,11 @@ import { ApiPropertyOptional } from '@nestjs/swagger';
import { IsOptional, IsString } from 'class-validator';
export class UpdateRestaurantBgDto {
@ApiPropertyOptional({ example: 'image', description: 'نوع پس‌زمینه' })
@IsOptional()
@IsString()
bgType?: string;
@ApiPropertyOptional({ example: 'https://cdn.example.com/backgrounds/wood.jpg', description: 'آدرس تصویر پس‌زمینه' })
@IsOptional()
@IsString()
@@ -109,6 +109,9 @@ export class Restaurant extends BaseEntity {
@Property({ nullable: true })
subscriptionStartDate?: Date;
@Property({ nullable: true })
bgType?: string;
@Property({ nullable: true })
bgUrl?: string;