public function actionAdmin() { $model = new Pegawai('search'); $model->unsetAttributes(); // clear any default values if (isset($_GET['Pegawai'])) { $model->attributes = $_GET['Pegawai']; } $this->render('admin', array('model' => $model)); }
public function actionIndex() { $model = new Pegawai('search'); $model->unsetAttributes(); // clear any default values $_SESSION['lap_3_id_satuan_kerja'] = isset($_SESSION['lap_3_id_satuan_kerja']) ? $_SESSION['lap_3_id_satuan_kerja'] : 'Semua'; if (isset($_GET['Pegawai'])) { $model->attributes = $_GET['Pegawai']; $_SESSION['lap_3_id_satuan_kerja'] = isset($_GET['Pegawai']['id_satuan_kerja']) ? $_GET['Pegawai']['id_satuan_kerja'] : 'Semua'; } $this->render('index', array('model' => $model)); }