🔂 Merge master into branch
This commit is contained in:
@@ -24,9 +24,13 @@ export default {
|
||||
const isSubPag = !!this.$store.state.currentConfigInfo;
|
||||
const jsonConfig = config;
|
||||
if (isSubPag) delete jsonConfig.appConfig;
|
||||
jsonConfig.sections = jsonConfig.sections.map(({ filteredItems, ...section }) => section);
|
||||
|
||||
// 2. Convert JSON into YAML
|
||||
const yamlOptions = {};
|
||||
const yaml = jsYaml.dump(jsonConfig, yamlOptions);
|
||||
const strjsonConfig = JSON.stringify(jsonConfig);
|
||||
const jsonObj = JSON.parse(strjsonConfig);
|
||||
const yaml = jsYaml.dump(jsonObj, yamlOptions);
|
||||
// 3. Prepare the request
|
||||
const baseUrl = process.env.VUE_APP_DOMAIN || window.location.origin;
|
||||
const endpoint = `${baseUrl}${serviceEndpoints.save}`;
|
||||
|
||||
@@ -148,13 +148,13 @@ const HomeMixin = {
|
||||
}
|
||||
},
|
||||
/* Returns true if there is more than 1 sub-result visible during searching */
|
||||
checkIfResults() {
|
||||
if (!this.sections) return false;
|
||||
checkIfResults(sections) {
|
||||
if (!sections) return false;
|
||||
else {
|
||||
let itemsFound = true;
|
||||
this.sections.forEach((section) => {
|
||||
sections.forEach((section) => {
|
||||
if (section.widgets && section.widgets.length > 0) itemsFound = false;
|
||||
if (this.filterTiles(section.items, this.searchValue).length > 0) itemsFound = false;
|
||||
if (section.filteredItems.length > 0) itemsFound = false;
|
||||
});
|
||||
return itemsFound;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user