Commit 862fe6f2 by Jerry Corbert Sinaga

Tamabah Account

parent 24ce874b
...@@ -15,19 +15,38 @@ class UserIdentity extends CUserIdentity ...@@ -15,19 +15,38 @@ class UserIdentity extends CUserIdentity
* against some persistent user identity storage (e.g. database). * against some persistent user identity storage (e.g. database).
* @return boolean whether authentication succeeds. * @return boolean whether authentication succeeds.
*/ */
public function authenticate() // to store the current account's id
{ private $_id;
$users=array(
// username => password // override the CBaseUserIdentity::getId()
'demo'=>'demo', // why should the method be overridden?
'admin'=>'admin', // in CBaseUserIdentity, this method returns username,
); // in our case it shouldn't so we need to override it.
if(!isset($users[$this->username])) public function getId() {
$this->errorCode=self::ERROR_USERNAME_INVALID; return($this->_id);
elseif($users[$this->username]!==$this->password)
$this->errorCode=self::ERROR_PASSWORD_INVALID;
else
$this->errorCode=self::ERROR_NONE;
return !$this->errorCode;
} }
public function authenticate() {
// find the account by its username
$account = Account::model()->findByAttributes(
array(
'ACCOUNT' => $this->username,
)
);
// tests the given password against account's
if ($account && $account->comparePassword($this->password)) {
// when it is successful, set the id with account's
$this->_id = $account->ID;
// as it is a successful test, no error occurs
$this->errorCode = self::ERROR_NONE;
// returns the validation summary as TRUE
return (TRUE);
}
// this two codes will only be executed when above test fails
// set the error as unknown membership
// and returns a FALSE value indicating a failed authentication
$this->errorCode = self::ERROR_UNKNOWN_IDENTITY;
return (FALSE);
}
} }
\ No newline at end of file
...@@ -53,6 +53,12 @@ return array( ...@@ -53,6 +53,12 @@ return array(
'class' => 'ext.booster.components.Booster', 'class' => 'ext.booster.components.Booster',
'responsiveCss' => true, 'responsiveCss' => true,
), ),
'digester' => array(
// specify the class being used
'class' => 'ext.components.MessageDigester',
// set the digester's salt attribute
'salt' => 'mY_CUStoM*SaLT',
),
'db' => array( 'db' => array(
'connectionString' => 'mysql:host=localhost;dbname=smartcard', 'connectionString' => 'mysql:host=localhost;dbname=smartcard',
'emulatePrepare' => true, 'emulatePrepare' => true,
......
<?php
// uncomment the following to define a path alias
// Yii::setPathOfAlias('local','path/to/local-folder');
// This is the main Web application configuration. Any writable
// CWebApplication properties can be configured here.
return array(
'basePath' => dirname(__FILE__) . DIRECTORY_SEPARATOR . '..',
'name' => 'Sistem Absensi Mahasiswa',
// preloading 'log' component
'preload' => array(
'log',
'booster'
),
'theme' => 'hebo',
// autoloading model and component classes
'import' => array(
'application.models.*',
'application.components.*',
),
'modules' => array(
// uncomment the following to enable the Gii tool
'gii' => array(
'class' => 'system.gii.GiiModule',
'password' => false,
'generatorPaths' => array(
'booster.gii', // boostrap generator
),
// If removed, Gii defaults to localhost only. Edit carefully to taste.
'ipFilters' => array('127.0.0.1', '::1'),
),
),
// application components
'components' => array(
'pdf' => array(
'class' => 'ext.yii-pdf.EYiiPdf',
'params' => array(
'HTML2PDF' => array(
'librarySourcePath' => 'application.vendors.html2pdf.*',
'classFile' => 'html2pdf.class.php', // For adding to Yii::$classMap
'defaultParams' => array( // More info: http://wiki.spipu.net/doku.php?id=html2pdf:en:v4:accueil
'orientation' => 'L', // landscape or portrait orientation
'format' => 'A4', // format A4, A5, ...
'language' => 'en', // language: fr, en, it ...
'unicode' => true, // TRUE means clustering the input text IS unicode (default = true)
'encoding' => 'UTF-8', // charset encoding; Default is UTF-8
'marges' => array(25, 10, 5, 8), // margins by default, in order (left, top, right, bottom)
)
)
),
),
'booster' => array(
'class' => 'ext.booster.components.Booster',
'responsiveCss' => true,
),
'db' => array(
'connectionString' => 'mysql:host=localhost;dbname=smartcard',
'emulatePrepare' => true,
'username' => 'root',
'password' => '',
'charset' => 'utf8',
),
),
// application-level parameters that can be accessed
// using Yii::app()->params['paramName']
'params' => array(
// this is used in contact page
'adminEmail' => 'webmaster@example.com',
),
);
\ No newline at end of file
<?php
class AccountController extends Controller
{
/**
* @var string the default layout for the views. Defaults to '//layouts/column2', meaning
* using two-column layout. See 'protected/views/layouts/column2.php'.
*/
public $layout='//layouts/column2';
/**
* @return array action filters
*/
public function filters()
{
return array(
'accessControl', // perform access control for CRUD operations
);
}
/**
* Specifies the access control rules.
* This method is used by the 'accessControl' filter.
* @return array access control rules
*/
public function accessRules()
{
return array(
array('allow', // allow all users to perform 'index' and 'view' actions
'actions'=>array('index','view'),
'users'=>array('*'),
),
array('allow', // allow authenticated user to perform 'create' and 'update' actions
'actions'=>array('create','update','Update2'),
'users'=>array('@'),
),
array('allow', // allow admin user to perform 'admin' and 'delete' actions
'actions'=>array('admin','delete'),
'users'=>array('admin'),
),
array('deny', // deny all users
'users'=>array('*'),
),
);
}
/**
* Displays a particular model.
* @param integer $id the ID of the model to be displayed
*/
public function actionView($id)
{
$this->render('view',array(
'model'=>$this->loadModel($id),
));
}
/**
* Creates a new model.
* If creation is successful, the browser will be redirected to the 'view' page.
*/
public function actionCreate()
{
$model=new Account;
// Uncomment the following line if AJAX validation is needed
// $this->performAjaxValidation($model);
if(isset($_POST['Account']))
{
$model->attributes=$_POST['Account'];
if($model->save())
$this->redirect(array('view','id'=>$model->ID));
}
$this->render('create',array(
'model'=>$model,
));
}
/**
* Updates a particular model.
* If update is successful, the browser will be redirected to the 'view' page.
* @param integer $id the ID of the model to be updated
*/
public function actionUpdate($id)
{
$model=$this->loadModel($id);
// Uncomment the following line if AJAX validation is needed
// $this->performAjaxValidation($model);
if(isset($_POST['Account']))
{
$model->attributes=$_POST['Account'];
if($model->save())
$this->redirect(array('view','id'=>$model->ID));
}
$this->render('update',array(
'model'=>$model,
));
}
public function actionUpdate2($id) {
$model = $this->loadModel($id);
// Uncomment the following line if AJAX validation is needed
// $this->performAjaxValidation($model);
//if($model->password== md5($_POST['User']->oldpassword)){
if(isset($_POST['Account']))
{
if($model->comparePassword($_POST['oldpw'])){
if(Account::validateChangePassword($_POST['password'],$_POST['repassword'])){
$model->attributes=$_POST['Account'];
$model->PASSWORD=$_POST['password'];
echo $_POST['password'];
if($model->save())
$this->redirect(array('/site/index'));
}
else
Yii::app()->user->setFlash('errorPassword', "Type correctly the new password");
}
else
{
Yii::app()->user->setFlash('errorPassword', "Re-check your current password");
}
}
/* }
else{
$this->render('update2', array(
'model' => $model,
));
}*/
$this->render('update2', array(
'model' => $model,
));
}
/**
* Deletes a particular model.
* If deletion is successful, the browser will be redirected to the 'admin' page.
* @param integer $id the ID of the model to be deleted
*/
public function actionDelete($id)
{
if(Yii::app()->request->isPostRequest)
{
// we only allow deletion via POST request
$this->loadModel($id)->delete();
// if AJAX request (triggered by deletion via admin grid view), we should not redirect the browser
if(!isset($_GET['ajax']))
$this->redirect(isset($_POST['returnUrl']) ? $_POST['returnUrl'] : array('admin'));
}
else
throw new CHttpException(400,'Invalid request. Please do not repeat this request again.');
}
/**
* Lists all models.
*/
public function actionIndex()
{
$dataProvider=new CActiveDataProvider('Account');
$this->render('index',array(
'dataProvider'=>$dataProvider,
));
}
/**
* Manages all models.
*/
public function actionAdmin()
{
$model=new Account('search');
$model->unsetAttributes(); // clear any default values
if(isset($_GET['Account']))
$model->attributes=$_GET['Account'];
$this->render('admin',array(
'model'=>$model,
));
}
/**
* Returns the data model based on the primary key given in the GET variable.
* If the data model is not found, an HTTP exception will be raised.
* @param integer the ID of the model to be loaded
*/
public function loadModel($id)
{
$model=Account::model()->findByPk($id);
if($model===null)
throw new CHttpException(404,'The requested page does not exist.');
return $model;
}
/**
* Performs the AJAX validation.
* @param CModel the model to be validated
*/
protected function performAjaxValidation($model)
{
if(isset($_POST['ajax']) && $_POST['ajax']==='account-form')
{
echo CActiveForm::validate($model);
Yii::app()->end();
}
}
}
<?php
class KurikulumController extends Controller
{
/**
* @var string the default layout for the views. Defaults to '//layouts/column2', meaning
* using two-column layout. See 'protected/views/layouts/column2.php'.
*/
public $layout='//layouts/column2';
/**
* @return array action filters
*/
public function filters()
{
return array(
'accessControl', // perform access control for CRUD operations
);
}
/**
* Specifies the access control rules.
* This method is used by the 'accessControl' filter.
* @return array access control rules
*/
public function accessRules()
{
return array(
array('allow', // allow all users to perform 'index' and 'view' actions
'actions'=>array('index','view'),
'users'=>array('*'),
),
array('allow', // allow authenticated user to perform 'create' and 'update' actions
'actions'=>array('create','update'),
'users'=>array('@'),
),
array('allow', // allow admin user to perform 'admin' and 'delete' actions
'actions'=>array('admin','delete'),
'users'=>array('admin'),
),
array('deny', // deny all users
'users'=>array('*'),
),
);
}
/**
* Displays a particular model.
* @param integer $id the ID of the model to be displayed
*/
public function actionView($id,$id2)
{
$this->render('view',array(
'model'=>$this->loadModel($id,$id2),
));
}
/**
* Creates a new model.
* If creation is successful, the browser will be redirected to the 'view' page.
*/
public function actionCreate()
{
$model=new Kurikulum;
// Uncomment the following line if AJAX validation is needed
// $this->performAjaxValidation($model);
if(isset($_POST['Kurikulum']))
{
$model->attributes=$_POST['Kurikulum'];
if($model->save())
$this->redirect(array('view','id'=>$model->NIM));
}
$this->render('create',array(
'model'=>$model,
));
}
/**
* Updates a particular model.
* If update is successful, the browser will be redirected to the 'view' page.
* @param integer $id the ID of the model to be updated
*/
public function actionUpdate($id,$id2)
{
$model=$this->loadModel($id,$id2);
if(isset($_POST['NamaModel']))
{
$model->attributes=$_POST['NamaModel'];
if($model->save())
$this->redirect(array('view','id'=>$model->id,'id2'=>$model->id2));
}
$this->render('update',array(
'model'=>$model,
));
}
/**
* Deletes a particular model.
* If deletion is successful, the browser will be redirected to the 'admin' page.
* @param integer $id the ID of the model to be deleted
*/
public function actionDelete($id,$id2)
{
if(Yii::app()->request->isPostRequest)
{
$this->loadModel($id,$id2)->delete();
if(!isset($_GET['ajax']))
$this->redirect(isset($_POST['returnUrl']) ? $_POST['returnUrl'] : array('admin'));
}
else
throw new CHttpException(400,'Invalid request. Please do not repeat this request again.');
}
/**
* Lists all models.
*/
public function actionIndex()
{
$dataProvider=new CActiveDataProvider('Kurikulum');
$this->render('index',array(
'dataProvider'=>$dataProvider,
));
}
/**
* Manages all models.
*/
public function actionAdmin()
{
$model=new Kurikulum('search');
$model->unsetAttributes(); // clear any default values
if(isset($_GET['Kurikulum']))
$model->attributes=$_GET['Kurikulum'];
$this->render('admin',array(
'model'=>$model,
));
}
/**
* Returns the data model based on the primary key given in the GET variable.
* If the data model is not found, an HTTP exception will be raised.
* @param integer the ID of the model to be loaded
*/
public function loadModel($id,$id2)
{
$model=NamaModel::model()->findByAttributes(array('ID_KUR'=>$id,'KODE_MK'=>$id2));
if($model===null)
throw new CHttpException(404,'The requested page does not exist.');
return $model;
}
/**
* Performs the AJAX validation.
* @param CModel the model to be validated
*/
protected function performAjaxValidation($model)
{
if(isset($_POST['ajax']) && $_POST['ajax']==='Kurikulum-form')
{
echo CActiveForm::validate($model);
Yii::app()->end();
}
}
}
<?php
// this class featured hashing capabilities
class MessageDigester extends CComponent {
const ALGORITM_MD5 = 0;
const ALGORITM_SHA1 = 1;
public $salt = 'ibad1314';
public function init(){
// overriding this method is a mandatory
}
// do the digesting
public function digest($_message, $_algorithm = self::ALGORITM_MD5) {
switch ($_algorithm){
case self::ALGORITM_MD5:
return $this->md5($_message);
case self::ALGORITM_SHA1:
return $this->sha1($_message);
default :
return (NULL);
}
}
// an md5 digesting
public function md5($_message) {
return(md5($_message . $this->salt));
}
// a sha1 digesting
public function sha1($_message) {
return(sha1($_message . $this->salt));
}
}
?>
\ No newline at end of file
<?php
/**
* This is the model class for table "account".
*
* The followings are the available columns in table 'account':
* @property integer $ID
* @property string $ACCOUNT
* @property string $PASSWORD
*/
class Account extends CActiveRecord
{
/**
* Returns the static model of the specified AR class.
* @param string $className active record class name.
* @return Account the static model class
*/
public static function model($className=__CLASS__)
{
return parent::model($className);
}
/**
* @return string the associated database table name
*/
public function tableName()
{
return 'account';
}
/**
* @return array validation rules for model attributes.
*/
public function rules()
{
// NOTE: you should only define rules for those attributes that
// will receive user inputs.
return array(
array('ACCOUNT', 'length', 'max'=>20),
array('PASSWORD', 'length', 'max'=>50),
// The following rule is used by search().
// Please remove those attributes that should not be searched.
array('ID, ACCOUNT, PASSWORD', 'safe', 'on'=>'search'),
);
}
/**
* @return array relational rules.
*/
public function relations()
{
// NOTE: you may need to adjust the relation name and the related
// class name for the relations automatically generated below.
return array(
);
}
/**
* @return array customized attribute labels (name=>label)
*/
public function attributeLabels()
{
return array(
'ID' => 'ID',
'ACCOUNT' => 'Account',
'PASSWORD' => 'Password',
);
}
/**
* Retrieves a list of models based on the current search/filter conditions.
* @return CActiveDataProvider the data provider that can return the models based on the search/filter conditions.
*/
public function search()
{
// Warning: Please modify the following code to remove attributes that
// should not be searched.
$criteria=new CDbCriteria;
$criteria->compare('ID',$this->ID);
$criteria->compare('ACCOUNT',$this->ACCOUNT,true);
$criteria->compare('PASSWORD',$this->PASSWORD,true);
return new CActiveDataProvider($this, array(
'criteria'=>$criteria,
));
}
// overrides the CModel::beforeSave()
public function beforeSave() {
$this->PASSWORD = Yii::app()->digester->md5($this->PASSWORD);
return (parent::beforeSave());
}
// to compare this model's password wirh a given password
public function comparePassword($_password) {
return($this->PASSWORD === Yii::app()->digester->md5($_password));
}
public static function validateChangePassword($pwd,$repwd){
if($pwd===$repwd)
return true;
else
return false;
}
}
\ No newline at end of file
<?php $form=$this->beginWidget('booster.widgets.TbActiveForm',array(
'id'=>'account-form',
'enableAjaxValidation'=>false,
)); ?>
<p class="help-block">Fields with <span class="required">*</span> are required.</p>
<?php echo $form->errorSummary($model); ?>
<?php echo $form->textFieldGroup($model,'ACCOUNT',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->passwordFieldGroup($model,'PASSWORD',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>50)))); ?>
<div class="form-actions">
<?php $this->widget('booster.widgets.TbButton', array(
'buttonType'=>'submit',
'context'=>'primary',
'label'=>$model->isNewRecord ? 'Create' : 'Save',
)); ?>
</div>
<?php $this->endWidget(); ?>
<?php
/* @var $this AccountController */
/* @var $model Account */
/* @var $form CActiveForm */
?>
<div class="form">
<?php $form=$this->beginWidget('CActiveForm', array(
'id'=>'Account-form',
// Please note: When you enable ajax validation, make sure the corresponding
// controller action is handling ajax validation correctly.
// There is a call to performAjaxValidation() commented in generated controller code.
// See class documentation of CActiveForm for details on this.
'enableAjaxValidation'=>false,
'htmlOptions'=>array('enctype'=>'multipart/form-data'),
)); ?>
<p class="note">Fields with <span class="required">*</span> are required.</p>
<?php echo $form->errorSummary($model); ?>
<div class="row">
<?php //echo $form->labelEx($model,'ACCOUNT'); ?>
<?php //echo $model->ACCOUNT?>
<?php echo $form->hiddenField($model,'ACCOUNT',array('size'=>30,'maxlength'=>30)); ?><br>
<?php echo $form->error($model,'ACCOUNT'); ?>
</div>
<div class="row">
<?php echo Chtml::label('Current Password','oldpw') ?>
<?php //echo Chtml::textField("aoldpw",'',array('size'=>60,'maxlength'=>64)); ?>
<?php echo Chtml::passwordField("oldpw",'',array('size'=>60,'maxlength'=>64)); ?>
</div>
<div class="row">
<?php echo CHtml::label('New Password','password') ?>
<?php echo CHtml::passwordField("password",'',array('size'=>60,'maxlength'=>64)); ?>
</div>
<div class="row">
<?php echo CHtml::label('Repeate New Password','repassword') ?>
<?php echo CHtml::passwordField("repassword",'',array('size'=>60,'maxlength'=>64)); ?>
</div>
<div class="row buttons">
<?php echo CHtml::submitButton($model->isNewRecord ? 'Create' : 'Save'); ?>
</div>
<?php $this->endWidget(); ?>
</div><!-- form -->
\ No newline at end of file
<?php $form=$this->beginWidget('booster.widgets.TbActiveForm',array(
'action'=>Yii::app()->createUrl($this->route),
'method'=>'get',
)); ?>
<?php echo $form->textFieldGroup($model,'ID',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'ACCOUNT',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->passwordFieldGroup($model,'PASSWORD',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>50)))); ?>
<div class="form-actions">
<?php $this->widget('booster.widgets.TbButton', array(
'buttonType' => 'submit',
'context'=>'primary',
'label'=>'Search',
)); ?>
</div>
<?php $this->endWidget(); ?>
<div class="view">
<b><?php echo CHtml::encode($data->getAttributeLabel('ID')); ?>:</b>
<?php echo CHtml::link(CHtml::encode($data->ID),array('view','id'=>$data->ID)); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('ACCOUNT')); ?>:</b>
<?php echo CHtml::encode($data->ACCOUNT); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('PASSWORD')); ?>:</b>
<?php echo CHtml::encode($data->PASSWORD); ?>
<br />
</div>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Accounts'=>array('index'),
'Manage',
);
$this->menu=array(
array('label'=>'List Account','url'=>array('index')),
array('label'=>'Create Account','url'=>array('create')),
);
Yii::app()->clientScript->registerScript('search', "
$('.search-button').click(function(){
$('.search-form').toggle();
return false;
});
$('.search-form form').submit(function(){
$.fn.yiiGridView.update('account-grid', {
data: $(this).serialize()
});
return false;
});
");
?>
<h1>Manage Accounts</h1>
<p>
You may optionally enter a comparison operator (<b>&lt;</b>, <b>&lt;=</b>, <b>&gt;</b>, <b>&gt;=</b>, <b>
&lt;&gt;</b>
or <b>=</b>) at the beginning of each of your search values to specify how the comparison should be done.
</p>
<?php echo CHtml::link('Advanced Search','#',array('class'=>'search-button btn')); ?>
<div class="search-form" style="display:none">
<?php $this->renderPartial('_search',array(
'model'=>$model,
)); ?>
</div><!-- search-form -->
<?php $this->widget('booster.widgets.TbGridView',array(
'id'=>'account-grid',
'dataProvider'=>$model->search(),
'filter'=>$model,
'columns'=>array(
'ID',
'ACCOUNT',
'PASSWORD',
array(
'class'=>'booster.widgets.TbButtonColumn',
),
),
)); ?>
<?php
/* @var $this AccountController */
/* @var $model Account */
?>
<h1>Update Password </h1>
<?php echo $this->renderPartial('_form2', array('model'=>$model)); ?>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Accounts'=>array('index'),
'Create',
);
$this->menu=array(
array('label'=>'List Account','url'=>array('index')),
array('label'=>'Manage Account','url'=>array('admin')),
);
?>
<h1>Create Account</h1>
<?php echo $this->renderPartial('_form', array('model'=>$model)); ?>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Accounts',
);
$this->menu=array(
array('label'=>'Create Account','url'=>array('create')),
array('label'=>'Manage Account','url'=>array('admin')),
);
?>
<h1>Accounts</h1>
<?php $this->widget('booster.widgets.TbListView',array(
'dataProvider'=>$dataProvider,
'itemView'=>'_view',
)); ?>
<?php
$this->breadcrumbs=array(
'Accounts'=>array('index'),
$model->ID=>array('view','id'=>$model->ID),
'Update',
);
$this->menu=array(
array('label'=>'List Account','url'=>array('index')),
array('label'=>'Create Account','url'=>array('create')),
array('label'=>'View Account','url'=>array('view','id'=>$model->ID)),
array('label'=>'Manage Account','url'=>array('admin')),
);
?>
<h1>Update Account <?php echo $model->ID; ?></h1>
<?php echo $this->renderPartial('_form',array('model'=>$model)); ?>
\ No newline at end of file
<h1>Update User <?php echo $model->ACCOUNT; ?></h1>
<?php $this->renderPartial('_form2', array('model'=>$model)); ?>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Accounts'=>array('index'),
$model->ID,
);
$this->menu=array(
array('label'=>'List Account','url'=>array('index')),
array('label'=>'Create Account','url'=>array('create')),
array('label'=>'Update Account','url'=>array('update','id'=>$model->ID)),
array('label'=>'Delete Account','url'=>'#','linkOptions'=>array('submit'=>array('delete','id'=>$model->ID),'confirm'=>'Are you sure you want to delete this item?')),
array('label'=>'Manage Account','url'=>array('admin')),
);
?>
<h1>View Account #<?php echo $model->ID; ?></h1>
<?php $this->widget('booster.widgets.TbDetailView',array(
'data'=>$model,
'attributes'=>array(
'ID',
'ACCOUNT',
'PASSWORD',
),
)); ?>
<?php $form=$this->beginWidget('booster.widgets.TbActiveForm',array(
'id'=>'kelas-form',
'enableAjaxValidation'=>false,
)); ?>
<p class="help-block">Fields with <span class="required">*</span> are required.</p>
<?php echo $form->errorSummary($model); ?>
<?php echo $form->textFieldGroup($model,'KELAS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textAreaGroup($model,'KET', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textFieldGroup($model,'LAST_UPDATE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'USER_ID',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>15)))); ?>
<?php echo $form->textFieldGroup($model,'WS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>15)))); ?>
<div class="form-actions">
<?php $this->widget('booster.widgets.TbButton', array(
'buttonType'=>'submit',
'context'=>'primary',
'label'=>$model->isNewRecord ? 'Create' : 'Save',
)); ?>
</div>
<?php $this->endWidget(); ?>
<?php $form=$this->beginWidget('booster.widgets.TbActiveForm',array(
'action'=>Yii::app()->createUrl($this->route),
'method'=>'get',
)); ?>
<?php echo $form->textFieldGroup($model,'KELAS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textAreaGroup($model,'KET', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textFieldGroup($model,'LAST_UPDATE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'USER_ID',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>15)))); ?>
<?php echo $form->textFieldGroup($model,'WS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>15)))); ?>
<div class="form-actions">
<?php $this->widget('booster.widgets.TbButton', array(
'buttonType' => 'submit',
'context'=>'primary',
'label'=>'Search',
)); ?>
</div>
<?php $this->endWidget(); ?>
<div class="view">
<b><?php echo CHtml::encode($data->getAttributeLabel('KELAS')); ?>:</b>
<?php echo CHtml::link(CHtml::encode($data->KELAS),array('view','id'=>$data->KELAS)); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('KET')); ?>:</b>
<?php echo CHtml::encode($data->KET); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('LAST_UPDATE')); ?>:</b>
<?php echo CHtml::encode($data->LAST_UPDATE); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('USER_ID')); ?>:</b>
<?php echo CHtml::encode($data->USER_ID); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('WS')); ?>:</b>
<?php echo CHtml::encode($data->WS); ?>
<br />
</div>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Kelases'=>array('index'),
'Manage',
);
$this->menu=array(
array('label'=>'List Kelas','url'=>array('index')),
array('label'=>'Create Kelas','url'=>array('create')),
);
Yii::app()->clientScript->registerScript('search', "
$('.search-button').click(function(){
$('.search-form').toggle();
return false;
});
$('.search-form form').submit(function(){
$.fn.yiiGridView.update('kelas-grid', {
data: $(this).serialize()
});
return false;
});
");
?>
<h1>Manage Kelases</h1>
<p>
You may optionally enter a comparison operator (<b>&lt;</b>, <b>&lt;=</b>, <b>&gt;</b>, <b>&gt;=</b>, <b>
&lt;&gt;</b>
or <b>=</b>) at the beginning of each of your search values to specify how the comparison should be done.
</p>
<?php echo CHtml::link('Advanced Search','#',array('class'=>'search-button btn')); ?>
<div class="search-form" style="display:none">
<?php $this->renderPartial('_search',array(
'model'=>$model,
)); ?>
</div><!-- search-form -->
<?php $this->widget('booster.widgets.TbGridView',array(
'id'=>'kelas-grid',
'dataProvider'=>$model->search(),
'filter'=>$model,
'columns'=>array(
'KELAS',
'KET',
'LAST_UPDATE',
'USER_ID',
'WS',
array(
'class'=>'booster.widgets.TbButtonColumn',
),
),
)); ?>
<?php
$this->breadcrumbs=array(
'Kelases'=>array('index'),
'Create',
);
$this->menu=array(
array('label'=>'List Kelas','url'=>array('index')),
array('label'=>'Manage Kelas','url'=>array('admin')),
);
?>
<h1>Create Kelas</h1>
<?php echo $this->renderPartial('_form', array('model'=>$model)); ?>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Kelases',
);
$this->menu=array(
array('label'=>'Create Kelas','url'=>array('create')),
array('label'=>'Manage Kelas','url'=>array('admin')),
);
?>
<h1>Kelases</h1>
<?php $this->widget('booster.widgets.TbListView',array(
'dataProvider'=>$dataProvider,
'itemView'=>'_view',
)); ?>
<?php
$this->breadcrumbs=array(
'Kelases'=>array('index'),
$model->KELAS=>array('view','id'=>$model->KELAS),
'Update',
);
$this->menu=array(
array('label'=>'List Kelas','url'=>array('index')),
array('label'=>'Create Kelas','url'=>array('create')),
array('label'=>'View Kelas','url'=>array('view','id'=>$model->KELAS)),
array('label'=>'Manage Kelas','url'=>array('admin')),
);
?>
<h1>Update Kelas <?php echo $model->KELAS; ?></h1>
<?php echo $this->renderPartial('_form',array('model'=>$model)); ?>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Kelases'=>array('index'),
$model->KELAS,
);
$this->menu=array(
array('label'=>'List Kelas','url'=>array('index')),
array('label'=>'Create Kelas','url'=>array('create')),
array('label'=>'Update Kelas','url'=>array('update','id'=>$model->KELAS)),
array('label'=>'Delete Kelas','url'=>'#','linkOptions'=>array('submit'=>array('delete','id'=>$model->KELAS),'confirm'=>'Are you sure you want to delete this item?')),
array('label'=>'Manage Kelas','url'=>array('admin')),
);
?>
<h1>View Kelas #<?php echo $model->KELAS; ?></h1>
<?php $this->widget('booster.widgets.TbDetailView',array(
'data'=>$model,
'attributes'=>array(
'KELAS',
'KET',
'LAST_UPDATE',
'USER_ID',
'WS',
),
)); ?>
<?php $form=$this->beginWidget('booster.widgets.TbActiveForm',array(
'id'=>'kurikulum-form',
'enableAjaxValidation'=>false,
)); ?>
<p class="help-block">Fields with <span class="required">*</span> are required.</p>
<?php echo $form->errorSummary($model); ?>
<?php echo $form->textFieldGroup($model,'ID_KUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'KODE_MK',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>8)))); ?>
<?php echo $form->textFieldGroup($model,'NAMA_KUL_IND',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>
<?php echo $form->textFieldGroup($model,'NAMA_KUL_ING',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>
<?php echo $form->textFieldGroup($model,'SHORT_NAME',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'KBK_ID',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'COURSE_GROUP',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'SKS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'SEM',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'URUT_DLM_SEM',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'SIFAT',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textAreaGroup($model,'KEY_TOPICS_IND', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'KEY_TOPICS_ING', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'OBJEKTIF_IND', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'OBJEKTIF_ING', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textFieldGroup($model,'LAB_HOUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'TUTORIAL_HOUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'COURSE_HOUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'COURSE_HOUR_IN_WEEK',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'LAB_HOUR_IN_WEEK',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'NUMBER_WEEK',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'OTHER_ACTIVITY',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>50)))); ?>
<?php echo $form->textFieldGroup($model,'OTHER_ACTIVITY_HOUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'KNOWLEDGE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'SKILL',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'ATTITUDE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'UTS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'UAS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'TUGAS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'QUIZ',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'WHITEBOARD',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'LCD',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'COURSEWARE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'LAB',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'ELEARNING',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'STATUS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'LAST_UPDATE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'USER_ID',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>15)))); ?>
<?php echo $form->textFieldGroup($model,'WS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>15)))); ?>
<?php echo $form->textAreaGroup($model,'PREREQUISITES', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'COURSE_DESCRIPTION', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'COURSE_OBJECTIVES', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'LEARNING_OUTCOMES', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'COURSE_FORMAT', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'GRADING_PROCEDURE', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'COURSE_CONTENT', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<div class="form-actions">
<?php $this->widget('booster.widgets.TbButton', array(
'buttonType'=>'submit',
'context'=>'primary',
'label'=>$model->isNewRecord ? 'Create' : 'Save',
)); ?>
</div>
<?php $this->endWidget(); ?>
<?php $form=$this->beginWidget('booster.widgets.TbActiveForm',array(
'action'=>Yii::app()->createUrl($this->route),
'method'=>'get',
)); ?>
<?php echo $form->textFieldGroup($model,'ID_KUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'KODE_MK',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>8)))); ?>
<?php echo $form->textFieldGroup($model,'NAMA_KUL_IND',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>
<?php echo $form->textFieldGroup($model,'NAMA_KUL_ING',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>255)))); ?>
<?php echo $form->textFieldGroup($model,'SHORT_NAME',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'KBK_ID',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'COURSE_GROUP',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'SKS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'SEM',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'URUT_DLM_SEM',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'SIFAT',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textAreaGroup($model,'KEY_TOPICS_IND', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'KEY_TOPICS_ING', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'OBJEKTIF_IND', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'OBJEKTIF_ING', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textFieldGroup($model,'LAB_HOUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'TUTORIAL_HOUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'COURSE_HOUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'COURSE_HOUR_IN_WEEK',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'LAB_HOUR_IN_WEEK',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'NUMBER_WEEK',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'OTHER_ACTIVITY',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>50)))); ?>
<?php echo $form->textFieldGroup($model,'OTHER_ACTIVITY_HOUR',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'KNOWLEDGE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'SKILL',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'ATTITUDE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'UTS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'UAS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'TUGAS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'QUIZ',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'WHITEBOARD',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'LCD',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'COURSEWARE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'LAB',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'ELEARNING',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>1)))); ?>
<?php echo $form->textFieldGroup($model,'STATUS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5')))); ?>
<?php echo $form->textFieldGroup($model,'LAST_UPDATE',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>20)))); ?>
<?php echo $form->textFieldGroup($model,'USER_ID',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>15)))); ?>
<?php echo $form->textFieldGroup($model,'WS',array('widgetOptions'=>array('htmlOptions'=>array('class'=>'span5','maxlength'=>15)))); ?>
<?php echo $form->textAreaGroup($model,'PREREQUISITES', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'COURSE_DESCRIPTION', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'COURSE_OBJECTIVES', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'LEARNING_OUTCOMES', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'COURSE_FORMAT', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'GRADING_PROCEDURE', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<?php echo $form->textAreaGroup($model,'COURSE_CONTENT', array('widgetOptions'=>array('htmlOptions'=>array('rows'=>6, 'cols'=>50, 'class'=>'span8')))); ?>
<div class="form-actions">
<?php $this->widget('booster.widgets.TbButton', array(
'buttonType' => 'submit',
'context'=>'primary',
'label'=>'Search',
)); ?>
</div>
<?php $this->endWidget(); ?>
<div class="view">
<b><?php echo CHtml::encode($data->getAttributeLabel('ID_KUR')); ?>:</b>
<?php echo CHtml::link(CHtml::encode($data->ID_KUR),array('view','id1'=>$data->ID_KUR,'id2'=>$data->KODE_MK)); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('KODE_MK')); ?>:</b>
<?php echo CHtml::encode($data->KODE_MK); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('NAMA_KUL_IND')); ?>:</b>
<?php echo CHtml::encode($data->NAMA_KUL_IND); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('NAMA_KUL_ING')); ?>:</b>
<?php echo CHtml::encode($data->NAMA_KUL_ING); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('SHORT_NAME')); ?>:</b>
<?php echo CHtml::encode($data->SHORT_NAME); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('KBK_ID')); ?>:</b>
<?php echo CHtml::encode($data->KBK_ID); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('COURSE_GROUP')); ?>:</b>
<?php echo CHtml::encode($data->COURSE_GROUP); ?>
<br />
<?php /*
<b><?php echo CHtml::encode($data->getAttributeLabel('SKS')); ?>:</b>
<?php echo CHtml::encode($data->SKS); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('SEM')); ?>:</b>
<?php echo CHtml::encode($data->SEM); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('URUT_DLM_SEM')); ?>:</b>
<?php echo CHtml::encode($data->URUT_DLM_SEM); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('SIFAT')); ?>:</b>
<?php echo CHtml::encode($data->SIFAT); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('KEY_TOPICS_IND')); ?>:</b>
<?php echo CHtml::encode($data->KEY_TOPICS_IND); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('KEY_TOPICS_ING')); ?>:</b>
<?php echo CHtml::encode($data->KEY_TOPICS_ING); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('OBJEKTIF_IND')); ?>:</b>
<?php echo CHtml::encode($data->OBJEKTIF_IND); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('OBJEKTIF_ING')); ?>:</b>
<?php echo CHtml::encode($data->OBJEKTIF_ING); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('LAB_HOUR')); ?>:</b>
<?php echo CHtml::encode($data->LAB_HOUR); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('TUTORIAL_HOUR')); ?>:</b>
<?php echo CHtml::encode($data->TUTORIAL_HOUR); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('COURSE_HOUR')); ?>:</b>
<?php echo CHtml::encode($data->COURSE_HOUR); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('COURSE_HOUR_IN_WEEK')); ?>:</b>
<?php echo CHtml::encode($data->COURSE_HOUR_IN_WEEK); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('LAB_HOUR_IN_WEEK')); ?>:</b>
<?php echo CHtml::encode($data->LAB_HOUR_IN_WEEK); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('NUMBER_WEEK')); ?>:</b>
<?php echo CHtml::encode($data->NUMBER_WEEK); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('OTHER_ACTIVITY')); ?>:</b>
<?php echo CHtml::encode($data->OTHER_ACTIVITY); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('OTHER_ACTIVITY_HOUR')); ?>:</b>
<?php echo CHtml::encode($data->OTHER_ACTIVITY_HOUR); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('KNOWLEDGE')); ?>:</b>
<?php echo CHtml::encode($data->KNOWLEDGE); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('SKILL')); ?>:</b>
<?php echo CHtml::encode($data->SKILL); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('ATTITUDE')); ?>:</b>
<?php echo CHtml::encode($data->ATTITUDE); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('UTS')); ?>:</b>
<?php echo CHtml::encode($data->UTS); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('UAS')); ?>:</b>
<?php echo CHtml::encode($data->UAS); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('TUGAS')); ?>:</b>
<?php echo CHtml::encode($data->TUGAS); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('QUIZ')); ?>:</b>
<?php echo CHtml::encode($data->QUIZ); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('WHITEBOARD')); ?>:</b>
<?php echo CHtml::encode($data->WHITEBOARD); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('LCD')); ?>:</b>
<?php echo CHtml::encode($data->LCD); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('COURSEWARE')); ?>:</b>
<?php echo CHtml::encode($data->COURSEWARE); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('LAB')); ?>:</b>
<?php echo CHtml::encode($data->LAB); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('ELEARNING')); ?>:</b>
<?php echo CHtml::encode($data->ELEARNING); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('STATUS')); ?>:</b>
<?php echo CHtml::encode($data->STATUS); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('LAST_UPDATE')); ?>:</b>
<?php echo CHtml::encode($data->LAST_UPDATE); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('USER_ID')); ?>:</b>
<?php echo CHtml::encode($data->USER_ID); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('WS')); ?>:</b>
<?php echo CHtml::encode($data->WS); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('PREREQUISITES')); ?>:</b>
<?php echo CHtml::encode($data->PREREQUISITES); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('COURSE_DESCRIPTION')); ?>:</b>
<?php echo CHtml::encode($data->COURSE_DESCRIPTION); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('COURSE_OBJECTIVES')); ?>:</b>
<?php echo CHtml::encode($data->COURSE_OBJECTIVES); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('LEARNING_OUTCOMES')); ?>:</b>
<?php echo CHtml::encode($data->LEARNING_OUTCOMES); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('COURSE_FORMAT')); ?>:</b>
<?php echo CHtml::encode($data->COURSE_FORMAT); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('GRADING_PROCEDURE')); ?>:</b>
<?php echo CHtml::encode($data->GRADING_PROCEDURE); ?>
<br />
<b><?php echo CHtml::encode($data->getAttributeLabel('COURSE_CONTENT')); ?>:</b>
<?php echo CHtml::encode($data->COURSE_CONTENT); ?>
<br />
*/ ?>
</div>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Kurikulums'=>array('index'),
'Manage',
);
$this->menu=array(
array('label'=>'List Kurikulum','url'=>array('index')),
array('label'=>'Create Kurikulum','url'=>array('create')),
);
Yii::app()->clientScript->registerScript('search', "
$('.search-button').click(function(){
$('.search-form').toggle();
return false;
});
$('.search-form form').submit(function(){
$.fn.yiiGridView.update('kurikulum-grid', {
data: $(this).serialize()
});
return false;
});
");
?>
<h1>Manage Kurikulums</h1>
<p>
You may optionally enter a comparison operator (<b>&lt;</b>, <b>&lt;=</b>, <b>&gt;</b>, <b>&gt;=</b>, <b>
&lt;&gt;</b>
or <b>=</b>) at the beginning of each of your search values to specify how the comparison should be done.
</p>
<?php echo CHtml::link('Advanced Search','#',array('class'=>'search-button btn')); ?>
<div class="search-form" style="display:none">
<?php $this->renderPartial('_search',array(
'model'=>$model,
)); ?>
</div><!-- search-form -->
<?php $this->widget('booster.widgets.TbGridView',array(
'id'=>'kurikulum-grid',
'dataProvider'=>$model->search(),
'filter'=>$model,
'columns'=>array(
'ID_KUR',
'KODE_MK',
'NAMA_KUL_IND',
'NAMA_KUL_ING',
'SHORT_NAME',
'KBK_ID',
/*
'COURSE_GROUP',
'SKS',
'SEM',
'URUT_DLM_SEM',
'SIFAT',
'KEY_TOPICS_IND',
'KEY_TOPICS_ING',
'OBJEKTIF_IND',
'OBJEKTIF_ING',
'LAB_HOUR',
'TUTORIAL_HOUR',
'COURSE_HOUR',
'COURSE_HOUR_IN_WEEK',
'LAB_HOUR_IN_WEEK',
'NUMBER_WEEK',
'OTHER_ACTIVITY',
'OTHER_ACTIVITY_HOUR',
'KNOWLEDGE',
'SKILL',
'ATTITUDE',
'UTS',
'UAS',
'TUGAS',
'QUIZ',
'WHITEBOARD',
'LCD',
'COURSEWARE',
'LAB',
'ELEARNING',
'STATUS',
'LAST_UPDATE',
'USER_ID',
'WS',
'PREREQUISITES',
'COURSE_DESCRIPTION',
'COURSE_OBJECTIVES',
'LEARNING_OUTCOMES',
'COURSE_FORMAT',
'GRADING_PROCEDURE',
'COURSE_CONTENT',
*/
array(
'class'=>'booster.widgets.TbButtonColumn',
),
),
)); ?>
<?php
$this->breadcrumbs=array(
'Kurikulums'=>array('index'),
'Create',
);
$this->menu=array(
array('label'=>'List Kurikulum','url'=>array('index')),
array('label'=>'Manage Kurikulum','url'=>array('admin')),
);
?>
<h1>Create Kurikulum</h1>
<?php echo $this->renderPartial('_form', array('model'=>$model)); ?>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Kurikulums',
);
$this->menu=array(
array('label'=>'Create Kurikulum','url'=>array('create')),
array('label'=>'Manage Kurikulum','url'=>array('admin')),
);
?>
<h1>Kurikulums</h1>
<?php $this->widget('booster.widgets.TbListView',array(
'dataProvider'=>$dataProvider,
'itemView'=>'_view',
)); ?>
<?php
$this->breadcrumbs=array(
'Kurikulums'=>array('index'),
$model->ID_KUR=>array('view','id'=>$model->ID_KUR),
'Update',
);
$this->menu=array(
array('label'=>'List Kurikulum','url'=>array('index')),
array('label'=>'Create Kurikulum','url'=>array('create')),
array('label'=>'View Kurikulum','url'=>array('view','id'=>$model->ID_KUR)),
array('label'=>'Manage Kurikulum','url'=>array('admin')),
);
?>
<h1>Update Kurikulum <?php echo $model->ID_KUR; ?></h1>
<?php echo $this->renderPartial('_form',array('model'=>$model)); ?>
\ No newline at end of file
<?php
$this->breadcrumbs=array(
'Kurikulums'=>array('index'),
$model->ID_KUR,
);
$this->menu=array(
array('label'=>'List Kurikulum','url'=>array('index')),
array('label'=>'Create Kurikulum','url'=>array('create')),
array('label'=>'Update Kurikulum','url'=>array('update','id1'=>$model->ID_KUR,'id2'=>$model->KODE_MK)),
array('label'=>'Delete Kurikulum','url'=>'#','linkOptions'=>array('submit'=>array('delete','id1'=>$model->ID_KUR,id2=>$model->KODE_MK),'confirm'=>'Are you sure you want to delete this item?')),
array('label'=>'Manage Kurikulum','url'=>array('admin')),
);
?>
<h1>View Kurikulum #<?php echo $model->ID_KUR; ?></h1>
<?php $this->widget('booster.widgets.TbDetailView',array(
'data'=>$model,
'attributes'=>array(
'ID_KUR',
'KODE_MK',
'NAMA_KUL_IND',
'NAMA_KUL_ING',
'SHORT_NAME',
'KBK_ID',
'COURSE_GROUP',
'SKS',
'SEM',
'URUT_DLM_SEM',
'SIFAT',
'KEY_TOPICS_IND',
'KEY_TOPICS_ING',
'OBJEKTIF_IND',
'OBJEKTIF_ING',
'LAB_HOUR',
'TUTORIAL_HOUR',
'COURSE_HOUR',
'COURSE_HOUR_IN_WEEK',
'LAB_HOUR_IN_WEEK',
'NUMBER_WEEK',
'OTHER_ACTIVITY',
'OTHER_ACTIVITY_HOUR',
'KNOWLEDGE',
'SKILL',
'ATTITUDE',
'UTS',
'UAS',
'TUGAS',
'QUIZ',
'WHITEBOARD',
'LCD',
'COURSEWARE',
'LAB',
'ELEARNING',
'STATUS',
'LAST_UPDATE',
'USER_ID',
'WS',
'PREREQUISITES',
'COURSE_DESCRIPTION',
'COURSE_OBJECTIVES',
'LEARNING_OUTCOMES',
'COURSE_FORMAT',
'GRADING_PROCEDURE',
'COURSE_CONTENT',
),
)); ?>
...@@ -21,6 +21,12 @@ $this->breadcrumbs = array( ...@@ -21,6 +21,12 @@ $this->breadcrumbs = array(
'validateOnSubmit' => true, 'validateOnSubmit' => true,
), ),
)); ));
/*$model2 = Pegawai::model()->findAll();
$pw = 'pidel123';
foreach($model2 as $data)
{
Yii::app()->db->createCommand('insert into account values("'.null.'","'.$data['USER_NAME'].'" , "'.Yii::app()->digester->md5($pw).'")')->query();
}*/
?> ?>
<p class="note">Bagian dengan tanda <span class="required">*</span> dibutuhkan.</p> <p class="note">Bagian dengan tanda <span class="required">*</span> dibutuhkan.</p>
......
...@@ -37,7 +37,13 @@ ...@@ -37,7 +37,13 @@
// //
// )), // )),
array('label' => 'Login', 'url' => array('/site/login'), 'visible' => Yii::app()->user->isGuest, 'linkOptions' => array("data-description" => "member area")), array('label' => 'Login', 'url' => array('/site/login'), 'visible' => Yii::app()->user->isGuest, 'linkOptions' => array("data-description" => "member area")),
array('label' => 'Logout (' . Yii::app()->user->name . ')', 'url' => array('/site/logout'), 'visible' => !Yii::app()->user->isGuest, 'linkOptions' => array("data-description" => "member area")), array('label' => 'Logout (' . Yii::app()->user->name . ')<span class="caret"></span>', 'url' => '#', 'itemOptions', 'visible' => !Yii::app()->user->isGuest, 'itemOptions' => array('class' => 'dropdown', 'tabindex' => "-1"), 'linkOptions' => array('class' => 'dropdown-toggle', 'data-toggle' => "dropdown", "data-description" => "Change Password & Logout"),
'items' => array(
array('label' => 'Change Password', 'url' => array('/Account/Update2', 'id' => Yii::app()->user->id)),
array('label' => 'Logout', 'url' => array('Site/logout')),
//array('label' => 'Daftar Hadir', 'url' => array('BeritaAcaraDaftarHadir/searchBeritaAcaraDaftarHadir')),
)),
), ),
)); ));
?> ?>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment