Ghost/ghost/admin/app/templates/member.hbs
Rish 5a609a785f Enabled write operation for member name and note
no issue

- Allows editing member's name and note in admin
2019-10-10 17:29:35 +05:30

52 lines
2.1 KiB
Handlebars
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<section class="gh-canvas">
<form class="mb10 member-basic-info-form" {{action (perform "save") on="submit"}}>
<GhCanvasHeader class="gh-canvas-header">
<h2 class="gh-canvas-title" data-test-screen-title>
{{#link-to "members" data-test-link="members-back"}}Members{{/link-to}}
<span>{{svg-jar "arrow-right"}}</span>
{{#if member.name}}
{{member.name}}
{{else}}
{{member.email}}
{{/if}}
</h2>
<section class="view-actions">
{{gh-task-button task=save class="gh-btn gh-btn-blue gh-btn-icon" data-test-button="save"}}
</section>
</GhCanvasHeader>
<div class="flex items-center mb10 bt b--lightgrey-d1 pt8">
<GhMemberAvatar @member={{member}} @sizeClass={{'f-headline fw4 lh-zero'}} class="w18 h18 mr4" />
<div>
<h3 class="f2 fw5 ma0 pa0">
{{if member.name member.name member.email}}
</h3>
<p class="f6 pa0 ma0 midgrey">
{{#if member.name}}
<span class="darkgrey">{{member.email}}</span>
{{/if}}
Member since {{this.subscribedAt}}
</p>
</div>
</div>
{{gh-member-settings-form member=member
setProperty=(action "setProperty")
isLoading=this.isLoading
showDeleteTagModal=(action "toggleDeleteTagModal")}}
</form>
<button
type="button"
class="gh-btn gh-btn-red gh-btn-icon mt3"
{{action (toggle "showDeleteMemberModal" this)}}
data-test-button="delete-member"
>
<span>Delete member</span>
</button>
</section>
{{#if showDeleteMemberModal}}
{{gh-fullscreen-modal "delete-member"
model=(hash member=member onSuccess=(action "finaliseDeletion"))
close=(action (toggle "showDeleteMemberModal" this))
modifier="action wide"}}
{{/if}}