UI
This commit is contained in:
4
ui/resources/views/layout/body/footer.blade.php
Normal file
4
ui/resources/views/layout/body/footer.blade.php
Normal file
@ -0,0 +1,4 @@
|
||||
<footer>
|
||||
</footer>
|
||||
|
||||
@include('layout.body.footer.scripts')
|
6
ui/resources/views/layout/body/footer/scripts.blade.php
Normal file
6
ui/resources/views/layout/body/footer/scripts.blade.php
Normal file
@ -0,0 +1,6 @@
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.6.1/jquery.min.js" integrity="sha512-aVKKRRi/Q/YV+4mjoKBsE4x3H+BkegoM/em46NNlCqNTmUYADjBbeNefNxYV7giUp0VxICtqdrbqU7iVaeZNXA==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/fomantic-ui/2.9.0/semantic.min.js" integrity="sha512-kcjXjSNAMuKRYv8VAk/rMsHzGC/M/thh4QRZAE3SM2HPAQs77N0aOVh35IpJAtLxFpzfHeYzFHf9upgnNFfQUQ==" crossorigin="anonymous" referrerpolicy="no-referrer"></script>
|
||||
|
||||
@include('layout.body.footer.scripts.main')
|
||||
|
||||
@stack('page_scripts')
|
38
ui/resources/views/layout/body/footer/scripts/main.blade.php
Normal file
38
ui/resources/views/layout/body/footer/scripts/main.blade.php
Normal file
@ -0,0 +1,38 @@
|
||||
<script type="text/javascript">
|
||||
const Send = {
|
||||
base_url: '{{$urls->api}}',
|
||||
base: function({method, uri, data = null, dataType = 'json', contentType = 'application/json'}) {
|
||||
const url = this.base_url + '/' + uri.replace(/^\//g, '')
|
||||
const options = {
|
||||
method,
|
||||
url,
|
||||
crossDomain: true,
|
||||
headers: {
|
||||
'Authorization': [
|
||||
'Bearer {{$api_key}}'
|
||||
]
|
||||
},
|
||||
dataType
|
||||
}
|
||||
if (method.toLowerCase() !== 'get' && data !== null) {
|
||||
if (!(typeof data === 'string' || data instanceof String)) {
|
||||
options['data'] = JSON.stringify(data)
|
||||
}
|
||||
options['contentType'] = contentType
|
||||
}
|
||||
return $.ajax(options)
|
||||
},
|
||||
get: function(uri, dataType = 'json') {
|
||||
return this.base({method: 'get', uri, dataType})
|
||||
},
|
||||
post: function({uri, data, dataType = 'json', contentType = 'application/json'}) {
|
||||
return this.base({method: 'post', uri, data, dataType, contentType})
|
||||
},
|
||||
put: function({uri, data, dataType = 'json', contentType = 'application/json'}) {
|
||||
return this.base({method: 'put', uri, data, dataType, contentType})
|
||||
},
|
||||
delete: function({uri, data, dataType = 'json', contentType = 'application/json'}) {
|
||||
return this.base({method: 'delete', uri, data, dataType, contentType})
|
||||
}
|
||||
}
|
||||
</script>
|
5
ui/resources/views/layout/body/header.blade.php
Normal file
5
ui/resources/views/layout/body/header.blade.php
Normal file
@ -0,0 +1,5 @@
|
||||
<header>
|
||||
<div class="ui container">
|
||||
@include('layout.body.header.navbar')
|
||||
</div>
|
||||
</header>
|
5
ui/resources/views/layout/body/header/navbar.blade.php
Normal file
5
ui/resources/views/layout/body/header/navbar.blade.php
Normal file
@ -0,0 +1,5 @@
|
||||
<nav class="ui menu">
|
||||
<a class="item" href="{{$urls->base}}">Inicio</a>
|
||||
<a class="item" href="{{$urls->base}}/emails/mailboxes">Register Mailboxes</a>
|
||||
</nav>
|
||||
<br />
|
Reference in New Issue
Block a user