@kipicore/dbcore 1.1.565 → 1.1.566

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,2 @@
1
+ export function up(queryInterface: any, Sequelize: any): Promise<void>;
2
+ export function down(queryInterface: any): Promise<void>;
@@ -0,0 +1,21 @@
1
+ 'use strict';
2
+ const up = async (queryInterface, Sequelize) => {
3
+ const table = await queryInterface.describeTable('institutes');
4
+ if (!table.is_play_house) {
5
+ await queryInterface.addColumn('institutes', 'is_play_house', {
6
+ type: Sequelize.BOOLEAN,
7
+ allowNull: true,
8
+ defaultValue: false,
9
+ });
10
+ }
11
+ };
12
+ const down = async (queryInterface) => {
13
+ const table = await queryInterface.describeTable('institutes');
14
+ if (table.is_play_house) {
15
+ await queryInterface.removeColumn('institutes', 'is_play_house');
16
+ }
17
+ };
18
+ module.exports = {
19
+ up,
20
+ down,
21
+ };
@@ -41,4 +41,5 @@ export interface IInstituteAttributes extends IDefaultAttributes {
41
41
  mobileVerification?: MOBILE_VERIFICATION;
42
42
  trialPlanCount: number;
43
43
  partnersIds?: string[];
44
+ isPlayHouse?: boolean;
44
45
  }
@@ -42,6 +42,7 @@ declare class InstituteModel extends Model<IInstituteAttributes, TInstituteCreat
42
42
  emailVerification?: EMAIL_VERIFICATION;
43
43
  mobileVerification?: MOBILE_VERIFICATION;
44
44
  partnersIds?: string[];
45
+ isPlayHouse: boolean;
45
46
  createdBy: string;
46
47
  updatedBy: string;
47
48
  deletedBy: string;
@@ -148,6 +148,12 @@ InstituteModel.init({
148
148
  allowNull: true,
149
149
  field: 'partners_ids',
150
150
  },
151
+ isPlayHouse: {
152
+ type: sequelize_1.DataTypes.BOOLEAN,
153
+ field: 'is_play_house',
154
+ defaultValue: false,
155
+ allowNull: true,
156
+ },
151
157
  }, {
152
158
  modelName: 'InstituteModel',
153
159
  tableName: 'institutes',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kipicore/dbcore",
3
- "version": "1.1.565",
3
+ "version": "1.1.566",
4
4
  "description": "Reusable DB core package with Postgres, MongoDB, models, services, interfaces, and types",
5
5
  "types": "dist/index.d.ts",
6
6
  "main": "dist/index.js",