2014-01-07 18:36:44 +00:00
|
|
|
|
extends ../layout
|
2013-11-19 18:20:50 +00:00
|
|
|
|
block content
|
2015-01-06 03:01:58 +00:00
|
|
|
|
.panel(ng-controller="profileValidationController")
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.container.text-center
|
|
|
|
|
h1 Update your profile here:
|
2015-01-06 06:09:17 +00:00
|
|
|
|
form.form-horizontal(action='/account/profile', method='POST', novalidate='novalidate')
|
2015-01-06 04:09:23 +00:00
|
|
|
|
input(type='hidden', name='_csrf', value=_csrf)
|
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='name') Name
|
|
|
|
|
.col-sm-4
|
2015-01-06 05:52:30 +00:00
|
|
|
|
input.form-control(type='text', placeholder='Name', name='name', ng-model='user.profile.name', ng-minlength='3', ng-maxlength='20', required='required', ng-focus='ng-focus', id='name', value='{{user.profile.name}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='username') Username (use letters, numbers, underscore) *
|
|
|
|
|
.col-sm-4
|
2015-01-06 05:52:30 +00:00
|
|
|
|
input.form-control(type='text', name='username', id='username', ng-model='user.profile.username', value='{{user.profile.username}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='email') Email *
|
|
|
|
|
.col-sm-4
|
2015-01-06 05:52:30 +00:00
|
|
|
|
input.form-control(type='email', name='email', id='email', ng-model='user.email', value= '{{user.email}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='location') Location
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='location', id='location', ng-model='user.profile.location')
|
2015-01-06 01:29:37 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='email') Twitter Handle
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='twitterHandle', id='twitterHandle', ng-model='user.profile.twitterHandle', value='{{ user.profile.twitterHandle')
|
2015-01-06 01:29:37 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='email') Github Profile Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='githubProfile', id='githubProfile', ng-model='user.profile.githubProfile', value='{{user.profile.githubProfile}}')
|
2015-01-06 01:29:37 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='email') CodePen Profile Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='codepenProfile', id='codepenProfile', ng-model='user.profile.codepenProfile', value='{{user.profile.codepenProfile}}')
|
2015-01-06 01:29:37 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='email') CoderByte Profile Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='coderbyteProfile', id='coderbyteProfile', ng-model='user.profile.coderbyteProfile', value='{{user.profile.coderbyteProfile}}')
|
2015-01-06 01:29:37 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='email') LinkedIn Profile Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='linkedinProfile', id='linkedinProfile', ng-model='user.profile.linkedinProfile', value='{{user.profile.linkedinProfile}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='website1Title') 1st Portfolio Website Title
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='website1Title', id='website1Title', ng-model='user.profile.website1Title', value='{{user.profile.website1Title}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='website1Link') 1st Portfolio Website Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='website1Link', id='website1Link', ng-model='user.profile.website1Link', value='{{user.profile.website1Link}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='website1Image') 1st Portfolio Website Image Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='website1Image', id='website1Image', ng-model='website1Image', value='{{user.profile.website1Image}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='website2Title') 2nd Portfolio Website Title
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='website2Title', id='website2Title', ng-model='user.profile.website2Title', value='{{user.profile.website2Title}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='website2Link') 2nd Portfolio Website Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='website2Link', id='website2Link', ng-model='user.profile.website2Link', value='{{user.profile.website2Link}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='website2Image') 2nd Portfolio Website Image Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='website2Image', id='website2Image', ng-model='user.profile.website2Image', value='{{user.profile.website2Image}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='website3Title') 3rd Portfolio Website Title
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='website3Title', id='website3Title', ng-model='user.profile.website3Title', value='{{user.profile.website3Title}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='website3Link') 3rd Portfolio Website Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='website3Link', id='website3Link', ng-model='user.profile.website3Link', value='{{user.profile.website3Link}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
label.col-sm-3.col-sm-offset-2.control-label(for='website3Image') 3rd Portfolio Website Image Link
|
|
|
|
|
.col-sm-4
|
2015-01-06 06:09:17 +00:00
|
|
|
|
input.form-control(type='text', name='website3Image', id='website3Image', ng-model='user.profile.website3Image', value='{{user.profile.website3Image}}')
|
2015-01-06 00:38:56 +00:00
|
|
|
|
.form-group
|
|
|
|
|
.col-sm-offset-2.col-sm-4
|
|
|
|
|
button.btn.btn.btn-primary(type='submit')
|
|
|
|
|
span.ion-edit
|
|
|
|
|
| Update my profile
|
2014-12-24 08:07:20 +00:00
|
|
|
|
.panel
|
2014-12-30 06:40:27 +00:00
|
|
|
|
.big-break
|
2014-12-24 08:07:20 +00:00
|
|
|
|
.container.text-center
|
2014-12-30 06:40:27 +00:00
|
|
|
|
a.btn.btn-cta.signup-btn(href='/') Take me to my current challenge
|
|
|
|
|
.big-break
|
|
|
|
|
.container.text-center
|
|
|
|
|
a.btn.btn-default.btn-big(href='/logout') Sign out
|
|
|
|
|
.big-break
|
2014-12-24 08:07:20 +00:00
|
|
|
|
|
2014-12-24 02:20:53 +00:00
|
|
|
|
- if (!user.google || !user.facebook || !user.github || !user.linkedin || !user.twitter)
|
|
|
|
|
.panel
|
2014-12-24 08:07:20 +00:00
|
|
|
|
.container.text-center
|
2014-12-24 02:20:53 +00:00
|
|
|
|
h1 Link other services to your account:
|
|
|
|
|
- if (!user.google)
|
|
|
|
|
.col-xs-12
|
|
|
|
|
a.btn.btn-lg.btn-block.btn-google-plus.btn-link-social(href='/auth/google')
|
|
|
|
|
i.fa.fa-google-plus
|
|
|
|
|
| Link Google with your account
|
|
|
|
|
- if (!user.facebook)
|
|
|
|
|
.col-xs-12
|
|
|
|
|
a.btn.btn-lg.btn-block.btn-facebook.btn-link-social(href='/auth/facebook')
|
|
|
|
|
i.fa.fa-facebook
|
|
|
|
|
| Link Facebook with your account
|
2015-01-04 20:29:21 +00:00
|
|
|
|
//- if (!user.github)
|
|
|
|
|
// .col-xs-12
|
|
|
|
|
// a.btn.btn-lg.btn-block.btn-github.btn-link-social(href='/auth/github')
|
|
|
|
|
// i.fa.fa-github
|
|
|
|
|
// | Link GitHub with your account
|
2014-12-24 02:20:53 +00:00
|
|
|
|
- if (!user.linkedin)
|
|
|
|
|
.col-xs-12
|
|
|
|
|
a.btn.btn-lg.btn-block.btn-linkedin.btn-link-social(href='/auth/linkedin')
|
|
|
|
|
i.fa.fa-linkedin
|
|
|
|
|
| Link LinkedIn with your account
|
|
|
|
|
- if (!user.twitter)
|
|
|
|
|
.col-xs-12
|
|
|
|
|
a.btn.btn-lg.btn-block.btn-twitter.btn-link-social(href='/auth/twitter')
|
|
|
|
|
i.fa.fa-twitter
|
|
|
|
|
| Link Twitter with your account
|
|
|
|
|
br
|
2014-12-31 06:03:03 +00:00
|
|
|
|
- if (ch[0] > 0)
|
2014-12-24 02:20:53 +00:00
|
|
|
|
.panel
|
|
|
|
|
.container
|
|
|
|
|
h1 Completed Challenges
|
|
|
|
|
.col-xs-12
|
|
|
|
|
table.table.table-striped
|
|
|
|
|
thead
|
|
|
|
|
tr
|
|
|
|
|
th Challenge
|
|
|
|
|
th Date Finished
|
2014-12-31 06:03:03 +00:00
|
|
|
|
for challenge in challenges
|
|
|
|
|
if ch[challenge.challengeNumber] > 0
|
2014-12-24 02:20:53 +00:00
|
|
|
|
tr
|
2014-12-31 06:03:03 +00:00
|
|
|
|
td= challenges[challenge.challengeNumber].name
|
|
|
|
|
td= moment(ch[challenge.challengeNumber], 'X').format("MMM DD, YYYY")
|
2014-12-24 02:20:53 +00:00
|
|
|
|
br
|
|
|
|
|
.panel
|
|
|
|
|
.container
|
2014-11-07 23:43:10 +00:00
|
|
|
|
h3 Danger Zone
|
|
|
|
|
button.btn.btn-danger.confirm-deletion
|
|
|
|
|
span.ion-trash-b
|
|
|
|
|
| I want to delete my account
|
2014-12-24 02:20:53 +00:00
|
|
|
|
br
|
2014-12-24 21:40:42 +00:00
|
|
|
|
br
|
2014-11-07 23:43:10 +00:00
|
|
|
|
script.
|
|
|
|
|
$('.confirm-deletion').on("click", function() {
|
|
|
|
|
$('#modal-dialog').modal('show');
|
|
|
|
|
});
|
2014-12-24 21:40:42 +00:00
|
|
|
|
#modal-dialog.modal.animated.wobble
|
|
|
|
|
.modal-dialog
|
|
|
|
|
.modal-content
|
|
|
|
|
.modal-header
|
|
|
|
|
a.close(href='#', data-dismiss='modal', aria-hidden='true') ×
|
|
|
|
|
h3 Are you really leaving us?
|
|
|
|
|
.modal-body
|
|
|
|
|
p Pro Tip: If you tweet feedback to
|
|
|
|
|
a(href="https://twitter.com/intent/tweet?text=Hey%20@freecodecamp") @FreeCodeCamp
|
|
|
|
|
| , we'll act quickly on it!
|
|
|
|
|
.modal-footer
|
|
|
|
|
a.btn.btn-success.btn-block(href='#', data-dismiss='modal', aria-hidden='true')
|
|
|
|
|
span.ion-happy
|
|
|
|
|
| Nevermind, I'll stick around
|
|
|
|
|
br
|
|
|
|
|
form(action='/account/delete', method='POST')
|
|
|
|
|
input(type='hidden', name='_csrf', value=_csrf)
|
|
|
|
|
button.btn.btn-danger.btn-block(type='submit')
|
|
|
|
|
span.ion-trash-b
|
|
|
|
|
| Yes, Delete my account
|
2015-01-06 01:29:37 +00:00
|
|
|
|
|