Add i18n for notification form

This commit is contained in:
zsxeee
2021-09-21 13:02:41 +08:00
parent ad6fcc2f2e
commit 8c941b1d56
18 changed files with 228 additions and 133 deletions

View File

@@ -1,11 +1,11 @@
<template>
<div class="mb-3">
<label for="webhook-url" class="form-label">Post URL</label>
<label for="webhook-url" class="form-label">{{ $t("Post URL") }}</label>
<input id="webhook-url" v-model="$parent.notification.webhookURL" type="url" pattern="https?://.+" class="form-control" required>
</div>
<div class="mb-3">
<label for="webhook-content-type" class="form-label">Content Type</label>
<label for="webhook-content-type" class="form-label">{{ $t("Content Type") }}</label>
<select id="webhook-content-type" v-model="$parent.notification.webhookContentType" class="form-select" required>
<option value="json">
application/json
@@ -17,7 +17,10 @@
<div class="form-text">
<p>"application/json" is good for any modern http servers such as express.js</p>
<p>"multipart/form-data" is good for PHP, you just need to parse the json by <strong>json_decode($_POST['data'])</strong></p>
<i18n-t keypath="webhookFormDataDesc" tag="p">
"multipart/form-data"
<strong>json_decode($_POST['data'])</strong>
</i18n-t>
</div>
</div>
</template>