profile.jade 3.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990
  1. extends ../layout
  2. block content
  3. section#partial
  4. .container
  5. .row
  6. .col-sm-8.col-sm-offset-2.text-center
  7. h3 Profile
  8. hr
  9. .row
  10. form.form-horizontal(action='/account/profile', method='POST')
  11. input(type='hidden', name='_csrf', value=_csrf)
  12. .form-group
  13. label.col-sm-3.control-label(for='email') Email
  14. .col-sm-7
  15. input.form-control(type='email', name='email', id='email', value='#{user.email}')
  16. .form-group
  17. label.col-sm-3.control-label(for='name') Name
  18. .col-sm-7
  19. input.form-control(type='text', name='name', id='name', value='#{user.profile.name}')
  20. .form-group
  21. label.col-sm-3.control-label(for='username') Username
  22. .col-sm-7
  23. input.form-control(type='text', name='username', id='username', value='#{user.profile.username}')
  24. .form-group
  25. label.col-sm-3.control-label(for='gender') Gender
  26. .col-sm-4
  27. label.radio.col-sm-4
  28. input(type='radio', checked=user.profile.gender=='male', name='gender', value='male', data-toggle='radio')
  29. span Male
  30. label.radio.col-sm-4
  31. input(type='radio', checked=user.profile.gender=='female', name='gender', value='female', data-toggle='radio')
  32. span Female
  33. .form-group
  34. label.col-sm-3.control-label(for='location') Location
  35. .col-sm-7
  36. input.form-control(type='text', name='location', id='location', value='#{user.profile.location}')
  37. .form-group
  38. label.col-sm-3.control-label(for='website') Website
  39. .col-sm-7
  40. input.form-control(type='text', name='website', id='website', value='#{user.profile.website}')
  41. .form-group
  42. label.col-sm-3.control-label(for='bio') Bio
  43. .col-sm-7
  44. input.form-control(type='text', name='bio', id='bio', value='#{user.profile.bio}')
  45. .form-group
  46. label.col-sm-3.control-label(for='gravatar') Gravatar
  47. .col-sm-4
  48. img(src="#{user.gravatar()}", class='profile', width='100', height='100')
  49. .form-group
  50. .col-sm-offset-3.col-sm-4
  51. button.btn.btn.btn-primary(type='submit')
  52. i.fa.fa-pencilr
  53. | Update Profile
  54. .row
  55. .col-sm-8.col-sm-offset-2.text-center
  56. h3 Password
  57. hr
  58. .row
  59. form.form-horizontal(action='/account/password', method='POST')
  60. input(type='hidden', name='_csrf', value=_csrf)
  61. .form-group
  62. label.col-sm-3.control-label(for='password') New Password
  63. .col-sm-7
  64. input.form-control(type='password', name='password', id='password')
  65. .form-group
  66. label.col-sm-3.control-label(for='confirmPassword') Confirm Password
  67. .col-sm-7
  68. input.form-control(type='password', name='confirmPassword', id='confirmPassword')
  69. .form-group
  70. .col-sm-offset-3.col-sm-4
  71. button.btn.btn-primary(type='submit')
  72. i.fa.fa-lock
  73. | Change Password
  74. .row
  75. .col-sm-8.col-sm-offset-2.text-center
  76. h3 Delete Account
  77. hr
  78. .row
  79. form.form-horizontal(action='/account/delete', method='POST')
  80. .form-group
  81. p.col-sm-offset-3.col-sm-4 You can delete your account, but keep in mind this action is irreversible.
  82. input(type='hidden', name='_csrf', value=_csrf)
  83. .col-sm-offset-3.col-sm-4
  84. button.btn.btn-danger(type='submit')
  85. i.fa.fa-trash
  86. | Delete my account