From 960802827a21950fbc67e40d83fa969403fb73d8 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Tue, 26 Apr 2016 15:16:25 +1000 Subject: [PATCH 01/21] Document Transformer --- .../Transformers/DocumentTransformer.php | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 app/Ninja/Transformers/DocumentTransformer.php diff --git a/app/Ninja/Transformers/DocumentTransformer.php b/app/Ninja/Transformers/DocumentTransformer.php new file mode 100644 index 000000000000..61d18506eba1 --- /dev/null +++ b/app/Ninja/Transformers/DocumentTransformer.php @@ -0,0 +1,21 @@ + (int) $document->public_id, + 'name' => $document->name, + 'account_key' => $this->account->account_key, + 'type' => $document->type, + 'invoice_id' => isset($document->invoice->public_id) ? (int) $document->invoice->public_id : null, + 'expense_id' => isset($document->expense->public_id) ? (int) $document->expense->public_id : null, + ]; + } +} \ No newline at end of file From 7cac31e7a64b1179ab4c2ec2e00d223756ff8b21 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Mon, 2 May 2016 19:40:54 +1000 Subject: [PATCH 02/21] Fix for cloning invoices from API --- app/Http/Controllers/InvoiceApiController.php | 10 ++++++++++ app/Http/routes.php | 1 + 2 files changed, 11 insertions(+) diff --git a/app/Http/Controllers/InvoiceApiController.php b/app/Http/Controllers/InvoiceApiController.php index ce5eaa1d72d6..6eb6df367e71 100644 --- a/app/Http/Controllers/InvoiceApiController.php +++ b/app/Http/Controllers/InvoiceApiController.php @@ -1,6 +1,7 @@ response($data); } + else if ($request->action == ACTION_CLONE) { + $invoice = Invoice::scope($publicId)->firstOrFail(); + $clonedInvoice = $this->invoiceRepo->cloneInvoice($invoice, null); + + $transformer = new InvoiceTransformer(\Auth::user()->account, Input::get('serializer')); + $data = $this->createItem($clonedInvoice, $transformer, 'invoice'); + + return $this->response($data); + } $data = $request->input(); $data['public_id'] = $publicId; $this->invoiceService->save($data); diff --git a/app/Http/routes.php b/app/Http/routes.php index 768c9c3d3d4c..bfeed103a99a 100644 --- a/app/Http/routes.php +++ b/app/Http/routes.php @@ -380,6 +380,7 @@ if (!defined('CONTACT_EMAIL')) { define('ACTION_RESTORE', 'restore'); define('ACTION_ARCHIVE', 'archive'); + define('ACTION_CLONE', 'clone'); define('ACTION_CONVERT', 'convert'); define('ACTION_DELETE', 'delete'); From f6abdedfac247e48dd2e201a0f9bbea7ec8f0ebb Mon Sep 17 00:00:00 2001 From: David Bomba Date: Mon, 9 May 2016 09:54:40 +1000 Subject: [PATCH 03/21] User Transformer permissions --- app/Ninja/Transformers/UserAccountTransformer.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/app/Ninja/Transformers/UserAccountTransformer.php b/app/Ninja/Transformers/UserAccountTransformer.php index e914a25c663d..2351fdf22b24 100644 --- a/app/Ninja/Transformers/UserAccountTransformer.php +++ b/app/Ninja/Transformers/UserAccountTransformer.php @@ -33,6 +33,8 @@ class UserAccountTransformer extends EntityTransformer 'account_key' => $user->account->account_key, 'name' => $user->account->present()->name, 'token' => $user->account->getToken($user->id, $this->tokenName), + 'is_admin' => (bool) $user->is_admin, + 'permissions' => $user->permissions, 'default_url' => SITE_URL ]; } From 985c4eda34549655f3079bdde3f3dc8ee9a17d8b Mon Sep 17 00:00:00 2001 From: David Bomba Date: Mon, 9 May 2016 10:02:15 +1000 Subject: [PATCH 04/21] working with permissions --- app/Ninja/Transformers/UserAccountTransformer.php | 2 -- app/Ninja/Transformers/UserTransformer.php | 2 ++ 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Ninja/Transformers/UserAccountTransformer.php b/app/Ninja/Transformers/UserAccountTransformer.php index 2351fdf22b24..e914a25c663d 100644 --- a/app/Ninja/Transformers/UserAccountTransformer.php +++ b/app/Ninja/Transformers/UserAccountTransformer.php @@ -33,8 +33,6 @@ class UserAccountTransformer extends EntityTransformer 'account_key' => $user->account->account_key, 'name' => $user->account->present()->name, 'token' => $user->account->getToken($user->id, $this->tokenName), - 'is_admin' => (bool) $user->is_admin, - 'permissions' => $user->permissions, 'default_url' => SITE_URL ]; } diff --git a/app/Ninja/Transformers/UserTransformer.php b/app/Ninja/Transformers/UserTransformer.php index 532c1f6fa4f2..f6bab290b817 100644 --- a/app/Ninja/Transformers/UserTransformer.php +++ b/app/Ninja/Transformers/UserTransformer.php @@ -26,6 +26,8 @@ class UserTransformer extends EntityTransformer 'notify_viewed' => (bool) $user->notify_viewed, 'notify_paid' => (bool) $user->notify_paid, 'notify_approved' => (bool) $user->notify_approved, + 'is_admin' => (bool) $user->is_admin, + 'permissions' => $user->getPermissions, ]; } } \ No newline at end of file From 5233047ab103306f64578d1843f1cef49621d084 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Mon, 9 May 2016 10:09:51 +1000 Subject: [PATCH 05/21] working with permissions --- app/Ninja/Transformers/UserTransformer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Ninja/Transformers/UserTransformer.php b/app/Ninja/Transformers/UserTransformer.php index f6bab290b817..711d0723250e 100644 --- a/app/Ninja/Transformers/UserTransformer.php +++ b/app/Ninja/Transformers/UserTransformer.php @@ -27,7 +27,7 @@ class UserTransformer extends EntityTransformer 'notify_paid' => (bool) $user->notify_paid, 'notify_approved' => (bool) $user->notify_approved, 'is_admin' => (bool) $user->is_admin, - 'permissions' => $user->getPermissions, + 'permissions' => $user->permissions, ]; } } \ No newline at end of file From dbdd1ac15579ab8db92c17c29a1a1e265d362a10 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Mon, 9 May 2016 10:28:47 +1000 Subject: [PATCH 06/21] working with permissions --- app/Ninja/Transformers/UserTransformer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Ninja/Transformers/UserTransformer.php b/app/Ninja/Transformers/UserTransformer.php index 711d0723250e..32cd42d90476 100644 --- a/app/Ninja/Transformers/UserTransformer.php +++ b/app/Ninja/Transformers/UserTransformer.php @@ -27,7 +27,7 @@ class UserTransformer extends EntityTransformer 'notify_paid' => (bool) $user->notify_paid, 'notify_approved' => (bool) $user->notify_approved, 'is_admin' => (bool) $user->is_admin, - 'permissions' => $user->permissions, + 'permissions' => Auth()::user->permissions, ]; } } \ No newline at end of file From 050b79cc75ddfaeb71816536587a5135e1a35e2c Mon Sep 17 00:00:00 2001 From: David Bomba Date: Tue, 10 May 2016 09:26:44 +1000 Subject: [PATCH 07/21] user transformer - add fields --- app/Ninja/Transformers/UserTransformer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Ninja/Transformers/UserTransformer.php b/app/Ninja/Transformers/UserTransformer.php index 32cd42d90476..63428ed64bb6 100644 --- a/app/Ninja/Transformers/UserTransformer.php +++ b/app/Ninja/Transformers/UserTransformer.php @@ -27,7 +27,7 @@ class UserTransformer extends EntityTransformer 'notify_paid' => (bool) $user->notify_paid, 'notify_approved' => (bool) $user->notify_approved, 'is_admin' => (bool) $user->is_admin, - 'permissions' => Auth()::user->permissions, + 'permissions' => (int) $user->getOriginal('permissions'), ]; } } \ No newline at end of file From 1dc692d57859893e8879b4929974619419073900 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Tue, 10 May 2016 22:51:17 +0300 Subject: [PATCH 08/21] Updated readme --- readme.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/readme.md b/readme.md index 93b30a8003d4..e435d9e90657 100644 --- a/readme.md +++ b/readme.md @@ -31,10 +31,11 @@ ### Features * Built using Laravel 5.2 * Live PDF generation using [pdfmake](http://pdfmake.org/) -* Integrates with 50+ payment providers with [OmniPay](https://github.com/thephpleague/omnipay) +* Integrates with 50+ payment providers with [Omnipay](https://github.com/thephpleague/omnipay) * Recurring invoices with auto-billing * Expenses and vendors * Tasks with time-tracking +* File Attachments * Multi-user/multi-company support * Tax rates and payment terms * Reminder emails From 0f95799f33131e10d201c6bf02ea07aab1b861c0 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Wed, 11 May 2016 09:22:43 +0300 Subject: [PATCH 09/21] Improved 'return to app' button logic --- resources/views/invoices/view.blade.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/resources/views/invoices/view.blade.php b/resources/views/invoices/view.blade.php index 3e5310ea40a6..e0a5cba5a2e4 100644 --- a/resources/views/invoices/view.blade.php +++ b/resources/views/invoices/view.blade.php @@ -25,10 +25,7 @@ @include('partials.checkout_com_payment') @else
- @if (Session::get('trackEventAction') === '/buy_pro_plan') - {!! Button::normal(trans('texts.download_pdf'))->withAttributes(['onclick' => 'onDownloadClick()'])->large() !!}   - {!! Button::primary(trans('texts.return_to_app'))->asLinkTo(URL::to('/dashboard'))->large() !!} - @elseif ($invoice->is_quote) + @if ($invoice->is_quote) {!! Button::normal(trans('texts.download_pdf'))->withAttributes(['onclick' => 'onDownloadClick()'])->large() !!}   @if ($showApprove) {!! Button::success(trans('texts.approve'))->asLinkTo(URL::to('/approve/' . $invitation->invitation_key))->large() !!} @@ -40,8 +37,11 @@ @else {{ trans('texts.pay_now') }} @endif - @else + @else {!! Button::normal(trans('texts.download_pdf'))->withAttributes(['onclick' => 'onDownloadClick()'])->large() !!} + @if ($account->isNinjaAccount()) + {!! Button::primary(trans('texts.return_to_app'))->asLinkTo(URL::to('/dashboard'))->large() !!} + @endif @endif
From ae6d85bb494ed9c3e90ef857a5c57020b47b9d14 Mon Sep 17 00:00:00 2001 From: Bartlomiej Szala Date: Wed, 11 May 2016 20:59:40 +0200 Subject: [PATCH 10/21] Working on texts translations --- resources/lang/pl/texts.php | 262 ++++++++++++++++++------------------ 1 file changed, 131 insertions(+), 131 deletions(-) diff --git a/resources/lang/pl/texts.php b/resources/lang/pl/texts.php index 9b91d00cfdd6..5af1bdfb427b 100644 --- a/resources/lang/pl/texts.php +++ b/resources/lang/pl/texts.php @@ -291,21 +291,21 @@ $LANG = array( 'fill_products_help' => 'Selecting a product will automatically fill in the description and cost', 'update_products' => 'Auto-update products', 'update_products_help' => 'Updating an invoice will automatically update the product library', - 'create_product' => 'Add Product', - 'edit_product' => 'Edit Product', - 'archive_product' => 'Archive Product', - 'updated_product' => 'Successfully updated product', - 'created_product' => 'Successfully created product', - 'archived_product' => 'Successfully archived product', + 'create_product' => 'Dodaj produkt', + 'edit_product' => 'Edytuj produkt', + 'archive_product' => 'Zarchiwizuj produkt', + 'updated_product' => 'Produkt został zaktualizowany', + 'created_product' => 'Produkt został utworzony', + 'archived_product' => 'Produkt został zarchiwizowany', 'pro_plan_custom_fields' => ':link to enable custom fields by joining the Pro Plan', - 'advanced_settings' => 'Advanced Settings', + 'advanced_settings' => 'Ustawienia zaawansowane', 'pro_plan_advanced_settings' => ':link to enable the advanced settings by joining the Pro Plan', - 'invoice_design' => 'Invoice Design', + 'invoice_design' => 'Szablon faktury', 'specify_colors' => 'Specify colors', 'specify_colors_label' => 'Select the colors used in the invoice', 'chart_builder' => 'Chart Builder', 'ninja_email_footer' => 'Use :site to invoice your clients and get paid online for free!', - 'go_pro' => 'Go Pro', + 'go_pro' => 'Wybierz Pro', 'quote' => 'Oferta', 'quotes' => 'Oferty', 'quote_number' => 'Numer oferty', @@ -314,7 +314,7 @@ $LANG = array( 'quote_total' => 'Suma oferty', 'your_quote' => 'Twoja oferta', 'total' => 'Suma', - 'clone' => 'Clone', + 'clone' => 'Klonuj', 'new_quote' => 'Nowa oferta', 'create_quote' => 'Stwórz ofertę', 'edit_quote' => 'Edytuj ofertę', @@ -327,81 +327,81 @@ $LANG = array( 'view_invoice' => 'Zobacz fakturę', 'view_client' => 'Zobacz klienta', 'view_quote' => 'Zobacz ofertę', - 'updated_quote' => 'Successfully updated quote', - 'created_quote' => 'Successfully created quote', - 'cloned_quote' => 'Successfully cloned quote', - 'emailed_quote' => 'Successfully emailed quote', - 'archived_quote' => 'Successfully archived quote', - 'archived_quotes' => 'Successfully archived :count quotes', - 'deleted_quote' => 'Successfully deleted quote', - 'deleted_quotes' => 'Successfully deleted :count quotes', - 'converted_to_invoice' => 'Successfully converted quote to invoice', - 'quote_subject' => 'New quote $quote from :account', + 'updated_quote' => 'Oferta została zaktualizowana', + 'created_quote' => 'Oferta została utworzona', + 'cloned_quote' => 'Oferta została sklonowana', + 'emailed_quote' => 'Oferta została wysłana', + 'archived_quote' => 'Oferta została zarchiwizowana', + 'archived_quotes' => 'Zarchiwizowano :count ofert', + 'deleted_quote' => 'Oferta została usunięta', + 'deleted_quotes' => 'Usunięto :count ofert', + 'converted_to_invoice' => 'Utworzono fakturę z oferty', + 'quote_subject' => 'Nowa oferta $quote z :account', 'quote_message' => 'To view your quote for :amount, click the link below.', 'quote_link_message' => 'To view your client quote click the link below:', 'notification_quote_sent_subject' => 'Quote :invoice was sent to :client', 'notification_quote_viewed_subject' => 'Quote :invoice was viewed by :client', 'notification_quote_sent' => 'The following client :client was emailed Quote :invoice for :amount.', 'notification_quote_viewed' => 'The following client :client viewed Quote :invoice for :amount.', - 'session_expired' => 'Your session has expired.', - 'invoice_fields' => 'Invoice Fields', - 'invoice_options' => 'Invoice Options', - 'hide_quantity' => 'Hide Quantity', + 'session_expired' => 'Twoja sesja wygasła.', + 'invoice_fields' => 'Pola faktury', + 'invoice_options' => 'Opcje faktury', + 'hide_quantity' => 'Ukryj ilość', 'hide_quantity_help' => 'If your line items quantities are always 1, then you can declutter invoices by no longer displaying this field.', - 'hide_paid_to_date' => 'Hide Paid to Date', + 'hide_paid_to_date' => 'Ukryj wypłacono do tej pory', 'hide_paid_to_date_help' => 'Only display the "Paid to Date" area on your invoices once a payment has been received.', 'charge_taxes' => 'Charge taxes', - 'user_management' => 'User Management', - 'add_user' => 'Add User', - 'send_invite' => 'Send invitation', - 'sent_invite' => 'Successfully sent invitation', - 'updated_user' => 'Successfully updated user', - 'invitation_message' => 'You\'ve been invited by :invitor. ', - 'register_to_add_user' => 'Please sign up to add a user', - 'user_state' => 'State', - 'edit_user' => 'Edit User', - 'delete_user' => 'Delete User', - 'active' => 'Active', - 'pending' => 'Pending', - 'deleted_user' => 'Successfully deleted user', - 'confirm_email_invoice' => 'Are you sure you want to email this invoice?', - 'confirm_email_quote' => 'Are you sure you want to email this quote?', - 'confirm_recurring_email_invoice' => 'Are you sure you want this invoice emailed?', - 'cancel_account' => 'Usuń konto', - 'cancel_account_message' => 'Warning: This will permanently erase all of your data, there is no undo.', - 'go_back' => 'Go Back', - 'data_visualizations' => 'Data Visualizations', + 'user_management' => 'Zarządzaj użytkownikiem', + 'add_user' => 'Dodaj użytkownika', + 'send_invite' => 'Wyślij zaproszenie', + 'sent_invite' => 'Zaproszenie zostało wysłane', + 'updated_user' => 'Użytkownik został zaktualizowany', + 'invitation_message' => 'Zostałeś zaproszony przez :invitor. ', + 'register_to_add_user' => 'Zaloguj się, aby dodać użytkownika', + 'user_state' => 'Stan', + 'edit_user' => 'Edytuj użytkownika', + 'delete_user' => 'Usuń użytkownika', + 'active' => 'Aktywny', + 'pending' => 'Oczekuję', + 'deleted_user' => 'Użytkownik został usunięty', + 'confirm_email_invoice' => 'Czy na pewno chcesz wysłać tą fakturę?', + 'confirm_email_quote' => 'Czy na pewno chcesz wysłać tą ofertę?', + 'confirm_recurring_email_invoice' => 'Czy na pewno chcesz wysłać tą fakturę?', + 'cancel_account' => 'Anuluj konto', + 'cancel_account_message' => 'Ostrzeżenie: Nie można cofnąć tej operacji, wszystkie twoje dane zostaną usunięte.', + 'go_back' => 'cofnij', + 'data_visualizations' => 'Wizualizacje danych', 'sample_data' => 'Sample data shown', - 'hide' => 'Hide', + 'hide' => 'Ukryj', 'new_version_available' => 'A new version of :releases_link is available. You\'re running v:user_version, the latest is v:latest_version', - 'invoice_settings' => 'Invoice Settings', - 'invoice_number_prefix' => 'Invoice Number Prefix', - 'invoice_number_counter' => 'Invoice Number Counter', - 'quote_number_prefix' => 'Quote Number Prefix', - 'quote_number_counter' => 'Quote Number Counter', + 'invoice_settings' => 'Ustawienia faktury', + 'invoice_number_prefix' => 'Prefiks numeru faktury', + 'invoice_number_counter' => 'Licznik numeru faktury', + 'quote_number_prefix' => 'Prefiks numeru oferty', + 'quote_number_counter' => 'Licznik numeru oferty', 'share_invoice_counter' => 'Share invoice counter', - 'invoice_issued_to' => 'Invoice issued to', + 'invoice_issued_to' => 'Faktura wystawiona dla', 'invalid_counter' => 'To prevent a possible conflict please set either an invoice or quote number prefix', - 'mark_sent' => 'Mark Sent', + 'mark_sent' => 'Oznacz jako wysłane', 'gateway_help_1' => ':link to sign up for Authorize.net.', 'gateway_help_2' => ':link to sign up for Authorize.net.', 'gateway_help_17' => ':link to get your PayPal API signature.', 'gateway_help_27' => ':link to sign up for TwoCheckout.', - 'more_designs' => 'More designs', - 'more_designs_title' => 'Additional Invoice Designs', - 'more_designs_cloud_header' => 'Go Pro for more invoice designs', + 'more_designs' => 'Więcej szablonów', + 'more_designs_title' => 'Dodatkowe szablony faktur', + 'more_designs_cloud_header' => 'Więcej szablonów faktur w wersji PRO', 'more_designs_cloud_text' => '', 'more_designs_self_host_text' => '', - 'buy' => 'Buy', - 'bought_designs' => 'Successfully added additional invoice designs', - 'sent' => 'sent', - 'vat_number' => 'VAT Number', + 'buy' => 'Kup', + 'bought_designs' => 'Dodatkowe szablony faktur zostały dodane', + 'sent' => 'wysłane', + 'vat_number' => 'NIP', 'timesheets' => 'Timesheets', 'payment_title' => 'Enter Your Billing Address and Credit Card information', 'payment_cvv' => '*This is the 3-4 digit number onthe back of your card', 'payment_footer1' => '*Billing address must match address associated with credit card.', 'payment_footer2' => '*Please click "PAY NOW" only once - transaction may take up to 1 minute to process.', - 'id_number' => 'ID Number', + 'id_number' => 'Numer ID', 'white_label_link' => 'White label', 'white_label_header' => 'White Label', 'bought_white_label' => 'Successfully enabled white label license', @@ -426,7 +426,7 @@ $LANG = array( 'select_version' => 'Wybierz wersję', 'view_history' => 'Zobacz historię', 'edit_payment' => 'Edytuj płatność', - 'updated_payment' => 'Successfully updated payment', + 'updated_payment' => 'Płatność została zaktualizowana', 'deleted' => 'Usunięte', 'restore_user' => 'Przywróć użytkownika', 'restored_user' => 'Użytkownik został przywrócony', @@ -443,7 +443,7 @@ $LANG = array( 'token_billing_2' => 'Opt-in - checkbox is shown but not selected', 'token_billing_3' => 'Opt-out - checkbox is shown and selected', 'token_billing_4' => 'Zawsze', - 'token_billing_checkbox' => 'Store credit card details', + 'token_billing_checkbox' => 'Zapisz dane karty kredytowej', 'view_in_stripe' => 'View in Stripe', 'use_card_on_file' => 'Use card on file', 'edit_payment_details' => 'Edit payment details', @@ -460,15 +460,15 @@ $LANG = array( 'click_once' => '*Please click "PAY NOW" only once - transaction may take up to 1 minute to process.', 'invoice_footer' => 'Stopka faktury', 'save_as_default_footer' => 'Save as default footer', - 'token_management' => 'Token Management', - 'tokens' => 'Tokens', - 'add_token' => 'Add Token', - 'show_deleted_tokens' => 'Show deleted tokens', - 'deleted_token' => 'Successfully deleted token', - 'created_token' => 'Successfully created token', - 'updated_token' => 'Successfully updated token', - 'edit_token' => 'Edit Token', - 'delete_token' => 'Delete Token', + 'token_management' => 'Zarządanie tokenem', + 'tokens' => 'Tokeny', + 'add_token' => 'Dodaj token', + 'show_deleted_tokens' => 'Pokaż usunięte tokeny', + 'deleted_token' => 'Token został usunięty', + 'created_token' => 'Token został utworzony', + 'updated_token' => 'Token został zaktualizowany', + 'edit_token' => 'Edytuj token', + 'delete_token' => 'Usuń token', 'token' => 'Token', 'add_gateway' => 'Add Gateway', 'delete_gateway' => 'Delete Gateway', @@ -482,25 +482,25 @@ $LANG = array( 'current_password' => 'Aktualne hasło', 'new_password' => 'Nowe hasło', 'confirm_password' => 'Potwierdź hasło', - 'password_error_incorrect' => 'The current password is incorrect.', - 'password_error_invalid' => 'The new password is invalid.', - 'updated_password' => 'Successfully updated password', - 'api_tokens' => 'API Tokens', - 'users_and_tokens' => 'Users & Tokens', + 'password_error_incorrect' => 'Hasło jest nieprawidłowe.', + 'password_error_invalid' => 'Nowe hasło jest nieprawidłowe.', + 'updated_password' => 'Hasło zostało zaktualizowane', + 'api_tokens' => 'Tokeny API', + 'users_and_tokens' => 'Użytkownicy i tokeny', 'account_login' => 'Account Login', - 'recover_password' => 'Recover your password', + 'recover_password' => 'Przywróć swoje hasło', 'forgot_password' => 'Forgot your password?', - 'email_address' => 'Email address', + 'email_address' => 'Adres email', 'lets_go' => 'Let\'s go', - 'password_recovery' => 'Password Recovery', + 'password_recovery' => 'Przywracanie hasła', 'send_email' => 'Wyślij email', 'set_password' => 'Ustaw hasło', 'converted' => 'Converted', - 'email_approved' => 'Email me when a quote is approved', - 'notification_quote_approved_subject' => 'Quote :invoice was approved by :client', - 'notification_quote_approved' => 'The following client :client approved Quote :invoice for :amount.', - 'resend_confirmation' => 'Resend confirmation email', - 'confirmation_resent' => 'The confirmation email was resent', + 'email_approved' => 'Wyślij email kiedy oferta będzie zatwierdzona', + 'notification_quote_approved_subject' => 'Oferta :invoice została zatwierdzona przez :client', + 'notification_quote_approved' => 'Klient :client zatwierdził ofertę :invoice na kwotę :amount.', + 'resend_confirmation' => 'Wyślij ponownie email potwierdzający', + 'confirmation_resent' => 'Email potwierdzający został wysłany', 'gateway_help_42' => ':link to sign up for BitPay.
Note: use a Legacy API Key, not an API token.', 'payment_type_credit_card' => 'Karta kredytowa', 'payment_type_paypal' => 'PayPal', @@ -508,14 +508,14 @@ $LANG = array( 'knowledge_base' => 'Baza wiedzy', 'partial' => 'Partial', 'partial_remaining' => ':partial of :balance', - 'more_fields' => 'More Fields', - 'less_fields' => 'Less Fields', + 'more_fields' => 'Więcej pól', + 'less_fields' => 'Mniej pól', 'client_name' => 'Nazwa klienta', 'pdf_settings' => 'Ustawienia PDF', 'product_settings' => 'Ustawienia produktu', - 'auto_wrap' => 'Auto Line Wrap', + 'auto_wrap' => 'Zawijaj wiersze', 'duplicate_post' => 'Warning: the previous page was submitted twice. The second submission had been ignored.', - 'view_documentation' => 'View Documentation', + 'view_documentation' => 'Zobacz dokumentację', 'app_title' => 'Free Open-Source Online Invoicing', 'app_description' => 'Invoice Ninja is a free, open-source solution for invoicing and billing customers. With Invoice Ninja, you can easily build and send beautiful invoices from any device that has access to the web. Your clients can print your invoices, download them as pdf files, and even pay you online from within the system.', 'rows' => 'wierszy', @@ -580,8 +580,8 @@ $LANG = array( 'stopped_task' => 'Successfully stopped task', 'invoice_task' => 'Invoice Task', 'invoice_labels' => 'Invoice Labels', - 'prefix' => 'Prefix', - 'counter' => 'Counter', + 'prefix' => 'Prefiks', + 'counter' => 'Licznik', 'payment_type_dwolla' => 'Dwolla', 'gateway_help_43' => ':link to sign up for Dwolla', 'partial_value' => 'Must be greater than zero and less than the total', @@ -727,7 +727,7 @@ $LANG = array( 'default_tax_rate_id' => 'Domyśłna stawka podatkowa', 'tax_rate' => 'Stawka podatkowa', 'recurring_hour' => 'Okresowa godzina', - 'pattern' => 'Pattern', + 'pattern' => 'Wzór', 'pattern_help_title' => 'Pattern Help', 'pattern_help_1' => 'Create custom invoice and quote numbers by specifying a pattern', 'pattern_help_2' => 'Available variables:', @@ -868,42 +868,42 @@ $LANG = array( 'expenses' => 'Wydatki', 'new_expense' => 'Nowy wydatek', 'enter_expense' => 'Dodaj wydatek', - 'vendors' => 'Vendors', - 'new_vendor' => 'New Vendor', + 'vendors' => 'Sprzedawcy', + 'new_vendor' => 'Nowy sprzedawca', 'payment_terms_net' => 'Net', - 'vendor' => 'Vendor', - 'edit_vendor' => 'Edit Vendor', - 'archive_vendor' => 'Archive Vendor', - 'delete_vendor' => 'Delete Vendor', - 'view_vendor' => 'View Vendor', - 'deleted_expense' => 'Successfully deleted expense', - 'archived_expense' => 'Successfully archived expense', - 'deleted_expenses' => 'Successfully deleted expenses', - 'archived_expenses' => 'Successfully archived expenses', - 'expense_amount' => 'Expense Amount', - 'expense_balance' => 'Expense Balance', - 'expense_date' => 'Expense Date', - 'expense_should_be_invoiced' => 'Should this expense be invoiced?', - 'public_notes' => 'Public Notes', - 'invoice_amount' => 'Invoice Amount', - 'exchange_rate' => 'Exchange Rate', - 'yes' => 'Yes', - 'no' => 'No', - 'should_be_invoiced' => 'Should be invoiced', - 'view_expense' => 'View expense # :expense', - 'edit_expense' => 'Edit Expense', - 'archive_expense' => 'Archive Expense', - 'delete_expense' => 'Delete Expense', - 'view_expense_num' => 'Expense # :expense', - 'updated_expense' => 'Successfully updated expense', - 'created_expense' => 'Successfully created expense', + 'vendor' => 'Sprzedawca', + 'edit_vendor' => 'Edytuj sprzedawcę', + 'archive_vendor' => 'Archiwizuj sprzedawcę', + 'delete_vendor' => 'Usuń sprzedawcę', + 'view_vendor' => 'Zobacz sprzedawcę', + 'deleted_expense' => 'Wydatki zostały usunięte', + 'archived_expense' => 'Wydatki zostały zarchiwizowane', + 'deleted_expenses' => 'Wydatki zostały usunięte', + 'archived_expenses' => 'Wydatki zostały zarchiwizowane', + 'expense_amount' => 'Wartość wydatków', + 'expense_balance' => 'Saldo wydatków', + 'expense_date' => 'Data obciążenia', + 'expense_should_be_invoiced' => 'Utwórz fakturę dla poniesionego kosztu?', + 'public_notes' => 'Notatki publiczne', + 'invoice_amount' => 'Kwota faktury', + 'exchange_rate' => 'Kurs wymiany', + 'yes' => 'Tak', + 'no' => 'Nie', + 'should_be_invoiced' => 'Utwórz fakturę', + 'view_expense' => 'Zobacz wydatek # :expense', + 'edit_expense' => 'Edytuj wydatek', + 'archive_expense' => 'Archiwizuj wydatek', + 'delete_expense' => 'Usuń wydatek', + 'view_expense_num' => 'Wydatek # :expense', + 'updated_expense' => 'Wydatek został zaktualizowany', + 'created_expense' => 'Wydatek został utworzony', 'enter_expense' => 'Dodaj wydatek', - 'view' => 'View', + 'view' => 'Podgląd', 'restore_expense' => 'Przywróć wydatek', 'invoice_expense' => 'Faktura na wydatek', - 'expense_error_multiple_clients' => 'The expenses can\'t belong to different clients', - 'expense_error_invoiced' => 'Expense has already been invoiced', - 'convert_currency' => 'Konwersja waluty', + 'expense_error_multiple_clients' => 'Wydatek nie może należeć do innych klientów', + 'expense_error_invoiced' => 'Faktura do wydatku została już utworzona', + 'convert_currency' => 'Konwertuj walutę', 'num_days' => 'Liczba dni', 'create_payment_term' => 'Utwórz warunki płatności', 'edit_payment_terms' => 'Edytuj warunki płatności', @@ -913,7 +913,7 @@ $LANG = array( 'recurring_due_date_help' => '

Automatycznie ustawia termin faktury.

Invoices on a monthly or yearly cycle set to be due on or before the day they are created will be due the next month. Invoices set to be due on the 29th or 30th in months that don\'t have that day will be due the last day of the month.

Invoices on a weekly cycle set to be due on the day of the week they are created will be due the next week.

-

For example:

+

Na przykład:

  • Today is the 15th, due date is 1st of the month. The due date should likely be the 1st of the next month.
  • Today is the 15th, due date is the last day of the month. The due date will be the last day of the this month. @@ -927,7 +927,7 @@ $LANG = array( 'next_due_on' => 'Następna opłata: :date', 'use_client_terms' => 'Use client terms', 'day_of_month' => ':ordinal day of month', - 'last_day_of_month' => 'Last day of month', + 'last_day_of_month' => 'Ostatni dzień miesiąca', 'day_of_week_after' => ':ordinal :day after', 'sunday' => 'Niedziela', 'monday' => 'Poniedziałek', @@ -1072,11 +1072,11 @@ $LANG = array( 'gateway_help_20' => ':link to sign up for Sage Pay.', 'gateway_help_21' => ':link to sign up for Sage Pay.', 'partial_due' => 'Partial Due', - 'restore_vendor' => 'Restore Vendor', - 'restored_vendor' => 'Successfully restored vendor', - 'restored_expense' => 'Successfully restored expense', - 'permissions' => 'Permissions', - 'create_all_help' => 'Allow user to create and modify records', + 'restore_vendor' => 'Przywróć sprzedawcę', + 'restored_vendor' => 'Sprzedawca został przywrócony', + 'restored_expense' => 'Wydatek został przywrócony', + 'permissions' => 'Uprawnienia', + 'create_all_help' => 'Pozwól urzytkownikowi tworzyć i aktualizować rekordy', 'view_all_help' => 'Allow user to view records they didn\'t create', 'edit_all_help' => 'Allow user to modify records they didn\'t create', 'view_payment' => 'Zobacz wpłatę', From 8185e87d0deaff277052bc3874c01af571621d6d Mon Sep 17 00:00:00 2001 From: Bartlomiej Szala Date: Wed, 11 May 2016 22:12:00 +0200 Subject: [PATCH 11/21] Add Polish currency into a CurrenciesSeeder --- database/seeds/CurrenciesSeeder.php | 1 + 1 file changed, 1 insertion(+) diff --git a/database/seeds/CurrenciesSeeder.php b/database/seeds/CurrenciesSeeder.php index 3b44d55d8d7f..857dbe628405 100644 --- a/database/seeds/CurrenciesSeeder.php +++ b/database/seeds/CurrenciesSeeder.php @@ -58,6 +58,7 @@ class CurrenciesSeeder extends Seeder ['name' => 'Maldivian Rufiyaa', 'code' => 'MVR', 'symbol' => '', 'precision' => '2', 'thousand_separator' => ',', 'decimal_separator' => '.'], ['name' => 'Costa Rican Colón', 'code' => 'CRC', 'symbol' => '', 'precision' => '2', 'thousand_separator' => ',', 'decimal_separator' => '.'], ['name' => 'Pakistani Rupee', 'code' => 'PKR', 'symbol' => 'Rs ', 'precision' => '0', 'thousand_separator' => ',', 'decimal_separator' => '.'], + ['name' => 'Polish Zloty', 'code' => 'PLN', 'symbol' => 'zł', 'precision' => '2', 'thousand_separator' => ' ', 'decimal_separator' => ','], ]; foreach ($currencies as $currency) { From 2b23a80fda15fef9469f97f1ae1d0fbc1cabd976 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Thu, 12 May 2016 08:27:21 +1000 Subject: [PATCH 12/21] rewind --- app/Http/Controllers/InvoiceApiController.php | 11 +---------- 1 file changed, 1 insertion(+), 10 deletions(-) diff --git a/app/Http/Controllers/InvoiceApiController.php b/app/Http/Controllers/InvoiceApiController.php index 69149c6d5b1a..dca69d840862 100644 --- a/app/Http/Controllers/InvoiceApiController.php +++ b/app/Http/Controllers/InvoiceApiController.php @@ -316,16 +316,7 @@ class InvoiceApiController extends BaseAPIController } elseif ($request->action) { return $this->handleAction($request); } - else if ($request->action == ACTION_CLONE) { - - $invoice = Invoice::scope($publicId)->firstOrFail(); - $clonedInvoice = $this->invoiceRepo->cloneInvoice($invoice, null); - - $transformer = new InvoiceTransformer(\Auth::user()->account, Input::get('serializer')); - $data = $this->createItem($clonedInvoice, $transformer, 'invoice'); - - return $this->response($data); - } + $data = $request->input(); $data['public_id'] = $publicId; $this->invoiceService->save($data, $request->entity()); From 7c0e2f4420a62df9c60ceb15c047db691db03cc1 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Thu, 12 May 2016 08:28:49 +1000 Subject: [PATCH 13/21] added in additional fields for Invoice Transformer --- app/Http/Controllers/InvoiceApiController.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/app/Http/Controllers/InvoiceApiController.php b/app/Http/Controllers/InvoiceApiController.php index dca69d840862..983e8fa14d71 100644 --- a/app/Http/Controllers/InvoiceApiController.php +++ b/app/Http/Controllers/InvoiceApiController.php @@ -1,8 +1,6 @@ action) { return $this->handleAction($request); } - + $data = $request->input(); $data['public_id'] = $publicId; $this->invoiceService->save($data, $request->entity()); From 110af6f28bee4d50492343bdcbe729c2752af74d Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Thu, 12 May 2016 12:44:22 +0300 Subject: [PATCH 14/21] Fix for #859 --- app/Http/Controllers/ReportController.php | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/app/Http/Controllers/ReportController.php b/app/Http/Controllers/ReportController.php index a63b16d9fcc4..4f162f260d37 100644 --- a/app/Http/Controllers/ReportController.php +++ b/app/Http/Controllers/ReportController.php @@ -248,11 +248,13 @@ class ReportController extends BaseController ->withArchived() ->with('contacts') ->with(['invoices' => function($query) use ($startDate, $endDate, $dateField) { - $query->withArchived(); - if ($dateField == FILTER_PAYMENT_DATE) { + $query->with('invoice_items')->withArchived(); + if ($dateField == FILTER_INVOICE_DATE) { $query->where('invoice_date', '>=', $startDate) ->where('invoice_date', '<=', $endDate) - ->whereHas('payments', function($query) use ($startDate, $endDate) { + ->with('payments'); + } else { + $query->whereHas('payments', function($query) use ($startDate, $endDate) { $query->where('payment_date', '>=', $startDate) ->where('payment_date', '<=', $endDate) ->withArchived(); @@ -260,9 +262,8 @@ class ReportController extends BaseController ->with(['payments' => function($query) use ($startDate, $endDate) { $query->where('payment_date', '>=', $startDate) ->where('payment_date', '<=', $endDate) - ->withArchived() - ->with('payment_type', 'account_gateway.gateway'); - }, 'invoice_items']); + ->withArchived(); + }]); } }]); From cca4e40ef58ef33f8fe692b0cef72a72176035ef Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Thu, 12 May 2016 12:44:44 +0300 Subject: [PATCH 15/21] Fix problem with migration --- database/migrations/2016_03_22_168362_add_documents.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/database/migrations/2016_03_22_168362_add_documents.php b/database/migrations/2016_03_22_168362_add_documents.php index 3d0a44f20c25..233f420c198b 100644 --- a/database/migrations/2016_03_22_168362_add_documents.php +++ b/database/migrations/2016_03_22_168362_add_documents.php @@ -19,7 +19,7 @@ class AddDocuments extends Migration { $table->boolean('document_email_attachment')->default(1); }); - DB::table('accounts')->update(array('logo' => '')); + \DB::table('accounts')->update(array('logo' => '')); Schema::dropIfExists('documents'); Schema::create('documents', function($t) { From 3202d2480fc68f2fb41fabb168a6a97f7a7a70ff Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Thu, 12 May 2016 20:26:36 +0300 Subject: [PATCH 16/21] Fix for saving client portal setting in self host --- app/Http/Controllers/AccountController.php | 101 +++++++++++---------- 1 file changed, 51 insertions(+), 50 deletions(-) diff --git a/app/Http/Controllers/AccountController.php b/app/Http/Controllers/AccountController.php index 5ce42356bf83..97226ad29c2a 100644 --- a/app/Http/Controllers/AccountController.php +++ b/app/Http/Controllers/AccountController.php @@ -117,21 +117,21 @@ class AccountController extends BaseController if (Auth::user()->isPro() && ! Auth::user()->isTrial()) { return false; } - + $invitation = $this->accountRepo->enablePlan(); return $invitation->invitation_key; } - + public function changePlan() { $user = Auth::user(); $account = $user->account; - + $plan = Input::get('plan'); $term = Input::get('plan_term'); - + $planDetails = $account->getPlanDetails(false, false); - + $credit = 0; if ($planDetails) { if ($planDetails['plan'] == PLAN_PRO && $plan == PLAN_ENTERPRISE) { @@ -141,7 +141,7 @@ class AccountController extends BaseController $pending_monthly = true; $term = PLAN_TERM_YEARLY; } - + $new_plan = array( 'plan' => PLAN_ENTERPRISE, 'term' => $term, @@ -169,7 +169,7 @@ class AccountController extends BaseController // Downgrade $refund_deadline = clone $planDetails['started']; $refund_deadline->modify('+30 days'); - + if ($plan == PLAN_FREE && $refund_deadline >= date_create()) { // Refund $account->company->plan = null; @@ -179,7 +179,7 @@ class AccountController extends BaseController $account->company->plan_paid = null; $account->company->pending_plan = null; $account->company->pending_term = null; - + if ($account->company->payment) { $payment = $account->company->payment; $this->paymentService->refund($payment); @@ -188,9 +188,9 @@ class AccountController extends BaseController } else { Session::flash('message', trans('texts.updated_plan')); } - + $account->company->save(); - + } else { $pending_change = array( 'plan' => $plan, @@ -198,18 +198,18 @@ class AccountController extends BaseController ); } } - + if (!empty($new_plan)) { $time_used = $planDetails['paid']->diff(date_create()); $days_used = $time_used->days; - + if ($time_used->invert) { // They paid in advance $days_used *= -1; } - + $days_total = $planDetails['paid']->diff($planDetails['expires'])->days; - + $percent_used = $days_used / $days_total; $old_plan_price = Account::$plan_prices[$planDetails['plan']][$planDetails['term']]; $credit = $old_plan_price * (1 - $percent_used); @@ -220,20 +220,20 @@ class AccountController extends BaseController 'term' => $term, ); } - + if (!empty($pending_change) && empty($new_plan)) { $account->company->pending_plan = $pending_change['plan']; $account->company->pending_term = $pending_change['term']; $account->company->save(); - + Session::flash('message', trans('texts.updated_plan')); } - + if (!empty($new_plan)) { $invitation = $this->accountRepo->enablePlan($new_plan['plan'], $new_plan['term'], $credit, !empty($pending_monthly)); return Redirect::to('view/'.$invitation->invitation_key); } - + return Redirect::to('/settings/'.ACCOUNT_MANAGEMENT, 301); } @@ -492,7 +492,7 @@ class AccountController extends BaseController $client->postal_code = trans('texts.postal_code'); $client->work_phone = trans('texts.work_phone'); $client->work_email = trans('texts.work_id'); - + $invoice->invoice_number = '0000'; $invoice->invoice_date = Utils::fromSqlDate(date('Y-m-d')); $invoice->account = json_decode($account->toJson()); @@ -510,7 +510,7 @@ class AccountController extends BaseController $invoiceItem->product_key = 'Item'; $document->base64 = 'data:image/jpeg;base64,/9j/4QAYRXhpZgAASUkqAAgAAAAAAAAAAAAAAP/sABFEdWNreQABAAQAAAAy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eW3iK4+oDc4bNYnwcKiQaks/Caxh5wK7kdeZvb3LEJhAMqbKrhAqim522Qv5gPgqp9FxlL7mnZpXi3MxIMgDkG/ug65qHbsEF8zXvjwBFAU4jmwArRmKjV6XLdNd1TvoiF1X5vX/fMHBChWDvd+4paeJz4FDgzLjs70CdhHznQBjzv7Sxo8bd2NfcZmYNWs8RxQGYGe1+olGV9n7Z+0UPFyYwlYvmDNJctGQPGwnyQAWPv0haPhQ4abtsUxZfaFBalqvypK8pGizJpYO+aShBw+h2xgHf3CNeSAXzRnTRxS/szKo3P+IMAszsGE7iUiOwZy99tXZg3BCqz2L+qH0gU09RzxfaMDrstvwgKoDsPRrCLj7jcKSy6oH5pLZC0I+L/UPAvRNDQUa9oMU7aNedH3NWIKBWuO+m4lsAS60VfopKsCajNR6AT7l8D418EaQCisod0YIUK9U/PBh6loQegqKly/QfkBmNzMzM/i+jOk/9k='; - + $invoice->client = $client; $invoice->invoice_items = [$invoiceItem]; //$invoice->documents = $account->hasFeature(FEATURE_DOCUMENTS) ? [$document] : []; @@ -523,7 +523,7 @@ class AccountController extends BaseController $data['invoiceDesigns'] = InvoiceDesign::getDesigns(); $data['invoiceFonts'] = Cache::get('fonts'); $data['section'] = $section; - + $pageSizes = [ 'A0', 'A1', @@ -701,6 +701,13 @@ class AccountController extends BaseController private function saveClientPortal() { + $account = Auth::user()->account; + + $account->enable_client_portal = !!Input::get('enable_client_portal'); + $account->enable_client_portal_dashboard = !!Input::get('enable_client_portal_dashboard'); + $account->enable_portal_password = !!Input::get('enable_portal_password'); + $account->send_portal_password = !!Input::get('send_portal_password'); + // Only allowed for pro Invoice Ninja users or white labeled self-hosted users if (Auth::user()->account->hasFeature(FEATURE_CLIENT_PORTAL_CSS)) { $input_css = Input::get('client_view_css'); @@ -735,19 +742,13 @@ class AccountController extends BaseController $sanitized_css = $input_css; } - $account = Auth::user()->account; $account->client_view_css = $sanitized_css; - - $account->enable_client_portal = !!Input::get('enable_client_portal'); - $account->enable_client_portal_dashboard = !!Input::get('enable_client_portal_dashboard'); - $account->enable_portal_password = !!Input::get('enable_portal_password'); - $account->send_portal_password = !!Input::get('send_portal_password'); - - $account->save(); - - Session::flash('message', trans('texts.updated_settings')); } + $account->save(); + + Session::flash('message', trans('texts.updated_settings')); + return Redirect::to('settings/'.ACCOUNT_CLIENT_PORTAL); } @@ -1003,15 +1004,15 @@ class AccountController extends BaseController /* Logo image file */ if ($uploaded = Input::file('logo')) { $path = Input::file('logo')->getRealPath(); - + $disk = $account->getLogoDisk(); if ($account->hasLogo()) { $disk->delete($account->logo); } - + $extension = strtolower($uploaded->getClientOriginalExtension()); if(empty(Document::$types[$extension]) && !empty(Document::$extraExtensions[$extension])){ - $documentType = Document::$extraExtensions[$extension]; + $documentType = Document::$extraExtensions[$extension]; } else{ $documentType = $extension; @@ -1030,19 +1031,19 @@ class AccountController extends BaseController } else { if ($documentType != 'gif') { $account->logo = $account->account_key.'.'.$documentType; - + $imageSize = getimagesize($filePath); $account->logo_width = $imageSize[0]; $account->logo_height = $imageSize[1]; $account->logo_size = $size; - + // make sure image isn't interlaced if (extension_loaded('fileinfo')) { $image = Image::make($path); $image->interlace(false); $imageStr = (string) $image->encode($documentType); $disk->put($account->logo, $imageStr); - + $account->logo_size = strlen($imageStr); } else { $stream = fopen($filePath, 'r'); @@ -1055,12 +1056,12 @@ class AccountController extends BaseController $image->resize(200, 120, function ($constraint) { $constraint->aspectRatio(); }); - + $account->logo = $account->account_key.'.png'; $image = Image::canvas($image->width(), $image->height(), '#FFFFFF')->insert($image); $imageStr = (string) $image->encode('png'); $disk->put($account->logo, $imageStr); - + $account->logo_size = strlen($imageStr); $account->logo_width = $image->width(); $account->logo_height = $image->height(); @@ -1070,7 +1071,7 @@ class AccountController extends BaseController } } } - + $account->save(); } @@ -1140,7 +1141,7 @@ class AccountController extends BaseController $account = Auth::user()->account; if ($account->hasLogo()) { $account->getLogoDisk()->delete($account->logo); - + $account->logo = null; $account->logo_size = null; $account->logo_width = null; @@ -1245,7 +1246,7 @@ class AccountController extends BaseController $this->accountRepo->unlinkAccount($account); if ($account->company->accounts->count() == 1) { - $account->company->forceDelete(); + $account->company->forceDelete(); } $account->forceDelete(); @@ -1293,7 +1294,7 @@ class AccountController extends BaseController return Redirect::to("/settings/$section/", 301); } - + public function previewEmail(\App\Services\TemplateService $templateService) { $template = Input::get('template'); @@ -1301,29 +1302,29 @@ class AccountController extends BaseController ->invoices() ->withTrashed() ->first(); - + if ( ! $invoice) { return trans('texts.create_invoice_for_sample'); } - + $account = Auth::user()->account; - + // replace the variables with sample data $data = [ 'account' => $account, 'invoice' => $invoice, 'invitation' => $invoice->invitations->first(), 'client' => $invoice->client, - 'amount' => $invoice->amount + 'amount' => $invoice->amount ]; - - // create the email view + + // create the email view $view = 'emails.' . $account->getTemplateView(ENTITY_INVOICE) . '_html'; $data = array_merge($data, [ 'body' => $templateService->processVariables($template, $data), 'entityType' => ENTITY_INVOICE, ]); - + return Response::view($view, $data); } } From 6c4009d1efb34621ff3b1329f6ba08b41df4ba71 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Thu, 12 May 2016 20:27:24 +0300 Subject: [PATCH 17/21] Fixes for initial setup --- ...11_05_180133_confide_setup_users_table.php | 148 +++++++++--------- ...2016_01_04_175228_create_vendors_table.php | 4 +- ...2016_01_24_112646_add_bank_subaccounts.php | 8 +- ..._01_27_173015_add_header_footer_option.php | 20 ++- ...135956_add_source_currency_to_expenses.php | 8 +- ...214710_add_support_three_decimal_taxes.php | 4 +- ...3_23_215049_support_multiple_tax_rates.php | 34 ++-- 7 files changed, 121 insertions(+), 105 deletions(-) diff --git a/database/migrations/2013_11_05_180133_confide_setup_users_table.php b/database/migrations/2013_11_05_180133_confide_setup_users_table.php index 6bd69f503980..e9c10da1ad1e 100644 --- a/database/migrations/2013_11_05_180133_confide_setup_users_table.php +++ b/database/migrations/2013_11_05_180133_confide_setup_users_table.php @@ -9,37 +9,37 @@ class ConfideSetupUsersTable extends Migration { * @return void */ public function up() - { - Schema::dropIfExists('payment_terms'); - Schema::dropIfExists('themes'); - Schema::dropIfExists('credits'); + { + Schema::dropIfExists('payment_terms'); + Schema::dropIfExists('themes'); + Schema::dropIfExists('credits'); Schema::dropIfExists('activities'); Schema::dropIfExists('invitations'); Schema::dropIfExists('payments'); Schema::dropIfExists('account_gateways'); Schema::dropIfExists('invoice_items'); Schema::dropIfExists('products'); - Schema::dropIfExists('tax_rates'); + Schema::dropIfExists('tax_rates'); Schema::dropIfExists('contacts'); Schema::dropIfExists('invoices'); Schema::dropIfExists('password_reminders'); Schema::dropIfExists('clients'); Schema::dropIfExists('users'); Schema::dropIfExists('accounts'); - Schema::dropIfExists('currencies'); + Schema::dropIfExists('currencies'); Schema::dropIfExists('invoice_statuses'); Schema::dropIfExists('countries'); - Schema::dropIfExists('timezones'); - Schema::dropIfExists('frequencies'); - Schema::dropIfExists('date_formats'); - Schema::dropIfExists('datetime_formats'); + Schema::dropIfExists('timezones'); + Schema::dropIfExists('frequencies'); + Schema::dropIfExists('date_formats'); + Schema::dropIfExists('datetime_formats'); Schema::dropIfExists('sizes'); Schema::dropIfExists('industries'); Schema::dropIfExists('gateways'); Schema::dropIfExists('payment_types'); Schema::create('countries', function($table) - { + { $table->increments('id'); $table->string('capital', 255)->nullable(); $table->string('citizenship', 255)->nullable(); @@ -53,7 +53,7 @@ class ConfideSetupUsersTable extends Migration { $table->string('name', 255)->default(''); $table->string('region_code', 3)->default(''); $table->string('sub_region_code', 3)->default(''); - $table->boolean('eea')->default(0); + $table->boolean('eea')->default(0); }); Schema::create('themes', function($t) @@ -85,21 +85,21 @@ class ConfideSetupUsersTable extends Migration { Schema::create('date_formats', function($t) { $t->increments('id'); - $t->string('format'); - $t->string('picker_format'); - $t->string('label'); + $t->string('format'); + $t->string('picker_format'); + $t->string('label'); }); Schema::create('datetime_formats', function($t) { $t->increments('id'); - $t->string('format'); - $t->string('label'); + $t->string('format'); + $t->string('label'); }); Schema::create('currencies', function($t) { - $t->increments('id'); + $t->increments('id'); $t->string('name'); $t->string('symbol'); @@ -107,20 +107,20 @@ class ConfideSetupUsersTable extends Migration { $t->string('thousand_separator'); $t->string('decimal_separator'); $t->string('code'); - }); + }); Schema::create('sizes', function($t) { $t->increments('id'); $t->string('name'); - }); + }); Schema::create('industries', function($t) { $t->increments('id'); $t->string('name'); - }); - + }); + Schema::create('accounts', function($t) { $t->increments('id'); @@ -136,13 +136,13 @@ class ConfideSetupUsersTable extends Migration { $t->string('ip'); $t->string('account_key')->unique(); $t->timestamp('last_login')->nullable(); - + $t->string('address1')->nullable(); $t->string('address2')->nullable(); $t->string('city')->nullable(); $t->string('state')->nullable(); $t->string('postal_code')->nullable(); - $t->unsignedInteger('country_id')->nullable(); + $t->unsignedInteger('country_id')->nullable(); $t->text('invoice_terms')->nullable(); $t->text('email_footer')->nullable(); $t->unsignedInteger('industry_id')->nullable(); @@ -158,17 +158,17 @@ class ConfideSetupUsersTable extends Migration { $t->foreign('currency_id')->references('id')->on('currencies'); $t->foreign('industry_id')->references('id')->on('industries'); $t->foreign('size_id')->references('id')->on('sizes'); - }); - + }); + Schema::create('gateways', function($t) { $t->increments('id'); - $t->timestamps(); + $t->timestamps(); $t->string('name'); $t->string('provider'); $t->boolean('visible')->default(true); - }); + }); Schema::create('users', function($t) { @@ -206,31 +206,31 @@ class ConfideSetupUsersTable extends Migration { $t->unsignedInteger('gateway_id'); $t->timestamps(); $t->softDeletes(); - + $t->text('config'); $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); $t->foreign('gateway_id')->references('id')->on('gateways'); $t->foreign('user_id')->references('id')->on('users')->onDelete('cascade'); - + $t->unsignedInteger('public_id')->index(); $t->unique( array('account_id','public_id') ); - }); + }); Schema::create('password_reminders', function($t) { $t->string('email'); $t->timestamps(); - + $t->string('token'); - }); + }); Schema::create('clients', function($t) { $t->increments('id'); $t->unsignedInteger('user_id'); - $t->unsignedInteger('account_id')->index(); + $t->unsignedInteger('account_id')->index(); $t->unsignedInteger('currency_id')->nullable(); $t->timestamps(); $t->softDeletes(); @@ -255,14 +255,14 @@ class ConfideSetupUsersTable extends Migration { $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); $t->foreign('user_id')->references('id')->on('users')->onDelete('cascade'); - $t->foreign('country_id')->references('id')->on('countries'); - $t->foreign('industry_id')->references('id')->on('industries'); - $t->foreign('size_id')->references('id')->on('sizes'); + $t->foreign('country_id')->references('id')->on('countries'); + $t->foreign('industry_id')->references('id')->on('industries'); + $t->foreign('size_id')->references('id')->on('sizes'); $t->foreign('currency_id')->references('id')->on('currencies'); - + $t->unsignedInteger('public_id')->index(); $t->unique( array('account_id','public_id') ); - }); + }); Schema::create('contacts', function($t) { @@ -279,14 +279,14 @@ class ConfideSetupUsersTable extends Migration { $t->string('last_name')->nullable(); $t->string('email')->nullable(); $t->string('phone')->nullable(); - $t->timestamp('last_login')->nullable(); + $t->timestamp('last_login')->nullable(); - $t->foreign('client_id')->references('id')->on('clients')->onDelete('cascade'); + $t->foreign('client_id')->references('id')->on('clients')->onDelete('cascade'); $t->foreign('user_id')->references('id')->on('users')->onDelete('cascade');; $t->unsignedInteger('public_id')->nullable(); $t->unique( array('account_id','public_id') ); - }); + }); Schema::create('invoice_statuses', function($t) { @@ -325,15 +325,15 @@ class ConfideSetupUsersTable extends Migration { $t->timestamp('last_sent_date')->nullable(); $t->unsignedInteger('recurring_invoice_id')->index()->nullable(); - $t->string('tax_name'); - $t->decimal('tax_rate', 13, 2); + $t->string('tax_name1'); + $t->decimal('tax_rate1', 13, 3); $t->decimal('amount', 13, 2); $t->decimal('balance', 13, 2); - + $t->foreign('client_id')->references('id')->on('clients')->onDelete('cascade'); - $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); - $t->foreign('user_id')->references('id')->on('users')->onDelete('cascade'); + $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); + $t->foreign('user_id')->references('id')->on('users')->onDelete('cascade'); $t->foreign('invoice_status_id')->references('id')->on('invoice_statuses'); $t->foreign('recurring_invoice_id')->references('id')->on('invoices')->onDelete('cascade'); @@ -375,11 +375,11 @@ class ConfideSetupUsersTable extends Migration { $t->softDeletes(); $t->string('name'); - $t->decimal('rate', 13, 2); - - $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); + $t->decimal('rate', 13, 3); + + $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); $t->foreign('user_id')->references('id')->on('users')->onDelete('cascade');; - + $t->unsignedInteger('public_id'); $t->unique( array('account_id','public_id') ); }); @@ -396,10 +396,10 @@ class ConfideSetupUsersTable extends Migration { $t->text('notes'); $t->decimal('cost', 13, 2); $t->decimal('qty', 13, 2)->nullable(); - - $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); + + $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); $t->foreign('user_id')->references('id')->on('users')->onDelete('cascade');; - + $t->unsignedInteger('public_id'); $t->unique( array('account_id','public_id') ); }); @@ -420,8 +420,8 @@ class ConfideSetupUsersTable extends Migration { $t->decimal('cost', 13, 2); $t->decimal('qty', 13, 2)->nullable(); - $t->string('tax_name')->nullable(); - $t->decimal('tax_rate', 13, 2)->nullable(); + $t->string('tax_name1')->nullable(); + $t->decimal('tax_rate1', 13, 3)->nullable(); $t->foreign('invoice_id')->references('id')->on('invoices')->onDelete('cascade'); $t->foreign('product_id')->references('id')->on('products')->onDelete('cascade'); @@ -458,10 +458,10 @@ class ConfideSetupUsersTable extends Migration { $t->foreign('account_gateway_id')->references('id')->on('account_gateways')->onDelete('cascade'); $t->foreign('user_id')->references('id')->on('users')->onDelete('cascade');; $t->foreign('payment_type_id')->references('id')->on('payment_types'); - + $t->unsignedInteger('public_id')->index(); $t->unique( array('account_id','public_id') ); - }); + }); Schema::create('credits', function($t) { @@ -471,21 +471,21 @@ class ConfideSetupUsersTable extends Migration { $t->unsignedInteger('user_id'); $t->timestamps(); $t->softDeletes(); - + $t->boolean('is_deleted')->default(false); $t->decimal('amount', 13, 2); $t->decimal('balance', 13, 2); $t->date('credit_date')->nullable(); $t->string('credit_number')->nullable(); $t->text('private_notes'); - + $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); $t->foreign('client_id')->references('id')->on('clients')->onDelete('cascade'); $t->foreign('user_id')->references('id')->on('users')->onDelete('cascade');; - + $t->unsignedInteger('public_id')->index(); $t->unique( array('account_id','public_id') ); - }); + }); Schema::create('activities', function($t) { @@ -500,13 +500,13 @@ class ConfideSetupUsersTable extends Migration { $t->unsignedInteger('invoice_id')->nullable(); $t->unsignedInteger('credit_id')->nullable(); $t->unsignedInteger('invitation_id')->nullable(); - + $t->text('message')->nullable(); $t->text('json_backup')->nullable(); - $t->integer('activity_type_id'); + $t->integer('activity_type_id'); $t->decimal('adjustment', 13, 2)->nullable(); $t->decimal('balance', 13, 2)->nullable(); - + $t->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); $t->foreign('client_id')->references('id')->on('clients')->onDelete('cascade'); }); @@ -519,9 +519,9 @@ class ConfideSetupUsersTable extends Migration { */ public function down() { - Schema::dropIfExists('payment_terms'); - Schema::dropIfExists('themes'); - Schema::dropIfExists('credits'); + Schema::dropIfExists('payment_terms'); + Schema::dropIfExists('themes'); + Schema::dropIfExists('credits'); Schema::dropIfExists('activities'); Schema::dropIfExists('invitations'); Schema::dropIfExists('payments'); @@ -535,16 +535,16 @@ class ConfideSetupUsersTable extends Migration { Schema::dropIfExists('clients'); Schema::dropIfExists('users'); Schema::dropIfExists('accounts'); - Schema::dropIfExists('currencies'); + Schema::dropIfExists('currencies'); Schema::dropIfExists('invoice_statuses'); Schema::dropIfExists('countries'); - Schema::dropIfExists('timezones'); - Schema::dropIfExists('frequencies'); - Schema::dropIfExists('date_formats'); - Schema::dropIfExists('datetime_formats'); + Schema::dropIfExists('timezones'); + Schema::dropIfExists('frequencies'); + Schema::dropIfExists('date_formats'); + Schema::dropIfExists('datetime_formats'); Schema::dropIfExists('sizes'); Schema::dropIfExists('industries'); - Schema::dropIfExists('gateways'); + Schema::dropIfExists('gateways'); Schema::dropIfExists('payment_types'); } } diff --git a/database/migrations/2016_01_04_175228_create_vendors_table.php b/database/migrations/2016_01_04_175228_create_vendors_table.php index 1295748b0801..5e8551004c20 100644 --- a/database/migrations/2016_01_04_175228_create_vendors_table.php +++ b/database/migrations/2016_01_04_175228_create_vendors_table.php @@ -57,7 +57,7 @@ class CreateVendorsTable extends Migration $table->foreign('vendor_id')->references('id')->on('vendors')->onDelete('cascade'); $table->foreign('user_id')->references('id')->on('users')->onDelete('cascade'); $table->foreign('account_id')->references('id')->on('accounts')->onDelete('cascade'); - + $table->unsignedInteger('public_id')->nullable(); $table->unique(array('account_id', 'public_id')); }); @@ -79,7 +79,7 @@ class CreateVendorsTable extends Migration $table->date('expense_date')->nullable(); $table->text('private_notes'); $table->text('public_notes'); - $table->unsignedInteger('currency_id')->nullable(); + $table->unsignedInteger('invoice_currency_id')->nullable(false); $table->boolean('should_be_invoiced')->default(true); // Relations diff --git a/database/migrations/2016_01_24_112646_add_bank_subaccounts.php b/database/migrations/2016_01_24_112646_add_bank_subaccounts.php index 92b283a52662..5c01fdd5de8b 100644 --- a/database/migrations/2016_01_24_112646_add_bank_subaccounts.php +++ b/database/migrations/2016_01_24_112646_add_bank_subaccounts.php @@ -35,13 +35,13 @@ class AddBankSubaccounts extends Migration { Schema::table('expenses', function($table) { - $table->string('transaction_id'); - $table->unsignedInteger('bank_id'); + $table->string('transaction_id')->nullable(); + $table->unsignedInteger('bank_id')->nullable(); }); Schema::table('vendors', function($table) { - $table->string('transaction_name'); + $table->string('transaction_name')->nullable(); }); } @@ -53,7 +53,7 @@ class AddBankSubaccounts extends Migration { public function down() { Schema::drop('bank_subaccounts'); - + Schema::table('expenses', function($table) { $table->dropColumn('transaction_id'); diff --git a/database/migrations/2016_01_27_173015_add_header_footer_option.php b/database/migrations/2016_01_27_173015_add_header_footer_option.php index 0cb690a17383..d840b31e8f13 100644 --- a/database/migrations/2016_01_27_173015_add_header_footer_option.php +++ b/database/migrations/2016_01_27_173015_add_header_footer_option.php @@ -25,20 +25,24 @@ class AddHeaderFooterOption extends Migration { $table->boolean('is_offsite'); $table->boolean('is_secure'); }); - + Schema::table('expenses', function($table) { - $table->string('transaction_id')->nullable()->change(); - $table->unsignedInteger('bank_id')->nullable()->change(); - }); + if (Schema::hasColumn('expenses', 'transaction_id')) { + $table->string('transaction_id')->nullable()->change(); + $table->unsignedInteger('bank_id')->nullable()->change(); + } + }); Schema::table('vendors', function($table) { - $table->string('transaction_name')->nullable()->change(); - }); - + if (Schema::hasColumn('vendors', 'transaction_name')) { + $table->string('transaction_name')->nullable()->change(); + } + }); + } - + /** * Reverse the migrations. * diff --git a/database/migrations/2016_02_01_135956_add_source_currency_to_expenses.php b/database/migrations/2016_02_01_135956_add_source_currency_to_expenses.php index 4fcfa367d6be..a4b1fa62436b 100644 --- a/database/migrations/2016_02_01_135956_add_source_currency_to_expenses.php +++ b/database/migrations/2016_02_01_135956_add_source_currency_to_expenses.php @@ -16,10 +16,12 @@ class AddSourceCurrencyToExpenses extends Migration $table->dropColumn('foreign_amount'); - $table->unsignedInteger('currency_id')->nullable(false)->change(); - $table->renameColumn('currency_id', 'invoice_currency_id'); - $table->unsignedInteger('expense_currency_id'); + if (Schema::hasColumn('expenses', 'currency_id')) { + $table->unsignedInteger('currency_id')->nullable(false)->change(); + $table->renameColumn('currency_id', 'invoice_currency_id'); + } + $table->unsignedInteger('expense_currency_id'); }); Schema::table('expenses', function (Blueprint $table) { diff --git a/database/migrations/2016_03_14_214710_add_support_three_decimal_taxes.php b/database/migrations/2016_03_14_214710_add_support_three_decimal_taxes.php index af35fc927564..339a29b521b7 100644 --- a/database/migrations/2016_03_14_214710_add_support_three_decimal_taxes.php +++ b/database/migrations/2016_03_14_214710_add_support_three_decimal_taxes.php @@ -11,7 +11,9 @@ class AddSupportThreeDecimalTaxes extends Migration { public function up() { Schema::table('tax_rates', function($table) { - $table->decimal('rate', 13, 3)->change(); + if (Schema::hasColumn('tax_rates', 'rate')) { + $table->decimal('rate', 13, 3)->change(); + } }); } /** diff --git a/database/migrations/2016_03_23_215049_support_multiple_tax_rates.php b/database/migrations/2016_03_23_215049_support_multiple_tax_rates.php index 4c2d8a29b931..cda2aef7b428 100644 --- a/database/migrations/2016_03_23_215049_support_multiple_tax_rates.php +++ b/database/migrations/2016_03_23_215049_support_multiple_tax_rates.php @@ -13,30 +13,38 @@ class SupportMultipleTaxRates extends Migration public function up() { Schema::table('invoices', function($table) { - $table->decimal('tax_rate', 13, 3)->change(); - }); + if (Schema::hasColumn('invoices', 'tax_rate')) { + $table->decimal('tax_rate', 13, 3)->change(); + } + }); Schema::table('invoice_items', function($table) { - $table->decimal('tax_rate', 13, 3)->change(); - }); - + if (Schema::hasColumn('invoice_items', 'tax_rate')) { + $table->decimal('tax_rate', 13, 3)->change(); + } + }); + Schema::table('invoices', function($table) { + if (Schema::hasColumn('invoices', 'tax_rate')) { $table->renameColumn('tax_rate', 'tax_rate1'); $table->renameColumn('tax_name', 'tax_name1'); - $table->string('tax_name2')->nullable(); - $table->decimal('tax_rate2', 13, 3); + } + $table->string('tax_name2')->nullable(); + $table->decimal('tax_rate2', 13, 3); }); Schema::table('invoice_items', function($table) { + if (Schema::hasColumn('invoice_items', 'tax_rate')) { $table->renameColumn('tax_rate', 'tax_rate1'); $table->renameColumn('tax_name', 'tax_name1'); - $table->string('tax_name2')->nullable(); - $table->decimal('tax_rate2', 13, 3); + } + $table->string('tax_name2')->nullable(); + $table->decimal('tax_rate2', 13, 3); }); - Schema::table('accounts', function($table) { - $table->boolean('enable_client_portal_dashboard')->default(true); - }); + Schema::table('accounts', function($table) { + $table->boolean('enable_client_portal_dashboard')->default(true); + }); } /** * Reverse the migrations. @@ -65,4 +73,4 @@ class SupportMultipleTaxRates extends Migration $table->dropColumn('enable_client_portal_dashboard'); }); } -} \ No newline at end of file +} From 0ce8a0d70aa580fa4ed12726b765ac082cec0d8c Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Thu, 12 May 2016 20:31:31 +0300 Subject: [PATCH 18/21] Set initial key value to enable setup page to load w/o error --- config/app.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/config/app.php b/config/app.php index 4a75f65f9e5f..d9aa4ef00030 100644 --- a/config/app.php +++ b/config/app.php @@ -82,7 +82,7 @@ return [ | */ - 'key' => env('APP_KEY', ''), + 'key' => env('APP_KEY', 'SomeRandomString'), 'cipher' => env('APP_CIPHER', MCRYPT_RIJNDAEL_128), @@ -139,7 +139,7 @@ return [ 'Illuminate\Validation\ValidationServiceProvider', 'Illuminate\View\ViewServiceProvider', 'Illuminate\Broadcasting\BroadcastServiceProvider', - + /* * Additional Providers */ From 751b084a5922b7fba167fee7b11dde824bf7f7ee Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Thu, 12 May 2016 22:35:33 +0300 Subject: [PATCH 19/21] Fix javasript typo --- resources/views/payments/paymentmethods_list.blade.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/resources/views/payments/paymentmethods_list.blade.php b/resources/views/payments/paymentmethods_list.blade.php index 0dc04a988e58..776cc942869c 100644 --- a/resources/views/payments/paymentmethods_list.blade.php +++ b/resources/views/payments/paymentmethods_list.blade.php @@ -63,7 +63,7 @@ {{ $paymentMethod->bank_data }} @endif @if($paymentMethod->status == PAYMENT_METHOD_STATUS_NEW) - ({{trans('texts.complete_verification')}}) + ({{trans('texts.complete_verification')}}) @elseif($paymentMethod->status == PAYMENT_METHOD_STATUS_VERIFICATION_FAILED) ({{trans('texts.verification_failed')}}) @endif @@ -77,7 +77,7 @@ @elseif($paymentMethod->payment_type_id != PAYMENT_TYPE_ACH || $paymentMethod->status == PAYMENT_METHOD_STATUS_VERIFIED) ({{trans('texts.use_for_auto_bill')}}) @endif - × + ×
@endforeach @endif @@ -184,4 +184,4 @@ $('#default_id').val(sourceId); $('#defaultSourceForm').submit() } - \ No newline at end of file + From 02b08402156c784977ad86692ddf0695fcb7c30d Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Fri, 13 May 2016 10:38:42 +0300 Subject: [PATCH 20/21] Fix for online payment test --- tests/acceptance/OnlinePaymentCest.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/acceptance/OnlinePaymentCest.php b/tests/acceptance/OnlinePaymentCest.php index 7e85f2cc6b5a..4621fecb7bb8 100644 --- a/tests/acceptance/OnlinePaymentCest.php +++ b/tests/acceptance/OnlinePaymentCest.php @@ -77,7 +77,7 @@ class OnlinePaymentCest $I->fillField(['name' => 'postal_code'], $this->faker->postcode); $I->selectDropdown($I, 'United States', '.country-select .dropdown-toggle'); */ - + $I->fillField('#card_number', '4242424242424242'); $I->fillField('#cvv', '1234'); $I->selectOption('#expiration_month', 12); @@ -94,10 +94,10 @@ class OnlinePaymentCest $I->selectDropdown($I, $clientEmail, '.client_select .dropdown-toggle'); $I->fillField('table.invoice-table tbody tr:nth-child(1) #product_key', $productKey); $I->click('table.invoice-table tbody tr:nth-child(1) .tt-selectable'); - $I->checkOption('#auto_bill'); + $I->selectOption('#auto_bill', 3); $I->executeJS('preparePdfData(\'email\')'); $I->wait(3); $I->see("$0.00"); } -} \ No newline at end of file +} From 5eaa90fd05bea94a64389982347c6070ec0baf2e Mon Sep 17 00:00:00 2001 From: Bartlomiej Szala Date: Sun, 15 May 2016 21:49:58 +0200 Subject: [PATCH 21/21] Add new translations into texts file --- resources/lang/pl/texts.php | 292 ++++++++++++++++++------------------ 1 file changed, 146 insertions(+), 146 deletions(-) diff --git a/resources/lang/pl/texts.php b/resources/lang/pl/texts.php index 5af1bdfb427b..176e8520466c 100644 --- a/resources/lang/pl/texts.php +++ b/resources/lang/pl/texts.php @@ -43,7 +43,7 @@ $LANG = array( 'subtotal' => 'Suma częściowa', 'paid_to_date' => 'Wypłacono do tej pory', 'balance_due' => 'Balance Due', - 'invoice_design_id' => 'Szablon', + 'invoice_design_id' => 'Motyw', 'terms' => 'Warunki', 'your_invoice' => 'Twoja faktura', 'remove_contact' => 'Usuń kontakt', @@ -185,69 +185,69 @@ $LANG = array( 'clients_will_create' => 'klienci będą utworzeni', 'email_settings' => 'Ustawienia e-mail', 'client_view_styling' => 'Client View Styling', - 'pdf_email_attachment' => 'Attach PDFs', + 'pdf_email_attachment' => 'Dodaj PDF', 'custom_css' => 'Custom CSS', - 'import_clients' => 'Import Client Data', - 'csv_file' => 'CSV file', - 'export_clients' => 'Export Client Data', - 'created_client' => 'Successfully created client', + 'import_clients' => 'Importuj dane klienta', + 'csv_file' => 'Plik CSV', + 'export_clients' => 'Eksportuj dane klienta', + 'created_client' => 'Klient został utworzony', 'created_clients' => 'Successfully created :count client(s)', - 'updated_settings' => 'Successfully updated settings', - 'removed_logo' => 'Successfully removed logo', - 'sent_message' => 'Successfully sent message', - 'invoice_error' => 'Please make sure to select a client and correct any errors', + 'updated_settings' => 'Ustawienia zostały zaktualizowane', + 'removed_logo' => 'Logo zostało usunięte', + 'sent_message' => 'Wiadomość została wysłana', + 'invoice_error' => 'Pamiętaj aby wybrać klienta i poprawidź błędy', 'limit_clients' => 'Sorry, this will exceed the limit of :count clients', 'payment_error' => 'There was an error processing your payment. Please try again later.', 'registration_required' => 'Please sign up to email an invoice', - 'confirmation_required' => 'Please confirm your email address', - 'updated_client' => 'Successfully updated client', - 'created_client' => 'Successfully created client', - 'archived_client' => 'Successfully archived client', - 'archived_clients' => 'Successfully archived :count clients', - 'deleted_client' => 'Successfully deleted client', - 'deleted_clients' => 'Successfully deleted :count clients', - 'updated_invoice' => 'Successfully updated invoice', - 'created_invoice' => 'Successfully created invoice', - 'cloned_invoice' => 'Successfully cloned invoice', - 'emailed_invoice' => 'Successfully emailed invoice', - 'and_created_client' => 'and created client', - 'archived_invoice' => 'Successfully archived invoice', - 'archived_invoices' => 'Successfully archived :count invoices', - 'deleted_invoice' => 'Successfully deleted invoice', - 'deleted_invoices' => 'Successfully deleted :count invoices', - 'created_payment' => 'Successfully created payment', - 'created_payments' => 'Successfully created :count payment(s)', - 'archived_payment' => 'Successfully archived payment', - 'archived_payments' => 'Successfully archived :count payments', - 'deleted_payment' => 'Successfully deleted payment', - 'deleted_payments' => 'Successfully deleted :count payments', - 'applied_payment' => 'Successfully applied payment', - 'created_credit' => 'Successfully created credit', - 'archived_credit' => 'Successfully archived credit', - 'archived_credits' => 'Successfully archived :count credits', - 'deleted_credit' => 'Successfully deleted credit', - 'deleted_credits' => 'Successfully deleted :count credits', - 'imported_file' => 'Successfully imported file', - 'updated_vendor' => 'Successfully updated vendor', - 'created_vendor' => 'Successfully created vendor', - 'archived_vendor' => 'Successfully archived vendor', - 'archived_vendors' => 'Successfully archived :count vendors', - 'deleted_vendor' => 'Successfully deleted vendor', - 'deleted_vendors' => 'Successfully deleted :count vendors', - 'confirmation_subject' => 'Invoice Ninja Account Confirmation', - 'confirmation_header' => 'Account Confirmation', + 'confirmation_required' => 'Proszę potwierdzić adres email', + 'updated_client' => 'Klient został zaktualizowany', + 'created_client' => 'Klient został uwtorzony', + 'archived_client' => 'Klient został zarchiwizowany', + 'archived_clients' => 'Zarchiwizowano :count klientów', + 'deleted_client' => 'Klient został usunięty', + 'deleted_clients' => 'Usunięto :count klientów', + 'updated_invoice' => 'Faktura została zaktualizowana', + 'created_invoice' => 'Faktura została utworzona', + 'cloned_invoice' => 'Faktura została sklonowana', + 'emailed_invoice' => 'Faktura została wysłana', + 'and_created_client' => 'i utworzono klienta', + 'archived_invoice' => 'Faktura została zarchiwizowana', + 'archived_invoices' => 'Zarchiwizowano :count faktury', + 'deleted_invoice' => 'Faktura została usunięta', + 'deleted_invoices' => 'Usunięto :count faktury', + 'created_payment' => 'Płatność została utworzona', + 'created_payments' => 'Utworzono :count płatność/płatności', + 'archived_payment' => 'Płatność zostałą zarchiwizowana', + 'archived_payments' => 'Zarchiwizowano :count płatności', + 'deleted_payment' => 'Płatność została usunięta', + 'deleted_payments' => 'Usunięto :count płatności', + 'applied_payment' => 'Zastosowano płatność', + 'created_credit' => 'Kredyt został utworzony', + 'archived_credit' => 'Kredyt zarchiwizowano', + 'archived_credits' => 'Zarchiwizowano :count kredyty', + 'deleted_credit' => 'Kredyt został usunięty', + 'deleted_credits' => 'Usunięto :count kredyty', + 'imported_file' => 'Plik został zaimportowany', + 'updated_vendor' => 'Zaktualizowano sprzedawcę', + 'created_vendor' => 'Sprzedawca został utworzony', + 'archived_vendor' => 'Sprzedawca został zarchiwizowany', + 'archived_vendors' => 'Zarchiwizowano :count sprzedawców', + 'deleted_vendor' => 'Sprzedawca usunięty', + 'deleted_vendors' => 'Usunięto :count sprzedawców', + 'confirmation_subject' => 'Potwierdzenie konta Invoice Ninja', + 'confirmation_header' => 'Potwierdzenie konta', 'confirmation_message' => 'Please access the link below to confirm your account.', - 'invoice_subject' => 'New invoice :invoice from :account', - 'invoice_message' => 'To view your invoice for :amount, click the link below.', - 'payment_subject' => 'Payment Received', + 'invoice_subject' => 'Nowa faktura :invoice z :account', + 'invoice_message' => 'Aby wyświetlić fakturę za :amount, kliknij link poniżej.', + 'payment_subject' => 'Otrzymano płatność', 'payment_message' => 'Thank you for your payment of :amount.', 'email_salutation' => 'Drogi :name,', 'email_signature' => 'Pozdrowienia,', 'email_from' => 'Zespół The Invoice Ninja', - 'invoice_link_message' => 'To view the invoice click the link below:', - 'notification_invoice_paid_subject' => 'Invoice :invoice was paid by :client', - 'notification_invoice_sent_subject' => 'Invoice :invoice was sent to :client', - 'notification_invoice_viewed_subject' => 'Invoice :invoice was viewed by :client', + 'invoice_link_message' => 'Aby wyświetlić fakturę kliknij link poniżej:', + 'notification_invoice_paid_subject' => 'Faktura :invoice zapłacona przez :client', + 'notification_invoice_sent_subject' => 'Faktura :invoice wysłana do :client', + 'notification_invoice_viewed_subject' => 'Faktura :invoice wyświetlona przez :client', 'notification_invoice_paid' => 'A payment of :amount was made by client :client towards Invoice :invoice.', 'notification_invoice_sent' => 'The following client :client was emailed Invoice :invoice for :amount.', 'notification_invoice_viewed' => 'The following client :client viewed Invoice :invoice for :amount.', @@ -260,14 +260,14 @@ $LANG = array( 'logout' => 'Wyloguj się', 'sign_up_to_save' => 'Sign up to save your work', 'agree_to_terms' => 'I agree to the Invoice Ninja :terms', - 'terms_of_service' => 'Terms of Service', - 'email_taken' => 'The email address is already registered', - 'working' => 'Working', - 'success' => 'Success', + 'terms_of_service' => 'Warunki korzystania z Serwisu', + 'email_taken' => 'Podany adres email już istnieje', + 'working' => 'Pracuję', + 'success' => 'Sukces', 'success_message' => 'You have successfully registered! Please visit the link in the account confirmation email to verify your email address.', 'erase_data' => 'This will permanently erase your data.', 'password' => 'Hasło', - 'pro_plan_product' => 'Pro Plan', + 'pro_plan_product' => 'Plan Pro', 'pro_plan_success' => 'Thanks for choosing Invoice Ninja\'s Pro plan!

 
Next Steps

A payable invoice has been sent to the email address associated with your account. To unlock all of the awesome @@ -282,14 +282,14 @@ $LANG = array( 'field_label' => 'Field Label', 'field_value' => 'Field Value', 'edit' => 'Edytuj', - 'set_name' => 'Set your company name', - 'view_as_recipient' => 'View as recipient', - 'product_library' => 'Product Library', + 'set_name' => 'Ustaw nazwę firmy', + 'view_as_recipient' => 'Wyświetl jako odbiorca', + 'product_library' => 'Biblioteka produktów', 'product' => 'Produkt', 'products' => 'Produkty', - 'fill_products' => 'Auto-fill products', + 'fill_products' => 'Automatycznie uzupełniaj produkty', 'fill_products_help' => 'Selecting a product will automatically fill in the description and cost', - 'update_products' => 'Auto-update products', + 'update_products' => 'Automatycznie aktualizuj produkty', 'update_products_help' => 'Updating an invoice will automatically update the product library', 'create_product' => 'Dodaj produkt', 'edit_product' => 'Edytuj produkt', @@ -300,9 +300,9 @@ $LANG = array( 'pro_plan_custom_fields' => ':link to enable custom fields by joining the Pro Plan', 'advanced_settings' => 'Ustawienia zaawansowane', 'pro_plan_advanced_settings' => ':link to enable the advanced settings by joining the Pro Plan', - 'invoice_design' => 'Szablon faktury', - 'specify_colors' => 'Specify colors', - 'specify_colors_label' => 'Select the colors used in the invoice', + 'invoice_design' => 'Motyw faktury', + 'specify_colors' => 'Wybierz kolory', + 'specify_colors_label' => 'Dopasuj kolory użyte w fakturze', 'chart_builder' => 'Chart Builder', 'ninja_email_footer' => 'Use :site to invoice your clients and get paid online for free!', 'go_pro' => 'Wybierz Pro', @@ -371,7 +371,7 @@ $LANG = array( 'cancel_account_message' => 'Ostrzeżenie: Nie można cofnąć tej operacji, wszystkie twoje dane zostaną usunięte.', 'go_back' => 'cofnij', 'data_visualizations' => 'Wizualizacje danych', - 'sample_data' => 'Sample data shown', + 'sample_data' => 'Użyto przykładowych danych', 'hide' => 'Ukryj', 'new_version_available' => 'A new version of :releases_link is available. You\'re running v:user_version, the latest is v:latest_version', 'invoice_settings' => 'Ustawienia faktury', @@ -387,21 +387,21 @@ $LANG = array( 'gateway_help_2' => ':link to sign up for Authorize.net.', 'gateway_help_17' => ':link to get your PayPal API signature.', 'gateway_help_27' => ':link to sign up for TwoCheckout.', - 'more_designs' => 'Więcej szablonów', - 'more_designs_title' => 'Dodatkowe szablony faktur', - 'more_designs_cloud_header' => 'Więcej szablonów faktur w wersji PRO', + 'more_designs' => 'Więcej motywów', + 'more_designs_title' => 'Dodatkowe motywy faktur', + 'more_designs_cloud_header' => 'Więcej motywów faktur w wersji PRO', 'more_designs_cloud_text' => '', 'more_designs_self_host_text' => '', 'buy' => 'Kup', - 'bought_designs' => 'Dodatkowe szablony faktur zostały dodane', + 'bought_designs' => 'Dodatkowe motywy faktur zostały dodane', 'sent' => 'wysłane', 'vat_number' => 'NIP', - 'timesheets' => 'Timesheets', + 'timesheets' => 'Ewidencja czasu', 'payment_title' => 'Enter Your Billing Address and Credit Card information', 'payment_cvv' => '*This is the 3-4 digit number onthe back of your card', 'payment_footer1' => '*Billing address must match address associated with credit card.', 'payment_footer2' => '*Please click "PAY NOW" only once - transaction may take up to 1 minute to process.', - 'id_number' => 'Numer ID', + 'id_number' => 'Regon', 'white_label_link' => 'White label', 'white_label_header' => 'White Label', 'bought_white_label' => 'Successfully enabled white label license', @@ -455,11 +455,11 @@ $LANG = array( 'amount_due' => 'Amount due', 'billing_address' => 'Adres billingowy (rozliczeniowy)', 'billing_method' => 'Billing Method', - 'order_overview' => 'Order overview', + 'order_overview' => 'Podgląd zamówienia', 'match_address' => '*Address must match address associated with credit card.', 'click_once' => '*Please click "PAY NOW" only once - transaction may take up to 1 minute to process.', 'invoice_footer' => 'Stopka faktury', - 'save_as_default_footer' => 'Save as default footer', + 'save_as_default_footer' => 'Zapisz jako domyślna stopka', 'token_management' => 'Zarządanie tokenem', 'tokens' => 'Tokeny', 'add_token' => 'Dodaj token', @@ -489,13 +489,13 @@ $LANG = array( 'users_and_tokens' => 'Użytkownicy i tokeny', 'account_login' => 'Account Login', 'recover_password' => 'Przywróć swoje hasło', - 'forgot_password' => 'Forgot your password?', + 'forgot_password' => 'Zapomniałeś hasło?', 'email_address' => 'Adres email', - 'lets_go' => 'Let\'s go', + 'lets_go' => 'Zaczynamy', 'password_recovery' => 'Przywracanie hasła', 'send_email' => 'Wyślij email', 'set_password' => 'Ustaw hasło', - 'converted' => 'Converted', + 'converted' => 'Skonwertowano', 'email_approved' => 'Wyślij email kiedy oferta będzie zatwierdzona', 'notification_quote_approved_subject' => 'Oferta :invoice została zatwierdzona przez :client', 'notification_quote_approved' => 'Klient :client zatwierdził ofertę :invoice na kwotę :amount.', @@ -521,7 +521,7 @@ $LANG = array( 'rows' => 'wierszy', 'www' => 'www', 'logo' => 'Logo', - 'subdomain' => 'Subdomain', + 'subdomain' => 'subdomeny', 'provide_name_or_email' => 'Proszę podać imię i nazwisko lub adres e-mail', 'charts_and_reports' => 'Raporty i wykresy', 'chart' => 'Wykres', @@ -596,10 +596,10 @@ $LANG = array( 'pro_plan_feature6' => 'Create Quotes & Pro-forma Invoices', 'pro_plan_feature7' => 'Customize Invoice Field Titles & Numbering', 'pro_plan_feature8' => 'Option to Attach PDFs to Client Emails', - 'resume' => 'Resume', - 'break_duration' => 'Break', - 'edit_details' => 'Edit Details', - 'work' => 'Work', + 'resume' => 'wznów', + 'break_duration' => 'zatrzymaj', + 'edit_details' => 'Edytuj szczegóły', + 'work' => 'Praca', 'timezone_unset' => 'Please :link to set your timezone', 'click_here' => 'click here', 'email_receipt' => 'Wyślij potwierdzenie zapłaty do klienta', @@ -620,31 +620,31 @@ $LANG = array( 'show_address_help' => 'Require client to provide their billing address', 'update_address' => 'Update Address', 'update_address_help' => 'Update client\'s address with provided details', - 'times' => 'krotnie', + 'times' => 'okres', 'set_now' => 'Ustaw na teraz', 'dark_mode' => 'Tryb ciemny', 'dark_mode_help' => 'Show white text on black background', - 'add_to_invoice' => 'Add to invoice :invoice', - 'create_new_invoice' => 'Create new invoice', + 'add_to_invoice' => 'Dodaj do faktury :invoice', + 'create_new_invoice' => 'Utwórz nową fakturę', 'task_errors' => 'Please correct any overlapping times', - 'from' => 'From', - 'to' => 'To', - 'font_size' => 'Font Size', - 'primary_color' => 'Primary Color', - 'secondary_color' => 'Secondary Color', - 'customize_design' => 'Customize Design', - 'content' => 'Content', - 'styles' => 'Styles', - 'defaults' => 'Defaults', - 'margins' => 'Margins', - 'header' => 'Header', - 'footer' => 'Footer', + 'from' => 'Od', + 'to' => 'Do', + 'font_size' => 'Rozmiar czcionki', + 'primary_color' => 'Główny kolor', + 'secondary_color' => 'Wtórny kolor', + 'customize_design' => 'Dostosuj motyw', + 'content' => 'Zawartość', + 'styles' => 'Style', + 'defaults' => 'Domyślne', + 'margins' => 'Marginesy', + 'header' => 'Nagłówek', + 'footer' => 'Stopka', 'custom' => 'Custom', 'invoice_to' => 'Invoice to', 'invoice_no' => 'Invoice No.', 'recent_payments' => 'Ostatnie płatności', 'outstanding' => 'Zaległe', - 'manage_companies' => 'Manage Companies', + 'manage_companies' => 'Zarządzaj kampaniami', 'total_revenue' => 'Całkowity dochód', 'current_user' => 'Aktualny użytkownik', 'new_recurring_invoice' => 'Nowa faktura okresowa', @@ -657,8 +657,8 @@ $LANG = array(

To access a child property using dot notation. For example to show the client name you could use $client.name.

If you need help figuring something out post a question to our support forum.

', 'invoice_due_date' => 'Termin', - 'quote_due_date' => 'Valid Until', - 'valid_until' => 'Valid Until', + 'quote_due_date' => 'Ważny do', + 'valid_until' => 'Ważny do', 'reset_terms' => 'Resetuj warunki', 'reset_footer' => 'Resetuj stópkę', 'invoices_sent' => ':count faktura wysłana|:count faktury wysłane', @@ -668,7 +668,7 @@ $LANG = array( 'status_partial' => 'Częściowo', 'status_paid' => 'Zapłacone', 'show_line_item_tax' => 'Wyświetl podatki pozycji w tej samej linii', - 'iframe_url' => 'Website', + 'iframe_url' => 'Strona internetowa', 'iframe_url_help1' => 'Copy the following code to a page on your site.', 'iframe_url_help2' => 'You can test the feature by clicking \'View as recipient\' for an invoice.', 'auto_bill' => 'Automatyczny Rachunek', @@ -710,10 +710,10 @@ $LANG = array( 'basic_settings' => 'Ustawienia podstawowe', 'pro' => 'Pro', 'gateways' => 'Payment Gateways', - 'next_send_on' => 'Send Next: :date', + 'next_send_on' => 'Wyślij ponownie: :date', 'no_longer_running' => 'This invoice is not scheduled to run', - 'general_settings' => 'General Settings', - 'customize' => 'Customize', + 'general_settings' => 'Ustawienia ogólne', + 'customize' => 'Dostosuj', 'oneclick_login_help' => 'Connect an account to login without a password', 'referral_code_help' => 'Earn money by sharing our app online', 'enable_with_stripe' => 'Aktywuj | Wymaga Stripe', @@ -721,21 +721,21 @@ $LANG = array( 'create_tax_rate' => 'Dodaj stawkę podatkową', 'updated_tax_rate' => 'Successfully updated tax rate', 'created_tax_rate' => 'Successfully created tax rate', - 'edit_tax_rate' => 'Edit tax rate', - 'archive_tax_rate' => 'Archive Tax Rate', - 'archived_tax_rate' => 'Successfully archived the tax rate', + 'edit_tax_rate' => 'Edytuj stawkę podatkową', + 'archive_tax_rate' => 'Archiwizuj stawkę podatkową', + 'archived_tax_rate' => 'Zarchiwizowano stawkę podatkową', 'default_tax_rate_id' => 'Domyśłna stawka podatkowa', 'tax_rate' => 'Stawka podatkowa', 'recurring_hour' => 'Okresowa godzina', 'pattern' => 'Wzór', - 'pattern_help_title' => 'Pattern Help', + 'pattern_help_title' => 'Wzór pomoc', 'pattern_help_1' => 'Create custom invoice and quote numbers by specifying a pattern', - 'pattern_help_2' => 'Available variables:', - 'pattern_help_3' => 'For example, :example would be converted to :value', - 'see_options' => 'See options', - 'invoice_counter' => 'Invoice Counter', - 'quote_counter' => 'Quote Counter', - 'type' => 'Type', + 'pattern_help_2' => 'Dostępne zmienne:', + 'pattern_help_3' => 'Na przykład, :example będzie skonwertowane do :value', + 'see_options' => 'Zobacz opcje', + 'invoice_counter' => 'Licznik faktur', + 'quote_counter' => 'Licznik ofert', + 'type' => 'Typ', 'activity_1' => ':user created client :client', 'activity_2' => ':user archived client :client', 'activity_3' => ':user deleted client :client', @@ -782,14 +782,14 @@ $LANG = array( 'default_invoice_terms' => 'Domyślne warunki faktury', 'default_invoice_footer' => 'Domyślna stopka faktury', 'quote_footer' => 'Quote Footer', - 'free' => 'Free', + 'free' => 'Darmowe', 'quote_is_approved' => 'This quote is approved', - 'apply_credit' => 'Apply Credit', - 'system_settings' => 'System Settings', - 'archive_token' => 'Archive Token', - 'archived_token' => 'Successfully archived token', - 'archive_user' => 'Archive User', - 'archived_user' => 'Successfully archived user', + 'apply_credit' => 'Zastosuj kredyt', + 'system_settings' => 'Ustawienia systemowe', + 'archive_token' => 'Archiwizuj token', + 'archived_token' => 'Token został zarchiwizowany', + 'archive_user' => 'Archiwizuj użytkownika', + 'archived_user' => 'Użytkownik został zarchiwizowany', 'archive_account_gateway' => 'Archive Gateway', 'archived_account_gateway' => 'Successfully archived gateway', 'archive_recurring_invoice' => 'Archiwizuj okresową fakturę', @@ -807,39 +807,39 @@ $LANG = array( 'export_data' => 'Exportuj dane', 'user' => 'Użytkownik', 'country' => 'Kraj', - 'include' => 'Include', + 'include' => 'Dołącz', 'logo_too_large' => 'Your logo is :size, for better PDF performance we suggest uploading an image file less than 200KB', 'import_freshbooks' => 'Import From FreshBooks', - 'import_data' => 'Import Data', + 'import_data' => 'Importuj dane', 'source' => 'Źródło', 'csv' => 'CSV', 'client_file' => 'Plik klienta', 'invoice_file' => 'Plik faktury', 'task_file' => 'Plik zadania', 'no_mapper' => 'No valid mapping for file', - 'invalid_csv_header' => 'Invalid CSV Header', + 'invalid_csv_header' => 'Nieprawidłowy nagłówek CSV', 'client_portal' => 'Portal klienta', 'admin' => 'Administrator', 'disabled' => 'Wyłączony', 'show_archived_users' => 'Pokaż zarchiwizowanych użytkowników', 'notes' => 'Notatki', - 'invoice_will_create' => 'client will be created', - 'invoices_will_create' => 'invoices will be created', + 'invoice_will_create' => 'klient zostanie utworzony', + 'invoices_will_create' => 'faktury zostaną utworzone', 'failed_to_import' => 'The following records failed to import, they either already exist or are missing required fields.', 'publishable_key' => 'Publishable Key', 'secret_key' => 'Sekretny klucz', 'missing_publishable_key' => 'Set your Stripe publishable key for an improved checkout process', - 'email_design' => 'Email Design', + 'email_design' => 'Motyw email', 'due_by' => 'Płatny do :date', - 'enable_email_markup' => 'Enable Markup', + 'enable_email_markup' => 'Aktywuj Markup', 'enable_email_markup_help' => 'Make it easier for your clients to pay you by adding schema.org markup to your emails.', - 'template_help_title' => 'Templates Help', - 'template_help_1' => 'Available variables:', - 'email_design_id' => 'Email Style', + 'template_help_title' => 'Szablony Pomoc', + 'template_help_1' => 'Dostępne zmienne:', + 'email_design_id' => 'Motyw email', 'email_design_help' => 'Make your emails look more professional with HTML layouts', - 'plain' => 'Plain', - 'light' => 'Light', - 'dark' => 'Dark', + 'plain' => 'Zwykły', + 'light' => 'Jasny', + 'dark' => 'Ciemny', 'industry_help' => 'Used to provide comparisons against the averages of companies of similar size and industry.', 'subdomain_help' => 'Customize the invoice link subdomain or display the invoice on your own website.', 'invoice_number_help' => 'Specify a prefix or use a custom pattern to dynamically set the invoice number.', @@ -849,19 +849,19 @@ $LANG = array( 'custom_invoice_fields_helps' => 'Add a field when creating an invoice and display the label and value on the PDF.', 'custom_invoice_charges_helps' => 'Add a field when creating an invoice and include the charge in the invoice subtotals.', 'token_expired' => 'Validation token was expired. Please try again.', - 'invoice_link' => 'Invoice Link', + 'invoice_link' => 'Link faktury', 'button_confirmation_message' => 'Click to confirm your email address.', - 'confirm' => 'Confirm', - 'email_preferences' => 'Email Preferences', + 'confirm' => 'Potwierdź', + 'email_preferences' => 'Preferencje email', 'created_invoices' => 'Successfully created :count invoice(s)', - 'next_invoice_number' => 'The next invoice number is :number.', - 'next_quote_number' => 'The next quote number is :number.', - 'days_before' => 'days before', - 'days_after' => 'days after', + 'next_invoice_number' => 'Następny numer faktury jest :number.', + 'next_quote_number' => 'Następny numer oferty jest :number.', + 'days_before' => 'dni przed', + 'days_after' => 'dni po', 'field_due_date' => 'termin', - 'field_invoice_date' => 'invoice date', - 'schedule' => 'Schedule', - 'email_designs' => 'Email Designs', + 'field_invoice_date' => 'data faktury', + 'schedule' => 'Zaplanuj', + 'email_designs' => 'Motyw email', 'assigned_when_sent' => 'Assigned when sent', 'white_label_purchase_link' => 'Purchase a white label license', 'expense' => 'Wydatek',