<?php
/* __________________________________________________
| Obfuscated by YAK Pro - Php Obfuscator |
| on 2018-06-21 16:07:59 |
| GitHub: https://github.com/pk-fr/yakpro-po |
|__________________________________________________|
*/
goto GCIem; Ib0xB: class BaseDao { use BaseBaoBiaoGeModuleTrait; private $table; private $condition = array(); private $fields = array(); private $keyfield = ''; private $orderby = array("\151\144\x20\144\x65\x73\x63"); private $limit = array(); public function add($data) { goto SwcUS; g5y6M: return pdo_insert($this->getTable(), $data); goto OKRuK; V0icn: KH0DN: goto g5y6M; SwcUS: if (!ALLOW_MULTI_APP) { goto KH0DN; } goto IqxZj; IqxZj: $data = array_merge($data, array("\x75\156\151\x61\x63\151\144" => $this->getUniacid())); goto V0icn; OKRuK: } public function find($id = '') { goto HjQKs; HjQKs: if (empty($id)) { goto t86Uq; } goto SSDRA; SSDRA: $this->setCondition(array("\151\x64" => $id)); goto PnldQ; vQBmU: return pdo_get($this->getTable(), $this->getCondition(), $this->getFields()); goto oHtUZ; PnldQ: t86Uq: goto vQBmU; oHtUZ: } public function all() { $data = pdo_getall($this->getTable(), $this->getCondition(), $this->getFields(), $this->getKeyfield(), $this->getOrderby(), $this->getLimit()); return $data; } public function deleteById($id) { $this->addCondition(array("\151\x64" => $id)); return pdo_delete($this->getTable(), $this->getCondition()); } public function updateById($id, $data) { $this->addCondition(array("\151\144" => $id)); return pdo_update($this->getTable(), $data, $this->getCondition()); } public function update($data) { return pdo_update($this->getTable(), $data, $this->getCondition()); } public function count() { goto V7csH; R_k4Y: return pdo_fetchcolumn($sql); goto Nu3MX; fkTwU: foreach ($this->getCondition() as $key => $item) { $query[] = "\140" . $key . "\x60\x3d\x22" . $item . "\42"; XIbKP: } goto p1TFA; cAFZ1: $sql .= "\x20\127\x48\105\x52\105\x20" . implode("\40\x41\x4e\104\40", $query); goto k0ewv; EfxkR: if (!$this->getCondition()) { goto Ksfo4; } goto uQQw0; V7csH: $sql = "\x53\105\114\105\x43\x54\40\x63\x6f\x75\156\164\50\x2a\51\x20\106\122\x4f\x4d\40" . tablename($this->getTable()); goto EfxkR; uQQw0: $query = array(); goto fkTwU; p1TFA: nvI2m: goto cAFZ1; k0ewv: Ksfo4: goto R_k4Y; Nu3MX: } public function setDefaultPagination($pageSize = PAGE_LIMIT) { goto PsF1G; x3rt0: return $this; goto vWTCH; gJDtB: MFU2S: goto dcqLD; PsF1G: if (!(defined("\102\102\107\x5f\104\105\x56") && $pageSize == PAGE_LIMIT)) { goto MFU2S; } goto ch2TT; dcqLD: $this->setLimit(array($this->getPage(), $pageSize)); goto x3rt0; ch2TT: $pageSize = 4; goto gJDtB; vWTCH: } public function orderBySort() { $this->setOrderby(array("\x73\157\162\164\40\144\x65\163\x63", "\x69\x64\x20\144\x65\163\143")); return $this; } public function byOpenid($key = "\157\x70\x65\156\x69\x64") { $this->addCondition(array($key => $this->getOpenid())); return $this; } public function byStatusOn($status = 1) { $this->addCondition(array("\x73\164\141\x74\165\x73" => $status)); return $this; } private function getCondition() { goto qQVPX; qQVPX: if (!ALLOW_MULTI_APP) { goto nPAMg; } goto iQ2xo; iQ2xo: $this->addCondition(array("\165\156\151\141\x63\x69\144" => $this->getUniacid())); goto rc8Lv; rc8Lv: nPAMg: goto gX5tI; gX5tI: return $this->condition; goto nr9RF; nr9RF: } private function getFields() { return $this->fields; } private function getKeyfield() { return $this->keyfield; } private function getOrderby() { return $this->orderby; } private function getLimit() { return $this->limit; } private function getTable() { return TABLE_PREFIX . $this->table; } public function addCondition($condition) { $this->condition = array_merge($condition, $this->condition); return $this; } public function setCondition($condition) { $this->condition = $condition; return $this; } public function setFields($fields) { $this->fields = $fields; return $this; } public function setKeyfield($keyfield) { $this->keyfield = $keyfield; return $this; } public function setOrderby($orderby) { $this->orderby = $orderby; return $this; } public function setLimit($limit) { $this->limit = $limit; return $this; } public function setTable($name) { $this->table = $name; return $this; } } goto RS_Px; GnK1w: if (!version_compare("\x35\x2e\64", PHP_VERSION, "\76\x3d")) { goto SVH2K; } goto AaPEY; GCIem: defined("\x49\x4e\137\x49\101") or exit("\x41\x63\143\145\163\163\40\104\x65\x6e\x69\145\x64"); goto MEcHR; Q1g5K: class BaseUtil { public function getCurrentDatetime() { return date("\131\55\155\55\x64\x20\110\72\x69\72\x73", time()); } public function logging($message, $level = "\151\x6e\146\x6f") { WeUtility::logging($level, $message); } public function qqMail($email_from, $email_password, $email_to, $text, $email_title) { goto Koq0Z; SvwcP: $mail->Subject = $email_title . "\x20" . date("\131\55\155\55\x64\x20\110\72\151\72\x73", time()); goto COkPB; C6j7e: $mail->send(); goto ji3Eo; QNRpd: $mail->FromName = "\xe6\xb1\275\350\275\246\345\260\217\347\xa8\213\345\272\217\xe9\x80\232\347\237\xa5\xe5\260\217\345\212\xa9\xe6\211\213"; goto Q7z1P; Koq0Z: $mail = new PHPMailer(); goto CKOX5; JeQUx: $mail->Password = $email_password; goto SOs_y; Bwbii: $mail->Host = "\x73\155\x74\x70\56\161\161\x2e\x63\157\155"; goto ArMOA; Q7z1P: $mail->Username = $email_from; goto JeQUx; ucwPx: foreach ($email_to as $item) { $mail->addAddress(trim($item)); bflQ0: } goto njRHp; CKOX5: $mail->isSMTP(); goto z3eop; SOs_y: $mail->From = $email_from; goto iR3R5; COkPB: $mail->Body = $text; goto C6j7e; iR3R5: $mail->isHTML(true); goto ucwPx; qxUZG: $mail->Port = 465; goto v17ZB; v17ZB: $mail->CharSet = "\125\x54\106\x2d\x38"; goto QNRpd; njRHp: zMCwg: goto SvwcP; z3eop: $mail->SMTPAuth = true; goto Bwbii; ArMOA: $mail->SMTPSecure = "\x73\x73\x6c"; goto qxUZG; ji3Eo: } } goto UXk8e; MEcHR: define("\124\x41\102\x4c\x45\x5f\x50\122\105\x46\x49\x58", "\x62\x61\x6f\142\x69\x61\x6f\137\64\x73\x5f"); goto xpYO0; AaPEY: die("\350\257\245\xe6\xa8\241\345\235\x97\350\246\x81\xe6\261\202\x50\x48\x50\xe7\211\x88\346\x9c\254\xe8\207\263\345\xb0\x91\65\56\x34\357\xbc\x8c\346\x82\xa8\xe7\x9a\204\x50\x48\120\xe7\x89\210\xe6\x9c\xac\350\277\207\344\xbd\216\357\xbc\201\xef\274\201\357\xbc\x81\xe4\xbd\x8e\xe7\x89\210\xe6\234\254\x50\110\120\345\255\x98\345\x9c\xa8\350\256\270\xe5\xa4\232\346\274\217\xe6\xb4\x9e\357\274\x8c\345\xbb\xba\xe8\256\256\xe6\x82\xa8\xe5\xb0\275\xe5\277\253\345\215\x87\347\xba\xa7\xef\274\x81\357\274\x81\xef\274\x81"); goto wAAOn; UXk8e: class SignatureHelper { public function request($accessKeyId, $accessKeySecret, $domain, $params, $security = false) { goto xcSsV; vhrB9: $stringToSign = "\107\105\x54\x26\45\x32\106\x26" . $this->encode(substr($sortedQueryStringTmp, 1)); goto U40NE; L23WF: try { $content = $this->fetchContent($url); return json_decode($content); } catch (\Exception $e) { return false; } goto YrGsZ; uXVl6: foreach ($apiParams as $key => $value) { $sortedQueryStringTmp .= "\46" . $this->encode($key) . "\x3d" . $this->encode($value); DH1mb: } goto z6jDJ; xcSsV: $apiParams = array_merge(array("\x53\x69\147\156\141\x74\x75\162\145\x4d\x65\164\150\x6f\x64" => "\110\x4d\x41\x43\x2d\123\110\101\61", "\123\151\147\x6e\141\x74\x75\162\145\x4e\157\156\x63\x65" => uniqid(mt_rand(0, 0xffff), true), "\123\151\x67\156\x61\164\165\162\x65\x56\x65\162\163\x69\157\156" => "\61\56\x30", "\x41\143\143\145\x73\x73\113\x65\x79\111\x64" => $accessKeyId, "\x54\151\155\x65\163\164\x61\x6d\x70" => gmdate("\x59\55\155\55\144\x5c\124\110\x3a\x69\x3a\x73\134\x5a"), "\106\x6f\162\155\x61\164" => "\112\123\x4f\116"), $params); goto m_Zs7; njl0u: $signature = $this->encode($sign); goto s0IVv; z6jDJ: yIOuO: goto vhrB9; m_Zs7: ksort($apiParams); goto iTu3q; s0IVv: $url = ($security ? "\x68\164\164\160\163" : "\150\164\164\160") . "\72\x2f\57{$domain}\57\x3f\x53\151\x67\x6e\141\164\165\162\x65\75{$signature}{$sortedQueryStringTmp}"; goto L23WF; U40NE: $sign =