@positivegrid/pg-mongoose-schema 27.6.0 → 27.6.1

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/models/payment.js CHANGED
@@ -38,11 +38,11 @@ const _oemMetaToLicenseName = function (redeemMeta) {
38
38
  return (!ret) ? null : { 'oem_name': redeemMeta['OEM_Name'], 'license_name': ret.display_name }
39
39
  }
40
40
 
41
- module.exports = function (mongoose) {
41
+ module.exports = (mongoose) => {
42
42
  const Schema = mongoose.Schema
43
43
  const ObjectId = Schema.Types.ObjectId
44
44
 
45
- let ProductSchema = new Schema({
45
+ const ProductSchema = new Schema({
46
46
  sku: { type: String, required: true, unique: true },
47
47
  name: { type: String, required: true }, // jamup/bias(AMP1)/live(FX1)/amp2/fx2/pedal/proseries
48
48
  display_name: { type: String, required: true },
@@ -55,6 +55,7 @@ module.exports = function (mongoose) {
55
55
  version: { type: String, required: true },
56
56
  max_purchase: { type: Number },
57
57
  can_upgrade_addition: { type: Boolean },
58
+ can_free_trial: { type: Boolean, default: false },
58
59
  upgrade: {
59
60
  to: { type: ObjectId },
60
61
  price: { type: Number },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@positivegrid/pg-mongoose-schema",
3
- "version": "27.6.0",
3
+ "version": "27.6.1",
4
4
  "description": "Positive Grid mongoose schema",
5
5
  "author": "Ferrari Lee <shiyung@positivegrid.com>",
6
6
  "homepage": "https://git.positivegrid.com:8443/backend/pg-mongoose-schema",