From 2de48110bbc253ff4aa8457ea0cfed5a6fb5feb0 Mon Sep 17 00:00:00 2001
From: syuilo <syuilotan@yahoo.co.jp>
Date: Wed, 7 Nov 2018 00:44:56 +0900
Subject: ghostの設定をDBに保存するように
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

---
 src/client/app/admin/views/instance.vue | 15 ++++++++++++---
 1 file changed, 12 insertions(+), 3 deletions(-)

(limited to 'src/client/app/admin/views/instance.vue')

diff --git a/src/client/app/admin/views/instance.vue b/src/client/app/admin/views/instance.vue
index 11f9d28fd2..5acb493332 100644
--- a/src/client/app/admin/views/instance.vue
+++ b/src/client/app/admin/views/instance.vue
@@ -13,8 +13,8 @@
 		<section class="fit-bottom">
 			<header><fa icon="cloud"/> %i18n:@drive-config%</header>
 			<ui-switch v-model="cacheRemoteFiles">%i18n:@cache-remote-files%<span slot="desc">%i18n:@cache-remote-files-desc%</span></ui-switch>
-			<ui-input v-model="localDriveCapacityMb">%i18n:@local-drive-capacity-mb%<span slot="desc">%i18n:@mb%</span><span slot="suffix">MB</span></ui-input>
-			<ui-input v-model="remoteDriveCapacityMb" :disabled="!cacheRemoteFiles">%i18n:@remote-drive-capacity-mb%<span slot="desc">%i18n:@mb%</span><span slot="suffix">MB</span></ui-input>
+			<ui-input v-model="localDriveCapacityMb">%i18n:@local-drive-capacity-mb%<span slot="suffix">MB</span><span slot="desc">%i18n:@mb%</span></ui-input>
+			<ui-input v-model="remoteDriveCapacityMb" :disabled="!cacheRemoteFiles">%i18n:@remote-drive-capacity-mb%<span slot="suffix">MB</span><span slot="desc">%i18n:@mb%</span></ui-input>
 		</section>
 		<section class="fit-bottom">
 			<header><fa icon="shield-alt"/> %i18n:@recaptcha-config%</header>
@@ -23,6 +23,12 @@
 			<ui-input v-model="recaptchaSiteKey" :disabled="!enableRecaptcha"><i slot="icon"><fa icon="key"/></i>%i18n:@recaptcha-site-key%</ui-input>
 			<ui-input v-model="recaptchaSecretKey" :disabled="!enableRecaptcha"><i slot="icon"><fa icon="key"/></i>%i18n:@recaptcha-secret-key%</ui-input>
 		</section>
+		<section>
+			<header><fa icon="ghost"/> %i18n:@proxy-account-config%</header>
+			<ui-info>%i18n:@proxy-account-info%</ui-info>
+			<ui-input v-model="proxyAccount"><i slot="prefix">@</i>%i18n:@proxy-account-username%<span slot="desc">%i18n:@proxy-account-username-desc%</span></ui-input>
+			<ui-info warn>%i18n:@proxy-account-warn%</ui-info>
+		</section>
 		<section>
 			<ui-switch v-model="disableRegistration">%i18n:@disable-registration%</ui-switch>
 		</section>
@@ -62,6 +68,7 @@ export default Vue.extend({
 			enableRecaptcha: false,
 			recaptchaSiteKey: null,
 			recaptchaSecretKey: null,
+			proxyAccount: null,
 			inviteCode: null,
 		};
 	},
@@ -78,6 +85,7 @@ export default Vue.extend({
 			this.enableRecaptcha = meta.enableRecaptcha;
 			this.recaptchaSiteKey = meta.recaptchaSiteKey;
 			this.recaptchaSecretKey = meta.recaptchaSecretKey;
+			this.proxyAccount = meta.proxyAccount;
 		});
 	},
 
@@ -106,7 +114,8 @@ export default Vue.extend({
 				maxNoteTextLength: parseInt(this.maxNoteTextLength, 10),
 				enableRecaptcha: this.enableRecaptcha,
 				recaptchaSiteKey: this.recaptchaSiteKey,
-				recaptchaSecretKey: this.recaptchaSecretKey
+				recaptchaSecretKey: this.recaptchaSecretKey,
+				proxyAccount: this.proxyAccount,
 			}).then(() => {
 				this.$swal({
 					type: 'success',
-- 
cgit v1.2.3-freya

