我如何扩展django BaseDateListView

时间:2015-08-27 17:11:35

标签: django django-views django-class-based-views

我希望我的视图能够提供具有特定日期范围的对象。我该如何实现BaseDateListView?有人可以举个例子吗

1 个答案:

答案 0 :(得分:0)

if (!defined('BASEPATH'))
    exit('No direct script access allowed');
if (!ini_get('date.timezone')) {
    date_default_timezone_set('my-time-zone');
}

class Login extends CI_Controller {
    public function __construct() {
        parent::__construct();
        $this->load->model('mod_login');
        $this->load->helper('date');
    }

    function index() {
         echo "Here I am!"; //Nothing echos 
    }

   function logout{
   //logout function here.
   }
}

Official US Government page on GPS accuracy