2021-02-22 10:01:02 -05:00
|
|
|
include ../../_mixins/reconfirm_affiliation
|
|
|
|
|
2019-10-02 17:37:19 -04:00
|
|
|
mixin aboutInstitutionLink()
|
2019-10-28 10:09:37 -04:00
|
|
|
a(href="/learn/how-to/Institutional_Login") #{translate("find_out_more_about_institution_login")}.
|
2019-10-02 17:37:19 -04:00
|
|
|
|
2019-10-28 10:05:29 -04:00
|
|
|
mixin btnMakePrimaryDisabled(tooltip)
|
|
|
|
div(
|
|
|
|
tooltip=tooltip
|
|
|
|
tooltip-enable="!ui.isMakingRequest"
|
|
|
|
)
|
|
|
|
button.btn.btn-sm.btn-success.affiliations-table-inline-action(
|
|
|
|
disabled
|
|
|
|
type="button"
|
|
|
|
) #{translate("make_primary")}
|
|
|
|
|
2021-02-02 09:25:12 -05:00
|
|
|
mixin btnRemoveEmail()
|
|
|
|
.affiliations-table-inline-action-disabled-wrapper(ng-if="userEmail.default")
|
|
|
|
div(
|
|
|
|
tooltip=translate("please_change_primary_to_remove")
|
|
|
|
tooltip-enable="!ui.isMakingRequest"
|
|
|
|
tooltip-placement="left"
|
|
|
|
)
|
|
|
|
button.btn.btn-sm.btn-danger(disabled)
|
|
|
|
i.fa.fa-fw.fa-trash(aria-hidden="true")
|
|
|
|
span.sr-only #{translate("please_change_primary_to_remove")}
|
|
|
|
button.btn.btn-sm.btn-danger.affiliations-table-inline-action(
|
|
|
|
ng-if="!userEmail.default"
|
|
|
|
ng-click="removeUserEmail(userEmail)"
|
|
|
|
ng-disabled="ui.isMakingRequest"
|
|
|
|
tooltip=translate("remove")
|
|
|
|
type="button"
|
|
|
|
)
|
|
|
|
i.fa.fa-fw.fa-trash(aria-hidden="true")
|
|
|
|
span.sr-only #{translate("remove")}
|
|
|
|
|
2018-06-27 12:08:25 -04:00
|
|
|
form.row(
|
|
|
|
ng-controller="UserAffiliationsController"
|
|
|
|
name="affiliationsForm"
|
|
|
|
)
|
|
|
|
.col-md-12
|
2018-07-05 10:31:34 -04:00
|
|
|
h3 #{translate("emails_and_affiliations_title")}
|
|
|
|
p.small #{translate("emails_and_affiliations_explanation")}
|
2018-06-27 12:08:25 -04:00
|
|
|
table.table.affiliations-table
|
|
|
|
thead
|
|
|
|
tr
|
2018-07-05 10:31:34 -04:00
|
|
|
th.affiliations-table-email #{translate("email")}
|
|
|
|
th.affiliations-table-institution #{translate("institution_and_role")}
|
2018-06-27 12:08:25 -04:00
|
|
|
th.affiliations-table-inline-actions
|
2018-07-17 06:12:47 -04:00
|
|
|
tbody
|
2018-06-27 12:08:25 -04:00
|
|
|
tr(
|
2019-09-30 09:21:31 -04:00
|
|
|
ng-repeat-start="userEmail in userEmails"
|
2018-06-27 12:08:25 -04:00
|
|
|
)
|
2018-07-12 12:13:26 -04:00
|
|
|
td
|
2019-04-12 05:39:17 -04:00
|
|
|
| {{ userEmail.email + (userEmail.default ? ' (primary)' : '') }}
|
2018-07-13 06:17:05 -04:00
|
|
|
div(ng-if="!userEmail.confirmedAt").small
|
2018-07-12 12:13:26 -04:00
|
|
|
strong #{translate('unconfirmed')}.
|
2019-12-09 10:10:07 -05:00
|
|
|
span(ng-if="!userEmail.ssoAvailable") #{translate('please_check_your_inbox')}.
|
2018-07-12 12:13:26 -04:00
|
|
|
br
|
|
|
|
a(
|
|
|
|
href,
|
2019-09-30 09:21:31 -04:00
|
|
|
ng-click="resendConfirmationEmail(userEmail)",
|
2019-12-09 10:10:07 -05:00
|
|
|
ng-if="!userEmail.ssoAvailable"
|
2018-07-12 12:13:26 -04:00
|
|
|
) #{translate('resend_confirmation_email')}
|
2020-02-20 11:07:54 -05:00
|
|
|
div(ng-if="userEmail.confirmedAt && userEmail.affiliation.institution && userEmail.affiliation.institution.confirmed && userEmail.affiliation.licence && userEmail.affiliation.licence != 'free'").small
|
2018-08-27 05:26:13 -04:00
|
|
|
span.label.label-primary #{translate("professional")}
|
2020-02-20 11:07:54 -05:00
|
|
|
td
|
|
|
|
div(ng-if="userEmail.affiliation.institution")
|
2018-07-04 11:37:40 -04:00
|
|
|
div {{ userEmail.affiliation.institution.name }}
|
2018-07-12 12:13:26 -04:00
|
|
|
span.small
|
|
|
|
a(
|
|
|
|
href
|
|
|
|
ng-if="!isChangingAffiliation(userEmail.email) && !userEmail.affiliation.role && !userEmail.affiliation.department"
|
|
|
|
ng-click="changeAffiliation(userEmail);"
|
|
|
|
) #{translate("add_role_and_department")}
|
|
|
|
div.small(
|
2018-07-04 11:37:40 -04:00
|
|
|
ng-if="!isChangingAffiliation(userEmail.email) && (userEmail.affiliation.role || userEmail.affiliation.department)"
|
|
|
|
)
|
|
|
|
span(ng-if="userEmail.affiliation.role") {{ userEmail.affiliation.role }}
|
2020-04-08 09:42:58 -04:00
|
|
|
span(ng-if="userEmail.affiliation.role && userEmail.affiliation.department") , 
|
2018-07-04 11:37:40 -04:00
|
|
|
span(ng-if="userEmail.affiliation.department") {{ userEmail.affiliation.department }}
|
2018-07-12 12:13:26 -04:00
|
|
|
br
|
2018-07-04 11:37:40 -04:00
|
|
|
a(
|
|
|
|
href
|
|
|
|
ng-click="changeAffiliation(userEmail);"
|
2018-07-06 07:03:26 -04:00
|
|
|
) #{translate("change")}
|
2018-07-05 10:31:34 -04:00
|
|
|
.affiliation-change-container(
|
2018-07-04 11:37:40 -04:00
|
|
|
ng-if="isChangingAffiliation(userEmail.email)"
|
|
|
|
)
|
|
|
|
affiliation-form(
|
|
|
|
affiliation-data="affiliationToChange"
|
|
|
|
show-university-and-country="false"
|
|
|
|
show-role-and-department="true"
|
|
|
|
)
|
2018-07-12 12:13:26 -04:00
|
|
|
.affiliation-change-actions.small
|
2018-08-27 05:32:24 -04:00
|
|
|
button.btn.btn-sm.btn-success(
|
2018-07-17 06:12:47 -04:00
|
|
|
ng-click="saveAffiliationChange(userEmail);"
|
2018-08-27 05:32:24 -04:00
|
|
|
ng-disabled="!(affiliationToChange.role && affiliationToChange.department)"
|
2019-10-25 04:21:22 -04:00
|
|
|
type="button"
|
2018-07-05 10:31:34 -04:00
|
|
|
) #{translate("save_or_cancel-save")}
|
2018-08-28 11:34:49 -04:00
|
|
|
|  #{translate("save_or_cancel-or" )} 
|
2018-07-04 11:37:40 -04:00
|
|
|
a(
|
|
|
|
href
|
|
|
|
ng-click="cancelAffiliationChange();"
|
2018-07-05 10:31:34 -04:00
|
|
|
) #{translate("save_or_cancel-cancel")}
|
2018-07-12 12:13:26 -04:00
|
|
|
td.affiliations-table-inline-actions
|
|
|
|
// Disabled buttons don't work with tooltips, due to pointer-events: none,
|
|
|
|
// so create a wrapper for the tooltip
|
2021-03-08 09:53:13 -05:00
|
|
|
span(ng-if="!userEmail.default && (!userEmail.confirmedAt || ui.isMakingRequest) && !institutionAlreadyLinked(userEmail) && !inReconfirmNotificationPeriod(userEmail)")
|
|
|
|
.affiliations-table-inline-action-disabled-wrapper(ng-if="userEmail.ssoAvailable")
|
|
|
|
+btnMakePrimaryDisabled(translate("please_link_before_making_primary"))
|
|
|
|
.affiliations-table-inline-action-disabled-wrapper(ng-if="!userEmail.ssoAvailable")
|
|
|
|
+btnMakePrimaryDisabled(translate("please_confirm_your_email_before_making_it_default"))
|
|
|
|
.affiliations-table-inline-action-disabled-wrapper(ng-if="inReconfirmNotificationPeriod(userEmail)")
|
|
|
|
+btnMakePrimaryDisabled(translate("please_reconfirm_your_affiliation_before_making_this_primary"))
|
2018-07-12 12:13:26 -04:00
|
|
|
button.btn.btn-sm.btn-success.affiliations-table-inline-action(
|
2019-04-12 05:39:17 -04:00
|
|
|
tooltip=translate("make_email_primary_description")
|
2021-03-08 09:53:13 -05:00
|
|
|
ng-if="!userEmail.default && (userEmail.confirmedAt && !ui.isMakingRequest) && !inReconfirmNotificationPeriod(userEmail)"
|
2018-07-04 11:54:04 -04:00
|
|
|
ng-click="setDefaultUserEmail(userEmail)"
|
2019-10-25 04:21:22 -04:00
|
|
|
type="button"
|
2019-04-12 05:39:17 -04:00
|
|
|
) #{translate("make_primary")}
|
2018-07-12 12:13:26 -04:00
|
|
|
|
|
2021-02-02 09:25:12 -05:00
|
|
|
+btnRemoveEmail()
|
2021-02-22 10:01:02 -05:00
|
|
|
tr.affiliations-table-saml-row(ng-if="userEmail.affiliation && userEmail.affiliation && userEmail.ssoAvailable")
|
2019-12-09 10:10:07 -05:00
|
|
|
td
|
|
|
|
td(ng-attr-colspan="{{userEmail.samlProviderId ? '2' : '1'}}" ng-class="institutionAlreadyLinked(userEmail) ? '' : 'with-border'")
|
|
|
|
p.small(ng-if="userEmail.samlProviderId")
|
|
|
|
| !{translate("acct_linked_to_institution_acct", {institutionName: '{{userEmail.affiliation.institution.name}}'})}
|
|
|
|
div(ng-if="!userEmail.samlProviderId && !institutionAlreadyLinked(userEmail)")
|
|
|
|
//- this email is not linked to institution login but
|
|
|
|
//- cannot have multiple emails at same institution linked for "institution login"
|
|
|
|
//- so check if institution is already linked
|
|
|
|
p.small
|
|
|
|
| !{translate("can_link_your_institution_acct", {institutionName: '{{userEmail.affiliation.institution.name}}'})}
|
|
|
|
p.small
|
|
|
|
| !{translate("doing_this_allow_log_in_through_institution")}
|
|
|
|
+aboutInstitutionLink()
|
|
|
|
td.with-border.affiliations-table-inline-actions(ng-if="!userEmail.samlProviderId && !institutionAlreadyLinked(userEmail)")
|
|
|
|
button.btn-sm.btn.btn-info(
|
|
|
|
ng-click="linkInstitutionAcct(userEmail.email, userEmail.affiliation.institution.id)"
|
|
|
|
ng-disabled="ui.isMakingRequest"
|
|
|
|
type="button"
|
|
|
|
)
|
|
|
|
| #{translate("link_accounts")}
|
2021-02-22 10:01:02 -05:00
|
|
|
tr(
|
|
|
|
class="reconfirm-row"
|
|
|
|
ng-if="userEmail.samlIdentifier && userEmail.samlIdentifier.providerId === reconfirmedViaSAML"
|
|
|
|
)
|
|
|
|
td(colspan="3")
|
|
|
|
+reconfirmedAffiliationNotification()
|
|
|
|
tr(
|
|
|
|
class="reconfirm-row"
|
|
|
|
ng-repeat-end
|
|
|
|
)
|
|
|
|
td(
|
|
|
|
colspan="3"
|
|
|
|
ng-if="userEmail.affiliation && userEmail.affiliation.inReconfirmNotificationPeriod"
|
|
|
|
)
|
|
|
|
div(ng-class="{'alert alert-info': reconfirmationRemoveEmail === userEmail.email}")
|
|
|
|
+reconfirmAffiliationNotification('/user/settings')
|
|
|
|
|
2018-06-27 12:08:25 -04:00
|
|
|
tr.affiliations-table-highlighted-row(
|
2018-07-17 06:12:47 -04:00
|
|
|
ng-if="!ui.showAddEmailUI && !ui.isMakingRequest"
|
2018-06-27 12:08:25 -04:00
|
|
|
)
|
|
|
|
td(colspan="3")
|
|
|
|
a(
|
|
|
|
href
|
|
|
|
ng-click="showAddEmailForm()"
|
2018-07-05 10:31:34 -04:00
|
|
|
) #{translate("add_another_email")}
|
2018-06-27 12:08:25 -04:00
|
|
|
|
|
|
|
tr.affiliations-table-highlighted-row(
|
2018-07-17 06:12:47 -04:00
|
|
|
ng-if="ui.showAddEmailUI && !ui.isLoadingEmails"
|
2018-06-27 12:08:25 -04:00
|
|
|
)
|
|
|
|
td
|
|
|
|
.affiliations-form-group
|
|
|
|
input-suggestions(
|
|
|
|
ng-model="newAffiliation.email"
|
|
|
|
ng-model-options="{ allowInvalid: true }"
|
|
|
|
get-suggestion="getEmailSuggestion(userInput)"
|
|
|
|
on-blur="handleEmailInputBlur()"
|
|
|
|
input-id="affilitations-email"
|
|
|
|
input-name="affilitationsEmail"
|
|
|
|
input-placeholder="e.g. johndoe@mit.edu"
|
|
|
|
input-type="email"
|
|
|
|
input-required="true"
|
|
|
|
)
|
2019-12-09 10:10:07 -05:00
|
|
|
td(
|
|
|
|
colspan="2"
|
|
|
|
ng-if="newAffiliation.ssoAvailable"
|
|
|
|
)
|
|
|
|
p.affiliations-table-label {{ newAffiliation.university.name }}
|
|
|
|
p !{translate("to_add_email_accounts_need_to_be_linked", {institutionName: "{{newAffiliation.university.name}}"})}
|
|
|
|
p !{translate("doing_this_will_verify_affiliation_and_allow_log_in", {institutionName: "{{newAffiliation.university.name}}"})}
|
|
|
|
+aboutInstitutionLink()
|
|
|
|
button.btn-sm.btn.btn-primary.btn-link-accounts(
|
|
|
|
ng-click="linkInstitutionAcct(newAffiliation.email, newAffiliation.university.id)"
|
|
|
|
ng-disabled="ui.isMakingRequest"
|
|
|
|
type="button"
|
2019-10-02 17:37:19 -04:00
|
|
|
)
|
2019-12-09 10:10:07 -05:00
|
|
|
| #{translate("link_accounts_and_add_email")}
|
2019-10-02 17:37:19 -04:00
|
|
|
td(
|
2019-12-09 10:10:07 -05:00
|
|
|
ng-if="!newAffiliation.ssoAvailable"
|
2019-10-02 17:37:19 -04:00
|
|
|
)
|
2018-07-12 12:13:26 -04:00
|
|
|
p.affiliations-table-label(
|
2018-06-27 12:08:25 -04:00
|
|
|
ng-if="newAffiliation.university && !ui.showManualUniversitySelectionUI"
|
|
|
|
)
|
2018-07-12 12:13:26 -04:00
|
|
|
| {{ newAffiliation.university.name }}
|
|
|
|
span.small
|
|
|
|
| (
|
|
|
|
a(
|
|
|
|
href
|
|
|
|
ng-click="selectUniversityManually();"
|
|
|
|
) #{translate("change")}
|
|
|
|
| )
|
2018-06-27 12:08:25 -04:00
|
|
|
.affiliations-table-label(
|
|
|
|
ng-if="!newAffiliation.university && !ui.isValidEmail && !ui.showManualUniversitySelectionUI"
|
2018-07-05 10:31:34 -04:00
|
|
|
) #{translate("start_by_adding_your_email")}
|
2018-06-27 12:08:25 -04:00
|
|
|
.affiliations-table-label(
|
|
|
|
ng-if="!newAffiliation.university && ui.isValidEmail && !ui.isBlacklistedEmail && !ui.showManualUniversitySelectionUI"
|
|
|
|
)
|
2018-07-05 10:31:34 -04:00
|
|
|
| #{translate("is_email_affiliated")}
|
2018-06-27 12:08:25 -04:00
|
|
|
br
|
|
|
|
a(
|
|
|
|
href
|
|
|
|
ng-click="selectUniversityManually();"
|
2018-07-05 10:31:34 -04:00
|
|
|
) #{translate("let_us_know")}
|
2018-07-03 11:47:02 -04:00
|
|
|
affiliation-form(
|
|
|
|
affiliation-data="newAffiliation"
|
|
|
|
show-university-and-country="ui.showManualUniversitySelectionUI"
|
|
|
|
show-role-and-department="ui.isValidEmail && newAffiliation.university"
|
2018-06-27 12:08:25 -04:00
|
|
|
)
|
2019-10-02 17:37:19 -04:00
|
|
|
td(
|
2019-12-09 10:10:07 -05:00
|
|
|
ng-if="!newAffiliation.ssoAvailable"
|
2019-10-02 17:37:19 -04:00
|
|
|
)
|
2018-07-12 12:13:26 -04:00
|
|
|
button.btn.btn-sm.btn-primary(
|
2018-07-17 06:12:47 -04:00
|
|
|
ng-disabled="affiliationsForm.$invalid || ui.isMakingRequest"
|
2018-06-27 12:08:25 -04:00
|
|
|
ng-click="addNewEmail()"
|
|
|
|
)
|
2018-07-17 06:12:47 -04:00
|
|
|
| #{translate("add_new_email")}
|
|
|
|
tr.affiliations-table-highlighted-row(
|
|
|
|
ng-if="ui.isMakingRequest"
|
|
|
|
)
|
2020-02-20 11:07:54 -05:00
|
|
|
td.text-center(colspan="3", ng-if="ui.isLoadingEmails")
|
2018-11-19 04:41:34 -05:00
|
|
|
i.fa.fa-fw.fa-spin.fa-refresh(aria-hidden="true")
|
2020-04-22 05:35:33 -04:00
|
|
|
| #{translate("loading")}…
|
2020-02-20 11:07:54 -05:00
|
|
|
td.text-center(colspan="3", ng-if="ui.isResendingConfirmation")
|
2018-11-19 04:41:34 -05:00
|
|
|
i.fa.fa-fw.fa-spin.fa-refresh(aria-hidden="true")
|
2020-04-22 05:35:33 -04:00
|
|
|
| #{translate("sending")}…
|
2020-02-20 11:07:54 -05:00
|
|
|
td.text-center.text-capitalize(colspan="3", ng-if="ui.isProcessing")
|
2019-10-02 10:06:23 -04:00
|
|
|
i.fa.fa-fw.fa-spin.fa-refresh(aria-hidden="true")
|
|
|
|
| #{translate("processing")}
|
|
|
|
td.text-center(colspan="3", ng-if="!ui.isLoadingEmails && !ui.isResendingConfirmation && !ui.isProcessing")
|
2019-09-30 09:21:31 -04:00
|
|
|
i.fa.fa-fw.fa-spin.fa-refresh(aria-hidden="true")
|
2019-09-30 11:58:31 -04:00
|
|
|
| #{translate("saving")}
|
2018-07-05 06:36:02 -04:00
|
|
|
tr.affiliations-table-error-row(
|
2018-07-17 06:12:47 -04:00
|
|
|
ng-if="ui.hasError"
|
2018-07-05 06:36:02 -04:00
|
|
|
)
|
2020-02-20 11:07:54 -05:00
|
|
|
td.text-center(colspan="3")
|
2018-07-05 06:36:02 -04:00
|
|
|
div
|
2018-11-19 04:41:34 -05:00
|
|
|
i.fa.fa-fw.fa-exclamation-triangle(aria-hidden="true")
|
2018-07-17 06:12:47 -04:00
|
|
|
span(ng-if="!ui.errorMessage") #{translate("error_performing_request")}
|
|
|
|
span(ng-if="ui.errorMessage") {{ui.errorMessage}}
|
2019-09-30 09:21:31 -04:00
|
|
|
if institutionLinked
|
|
|
|
tr.affiliations-table-info-row(ng-if="!hideInstitutionNotifications.info")
|
2019-10-21 12:02:01 -04:00
|
|
|
td.text-center(aria-live="assertive" colspan="3")
|
2019-09-30 09:21:31 -04:00
|
|
|
button.close(
|
|
|
|
type="button"
|
|
|
|
data-dismiss="modal"
|
|
|
|
ng-click="closeInstitutionNotification('info')"
|
|
|
|
aria-label=translate("close")
|
|
|
|
)
|
|
|
|
span(aria-hidden="true") ×
|
|
|
|
.small !{translate("institution_acct_successfully_linked", {institutionName: institutionLinked.universityName})}
|
|
|
|
if institutionLinked.hasEntitlement
|
|
|
|
.small !{translate("this_grants_access_to_features", {featureType: translate("professional")})}
|
2019-10-17 11:30:37 -04:00
|
|
|
if institutionEmailNonCanonical
|
2019-09-30 09:21:31 -04:00
|
|
|
tr.affiliations-table-warning-row(ng-if="!hideInstitutionNotifications.warning")
|
2019-10-21 12:02:01 -04:00
|
|
|
td.text-center(aria-live="assertive" colspan="3")
|
2019-09-30 09:21:31 -04:00
|
|
|
button.close(
|
|
|
|
type="button"
|
|
|
|
data-dismiss="modal"
|
|
|
|
ng-click="closeInstitutionNotification('warning')"
|
|
|
|
aria-label=translate("close")
|
|
|
|
)
|
|
|
|
span(aria-hidden="true") ×
|
|
|
|
.small
|
|
|
|
i.fa.fa-exclamation-triangle(aria-hidden="true")
|
|
|
|
|
|
2019-10-17 11:30:37 -04:00
|
|
|
| !{translate("in_order_to_match_institutional_metadata", {email: institutionEmailNonCanonical})}
|
2021-02-18 06:46:08 -05:00
|
|
|
|
|
|
|
if samlError
|
2020-03-11 09:21:54 -04:00
|
|
|
tr.affiliations-table-error-row(ng-if="!hideInstitutionNotifications.linkError")
|
|
|
|
td.text-center(aria-live="assertive" colspan="3")
|
|
|
|
button.close(
|
|
|
|
type="button"
|
|
|
|
data-dismiss="modal"
|
|
|
|
ng-click="closeInstitutionNotification('linkError')"
|
|
|
|
aria-label=translate("close")
|
|
|
|
)
|
|
|
|
span(aria-hidden="true") ×
|
|
|
|
.small
|
2021-02-18 06:46:08 -05:00
|
|
|
i.fa.fa-fw.fa-exclamation-triangle(aria-hidden="true")
|
|
|
|
| #{translate("generic_something_went_wrong")}.
|
|
|
|
br
|
|
|
|
if samlError.translatedMessage
|
|
|
|
| !{samlError.translatedMessage}
|
|
|
|
else if samlError.message
|
|
|
|
| #{samlError.message}
|
|
|
|
if samlError.tryAgain
|
|
|
|
br
|
|
|
|
| #{translate("try_again")}.
|
2018-07-03 11:47:02 -04:00
|
|
|
|
|
|
|
script(type="text/ng-template", id="affiliationFormTpl")
|
|
|
|
.affiliations-form-group(
|
|
|
|
ng-if="$ctrl.showUniversityAndCountry"
|
|
|
|
)
|
|
|
|
ui-select(
|
|
|
|
ng-model="$ctrl.affiliationData.country"
|
|
|
|
)
|
|
|
|
ui-select-match(
|
|
|
|
placeholder="Country"
|
|
|
|
) {{ $select.selected.name }}
|
|
|
|
ui-select-choices(
|
|
|
|
repeat="country in $ctrl.countries | filter: $select.search"
|
|
|
|
)
|
|
|
|
span(
|
|
|
|
ng-bind="country.name"
|
|
|
|
)
|
|
|
|
.affiliations-form-group(
|
|
|
|
ng-if="$ctrl.showUniversityAndCountry"
|
|
|
|
)
|
|
|
|
ui-select(
|
|
|
|
ng-model="$ctrl.affiliationData.university"
|
|
|
|
ng-disabled="!$ctrl.affiliationData.country"
|
2018-08-24 10:29:48 -04:00
|
|
|
tagging="$ctrl.addUniversityToSelection"
|
2018-07-03 11:47:02 -04:00
|
|
|
tagging-label="false"
|
|
|
|
)
|
|
|
|
ui-select-match(
|
|
|
|
placeholder="Institution"
|
|
|
|
) {{ $select.selected.name }}
|
|
|
|
ui-select-choices(
|
|
|
|
repeat="university in $ctrl.universities | filter: $select.search"
|
2018-08-29 12:31:47 -04:00
|
|
|
refresh="$ctrl.handleFreeformInputChange($select, 'name');"
|
|
|
|
refresh-delay="10"
|
2018-07-03 11:47:02 -04:00
|
|
|
)
|
|
|
|
span(
|
|
|
|
ng-bind="university.name"
|
|
|
|
)
|
|
|
|
.affiliations-form-group(
|
|
|
|
ng-if="$ctrl.showRoleAndDepartment"
|
|
|
|
)
|
|
|
|
ui-select(
|
|
|
|
ng-model="$ctrl.affiliationData.role"
|
|
|
|
tagging
|
|
|
|
tagging-label="false"
|
|
|
|
)
|
|
|
|
ui-select-match(
|
|
|
|
placeholder="Role"
|
|
|
|
) {{ $select.selected }}
|
|
|
|
ui-select-choices(
|
|
|
|
repeat="role in $ctrl.roles | filter: $select.search"
|
2018-08-29 12:31:47 -04:00
|
|
|
refresh="$ctrl.handleFreeformInputChange($select);"
|
|
|
|
refresh-delay="10"
|
2018-07-03 11:47:02 -04:00
|
|
|
)
|
|
|
|
span(
|
|
|
|
ng-bind="role"
|
|
|
|
)
|
|
|
|
|
|
|
|
.affiliations-form-group(
|
|
|
|
ng-if="$ctrl.showRoleAndDepartment"
|
|
|
|
)
|
|
|
|
ui-select(
|
|
|
|
ng-model="$ctrl.affiliationData.department"
|
|
|
|
tagging
|
|
|
|
tagging-label="false"
|
|
|
|
)
|
|
|
|
ui-select-match(
|
|
|
|
placeholder="Department"
|
|
|
|
) {{ $select.selected }}
|
|
|
|
ui-select-choices(
|
|
|
|
repeat="department in $ctrl.departments | filter: $select.search"
|
2018-08-29 12:31:47 -04:00
|
|
|
refresh="$ctrl.handleFreeformInputChange($select);"
|
|
|
|
refresh-delay="10"
|
2018-07-03 11:47:02 -04:00
|
|
|
)
|
|
|
|
span(
|
|
|
|
ng-bind="department"
|
|
|
|
)
|