1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-12 14:12:44 +01:00

Merge pull request #8348 from turbo124/v5-develop

Add missing migration
This commit is contained in:
David Bomba 2023-03-10 08:38:41 +11:00 committed by GitHub
commit 39eb75c440
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 48 additions and 3 deletions

View File

@ -1 +1 @@
5.5.85
5.5.86

View File

@ -114,6 +114,7 @@ class ClientTransformer extends EntityTransformer
'balance' => (float) $client->balance,
'group_settings_id' => isset($client->group_settings_id) ? (string) $this->encodePrimaryKey($client->group_settings_id) : '',
'paid_to_date' => (float) $client->paid_to_date,
'payment_balance' => (float) $client->payment_balance,
'credit_balance' => (float) $client->credit_balance,
'last_login' => (int) $client->last_login,
'size_id' => (string) $client->size_id,

View File

@ -14,8 +14,8 @@ return [
'require_https' => env('REQUIRE_HTTPS', true),
'app_url' => rtrim(env('APP_URL', ''), '/'),
'app_domain' => env('APP_DOMAIN', 'invoicing.co'),
'app_version' => '5.5.85',
'app_tag' => '5.5.85',
'app_version' => '5.5.86',
'app_tag' => '5.5.86',
'minimum_client_version' => '5.0.16',
'terms_version' => '1.0.1',
'api_secret' => env('API_SECRET', ''),

View File

@ -0,0 +1,44 @@
<?php
use App\Models\Company;
use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
return new class extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::table('clients', function (Blueprint $table) {
$table->decimal('payment_balance', 20, 6)->default(0);
});
Company::query()
->cursor()
->each(function (Company $company) {
$settings = $company->settings;
if(!property_exists($settings, 'show_task_item_description'))
$company->saveSettings((array)$company->settings, $company);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
}
};