From 536b21595d86aa3dac45e692d013b8cb272faa24 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Sat, 27 Feb 2016 22:44:18 +0200 Subject: [PATCH 1/7] Updated build branch --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index 1addcb2fd9d1..9edb27210fc8 100644 --- a/readme.md +++ b/readme.md @@ -5,7 +5,7 @@ # Invoice Ninja ### [https://www.invoiceninja.com](https://www.invoiceninja.com) -[![Build Status](https://travis-ci.org/invoiceninja/invoiceninja.svg?branch=develop)](https://travis-ci.org/invoiceninja/invoiceninja) +[![Build Status](https://travis-ci.org/invoiceninja/invoiceninja.svg?branch=master)](https://travis-ci.org/invoiceninja/invoiceninja) [![Join the chat at https://gitter.im/hillelcoren/invoice-ninja](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/hillelcoren/invoice-ninja?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) ### Affiliates Programs From dade97fbfae32fc478764f77c31e4affdda77266 Mon Sep 17 00:00:00 2001 From: Hillel Coren Date: Mon, 29 Feb 2016 13:25:32 +0200 Subject: [PATCH 2/7] Merged minor fixes --- app/Ninja/Repositories/AccountRepository.php | 12 +++++------- app/Services/ImportService.php | 2 +- resources/views/accounts/bank_account.blade.php | 1 + resources/views/header.blade.php | 2 +- 4 files changed, 8 insertions(+), 9 deletions(-) diff --git a/app/Ninja/Repositories/AccountRepository.php b/app/Ninja/Repositories/AccountRepository.php index 2b469bf0fcf7..62c924d545da 100644 --- a/app/Ninja/Repositories/AccountRepository.php +++ b/app/Ninja/Repositories/AccountRepository.php @@ -124,25 +124,23 @@ class AccountRepository return false; } - $client = $this->getNinjaClient(Auth::user()->account); - $invitation = $this->createNinjaInvoice($client); - + $account = Auth::user()->account; + $client = $this->getNinjaClient($account); + $invitation = $this->createNinjaInvoice($client, $account); return $invitation; } - - public function createNinjaInvoice($client) + public function createNinjaInvoice($client, $clientAccount) { $account = $this->getNinjaAccount(); $lastInvoice = Invoice::withTrashed()->whereAccountId($account->id)->orderBy('public_id', 'DESC')->first(); $publicId = $lastInvoice ? ($lastInvoice->public_id + 1) : 1; - $invoice = new Invoice(); $invoice->account_id = $account->id; $invoice->user_id = $account->users()->first()->id; $invoice->public_id = $publicId; $invoice->client_id = $client->id; $invoice->invoice_number = $account->getNextInvoiceNumber($invoice); - $invoice->invoice_date = Auth::user()->account->getRenewalDate(); + $invoice->invoice_date = $clientAccount->getRenewalDate(); $invoice->amount = PRO_PLAN_PRICE; $invoice->balance = PRO_PLAN_PRICE; $invoice->save(); diff --git a/app/Services/ImportService.php b/app/Services/ImportService.php index b557e067b2bf..c17a8e359a80 100644 --- a/app/Services/ImportService.php +++ b/app/Services/ImportService.php @@ -1,4 +1,4 @@ - Date: Tue, 1 Mar 2016 18:15:43 +1100 Subject: [PATCH 3/7] Update readme.md --- readme.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/readme.md b/readme.md index 9edb27210fc8..c5d3a5ce69f1 100644 --- a/readme.md +++ b/readme.md @@ -19,7 +19,7 @@ * [Softaculous](https://www.softaculous.com/apps/ecommerce/Invoice_Ninja) - $30 ### Requirements -* PHP >= 5.4.0 +* PHP >= 5.5.9 * MCrypt PHP Extension * MySQL @@ -28,7 +28,7 @@ * [Postmark](https://postmarkapp.com/) ### Features -* Built using Laravel 5 +* Built using Laravel 5.1 * Live PDF generation using [pdfmake](http://pdfmake.org/) * Integrates with 50+ payment providers with [OmniPay](https://github.com/thephpleague/omnipay) * Recurring invoices with auto-billing @@ -96,4 +96,4 @@ We're using the [Git-Flow](http://nvie.com/posts/a-successful-git-branching-mode * [ezyang/htmlpurifier](https://github.com/ezyang/htmlpurifier) - Standards compliant HTML filter written in PHP * [cerdic/css-tidy](https://github.com/Cerdic/CSSTidy) - CSSTidy is a CSS minifier * [asgrim/ofxparser](https://github.com/asgrim/ofxparser) - OFX File Parser -* [stacktracejs/stacktrace.js](https://github.com/stacktracejs/stacktrace.js) - Framework-agnostic, micro-library for getting stack traces in all web browsers \ No newline at end of file +* [stacktracejs/stacktrace.js](https://github.com/stacktracejs/stacktrace.js) - Framework-agnostic, micro-library for getting stack traces in all web browsers From 66fca98fa13203a6d65fe3b8555423be3d2f1fff Mon Sep 17 00:00:00 2001 From: David Bomba Date: Tue, 1 Mar 2016 18:18:13 +1100 Subject: [PATCH 4/7] Update readme.md --- readme.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/readme.md b/readme.md index c5d3a5ce69f1..da8709109d65 100644 --- a/readme.md +++ b/readme.md @@ -19,7 +19,7 @@ * [Softaculous](https://www.softaculous.com/apps/ecommerce/Invoice_Ninja) - $30 ### Requirements -* PHP >= 5.5.9 +* PHP >= 5.4 * MCrypt PHP Extension * MySQL @@ -28,7 +28,7 @@ * [Postmark](https://postmarkapp.com/) ### Features -* Built using Laravel 5.1 +* Built using Laravel 5 * Live PDF generation using [pdfmake](http://pdfmake.org/) * Integrates with 50+ payment providers with [OmniPay](https://github.com/thephpleague/omnipay) * Recurring invoices with auto-billing From aa4aae4797146d86c4b99bd94dec99c4c3fb9fa7 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Tue, 1 Mar 2016 21:31:23 +1100 Subject: [PATCH 5/7] Working on API --- app/Http/Controllers/AccountApiController.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Http/Controllers/AccountApiController.php b/app/Http/Controllers/AccountApiController.php index 6d4ef0ccf1e7..5f34f267db7c 100644 --- a/app/Http/Controllers/AccountApiController.php +++ b/app/Http/Controllers/AccountApiController.php @@ -152,7 +152,7 @@ class AccountApiController extends BaseAPIController $account->devices = json_encode($devices); $account->save(); - return $this->response($account); + return $this->response($newDevice); } @@ -185,7 +185,7 @@ class AccountApiController extends BaseAPIController $account->devices = json_encode($devices); $account->save(); - return $this->response($account); + return $this->response($newDevice); } } From c1b9d6febc8e1c92418fde26d6f5c232bf3268d7 Mon Sep 17 00:00:00 2001 From: David Bomba Date: Wed, 2 Mar 2016 12:13:57 +1100 Subject: [PATCH 6/7] Bug Fix --- app/Listeners/NotificationListener.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/Listeners/NotificationListener.php b/app/Listeners/NotificationListener.php index c7b58fe30ba5..29a190eeb712 100644 --- a/app/Listeners/NotificationListener.php +++ b/app/Listeners/NotificationListener.php @@ -10,6 +10,7 @@ use App\Events\QuoteInvitationWasViewed; use App\Events\QuoteInvitationWasApproved; use App\Events\PaymentWasCreated; use App\Ninja\Notifications; +use App\Services\PushService; class NotificationListener { @@ -17,7 +18,7 @@ class NotificationListener protected $contactMailer; protected $pushService; - public function __construct(UserMailer $userMailer, ContactMailer $contactMailer, Notifications\PushService $pushService) + public function __construct(UserMailer $userMailer, ContactMailer $contactMailer, PushService $pushService) { $this->userMailer = $userMailer; $this->contactMailer = $contactMailer; From 922849409c4e13d4b4e9f624dbd074a49479c24d Mon Sep 17 00:00:00 2001 From: David Bomba Date: Wed, 2 Mar 2016 12:17:59 +1100 Subject: [PATCH 7/7] Bug Fix --- readme.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/readme.md b/readme.md index 7e2b04ec71fd..d164ce19ab68 100644 --- a/readme.md +++ b/readme.md @@ -5,7 +5,7 @@ # Invoice Ninja ### [https://www.invoiceninja.com](https://www.invoiceninja.com) -[![Build Status](https://travis-ci.org/invoiceninja/invoiceninja.svg?branch=master)](https://travis-ci.org/invoiceninja/invoiceninja) +[![Build Status](https://travis-ci.org/invoiceninja/invoiceninja.svg?branch=develop)](https://travis-ci.org/invoiceninja/invoiceninja) [![Join the chat at https://gitter.im/hillelcoren/invoice-ninja](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/hillelcoren/invoice-ninja?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge) ### Affiliates Programs