mirror of
https://github.com/overleaf/overleaf.git
synced 2025-02-17 11:01:29 +00:00
don't show the user details area on project list if algolia instituions has not be setup
This commit is contained in:
parent
df44792a10
commit
cc1b9472b2
2 changed files with 26 additions and 25 deletions
|
@ -99,6 +99,7 @@ module.exports =
|
|||
return res.send 500
|
||||
logger.log results:results, user_id:user_id, "rendering project list"
|
||||
viewModel = _buildListViewModel results.projects[0], results.projects[1], results.projects[2], results.tags[0], results.tags[1]
|
||||
viewModel.showUserDetailsArea = Settings?.algolia?.institutions?.app_id? and Settings?.algolia?.institutions?.api_key?
|
||||
res.render 'project/list', viewModel
|
||||
timer.done()
|
||||
|
||||
|
|
|
@ -100,35 +100,35 @@ block content
|
|||
i.icon-remove
|
||||
ul#projectList
|
||||
mixin projectList(projects)
|
||||
- if (showUserDetailsArea)
|
||||
.span3#userProfileInformation(ng-cloak)
|
||||
div(ng-controller="UpdateForm").userProfileInformationArea
|
||||
div(ng-hide="hidePersonalInfoSection").alert.alert-info
|
||||
|
||||
.span3#userProfileInformation(ng-cloak)
|
||||
div(ng-controller="UpdateForm").userProfileInformationArea
|
||||
div(ng-hide="hidePersonalInfoSection").alert.alert-info
|
||||
div(ng-show="percentComplete >= 100")
|
||||
h4 100% complete, well done!
|
||||
div(ng-hide="percentComplete >= 100")
|
||||
h4 Your account is
|
||||
strong {{percentComplete}}%
|
||||
| complete
|
||||
|
||||
div(ng-show="percentComplete >= 100")
|
||||
h4 100% complete, well done!
|
||||
div(ng-hide="percentComplete >= 100")
|
||||
h4 Your account is
|
||||
strong {{percentComplete}}%
|
||||
| complete
|
||||
.progress
|
||||
.bar.bar-success(ng-style="{'width' : (percentComplete+'%')}")
|
||||
|
||||
.progress
|
||||
.bar.bar-success(ng-style="{'width' : (percentComplete+'%')}")
|
||||
button#completeUserProfileInformation.btn.btn-primary(ng-hide="formVisable", ng-click="showForm()") Complete now
|
||||
|
||||
button#completeUserProfileInformation.btn.btn-primary(ng-hide="formVisable", ng-click="showForm()") Complete now
|
||||
|
||||
div(ng-show="formVisable")
|
||||
form(enctype='multipart/form-data', method='post')
|
||||
.input
|
||||
input(type='text', name='first_name', ng-model="userInfoForm.first_name", ng-blur="sendUpdate()", placeholder="First Name", focus-input="formVisable")
|
||||
.input
|
||||
input(type='text', name='last_name', ng-model="userInfoForm.last_name", ng-blur="sendUpdate()", placeholder='Last Name')
|
||||
.input#institution_auto_complete
|
||||
autocomplete(ng-model="userInfoForm.institution", data="institutions", ng-blur="sendUpdate()", on-type="updateInstitutionsList", attr-placeholder="Institution")
|
||||
.input
|
||||
input(type='text', name='role', ng-model="userInfoForm.role", placeholder='Role', ng-blur="sendUpdate()", list="_roles")
|
||||
datalist#_roles
|
||||
option(ng-repeat='role in roles') {{role}}
|
||||
div(ng-show="formVisable")
|
||||
form(enctype='multipart/form-data', method='post')
|
||||
.input
|
||||
input(type='text', name='first_name', ng-model="userInfoForm.first_name", ng-blur="sendUpdate()", placeholder="First Name", focus-input="formVisable")
|
||||
.input
|
||||
input(type='text', name='last_name', ng-model="userInfoForm.last_name", ng-blur="sendUpdate()", placeholder='Last Name')
|
||||
.input#institution_auto_complete
|
||||
autocomplete(ng-model="userInfoForm.institution", data="institutions", ng-blur="sendUpdate()", on-type="updateInstitutionsList", attr-placeholder="Institution")
|
||||
.input
|
||||
input(type='text', name='role', ng-model="userInfoForm.role", placeholder='Role', ng-blur="sendUpdate()", list="_roles")
|
||||
datalist#_roles
|
||||
option(ng-repeat='role in roles') {{role}}
|
||||
.span3
|
||||
.tag-list
|
||||
h2 Tags
|
||||
|
|
Loading…
Reference in a new issue