mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
show the publish template area to all project owners
This commit is contained in:
parent
fe16bea798
commit
721eda71f3
2 changed files with 29 additions and 29 deletions
|
@ -286,32 +286,31 @@
|
|||
|
||||
|
||||
script(type="text/template")#publishProjectTemplate
|
||||
-if(session && session.user && session.user.isAdmin)
|
||||
.box
|
||||
.page-header
|
||||
h2 Publish project as template
|
||||
|
||||
#publishedAsTemplateArea.show-when-published.alert.alert-success
|
||||
p
|
||||
.btn.btn-warning#unPublishProjectAsTemplate.pull-right Unpublish
|
||||
i.icon-ok
|
||||
| Your project is currently published.
|
||||
a#templateLink(href='{{canonicalUrl}}') View in template gallery.
|
||||
p
|
||||
| Lastest version: {{publishedDate}}.
|
||||
.box
|
||||
.page-header
|
||||
h2 Publish project as template
|
||||
|
||||
#publishedAsTemplateArea.show-when-published.alert.alert-success
|
||||
p
|
||||
.btn.btn-warning#unPublishProjectAsTemplate.pull-right Unpublish
|
||||
i.icon-ok
|
||||
| Your project is currently published.
|
||||
a#templateLink(href='{{canonicalUrl}}') View in template gallery.
|
||||
p
|
||||
| Lastest version: {{publishedDate}}.
|
||||
|
||||
#problemWithPublishingArea
|
||||
p There is a problem with our publishing service, please try again in a few minutes.
|
||||
#publishWorkingArea
|
||||
p Working...
|
||||
div.show-when-published.show-when-unpublished.project-description
|
||||
label(for="project-description") Description
|
||||
.row-fluid
|
||||
textarea(placeholder="Template description", name="project-description").span12#projectDescription {{description}}
|
||||
#unpublishedAsTemplateArea.show-when-unpublished
|
||||
.btn.btn-success#publishProjectAsTemplate Publish
|
||||
p.show-when-published
|
||||
button.btn.btn-success#republishProjectAsTemplate Re-Publish
|
||||
#problemWithPublishingArea
|
||||
p There is a problem with our publishing service, please try again in a few minutes.
|
||||
#publishWorkingArea
|
||||
p Working...
|
||||
div.show-when-published.show-when-unpublished.project-description
|
||||
label(for="project-description") Description
|
||||
.row-fluid
|
||||
textarea(placeholder="Template description", name="project-description").span12#projectDescription {{description}}
|
||||
#unpublishedAsTemplateArea.show-when-unpublished
|
||||
.btn.btn-success#publishProjectAsTemplate Publish
|
||||
p.show-when-published
|
||||
button.btn.btn-success#republishProjectAsTemplate Re-Publish
|
||||
|
||||
|
||||
script(type="text/template")#settingsPanelTemplate
|
||||
|
|
|
@ -25,10 +25,11 @@ define [
|
|||
@publishProjectView?.refreshPublishStatus()
|
||||
|
||||
setupPublish = _.once =>
|
||||
@publishProjectView = new PublishProjectView
|
||||
ide: @ide
|
||||
el: $("#publishProject")
|
||||
@publishProjectView.render()
|
||||
if @ide.security? and @ide.security.permissionsLevel == "owner"
|
||||
@publishProjectView = new PublishProjectView
|
||||
ide: @ide
|
||||
el: $("#publishProject")
|
||||
@publishProjectView.render()
|
||||
|
||||
setupArea()
|
||||
if @ide?
|
||||
|
|
Loading…
Reference in a new issue