public function loadModel($id)
 {
     $model = sModule::model()->findByPk((int) $id);
     if ($model === null) {
         throw new CHttpException(404, 'The requested page does not exist.');
     }
     return $model;
 }
 public function actionIndex()
 {
     /*
     		 1 = Admin Message
     		2 = User Message
     		3 = Allocation Custom Message
     */
     $model = $this->newNotification();
     $model3 = $this->newNotification3();
     if (!Yii::app()->user->isGuest) {
         $dataProvider = sNotification::model()->searchFilter();
         $dataProvider3 = sNotification3::model()->searchFilter3();
         $dataProviderImage = sModule::model()->searchMenuImage();
         //Yii::app()->user->setFlash('success','<strong>Testing Flash</strong>..Testing Flash... Bagus nggak nih flash...');
         $this->render('index', array('dataProvider' => $dataProvider, 'model' => $model, 'dataProvider3' => $dataProvider3, 'model3' => $model3, 'dataProviderImage' => $dataProviderImage));
     } else {
         $this->redirect(array('site/login'));
     }
 }