|
185 | 185 | </a-list-item>
|
186 | 186 | </a-list>
|
187 | 187 | </a-tab-pane>
|
188 |
| - <a-tab-pane key="2" tab='{{ i18n "pages.settings.securitySettings"}}' style="padding: 20px;"> |
189 |
| - <a-divider>{{ i18n "pages.settings.security.admin"}}</a-divider> |
190 |
| - <a-form layout="horizontal" :colon="false" style="float: left; margin-bottom: 2rem;" :label-col="{ md: {span:10} }" :wrapper-col="{ md: {span:14} }"> |
191 |
| - <a-form-item label='{{ i18n "pages.settings.oldUsername"}}'> |
192 |
| - <a-input autocomplete="username" v-model="user.oldUsername"></a-input> |
193 |
| - </a-form-item> |
194 |
| - <a-form-item label='{{ i18n "pages.settings.currentPassword"}}'> |
195 |
| - <password-input autocomplete="current-password" v-model="user.oldPassword"></password-input> |
196 |
| - </a-form-item> |
197 |
| - <a-form-item label='{{ i18n "pages.settings.newUsername"}}'> |
198 |
| - <a-input v-model="user.newUsername"></a-input> |
199 |
| - </a-form-item> |
200 |
| - <a-form-item label='{{ i18n "pages.settings.newPassword"}}'> |
201 |
| - <password-input autocomplete="new-password" v-model="user.newPassword"></password-input> |
202 |
| - </a-form-item> |
203 |
| - <a-form-item label=" "> |
204 |
| - <a-button type="primary" @click="updateUser">{{ i18n "confirm" }}</a-button> |
205 |
| - </a-form-item> |
206 |
| - </a-form> |
| 188 | + <a-tab-pane key="2" tab='{{ i18n "pages.settings.securitySettings"}}' style="padding-top: 20px;"> |
| 189 | + <a-collapse> |
| 190 | + <a-collapse-panel header='{{ i18n "pages.settings.security.admin"}}'> |
| 191 | + <a-list-item> |
| 192 | + <a-row style="padding: 0 20px; padding-bottom: 10px;"> |
| 193 | + <a-col :lg="24" :xl="12"> |
| 194 | + <a-list-item-meta title='{{ i18n "pages.settings.oldUsername"}}'></a-list-item-meta> |
| 195 | + </a-col> |
| 196 | + <a-col :lg="24" :xl="12"> |
| 197 | + <template> |
| 198 | + <a-input autocomplete="username" v-model="user.oldUsername"></a-input> |
| 199 | + </template> |
| 200 | + </a-col> |
| 201 | + </a-row> |
| 202 | + <a-row style="padding: 10px 20px"> |
| 203 | + <a-col :lg="24" :xl="12"> |
| 204 | + <a-list-item-meta title='{{ i18n "pages.settings.currentPassword"}}'></a-list-item-meta> |
| 205 | + </a-col> |
| 206 | + <a-col :lg="24" :xl="12"> |
| 207 | + <template> |
| 208 | + <password-input autocomplete="current-password" v-model="user.oldPassword"></password-input> |
| 209 | + </template> |
| 210 | + </a-col> |
| 211 | + </a-row> |
| 212 | + <a-row style="padding: 10px 20px"> |
| 213 | + <a-col :lg="24" :xl="12"> |
| 214 | + <a-list-item-meta title='{{ i18n "pages.settings.newUsername"}}'></a-list-item-meta> |
| 215 | + </a-col> |
| 216 | + <a-col :lg="24" :xl="12"> |
| 217 | + <template> |
| 218 | + <a-input v-model="user.newUsername"></a-input> |
| 219 | + </template> |
| 220 | + </a-col> |
| 221 | + </a-row> |
| 222 | + <a-row style="padding: 10px 20px"> |
| 223 | + <a-col :lg="24" :xl="12"> |
| 224 | + <a-list-item-meta title='{{ i18n "pages.settings.newPassword"}}'></a-list-item-meta> |
| 225 | + </a-col> |
| 226 | + <a-col :lg="24" :xl="12"> |
| 227 | + <template> |
| 228 | + <password-input autocomplete="new-password" v-model="user.newPassword"></password-input> |
| 229 | + </template> |
| 230 | + </a-col> |
| 231 | + </a-row> |
| 232 | + <a-space direction="horizontal" style="padding: 0 20px; padding-top: 20px;"> |
| 233 | + <a-button type="primary" @click="updateUser">{{ i18n "confirm" }}</a-button> |
| 234 | + </a-space> |
| 235 | + </a-list-item> |
| 236 | + </a-collapse-panel> |
| 237 | + <a-collapse-panel header='{{ i18n "pages.settings.security.secret"}}'> |
| 238 | + <a-list-item> |
| 239 | + <a-row style="padding: 0 20px; padding-bottom: 10px;"> |
| 240 | + <a-col :lg="24" :xl="12"> |
| 241 | + <a-list-item-meta title='{{ i18n "pages.settings.security.loginSecurity" }}' |
| 242 | + description='{{ i18n "pages.settings.security.loginSecurityDesc" }}'> |
| 243 | + </a-list-item-meta> |
| 244 | + </a-col> |
| 245 | + <a-col :lg="24" :xl="12"> |
| 246 | + <template> |
| 247 | + <a-switch @change="toggleToken(allSetting.secretEnable)" v-model="allSetting.secretEnable"></a-switch> |
| 248 | + <a-icon style="margin-left: 1rem;" v-if="allSetting.secretEnable" :spin="this.changeSecret" type="sync" @click="getNewSecret"></a-icon> |
| 249 | + </template> |
| 250 | + </a-col> |
| 251 | + </a-row> |
| 252 | + <a-row style="padding: 10px 20px"> |
| 253 | + <a-col :lg="24" :xl="12"> |
| 254 | + <a-list-item-meta title='{{ i18n "pages.settings.security.secretToken" }}' |
| 255 | + description='{{ i18n "pages.settings.security.secretTokenDesc" }}'> |
| 256 | + </a-list-item-meta> |
| 257 | + </a-col> |
| 258 | + <a-col :lg="24" :xl="12"> |
| 259 | + <template> |
| 260 | + <a-textarea type="text" :disabled="!allSetting.secretEnable" v-model="user.loginSecret"></a-textarea> |
| 261 | + </template> |
| 262 | + </a-col> |
| 263 | + </a-row> |
| 264 | + <a-space direction="horizontal" style="padding: 0 20px; padding-top: 20px;"> |
| 265 | + <a-button type="primary" :loading="this.changeSecret" @click="updateSecret">{{ i18n "confirm" }}</a-button> |
| 266 | + </a-space> |
| 267 | + </a-list-item> |
| 268 | + </a-collapse-panel> |
| 269 | + </a-collapse> |
| 270 | + <!-- |
207 | 271 | <a-divider>{{ i18n "pages.settings.security.secret"}}</a-divider>
|
208 | 272 | <a-form style="padding: 0 20px;">
|
209 | 273 | <a-list-item>
|
|
221 | 285 | </a-col>
|
222 | 286 | </a-row>
|
223 | 287 | </a-list-item>
|
224 |
| - <a-list-item> |
225 |
| - <a-row> |
226 |
| - <a-col :lg="24" :xl="12"> |
227 |
| - <a-list-item-meta title='{{ i18n "pages.settings.security.secretToken" }}' |
228 |
| - description='{{ i18n "pages.settings.security.secretTokenDesc" }}'> |
229 |
| - </a-list-item-meta> |
230 |
| - </a-col> |
231 |
| - <a-col :lg="24" :xl="12"> |
232 |
| - <template> |
233 |
| - <a-textarea type="text" :disabled="!allSetting.secretEnable" v-model="user.loginSecret"></a-textarea> |
234 |
| - </template> |
235 |
| - </a-col> |
236 |
| - </a-row> |
237 |
| - </a-list-item> |
| 288 | + |
238 | 289 | <a-button type="primary" :loading="this.changeSecret" @click="updateSecret">{{ i18n "confirm" }}</a-button>
|
239 |
| - </a-form> |
| 290 | + </a-form> --> |
240 | 291 | </a-tab-pane>
|
241 | 292 | <a-tab-pane key="3" tab='{{ i18n "pages.settings.TGBotSettings"}}'>
|
242 | 293 | <a-list item-layout="horizontal">
|
|
0 commit comments