@(c: lila.coach.Coach.WithUser, form: Form[_], reviews: lila.coach.CoachReview.Reviews)(implicit ctx: Context) @import play.api.data.Field @textarea(field: Field, name: Html, help: Option[Html] = None) = { @base.form.group(field, name, half = false, help = help) { } } @moreCss = { @cssTag("material.form.css") @cssTag("coach.form.css") } @moreJs = { @jsAt("vendor/bar-rating/dist/jquery.barrating.min.js") @jsTag("coach.form.js") } @side = { Preview coach page } @base.layout(title = s"${c.user.titleUsername} coach page", moreCss = moreCss, moreJs = moreJs, side = side.some) {
@if(c.coach.hasPicture) { @pic(c, 250) } else { }

@c.user.title.map { t => @t }@c.user.profileOrDefault.nonEmptyRealName.getOrElse(c.user.username)

TODO list before publishing your coach profile

    Basics
    Texts
    Contents
    Pending reviews
    @base.form.group(form("listed"), Html("Publish on the coaches list"), help = Html("Set to Yes when your profile is ready").some, half = true) { @base.form.select(form("listed"), booleanChoices) } @base.form.group(form("available"), Html("Currently available for lessons"), help = Html("Set to Yes to get more students").some, half = true) { @base.form.select(form("available"), booleanChoices) }
    @base.form.group(form("profile.headline"), Html("Short and inspiring headline"), help = Html("Just one sentence to make students want to choose you").some) { @base.form.input(form("profile.headline"), maxLength = 170) }
    @base.form.group(form("profile.languages"), Html("Languages spoken"), help = Html("Which languages can you give lessons in?").some, half = true) { @base.form.input(form("profile.languages"), maxLength = 140) } @base.form.group(form("profile.hourlyRate"), Html("Hourly rate"), help = Html("Indicative, non-contractual").some, half = true) { @base.form.input(form("profile.hourlyRate"), maxLength = 140) }
    @textarea(form("profile.description"), Html("Who are you?"), help = Html("Age, profession, country... let your students know you").some) @textarea(form("profile.playingExperience"), Html("Playing experience"), help = Html("Tournaments played, best wins, other achievements").some) @textarea(form("profile.teachingExperience"), Html("Teaching experience"), help = Html("Diplomas, years of practice, best student results").some) @textarea(form("profile.otherExperience"), Html("Other experiences"), help = Html("E.g. as chess commentator, or teaching other domains").some) @textarea(form("profile.skills"), Html("Best skills in chess and teaching")) @textarea(form("profile.methodology"), Html("Teaching methodology"), help = Html("How you prepare and run lessons. How you follow up with students.").some)
    @textarea(form("profile.publicStudies"), Html("Featured public lichess studies"), help = Html("Up to 6 lichess study URLs, one per line").some) @base.form.group(form("profile.youtubeChannel"), Html("URL of your Youtube channel")) { @base.form.input(form("profile.youtubeChannel")) } @textarea(form("profile.youtubeVideos"), Html("Featured youtube videos"), help = Html("Up to 6 Youtube video URLs, one per line").some)

    Reviews are visible only after you approve them.

    @reviews.list.map { r =>
    @userIdLink(r.userId.some) @barRating(selected = r.score.some, enabled = false) @momentFromNow(r.updatedAt)
    @if(r.moddedAt.isDefined) {
    Moderators have disapproved this review. Please only accept reviews from actual students, based on actual lessons. Reviews must be about your coaching services.
    You may delete this review, or ask the author to rephrase it, then approve it.
    } @richText(r.text)
    @if(r.moddedAt.fold(true)(_.isBefore(r.updatedAt))) { }
    }
    Your changes have been saved.
    }