codebase-models 2.1.9 → 2.1.10

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.
package/dist/index.js CHANGED
@@ -119,7 +119,7 @@ function seedRoles() {
119
119
  return __awaiter(this, void 0, void 0, function* () {
120
120
  const checkRoles = yield Role_1.default.countDocuments();
121
121
  if (checkRoles < 5) {
122
- Promise.all(["USER", "ADMIN", "EDITOR", "OPTIMIZER", "CLIENT"].map((name) => {
122
+ Promise.all(["USER", "ADMIN", "EDITOR", "OPTIMIZER", "CLIENT", "EXTERNAL"].map((name) => {
123
123
  Role_1.default.bulkWrite([
124
124
  {
125
125
  updateOne: {
@@ -30,6 +30,7 @@ export interface IClientReportsTemp extends Document {
30
30
  test?: mongoose.Schema.Types.ObjectId;
31
31
  filters?: string;
32
32
  metricsFilters?: string;
33
+ otherFilters?: mongoose.Schema.Types.Mixed;
33
34
  date?: Date;
34
35
  report?: mongoose.Schema.Types.Mixed;
35
36
  deactivated?: boolean;
@@ -49,6 +49,10 @@ const ClientReportsTempSchema = new mongoose_1.Schema({
49
49
  type: String,
50
50
  trim: true,
51
51
  },
52
+ otherFilters: {
53
+ type: mongoose_1.default.Schema.Types.Mixed,
54
+ default: {},
55
+ },
52
56
  date: {
53
57
  type: Date,
54
58
  },
package/index.ts CHANGED
@@ -54,7 +54,7 @@ async function seedRoles() {
54
54
  const checkRoles = await Role.countDocuments();
55
55
  if (checkRoles < 5) {
56
56
  Promise.all(
57
- ["USER", "ADMIN", "EDITOR", "OPTIMIZER", "CLIENT"].map((name) => {
57
+ ["USER", "ADMIN", "EDITOR", "OPTIMIZER", "CLIENT", "EXTERNAL"].map((name) => {
58
58
  Role.bulkWrite([
59
59
  {
60
60
  updateOne: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "codebase-models",
3
- "version": "2.1.9",
3
+ "version": "2.1.10",
4
4
  "description": "Common models for codebase",
5
5
  "main": "dist/index.js",
6
6
  "scripts": {
@@ -7,6 +7,7 @@ export interface IClientReportsTemp extends Document {
7
7
  test?: mongoose.Schema.Types.ObjectId;
8
8
  filters?: string;
9
9
  metricsFilters?: string;
10
+ otherFilters?: mongoose.Schema.Types.Mixed;
10
11
  date?: Date;
11
12
  report?: mongoose.Schema.Types.Mixed;
12
13
  deactivated?: boolean;
@@ -39,6 +40,10 @@ const ClientReportsTempSchema = new Schema<IClientReportsTemp>(
39
40
  type: String,
40
41
  trim: true,
41
42
  },
43
+ otherFilters: {
44
+ type: mongoose.Schema.Types.Mixed,
45
+ default: {},
46
+ },
42
47
  date: {
43
48
  type: Date,
44
49
  },