本文整理汇总了PHP中Crud::__construct方法的典型用法代码示例。如果您正苦于以下问题:PHP Crud::__construct方法的具体用法?PHP Crud::__construct怎么用?PHP Crud::__construct使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Crud
的用法示例。
在下文中一共展示了Crud::__construct方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1:
function __construct()
{
// Call the Model constructor
parent::__construct();
$this->_setTableName($this->table_name);
}
示例2: __construct
public function __construct()
{
parent::__construct();
$this->table = 'order';
$this->idkey = 'id_sessions';
$this->lib_auth->check_admin();
}
示例3: __construct
public function __construct()
{
parent::__construct();
$this->table = 'good';
$this->idkey = 'id_good';
$this->load->library('MY_Form_validation');
}
示例4: __construct
public function __construct()
{
parent::__construct();
$this->table = 'menu';
$this->idkey = 'id';
$this->p = 1;
header('Content-type: text/html; charset=utf-8');
}
示例5: array
function __construct()
{
parent::__construct();
$this->title = "Statutory Holidays";
$this->table = "{$_SESSION['DB_PREFIX']}bankholiday";
$this->dialogwidth = 500;
$this->sql = "SELECT A.* \n\t\t\t\t FROM {$_SESSION['DB_PREFIX']}bankholiday A \n\t\t\t\t ORDER BY startdate";
$this->columns = array(array('name' => 'id', 'length' => 6, 'pk' => true, 'showInView' => false, 'editable' => false, 'bind' => false, 'filter' => false, 'label' => 'ID'), array('name' => 'name', 'length' => 55, 'label' => 'Name'), array('name' => 'startdate', 'filter' => false, 'datatype' => 'date', 'associatedcolumns' => array('startdate_half'), 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'Start Date'), array('name' => 'startdate_half', 'type' => 'CHECKBOX', 'showInView' => false, 'filter' => false, 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'Full Day'), array('name' => 'enddate', 'filter' => false, 'datatype' => 'date', 'associatedcolumns' => array('enddate_half'), 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'End Date'), array('name' => 'enddate_half', 'filter' => false, 'type' => 'CHECKBOX', 'showInView' => false, 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'Full Day'), array('name' => 'daystaken', 'filter' => false, 'align' => 'center', 'length' => 15, 'readonly' => true, 'required' => false, 'label' => 'Duration'));
}
示例6: __construct
public function __construct()
{
parent::__construct();
$this->idkey = 'name';
$this->table = 'img';
$this->load->helper('directory');
$d = $this->config->item('upload_path');
$this->data['list'] = directory_map("{$d}", true);
//Берем только картинки без минимизации
return $this->data['list'];
}
示例7: __construct
public function __construct()
{
parent::__construct();
$this->_index_fields[] = name();
}
示例8: SUM
function __construct()
{
parent::__construct();
$this->title = "Holidays";
$this->table = "{$_SESSION['DB_PREFIX']}holiday";
$this->dialogwidth = 500;
$this->onClickCallback = "checkStatus";
$this->sql = "SELECT A.*, " . "B.holidayentitlement," . "B.firstname, B.lastname, " . "(SELECT SUM(D.daystaken) FROM {$_SESSION['DB_PREFIX']}holiday D WHERE YEAR(D.startdate) = YEAR(A.startdate) AND D.memberid = A.memberid) AS daysremaining " . "FROM {$_SESSION['DB_PREFIX']}holiday A " . "INNER JOIN {$_SESSION['DB_PREFIX']}members B " . "ON B.member_id = A.memberid";
$this->messages = array(array('id' => 'holidayid'), array('id' => 'reasonnotes'));
$this->columns = array(array('name' => 'id', 'length' => 6, 'pk' => true, 'showInView' => false, 'editable' => false, 'bind' => false, 'filter' => false, 'label' => 'ID'), array('name' => 'requestedbyname', 'type' => 'DERIVED', 'length' => 30, 'bind' => false, 'editable' => false, 'filter' => false, 'sortcolumn' => 'B.firstname', 'function' => 'fullName', 'label' => 'Employee'), array('name' => 'memberid', 'datatype' => 'user', 'length' => 12, 'showInView' => false, 'label' => 'Employee'), array('name' => 'remaining', 'type' => 'DERIVED', 'length' => 12, 'filter' => false, 'bind' => false, 'editable' => false, 'function' => 'daysRemaining', 'align' => 'center', 'label' => 'Days Remainings'), array('name' => 'requesteddate', 'datatype' => 'date', 'length' => 10, 'filter' => false, 'readonly' => true, 'label' => 'Request Date'), array('name' => 'startdate', 'filter' => false, 'datatype' => 'date', 'associatedcolumns' => array('startdate_half'), 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'Start Date'), array('name' => 'startdate_half', 'type' => 'CHECKBOX', 'showInView' => false, 'filter' => false, 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'Full Day'), array('name' => 'enddate', 'filter' => false, 'datatype' => 'date', 'associatedcolumns' => array('enddate_half'), 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'End Date'), array('name' => 'enddate_half', 'filter' => false, 'type' => 'CHECKBOX', 'showInView' => false, 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'Full Day'), array('name' => 'daystaken', 'filter' => false, 'align' => 'center', 'length' => 15, 'readonly' => true, 'required' => false, 'label' => 'Duration'));
}
示例9: __construct
public function __construct()
{
parent::__construct();
$this->load->model($this->model);
$this->_primary_key = $this->{$this->model}->_primary_keys[0];
}
示例10: __construct
public function __construct(\Magento\Framework\App\ResourceConnection $resource, \Praxigento\Core\Repo\Query\IHasSelect $factorySelect)
{
parent::__construct($resource);
$this->_factorySelect = $factorySelect;
}
示例11: __construct
public function __construct()
{
parent::__construct();
}
示例12: __construct
public function __construct()
{
parent::__construct();
$this->load->library('Cdn');
// $this->_index_fields[] = name();
}
示例13: __construct
public function __construct($db) {
parent::__construct($db, 'tcontact');
}
示例14: __construct
public function __construct($db) {
parent::__construct($db, 'accounts');
}
示例15: array
function __construct()
{
parent::__construct();
$this->title = "Absences";
$this->table = "{$_SESSION['DB_PREFIX']}absence";
$this->dialogwidth = 500;
$this->onClickCallback = "checkStatus";
$this->sql = "SELECT A.*, " . "B.firstname, B.lastname " . "FROM {$_SESSION['DB_PREFIX']}absence A " . "INNER JOIN {$_SESSION['DB_PREFIX']}members B " . "ON B.member_id = A.memberid";
$this->messages = array(array('id' => 'absenceid'), array('id' => 'reasonnotes'));
$this->columns = array(array('name' => 'id', 'length' => 6, 'pk' => true, 'showInView' => false, 'editable' => false, 'bind' => false, 'filter' => false, 'label' => 'ID'), array('name' => 'requestedbyname', 'type' => 'DERIVED', 'length' => 30, 'bind' => false, 'editable' => false, 'filter' => false, 'sortcolumn' => 'B.firstname', 'function' => 'fullName', 'label' => 'Employee'), array('name' => 'memberid', 'datatype' => 'user', 'length' => 12, 'showInView' => false, 'label' => 'Employee'), array('name' => 'absencetype', 'length' => 30, 'label' => 'Type', 'type' => 'COMBO', 'options' => array(array('value' => 'Unauthorised', 'text' => 'Unauthorised'), array('value' => 'Authorised', 'text' => 'Authorised'), array('value' => 'Sick', 'text' => 'Sick'), array('value' => 'Family Matter', 'text' => 'Family Matter'), array('value' => 'Not In', 'text' => 'Not In'), array('value' => 'Leaver', 'text' => 'Leaver'))), array('name' => 'requesteddate', 'datatype' => 'date', 'length' => 10, 'filter' => false, 'readonly' => true, 'label' => 'Request Date'), array('name' => 'startdate', 'filter' => false, 'datatype' => 'date', 'associatedcolumns' => array('startdate_half'), 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'Start Date'), array('name' => 'startdate_half', 'type' => 'CHECKBOX', 'showInView' => false, 'filter' => false, 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'Full Day'), array('name' => 'enddate', 'filter' => false, 'datatype' => 'date', 'associatedcolumns' => array('enddate_half'), 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'End Date'), array('name' => 'enddate_half', 'filter' => false, 'type' => 'CHECKBOX', 'showInView' => false, 'length' => 15, 'onchange' => 'calculateDuration', 'label' => 'Full Day'), array('name' => 'daystaken', 'filter' => false, 'align' => 'center', 'length' => 15, 'readonly' => true, 'required' => false, 'label' => 'Duration'));
}