当前位置: 首页>>代码示例>>PHP>>正文


PHP Account::getMyRole方法代码示例

本文整理汇总了PHP中Account::getMyRole方法的典型用法代码示例。如果您正苦于以下问题:PHP Account::getMyRole方法的具体用法?PHP Account::getMyRole怎么用?PHP Account::getMyRole使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在Account的用法示例。


在下文中一共展示了Account::getMyRole方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: home

    function home()
    {
        $arrTabs = $this->loadedDomains4Role[Account::getMyRole()];
        $arrDomain = $this->domains;
        //mold ini masi ada logic dibelakangnya untuk first loadnya..
        //Mold::both("header",array("arrTabs"=>$arrTabs,"arrDomain"=>$arrDomain));
        //$st = new Schoolsetup();
        //$st->getEffDay();
        //Mold::both("timeline");
        ?>
        <script type="text/javascript">
            $(document).ready(function () {
                openLw('Home', '<?php 
        echo _SPPATH;
        ?>
homeLoad', 'fade');
            });
        </script>
    <?php 
    }
开发者ID:CapsuleCorpIndonesia,项目名称:elang-combo,代码行数:20,代码来源:Leap.php

示例2:

                    <?php 
echo RoleLevel::getMy()->level_name;
?>
                </td>
            </tr>
            <tr>
                <td>
                    <?php 
echo Lang::t('Administrator Role');
?>
 :
                </td>
                
                <td>
                    <?php 
echo Account::getMyRole();
?>
                </td>
            </tr>
        </table>
        <h3 style="padding-left: 10px;"><?php 
echo Lang::t('Account Details');
?>
</h3>
        <table class="table table-striped">
            <tr>
                <td>
                    <?php 
echo Lang::t('Username');
?>
 :
开发者ID:CapsuleCorpIndonesia,项目名称:es-teler-baru-suka,代码行数:31,代码来源:myprofile.php

示例3: openLw

                    event.preventDefault();
                    $('#myModalLabel').empty().append('<?php 
echo Lang::t('Compose Message');
?>
');
                    $('#myModalBody').load('<?php 
echo _SPPATH;
?>
inboxweb/composeByID?acc_id=<?php 
echo $acc->admin_id;
?>
');
                });
            </script>
            <?php 
if (Account::getMyRole() != "murid") {
    ?>
                <button style="margin-top:5px;" id="Gallery<?php 
    echo $acc->admin_id;
    ?>
" type="button"
                        class="btn btn-primary btn-block"><?php 
    echo Lang::t('Upload Photos');
    ?>
</button>
                <script>
                    $('#Gallery<?php 
    echo $acc->admin_id;
    ?>
').click(function () {
                        openLw('ViewGallery<?php 
开发者ID:CapsuleCorpIndonesia,项目名称:elang-combo,代码行数:31,代码来源:profile.php

示例4: addLog

 public static function addLog($ket = "", $action = 'browse')
 {
     $bl = new BLogger();
     $bl->b_log_ip = $_SERVER['REMOTE_ADDR'];
     $bl->b_log_userid = Account::getMyID();
     $bl->b_log_time = leap_mysqldate();
     $uri = $_SERVER['REQUEST_URI'];
     $pos = strpos($uri, 'DMWeb');
     if ($pos !== false) {
         $uri = 'DMWeb';
     }
     $bl->b_log_url = $uri;
     $bl->b_log_action = $action;
     $bl->b_log_username = Account::getMyUsername();
     $bl->b_log_keterangan = $ket;
     $bl->b_timestamp = time();
     $bl->b_log_userrole = Account::getMyRole();
     $md = new \Leap\Utility\MobileDetect();
     $isMobile = $md->isMobile();
     $isTablet = $md->isTablet();
     $userAgent = $md->getUserAgent();
     $txt = "";
     if ($isMobile) {
         $txt .= "Mobile";
     } elseif ($isTablet) {
         $txt .= "Tablet";
     } else {
         $txt .= "Desktop";
     }
     $bl->b_log_user_agent = $txt . " | {$userAgent}";
     $bl->log_user_org = PortalHierarchy::getMyOrganization();
     $bl->log_user_level = PortalHierarchy::getMyLevel();
     $bl->save();
 }
开发者ID:CapsuleCorpIndonesia,项目名称:elang-combo,代码行数:34,代码来源:BLogger.php

示例5: selectMPNoRestriction

><?php 
        echo $slots[$day][$kelasName][0]->namaMatapelajaran;
        ?>
</td>
                <?php 
    }
    ?>
            </tr>
            <?php 
    $slotID++;
}
?>
    </table>
</div>
<?php 
if (Account::getMyRole() == "supervisor" || Account::getMyRole() == "tatausaha") {
    ?>
    <script>
        function selectMPNoRestriction(slotID, day, mp_id, mp_type) {
            //alert(slotID+" "+day);
            //$('#kls<?php 
    echo $kls->kelas_id;
    ?>
_'+slotID+'_'+day).load('<?php 
    echo _SPPATH;
    ?>
index');

            $('#kls<?php 
    echo $kls->kelas_id;
    ?>
开发者ID:CapsuleCorpIndonesia,项目名称:biji_katak,代码行数:31,代码来源:jadwalmatapelajaranWeekly.php

示例6:

        }

        .walltext {
            clear: both;
        }

        .fotocontainer {
            margin-bottom: 10px;
        }
    </style>
    <h1><?php 
echo Lang::t('Schoolwall');
?>
</h1>
<?php 
if (Account::getMyRole() == "supervisor" && !$noPost) {
    ?>
    <div id='writewall<?php 
    echo $t;
    ?>
' data-toggle="modal" data-target="#myModal"
         style="width:100%; height: 30px; line-height: 30px; color: #999999; text-align: center; border-bottom: 1px solid #aaaaaa;">
        <?php 
    echo Lang::t("Write On Wall");
    ?>
    </div>
    <script type="text/javascript">
        $("#writewall<?php 
    echo $t;
    ?>
").click(function () {
开发者ID:CapsuleCorpIndonesia,项目名称:elang-combo,代码行数:31,代码来源:school_wall.php

示例7: composewall

 public function composewall()
 {
     $ta = TahunAjaran::ta();
     $typ = isset($_GET['typ']) ? addslashes($_GET['typ']) : '';
     $klsid = isset($_GET['klsid']) ? addslashes($_GET['klsid']) : '';
     $cmd = isset($_GET['cmd']) ? addslashes($_GET['cmd']) : 'form';
     if ($typ == "") {
         die('Type must be defined');
     }
     if ($typ == "kelas" && $klsid == "") {
         die("Kelas must be defined");
     }
     $return['webClass'] = __CLASS__;
     $return['method'] = __FUNCTION__;
     if ($cmd == "form") {
         $return["typ"] = $typ;
         $return["klsid"] = $klsid;
         $return['id'] = Wall::createID();
         Mold::both("wall/compose", $return);
     }
     if ($cmd == "add") {
         $json['bool'] = 0;
         $json['err'] = '';
         if (isset($_POST['wall_msg'])) {
             $wall_msg = trim(rtrim($_POST['wall_msg']));
         }
         if ($wall_msg == '') {
             $json['err'] .= Lang::t('Message is empty');
         }
         $id = isset($_GET['id']) ? addslashes($_GET['id']) : '';
         if ($id == '') {
             $json['err'] .= Lang::t('Id is empty');
         }
         if ($json['err'] == '') {
             //$wall_msg = addslashes(strip_tags(trim(rtrim ($_POST['wall_msg'])),'<p><a><br><b><i><img><hr>'));
             // am 01.10.2014,insert <embed><iframe> vom Efindi
             $wall_msg = strip_tags(trim(rtrim($_POST['wall_msg'])), '<p><a><br><b><i><img><hr><embed><iframe>');
             if ($typ == "kelas") {
                 $wall = new MuridWall();
                 $wall->wall_id = $id;
                 $wall->wall_msg = $wall_msg;
                 $wall->wall_from = Account::getMyIDwithCheck();
                 $wall->wall_kelas_id = $klsid;
                 $wall->wall_role = Account::getMyRole();
                 $wall->wall_ta_id = $ta;
                 $tgl = Wall::getDateTime();
                 $wall->wall_date = $tgl;
                 $wall->wall_update = $tgl;
                 $json['bool'] = $wall->save();
             }
             if ($typ == "school") {
                 $wall2 = new SchoolWall();
                 $wall2->wall_id = $id;
                 $wall2->wall_msg = $wall_msg;
                 $wall2->wall_from = Account::getMyIDwithCheck();
                 $wall2->wall_role = Account::getMyRole();
                 Auth::checkRole("supervisor");
                 $wall2->wall_kls_ta = "school";
                 $tgl = Wall::getDateTime();
                 $wall2->wall_date = $tgl;
                 //  echo "in";
                 //  die($wall_msg);
                 $json['bool'] = $wall2->save();
             }
         }
         die(json_encode($json));
     }
 }
开发者ID:CapsuleCorpIndonesia,项目名称:elang-combo,代码行数:68,代码来源:Wallweb.php

示例8: myProfile

 public function myProfile()
 {
     $role = Account::getMyRole();
     if ($role == "murid") {
         $murid = new Murid();
         $murid->default_read_coloms = "*";
         $murid->getByAccountID(Account::getMyID());
         //pr($murid);
         $ta = TahunAjaran::ta();
         $kelas = $murid->getMyKelas($ta);
         //pr($murid);
         //get all my kelas
         $kelases = $murid->getAllMyKelas();
         $return['webClass'] = __CLASS__;
         $return['method'] = __FUNCTION__;
         $return['murid'] = $murid;
         $return['kelas'] = $kelas;
         $return['kelases'] = $kelases;
         Mold::both("murid/myprofile", $return);
     } else {
         $roleObj = new $role();
         $roleObj->default_read_coloms = "*";
         $roleObj->getByAccountID(Account::getMyID());
         $return['webClass'] = __CLASS__;
         $return['method'] = __FUNCTION__;
         $return['roleObj'] = $roleObj;
         Mold::both("leap/myprofile", $return);
     }
 }
开发者ID:CapsuleCorpIndonesia,项目名称:elang-combo,代码行数:29,代码来源:Muridweb.php


注:本文中的Account::getMyRole方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。