Merge pull request #1564 from rahulshukla-webkul/development

Fixed issue #1563
This commit is contained in:
Jitendra Singh 2019-10-10 13:03:59 +05:30 committed by GitHub
commit e85f07af08
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 15 additions and 4 deletions

View File

@ -4,6 +4,7 @@ namespace Webkul\Customer\Http\Controllers;
use Hash;
use Webkul\Customer\Repositories\CustomerRepository;
use Webkul\Product\Repositories\ProductReviewRepository;
/**
* Customer controlller for the customer basically for the tasks of customers which will be
@ -28,19 +29,29 @@ class CustomerController extends Controller
*/
protected $customerRepository;
/**
* ProductReviewRepository object
*
* @var array
*/
protected $productReviewRepository;
/**
* Create a new controller instance.
*
* @param \Webkul\Customer\Repositories\CustomerRepository $customer
* @param \Webkul\Product\Repositories\ProductReviewRepository $productReview
* @return void
*/
public function __construct(CustomerRepository $customerRepository)
public function __construct(CustomerRepository $customerRepository, ProductReviewRepository $productReviewRepository)
{
$this->middleware('customer');
$this->_config = request('_config');
$this->customerRepository = $customerRepository;
$this->productReviewRepository = $productReviewRepository;
}
/**
@ -147,7 +158,7 @@ class CustomerController extends Controller
*/
public function reviews()
{
$reviews = $this->productReview->getCustomerReview();
$reviews = $this->productReviewRepository->getCustomerReview();
return view($this->_config['view'], compact('reviews'));
}

View File

@ -155,7 +155,7 @@
new_shipping_address: false,
new_billing_address: false,
allAddress: {},
countryStates: @json(core()->groupedStatesByCountries()),
@ -251,7 +251,7 @@
.then(function(response) {
this_this.disable_button = false;
if (this_this.step_numbers[response.data.jump_to_section] == 2)
if (this_this.step_numbers[response.data.jump_to_section] == 2)
shippingHtml = Vue.compile(response.data.html)
else
paymentHtml = Vue.compile(response.data.html)