当前位置: 首页>>代码示例>>PHP>>正文


PHP Backend::getDetail方法代码示例

本文整理汇总了PHP中Backend::getDetail方法的典型用法代码示例。如果您正苦于以下问题:PHP Backend::getDetail方法的具体用法?PHP Backend::getDetail怎么用?PHP Backend::getDetail使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Backend的用法示例。


在下文中一共展示了Backend::getDetail方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: Backend

<?php

$id = 0;
$is_detail = false;
if (isset($_GET['id'])) {
    $id = (int) $_GET['id'];
    require_once "model/Backend.php";
    $model = new Backend();
    $detail = $model->getDetail("pages", $id);
    $is_detail = true;
}
?>
<div class="row">
    <div class="col-md-12">
        <section class="content-header">     
          <ol class="breadcrumb">
            <li><a href="index.php"><i class="fa fa-dashboard"></i> Dashboard</a></li>
            <li><a href="index.php?mod=pages&act=list">Trang nội dung</a></li>              
          </ol>
        </section>
        <!-- Custom Tabs -->
        <button class="btn btn-primary btn-sm" onclick="location.href='index.php?mod=pages&act=list'">
            Danh sách
        </button>
        <div style="clear:both;margin-bottom:10px"></div>

        <div class="box box-primary">
            <div class="box-header">
                <h2 class="box-title" style="text-tranform:uppercase !important;color: #B10007">
                    <?php 
echo $id > 0 ? "Cập nhật" : "Tạo mới";
开发者ID:hoangnhonline,项目名称:hoa-tuoi,代码行数:31,代码来源:form.php

示例2: isset

<?php

require_once "model/Backend.php";
$model = new Backend();
$link = "index.php?mod=page&act=list";
$detail = array();
if (isset($_GET['id'])) {
    $id = (int) $_GET['id'];
    $data = $model->getDetail("pages", $id);
}
?>
<div class="row">
    <div class="col-md-12">
        <button class="btn btn-primary btn-sm" onclick="location.href='index.php?mod=page&act=list'">Danh sách</button>
        <form method="post"  action="controller/Page.php" enctype="multipart/form-data">

        <div class="col-md-6">

            <!-- Custom Tabs -->

            <div style="clear:both;margin-bottom:10px"></div>

            <div class="box-header">

                <h3 class="box-title"><?php 
echo isset($id) && $id > 0 ? "Cập nhật" : "Tạo mới";
?>
 
                    trang 
                    <?php 
echo isset($id) && $id > 0 ? " : " . $data['page_name'] : "";
开发者ID:hoangnhonline,项目名称:phong-tro-sg,代码行数:31,代码来源:form.php

示例3: isset

<?php

if ($_SESSION['level'] == 1) {
    $user_id = isset($_GET['user_id']) ? (int) $_GET['user_id'] : -1;
} else {
    $user_id = $_SESSION['user_id'];
}
require_once "model/Backend.php";
$model = new Backend();
$link = "index.php?mod=doanhthu&act=list";
$detail = array();
if (isset($_GET['house_id']) && $_GET['house_id'] > 0) {
    $house_id = (int) $_GET['house_id'];
    $detail = $model->getDetail('house', $house_id);
} else {
    $house_id = -1;
}
$month = isset($_GET['month']) ? (int) $_GET['month'] : -1;
$year = isset($_GET['year']) ? (int) $_GET['year'] : -1;
if ($_SESSION['level'] == 1) {
    $user_id = -1;
} else {
    $user_id = $_SESSION['user_id'];
}
$arrList = $model->getChiPhiTotalHouse($house_id, $user_id, $month, $year);
$modArr = $model->getList('users', -1, -1, array('level' => 2));
/* get list house */
$arrCustom = array('type' => 1);
if ($_SESSION['level'] == 1) {
    $arrCustom['user_id'] = -1;
} else {
开发者ID:hoangnhonline,项目名称:bds-sth,代码行数:31,代码来源:list-chi-phi.php

示例4: Backend

<?php

$id = 0;
if (isset($_GET['id'])) {
    $id = (int) $_GET['id'];
    require_once "model/Backend.php";
    $model = new Backend();
    $detail = $model->getDetail("convenient", $id);
}
?>
<div class="row">
    <div class="col-md-8">

        <!-- Custom Tabs -->
        <button class="btn btn-primary btn-sm" onclick="location.href='index.php?mod=convenient&act=list'">Danh sách</button>
        <div style="clear:both;margin-bottom:10px"></div>

        <div class="box box-primary">
            <div class="box-header">
                <h3 class="box-title"><?php 
echo $id > 0 ? "Cập nhật" : "Thêm mới";
?>
 tiện nghi</h3>

            </div><!-- /.box-header -->
            <!-- form start -->
            <form role="form" method="post" action="controller/Convenient.php" enctype="multipart/form-data">
                <?php 
if ($id > 0) {
    ?>
                <input type="hidden" value="<?php 
开发者ID:hoangnhonline,项目名称:bds-sth,代码行数:31,代码来源:form.php

示例5: isset

<?php

$id = 0;
if (isset($_GET['id'])) {
    $id = (int) $_GET['id'];
    require_once "model/Backend.php";
    $model = new Backend();
    $data = $model->getDetail("seo", $id);
}
?>
<div class="row">
    <div class="col-md-12" >
        <button class="btn btn-primary btn-sm" onclick="location.href='index.php?mod=seo&act=list'">SEO List</button>
        <form method="post"  action="controller/Seo.php" enctype="multipart/form-data">

        <div class="col-md-10" style="background-color:#FFF">

            <!-- Custom Tabs -->

            <div style="clear:both;margin-bottom:10px"></div>

            <div class="box-header">

                <h3 class="box-title"><?php 
echo isset($id) && $id > 0 ? "Update SEO info " : "Tạo mới";
?>
                      
                    <?php 
echo isset($id) && $id > 0 ? " : " . $data['page_name'] : "";
?>
</h3>
开发者ID:hoangnhonline,项目名称:bds-sth,代码行数:31,代码来源:form.php

示例6: Backend

<?php

if (isset($_GET['id'])) {
    $id = (int) $_GET['id'];
    $contract_id = (int) $_GET['contract_id'];
    require_once "model/Backend.php";
    $model = new Backend();
    $detail = $model->getDetail("doanh_thu", $id);
    $detailHD = $model->getDetail('contract', $contract_id);
    $object_type = $detailHD['object_type'];
    $object_id = $detailHD['object_id'];
    if ($object_type == 1) {
        $detailObject = $model->getDetail('objects', $object_id);
        $house_id = $detailObject['house_id'];
        $arrServiceHouse = $model->getHouseServices($house_id);
        $conArr = $model->getList('convenient', -1, -1);
        $conArr = $conArr['data'];
        //var_dump("<pre>", $arrServiceHouse);
    }
    $arrPriceDT = $model->getDoanhThuThang($id, 1);
    $arrServiceDT = $model->getDoanhThuThang($id, 2);
    $arrConvenientDT = $model->getDoanhThuThang($id, 3);
    $arrService = $model->getList('services', -1, -1);
    $arrCon = $model->getList('convenient', -1, -1);
    $haveDoanhThu = $model->checkDoanhThu($contract_id);
    $serviceSelectedArr = $model->getContractService($contract_id);
    $conSelectedArr = $model->getContractCon($contract_id);
}
?>
<div class="row">
    <div class="col-md-8">
开发者ID:hoangnhonline,项目名称:phong-tro-sg,代码行数:31,代码来源:edit.php

示例7: Backend

<?php

$id = 0;
if (isset($_GET['id'])) {
    $id = (int) $_GET['id'];
    require_once "model/Backend.php";
    $model = new Backend();
    $detailEvent = $model->getDetail("events", $id);
    $imageArr = $model->getChild("images", "object_id", $id, 2);
    $lichArr = $model->getChild("event_content", "event_id", $id);
    if (!empty($lichArr)) {
        foreach ($lichArr as $key => $value) {
            $dayArr['content_vi'][$value['days']][] = $value['content_vi'];
            $dayArr['content_en'][$value['days']][] = $value['content_en'];
        }
    }
}
?>
<div class="row">
    <div class="col-md-12">

        <!-- Custom Tabs -->
        <button class="btn btn-primary btn-sm" onclick="location.href='index.php?mod=event&act=list'">LIST</button>
        <div style="clear:both;margin-bottom:10px"></div>

        <div class="box box-primary">
            <div class="box-header">
                <h2 class="box-title" style="text-tranform:uppercase !important;color: #B10007">
                    LỊCH TRÌNH EVENT : <?php 
echo $detailEvent['name_vi'];
?>
开发者ID:hoangnhonline,项目名称:hoa-tuoi,代码行数:31,代码来源:lichtrinh_sua.php

示例8: Backend

<?php

$id = 0;
if (isset($_GET['id'])) {
    $id = (int) $_GET['id'];
    $contract_id = (int) $_GET['contract_id'];
    require_once "model/Backend.php";
    $model = new Backend();
    $detail = $model->getDetail("doanh_thu", $id);
    $detailHD = $model->getDetail('contract', $contract_id);
    $arrPriceDT = $model->getDoanhThuThang($id, 1);
    $arrServiceDT = $model->getDoanhThuThang($id, 2);
    $arrConvenientDT = $model->getDoanhThuThang($id, 3);
    $arrService = $model->getList('services', -1, -1);
    $arrCon = $model->getList('convenient', -1, -1);
}
?>
<div class="row">   
   
    <div class="col-md-12">

        <!-- Custom Tabs -->

        <button class="btn btn-default btn-sm" onclick="location.href='index.php?mod=doanhthu&act=list&contract_id=<?php 
echo $contract_id;
?>
'">Quay lại</button>
        <?php 
if ($detailHD['status'] == 1) {
    ?>
        <button class="btn btn-primary btn-sm" onclick="location.href='index.php?mod=doanhthu&act=form&id=<?php 
开发者ID:hoangnhonline,项目名称:bds-sth,代码行数:31,代码来源:view.php

示例9: Backend

<?php

$id = 0;
if (isset($_GET['id'])) {
    $id = (int) $_GET['id'];
    require_once "model/Backend.php";
    $model = new Backend();
    $detail = $model->getDetail("expense", $id);
}
?>
<div class="row">
    <div class="col-md-8">

        <!-- Custom Tabs -->
        <button class="btn btn-primary btn-sm" onclick="location.href='index.php?mod=expense&act=list'">Danh sách</button>
        <div style="clear:both;margin-bottom:10px"></div>

        <div class="box box-primary">
            <div class="box-header">
                <h3 class="box-title"><?php 
echo $id > 0 ? "Cập nhật" : "Tạo mới";
?>
 loại chi phí</h3>

            </div><!-- /.box-header -->
            <!-- form start -->
            <form role="form" method="post" action="controller/Expense.php">
                <?php 
if ($id > 0) {
    ?>
                <input type="hidden" value="<?php 
开发者ID:hoangnhonline,项目名称:phong-tro-sg,代码行数:31,代码来源:form.php

示例10: Backend

$model = new Backend();
$link = $link_back = "index.php?mod=articles&act=list";
$link_form = "index.php?mod=articles&act=form";
if (isset($_GET['name_vi']) && $_GET['name_vi'] != '') {
    $arrCustom['name_vi'] = $model->processData($_GET['name_vi']);
    $link .= "&name=" . $arrCustom['name_vi'];
    $link_back .= "&name=" . $arrCustom['name_vi'];
} else {
    $arrCustom['name_vi'] = '';
}
if (isset($_GET['cate_id']) && $_GET['cate_id'] > 0) {
    $cate_id = $_GET['cate_id'];
    $link .= "&cate_id=" . $cate_id;
    $link_form .= "&cate_id=" . $cate_id;
    $arrCustom['cate_id'] = $cate_id;
    $detailParent = $model->getDetail('articles_cate', $cate_id);
} else {
    $cate_id = -1;
}
if (isset($_GET['is_hot'])) {
    $is_hot = $_GET['is_hot'];
    $link .= "&is_hot=" . $is_hot;
    $link_form .= "&is_hot=" . $is_hot;
    $arrCustom['is_hot'] = $is_hot;
} else {
    $is_hot = -1;
}
$table = "articles";
$listTotal = $model->getList($table, -1, -1, $arrCustom);
$total_record = $listTotal['total'];
$total_page = ceil($total_record / 100);
开发者ID:hoangnhonline,项目名称:hoa-tuoi,代码行数:31,代码来源:list.php

示例11:

                            </a>   
<?php 
        if ($row['status'] == 2) {
            ?>
<span class="label label-danger">Đã kết thúc</span>                       
<?php 
        } else {
            ?>
<span class="label label-info">Đang hiệu lực</span>                       
<?php 
        }
        ?>
                    
                            <br />     
                            <?php 
        $detail = $model->getDetail("objects", $row['object_id']);
        ?>

                            <?php 
        echo $row['object_type'] == 1 ? "Phòng" : "Nhà";
        ?>
 : 
                            <a href="index.php?mod=<?php 
        echo $table;
        ?>
&act=form&id=<?php 
        echo $row['object_id'];
        ?>
" target="_blank">
                            <?php 
        echo $detail['name'];
开发者ID:hoangnhonline,项目名称:phong-tro-sg,代码行数:31,代码来源:list.php

示例12: randomPassword

<?php

$id = 0;
$cityArr = $model->getList('city', -1, -1);
$id = isset($_GET['id']) ? (int) $_GET['id'] : 0;
if (isset($_GET['id'])) {
    require_once "model/Backend.php";
    $model = new Backend();
    $detail = $model->getDetail("users", $id);
} else {
    $pass = randomPassword();
}
function randomPassword()
{
    $alphabet = 'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ1234567890';
    $pass = array();
    //remember to declare $pass as an array
    $alphaLength = strlen($alphabet) - 1;
    //put the length -1 in cache
    for ($i = 0; $i < 8; $i++) {
        $n = rand(0, $alphaLength);
        $pass[] = $alphabet[$n];
    }
    return implode($pass);
    //turn the array into a string
}
?>
<div class="row">
   <div class="col-md-12">
      <!-- Custom Tabs -->        
      <button class="btn btn-primary btn-sm" onclick="location.href='index.php?mod=user&act=list'">Danh sách</button>        
开发者ID:hoangnhonline,项目名称:bds-sth,代码行数:31,代码来源:form.php

示例13: date

     $contract_id = $model->insert('contract', $contractArr);
     $start = $_POST['start_date'];
     $current = date('d-m-Y');
     if ($current < $start) {
         $status = 2;
         // coc
     } else {
         $status = 3;
         // dang o
     }
     mysql_query("UPDATE objects SET status = {$status} WHERE id = {$object_id} AND object_type = {$object_type}");
 }
 mysql_query("DELETE FROM contract_service WHERE contract_id = {$contract_id}");
 //save service
 if ($object_type == 1) {
     $detailTaiSan = $model->getDetail('objects', $object_id);
     if ($detailTaiSan['house_id'] > 0) {
         $arrServiceHouse = $model->getHouseServices($detailTaiSan['house_id']);
     }
     if (!empty($_POST['service_id'])) {
         foreach ($_POST['service_id'] as $service_id) {
             $dataService['service_id'] = $service_id;
             $dataService['contract_id'] = $contract_id;
             $dataService['cal_type'] = $arrServiceHouse[$service_id]['cal_type'];
             $model->insert('contract_service', $dataService);
         }
     }
     mysql_query("DELETE FROM contract_convenient WHERE contract_id = {$contract_id}");
     //save convenient
     if (!empty($_POST['convenient_id'])) {
         foreach ($_POST['convenient_id'] as $convenient_id) {
开发者ID:hoangnhonline,项目名称:bds-sth,代码行数:31,代码来源:Contract.php

示例14: isset

<?php

if ($_SESSION['level'] == 1) {
    $user_id = isset($_GET['user_id']) ? (int) $_GET['user_id'] : -1;
} else {
    $user_id = $_SESSION['user_id'];
}
require_once "model/Backend.php";
$model = new Backend();
$link = "index.php?mod=doanhthu&act=list";
if (isset($_GET['contract_id']) && $_GET['contract_id'] > 0) {
    $contract_id = (int) $_GET['contract_id'];
    $detail = $model->getDetail('contract', $contract_id);
} else {
    $contract_id = -1;
}
$month = isset($_GET['month']) ? (int) $_GET['month'] : -1;
$year = isset($_GET['year']) ? (int) $_GET['year'] : -1;
$arrList = $model->getDoanhThuTotalUser($user_id, $month, $year);
$modArr = $model->getList('users', -1, -1, array('level' => 2));
?>
<form id="exportForm" action="export.php">
    <input type="hidden" name="user_id" value="<?php 
echo $user_id;
?>
">
    <input type="hidden" name="year" value="<?php 
echo $year;
?>
">
    <input type="hidden" name="month" value="<?php 
开发者ID:hoangnhonline,项目名称:bds-sth,代码行数:31,代码来源:list.php

示例15: array

<?php

$id = 0;
$is_detail = false;
$arrLink = array();
if (isset($_GET['id'])) {
    $id = (int) $_GET['id'];
    require_once "model/Backend.php";
    $model = new Backend();
    $detail = $model->getDetail("block", $id);
    $is_detail = true;
    $rs = mysql_query("SELECT * FROM link WHERE block_id = {$id} ORDER BY id ASC");
    while ($row = mysql_fetch_assoc($rs)) {
        $arrLink[] = $row;
    }
}
$current = count($arrLink);
$balance = 7 - $current;
?>
<div class="row">
    <div class="col-md-12">
        <section class="content-header">     
          <ol class="breadcrumb">
            <li><a href="index.php"><i class="fa fa-dashboard"></i> Dashboard</a></li>
            <li><a href="index.php?mod=block&act=list">Link footer</a></li>              
          </ol>
        </section>
        <!-- Custom Tabs -->
        <button class="btn btn-primary btn-sm" onclick="location.href='index.php?mod=block&act=list'">
            Danh sách
        </button>
开发者ID:hoangnhonline,项目名称:hoa-tuoi,代码行数:31,代码来源:form.php


注:本文中的Backend::getDetail方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。