当前位置: 首页>>代码示例>>PHP>>正文


PHP ui_print_success_message函数代码示例

本文整理汇总了PHP中ui_print_success_message函数的典型用法代码示例。如果您正苦于以下问题:PHP ui_print_success_message函数的具体用法?PHP ui_print_success_message怎么用?PHP ui_print_success_message使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了ui_print_success_message函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: get_db_row

$lead = get_db_row('tlead','id',$id);
$user = get_db_row("tusuario", "id_usuario", $config["id_user"]);
$company_user = get_db_sql ("select name FROM tcompany where id = ". $user["id_company"]);

$from = get_parameter ("from", $user["direccion"]);
$to = get_parameter ("to", "");
$subject = get_parameter ("subject", "");
$mail = get_parameter ("mail", "");
$send = (int) get_parameter ("send",0);
$cco = get_parameter ("cco", "");

// Send mail
if ($send) {
	if (($subject != "") AND ($from != "") AND ($to != "")) {
		echo ui_print_success_message (__('Mail queued'), '', true, 'h3', true);

		integria_sendmail ($to, $subject, $mail, false, "", $from, true);

		if ($cco != "")
			integria_sendmail ($cco, $subject, $mail, false, "", $from, true);

		$datetime =  date ("Y-m-d H:i:s");	
		// Update tracking
		$sql = sprintf ('INSERT INTO tlead_history (id_lead, id_user, timestamp, description) VALUES (%d, "%s", "%s", "%s")', $id, $config["id_user"], $datetime, "Forwarded lead by mail to $to");
		process_sql ($sql);

		// Update activity
		$comments = __("Forwarded lead by mail to $to"). "
" . $mail; // this adds 
 
		$sql = sprintf ('INSERT INTO tlead_activity (id_lead, written_by, creation, description) VALUES (%d, "%s", "%s", "%s")', $id, $config["id_user"], $datetime, $comments);
		process_sql ($sql);
开发者ID:articaST,项目名称:integriaims,代码行数:30,代码来源:lead_forward.php

示例2: ui_print_error_message

	} else {
		$result_msg = ui_print_error_message (__('Could not be created'), '', true, 'h3', true);
		$id = false;
	}
}

if ($update) {
	$values['name'] = (string) get_parameter ('name');
	$values['sql'] = (string) get_parameter ('sql');
	$values['id_group'] = get_parameter('id_group');
	
	$result = false;
	if (! empty ($values['name']))
		$result = process_sql_update ('tinventory_reports', $values, array ('id' => $id));
	if ($result) {
		$result_msg = ui_print_success_message (__("Successfully updated"), '', true, 'h3', true);
	} else {
		$result_msg = ui_print_error_message (__('Could not be updated'), '', true, 'h3', true);
	}
}

if ($id) {
	clean_cache_db();

	$report = get_db_row ('tinventory_reports', 'id', $id);
	if ($report === false)
		return;
	$name = $report['name'];
	$sql = $report['sql'];
	$id_group = $report['id_group'];
}
开发者ID:articaST,项目名称:integriaims,代码行数:31,代码来源:inventory_reports_detail.php

示例3: update_config_token

    update_config_token("access_public", $config["access_public"]);
    update_config_token("loginhash_pwd", $config["loginhash_pwd"]);
    update_config_token("csv_standard_encoding", $config["csv_standard_encoding"]);
    update_config_token("enable_update_manager", $config["enable_update_manager"]);
    update_config_token("max_direct_download", $config["max_direct_download"]);
    if ($is_enterprise) {
        update_config_token("enable_pass_policy", $config["enable_pass_policy"]);
        update_config_token("pass_size", $config["pass_size"]);
        update_config_token("pass_needs_numbers", $config["pass_needs_numbers"]);
        update_config_token("pass_needs_symbols", $config["pass_needs_symbols"]);
        update_config_token("pass_expire", $config["pass_expire"]);
        update_config_token("first_login", $config["first_login"]);
        update_config_token("mins_fail_pass", $config["mins_fail_pass"]);
        update_config_token("number_attempts", $config["number_attempts"]);
    }
    echo ui_print_success_message(__('Successfully updated'), '', true, 'h3', true);
}
// Render SYSTEM language code, not current language.
$table = new StdClass();
$table->width = '100%';
$table->class = 'search-table-button';
$table->colspan = array();
$table->data = array();
$incident_reporter_options[0] = __('Disabled');
$incident_reporter_options[1] = __('Enabled');
$language_config = get_db_value('value', 'tconfig', 'token', 'language_code');
$table->data[0][0] = print_select_from_sql('SELECT id_language, name FROM tlanguage ORDER BY name', 'language_code', $language_config, '', '', '', true, false, false, __('Language'));
$table->data[0][1] = print_input_text("sitename", $config["sitename"], '', 30, 50, true, __('Sitename'));
$error_log_options[0] = __('Disabled');
$error_log_options[1] = __('Enabled');
$table->data[1][0] = print_checkbox("error_log", $error_log_options, $config["error_log"], true, __('Enable error log') . print_help_tip(__("This errorlog is on /integria.log"), true));
开发者ID:articaST,项目名称:integriaims,代码行数:31,代码来源:setup.php

示例4: process_sql

		work_home = %d 
		WHERE id = %d',
		$timestamp, $duration, $description, $have_cost,
		$id_profile, $public, $wu_user, $work_home, $id_workunit);
	$result = process_sql ($sql);

	if ($id_task !=0) {
	    // Old old association
	    process_sql ("DELETE FROM tworkunit_task WHERE id_workunit = $id_workunit");
	    // Create new one
            $sql = sprintf ('INSERT INTO tworkunit_task
                            (id_task, id_workunit) VALUES (%d, %d)',
                                        $id_task, $id_workunit);
            $result = process_sql ($sql, 'insert_id');
	}
	$result_output = ui_print_success_message (__('Workunit updated'), '', true, 'h3', true);
	audit_db ($config["id_user"], $config["REMOTE_ADDR"], "PWU", "Updated PWU. $description");
	
	if ($result !== false) {
		set_task_completion ($id_task);
	}
}

$multiple_wu_report = array();

if ($operation == 'multiple_wu_insert') {
	
	//Walk post array looking for 
	$i = 1;
	while(true) {
		
开发者ID:articaST,项目名称:integriaims,代码行数:30,代码来源:user_spare_workunit.php

示例5: ui_print_success_message

		echo ui_print_success_message (__('Successfully updated'), '', true, 'h3', true);
        audit_db ($config["id_user"], $config["REMOTE_ADDR"], "SLA Modified",
		"Updated SLA ($name)", $sql);
	}
	$id = 0;
}

// DELETE
// ==================
if ($delete_sla) {
	$name = get_db_value ('name', 'tsla', 'id', $id);
	$sql = sprintf ('DELETE FROM tsla WHERE id = %d', $id);
	$result = process_sql ($sql);
    audit_db ($config["id_user"], $config["REMOTE_ADDR"], "SLA Deleted",
		"Delete SLA ($name)", $sql);
	echo ui_print_success_message (__("Successfully deleted"), '', true, 'h3', true);
	$id = 0;
}

// FORM (Update / Create)
if ($id || $new_sla) {
	if ($new_sla) {
		$name = "";
		$description = "";
		$min_response = 48.0;
		$max_response = 480.0;
		$max_incidents = 10;
		$max_inactivity = 96.0;
		$id_sla_base = 0;
		$enforced = 1;
        $five_daysonly = 1;
开发者ID:articaST,项目名称:integriaims,代码行数:31,代码来源:sla_detail.php

示例6: get_parameter

// ---------------

if ($operation == "delete"){
	// Delete workunit with ACL / Project manager check
	$id_workunit = get_parameter ("id_workunit");
	$sql = "SELECT * FROM tworkunit WHERE id = $id_workunit";
	if ($res = mysql_query($sql)) 
		$row=mysql_fetch_array($res);
	else
		return;
	
	$id_user_wu = $row["id_user"];
	if (($id_user_wu == $config["id_user"]) OR (give_acl($config["id_user"], 0,"PM") ==1 ) OR (project_manager_check($id_project) == 1)){
		mysql_query ("DELETE FROM tworkunit where id = '$id_workunit'");
		if (mysql_query ("DELETE FROM tworkunit_task where id_workunit = '$id_workunit'")){
				$result_output = ui_print_success_message (__('Successfully deleted'), '', true, 'h3', true);
				audit_db ($id_user, $config["REMOTE_ADDR"], "Work unit deleted", "Workunit for $id_user");
		} else {
			$result_output = ui_print_error_message (__('Not deleted. Error deleting data'), '', true, 'h3', true);
		}
	} else {
		audit_db($id_user, $config["REMOTE_ADDR"], "ACL Violation","Trying to delete WU $id_workunit without rigths");
		include ("general/noaccess.php");
		exit;
	}
}

// --------------------
// Workunit report
// --------------------
开发者ID:articaST,项目名称:integriaims,代码行数:30,代码来源:user_workunit_report.php

示例7: process_sql_insert

				'id_incident_type' => $id_incident_type,
				'id_parent' => $idParentValue,
				'sla_disabled' => $sla_disabled,
				'email_copy' => $email_copy,
				'editor' => $editor,
				'id_group_creator' => $id_group_creator,
				'blocked' => $blocked,
				'old_status' => $old_status,
				'old_resolution' => $old_resolution
			);
		$id = process_sql_insert ('tincidencia', $values);

		if ($id !== false) {
			/* Update inventory objects in incident */
			update_incident_inventories ($id, get_parameter ('inventories'));
			$result_msg = ui_print_success_message (__('Successfully created'), '', true, 'h3', true);
			$result_msg .= '<h4><a href="index.php?sec=incidents&sec2=operation/incidents/incident_dashboard_detail&id='.$id.'">'.__('Please click here to continue working with incident #').$id."</a></h4>";

			//Add traces and statistic information	
			incidents_set_tracking ($id, 'create', $priority, $estado, $resolution, $usuario, $grupo);
			audit_db ($config["id_user"], $config["REMOTE_ADDR"],
				"Ticket created",
				"User ".$config['id_user']." created incident #".$id);
			
			// Create automatically a WU with the editor ?
			if ($config["incident_creation_wu"] == 1){
				$wu_text = __("WU automatically created by the editor on the incident creation.");
				// Do not send mail in this WU
				create_workunit ($id, $wu_text, $editor, $config["iwu_defaultime"], 0, "", 1, 0);
			}
			
开发者ID:articaST,项目名称:integriaims,代码行数:30,代码来源:incident_detail.php

示例8: get_parameter



// Database DELETE
// ==================
if (isset($_GET["delete_cat"])){ // if delete
	$id = get_parameter ("delete_cat",0);
	// First delete from tagente_modulo
	$sql_delete= "DELETE FROM tkb_category WHERE id = $id";

	// Move parent who has this product to 0
	mysql_query("UPDATE tkb_category SET parent = 0 WHERE parent = $id");		
	$result = mysql_query($sql_delete);
	if ($result)
		echo ui_print_error_message (__('Successfully deleted'), '', true, 'h3', true); 
	else
		echo ui_print_success_message (__('Cannot be deteled'), '', true, 'h3', true);
}



// CREATE form
if ((isset($_GET["create"]) OR (isset($_GET["update"])))) {
	if (isset($_GET["create"])){
		$icon = "";
		$description = "";
		$name = "";
		$id = -1;
		$parent = -1;
	} else {
		$id = get_parameter ("update",-1);
		$row = get_db_row ("tkb_category", "id", $id);
开发者ID:articaST,项目名称:integriaims,代码行数:29,代码来源:manage_cat.php

示例9: get_workunit_data

					$workunit_data = get_workunit_data($workunit["id_workunit"]);
					
					echo '<div class="comment">';
					show_workunit_data ($workunit_data, $title);
					echo '</div>';
				}
			}
		}
		
		if ($is_enterprise) {
			incidents_run_realtime_workflow_rules ($id_incident);
		}
		return;
	}
	else {
		$result_msg = ui_print_success_message (__('Comment added successfully'), '', true, 'h3', true);
		echo $result_msg;
	}
	
	if ($is_enterprise) {
		incidents_run_realtime_workflow_rules ($id_incident);
	}
}

$table = new StdClass();
$table->width = '100%';
$table->class = 'search-table';
$table->colspan = array ();
$table->colspan[1][0] = 6;
$table->colspan[2][0] = 6;
$table->data = array ();
开发者ID:articaST,项目名称:integriaims,代码行数:31,代码来源:incident_workunits.php

示例10: sprintf

}

/* Delete a custom saved search */
if ($id_search && $delete_custom_search) {
	
	$sql = sprintf ('DELETE FROM tcustom_search
		WHERE id_user = "%s"
		AND id = %d',
		$config['id_user'], $id_search);
	$result = process_sql ($sql);
	if ($result === false) {
		echo ui_print_error_message (__('Could not delete custom search'), '', true, 'h3', true);
	}
	else {
		$id_search = false;
		echo ui_print_success_message (__('Custom search deleted'), '', true, 'h3', true);
	}
}

// FORM (Update / Create)
if ($id || $new) {
	if ($new) {
		
		if (!$section_write_permission && !$section_manage_permission) {
			audit_db ($config["id_user"], $config["REMOTE_ADDR"], "ACL Violation", "Trying to create a lead");
			require ("general/noaccess.php");
			exit;
		}
		
		$id = 0;
开发者ID:articaST,项目名称:integriaims,代码行数:30,代码来源:lead_detail.php

示例11: process_sql_delete

		}
		echo "<br>";
		print_button (__('OK'), 'OK', false, '', 'class="sub blank"');
	}
}


if ($delete_agenda_entry) {
	
	if (!empty($id) && !$permission) {
		// Doesn't have access to this page
		audit_db ($config['id_user'], $config["REMOTE_ADDR"], "ACL Violation", "Trying to delete an agenda entry");
		include ("general/noaccess.php");
		exit;
	}
	
	$result = process_sql_delete('tagenda', array('id' => $id));
	
	if ($result !== false) {
		echo ui_print_success_message (__('The event was deleted'), '', true, 'h3', true);
		echo "<br>";
		print_button (__('OK'), 'OK', false, '', 'class="sub blank"');
	} else {
		echo ui_print_error_message (__('An error ocurred. Event not deleted'), '', true, 'h3', true);
		echo "<br>";
		print_button (__('OK'), 'OK', false, '', 'class="sub blank"');
	}
}

?>
开发者ID:articaST,项目名称:integriaims,代码行数:30,代码来源:entry.php

示例12: db_update_schema

function db_update_schema()
{
    global $config;
    $dir = $config["homedir"] . "extras/mr";
    $message = '';
    if (file_exists($dir) && is_dir($dir)) {
        if (is_readable($dir)) {
            $files = scandir($dir);
            // Get all the files from the directory ordered by asc
            if ($files !== false) {
                $pattern = "/^\\d+\\.sql\$/";
                $sqlfiles = preg_grep($pattern, $files);
                // Get the name of the correct files
                $files = null;
                $pattern = "/\\.sql\$/";
                $replacement = "";
                $sqlfiles_num = preg_replace($pattern, $replacement, $sqlfiles);
                // Get the number of the file
                $sqlfiles = null;
                if ($sqlfiles_num) {
                    foreach ($sqlfiles_num as $sqlfile_num) {
                        $file = "{$dir}/{$sqlfile_num}.sql";
                        if ($config["minor_release"] >= $sqlfile_num) {
                            if (!file_exists($dir . "/updated") || !is_dir($dir . "/updated")) {
                                mkdir($dir . "/updated");
                            }
                            $file_dest = "{$dir}/updated/{$sqlfile_num}.sql";
                            if (copy($file, $file_dest)) {
                                unlink($file);
                            }
                        } else {
                            $result = db_run_sql_file($file);
                            if ($result) {
                                update_config_token("minor_release", $sqlfile_num);
                                if ($config["minor_release"] == $sqlfile_num) {
                                    if (!file_exists($dir . "/updated") || !is_dir($dir . "/updated")) {
                                        mkdir($dir . "/updated");
                                    }
                                    $file_dest = "{$dir}/updated/{$sqlfile_num}.sql";
                                    if (copy($file, $file_dest)) {
                                        unlink($file);
                                    }
                                }
                                $message = ui_print_success_message(__('The database schema has been updated to the minor release') . $sqlfile_num, '', true, 'h3', true);
                            } else {
                                $message = ui_print_error_message(__('An error occurred while updating the database schema to the minor release ') . $sqlfile_num, '', true, 'h3', true);
                                break;
                            }
                        }
                    }
                }
            }
        } else {
            $message = ui_print_error_message(__('The directory ') . $dir . __(' should have read permissions in order to update the database schema'), '', true, 'h3', true);
        }
    } else {
        $message = ui_print_error_message(__('The directory ') . $dir . __(' does not exist'), '', true, 'h3', true);
    }
    return $message;
}
开发者ID:articaST,项目名称:integriaims,代码行数:60,代码来源:functions_db.mysql.php

示例13: get_parameter

$id_user = get_parameter ("id_user", $config["id_user"]);
$id_role = get_parameter ("roles", 0);
if (isset($_POST["tasks"])){
	$tasks = (array) $_POST["tasks"];
}
$delete = get_parameter ("delete", 0);
if ($delete) {
	$id_project = get_db_value ('id_project', 'ttask', 'id', $delete);
	$project_access = get_project_access ($config['id_user'], $id_project);
	$task_access = get_project_access ($config['id_user'], $id_project, $delete);
	// ACL - To delete a task, you should have TW permission and belong to the task or be project manager
	if ($project_access['manage'] || $task_access['manage']) {
		$id_task = $delete;
		$sql = "DELETE FROM trole_people_task WHERE id_task = $id_task AND id_user = '$id_user'";
		$resq1=mysql_query($sql);
		echo ui_print_success_message (__("Assigment removed succesfully"), '', true, 'h3', true);
	} else {
		audit_db ($config['id_user'], $config["REMOTE_ADDR"], "ACL Violation", "Trying to delete the task $delete");
		echo ui_print_error_message (__("You do not have permission to delete this task"), '', true, 'h3', true);
	}
}

$add = get_parameter ("add", 0);
if ($add && $id_role) {
	
	foreach ($tasks as $id_task) {
		
		$id_project = get_db_value ('id_project', 'ttask', 'id', $id_task);
		$task = get_db_value ('name', 'ttask', 'id', $id_task);
		if (!$id_project) {
			echo ui_print_error_message (__('Error. Task is not assigned to a project.'), '', true, 'h3', true);
开发者ID:articaST,项目名称:integriaims,代码行数:31,代码来源:role_user_global.php

示例14: get_parameter

	$key = get_parameter('key');
	
	if ($fields == false) {
		$fields = array();
	}
	
	foreach ($fields as $field) {
		if ($field['Field'] != $key) {
			$values[$field['Field']] = get_parameter($field['Field']);
		}
	}
	
	$result_insert = process_sql_insert ($external_table, $values);
	
	if ($result_insert) {
		echo ui_print_success_message (__('Inserted row'), '', true, 'h3', true);
	} else {
		echo ui_print_error_message (__('There was a problem inserting row'), '', true, 'h3', true);
	}
}

echo "<h1>".__('External table management')."</h1>";

$table = new stdClass;
$table->width = '98%';
$table->class = 'search-table';
$table->id = "external-editor";

$table->data = array ();

开发者ID:articaST,项目名称:integriaims,代码行数:29,代码来源:manage_external_tables.php

示例15: user_delete_user

function user_delete_user($id_user)
{
    global $config;
    // Delete user
    // Delete cols from table tgrupo_usuario
    if ($config["enteprise"] == 1) {
        $query_del1 = "DELETE FROM tusuario_perfil WHERE id_usuario = '" . $id_user . "'";
        $resq1 = mysql_query($query_del1);
    }
    // Delete trole_people_task entries
    mysql_query("DELETE FROM trole_people_task WHERE id_user = '" . $id_user . "'");
    // Delete trole_people_project entries
    mysql_query("DELETE FROM trole_people_project WHERE id_user = '" . $id_user . "'");
    $query_del2 = "DELETE FROM tusuario WHERE id_usuario = '" . $id_user . "'";
    $resq2 = mysql_query($query_del2);
    //Delet custom fields
    $query_del3 = "DELETE FROM tuser_field_data WHERE id_user = '" . $id_user . "'";
    $resq3 = mysql_query($query_del3);
    if (!$resq2) {
        echo ui_print_error_message(__('Could not be deleted'), '', true, 'h3', true);
    } else {
        echo ui_print_success_message(__('Successfully deleted'), '', true, 'h3', true);
    }
    return;
}
开发者ID:articaST,项目名称:integriaims,代码行数:25,代码来源:functions_user.php


注:本文中的ui_print_success_message函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。