forked from tbnobody/OpenDTU
-
Notifications
You must be signed in to change notification settings - Fork 66
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
webapp: apply formatter on downstream sources
- Loading branch information
1 parent
77af085
commit 4334e60
Showing
28 changed files
with
1,791 additions
and
1,256 deletions.
There are no files selected for viewing
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,15 @@ | ||
<template> | ||
<div> | ||
<InputElement | ||
:label="$t('httprequestsettings.url')" | ||
v-model="cfg.url" | ||
type="text" | ||
maxlength="1024" | ||
placeholder="http://admin:[email protected]/status" | ||
prefix="GET " | ||
:tooltip="$t('httprequestsettings.urlDescription')" | ||
wide /> | ||
:label="$t('httprequestsettings.url')" | ||
v-model="cfg.url" | ||
type="text" | ||
maxlength="1024" | ||
placeholder="http://admin:[email protected]/status" | ||
prefix="GET " | ||
:tooltip="$t('httprequestsettings.urlDescription')" | ||
wide | ||
/> | ||
|
||
<div class="row mb-3"> | ||
<label for="auth_type" class="col-sm-4 col-form-label">{{ $t('httprequestsettings.authorization') }}</label> | ||
|
@@ -22,42 +23,47 @@ | |
</div> | ||
|
||
<InputElement | ||
v-if="cfg.auth_type != 0" | ||
:label="$t('httprequestsettings.username')" | ||
v-model="cfg.username" | ||
type="text" | ||
maxlength="64" | ||
wide /> | ||
v-if="cfg.auth_type != 0" | ||
:label="$t('httprequestsettings.username')" | ||
v-model="cfg.username" | ||
type="text" | ||
maxlength="64" | ||
wide | ||
/> | ||
|
||
<InputElement | ||
v-if="cfg.auth_type != 0" | ||
:label="$t('httprequestsettings.password')" | ||
v-model="cfg.password" | ||
type="password" | ||
maxlength="64" | ||
wide /> | ||
v-if="cfg.auth_type != 0" | ||
:label="$t('httprequestsettings.password')" | ||
v-model="cfg.password" | ||
type="password" | ||
maxlength="64" | ||
wide | ||
/> | ||
|
||
<InputElement | ||
:label="$t('httprequestsettings.headerKey')" | ||
v-model="cfg.header_key" | ||
type="text" | ||
maxlength="64" | ||
:tooltip="$t('httprequestsettings.headerKeyDescription')" | ||
wide /> | ||
:label="$t('httprequestsettings.headerKey')" | ||
v-model="cfg.header_key" | ||
type="text" | ||
maxlength="64" | ||
:tooltip="$t('httprequestsettings.headerKeyDescription')" | ||
wide | ||
/> | ||
|
||
<InputElement | ||
:label="$t('httprequestsettings.headerValue')" | ||
v-model="cfg.header_value" | ||
type="text" | ||
maxlength="256" | ||
wide /> | ||
:label="$t('httprequestsettings.headerValue')" | ||
v-model="cfg.header_value" | ||
type="text" | ||
maxlength="256" | ||
wide | ||
/> | ||
|
||
<InputElement | ||
:label="$t('httprequestsettings.timeout')" | ||
v-model="cfg.timeout" | ||
type="number" | ||
:postfix="$t('httprequestsettings.milliSeconds')" | ||
wide /> | ||
:label="$t('httprequestsettings.timeout')" | ||
v-model="cfg.timeout" | ||
type="number" | ||
:postfix="$t('httprequestsettings.milliSeconds')" | ||
wide | ||
/> | ||
</div> | ||
</template> | ||
|
||
|
@@ -67,28 +73,28 @@ import type { HttpRequestConfig } from '@/types/HttpRequestConfig'; | |
import InputElement from '@/components/InputElement.vue'; | ||
export default defineComponent({ | ||
props: { 'modelValue': Object as () => HttpRequestConfig }, | ||
props: { modelValue: Object as () => HttpRequestConfig }, | ||
computed: { | ||
cfg: { | ||
get(): HttpRequestConfig { | ||
return this.modelValue || {} as HttpRequestConfig; | ||
return this.modelValue || ({} as HttpRequestConfig); | ||
}, | ||
set(newValue: HttpRequestConfig): void { | ||
this.$emit('update:modelValue', newValue); | ||
} | ||
} | ||
}, | ||
}, | ||
}, | ||
components: { | ||
InputElement | ||
InputElement, | ||
}, | ||
data() { | ||
return { | ||
authTypeList: [ | ||
{ key: 0, value: "None" }, | ||
{ key: 1, value: "Basic" }, | ||
{ key: 2, value: "Digest" }, | ||
] | ||
{ key: 0, value: 'None' }, | ||
{ key: 1, value: 'Basic' }, | ||
{ key: 2, value: 'Digest' }, | ||
], | ||
}; | ||
} | ||
}, | ||
}); | ||
</script> |
Oops, something went wrong.