You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

DepartamentoModel.php 395B

2 jaren geleden
1234567891011121314151617181920
  1. <?php
  2. namespace App\Models;
  3. use CodeIgniter\Model;
  4. class DepartamentoModel extends Model
  5. {
  6. protected $table = 'departamento';
  7. protected $primaryKey = 'iddepartamento';
  8. function getDepartamentos()
  9. {
  10. return $this->select(['iddepartamento', 'nombre'])
  11. ->where('status', '1')
  12. ->orderBy('nombre')
  13. ->findAll();
  14. }
  15. }