2016-08-09 13:18:27 +08:00
|
|
|
@extends('admin.master')
|
|
|
|
|
2016-09-25 10:02:40 +08:00
|
|
|
@section('title', trans('general.check-update'))
|
2016-08-09 13:18:27 +08:00
|
|
|
|
|
|
|
@section('content')
|
|
|
|
|
|
|
|
<!-- Content Wrapper. Contains page content -->
|
|
|
|
<div class="content-wrapper">
|
|
|
|
<!-- Content Header (Page header) -->
|
|
|
|
<section class="content-header">
|
|
|
|
<h1>
|
2016-09-25 10:02:40 +08:00
|
|
|
{{ trans('general.check-update') }}
|
2016-08-09 13:18:27 +08:00
|
|
|
</h1>
|
|
|
|
</section>
|
|
|
|
|
|
|
|
<!-- Main content -->
|
|
|
|
<section class="content">
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-md-6">
|
|
|
|
<div class="box box-primary">
|
|
|
|
<div class="box-header with-border">
|
2016-12-30 20:37:27 +08:00
|
|
|
<h3 class="box-title">{{ trans('admin.update.info.title') }}</h3>
|
2016-08-09 13:18:27 +08:00
|
|
|
</div><!-- /.box-header -->
|
|
|
|
<div class="box-body">
|
2016-11-25 12:54:20 +08:00
|
|
|
@if ($info['new_version_available'])
|
2016-12-30 20:37:27 +08:00
|
|
|
<div class="callout callout-info">{{ trans('admin.update.info.available') }}</div>
|
2016-08-09 13:18:27 +08:00
|
|
|
<table class="table">
|
|
|
|
<tbody>
|
|
|
|
<tr>
|
2016-12-30 20:37:27 +08:00
|
|
|
<td class="key">{{ trans('admin.update.info.versions.latest') }}</td>
|
2016-08-09 13:18:27 +08:00
|
|
|
<td class="value">
|
2016-11-25 12:54:20 +08:00
|
|
|
v{{ $info['latest_version'] }}
|
2016-08-09 13:18:27 +08:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2016-12-30 20:37:27 +08:00
|
|
|
<td class="key">{{ trans('admin.update.info.versions.current') }}</td>
|
2016-08-09 13:18:27 +08:00
|
|
|
<td class="value">
|
2016-11-25 12:54:20 +08:00
|
|
|
v{{ $info['current_version'] }}
|
2016-08-09 13:18:27 +08:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2016-12-30 20:37:27 +08:00
|
|
|
<td class="key">{{ trans('admin.update.info.release-time') }}</td>
|
2016-08-09 13:18:27 +08:00
|
|
|
<td class="value">
|
2016-11-25 12:54:20 +08:00
|
|
|
{{ Utils::getTimeFormatted($info['release_time']) }}
|
2016-08-09 13:18:27 +08:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2016-12-30 20:37:27 +08:00
|
|
|
<td class="key">{{ trans('admin.update.info.change-log.text') }}</td>
|
2016-08-09 13:18:27 +08:00
|
|
|
<td class="value">
|
2016-12-30 20:37:27 +08:00
|
|
|
{!! nl2br($info['release_note']) ?: trans('admin.update.info.change-log.empty') !!}
|
2016-08-09 13:18:27 +08:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2016-12-30 20:37:27 +08:00
|
|
|
<td class="key">{{ trans('admin.update.info.downloads.text') }}</td>
|
2016-08-09 13:18:27 +08:00
|
|
|
<td class="value">
|
2016-12-30 20:37:27 +08:00
|
|
|
<a href="{!! $info['release_url'] !!}">{{ trans('admin.update.info.downloads.link') }}</a>
|
2016-08-09 13:18:27 +08:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
|
2016-11-25 12:54:20 +08:00
|
|
|
@if($info['pre_release'])
|
2016-12-30 20:37:27 +08:00
|
|
|
<div class="callout callout-warning">{{ trans('admin.update.info.pre-release-warning') }}</div>
|
2016-11-25 12:54:20 +08:00
|
|
|
@endif
|
|
|
|
|
2016-08-09 13:18:27 +08:00
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
@else
|
2016-12-30 20:37:27 +08:00
|
|
|
<div class="callout callout-success">{{ trans('admin.update.info.up-to-date') }}</div>
|
2016-08-09 13:18:27 +08:00
|
|
|
<table class="table">
|
|
|
|
<tbody>
|
|
|
|
<tr>
|
2016-12-30 20:37:27 +08:00
|
|
|
<td class="key">{{ trans('admin.update.info.versions.current') }}</td>
|
2016-08-09 13:18:27 +08:00
|
|
|
<td class="value">
|
2016-11-25 12:54:20 +08:00
|
|
|
v{{ $info['current_version'] }}
|
2016-08-09 13:18:27 +08:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
<tr>
|
2016-12-30 20:37:27 +08:00
|
|
|
<td class="key">{{ trans('admin.update.info.release-time') }}</td>
|
2016-08-09 13:18:27 +08:00
|
|
|
<td class="value">
|
2016-12-30 20:37:27 +08:00
|
|
|
@if ($info['release_time'])
|
2016-11-25 12:54:20 +08:00
|
|
|
{{ Utils::getTimeFormatted($info['release_time']) }}
|
|
|
|
@else
|
2016-12-30 20:37:27 +08:00
|
|
|
{{ trans('admin.update.info.pre-release') }}
|
2016-11-25 12:54:20 +08:00
|
|
|
@endif
|
2016-08-09 13:18:27 +08:00
|
|
|
</td>
|
|
|
|
</tr>
|
|
|
|
</tbody>
|
|
|
|
</table>
|
|
|
|
@endif
|
|
|
|
</div><!-- /.box-body -->
|
|
|
|
<div class="box-footer">
|
2017-11-24 22:27:33 +08:00
|
|
|
<a class="btn btn-primary" id="update-button" {!! !$info['new_version_available'] ? 'disabled="disabled"' : 'onclick="downloadUpdates();"' !!}>{{ trans('admin.update.info.button') }}</a>
|
2016-12-30 20:37:27 +08:00
|
|
|
{!! trans('admin.update.info.check-github', ['url' => 'https://github.com/printempw/blessing-skin-server/releases']) !!}
|
2016-08-09 13:18:27 +08:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="box box-default">
|
|
|
|
<div class="box-header with-border">
|
2016-12-30 20:37:27 +08:00
|
|
|
<h3 class="box-title">{{ trans('admin.update.cautions.title') }}</h3>
|
2016-08-09 13:18:27 +08:00
|
|
|
</div><!-- /.box-header -->
|
|
|
|
<div class="box-body">
|
2016-12-30 20:37:27 +08:00
|
|
|
<p>{!! nl2br(trans('admin.update.cautions.text')) !!}</p>
|
2016-08-09 13:18:27 +08:00
|
|
|
</div><!-- /.box-body -->
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
|
|
|
|
<div class="col-md-6">
|
2016-12-30 20:37:27 +08:00
|
|
|
{!! $update->render() !!}
|
2016-08-09 13:18:27 +08:00
|
|
|
</div>
|
|
|
|
|
|
|
|
</div>
|
|
|
|
</section><!-- /.content -->
|
|
|
|
</div><!-- /.content-wrapper -->
|
|
|
|
|
2016-11-25 12:54:20 +08:00
|
|
|
<div id="modal-start-download" class="modal fade" tabindex="-1" role="dialog">
|
|
|
|
<div class="modal-dialog">
|
|
|
|
<div class="modal-content">
|
|
|
|
<div class="modal-header">
|
|
|
|
<button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">×</span></button>
|
2017-01-02 15:31:46 +08:00
|
|
|
<h4 class="modal-title">{{ trans('admin.update.download.downloading') }}</h4>
|
2016-11-25 12:54:20 +08:00
|
|
|
</div>
|
|
|
|
<div class="modal-body">
|
2017-01-02 15:31:46 +08:00
|
|
|
<p>{{ trans('admin.update.download.size') }}<span id="file-size">0</span> Bytes</p>
|
2016-11-25 12:54:20 +08:00
|
|
|
<div class="progress">
|
|
|
|
<div class="progress-bar progress-bar-striped active" role="progressbar" aria-valuenow="0" aria-valuemin="0" aria-valuemax="100" style="width: 0%">
|
|
|
|
<span id="imported-progress">0</span>%
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div><!-- /.modal-content -->
|
|
|
|
</div><!-- /.modal-dialog -->
|
|
|
|
</div><!-- /.modal -->
|
2016-08-27 16:29:20 +08:00
|
|
|
|
|
|
|
@endsection
|