mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-10 13:12:50 +01:00
Add expose headers
This commit is contained in:
parent
8e7ae83739
commit
1dd73e3a06
@ -291,7 +291,7 @@ class BaseController extends Controller
|
||||
* Thresholds for displaying large account on first load
|
||||
*/
|
||||
if (request()->has('first_load') && request()->input('first_load') == 'true') {
|
||||
if (auth()->user()->getCompany()->invoices->count() > 1000 || auth()->user()->getCompany()->products->count() > 1000) {
|
||||
if (auth()->user()->getCompany()->invoices->count() > 1000 || auth()->user()->getCompany()->products->count() > 1000 || auth()->user()->getCompany()->clients->count() > 1000) {
|
||||
$data = $mini_load;
|
||||
} else {
|
||||
$data = $first_load;
|
||||
|
@ -37,6 +37,7 @@ class Cors
|
||||
$response->headers->set('Access-Control-Allow-Origin', '*');
|
||||
$response->headers->set('Access-Control-Allow-Methods', 'GET, POST, PUT, DELETE, OPTIONS');
|
||||
$response->headers->set('Access-Control-Allow-Headers', 'X-API-SECRET,X-API-TOKEN,X-API-PASSWORD,DNT,User-Agent,X-Requested-With,If-Modified-Since,Cache-Control,Content-Type,Range');
|
||||
$response->headers->set('Access-Control-Expose-Headers', 'X-APP-VERSION');
|
||||
$response->headers->set('X-APP-VERSION', config('ninja.app_version'));
|
||||
$response->headers->set('X-API-VERSION', config('ninja.api_version'));
|
||||
|
||||
|
@ -16,7 +16,7 @@
|
||||
}
|
||||
</script>
|
||||
|
||||
<script src="main.dart.js" type="application/javascript"></script>
|
||||
<script src="main.dart.js?version={{ config('ninja.api_version') }}" type="application/javascript"></script>
|
||||
|
||||
<center style="font-family:Tahoma,Geneva,sans-serif;font-size:28px;color:white;padding-top:100px">
|
||||
Loading...
|
||||
|
Loading…
Reference in New Issue
Block a user