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


PHP Helpers::getTotalInvestorBid方法代码示例

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


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

示例1: show

 /**
  * Display the specified resource.
  *
  * @param  int  $id
  * @return Response
  */
 public function show($id, $option = false)
 {
     if (strtolower(Session::get('account_type')) == 'admin') {
         $transactions = Mradiwallettransaction::where('user_id', $id)->orderBy('id', 'desc')->paginate(15);
         $myBalance = Helpers::investorBalance($id);
         $totalInvestorBid = Helpers::getTotalInvestorBid($id, false, true);
         return View::make('admin.pages.investor_transactions_admin')->with(compact('totalInvestorBid', 'myBalance'))->withObjects($transactions);
     } else {
         //get transactions of a single investor
         $transactions = Mraditransactionlog::find($id);
         // show the view and pass the investor transactions to it
         return View::make('admin.pages.jambo_form')->withObjects($transactions);
     }
 }
开发者ID:centaurustech,项目名称:bmradi,代码行数:20,代码来源:WalletController.php

示例2: number_format

                <input type="text" name="subscribers_email" class="form-control" placeholder="Email Address" style="height:30px;">               
                <span class="input-group-btn">
                    <button class="btn btn-default" type="submit" style="height:30px; padding-top: 1px">Subscribe Newsletter</button>
                </span>
                
            </div></div></center></div>

<div class="video_spacer"></div>
<div id="sticky-anchor"></div>
<?php 
include 'common/headerB.php';
?>


<center><h1 style="color: #57A0C9; font-size: 40px; font-family: 'Kirvy-regular'; clear: both;">Over <b>KES <?php 
echo number_format(Helpers::getTotalInvestorBid("guest")->sum('Amount'), 2);
?>
</b> Raised</h1></center>


<!--<div style='height: 720px;'></div> -->
<div style="width: 100%; clear: both; background: url('<?php 
echo url();
?>
/media/img/xcx.jpg') no-repeat; padding: 20px; margin-top: 30px">   
    <div class="jumbotron center-block" style='border-top: 1px #ccc solid; clear: both; width: 70%; background-color: #96864C; background-color: rgba(252, 228, 106, 0.8); padding: 20px;  margin-top: 30px;'>
        <h3 style='color: #fff;' class="mradi_header">Mradifund</h3>
        <p class="lead" style='font-size: 1.1em;  color: #000000; '>
            <span style=""><b>Mradifund is an online fundraising platform. We connect small business owners with investors who provide the expansion
                    capital and mentorship they need to get to the next level. <br />At the same time, we give investors an opportunity to hand pick  
                    small companies to privately invest it, allowing them to diversify their portfolios and find the next big thing before it 
开发者ID:centaurustech,项目名称:bmradi,代码行数:31,代码来源:index4.php

示例3: getList

    public function getList($status = false)
    {
        //get all bids
        // load the view and pass the all transactions
        $status = e(Input::get('categories_list'));
        if ($status == "" || $status == "All") {
            $condition = "";
        } else {
            $condition = " where tbl_campaigns.campaignstatus = '" . $status . "'";
        }
        if (strtolower(Session::get('account_type')) == 'admin') {
            $transactions = DB::select(DB::raw('select mcb.*, drv.*, tbl_campaigns.campaignstatus from mradicampaignbids mcb
							inner join
							(SELECT campaign_id as cid, count(id) as count, max(total_bidded) as totalBid, max(updated_at) as last_bid
							from mradicampaignbids group by campaign_id order by id desc) drv
							on mcb.campaign_id = drv.cid
							inner join tbl_campaigns on mcb.campaign_id = tbl_campaigns.uniqueid
							' . $condition . '
							group by mcb.campaign_id'));
            $pageNumber = Input::get('page', 1);
            $perpage = 15;
            $slice = array_slice($transactions, $perpage * ($pageNumber - 1), $perpage);
            $transactions = Paginator::make($slice, count($transactions), $perpage);
        } elseif (strtolower(Session::get('account_type')) == 'entrepreneur') {
            $con = "where " . strtolower(Session::get('account_type')) . "_id = " . Session::get('account_id');
            $transactions = DB::select(DB::raw('select mcb.*, drv.*, tbl_campaigns.campaignstatus from mradicampaignbids mcb 
							inner join
							(SELECT campaign_id as cid, count(id) as count, max(total_bidded) as totalBid, max(updated_at) as last_bid
							from mradicampaignbids ' . $con . ' group by campaign_id order by id desc) drv
							on mcb.campaign_id = drv.cid
							inner join tbl_campaigns on mcb.campaign_id = tbl_campaigns.uniqueid
							' . $condition . '
							group by mcb.campaign_id'));
            $pageNumber = Input::get('page', 1);
            $perpage = 15;
            $slice = array_slice($transactions, $perpage * ($pageNumber - 1), $perpage);
            $transactions = Paginator::make($slice, count($transactions), $perpage);
        } else {
            //$transactions = Mradicampaignbid::where(strtolower(Session::get('account_type')).'_id', Session::get('account_id'))->orderBy('id','desc')->paginate(15);
            $con = "where " . strtolower(Session::get('account_type')) . "_id = " . Session::get('account_id');
            $transactions = DB::select(DB::raw('select mcb.*, drv.*, tbl_campaigns.campaignstatus from mradicampaignbids mcb 
							inner join
							(SELECT campaign_id as cid, count(id) as count, max(total_bidded) as totalBid, max(updated_at) as last_bid
							from mradicampaignbids ' . $con . ' group by campaign_id order by id desc) drv
							on mcb.campaign_id = drv.cid
							inner join tbl_campaigns on mcb.campaign_id = tbl_campaigns.uniqueid
							' . $condition . '
							group by mcb.campaign_id'));
            $pageNumber = Input::get('page', 1);
            $perpage = 15;
            $slice = array_slice($transactions, $perpage * ($pageNumber - 1), $perpage);
            $transactions = Paginator::make($slice, count($transactions), $perpage);
        }
        $totalInvestorBid = Helpers::getTotalInvestorBid(Session::get('account_id'));
        $totalOnlineBid = Helpers::getTotalInvestorBid(Session::get('account_id'), true);
        $myBalance = Helpers::investorBalance(Session::get('account_id'));
        return View::make('admin.pages.campaign_bids')->with(compact('totalInvestorBid', 'myBalance', 'totalOnlineBid'))->withObjects($transactions);
    }
开发者ID:centaurustech,项目名称:bmradi,代码行数:58,代码来源:BidController.php


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