2017-09-26 02:43:01 +00:00
|
|
|
{{-- Pterodactyl - Panel --}}
|
2017-01-24 22:57:08 +00:00
|
|
|
{{-- Copyright (c) 2015 - 2017 Dane Everitt <dane@daneeveritt.com> --}}
|
2017-01-19 21:58:57 +00:00
|
|
|
|
2017-09-26 02:43:01 +00:00
|
|
|
{{-- This software is licensed under the terms of the MIT license. --}}
|
|
|
|
{{-- https://opensource.org/licenses/MIT --}}
|
2017-01-19 21:58:57 +00:00
|
|
|
@extends('layouts.master')
|
|
|
|
|
|
|
|
@section('title')
|
|
|
|
@lang('server.files.edit.header')
|
|
|
|
@endsection
|
|
|
|
|
|
|
|
@section('content-header')
|
|
|
|
<h1>@lang('server.files.edit.header')<small>@lang('server.files.edit.header_sub')</small></h1>
|
|
|
|
<ol class="breadcrumb">
|
|
|
|
<li><a href="{{ route('index') }}">@lang('strings.home')</a></li>
|
|
|
|
<li><a href="{{ route('server.index', $server->uuidShort) }}">{{ $server->name }}</a></li>
|
|
|
|
<li><a href="{{ route('server.files.index', $server->uuidShort) }}">@lang('navigation.server.file_browser')</a></li>
|
|
|
|
<li class="active">@lang('navigation.server.edit_file')</li>
|
|
|
|
</ol>
|
|
|
|
@endsection
|
|
|
|
|
|
|
|
@section('content')
|
|
|
|
<div class="row">
|
|
|
|
<div class="col-xs-12">
|
|
|
|
<div class="box">
|
|
|
|
<div class="box-header with-border">
|
|
|
|
<h3 class="box-title">{{ $file }}</h3>
|
|
|
|
<div class="pull-right box-tools">
|
2017-09-21 23:05:10 +00:00
|
|
|
<a href="/server/{{ $server->uuidShort }}/files#{{ rawurlencode($directory) }}" class="pull-right"><button class="btn btn-default btn-sm">@lang('server.files.edit.return')</button></a>
|
2017-01-19 21:58:57 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
<input type="hidden" name="file" value="{{ $file }}" />
|
2017-04-18 01:22:36 +00:00
|
|
|
<textarea id="editorSetContent" class="hidden">{{ $contents }}</textarea>
|
|
|
|
<div class="overlay" id="editorLoadingOverlay"><i class="fa fa-refresh fa-spin"></i></div>
|
|
|
|
<div class="box-body" style="height:500px;" id="editor"></div>
|
2017-01-19 21:58:57 +00:00
|
|
|
<div class="box-footer with-border">
|
|
|
|
<button class="btn btn-sm btn-primary" id="save_file"><i class="fa fa-fw fa-save"></i> @lang('server.files.edit.save')</button>
|
2017-09-21 23:05:10 +00:00
|
|
|
<a href="/server/{{ $server->uuidShort }}/files#{{ rawurlencode($directory) }}" class="pull-right"><button class="btn btn-default btn-sm">@lang('server.files.edit.return')</button></a>
|
2017-01-19 21:58:57 +00:00
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
</div>
|
|
|
|
@endsection
|
|
|
|
|
|
|
|
@section('footer-scripts')
|
|
|
|
@parent
|
|
|
|
{!! Theme::js('js/frontend/server.socket.js') !!}
|
2017-03-18 23:03:25 +00:00
|
|
|
{!! Theme::js('vendor/ace/ace.js') !!}
|
|
|
|
{!! Theme::js('vendor/ace/ext-modelist.js') !!}
|
2017-04-15 21:14:20 +00:00
|
|
|
{!! Theme::js('vendor/ace/ext-whitespace.js') !!}
|
2017-01-19 21:58:57 +00:00
|
|
|
{!! Theme::js('js/frontend/files/editor.js') !!}
|
2017-04-18 01:22:36 +00:00
|
|
|
<script>
|
|
|
|
$(document).ready(function () {
|
|
|
|
Editor.setValue($('#editorSetContent').val(), -1);
|
2018-06-01 05:43:18 +00:00
|
|
|
Editor.getSession().setUndoManager(new ace.UndoManager());
|
2017-04-18 01:22:36 +00:00
|
|
|
$('#editorLoadingOverlay').hide();
|
|
|
|
});
|
|
|
|
</script>
|
2017-01-19 21:58:57 +00:00
|
|
|
@endsection
|