Skip to content

Commit

Permalink
add primarykey to pets table
Browse files Browse the repository at this point in the history
  • Loading branch information
trinity-y committed Jul 3, 2024
1 parent 0c8e034 commit 84a4eab
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions backend/typescript/models/pet.model.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import {
DataType,
ForeignKey,
BelongsTo,
PrimaryKey,
} from "sequelize-typescript";
import Animal_Type from "./animal_type.model";
// import { PetCareInfo } from "./PetCareInfo"
Expand All @@ -13,6 +14,7 @@ import { Letters } from "../types";

@Table({ timestamps: false, tableName: "pet" })
export default class Pet extends Model {
@PrimaryKey
@Column({ type: DataType.INTEGER })
id!: number;

Expand Down

0 comments on commit 84a4eab

Please sign in to comment.