예제 #1
0
        // Open box that hides this form by default
        echo '<div id="new_client" ' . (_session('add_client') ? '' : ' style="display: none;"') . '>';
        echo "<div style='overflow: hidden; width: 100%;'>";
        echo '<div style="float: left; text-align: right; width: 29%;">';
        echo '<p class="normal_text" style="margin: 0; padding: 4px;">' . _Ti('input_search_client') . '</p>';
        echo "</div>\n";
        echo '<div style="float: right; width: 69%;">';
        echo '<p class="normal_text" style="margin: 0; padding: 4px;"><input type="text" name="clientsearchkey" id="clientsearchkey" size="25" />' . "</p>\n";
        echo '<span id="autocomplete-client-popup" class="autocomplete" style="visibility: hidden;"><span></span></span>';
        echo '</div>';
        echo '<div style="clear: right;"></div>';
        echo '<div id="autocomplete-client-data"></div>' . "\n";
        echo "</div>\n";
        echo '<div id="autocomplete-client-alt">';
        $client = new LcmClientInfoUI();
        $client->printEdit();
        echo '</div>';
        echo "<script type=\"text/javascript\">\n\t\t\tautocomplete('clientsearchkey', 'autocomplete-client-popup', 'ajax.php', 'autocomplete-client-data', 'autocomplete-client-alt')\n\t\t\t</script>\n";
        echo "</div>\n";
        // closes box that hides this form by default
    }
}
if (!$id_case) {
    //
    // Find case (show only if new case)
    //
    show_page_subtitle("Case information", 'cases_intro');
    // TRAD
    echo "<div style='overflow: hidden; width: 100%;'>";
    echo '<div style="float: left; text-align: right; width: 29%;">';
    echo '<p class="normal_text" style="margin: 0; padding: 4px;">' . _Ti('input_search_case') . '</p>';
예제 #2
0
            $form_data[$key] = $value;
        }
    }
}
if ($id_client > 0) {
    lcm_page_start(_T('title_client_edit') . ' ' . get_person_name($form_data), '', '', 'clients_newclient');
} else {
    lcm_page_start(_T('title_client_new'), '', '', 'clients_newclient');
}
echo show_all_errors();
echo '<form action="upd_client.php" method="post">' . "\n";
if (_request('attach_case')) {
    echo '<input type="hidden" name="attach_case" id="attach_case" value="' . _request('attach_case') . '" />' . "\n";
}
$obj_client = new LcmClientInfoUI($form_data['id_client']);
$obj_client->printEdit();
//
// Organisations this client represents
//
/* [ML] too confusing
	echo "<tr>\n";
	echo '<td colspan="2" align="center" valign="middle" class="heading">';
	echo '<h4>' . _T('client_subtitle_organisations') . '</h4>';
	echo '</td>';
	echo "</tr>\n";
	$q = "SELECT name FROM lcm_client_org, lcm_org WHERE id_client=" . $form_data['id_client'] . " AND lcm_client_org.id_org=lcm_org.id_org";
	$result = lcm_query($q);
	$orgs = array();
	while ($row = lcm_fetch_array($result)) {
		$orgs[] = $row['name'];
	}