mirror of
https://code.lenaisten.de/Lenaisten/advent22.git
synced 2024-11-23 00:03:07 +00:00
reflect api changes in UI
This commit is contained in:
parent
3316bf2822
commit
20375f2c9d
6 changed files with 7 additions and 7 deletions
|
@ -3,7 +3,7 @@
|
|||
|
||||
<figure>
|
||||
<div class="image is-unselectable">
|
||||
<img :src="$advent22.api_url('general/background')" />
|
||||
<img :src="$advent22.api_url('images/background')" />
|
||||
<ThouCanvas>
|
||||
<CalendarDoor
|
||||
v-for="(door, index) in doors"
|
||||
|
|
|
@ -70,7 +70,7 @@ export default class extends Vue {
|
|||
this.$refs.multi_modal.show_progress();
|
||||
|
||||
this.$advent22
|
||||
.api_get_blob(`days/image/${day}`)
|
||||
.api_get_blob(`images/${day}`)
|
||||
.then((data) => this.$refs.multi_modal.show_image(data))
|
||||
.catch(() => this.$refs.multi_modal.set_active(false));
|
||||
}
|
||||
|
|
|
@ -76,7 +76,7 @@ export default class extends Vue {
|
|||
public doors: Door[] = [];
|
||||
|
||||
private load_doors(): Promise<void | DoorsSaved> {
|
||||
return this.$advent22.api_get<DoorsSaved>("general/doors").then((data) => {
|
||||
return this.$advent22.api_get<DoorsSaved>("admin/doors").then((data) => {
|
||||
this.doors.length = 0;
|
||||
|
||||
for (const value of data) {
|
||||
|
@ -96,7 +96,7 @@ export default class extends Vue {
|
|||
data.push(door.save());
|
||||
}
|
||||
|
||||
return this.$advent22.api_put("general/doors", data);
|
||||
return this.$advent22.api_put("admin/doors", data);
|
||||
}
|
||||
|
||||
public mounted(): void {
|
||||
|
|
|
@ -25,7 +25,7 @@ export default class extends Vue {
|
|||
this.$emit("doorClick");
|
||||
|
||||
this.$advent22
|
||||
.api_get_blob(`days/image/${this.door.day}`)
|
||||
.api_get_blob(`images/${this.door.day}`)
|
||||
.then((data) => this.$emit("doorSuccess", data))
|
||||
.catch(([reason]) => {
|
||||
let msg = "Unbekannter Fehler, bitte wiederholen!";
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
</ul>
|
||||
</div>
|
||||
<figure class="image is-unselectable">
|
||||
<img :src="$advent22.api_url('general/background')" />
|
||||
<img :src="$advent22.api_url('images/background')" />
|
||||
<ThouCanvas>
|
||||
<PreviewDoor
|
||||
v-for="(_, index) in doors"
|
||||
|
|
|
@ -9,7 +9,7 @@
|
|||
</ul>
|
||||
</div>
|
||||
<figure class="image is-unselectable">
|
||||
<img :src="$advent22.api_url('general/background')" />
|
||||
<img :src="$advent22.api_url('images/background')" />
|
||||
<RectangleCanvas
|
||||
:rectangles="rectangles"
|
||||
@draw="on_draw"
|
||||
|
|
Loading…
Reference in a new issue