Complete base implementation of services for administrative server creation

This commit is contained in:
Dane Everitt 2017-07-24 21:34:10 -05:00
parent f842aae3d3
commit 8daec38622
No known key found for this signature in database
GPG key ID: EEA66103B3D71F53
22 changed files with 633 additions and 141 deletions

View file

@ -31,6 +31,9 @@ return [
'default_allocation_not_found' => 'The requested default allocation was not found in this server\'s allocations.',
],
'alerts' => [
'startup_changed' => 'The startup configuration for this server has been updated. If this server\'s service or option was changed a reinstall will be occuring now.',
'server_deleted' => 'Server has successfully been deleted from the system.',
'server_created' => 'Server was successfully created on the panel. Please allow the daemon a few minutes to completely install this server.',
'build_updated' => 'The build details for this server have been updated. Some changes may require a restart to take effect.',
'suspension_toggled' => 'Server suspension status has been changed to :status.',
'rebuild_on_boot' => 'This server has been marked as requiring a Docker Container rebuild. This will happen the next time the server is started.',

View file

@ -49,7 +49,7 @@
</div>
<div class="form-group">
<label for="pUserId">Server Owner</label>
<select class="form-control" style="padding-left:0;" name="user_id" id="pUserId"></select>
<select class="form-control" style="padding-left:0;" name="owner_id" id="pUserId"></select>
</div>
</div>
<div class="col-md-6">

View file

@ -160,7 +160,6 @@
$('#pServiceId').on('change', function (event) {
$('#pOptionId').html('').select2({
data: $.map(_.get(Pterodactyl.services, $(this).val() + '.options', []), function (item) {
console.log(item);
return {
id: item.id,
text: item.name,
@ -182,7 +181,7 @@
}
$('#pPackId').html('').select2({
data: [{ id: 0, text: 'No Service Pack' }].concat(
data: [{ id: '', text: 'No Service Pack' }].concat(
$.map(_.get(objectChain, 'packs', []), function (item, i) {
return {
id: item.id,
@ -190,7 +189,11 @@
};
})
),
}).val('{{ is_null($server->pack_id) ? 0 : $server->pack_id }}');
});
@if(! is_null($server->pack_id))
$('#pPackId').val({{ $server->pack_id }});
@endif
$('#appendVariablesTo').html('');
$.each(_.get(objectChain, 'variables', []), function (i, item) {