* * All copies of the Covered Code must include on each user interface screen: * (i) the "Powered by SugarCRM" logo and * (ii) the SugarCRM copyright notice * in the same form as they appear in the distribution. See full license for * requirements. * * The Original Code is: SugarCRM Open Source * The Initial Developer of the Original Code is SugarCRM, Inc. * Portions created by SugarCRM are Copyright (C) 2004-2006 SugarCRM, Inc.; * All Rights Reserved. * Contributor(s): ______________________________________. ********************************************************************************/ /********************************************************************************* * Description: TODO: To be written. * Portions created by SugarCRM are Copyright (C) SugarCRM, Inc. * All Rights Reserved. * Contributor(s): ______________________________________.. ********************************************************************************/ require_once 'modules/Bugs/Bug.php'; $focus = new Bug(); if (!isset($_REQUEST['record'])) { sugar_die("A record number must be specified to delete the bug."); } $focus->retrieve($_REQUEST['record']); if (!$focus->ACLAccess('Delete')) { ACLController::displayNoAccess(true); sugar_cleanup(true); } $focus->mark_deleted($_REQUEST['record']); header("Location: index.php?module=" . $_REQUEST['return_module'] . "&action=" . $_REQUEST['return_action'] . "&record=" . $_REQUEST['return_id']);
function bug_by_search($name, $where = '', $msi_id = '0') { $seed = new Bug(); if (!$seed->ACLAccess('ListView')) { return array(); } if ($where == '') { $where = $seed->build_generic_where_clause($name); } $response = $seed->get_list("name", $where, 0); $list = $response['list']; $output_list = array(); // create a return array of names and email addresses. foreach ($list as $value) { $output_list[] = get_bean_array($value, $msi_id, 'Bug'); } return $output_list; }
* The Initial Developer of the Original Code is SugarCRM, Inc. * Portions created by SugarCRM are Copyright (C) 2004-2006 SugarCRM, Inc.; * All Rights Reserved. * Contributor(s): ______________________________________. ********************************************************************************/ /********************************************************************************* * Description: TODO: To be written. * Portions created by SugarCRM are Copyright (C) SugarCRM, Inc. * All Rights Reserved. * Contributor(s): ______________________________________.. ********************************************************************************/ require_once 'modules/Bugs/Bug.php'; require_once 'include/formbase.php'; $focus = new Bug(); $focus->retrieve($_POST['record']); if (!$focus->ACLAccess('Save')) { ACLController::displayNoAccess(true); sugar_cleanup(true); } if (!empty($_POST['assigned_user_id']) && $focus->assigned_user_id != $_POST['assigned_user_id'] && $_POST['assigned_user_id'] != $current_user->id) { $check_notify = TRUE; } else { $check_notify = FALSE; } foreach ($focus->column_fields as $field) { if (isset($_POST[$field])) { $value = $_POST[$field]; $focus->{$field} = $value; } } foreach ($focus->additional_column_fields as $field) {