Exemplo n.º 1
0
Arquivo: table.php Projeto: pumi11/aau
 print "<td>" . $ur_region['name'] . "</td>";
 $modal_ur_id = "modal" . $region_id . "_" . $user_id;
 $modal_apteki_id = "modal_a" . $region_id . "_" . $user_id;
 $modal_ur = \yii\bootstrap\Modal::widget(['id' => $modal_ur_id, 'toggleButton' => ['label' => $ur_region['count'], 'tag' => 'a', 'data-target' => "#{$modal_ur_id}", 'href' => Url::toRoute(["/vznos/modalplat/?region_id={$region_id}&regional_id={$user_id}"]), 'class' => 'badge'], 'clientOptions' => false]);
 print "<td align='center'>" . $modal_ur . "</td>";
 foreach ($apteki_region_array[$user_id] as $apteki_region) {
     if ($apteki_region['id'] == $region_id) {
         $apteki_count = $apteki_region['count'];
     }
 }
 if ($apteki_count == "") {
     $apteki_count = 0;
 }
 $modal_apteki = \yii\bootstrap\Modal::widget(['id' => $modal_apteki_id, 'toggleButton' => ['label' => $apteki_count, 'tag' => 'a', 'data-target' => "#{$modal_apteki_id}", 'href' => Url::toRoute(["/vznos/modalapteki/?region_id={$region_id}&regional_id={$user_id}"]), 'class' => 'badge'], 'clientOptions' => false]);
 print "<td align='center'>" . $modal_apteki . "</td>";
 $id_ur_l = Vznos::getUr_l_in_region($user_id, $region_id);
 $all_ur = ArrayHelper::getColumn($id_ur_l, 'id');
 $oplatili = Vznos::Oplatalili($all_ur);
 foreach ($kv = Vznos::getKvartals(null, 3) as $date) {
     $array_date = $date['year'] . $date['kvartal'];
     print "<td align='center'>";
     $neOplatili = Vznos::NeOplatalili($all_ur, $oplatili, $region_id, $user_id, $date);
     $count_n[$array_date] = $count_n[$array_date] + $neOplatili;
     $nurl = implode(",", Vznos::$neoplatili_ur_l);
     print \yii\bootstrap\Modal::widget(['id' => $modal_apteki_id, 'toggleButton' => ['label' => $neOplatili, 'tag' => 'a', 'data-target' => "#{$modal_apteki_id}", 'href' => Url::toRoute(["/vznos/modalneoplatili2/?ur_ls={$nurl}"]), 'class' => 'badge'], 'clientOptions' => false]);
     print "</td>";
 }
 print "</tr>\n";
 $c_a = $c_a + $apteki_count;
 $c_u = $c_u + $ur_region['count'];
 $c++;
Exemplo n.º 2
0
 public function actionModalplat($regional_id, $region_id)
 {
     $return = Vznos::getUr_l_in_region($regional_id, $region_id);
     $this->layout = 'modal_400';
     return $this->render('modalplat', compact(['return']));
     //  return $this->render('index');
 }