if (!isset($_GET['table']) || !isset($_GET['id'])) {
    return false;
}
$table = $c->_model->_changeDauNhay($_GET['table']);
$id = $c->_model->_changeDauNhay($_GET['id']);
$rowDetail = $c->_model->_viewDetail($table, $id);
$rowCourse = '';
if (isset($rowDetail['header_id'])) {
    $rowCourse = $c->_model->_viewDetail('web_header', $rowDetail['header_id']);
    $rowCourse = $rowCourse['name'];
}
$cA = new modelAdmin();
$cF = new controlAdminForm();
echo $cF->displayDiv('Email nhận', '<b class="label2 adMessage" id="email">' . $rowDetail['email'] . '</b>');
$name = 'type_id';
$values = $cA->_listTable('web_event_form', NULL, 'AND `type`=2 AND `type_id`=1');
array_unshift($values, array('name' => '-- chọn form --', 'id' => ''));
$data = $cF->select($name, $values, '', 'adInput adTxtMedium');
$other = '<p class="adError error" id="type_id_error"></p>';
echo $cF->displayDiv('Chọn form mẫu', $data . $other);
$name = 'price';
$properties = array();
$properties[] = array('propertie' => 'maxlength', 'value' => '9');
$properties[] = array('propertie' => 'placeholder', 'value' => 'Giá cá nhân khóa Public');
$data = $cF->inputText($name, '', 'adInput adTxtMedium', $properties);
echo $cF->displayDiv('Giá', $data);
$name = 'totalusd';
$properties = array();
$properties[] = array('propertie' => 'maxlength', 'value' => '8');
$properties[] = array('propertie' => 'placeholder', 'value' => 'Tổng cộng chi phí USD');
$data = $cF->inputText($name, '', 'adInput adTxtMedium', $properties);
Exemplo n.º 2
0
    foreach ($data as $row) {
        if ($row['id'] != $district_id) {
            echo '<option value="' . $row['id'] . '">' . $row['name'] . '</option>';
        } else {
            echo '<option value="' . $row['id'] . '" selected="selected">' . $row['name'] . '</option>';
        }
    }
    return true;
}
if (isset($_POST['searchID'])) {
    $code = $c->_model->_changeDauNhay($_POST['searchID']);
    $table = $c->_model->_changeDauNhay($_POST['table']);
    $ad = new modelAdmin();
    $data = $ad->_listTable($table, NULL, " AND `code`='{$code}' ");
    foreach ($data as $row) {
        echo $row['name'];
        return true;
    }
    return true;
}
if (isset($_POST['searchName'])) {
    $name = $c->_model->_changeDauNhay($_POST['searchName']);
    $table = $c->_model->_changeDauNhay($_POST['table']);
    $ad = new modelAdmin();
    $data = $ad->_listTable($table, NULL, "AND `name` LIKE '%{$name}%'");
    foreach ($data as $row) {
        echo '<p class="value_data" id="' . $row['code'] . '">' . $row['name'] . '</p>';
    }
    return true;
}
/*end other*/
Exemplo n.º 3
0
    $name = $c->_model->_changeDauNhay($_POST['searchName']);
    $table = $c->_model->_changeDauNhay($_POST['table']);
    if (isset($_POST['limit'])) {
        $limit = $c->_model->_changeDauNhay($_POST['limit']);
    } else {
        $limit = 20;
    }
    $where = '';
    //if($table=='web_header') $where .= " AND `properties`=2 ";
    $ad = new modelAdmin();
    $where .= "AND `name` LIKE '%{$name}%'";
    $order = NULL;
    if ($table == 'mn_class') {
        $order = '`name` DESC';
    }
    $data = $ad->_listTable($table, $order, $where, $limit);
    foreach ($data as $row) {
        echo '<p class="value_data" id="' . $row['id'] . '" title="Click để chọn">' . $row['name'] . '</p>';
    }
    return true;
}
if (isset($_POST['formType'])) {
    $type = $c->_model->_changeDauNhay($_POST['type']);
    $type_id = $c->_model->_changeDauNhay($_POST['type_id']);
    if ($type == 1) {
        $cA = new modelAdmin();
        $data = $cA->_webTypeList(1);
        array_unshift($data, array('name' => '-- chọn form mẫu --', 'id' => ''));
        foreach ($data as $row) {
            if ($row['id'] != $type_id) {
                $str = '';
Exemplo n.º 4
0
    }
    return true;
}
if (isset($_POST['searchName'])) {
    $name = $c->_model->_changeDauNhay($_POST['searchName']);
    $table = $c->_model->_changeDauNhay($_POST['table']);
    if (isset($_POST['limit'])) {
        $limit = $c->_model->_changeDauNhay($_POST['limit']);
    } else {
        $limit = 20;
    }
    $where = '';
    //if($table=='web_header') $where .= " AND `properties`=2 ";
    $ad = new modelAdmin();
    $where .= "AND `name` LIKE '%{$name}%'";
    $data = $ad->_listTable($table, NULL, $where, $limit);
    foreach ($data as $row) {
        echo '<p class="value_data" id="' . $row['id'] . '" title="Click để chọn">' . $row['name'] . '</p>';
    }
    return true;
}
if (isset($_POST['formType'])) {
    $type = $c->_model->_changeDauNhay($_POST['type']);
    $type_id = $c->_model->_changeDauNhay($_POST['type_id']);
    if ($type == 1) {
        $cA = new modelAdmin();
        $data = $cA->_webTypeList(1);
        array_unshift($data, array('name' => '-- chọn form mẫu --', 'id' => ''));
        foreach ($data as $row) {
            if ($row['id'] != $type_id) {
                $str = '';