web: fix more special API Calls

Signed-off-by: Jens Langhammer <jens.langhammer@beryju.org>
This commit is contained in:
Jens Langhammer
2021-05-16 18:38:19 +02:00
parent ba5374f6e1
commit d38fd603dd
19 changed files with 25 additions and 268 deletions

View File

@ -29,12 +29,12 @@ export class OutpostForm extends ModelForm<Outpost, string> {
send = (data: Outpost): Promise<Outpost> => {
if (this.instance) {
return new OutpostsApi(DEFAULT_CONFIG).outpostsOutpostsUpdate({
return new OutpostsApi(DEFAULT_CONFIG).outpostsInstancesUpdate({
uuid: this.instance.pk || "",
outpostRequest: data
});
} else {
return new OutpostsApi(DEFAULT_CONFIG).outpostsOutpostsCreate({
return new OutpostsApi(DEFAULT_CONFIG).outpostsInstancesCreate({
outpostRequest: data
});
}
@ -108,7 +108,7 @@ export class OutpostForm extends ModelForm<Outpost, string> {
<ak-form-element-horizontal
label=${t`Configuration`}
name="config">
<ak-codemirror mode="yaml" value="${until(new OutpostsApi(DEFAULT_CONFIG).outpostsOutpostsDefaultSettings({}).then(config => {
<ak-codemirror mode="yaml" value="${until(new OutpostsApi(DEFAULT_CONFIG).outpostsInstancesDefaultSettingsRetrieve().then(config => {
let fc = config.config;
if (this.instance) {
fc = this.instance.config;