I am working with the subproducts module and I need to make a very simple change to the function, but everything I have tried is not working. I need to change the price column to be a text field instead of static text, so it looks like the Stock column. This is the function, from the subproducts.module:
function theme_subproducts_generate_wizard2($form) {
$header = array(array('data' => ''));
foreach (element_children($form['header']) as $key) {
$header[] = array('data' => form_render($form['header'][$key]));
}
$header[] = array('data' => t('Price'));
$header[] = array('data' => t('Stock'));
$rows = array();
$i = 0;
foreach (element_children($form['permutations']) as $key)
{
$rows[$i] = array(array('data' => form_render($form['permutations'][$key]['use'])));
foreach(element_children($form['name'][$key]) as $aid)
{
$rows[$i][] = array('data' => form_render($form['name'][$key][$aid]),'align' => 'center');
}
// I want to change the price row below to display a text field exactly the same way it is displaying the 'stock' field.
$rows[$i][] = array('data' => form_render($form['price'][$key]));
$rows[$i][] = array('data' => form_render($form['permutations'][$key]['stock']));
$i++;
}
$output = form_render($form['help']);
$output .= theme('table', $header, $rows);
$output .= form_render($form['submit']);