示例#1
0
    ?>
" style="cursor:pointer" onclick='setReturnItem(<?php 
    echo $pointer . ', ' . $rowID;
    ?>
)'>
	<td nowrap="nowrap"><?php 
    echo $query_result->fields['task_name'];
    ?>
</td>
	<td><?php 
    echo $query_result->fields['description'];
    ?>
</td>
  </tr>
<?php 
    $java_string .= 'task_list[' . $pointer . '] = new taskRecord(' . $query_result->fields['id'] . ', "' . gen_js_encode($query_result->fields['task_name']) . '", "' . gen_js_encode($query_result->fields['description']) . '");' . chr(10);
    $pointer++;
    $query_result->MoveNext();
    $odd = !$odd;
}
?>
 </tbody>
</table>
<div style="float:right"><?php 
echo $query_split->display_links();
?>
</div>
<div><?php 
echo $query_split->display_count(TEXT_DISPLAY_NUMBER . TEXT_TASKS);
?>
</div>
function gen_build_company_arrays()
{
    $acct_array = array();
    $acct_array['fields'] = array('primary_name', 'contact', 'address1', 'address2', 'city_town', 'state_province', 'postal_code', 'country_code', 'telephone1', 'email');
    $acct_array['company'] = array(gen_js_encode(COMPANY_NAME), gen_js_encode(AP_CONTACT_NAME), gen_js_encode(COMPANY_ADDRESS1), gen_js_encode(COMPANY_ADDRESS2), gen_js_encode(COMPANY_CITY_TOWN), gen_js_encode(COMPANY_ZONE), gen_js_encode(COMPANY_POSTAL_CODE), gen_js_encode(COMPANY_COUNTRY), gen_js_encode(COMPANY_TELEPHONE1), gen_js_encode(COMPANY_EMAIL));
    $acct_array['text'] = array();
    foreach ($acct_array['fields'] as $value) {
        $acct_array['text'][] = constant('GEN_' . strtoupper($value));
    }
    return $acct_array;
}
        $_REQUEST['list'] = 99999;
        break;
    case 'search':
    case 'search_reset':
    case 'go_page':
    default:
}
/*****************   prepare to display templates  *************************/
$user_choices = gen_get_pull_down(TABLE_USERS, true, '1', 'admin_id', 'display_name');
// build disposition drop-dwn javascript
$js_disp_code = 'js_disp_code = new Array(' . sizeof($action_codes) . ');' . chr(10);
$js_disp_value = 'js_disp_value = new Array(' . sizeof($action_codes) . ');' . chr(10);
$i = 0;
foreach ($action_codes as $key => $value) {
    $js_disp_code .= 'js_disp_code[' . $i . '] = "' . $key . '";' . chr(10);
    $js_disp_value .= 'js_disp_value[' . $i . '] = "' . gen_js_encode($value) . '";' . chr(10);
    $i++;
}
$cal_create = array('name' => 'createDate', 'form' => 'rma', 'fieldname' => 'creation_date', 'imagename' => 'btn_date_1', 'default' => isset($cInfo->creation_date) ? gen_locale_date($cInfo->creation_date) : gen_locale_date($creation_date), 'params' => array('align' => 'left'));
$cal_rcv = array('name' => 'receiveDate', 'form' => 'rma', 'fieldname' => 'receive_date', 'imagename' => 'btn_date_1', 'default' => isset($cInfo->receive_date) ? gen_locale_date($cInfo->receive_date) : gen_locale_date($receive_date), 'params' => array('align' => 'left'));
$cal_close = array('name' => 'closedDate', 'form' => 'rma', 'fieldname' => 'closed_date', 'imagename' => 'btn_date_1', 'default' => isset($cInfo->closed_date) ? gen_locale_date($cInfo->closed_date) : gen_locale_date($closed_date), 'params' => array('align' => 'left'));
$cal_invoice = array('name' => 'invoiceDate', 'form' => 'rma', 'fieldname' => 'invoice_date', 'imagename' => 'btn_date_1', 'default' => isset($cInfo->invoice_date) ? gen_locale_date($cInfo->invoice_date) : gen_locale_date($invoice_date), 'params' => array('align' => 'left'));
$include_header = true;
$include_footer = true;
switch ($_REQUEST['action']) {
    case 'new':
        // set some defaults
        $cInfo->creation_date = date('Y-m-d');
        if (isset($_GET['name'])) {
            // defaults wre passed
            $cInfo->caller_name = urldecode($_GET['name']);
示例#4
0
function contacts_add_address_info($idx, $fields)
{
    $result = 'addBook[' . $idx . '] = new addressRecord(' . $fields['address_id'] . ', ';
    $result .= '"' . str_replace('"', '\\"', $fields['primary_name']) . '", ';
    $result .= '"' . str_replace('"', '\\"', $fields['contact']) . '", ';
    $result .= '"' . str_replace('"', '\\"', $fields['address1']) . '", ';
    $result .= '"' . str_replace('"', '\\"', $fields['address2']) . '", ';
    $result .= '"' . str_replace('"', '\\"', $fields['city_town']) . '", ';
    $result .= '"' . str_replace('"', '\\"', $fields['state_province']) . '", ';
    $result .= '"' . $fields['postal_code'] . '", ';
    $result .= '"' . ($fields['country_code'] ? $fields['country_code'] : COMPANY_COUNTRY) . '", ';
    $result .= '"' . $fields['telephone1'] . '", ';
    $result .= '"' . $fields['telephone2'] . '", ';
    $result .= '"' . $fields['telephone3'] . '", ';
    $result .= '"' . $fields['telephone4'] . '", ';
    $result .= '"' . $fields['email'] . '", ';
    $result .= '"' . $fields['website'] . '", ';
    $result .= '"' . gen_js_encode($fields['notes']) . '");' . chr(10);
    return $result;
}