wikijs-fork/server/views/pages/admin/profile.pug

54 lines
2.3 KiB
Plaintext
Raw Normal View History

2016-11-21 01:09:50 +00:00
extends ./_layout.pug
block adminContent
2017-02-10 02:35:37 +00:00
#page-type-admin-profile
.hero
2017-05-04 02:10:12 +00:00
h1.title#title= t('nav.myprofile')
h2.subtitle= t('admin:profile.subtitle')
2017-02-10 02:35:37 +00:00
.form-sections
.columns.is-gapless
.column.is-two-thirds
section
2017-05-04 02:10:12 +00:00
label.label= t('admin:profile.email')
2017-02-10 02:35:37 +00:00
p.control.is-fullwidth
2017-05-04 02:10:12 +00:00
input.input(type='text', placeholder=t('admin:profile.email'), value=user.email, disabled)
2017-02-10 02:35:37 +00:00
if user.provider === 'local'
section
2017-05-04 02:10:12 +00:00
label.label= t('admin:profile.password')
2017-02-10 02:35:37 +00:00
p.control.is-fullwidth
2017-05-04 02:10:12 +00:00
input.input(type='password', placeholder=t('admin:profile.password'), value='********', v-model='password')
2017-02-10 02:35:37 +00:00
section
2017-05-04 02:10:12 +00:00
label.label= t('admin:profile.passwordverify')
2017-02-10 02:35:37 +00:00
p.control.is-fullwidth
2017-05-04 02:10:12 +00:00
input.input(type='password', placeholder=t('admin:profile.password'), value='********', v-model='passwordVerify')
2017-02-10 02:35:37 +00:00
section
2017-05-04 02:10:12 +00:00
label.label= t('admin:profile.displayname')
2017-02-10 02:35:37 +00:00
p.control.is-fullwidth
2017-05-04 02:10:12 +00:00
input.input(type='text', placeholder=t('admin:profile.displaynameexample'), v-model='name')
2017-02-10 02:35:37 +00:00
section
button.button.is-green(v-on:click='saveUser')
i.icon-check
2017-05-04 02:10:12 +00:00
span= t('admin:profile.savechanges')
2017-02-10 02:35:37 +00:00
.column
2017-02-26 23:06:20 +00:00
.panel-aside
2017-05-04 02:10:12 +00:00
label.label= t('admin:profile.provider')
2017-02-10 02:35:37 +00:00
p.control.account-profile-provider
case user.provider
when 'local': i.icon-server
when 'windowslive': i.icon-windows2.is-blue
when 'azure': i.icon-windows2.is-blue
2017-02-10 02:35:37 +00:00
when 'google': i.icon-google.is-blue
when 'facebook': i.icon-facebook.is-indigo
when 'github': i.icon-github.is-grey
when 'slack': i.icon-slack.is-purple
2017-03-12 04:38:47 +00:00
when 'ldap': i.icon-arrow-repeat-outline
2017-02-10 02:35:37 +00:00
default: i.icon-warning
= t('auth:providers.' + user.provider)
2017-05-04 02:10:12 +00:00
label.label= t('admin:profile.membersince')
2017-02-10 02:35:37 +00:00
p.control= userMoment(user.createdAt).format('LL')
2017-05-04 02:10:12 +00:00
label.label= t('admin:profile.lastprofileupdate')
2017-02-10 02:35:37 +00:00
p.control= userMoment(user.updatedAt).format('LL')
2017-02-10 02:35:37 +00:00
script(type='text/javascript').
var usrDataName = "!{user.name}";