Post by shoo002 » Fri Feb 26, 2010 6:25 am

Please could someone help me to add a Cost price to the OC132 system. I would like to be able to create a report eventually Cost Vs Price. If anyone could help with where to add code and what to add etc etc it would really be helpful. I've already tried adding a database field in the product table of my db. and tried to copy the structure of the (price) structure in the public_html/admin files but am not sure how to get it all working

Thanks in advance
Stewart
Last edited by i2Paq on Fri Feb 26, 2010 3:12 pm, edited 1 time in total.
Reason: Title fix

Active Member

Posts

Joined
Sat Jul 04, 2009 9:40 pm


Post by rph » Fri Feb 26, 2010 12:58 pm

Sounds like a good start. Just duplicate the model/controller/template code for adding prices and change it to cost.

-Ryan


rph
Expert Member

Posts

Joined
Fri Jan 08, 2010 5:05 am
Location - Lincoln, Nebraska

Post by shoo002 » Sat Feb 27, 2010 2:41 am

Thanks for your reply,

Can anyone be a bit more specific, which files do i need to edit, then once in the files which sections of code do i need to look at.

Thanks
Stewart

Active Member

Posts

Joined
Sat Jul 04, 2009 9:40 pm


Post by rph » Sat Feb 27, 2010 5:35 am

Off the top of my head:

/admin/controller/catalog/product.php
/admin/model/catalog/product.php
/admin/view/template/catalog/product_form.tpl

-Ryan


rph
Expert Member

Posts

Joined
Fri Jan 08, 2010 5:05 am
Location - Lincoln, Nebraska

Post by shoo002 » Sat Feb 27, 2010 6:21 am

Ok i have gone through the files and copied any code that references the [price] when i try and look at the product to see if the cost section has come up and save the product it comes up with the below error. Does anyone know why this is happening and how to sort it.

Regards
Stewart

Active Member

Posts

Joined
Sat Jul 04, 2009 9:40 pm


Post by shoo002 » Sat Feb 27, 2010 6:34 am

Ok dont worry people i have managed to sort it out, The cost now shows in the product section. My next question is does anyone know how to export it using JNeuhoffs import export module.

By the way I hadnt edited the product_form.tpl file correctly thats why i was getting the error.

Thanks
Stewart

Active Member

Posts

Joined
Sat Jul 04, 2009 9:40 pm

Who is online

Users browsing this forum: No registered users and 341 guests