37 lines
887 B
PHP
37 lines
887 B
PHP
<?php namespace App\Models;
|
|
|
|
use CodeIgniter\Model;
|
|
|
|
class Transaction_model extends Model
|
|
{
|
|
protected $table = 'transactions_uploads';
|
|
protected $primaryKey = 'id';
|
|
|
|
protected $allowedFields = ['date', 'ref_1','ref_2','remarks', 'amount','donation_ref'];
|
|
|
|
|
|
|
|
function all_transaction()
|
|
{
|
|
|
|
$builder = $this->db->table('transactions_uploads');
|
|
$result = $builder->get();
|
|
$output = $result->getResultArray();
|
|
return $output;
|
|
}
|
|
|
|
|
|
// protected $returnType = 'array';
|
|
// protected $useSoftDeletes = true;
|
|
|
|
|
|
|
|
// protected $useTimestamps = false;
|
|
// protected $createdField = 'created_at';
|
|
// protected $updatedField = 'updated_at';
|
|
// protected $deletedField = 'deleted_at';
|
|
|
|
// protected $validationRules = [];
|
|
// protected $validationMessages = [];
|
|
// protected $skipValidation = false;
|
|
} |