1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-08 20:22:42 +01:00

Merge pull request #4349 from turbo124/master

Improve docs for v4 / v5
This commit is contained in:
David Bomba 2020-11-23 22:09:30 +11:00 committed by GitHub
commit 86993ba456
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
8 changed files with 18 additions and 10 deletions

2
.gitignore vendored
View File

@ -11,6 +11,8 @@
/resources/assets/bower
/storage/*.key
/storage/documents
/storage/import
/storage/migrations
/bootstrap/compiled.php
/bootstrap/environment.php
/vendor

View File

@ -68,7 +68,7 @@ class ExportMigrations extends Command
$fileName = "{$accountKey}-{$date}-invoiceninja";
$data = [
$data['data'] = [
'company' => $this->getCompany(),
'users' => $this->getUsers(),
'tax_rates' => $this->getTaxRates(),

View File

@ -43,8 +43,10 @@ class CompleteService
$files = [];
foreach ($this->data as $companyKey => $companyData) {
$data[] = [
'company_key' => $companyKey,
'company_index' => $companyKey,
'company_key' => $companyData['data']['company']['company_key'],
'force' => $companyData['force'],
];

View File

@ -773,7 +773,7 @@ trait GenerateMigrationResources
'date' => Carbon::parse($item->created_at)->toDateString(),
'custom_value1' => $item->custom_value1,
'custom_value2' => $item->custom_value2,
'type_id' => $item->invoice_item_type_id,
'type_id' => (string)$item->invoice_item_type_id,
];
}
@ -879,7 +879,7 @@ trait GenerateMigrationResources
'invitation_id' => $payment->invitation_id,
'company_gateway_id' => $payment->account_gateway_id,
'type_id' => $payment->payment_type_id,
'status_id' => $payment->payment_status_id,
'status_id' => $this->transformPaymentStatus($payment),
'amount' => $payment->amount ?: 0,
'applied' => $payment->amount ?: 0,
'refunded' => $payment->refunded ?: 0,
@ -899,6 +899,14 @@ trait GenerateMigrationResources
return $transformed;
}
private function transformPaymentStatus($payment)
{
if($payment->is_deleted && $payment->payment_status_id == 4)
return 2;
return $payment->payment_status_id;
}
private function getCredits()
{
$credits = Credit::where('account_id', $this->account->id)->where('balance', '>', 0)->whereIsDeleted(false)

View File

@ -1,4 +1,4 @@
Invoice Ninja User Guide
Invoice Ninja V4.x User Guide. For Version 5.x documentation, please go to <a href="https://invoiceninja.github.io">invoiceninja.github.io</a>
========================
Want to find out everything there is to know about how to use your Invoice Ninja account? Look no further than our User Guide, where youll learn all about creating and sending invoices, receiving payments, creating tasks, converting quotes to invoices, recurring invoices, entering credits and much, much more.

View File

@ -3536,7 +3536,7 @@ $LANG = array(
'marked_credit_as_sent' => 'Successfully marked credit as sent',
'email_subject_payment_partial' => 'Email Partial Payment Subject',
'is_approved' => 'Is Approved',
'migration_went_wrong' => 'Oops, something went wrong! Make sure you did proper setup with V2 of Invoice Ninja, before starting migration.',
'migration_went_wrong' => 'Error: Make sure you did proper setup with V5 of Invoice Ninja, before starting migration.',
'cross_migration_message' => 'Cross account migration is not allowed. Make sure e-mail address is same on V4 and V5.',
'email_credit' => 'Email Credit',
'client_email_not_set' => 'Client does not have an email address set',

2
storage/import/.gitignore vendored Executable file → Normal file
View File

@ -1,2 +0,0 @@
*
!.gitignore

View File

@ -1,2 +0,0 @@
*
!.gitignore