Cart view incorrect

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #216875

-- url of the page with the problem -- : www.elbertbos.nl
-- HikaShop version -- : 2.6.0
-- Joomla version -- : 3.4.4
-- PHP version -- : 5.4.41-1
-- Browser(s) name and version -- : all

Hi,
As you can see in the screenshot the cart displays incorrect.
This is out of the box, I didn't write any CSS.
Any idea how to get it correct?

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 26158
  • Thank you received: 4028
  • MODERATOR
9 years 1 month ago #216883

Hi,

See : www.hikashop.com/support/support/documen...ize-the-display.html

Your template is the source of that black display.

table thead,
.table-hover tbody tr:hover > td, .table-hover tbody tr:hover > th {
  background-color: #333;
}

Regards,


Jerome - Obsidev.com
HikaMarket & HikaSerial developer / HikaShop core dev team.

Also helping the HikaShop support team when having some time or couldn't sleep.
By the way, do not send me private message, use the "contact us" form instead.

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #216934

Hi,
I apologize for not making clear what I meant. That is: why is the table row containing "image", " name" etc. shorter than the
other rows of the table?

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13376
  • MODERATOR
9 years 1 month ago #216952

Hi,

I've checked your website but I don't see the problem on the checkout:
take.ms/1qvsE
And the link of your screenshot doesn't work anymore:
take.ms/4IxrU

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #216978

Hi,

The problem doesn't ocur in the checkout. If a visitor clicks on the menu item "Cart" the display of the cart is wrong as mentioned above.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13376
  • MODERATOR
9 years 1 month ago #217017

As I said in my previous message, I'm not able to display that page on your website: take.ms/4IxrU
So I can't help you with CSS if I can't display the corresponding page on your website. Could you double check the link ?

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #217061

Now the link should work.

Please Log in or Create an account to join the conversation.

  • Posts: 82868
  • Thank you received: 13376
  • MODERATOR
9 years 1 month ago #217069

Hi,

Change the code:

<?php if($tmpl != 'component' && hikashop_level(1) && (($this->config->get('enable_wishlist') && $cart_type == 'cart') || $cart_type == 'wishlist')) { ?>
			<th class="hikashop_cart_action_title title" align="center">
				<a  style="cursor: pointer;" onClick="checkAll();"><?php echo JText::_('HIKASHOP_ADD_TO'); ?></a>
			</th>
			<th class="hikashop_cart_delete_title title" align="center">
				<?php echo JText::_('HIKA_DELETE'); ?>
			</th>
	<?php } ?>
to:
<?php if($tmpl != 'component'){
			if(hikashop_level(1) && (($this->config->get('enable_wishlist') && $cart_type == 'cart') || $cart_type == 'wishlist')) { ?>
			<th class="hikashop_cart_action_title title" align="center">
				<a  style="cursor: pointer;" onClick="checkAll();"><?php echo JText::_('HIKASHOP_ADD_TO'); ?></a>
			</th>
	<?php 	}
			if($hasAccess) { ?>
			<th class="hikashop_cart_delete_title title" align="center">
				<?php echo JText::_('HIKA_DELETE'); ?>
			</th>
	<?php 	}
		} ?>
in the file "showcart" of the view "cart" via the menu Display>Views and that should fix the problem.

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #217143

Super! Thanks very much!

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #217150

Uhm...Somehow I lost the small "delete" icon. Any idea how to get it back?

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 1 month ago #217159

Hi,

You can add this line at the top of the view:

$this->params->set('show_delete',1)

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #217246

Hi,

I did, but the delete icon is still not displayed.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 1 month ago #217249

Hi,

When looking at the cart, are you using the correct user account for that cart ?
We have the code:

$hasAccess = $this->cartVal->user_id == $userCurrent || $this->cartVal->session_id == $session->getId();
Which check if the current logged in user is the one who own the cart. If not, so no delete button displayed.

So in your case, it is an issue due to the used account, maybe not the correct one, or a session_id issue.

If you try to add the code:
$hasAccess = true;
after the previous given code, is the delete button displayed ?

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #217311

No, I'm afraid not. In the screenshot you can see how I inserted the code. Perhaps I did something wrong?

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 1 month ago #217354

Hi,

My bad, I forgot to say that the code $hasAccess = 1; must be added after that one:

$hasAccess = $this->cartVal->user_id == $userCurrent || $this->cartVal->session_id == $session->getId();

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #217396


I'm afraid that won't help either.

Attachments:

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 1 month ago #217400

Hi,

Are you sure that the view is edited in the correct template ?

If it is, please send us a backend access via our contact form (with the url of this id in the message):
hikashop.com/support/contact-us.html

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #217446

Hi,

The view is edited in the correct template, as far as I know. I send backend access so you can verify that.

Please Log in or Create an account to join the conversation.

  • Posts: 13201
  • Thank you received: 2322
9 years 1 month ago #217482

Hi,

Problem solved, it was a css issue du to your template, in the template.css file there was the property:

table#hikashop_cart_product_listing td:nth-child(8){
  display:none;
}
on the line "88", and this was hidding the delete part instead of the stock information one.
So I edited the property from child "8" to "7".

Please Log in or Create an account to join the conversation.

  • Posts: 43
  • Thank you received: 0
9 years 1 month ago #217495

Thanks very much

Please Log in or Create an account to join the conversation.

Time to create page: 0.125 seconds
Powered by Kunena Forum