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


PHP Branch::model方法代码示例

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


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

示例1: getOptions

 public static function getOptions($no_select = null)
 {
     $model = Branch::model()->findAll();
     $arr = array();
     if ($no_select == true) {
         $arr[] = '--- ไม่เลือกรายการ ---';
     }
     foreach ($model as $r) {
         $arr[$r->branch_id] = $r->branch_name;
     }
     return $arr;
 }
开发者ID:adsavin,项目名称:bswshop,代码行数:12,代码来源:Branch.php

示例2: renderContent

 protected function renderContent()
 {
     $id = Yii::app()->user->getState('org_id');
     if (!empty($id)) {
         $branch = Yii::app()->db->createCommand()->selectDistinct('branch_id')->from('attendence att')->join('academic_term ac', 'ac.academic_term_id = att.sem_name_id')->where("ac.current_sem=1 AND ac.academic_term_organization_id=" . $id)->queryAll();
         /*$branch = Yii::app()->db->createCommand()
                 	->selectDistinct('branch_id')
         		->from('attendence')
         		//->order('branch_id DESC')
         		->where('attendence_organization_id='.$id)
         		->queryAll();*/
         $attendence = Yii::app()->db->createCommand()->select('count(attendence)')->from('attendence att')->group('branch_id')->join('academic_term ac', 'ac.academic_term_id = att.sem_name_id')->where('ac.current_sem=1 AND att.attendence="P" and att.attendence_organization_id=' . $id)->queryAll();
         $all = Yii::app()->db->createCommand()->select('count(attendence)')->from('attendence att')->group('branch_id')->join('academic_term ac', 'ac.academic_term_id = att.sem_name_id')->where('ac.current_sem=1 AND att.attendence_organization_id=' . $id)->queryAll();
         $xaxis = array();
         $yaxis = array();
         //print_r($all[0]['count(attendence)']);
         foreach ($branch as $xvalue) {
             foreach ($xvalue as $x) {
                 $xaxis[] = Branch::model()->findByPk($x)->branch_name;
             }
         }
         $i = 0;
         foreach ($attendence as $yvalue) {
             foreach ($yvalue as $y) {
                 $yaxis[] = round($y * 100 / $all[$i]['count(attendence)'], 2);
             }
             $i += 1;
         }
         if (!empty($branch)) {
             echo "<div id=\"container\" style=\"min-width: 00px; height: 230px; margin: 0 auto\"></div>";
             for ($i = 0; $i < count($xaxis); $i++) {
                 $t = 0;
                 $n[$i][$t] = $xaxis[$i];
                 $n[$i][$t + 1] = $yaxis[$i];
             }
             //print_r($n);
             //print_r($m);
             //$l = array_combine($n,$m);
             //print_r($l);
             $this->Widget('ext.highcharts.HighchartsWidget', array('options' => array('chart' => array('renderTo' => 'container', 'type' => 'column'), 'title' => array('text' => 'Branch Wise Attendence'), 'xAxis' => array('categories' => $xaxis), 'yAxis' => array('min' => 0, 'max' => 100, 'title' => array('text' => 'Attendence')), 'legend' => array('layout' => 'vertical', 'backgroundColor' => '#FFFFFF', 'align' => 'left', 'verticalAlign' => 'top', 'x' => 100, 'y' => 70, 'floating' => true, 'shadow' => true), 'tooltip' => array('formatter' => 'js:function() { return "<b>"+ this.x +"</b>: "+ this.y +" Per"; }'), 'plotOptions' => array('column' => array('pointPadding' => 0.2, 'borderWidth' => 0)), 'series' => array(array('data' => $n)))));
         }
     }
 }
开发者ID:sharmarakesh,项目名称:edusec-college-management-system,代码行数:43,代码来源:Attendance.php

示例3: actionRecpt_list

 public function actionRecpt_list()
 {
     $this->layout = 'receipt_layout';
     $misc_fees_payment = MiscellaneousFeesPaymentCheque::model()->findByPk($_REQUEST['id']);
     $model = StudentTransaction::model()->findByPk($misc_fees_payment->miscellaneous_fees_payment_cheque_student_id);
     $stud_id = $model->student_transaction_student_id;
     $stud_model = StudentInfo::model()->findByPk($model->student_transaction_student_id);
     $acd_term = AcademicTermPeriod::model()->findByPk($model->student_academic_term_period_tran_id);
     $branch = Branch::model()->findByPk($model->student_transaction_branch_id);
     //print_r($_REQUEST['id']);
     //print "<br/>model".$misc_fees_payment->miscellaneous_fees_payment_cash_student_id;
     //print "<br/>reciept_no".$misc_fees_payment->miscellaneous_fees_payment_cash_receipt_id;
     //print "<br/>stud_id".$model->student_transaction_student_id;
     //print "<br/>curent date".date('d/m/y');
     //print "<br/>stud_model".$stud_model->student_first_name.''.$stud_model->student_middle_name.''.$stud_model->student_last_name;
     //print "<br/>dbdate".$misc_fees_payment->miscellaneous_fees_payment_cash_creation_date;
     //print "<br/>branch_name".$branch->branch_name;
     //print "<br/>academic_term".$acd_term->academic_terms_period_name;
     //print "</br>roll no".$stud_model->student_roll_no;
     //exit;
     $this->render('recpt_list', array('model' => $model, 'stud_model' => $stud_model, 'acd_term' => $acd_term, 'branch' => $branch, 'misc_fees_payment' => $misc_fees_payment));
 }
开发者ID:sharmarakesh,项目名称:edusec-college-management-system,代码行数:22,代码来源:MiscellaneousFeesPaymentChequeController.php

示例4:

?>
</legend>
		<div class="row">
			<?php 
echo $form->labelEx($model, 'app_subject');
?>
			<?php 
echo $form->textArea($model, 'app_subject');
?>
		</div>
        <div class="row">
			<?php 
echo $form->labelEx($model, 'calendarID');
?>
			<?php 
echo $form->dropDownList($model, 'calendarID', CHtml::listData(Branch::model()->findAll(['scopes' => 'active']), 'bra_id', 'bra_title'));
?>
        </div>
		<div class="row">
			<?php 
echo $form->labelEx($model, 'app_user');
?>
			<?php 
echo $form->dropDownList($model, 'app_user', CHtml::listData(User::model()->findAll("use_status='Active'"), 'use_id', 'fullName'));
?>
		</div>
		<div class="row">
			<label>Attendees</label>
			<input type="button" value="Select attendees" id="selectAttendees">
		</div>
		<div class="row">
开发者ID:jankichaudhari,项目名称:yii-site,代码行数:31,代码来源:_appointment.php

示例5: array

echo $form->error($model, 'student_academic_term_name_id');
?>
	</div>	


</div>
	
<div class="row">


	<div class="row-left">
		<?php 
echo $form->labelEx($model, 'student_transaction_branch_id');
?>
		<?php 
echo $form->dropDownList($model, 'student_transaction_branch_id', CHtml::listData(Branch::model()->findAll(array('condition' => 'branch_organization_id=' . $org_id)), 'branch_id', 'branch_name'), array('prompt' => '-----------Select-----------', 'tabindex' => 11, 'ajax' => array('type' => 'POST', 'url' => CController::createUrl('dependent/getStudDivision'), 'dataType' => 'json', 'success' => 'function(data) {

		                  $("#StudentTransaction_student_transaction_division_id").html(data.div);
				  $("#StudentTransaction_student_transaction_batch_id").html(data.bat);
				
		                }')));
?>
<span class="status">&nbsp;</span>
		<?php 
echo $form->error($model, 'student_transaction_branch_id');
?>
	</div>
	
	<div class="row-right">
		<?php 
echo $form->labelEx($model, 'student_transaction_division_id');
开发者ID:sharmarakesh,项目名称:edusec-college-management-system,代码行数:31,代码来源:_tab1.php

示例6: actionReportSalePerDayPdf

 function actionReportSalePerDayPdf()
 {
     $params = array();
     $result = TempSalePerDay::model()->findAll();
     $date_find = Yii::app()->session['date_find'];
     if (!empty($result)) {
         $branch_id = Yii::app()->session['branch_id'];
         $params['result'] = $result;
         $params['date_find'] = Util::mysqlToThaiDate($date_find);
         $params['sale_condition_cash'] = Yii::app()->session['sale_condition_cash'];
         $params['sale_condition_credit'] = Yii::app()->session['sale_condition_credit'];
         $params['has_bonus_no'] = Yii::app()->session['has_bonus_no'];
         $params['has_bonus_yes'] = Yii::app()->session['has_bonus_yes'];
         $params['n'] = 1;
         $params['branch'] = Branch::model()->findByPk((int) $branch_id);
     }
     $this->render('//Report/ReportSalePerDayPdf', $params);
 }
开发者ID:adsavin,项目名称:air,代码行数:18,代码来源:DialogController.php

示例7: array

if(isset($branch) )
{
	?>
<div class="portlet box yellow" style="width:100%;margin-top:20px;">
    <i class="icon-reorder"></i>
    <div class="portlet-title"><span class="box-title">Batchwise Student History Report</span>
    	<div class="operation">
	 
	  <?php echo CHtml::link('Excel', array('BranchwiseAllStudentsFeesDetailInfoReport','excel'=>'excel','Year[year]'=>$year, 'FeesPaymentTransaction[fees_student_branch_id]'=>$branch), array('class'=>'btnblue'));?>	
	</div>
    </div>
<div class="portlet-body" >
<?php
	$org = Organization::model()->findAll();
	$org_data=$org[0];
        $branch_model=Branch::model()->findByPk($branch);
	$yr=Year::model()->findByPk($year);
?>	
	
	<?php	echo '<table class="report-table" border=2 > ';
	
	echo "<tr align=center> <th  colspan = 60 style=text-align:left;> ".CHtml::image(Yii::app()->controller->createUrl('/site/loadImage', array('id'=>$org_data->organization_id)),'No Image',array('width'=>80,'height'=>55,'style'=>'float:left;margin-left:200px;')) ."
	 <big> <b>".$org_data->organization_name ."</big><br>". $org_data->address_line1." ".$org_data->address_line2."</br>"  . City::model()->findBypk($org_data->city)->city_name.", ".State::model()->findBypk($org_data->state)->state_name.", ".Country::model()->findBypk($org_data->country)->name."." ." </th> <br>	 </tr>";
	echo "<tr><th colspan=60><h3> Batch-".$yr->year." Branch  of ".$branch_model->branch_name."  All Students Fees Collection Report</h3></th> </tr>";
	
	echo "<tr class='table_header'>"; 
	echo "<th > SI<br> No.</th>";
	echo "<th> Enrollement<br> No. </th>";
	echo "<th colspan=2 > Student Full Name</th>";
	
	foreach($startYear as $y)
开发者ID:rinodung,项目名称:EduSec3.0.0,代码行数:31,代码来源:branchwise_allstudents_fees_detail_info_report.php

示例8: array

	<!--Content div-->
	<div class="front_content">
		<div class="contentpic">
			<?php 
        echo CHtml::image(Yii::app()->baseUrl . "/college_data/stud_images/" . $studphoto, "no-images", array("width" => "60px", "height" => "60px"));
        ?>
		</div>
		<div class="contentinfo">
		
		<?php 
        foreach ($selected_list as $key => $value) {
            if ($key == 'quota_name') {
                $field_value = Quota::model()->findByPk($stud['student_transaction_quota_id'])->quota_name;
            } else {
                if ($key == 'branch_name') {
                    $field_value = Branch::model()->findByPk($stud['student_transaction_branch_id'])->branch_name;
                } else {
                    if ($key == 'division_code') {
                        $field_value = Division::model()->findByPk($stud['student_transaction_division_id'])->{$key};
                    } else {
                        if ($key == 'sem') {
                            $field_value = AcademicTerm::model()->findByPk($stud['student_academic_term_name_id'])->academic_term_name;
                        } else {
                            if ($key == 'student_first_name') {
                                $lname = $StudentInfo->student_last_name;
                                $fname = $StudentInfo->student_first_name;
                                $mname = $StudentInfo->student_middle_name;
                                $label = $value;
                                $field_value = $lname . " " . $fname . " " . $mname;
                            } else {
                                $field_value = $stud[$key];
开发者ID:sharmarakesh,项目名称:EduSec2.0.0,代码行数:31,代码来源:print_idcard.php

示例9: date

</tr>	
<tr class="row">
	<td class="col1">ACPC Admission Date </td> 
	<td class="col2"> <?php echo date('d-m-Y',strtotime($stud_trans[0]['student_adm_date'])) ;?></td>
</tr>
<tr class="row">	
	<td class="col1">Enrollment No. </td> 
	<td class="col2"><?php echo $stud_trans[0]['student_enroll_no'];?></td>
</tr>	
<tr class="row">
	<td class="col1">Roll No. </td> 
	<td class="col2"> <?php echo $stud_trans[0]['student_roll_no'];?></td>
</tr>	
<tr class="row">
	<td class="col1">Branch </td> 
	<td class="col2"><?php echo Branch::model()->findByPk($stud_trans[0]['student_transaction_branch_id'])->branch_name;?></td>
</tr>	
<tr class="row">
	<td class="col1">
	<?php 
		$sem = AcademicTerm::model()->findByPk($stud_trans[0]['student_academic_term_name_id'])->academic_term_name;
		$acdm_period = AcademicTermPeriod::model()->findByPk($stud_trans[0]['student_academic_term_period_tran_id'])->academic_term_period;?>
	Current/Last Semester </td> 
	<td class="col2"> <?php echo "Sem-".$sem; ?></td>
</tr>	
<tr class="row">	
	<td class="col1">Current/Passing Academic Year </td> 
	<td class="col2"><?php echo $acdm_period ?></td>
</tr>	
<tr class="row">
	<td class="col1">Quota </td> 
开发者ID:rinodung,项目名称:EduSec3.0.0,代码行数:31,代码来源:student_history_view.php

示例10:

echo $form->textFieldGroup($model, 'patronymic', ['widgetOptions' => ['htmlOptions' => ['class' => 'popover-help', 'data-original-title' => $model->getAttributeLabel('patronymic'), 'data-content' => $model->getAttributeDescription('patronymic')]]]);
?>
        </div>
		<div class="col-sm-3">
            <?php 
echo $form->textFieldGroup($model, 'phone', ['widgetOptions' => ['htmlOptions' => ['class' => 'popover-help', 'data-original-title' => $model->getAttributeLabel('phone'), 'data-content' => $model->getAttributeDescription('phone')]]]);
?>
        </div>
		<div class="col-sm-3">
            <?php 
echo $form->textFieldGroup($model, 'create_date', ['widgetOptions' => ['htmlOptions' => ['class' => 'popover-help', 'data-original-title' => $model->getAttributeLabel('create_date'), 'data-content' => $model->getAttributeDescription('create_date')]]]);
?>
        </div>
		<div class="col-sm-3">
            <?php 
echo $form->dropDownListGroup($model, 'branch_id', ['widgetOptions' => ['data' => CHtml::listData(Branch::model()->findAll(), 'id', 'name')]]);
?>
        </div>
		<div class="col-sm-3">
            <?php 
echo $form->textFieldGroup($model, 'email', ['widgetOptions' => ['htmlOptions' => ['class' => 'popover-help', 'data-original-title' => $model->getAttributeLabel('email'), 'data-content' => $model->getAttributeDescription('email')]]]);
?>
        </div>
        <div class="row">
            <div class="col-sm-3">
                <?php 
echo $form->dropDownListGroup($model, 'status', ['widgetOptions' => ['data' => $model->getStatusList(), 'htmlOptions' => ['empty' => '--Все--']]]);
?>
            </div>
        </div>
		    </div>
开发者ID:shipovalovyuriy,项目名称:spasibeaucoup,代码行数:31,代码来源:_search.php

示例11: foreach

<?php 
        echo "Sem-" . $ac['academic_term_name'];
        ?>
</th>

<?php 
    }
    ?>
</tr>
<?php 
    foreach ($branch as $b) {
        if ($m % 2 == 0) {
            $class = "odd";
        } else {
            $class = "even";
        }
        echo "<tr class=" . $class . ">";
        echo "<td  align=center><b>" . Branch::model()->findByPk($b['branch_id'])->branch_name . "</b></td>";
        foreach ($acdm_name as $ac1) {
            echo "<td  align=center><u>" . CHtml::link('View Chart', array('attendence/DisplayChart', 'sem_id' => $acdm_period, 'sem_name_id' => $ac1['academic_term_id'], 'branch_id' => $b['branch_id']), array('target' => '_blank')) . "</u></td>";
        }
        echo "</tr>";
        $m++;
    }
    echo "</table>";
} else {
    print "<h1 style=\"color:red;text-align:center\">No Record To Display</h1>";
}
?>

开发者ID:sharmarakesh,项目名称:edusec-college-management-system,代码行数:29,代码来源:chart_table.php

示例12: actionBranchDelete

 function actionBranchDelete($id)
 {
     $this->checkLogin();
     Branch::model()->deleteByPk((int) $id);
     $this->redirect(array('BranchIndex'));
 }
开发者ID:adsavin,项目名称:bswshop,代码行数:6,代码来源:ConfigController.php

示例13:

	<td class="col2"><?php 
    echo $div_model->division_code;
    ?>
</td>
</tr>	
<tr class="row">
	<td class="col1">Semester </td> 
	<td class="col2"> <?php 
    echo $acd_model->academic_term_name;
    ?>
</td>
</tr>
	<tr class="row">	
	<td class="col1"> Branch </td> 
	<td class="col2"><?php 
    echo Branch::model()->findByPk($div_model->branch_id)->branch_name;
    ?>
</td>
</tr>
	</table></br>
	


<?php 
    echo '<table class="table_data" >
	<tr class="table_header"><th>SI No.</th><th>Subject Name</th><th>Total</th><th>Present</th><th>Attendance %</th></tr>';
    for ($i = 0; $i < count($subject); $i++) {
        if ($m % 2 == 0) {
            $class = "odd";
        } else {
            $class = "even";
开发者ID:sharmarakesh,项目名称:EduSec2.0.0,代码行数:31,代码来源:attendence_division_report_view.php

示例14:

	'data'=>$model,
	'attributes'=>array(
		//'student_attendence_email_id',
		array(
                'name'=>'employee_first_name',
	        'value'=> EmployeeInfo::model()->findByAttributes(array(
						'employee_info_transaction_id' => $model->student_attendence_email_emp_id))->employee_first_name,
		),
		array(
                'name'=>'employee_last_name',
	        'value'=> EmployeeInfo::model()->findByAttributes(array(
						'employee_info_transaction_id' => $model->student_attendence_email_emp_id))->employee_last_name,
		),
		array(
                'name'=>'branch_name',
	        'value'=> ($model->student_attendence_email_branch_id==0)?"All Branch":Branch::model()->findByPk($model->student_attendence_email_branch_id)->branch_name,
		),

		array(
                'name'=>'employee_transaction_designation_id',
	        'value'=> EmployeeDesignation::model()->findByPk($model->rel_emp_tran->employee_transaction_designation_id)->employee_designation_name,
		),
		'student_attendence_email_minute',
		'student_attendence_email_hour',

		array(
                'name'=>'student_attendence_email_org_id',
		'value'=> Organization::model()->findByPk($model->student_attendence_email_org_id)->organization_name,
		),
		array(
                'name'=>'student_attendence_email_created_by',
开发者ID:rinodung,项目名称:EduSec3.0.0,代码行数:31,代码来源:view.php

示例15:

}

</style>
<?php 
$org_id = Yii::app()->user->getState('org_id');
$fees = FeesPaymentTransaction::model()->findAll('fees_student_id=' . $info_model[0]['student_transaction_id'] . ' and  	fees_payment_transaction_organization_id = ' . $org_id);
if (empty($fees)) {
    echo "<div class=\"block-error\">";
    echo "No fees record available for this student.";
    echo "</div>";
} else {
    $i = 1;
    echo "<h5>Student Roll Number : " . $info_model[0]['student_roll_no'] . "</h5>";
    echo "<h5>Student Enrollment Number : " . $info_model[0]['student_enroll_no'] . "</h5>";
    echo "<h5>Student Name : " . $info_model[0]['student_first_name'] . ' ' . $info_model[0]['student_middle_name'] . ' ' . $info_model[0]['student_last_name'] . "</h5>";
    echo "<h5>Branch: " . Branch::model()->findByPk($info_model[0]['student_transaction_branch_id'])->branch_name . "</h5>";
    echo "<h5>Current Semester: " . AcademicTerm::model()->findByPk($info_model[0]['student_academic_term_name_id'])->academic_term_name . "</h5>";
    ?>

	<table border="1">
		<tr class="table_header">
			<th>
				Sr No.
			</th>
			<th>
				Academic Year
			</th>
			<th>
				Semester
			</th>
			<th>
开发者ID:sharmarakesh,项目名称:edusec-college-management-system,代码行数:31,代码来源:student_fees_report_pdf.php


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