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:
commit
39eb75c440
@ -1 +1 @@
|
||||
5.5.85
|
||||
5.5.86
|
@ -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,
|
||||
|
@ -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', ''),
|
||||
|
@ -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()
|
||||
{
|
||||
|
||||
}
|
||||
};
|
Loading…
Reference in New Issue
Block a user