diff --git a/src/api.ts b/src/api.ts
index 647ad30..5d674cf 100644
--- a/src/api.ts
+++ b/src/api.ts
@@ -60,12 +60,12 @@ export async function get_templates(url: string) {
links: [{ telegram: "", mail: "", site: "" }],
preview: "https://api.agorata.io/static/mountain.jpg",
},
- {
- title: "",
- description: "",
- links: [{ telegram: "", mail: "", site: "" }],
- preview: "https://api.agorata.io/static/mountain.jpg",
- },
+ // {
+ // title: "",
+ // description: "",
+ // links: [{ telegram: "", mail: "", site: "" }],
+ // preview: "https://api.agorata.io/static/mountain.jpg",
+ // },
])
);
}
diff --git a/src/components/TemplatesList.vue b/src/components/TemplatesList.vue
index a20cfa5..02ba34b 100644
--- a/src/components/TemplatesList.vue
+++ b/src/components/TemplatesList.vue
@@ -24,6 +24,17 @@
v-model="constructor_params.description"
>
+
Add link:
= new Map();
template_id: string;
+ picture: string;
+ blog: string[];
constructor(
domain: string,
title: string = "",
description: string = "",
contacts: Map = new Map(),
- template_id: string = ""
+ template_id: string = "",
+ picture: string = "",
+ blog = []
) {
this.domain = domain;
this.title = title;
this.description = description;
this.contacts = contacts;
this.template_id = template_id;
+ this.picture = picture;
+ this.blog = blog;
}
copy(): SiteConstructorParams {
@@ -256,6 +262,8 @@ export async function get_constr_params(domain: string) {
res.title,
res.description,
res.contacts,
- res.template_id
+ res.template_id,
+ res.picture,
+ res.blog
);
}
diff --git a/src/views/Explore.vue b/src/views/Explore.vue
index 1c2f8f5..f90b2f5 100644
--- a/src/views/Explore.vue
+++ b/src/views/Explore.vue
@@ -308,7 +308,18 @@ export default {
await this.saveSite();
}
this.constructor_params.domain = this.domain;
- await call_api_post("set-site-data", this.constructor_params);
+ console.log("this.constructor_params", this.constructor_params);
+ await call_api_post("set-site-data", {
+ ...this.constructor_params,
+ blog:
+ this.constructor_params.template_id === "Template #3"
+ ? [
+ "Ipsum dolor sit amet",
+ "Consectetur adipiscing elit",
+ "Sed do eiusmod tempor",
+ ]
+ : undefined,
+ });
this.saved_constructor_params = this.constructor_params;
this.updSettingsComponent();
},