test
This commit is contained in:
@@ -464,8 +464,6 @@ class Wiaas_Cart {
|
|||||||
* @return int Number of wiaas standard packages in cart
|
* @return int Number of wiaas standard packages in cart
|
||||||
*/
|
*/
|
||||||
public static function get_cart_packages_count() {
|
public static function get_cart_packages_count() {
|
||||||
|
|
||||||
return 1;
|
|
||||||
$items = WC()->cart->get_cart_contents();
|
$items = WC()->cart->get_cart_contents();
|
||||||
|
|
||||||
return array_reduce($items, function($count, $item) {
|
return array_reduce($items, function($count, $item) {
|
||||||
|
|||||||
@@ -4,13 +4,9 @@ import {Link} from 'react-router-dom';
|
|||||||
import {Row, Col, Container, NavLink} from 'reactstrap';
|
import {Row, Col, Container, NavLink} from 'reactstrap';
|
||||||
import CartStepsContainer from './CartStepsContainer.jsx';
|
import CartStepsContainer from './CartStepsContainer.jsx';
|
||||||
import CartItemsContainer from './CartItemsContainer.jsx';
|
import CartItemsContainer from './CartItemsContainer.jsx';
|
||||||
import {fetchCartCount} from '../../actions/cart/cartActions';
|
|
||||||
import {cartTexts} from '../../constants/cartConstants';
|
import {cartTexts} from '../../constants/cartConstants';
|
||||||
|
|
||||||
class CartContainer extends Component {
|
class CartContainer extends Component {
|
||||||
componentDidMount() {
|
|
||||||
this.props.dispatch(fetchCartCount());
|
|
||||||
}
|
|
||||||
|
|
||||||
render() {
|
render() {
|
||||||
const {cartSteps, currentStep, cartCount} = this.props;
|
const {cartSteps, currentStep, cartCount} = this.props;
|
||||||
|
|||||||
Reference in New Issue
Block a user