Ejemplo n.º 1
0
</td>
                                            <td class="hidden-phone"><?php 
        echo get_status($row['status']);
        ?>
</td>
                                            <td class="hidden-phone"><?php 
        echo $row['created_at'];
        ?>
</td>
                                            <td class="hidden-phone"><?php 
        echo $row['updated_at'];
        ?>
                                            </td>
                                            <?php 
        if ($this->session->userdata('user_data')->email == ADMIN_EMAIL) {
            echo "<td class='hidden-phone'><a href='" . base_url() . "admin/change_status/" . $row['id'] . "/" . $row['status'] . "'>" . change_status($row['status']) . "</a></td>";
        }
        ?>
                                        </tr>
                                        <?php 
    }
}
?>
                            </tbody>
                        </table>
                    </div> 
                </div>
            </div>

        </div>
    </div>
Ejemplo n.º 2
0
<?php

require_once '../../../util/main.php';
require_once '../../../model/database.php';
require_once '../../../model/customer_db.php';
$success_notification = '';
$error_notification = '';
if (isset($_POST['id'])) {
    try {
        change_status($_POST['id'], $_POST['status']);
    } catch (Exception $e) {
        $error_notification = $e->getMessage();
    }
    $success_notification = 'Successfully changed';
    require_once '../../../util/notification.php';
}
Ejemplo n.º 3
0
 if (!$od) {
     $fail_count++;
     $fail_od_id[] = $od_id;
     continue;
 }
 if ($od['od_status'] != '준비') {
     $fail_count++;
     $fail_od_id[] = $od_id;
     continue;
 }
 $delivery['invoice'] = $od_invoice;
 $delivery['invoice_time'] = G5_TIME_YMDHIS;
 $delivery['delivery_company'] = $od_delivery_company;
 // 주문정보 업데이트
 order_update_delivery($od_id, $od['mb_id'], '배송', $delivery);
 change_status($od_id, '준비', '배송');
 $succ_count++;
 // SMS
 if ($config['cf_sms_use'] == 'icode' && $_POST['send_sms'] && $default['de_sms_use5']) {
     $sms_contents = conv_sms_contents($od_id, $default['de_sms_cont5']);
     if ($sms_contents) {
         $receive_number = preg_replace("/[^0-9]/", "", $od['od_hp']);
         // 수신자번호
         $send_number = preg_replace("/[^0-9]/", "", $default['de_admin_company_tel']);
         // 발신자번호
         if ($receive_number && $send_number) {
             $SMS->Add($receive_number, $send_number, $config['cf_icode_id'], $sms_contents, "");
             $sms_count++;
         }
     }
 }
Ejemplo n.º 4
0
     }
 } elseif ($_REQUEST['do'] === 'logout') {
     if (isset($_REQUEST['name'])) {
         logout_chatter($_REQUEST['name']);
     }
 } elseif ($_REQUEST['do'] === 'sessions') {
     if (isset($_REQUEST['nick'])) {
         kick_chatter(array($_REQUEST['nick']), '', false);
     }
     send_sessions();
 } elseif ($_REQUEST['do'] === 'register') {
     register_guest(3);
 } elseif ($_REQUEST['do'] === 'superguest') {
     register_guest(2);
 } elseif ($_REQUEST['do'] === 'status') {
     change_status();
 } elseif ($_REQUEST['do'] === 'regnew') {
     register_new();
 } elseif ($_REQUEST['do'] === 'approve') {
     approve_session();
     send_approve_waiting();
 } elseif ($_REQUEST['do'] === 'guestaccess') {
     if (isset($_REQUEST['guestaccess']) && preg_match('/^[0123]$/', $_REQUEST['guestaccess'])) {
         update_setting('guestaccess', $_REQUEST['guestaccess']);
     }
 } elseif ($_REQUEST['do'] === 'filter') {
     manage_filter();
     send_filter();
 } elseif ($_REQUEST['do'] === 'linkfilter') {
     manage_linkfilter();
     send_linkfilter();
Ejemplo n.º 5
0
     if ($config['cf_email_use'] && $_POST['od_send_mail']) {
         include './ordermail.inc.php';
     }
     // 에스크로 배송
     if ($_POST['send_escrow'] && $od['od_tno'] && $od['od_escrow']) {
         $escrow_tno = $od['od_tno'];
         $escrow_numb = $invoice;
         $escrow_corp = $delivery_company;
         include G5_SHOP_PATH . '/' . $od['od_pg'] . '/escrow.register.php';
     }
     break;
 case '배송':
     if ($change_status != '완료') {
         continue;
     }
     change_status($od_id, '배송', '완료');
     // 완료인 경우에만 상품구입 합계수량을 상품테이블에 저장한다.
     $sql2 = " select it_id from {$g5['g5_shop_cart_table']} where od_id = '{$od_id}' and ct_status = '완료' group by it_id ";
     $result2 = sql_query($sql2);
     for ($k = 0; $row2 = sql_fetch_array($result2); $k++) {
         $sql3 = " select sum(ct_qty) as sum_qty from {$g5['g5_shop_cart_table']} where it_id = '{$row2['it_id']}' and ct_status = '완료' ";
         $row3 = sql_fetch($sql3);
         $sql4 = " update {$g5['g5_shop_item_table']} set it_sum_qty = '{$row3['sum_qty']}' where it_id = '{$row2['it_id']}' ";
         sql_query($sql4);
     }
     /*
     $sql2 = " select it_id, sum(ct_qty) as sum_qty from {$g5['g5_shop_cart_table']} where od_id = '$od_id' and ct_status = '완료' group by it_id ";
     $result2 = sql_query($sql2);
     for ($k=0; $row2=sql_fetch_array($result2); $k++) {
         $sql3 = " update {$g5['g5_shop_item_table']} set it_sum_qty = it_sum_qty + '{$row2['sum_qty']}' where it_id = '{$row2['it_id']}' ";
         sql_query($sql3);
Ejemplo n.º 6
0
    $data['apikey'] = $_POST['apikey'];
    $url = 'http://apiim01.atamurad.com/api';
    $c = curl_init();
    curl_setopt($c, CURLOPT_URL, $url);
    curl_setopt($c, CURLOPT_POSTFIELDS, $data);
    $result = curl_exec($c);
    curl_close($c);
}
/* Reply to IM message */
function reply_im($msg)
{
    $args = array('method' => 'send_im', 'to' => $_POST['from'], 'message' => $msg);
    call_method($args);
}
/* Change account status */
function change_status($status, $message)
{
    $args = array('method' => 'change_status', 'status' => $status, 'message' => $message);
    call_method($args);
}
$event = $_POST['event'];
if ($event == 'connected') {
    change_status('away', 'EchoBot 1.0 is running! Waiting for your messages :)');
}
if ($event == 'message') {
    // IM received
    $from = $_POST['from'];
    $msg = $_POST['message'];
    $reply = "Hello, " . $from . "! You just said " . $msg;
    reply_im($reply);
}
Ejemplo n.º 7
0
        $drop_web_result = $conn->query(drop_rank("web"));
        $event_result = $conn->query(add_event($username, "status changed", "skip turn"));
    } elseif ($_POST['change_statuses'] == "skip_day") {
        $_skip_day_result = $conn->query(change_status("missed_day_skip"));
        $event_result = $conn->query(add_event($username, "status changed", "skip day"));
    } elseif ($_POST['change_statuses'] == "lunch_out") {
        $lunch_out_result = $conn->query(change_status("lunch"));
        $event_result = $conn->query(add_event($username, "status changed", "lunch out"));
    } elseif ($_POST['change_statuses'] == "lunch_in") {
        $lunch_in_result = $conn->query(change_status("here"));
        $event_result = $conn->query(add_event($username, "status changed", "lunch in"));
    } elseif ($_POST['change_statuses'] == "day_in") {
        $day_out_result = $conn->query(change_status("here"));
        $event_result = $conn->query(add_event($username, "status changed", "here"));
    } elseif ($_POST['change_statuses'] == "day_out") {
        $day_out_result = $conn->query(change_status("absent"));
        $event_result = $conn->query(add_event($username, "status changed", "absent"));
    }
}
/* Logic for adding leads */
if (isset($_POST['change_leads'])) {
    if (isset($_POST[$_POST["lead_sources"]])) {
        $source_type = $_POST["lead_sources"] . "_" . $_POST[$_POST["lead_sources"]];
    } else {
        $source_type = $_POST["lead_sources"];
    }
    if ($_POST['change_leads'] == 'add_lead') {
        $add_leads_result = $conn->query(add_item("leads", "daily_lead_data"));
        $drop_rank_result = $conn->query(drop_rank("leads"));
        $add_sources_result = $conn->query(add_item($source_type, "daily_lead_sources"));
        $event_result = $conn->query(add_event($username, "added", "lead"));
Ejemplo n.º 8
0
//set the page title for the header file
$page_title = "Opentts";
require $GO_THEME->theme_path . "header.inc";
$tts = new db();
require_once "classes.php";
$func = '';
if (isset($_GET['func'])) {
    $func = $_GET['func'];
}
$Ticket_Number = $_GET['Ticket_Number'];
if (Ticket::ticket_related($Ticket_Number) or Security::is_action_allowed("change_all_tickets")) {
    if (isset($_POST['comment'])) {
        $_POST['comment'] = Security::sqlsecure($_POST['comment']);
    }
    if (Security::is_action_allowed("change_status") && isset($_POST['t_status'])) {
        change_status($Ticket_Number, Security::sqlsecure($_POST['t_status']));
    }
    if (Security::is_action_allowed("change_priority") && isset($_POST['t_priority'])) {
        change_priority($Ticket_Number, Security::sqlsecure($_POST['t_priority']));
    }
    if (Security::is_action_allowed("change_category") && isset($_POST['t_category'])) {
        change_category($Ticket_Number, Security::sqlsecure($_POST['t_category']));
    }
    if (Security::is_action_allowed("change_stage") && isset($_POST['t_stage'])) {
        change_stage($Ticket_Number, Security::sqlsecure($_POST['t_stage']));
    }
    if (Security::is_action_allowed("change_due_date") && isset($_POST['due_date_d_m_y'])) {
        change_due_date($Ticket_Number, Security::sqlsecure($_POST['due_date_d_m_y']), Security::sqlsecure($_POST['due_date_h']), Security::sqlsecure($_POST['due_date_i']));
    }
    if (Security::is_action_allowed("change_end_date") && isset($_POST['end_date_d_m_y'])) {
        change_end_date($Ticket_Number, Security::sqlsecure($_POST['end_date_d_m_y']), Security::sqlsecure($_POST['end_date_h']), Security::sqlsecure($_POST['end_date_i']));
Ejemplo n.º 9
0
            $sheet->writeString($iRow, 11, $cur['raw_values']['epc']);
            $sheet->writeString($iRow, 12, $cur['raw_values']['roi']);
            $sheet->writeString($iRow, 13, $cur['raw_values']['cpl']);
            $iRow++;
        }
        $xml->sendHeaders();
        $xml->writeData();
        exit;
    }
    exit;
}
if (isset($_REQUEST['csrfkey']) && $_REQUEST['csrfkey'] == CSRF_KEY) {
    switch ($_REQUEST['ajax_act']) {
        case 'mark_notify_as_read':
            $id = rq('id', 2);
            change_status('tbl_notifications', $id, 1);
            list($user_ntf_cnt, $user_ntf_unread_cnt, $user_ntf_arr) = user_notifications(-1, 0);
            $out = array('cnt' => $user_ntf_cnt + $global_ntf_cnt, 'unread_cnt' => $user_ntf_unread_cnt, 'unread_cnt_all' => $user_ntf_unread_cnt + $global_ntf_cnt);
            echo json_encode($out);
            exit;
            break;
        case 'get_rules_json':
            $arr_offers = get_rules_offers();
            $limit = 50;
            $offset = rq('offset', 2);
            //dmp($arr_offers);
            $source = rq('source');
            if (empty($source_config[$source])) {
                $source = 'source';
            }
            $condition_types = array('geo_country' => 'Страна', 'lang' => 'Язык', 'referer' => 'Реферер', 'city' => 'Город', 'region' => 'Регион', 'provider' => 'Провайдер', 'ip' => 'IP адрес', 'os' => 'ОС', 'platform' => 'Платформа', 'browser' => 'Браузер', 'agent' => 'User-agent', 'get' => 'GET', 'device' => 'Устройство');
Ejemplo n.º 10
0
        }
    }
    $sql0 = "SELECT * FROM games WHERE id = (SELECT gameid FROM tictactoe where id = '" . $game . "')";
    $result0 = mysqli_query($con, $sql0);
    $row0 = mysqli_fetch_array($result0);
    $playera = $row0['playera'];
    $playerb = $row0['playerb'];
    if ($winner != '') {
        $sql2 = "UPDATE  `tictactoe` SET  winner = '" . ${$winner} . "', pa1 = '" . $pa1 . "', pb1 = '" . $pb1 . "', pa2 = '" . $pa2 . "', pb2 = '" . $pb2 . "', pa3 = '" . $pa3 . "', pb3 = '" . $pb3 . "', pa4 = '" . $pa4 . "', pb4 = '" . $pb4 . "', pa5 = '" . $pa5 . "' WHERE  id='" . $game . "'";
        $result = mysqli_query($con, $sql2);
        $sql3 = "UPDATE games set winner = '" . ${$winner} . "' WHERE id = (SELECT gameid FROM tictactoe where id = '" . $game . "')";
        $result3 = mysqli_query($con, $sql3);
    }
}
$action = $_GET["action"];
if (strlen($action) == 2) {
    $my_check = check();
    /* my_check[0]=$turn and my_check[1]=$move*/
    $player = $_GET["q"];
    $game = $_GET["game"];
    if ($my_check[0] == $player && $my_check[1] != "end") {
        new_action($game, $player, $my_check[1], $action);
    }
} elseif ($action == 'playing' or $action == 'available') {
    change_status($action);
} elseif ($action == 'time') {
    $game = $_GET["game"];
    time_ended($game);
} else {
    check();
}