mirror of
https://github.com/cheveguerra/whaticket-community.git
synced 2026-04-19 20:29:17 +00:00
add validation to whatsapp name
This commit is contained in:
@@ -9,7 +9,8 @@ import {
|
||||
AutoIncrement,
|
||||
Default,
|
||||
AllowNull,
|
||||
HasMany
|
||||
HasMany,
|
||||
Unique
|
||||
} from "sequelize-typescript";
|
||||
import Ticket from "./Ticket";
|
||||
|
||||
@@ -20,6 +21,8 @@ class Whatsapp extends Model<Whatsapp> {
|
||||
@Column
|
||||
id: number;
|
||||
|
||||
@AllowNull
|
||||
@Unique
|
||||
@Column(DataType.TEXT)
|
||||
name: string;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user