@dynamatix/cat-shared 0.0.33 → 0.0.34

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.
@@ -1,5 +1,10 @@
1
1
  import mongoose from 'mongoose';
2
2
 
3
+ const optionSchema = new mongoose.Schema({
4
+ key: { type: mongoose.Schema.Types.Mixed },
5
+ value: { type: mongoose.Schema.Types.Mixed }
6
+ }, { _id: false });
7
+
3
8
  const formfieldSchema = new mongoose.Schema({
4
9
  fieldName: {
5
10
  type: String,
@@ -56,10 +61,7 @@ const formfieldSchema = new mongoose.Schema({
56
61
  type: mongoose.Schema.Types.Mixed,
57
62
  default: null
58
63
  },
59
- options: [{
60
- key: { type: mongoose.Schema.Types.Number || mongoose.Schema.Types.String },
61
- value: { type: mongoose.Schema.Types.String || mongoose.Schema.Types.Number },
62
- }],
64
+ options: [optionSchema],
63
65
  section: {
64
66
  type: String,
65
67
  default: null
@@ -108,7 +110,7 @@ const formfieldSchema = new mongoose.Schema({
108
110
  type: Boolean,
109
111
  default: false
110
112
  }
111
- }, { timestamps: true });
113
+ }, { timestamps: true , _id: false });
112
114
 
113
115
  const formConfigurationSchema = new mongoose.Schema({
114
116
  formName: {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@dynamatix/cat-shared",
3
- "version": "0.0.33",
3
+ "version": "0.0.34",
4
4
  "main": "index.js",
5
5
  "scripts": {
6
6
  "test": "echo \"Error: no test specified\" && exit 1"