Follow-up - 51bf33d - Fixes #3580 - Add description to package manager GUI.
This commit is contained in:
parent
d4e26f878c
commit
28d1594956
3 changed files with 17 additions and 1 deletions
|
@ -16,6 +16,7 @@ class Package extends App.ControllerSubContent
|
|||
processData: true,
|
||||
success: (data) =>
|
||||
@packages = data.packages
|
||||
@commands = data.commands
|
||||
@render()
|
||||
)
|
||||
|
||||
|
@ -34,6 +35,7 @@ class Package extends App.ControllerSubContent
|
|||
@html App.view('package')(
|
||||
head: 'Dashboard'
|
||||
packages: @packages
|
||||
commands: @commands
|
||||
)
|
||||
|
||||
action: (e) ->
|
||||
|
|
|
@ -3,6 +3,15 @@
|
|||
</div>
|
||||
|
||||
<div class="page-content">
|
||||
<p>
|
||||
<%- @T('After installing, updating or uninstalling packages the following commands need to be executed on the server:') %>
|
||||
<ul>
|
||||
<% for command in @commands: %>
|
||||
<li><code>zammad> <%- command %></code></li>
|
||||
<% end %>
|
||||
<li><code>root> systemctl restart zammad</code></li>
|
||||
</ul>
|
||||
</p>
|
||||
<!--
|
||||
<ul class="nav nav-tabs nav-stacked">
|
||||
<li class=""><a data-type="" ><%- @T('Installed') %></a></li>
|
||||
|
|
|
@ -6,8 +6,13 @@ class PackagesController < ApplicationController
|
|||
# GET /api/v1/packages
|
||||
def index
|
||||
packages = Package.all.order('name')
|
||||
commands = ['rails zammad:db:migrate', 'rails assets:precompile']
|
||||
if File.exist?('/usr/bin/zammad')
|
||||
commands.map! { |s| "zammad run #{s}" }
|
||||
end
|
||||
render json: {
|
||||
packages: packages
|
||||
packages: packages,
|
||||
commands: commands
|
||||
}
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in a new issue