1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-09-20 16:31:33 +02:00

Fixes for Readme (#3721)

* Skip preview tests

* Fixes for product test

* Fixes for tests

* Update README.md

* Update README.md

* Update README.md

* Update README.md

* Fixes for incorrect payment types

* Refactor class nameS

* Entity Notification refactor

* Entity Notifications

* Add oauth_provider to User transformer

* Invoices can only be deleted in the balance in zero
This commit is contained in:
David Bomba 2020-05-19 22:54:22 +10:00 committed by GitHub
parent 6541e2f4aa
commit ac0d63b0b2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 10 additions and 1 deletions

View File

@ -311,6 +311,12 @@ class BaseController extends Controller
public function flutterRoute()
{
// // Ensure all request are over HTTPS in production
// if (! request()->secure()) {
// return redirect()->secure(request()->path());
// }
if ((bool)$this->checkAppSetup() !== false) {
$data = [];

View File

@ -45,6 +45,8 @@ class StartupCheck
Session::flash('message', 'Cache cleared');
}
/* Make sure our cache is built */
$cached_tables = config('ninja.cached_tables');

View File

@ -64,6 +64,7 @@ class UserTransformer extends EntityTransformer
'custom_value2' => $user->custom_value2 ?: '',
'custom_value3' => $user->custom_value3 ?: '',
'custom_value4' => $user->custom_value4 ?: '',
'oauth_provider_id' => (string)$user->oauth_provider_id,
];
}

View File

@ -17,7 +17,7 @@ trait ActionsInvoice
{
public function invoiceDeletable($invoice) :bool
{
if ($invoice->status_id <= Invoice::STATUS_SENT && $invoice->is_deleted == false && $invoice->deleted_at == null) {
if ($invoice->status_id <= Invoice::STATUS_SENT && $invoice->is_deleted == false && $invoice->deleted_at == null && $invoice->balance == 0) {
return true;
}