mirror of
https://github.com/invoiceninja/invoiceninja.git
synced 2024-11-05 18:52:44 +01:00
Minor release
This commit is contained in:
parent
02baff1119
commit
3aa5e2e4eb
@ -38,7 +38,7 @@ class InvoiceItemFactory
|
||||
$item->custom_value2 = '';
|
||||
$item->custom_value3 = '';
|
||||
$item->custom_value4 = '';
|
||||
$item->type_id = 1;
|
||||
$item->type_id = "1";
|
||||
|
||||
return $item;
|
||||
}
|
||||
@ -69,7 +69,7 @@ class InvoiceItemFactory
|
||||
$item->custom_value4 = $faker->realText(10);
|
||||
$item->tax_name1 = 'GST';
|
||||
$item->tax_rate1 = 10.00;
|
||||
$item->type_id = 1;
|
||||
$item->type_id = "1";
|
||||
|
||||
$data[] = $item;
|
||||
}
|
||||
@ -103,7 +103,7 @@ class InvoiceItemFactory
|
||||
$item->custom_value4 = $faker->realText(10);
|
||||
$item->tax_name1 = 'GST';
|
||||
$item->tax_rate1 = 10.00;
|
||||
$item->type_id = 1;
|
||||
$item->type_id = "1";
|
||||
|
||||
$data[] = $item;
|
||||
}
|
||||
|
@ -97,12 +97,13 @@ class StoreRecurringInvoiceRequest extends Request
|
||||
|
||||
$input['line_items'] = isset($input['line_items']) ? $this->cleanItems($input['line_items']) : [];
|
||||
|
||||
if(isset($input['auto_bill']))
|
||||
$input['auto_bill_enabled'] = $this->setAutoBillFlag($input['auto_bill']);
|
||||
else{
|
||||
$client = Client::find($input['client_id']);
|
||||
$input['auto_bill'] = $client->getSetting('auto_bill');
|
||||
}
|
||||
if(isset($input['auto_bill']))
|
||||
$input['auto_bill_enabled'] = $this->setAutoBillFlag($input['auto_bill']);
|
||||
else{
|
||||
|
||||
if($client = Client::find($input['client_id']))
|
||||
$input['auto_bill'] = $client->getSetting('auto_bill');
|
||||
}
|
||||
|
||||
$this->replace($input);
|
||||
}
|
||||
|
@ -33,6 +33,8 @@ class RecurringInvoiceRepository extends BaseRepository
|
||||
|
||||
$invoice_calc = new InvoiceSum($invoice, $invoice->settings);
|
||||
|
||||
$invoice->service()->applyNumber()->save();
|
||||
|
||||
$invoice = $invoice_calc->build()->getInvoice();
|
||||
|
||||
return $invoice;
|
||||
|
@ -154,13 +154,13 @@ trait GeneratesCounter
|
||||
$is_client_counter = false;
|
||||
|
||||
//todo handle if we have specific client patterns in the future
|
||||
$pattern = $client->company->settings->invoice_number_pattern;
|
||||
$pattern = $client->company->settings->recurring_invoice_number_pattern;
|
||||
|
||||
//Determine if we are using client_counters
|
||||
if (strpos($pattern, 'client_counter') === false) {
|
||||
$counter = $client->company->settings->invoice_number_counter;
|
||||
$counter = $client->company->settings->recurring_invoice_number_counter;
|
||||
} else {
|
||||
$counter = $client->settings->invoice_number_counter;
|
||||
$counter = $client->settings->recurring_invoice_number_counter;
|
||||
$is_client_counter = true;
|
||||
}
|
||||
|
||||
@ -172,9 +172,9 @@ trait GeneratesCounter
|
||||
|
||||
//increment the correct invoice_number Counter (company vs client)
|
||||
if ($is_client_counter) {
|
||||
$this->incrementCounter($client, 'invoice_number_counter');
|
||||
$this->incrementCounter($client, 'recurring_invoice_number_counter');
|
||||
} else {
|
||||
$this->incrementCounter($client->company, 'invoice_number_counter');
|
||||
$this->incrementCounter($client->company, 'recurring_invoice_number_counter');
|
||||
}
|
||||
|
||||
return $invoice_number;
|
||||
|
64
composer.lock
generated
64
composer.lock
generated
@ -108,16 +108,16 @@
|
||||
},
|
||||
{
|
||||
"name": "aws/aws-sdk-php",
|
||||
"version": "3.158.1",
|
||||
"version": "3.158.2",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/aws/aws-sdk-php.git",
|
||||
"reference": "55ae8bdf2eb2f9774193fa79c6fc436835c42db4"
|
||||
"reference": "b80957465d94c127254e36061dd3d0c3ccc94cc1"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/55ae8bdf2eb2f9774193fa79c6fc436835c42db4",
|
||||
"reference": "55ae8bdf2eb2f9774193fa79c6fc436835c42db4",
|
||||
"url": "https://api.github.com/repos/aws/aws-sdk-php/zipball/b80957465d94c127254e36061dd3d0c3ccc94cc1",
|
||||
"reference": "b80957465d94c127254e36061dd3d0c3ccc94cc1",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -189,7 +189,7 @@
|
||||
"s3",
|
||||
"sdk"
|
||||
],
|
||||
"time": "2020-10-02T18:16:40+00:00"
|
||||
"time": "2020-10-05T18:13:27+00:00"
|
||||
},
|
||||
{
|
||||
"name": "brick/math",
|
||||
@ -1777,16 +1777,16 @@
|
||||
},
|
||||
{
|
||||
"name": "google/apiclient-services",
|
||||
"version": "v0.148",
|
||||
"version": "v0.149",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/googleapis/google-api-php-client-services.git",
|
||||
"reference": "692a8d4c6a89458570e0d804624c50120cdd6388"
|
||||
"reference": "6a44aa8dc22b181594ba93c2ffb5d731c318c810"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/googleapis/google-api-php-client-services/zipball/692a8d4c6a89458570e0d804624c50120cdd6388",
|
||||
"reference": "692a8d4c6a89458570e0d804624c50120cdd6388",
|
||||
"url": "https://api.github.com/repos/googleapis/google-api-php-client-services/zipball/6a44aa8dc22b181594ba93c2ffb5d731c318c810",
|
||||
"reference": "6a44aa8dc22b181594ba93c2ffb5d731c318c810",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -1810,7 +1810,7 @@
|
||||
"keywords": [
|
||||
"google"
|
||||
],
|
||||
"time": "2020-09-26T00:26:16+00:00"
|
||||
"time": "2020-10-05T00:26:25+00:00"
|
||||
},
|
||||
{
|
||||
"name": "google/auth",
|
||||
@ -3880,16 +3880,16 @@
|
||||
},
|
||||
{
|
||||
"name": "nesbot/carbon",
|
||||
"version": "2.40.1",
|
||||
"version": "2.41.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/briannesbitt/Carbon.git",
|
||||
"reference": "d9a76d8b7eb0f97cf3a82529393245212f40ba3b"
|
||||
"reference": "8690b13ad4da6d54d692afea15aab30b36fee52e"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/d9a76d8b7eb0f97cf3a82529393245212f40ba3b",
|
||||
"reference": "d9a76d8b7eb0f97cf3a82529393245212f40ba3b",
|
||||
"url": "https://api.github.com/repos/briannesbitt/Carbon/zipball/8690b13ad4da6d54d692afea15aab30b36fee52e",
|
||||
"reference": "8690b13ad4da6d54d692afea15aab30b36fee52e",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -3965,7 +3965,7 @@
|
||||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2020-09-23T08:17:37+00:00"
|
||||
"time": "2020-10-04T09:11:05+00:00"
|
||||
},
|
||||
{
|
||||
"name": "nikic/php-parser",
|
||||
@ -6039,16 +6039,16 @@
|
||||
},
|
||||
{
|
||||
"name": "sentry/sentry-laravel",
|
||||
"version": "2.0.1",
|
||||
"version": "2.1.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/getsentry/sentry-laravel.git",
|
||||
"reference": "3c6b1da08087f428ab1a188af35483eb76ef6b1e"
|
||||
"reference": "1815b6e7c037f9495768e906f978e1a15d7a2944"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/getsentry/sentry-laravel/zipball/3c6b1da08087f428ab1a188af35483eb76ef6b1e",
|
||||
"reference": "3c6b1da08087f428ab1a188af35483eb76ef6b1e",
|
||||
"url": "https://api.github.com/repos/getsentry/sentry-laravel/zipball/1815b6e7c037f9495768e906f978e1a15d7a2944",
|
||||
"reference": "1815b6e7c037f9495768e906f978e1a15d7a2944",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -6116,7 +6116,7 @@
|
||||
"type": "custom"
|
||||
}
|
||||
],
|
||||
"time": "2020-10-01T12:14:37+00:00"
|
||||
"time": "2020-10-06T08:40:32+00:00"
|
||||
},
|
||||
{
|
||||
"name": "spatie/browsershot",
|
||||
@ -8848,16 +8848,16 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/translation-contracts",
|
||||
"version": "v2.2.0",
|
||||
"version": "v2.3.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/translation-contracts.git",
|
||||
"reference": "77ce1c3627c9f39643acd9af086631f842c50c4d"
|
||||
"reference": "e2eaa60b558f26a4b0354e1bbb25636efaaad105"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/translation-contracts/zipball/77ce1c3627c9f39643acd9af086631f842c50c4d",
|
||||
"reference": "77ce1c3627c9f39643acd9af086631f842c50c4d",
|
||||
"url": "https://api.github.com/repos/symfony/translation-contracts/zipball/e2eaa60b558f26a4b0354e1bbb25636efaaad105",
|
||||
"reference": "e2eaa60b558f26a4b0354e1bbb25636efaaad105",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -8869,7 +8869,7 @@
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.2-dev"
|
||||
"dev-master": "2.3-dev"
|
||||
},
|
||||
"thanks": {
|
||||
"name": "symfony/contracts",
|
||||
@ -8919,7 +8919,7 @@
|
||||
"type": "tidelift"
|
||||
}
|
||||
],
|
||||
"time": "2020-09-07T11:33:47+00:00"
|
||||
"time": "2020-09-28T13:05:58+00:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/var-dumper",
|
||||
@ -11940,16 +11940,16 @@
|
||||
},
|
||||
{
|
||||
"name": "sebastian/type",
|
||||
"version": "2.2.2",
|
||||
"version": "2.3.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/sebastianbergmann/type.git",
|
||||
"reference": "e494dcaeb89d1458c9ccd8c819745245a1669aea"
|
||||
"reference": "fa592377f3923946cb90bf1f6a71ba2e5f229909"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/sebastianbergmann/type/zipball/e494dcaeb89d1458c9ccd8c819745245a1669aea",
|
||||
"reference": "e494dcaeb89d1458c9ccd8c819745245a1669aea",
|
||||
"url": "https://api.github.com/repos/sebastianbergmann/type/zipball/fa592377f3923946cb90bf1f6a71ba2e5f229909",
|
||||
"reference": "fa592377f3923946cb90bf1f6a71ba2e5f229909",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@ -11961,7 +11961,7 @@
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.2-dev"
|
||||
"dev-master": "2.3-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
@ -11988,7 +11988,7 @@
|
||||
"type": "github"
|
||||
}
|
||||
],
|
||||
"time": "2020-09-28T06:01:38+00:00"
|
||||
"time": "2020-10-06T08:41:03+00:00"
|
||||
},
|
||||
{
|
||||
"name": "sebastian/version",
|
||||
|
@ -34,7 +34,7 @@ class ProjectFactory extends Factory
|
||||
{
|
||||
return [
|
||||
'name' => $this->faker->name(),
|
||||
'description' => $this->faker->text(50),
|
||||
'public_notes' => $this->faker->text(50),
|
||||
];
|
||||
}
|
||||
}
|
||||
|
@ -31,6 +31,17 @@ class UpdateGatewayTableVisibleColumn extends Migration
|
||||
|
||||
});
|
||||
|
||||
|
||||
Schema::table('expenses', function ($t){
|
||||
$t->renameColumn('invoice_category_id', 'category_id');
|
||||
});
|
||||
|
||||
Schema::table('projects', function ($t){
|
||||
$t->text('public_notes')->nullable();
|
||||
$t->dropColumn('description');
|
||||
$t->decimal('budgeted_hours', 12,2)->change();
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user