diff options
author | Maxime Quandalle <maxime@quandalle.com> | 2015-09-05 01:31:25 +0200 |
---|---|---|
committer | Maxime Quandalle <maxime@quandalle.com> | 2015-09-05 01:37:55 +0200 |
commit | 82b322777852b0f7b3f93295a0dbcc0c238bd20d (patch) | |
tree | cb75983a021909ac96f99bdb1448cd2ebee72b48 /client/components/sidebar/sidebar.jade | |
parent | 6a92963e2a79e2819b7492a0389c1c48a9467ba3 (diff) | |
download | wekan-82b322777852b0f7b3f93295a0dbcc0c238bd20d.tar.gz wekan-82b322777852b0f7b3f93295a0dbcc0c238bd20d.tar.bz2 wekan-82b322777852b0f7b3f93295a0dbcc0c238bd20d.zip |
Fix member permission modification
Fixes #280
Diffstat (limited to 'client/components/sidebar/sidebar.jade')
-rw-r--r-- | client/components/sidebar/sidebar.jade | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/client/components/sidebar/sidebar.jade b/client/components/sidebar/sidebar.jade index f162fd6c..7e9cde80 100644 --- a/client/components/sidebar/sidebar.jade +++ b/client/components/sidebar/sidebar.jade @@ -26,7 +26,7 @@ template(name="membersWidget") i.fa.fa-user | {{_ 'members'}} .board-widget-content - each currentBoard.members + each currentBoard.activeMembers +userAvatar(userId=this.userId showStatus=true) unless isSandstorm if currentUser.isBoardAdmin @@ -50,7 +50,7 @@ template(name="labelsWidget") template(name="memberPopup") .board-member-menu .miniprofile-header - +userAvatar(userId=user._id) + +userAvatar(userId=user._id showEdit=true) .info h3 .js-profile= user.profile.fullname @@ -67,10 +67,12 @@ template(name="memberPopup") | {{_ 'change-permissions'}} span.quiet (#{memberType}) li - if currentUser.isBoardAdmin - a.js-remove-member {{_ 'remove-from-board'}} + if $eq currentUser._id userId + //- + XXX Not implemented! + // a.js-leave-member {{_ 'leave-board'}} else - a.js-leave-member {{_ 'leave-board'}} + a.js-remove-member {{_ 'remove-from-board'}} template(name="removeMemberPopup") @@ -81,16 +83,16 @@ template(name="addMemberPopup") .js-search-member +esInput(index="users") - ul.pop-over-member-list + ul.pop-over-list +esEach(index="users") - li.item.js-member-item(class="{{#if isBoardMember }}disabled{{/if}}") - a.name.js-select-member(title="{{ profile.name }} ({{ username }})") + li.item.js-member-item(class="{{#if isBoardMember}}disabled{{/if}}") + a.name.js-select-member(title="{{profile.name}} ({{username}})") +userAvatar(userId=_id) span.full-name = profile.name - | (<span class="username">{{ username }}</span>) + | (<span class="username">{{username}}</span>) if isBoardMember - .extra-text.quiet ({{_ 'joined'}}) + .quiet ({{_ 'joined'}}) +ifEsIsSearching(index='users') +spinner |