本文整理汇总了PHP中funciones::borrar方法的典型用法代码示例。如果您正苦于以下问题:PHP funciones::borrar方法的具体用法?PHP funciones::borrar怎么用?PHP funciones::borrar使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类funciones
的用法示例。
在下文中一共展示了funciones::borrar方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: funciones
function del_item($id)
{
$fun = new funciones();
$tbl = 'books';
$field = 'tb_id';
$var = $id;
return $fun->borrar($tbl, $field, $var);
}
示例2: remove_user
function remove_user()
{
$fun = new funciones();
$msg = new messages();
$response = new StdClass();
/*recibimos variables*/
$user = $_POST["user"];
$res = $fun->borrar("vehiculos", "ve_id", $user);
if ($res) {
$res = true;
$mes = $msg->get_msg("e004");
} else {
$res = false;
$mes = $msg->get_msg("e022");
}
$response->res = $res;
$response->mes = $mes;
echo json_encode($response);
}
示例3: change_pack
function change_pack()
{
$fun = new funciones();
$msg = new messages();
$response = new StdClass();
/*recibimos variables*/
$act = $_POST["a"];
$id = $_POST["id"];
if ($act == "" || $id == "") {
$res = false;
$mes = $msg->get_msg("e005");
} else {
$con = new con();
$con->connect();
if ($act == 1) {
//activar, cambiar a 99
if ($fun->borrar("remisiones_fisicas", "rf_id", $id)) {
$res = true;
$mes = $msg->get_msg("e004");
} else {
$res = false;
$mes = $msg->get_msg("e003-1", "Activando remision.");
}
} else {
//desactivar, cambiar a 1
if ($fun->activar("remisiones_fisicas", "rf_id", $id)) {
$res = true;
$mes = $msg->get_msg("e004");
} else {
$res = false;
$mes = $msg->get_msg("e003-1", "Desactivando remision.");
}
}
}
$response->res = $res;
$response->mes = $mes;
echo json_encode($response);
$con->disconnect();
}
示例4: remove_inv
function remove_inv()
{
$fun = new funciones();
$msg = new messages();
$response = new StdClass();
/*recibimos variables*/
$inv = $_POST["inv"];
$res = $fun->borrar("inventario", "in_id", $inv);
if ($res) {
$res = true;
$mes = $msg->get_msg("e004");
} else {
$res = false;
$mes = $msg->get_msg("e019");
}
$response->res = $res;
$response->mes = $mes;
echo json_encode($response);
}
示例5: remove_finca
function remove_finca()
{
$fun = new funciones();
$msg = new messages();
$response = new StdClass();
/*recibimos variables*/
$finca = $_POST["finca"];
if ($fun->borrar("fincas", "fi_id", $finca)) {
if ($fun->borrar("inventario", "in_fi_id", $finca)) {
if ($fun->borrar("control_inventarios", "ci_fi_id", $finca)) {
if ($fun->borrar("lotes_autorizados", "la_fi_id", $finca)) {
$res = true;
$mes = $msg->get_msg("e004");
} else {
$res = false;
$mes = $msg->get_msg("e016");
}
} else {
$res = false;
$mes = $msg->get_msg("e017");
}
} else {
$res = false;
$mes = $msg->get_msg("e018");
}
} else {
$res = false;
$mes = $msg->get_msg("e015");
}
$response->res = $res;
$response->mes = $mes;
echo json_encode($response);
}