<?php
/*   __________________________________________________
    |  Obfuscated by YAK Pro - Php Obfuscator  2.0.17  |
    |              on 2026-03-26 06:01:16              |
    |    GitHub: https://github.com/pk-fr/yakpro-po    |
    |__________________________________________________|
*/
 require_once RUTA_APP . 'Conexion.php'; class SimpleQuery { public static function exec($query, $is_insert = FALSE) { goto jBIL5; mgKoX: $r = array("status" => "error", "error" => mysqli_error($con), "query" => $query); goto Nfmik; a4YCW: dXlY0: goto oTab2; FbAlr: $r = array("status" => "ok", "result" => $res, "id" => $id); goto a4YCW; WuP6F: if ($res) { goto e52Nn; } goto mgKoX; ONcD_: e52Nn: goto IhP_S; YaM1z: if (!$is_insert) { goto DG5FJ; } goto w7iDv; IhP_S: $id = "-1"; goto YaM1z; spgV9: $res = sv_mysqli_query($con, $query); goto iG_Dh; w7iDv: $id = mysqli_insert_id($con); goto GZayR; YWzz8: return $r; goto wW7Dv; Nfmik: goto dXlY0; goto ONcD_; GZayR: DG5FJ: goto FbAlr; iG_Dh: $r = array(); goto WuP6F; jBIL5: $con = getConnection(); goto spgV9; oTab2: sv_mysqli_close($con); goto YWzz8; wW7Dv: } public static function simpleSelect($fields = "", $table = "", $conditions = "", $skip = 0, $limit = 15, $group = "") { goto mZJdk; XWFmh: $query .= " LIMIT {$skip}, {$limit} "; goto C5LSk; mZJdk: $query = "SELECT {$fields} FROM {$table}"; goto PmjBD; xkA6R: $query .= " WHERE {$conditions} "; goto mItz4; UAkYU: CX4ef: goto Z9RVY; arc5C: FZ3P_: goto v4wnS; mItz4: ZzgWn: goto A_7RG; uuyVZ: $query .= " GROUP BY {$group}"; goto zkCap; Hs1mr: if (!($group !== "")) { goto G0eqO; } goto uuyVZ; PmjBD: if (!($conditions !== "")) { goto ZzgWn; } goto xkA6R; GRIxH: return $query; goto Hvh5G; esLic: $query .= " OFFSET {$skip} "; goto UAkYU; gaUgd: RkpMB: goto vgrSg; Z9RVY: goto FZ3P_; goto gaUgd; C5LSk: eD8d5: goto Hs1mr; vgrSg: $query .= " LIMIT {$limit} "; goto arc5C; A_7RG: if ($limit > 0 && $skip > 0) { goto KD52U; } goto VsTNZ; rIseW: KD52U: goto XWFmh; VsTNZ: if ($limit > 0) { goto RkpMB; } goto CzpXC; CzpXC: if (!($skip > 0)) { goto CX4ef; } goto esLic; v4wnS: goto eD8d5; goto rIseW; zkCap: G0eqO: goto GRIxH; Hvh5G: } public static function insert($table = "", $values = array()) { goto ccxpt; ccxpt: $str_fields = ""; goto kfjlR; Z2jgh: FZASt: goto eW3f3; fcnnS: foreach ($values as $field => $value) { goto GuT7O; y6ovP: if ($str_values === "") { goto EO3gI; } goto AYV2a; MMLt0: if (is_string($value)) { goto pjnED; } goto y6ovP; OJhnR: pJGBU: goto MMLt0; oVgUi: EO3gI: goto W27Lm; FsFZo: goto pJGBU; goto Ml8Ry; Ovecd: gKB1D: goto b2Vs1; IJiM0: if ($str_values === "") { goto z5K_k; } goto gBAVL; QjIBQ: pjnED: goto IJiM0; CvaMx: $str_fields .= $field; goto OJhnR; GuT7O: if ($str_fields === "") { goto mSy67; } goto F94Or; KNGao: goto BnL0q; goto oVgUi; Nmuvh: goto u36z4; goto s2owo; s2owo: z5K_k: goto nEmWc; ngu0o: goto NU9ng; goto QjIBQ; vhMSZ: BnL0q: goto ngu0o; W27Lm: $str_values .= $value; goto vhMSZ; Ml8Ry: mSy67: goto CvaMx; nEmWc: $str_values .= "'" . limpia($value) . "'"; goto BKGFu; gBAVL: $str_values .= ",'" . limpia($value) . "'"; goto Nmuvh; F94Or: $str_fields .= ",{$field}"; goto FsFZo; GKK5F: NU9ng: goto Ovecd; BKGFu: u36z4: goto GKK5F; AYV2a: $str_values .= ",{$value}"; goto KNGao; b2Vs1: } goto Z2jgh; eW3f3: return "INSERT INTO {$table} ({$str_fields}) VALUES ({$str_values})"; goto EGCD1; kfjlR: $str_values = ""; goto fcnnS; EGCD1: } public static function update($table = "", $values = array(), $conditions = "") { goto WgrhK; f8DbY: $query .= " WHERE {$conditions} "; goto qDNsm; qDNsm: PPtBj: goto zkboO; Y0pQX: $query = "UPDATE {$table} SET {$str_values} "; goto ZRGkh; WgrhK: $str_values = ""; goto gtnTU; uz4QN: y0ppX: goto Y0pQX; ZRGkh: if (!($conditions !== "")) { goto PPtBj; } goto f8DbY; gtnTU: foreach ($values as $field => $value) { goto n0wOt; jSGQT: if (is_string($value)) { goto E5xyP; } goto eDLvK; bXN5l: NrJHN: goto BKBfa; eDLvK: $str_values .= ",{$field} = {$value}"; goto mu9bA; nOut4: E5xyP: goto pnW_p; WdKbP: goto t70lH; goto xRzWo; tIdsm: BR6mk: goto NNYA2; pnW_p: $str_values .= ",{$field} = '" . limpia($value) . "'"; goto SEOoN; tuTqI: Dxjl8: goto QBgfk; NA_3X: goto NrJHN; goto tuTqI; xRzWo: CZGvQ: goto TYdGt; mu9bA: goto LFZHq; goto nOut4; fHfJw: $str_values .= "{$field} = {$value}"; goto NA_3X; n0wOt: if ($str_values === "") { goto CZGvQ; } goto jSGQT; SEOoN: LFZHq: goto WdKbP; TYdGt: if (is_string($value)) { goto Dxjl8; } goto fHfJw; QBgfk: $str_values .= "{$field} = '" . limpia($value) . "'"; goto bXN5l; BKBfa: t70lH: goto tIdsm; NNYA2: } goto uz4QN; zkboO: return $query; goto ITmB0; ITmB0: } }