Follow us on Twitter X-Cart on Facebook Wiki
Shopping cart software Solutions for online shops and malls
 

Problem adding Modify Extra Fields from Admin Search Results: main/products.tpl page

 
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design
 
Thread Tools Search this Thread
  #1  
Old 04-05-2011, 11:05 AM
 
censusadv88 censusadv88 is offline
 

Advanced Member
  
Join Date: Jul 2005
Posts: 55
 

Default Problem adding Modify Extra Fields from Admin Search Results: main/products.tpl page

Hello X-Cart,

I want to edit main/products.tpl in version 4.0.9 GOLD such that I can add one of Extra Fields to edit on the Search Results in the admin back end. This is instead of going into the product details themselves and having to modify from there.

What this is going to be for is so we can specify warranty values of "30" "30r" "1yr" etc. 1yr being for one year...

Anyway I edit the tables and able to make room for the changes. However the question is: How do I make the field_value for the extra product field update when I press the "update" button.

I used the following code to display a text box with the "field_value (Which is the value of the extra field)" of the extra field product variable:

{assign var="pid" value=$products[prod].productid}
{foreach from=$products_extra_fields[$pid] item=field}
{if $field.field eq "Warranty"}
<TD><input type="text" name="efields[{$field.fieldid}]" size="4" value="{$field.field_value}"></TD>
{/foreach}

The VALUE (Lets say "30") is $field.field_value and is shown correctly in the input-table text box on the admin back end main/product.tpl. However if I try to change the value inside the text box lets say to "1yr"... it goes back to "30" (The original value after modification on the product details page) after I press update.

Therefore I am thinking there must be some change to process_product.php (in includes/process_product.php) which will take the new value and change the proper extra field value.

My hypothesis is that the <input type="text" name=" NEEDS TO BE MODIFIED... and also something in the process_product.php needs to be changed in order to accept extra_field value inputs and to change them...

Lets try to figure this out!! PLEASE! =)
__________________
JC-x-cart 4.0.9
X-Cart Gold 4.5.5 / X-payments 1.0.6

SIGHTLESS =)
Reply With Quote
Reply
   X-Cart forums > X-Cart 4 > Dev Questions > Changing design



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -8. The time now is 11:57 AM.

   

 
X-Cart forums © 2001-2020