Updated server create blade view

Updated server create blade view for NPM webpack usage
This commit is contained in:
cp6 2022-11-13 15:54:43 +11:00
parent 26356b3cd7
commit 908b8df495

View File

@ -1,8 +1,4 @@
@section("title", "Add a server") @section("title", "Add a server")
@section('scripts')
<script src="{{ asset('js/vue.min.js') }}"></script>
<script src="{{ asset('js/axios.min.js') }}"></script>
@endsection
<x-app-layout> <x-app-layout>
<x-slot name="header"> <x-slot name="header">
{{ __('Insert a new server') }} {{ __('Insert a new server') }}
@ -224,7 +220,8 @@
</x-labels-select> </x-labels-select>
</div> </div>
</div> </div>
<x-form-check text="Allow this data to be public, restrict values in settings" name="show_public"></x-form-check> <x-form-check text="Allow this data to be public, restrict values in settings"
name="show_public"></x-form-check>
<div class="row"> <div class="row">
<div class="col-12 col-lg-4"> <div class="col-12 col-lg-4">
<x-submit-button>Insert server</x-submit-button> <x-submit-button>Insert server</x-submit-button>
@ -233,8 +230,10 @@
</form> </form>
</x-card> </x-card>
</div> </div>
@section('scripts')
<script> <script>
window.addEventListener('load', function () {
axios.defaults.headers.common = { axios.defaults.headers.common = {
'Content-Type': 'application/json', 'Content-Type': 'application/json',
'X-Requested-With': 'XMLHttpRequest', 'X-Requested-With': 'XMLHttpRequest',
@ -263,5 +262,7 @@
} }
} }
}); });
})
</script> </script>
@endsection
</x-app-layout> </x-app-layout>