mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-05 18:52:44 +01:00
Fixes for self updater (#3740)
* Add checks for duplicate contacts in invitations * Fixes for self updater
This commit is contained in:
parent
8129a5b49d
commit
ed5ce8634e
@ -38,6 +38,8 @@ class PostUpdate extends Command
|
||||
{
|
||||
set_time_limit(0);
|
||||
|
||||
info("running post update");
|
||||
|
||||
try {
|
||||
Artisan::call('migrate');
|
||||
} catch (Exception $e) {
|
||||
@ -85,7 +87,7 @@ class PostUpdate extends Command
|
||||
$output = $factory->createOutput();
|
||||
|
||||
$input = new \Symfony\Component\Console\Input\ArrayInput(array(
|
||||
'command' => 'update --no-dev',
|
||||
'command' => 'install',
|
||||
));
|
||||
$input->setInteractive(false);
|
||||
echo "<pre>";
|
||||
|
@ -83,6 +83,8 @@ info(print_r($release,1));
|
||||
|
||||
info(print_r($res,1));
|
||||
|
||||
Artisan::call('ninja:post-update');
|
||||
|
||||
return response()->json(['message'=>$res], 200);
|
||||
}
|
||||
}
|
||||
|
@ -49,6 +49,9 @@ class StoreInvoiceRequest extends Request
|
||||
|
||||
$rules['client_id'] = 'required|exists:clients,id,company_id,'.auth()->user()->company()->id;
|
||||
|
||||
$rules['invitations.*.client_contact_id'] = 'distinct';
|
||||
|
||||
|
||||
return $rules;
|
||||
}
|
||||
|
||||
|
@ -140,11 +140,7 @@ return [
|
||||
'post_update' => [
|
||||
'ninja:post-update' => [
|
||||
'class' => \App\Console\Commands\PostUpdate::class,
|
||||
'params' => [
|
||||
'log' => 1,
|
||||
'reset' => false,
|
||||
// etc.
|
||||
]
|
||||
'params' => []
|
||||
],
|
||||
],
|
||||
],
|
||||
|
Loading…
Reference in New Issue
Block a user