case 161100:
            $satker = DaftarUnit::find()->where('unit_id in (0)')->all();
            break;
        case 151000:
            $satker = DaftarUnit::find()->where('unit_id=0')->all();
            break;
        default:
            echo "";
    }
    foreach ($satker as $sat) {
        ?>
                        <tr>
                            <th  width="240" bgcolor="gray" align="left">
                                <div class="pull-right">
                                    <?php 
        echo HelperUnit::Apagu($sat->unit_id);
        ?>
   
                                </div>

                            </th>
                            <td align="center"><?php 
        $pag = HelperUnit::Pagu($sat->unit_id);
        $pagn = number_format(HelperUnit::Pagu($sat->unit_id), 0, ",", ".");
        echo $pagn;
        ?>
   
                             </td>
                            <td align="center">
                            	<?php 
        $re = HelperUnit::Real($sat->unit_id);
示例#2
0
                                                    <?php 
                break;
            case 151000:
                ?>
                                                    <h6> <?php 
                echo Html::a(HelperUnit::Apagu($sat->unit_id), Yii::$app->urlManager->createUrl(['simpel-keg/tabarsip', 'unit' => '161100']), ['title' => Yii::t('yii', 'Proses')]);
                ?>
 </h6>  

                                                    <?php 
                break;
            default:
                ?>
                                                    <h6> <?php 
                echo Html::a(HelperUnit::Apagu($sat->unit_id), Yii::$app->urlManager->createUrl(['simpel-keg/tabarsip', 'unit' => $sat->unit_id]), ['title' => Yii::t('yii', 'Proses')]);
                ?>
 </h6> 
                                                    <?php 
                break;
        }
        ?>

                                        </div>

                                    </td>

                                    <td width="120" align="center">
                                               <?php 
        switch ($sat->unit_id) {
            case 161100:
示例#3
0
            break;
        case 151000:
            $jum = Yii::$app->db->createCommand("SELECT \n                                sum(alokasi_sub_mak) as total\n                             FROM pagu_mak where tahun=" . $tahun . " and unit_id in(151000)")->queryScalar();
            $totalreal = Yii::$app->db->createCommand("SELECT SUM(jml) as JUMLah FROM `simpel_rincian_biaya` as g WHERE id_kegiatan in \n                            (SELECT a.id_kegiatan FROM simpel_keg a  LEFT JOIN \n                             pegawai.daf_unit b ON a.unit_id=b.unit_id WHERE status=4 and g.bukti_kwitansi in(1,2) and \n                             b.unit_id \n                             IN (SELECT c.unit_id FROM  pegawai.daf_unit c  WHERE c.unit_parent_id in (151000) ))")->queryScalar();
            break;
        default:
            echo "";
    }
    ?>
                    <tr bgcolor="#68C8E8" >
                        <th><?php 
    echo $no;
    ?>
.</th>
                        <th > <?php 
    echo \common\components\HelperUnit::Apagu($unit->unit_id);
    ?>
</th>
                        <th><?php 
    echo number_format($jum, 0, ",", ".");
    ?>
</th>
                        <?php 
    for ($i = 1; $i < 13; $i++) {
        if ($i < 10) {
            $a = '0' . $i;
        } else {
            $a = $i;
        }
        switch ($unit->unit_id) {
            case 110000: