@hulkapps/app-manager-vue 2.2.7 → 2.2.8
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/package.json
CHANGED
|
@@ -238,6 +238,7 @@
|
|
|
238
238
|
plan: {},
|
|
239
239
|
plans: [],
|
|
240
240
|
features: [],
|
|
241
|
+
featureValues: [],
|
|
241
242
|
featuresByGroup: [],
|
|
242
243
|
shopify_plan: '',
|
|
243
244
|
default_plan_id: null,
|
|
@@ -342,7 +343,12 @@
|
|
|
342
343
|
} else return feature.value
|
|
343
344
|
}
|
|
344
345
|
else if(feature?.value_type === 'array') {
|
|
345
|
-
|
|
346
|
+
let values= JSON.parse(feature.value);
|
|
347
|
+
let that = this;
|
|
348
|
+
values = values.map(function(value){
|
|
349
|
+
return that.featureValues[feature.feature_id][value];
|
|
350
|
+
});
|
|
351
|
+
return values.join(', ')
|
|
346
352
|
}
|
|
347
353
|
else if(feature?.value_type === 'string') {
|
|
348
354
|
return feature.value.replace('"', '').replace('"', '')
|
|
@@ -417,6 +423,13 @@
|
|
|
417
423
|
this.features = this.features?.sort((featureA, featureB) => parseInt(featureA.display_order) - parseInt(featureB.display_order))
|
|
418
424
|
this.features = this.features?.sort((featureA, featureB) => parseInt(featureA.group_order) - parseInt(featureB.group_order))
|
|
419
425
|
this.featuresByGroup = this.groupBy(this.features, 'group')
|
|
426
|
+
|
|
427
|
+
//Get feature array time values
|
|
428
|
+
this.features.forEach((feature) => {
|
|
429
|
+
if(feature.value_type == 'array'){
|
|
430
|
+
this.featureValues[feature.uuid] = feature.values;
|
|
431
|
+
}
|
|
432
|
+
});
|
|
420
433
|
}
|
|
421
434
|
},
|
|
422
435
|
async fetchPlans() {
|
|
@@ -477,7 +490,6 @@
|
|
|
477
490
|
await this.fetchFeatures();
|
|
478
491
|
await this.fetchPlans();
|
|
479
492
|
this.planLoading = false;
|
|
480
|
-
console.log(this.shop.plan.price);
|
|
481
493
|
}
|
|
482
494
|
}
|
|
483
495
|
</script>
|
|
@@ -212,6 +212,7 @@
|
|
|
212
212
|
plan: {},
|
|
213
213
|
plans: [],
|
|
214
214
|
features: [],
|
|
215
|
+
featureValues:[],
|
|
215
216
|
shopify_plan: '',
|
|
216
217
|
default_plan_id: null,
|
|
217
218
|
onboard: true,
|
|
@@ -345,7 +346,12 @@
|
|
|
345
346
|
} else return feature.value
|
|
346
347
|
}
|
|
347
348
|
else if(feature?.value_type === 'array') {
|
|
348
|
-
|
|
349
|
+
let values= JSON.parse(feature.value);
|
|
350
|
+
let that = this;
|
|
351
|
+
values = values.map(function(value){
|
|
352
|
+
return that.featureValues[feature.feature_id][value];
|
|
353
|
+
});
|
|
354
|
+
return values.join(', ')
|
|
349
355
|
}
|
|
350
356
|
else if(feature?.value_type === 'string') {
|
|
351
357
|
return feature.value.replace('"', '').replace('"', '')
|
|
@@ -461,7 +467,13 @@
|
|
|
461
467
|
if (data.features.length) {
|
|
462
468
|
this.features = data.features;
|
|
463
469
|
this.features = this.features?.filter((item) => item.hidden_feature !== true)
|
|
464
|
-
this.features = this.features?.sort((featureA, featureB) => parseInt(featureA.display_order) - parseInt(featureB.display_order))
|
|
470
|
+
this.features = this.features?.sort((featureA, featureB) => parseInt(featureA.display_order) - parseInt(featureB.display_order));
|
|
471
|
+
//Get feature array time values
|
|
472
|
+
this.features.forEach((feature) => {
|
|
473
|
+
if(feature.value_type == 'array'){
|
|
474
|
+
this.featureValues[feature.uuid] = feature.values;
|
|
475
|
+
}
|
|
476
|
+
});
|
|
465
477
|
}
|
|
466
478
|
},
|
|
467
479
|
async fetchPlans() {
|