This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//conf/main.php | |
'modules' => [//add by Scott | |
'gridview' => [ | |
'class' => '\kartik\grid\Module' | |
// enter optional module parameters below - only if you need to | |
// use your own export download action or custom translation | |
// message source | |
// 'downloadAction' => 'gridview/export/download', | |
// 'i18n' => [] | |
], |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public function actionIndex() | |
{ | |
/* variable content View Side Menu Author: -Eka- */ | |
//set menu side menu index - Array Jeson Decode | |
// $side_menu=M1000::find()->findMenu('sss_berita_acara')->one()->jval; | |
//$side_menu=json_decode($side_menu,true); | |
/* variable content View Employe Author: -ptr.nov- */ | |
$searchModel = new EmployeSearch(); | |
$dataProvider = $searchModel->search(Yii::$app->request->queryParams); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!-- | |
How to use Google JS Visualization Api offline, step by step | |
this approach might work with other libraries loaded with google.load, after all it's still JavaScript!!! | |
--> | |
<!DOCTYPE html> | |
<html> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// make a comma delimited list | |
$string = join(',', $array); | |
Or loop yourself: | |
$string = ''; | |
foreach ($array as $key => $value) { | |
$string .= ",$value"; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$dbExercises = Exercise::model()->find($someCriteria); | |
$exercises = new JSONArray(); | |
foreach ($dbExercises as $model) { | |
$exercise = new JSONArray(); | |
$exercise->uid = $model->uid; | |
$exercise->name = $model->name_de; | |
$exercise->version = $model->version; | |
foreach ($model->categories as $modCategory) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/*Author -ptr.nov- */ | |
$this->registerJs('FusionCharts.ready(function () { | |
var jsonData= $.ajax({ | |
url: "http://localhost-api.int/notify/hrd_personas?access-token=azLSTAYr7Y7TLsEAML-LsVq9cAXLyAWa", | |
dataType:"json", | |
async: false | |
}).responseText; | |
var myData = jsonData; | |
var chart = new FusionCharts({ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Definitation doc | |
* @author me | |
* @version 0.1 | |
* @package application.components | |
* @param string $bar param description {@link DummyClassB} | |
* @return DummyClassA | |
* @var | |
* @inheritdoc => | |
@throws NotFoundHttpException if the model cannot be found |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php $form = ActiveForm::begin([ | |
// 'beforeSubmit' => 'window.forms.candidate', | |
'enableClientValidation' => true, | |
// 'enableAjaxValidation' => true, | |
'id' => 'someform' | |
]); ?> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
Modal::begin( | |
[ | |
'size' => Modal::SIZE_LARGE, | |
'options' => ['class'=>'slide'], | |
] | |
); | |
echo $this->render('view', ['model' => $model]); | |
Modal::end(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$this->registerJs(" | |
$.fn.modal.Constructor.prototype.enforceFocus = function() {}; | |
$('#stock-gudang').on('show.bs.modal', function (event) { | |
var button = $(event.relatedTarget) | |
var modal = $(this) | |
var title = button.data('title') | |
var href = button.attr('href') | |
modal.find('.modal-title').html(title) | |
modal.find('.modal-body').html('<i class=\"fa fa-spinner fa-spin\"></i>') | |
$.post(href) |
OlderNewer