Post by skip » Wed Jun 27, 2018 2:53 pm

Is it posible to set default weight 0.01 instead 0 ? Thanks

Active Member

Posts

Joined
Mon May 09, 2011 9:57 pm

Post by thekrotek » Wed Jun 27, 2018 3:25 pm

Default value where exactly and for what purpose?

Professional OpenCart extensions, support and custom work.
Contact me via email or Skype by support@thekrotek.com


User avatar
Expert Member

Posts

Joined
Sun Jul 03, 2016 12:24 am


Post by skip » Wed Jun 27, 2018 3:32 pm

On product data page under weight, I need settings 0kg - 0.01 kg free shipping and under 0.01kg some value for shipping
So in case I forgot set 0.01 system set up automatically

Active Member

Posts

Joined
Mon May 09, 2011 9:57 pm

Post by thekrotek » Wed Jun 27, 2018 4:28 pm

Product page doesn't have shipping method selection by default. But if you just want to have a default value for Weight option, you can simply set it right in your database, "product" table.

Professional OpenCart extensions, support and custom work.
Contact me via email or Skype by support@thekrotek.com


User avatar
Expert Member

Posts

Joined
Sun Jul 03, 2016 12:24 am


Post by skip » Thu Jun 28, 2018 2:35 am

I was set default value in database to 0.01 but it still show 0.00000 in admin data weight field, and if I save product without enter value it register 0.00
Maybe something in code must be changed ? image in att

Attachments

weight.jpg

weight.jpg (299.17 KiB) Viewed 320 times


Active Member

Posts

Joined
Mon May 09, 2011 9:57 pm

Post by straightlight » Thu Jun 28, 2018 2:55 am

Maybe something in code must be changed ?
OC version?

The most generated errors being found on Opencart forum originates from contributed programming. The increased post counters are caused by redundancies of the same solutions that were already provided prior.


Regards,
Straightlight
Opencart.com Administrator / Quality Assurance Analyst / Programmer


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by skip » Thu Jun 28, 2018 3:01 am

2.2.0.0

Active Member

Posts

Joined
Mon May 09, 2011 9:57 pm

Post by straightlight » Thu Jun 28, 2018 3:34 am

In admin/controller/catalog/product.php file,

find:

Code: Select all

$data['weight'] = '';
replace with:

Code: Select all

$data['weight'] = '0.01';

The most generated errors being found on Opencart forum originates from contributed programming. The increased post counters are caused by redundancies of the same solutions that were already provided prior.


Regards,
Straightlight
Opencart.com Administrator / Quality Assurance Analyst / Programmer


Legendary Member

Posts

Joined
Mon Nov 14, 2011 11:38 pm
Location - Canada, ON

Post by skip » Fri Jun 29, 2018 7:54 am

Thank You very much. Solved

Active Member

Posts

Joined
Mon May 09, 2011 9:57 pm
Who is online

Users browsing this forum: No registered users and 33 guests