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


PHP Country::unsetAttributes方法代码示例

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


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

示例1: actionAdmin

 public function actionAdmin()
 {
     $model = new Country('search');
     $model->unsetAttributes();
     if (isset($_GET['Country'])) {
         $model->setAttributes($_GET['Country']);
     }
     $this->render('admin', array('model' => $model));
 }
开发者ID:schmunk42,项目名称:yii-sakila-crud,代码行数:9,代码来源:CountryController.php

示例2: actionAdmin

 /**
  * Manages all models.
  */
 public function actionAdmin()
 {
     $model = new Country('search');
     $model->unsetAttributes();
     // clear any default values
     if (isset($_GET['Country'])) {
         $model->attributes = $_GET['Country'];
     }
     $this->render('admin', array('model' => $model));
 }
开发者ID:rinodung,项目名称:EduSec3.0.0,代码行数:13,代码来源:CountryController.php

示例3: actionView

 /**
  * Displays a particular model.
  * @param integer $id the ID of the model to be displayed
  */
 public function actionView($id)
 {
     //Countries with given Time Zone
     $country = new Country('search');
     $country->unsetAttributes();
     // clear any default values
     $country->timeZoneID = $id;
     if (isset($_GET['Country'])) {
         $country->attributes = $_GET['Country'];
     }
     //Users with given Time Zone
     $profile = new Profile('search');
     $profile->unsetAttributes();
     $profile->timeZoneID = $id;
     if (isset($_GET['Profile'])) {
         $profile->attributes = $_GET['Profile'];
     }
     $this->render('view', array('model' => $this->loadModel($id), 'country' => $country, 'profile' => $profile));
 }
开发者ID:hattd52,项目名称:GCMails,代码行数:23,代码来源:TimeZoneController.php

示例4: actionIndex

 /**
  * Lists all models.
  */
 public function actionIndex()
 {
     parent::actionIndex();
     $model = new Country('search');
     $model->unsetAttributes();
     // clear any default values
     if (isset($_GET['Country'])) {
         $model->attributes = $_GET['Country'];
     }
     if (isset($_GET['pageSize'])) {
         Yii::app()->user->setState('pageSize', (int) $_GET['pageSize']);
         unset($_GET['pageSize']);
         // would interfere with pager and repetitive page size change
     }
     $this->render('index', array('model' => $model));
 }
开发者ID:bylinggha,项目名称:Capella-ERP-Indonesia,代码行数:19,代码来源:CountryController.php

示例5: array

<?php 
$form = $this->beginWidget('CActiveForm', array('id' => 'province-form', 'enableAjaxValidation' => false));
$this->widget('ToolbarButton', array('isSave' => true, 'UrlSave' => 'province/write', 'isCancel' => true, 'UrlCancel' => 'province/cancelwrite'));
echo $form->hiddenField($model, 'provinceid');
?>

	<div class="row">
		<?php 
echo $form->labelEx($model, 'countryid');
echo $form->hiddenField($model, 'countryid');
?>
	  <input type="text" name="countryname" id="countryname" readonly >
    <?php 
$this->beginWidget('zii.widgets.jui.CJuiDialog', array('id' => 'country_dialog', 'options' => array('title' => Yii::t('app', 'Country'), 'width' => 'auto', 'autoOpen' => false, 'modal' => true)));
$country = new Country('searchwstatus');
$country->unsetAttributes();
// clear any default values
if (isset($_GET['Country'])) {
    $country->attributes = $_GET['Country'];
}
$this->widget('zii.widgets.grid.CGridView', array('id' => 'product-grid', 'dataProvider' => $country->Searchwstatus(), 'filter' => $country, 'template' => '{summary}{pager}<br>{items}{pager}{summary}', 'columns' => array(array('header' => '', 'type' => 'raw', 'value' => 'CHtml::Button("+",
          array("name" => "send_product",
          "id" => "send_product",
          "onClick" => "$(\\"#country_dialog\\").dialog(\\"close\\"); $(\\"#countryname\\").val(\\"$data->countryname\\"); $(\\"#Province_countryid\\").val(\\"$data->countryid\\");
		  "))'), array('name' => 'countryid', 'visible' => false, 'value' => '$data->countryid', 'htmlOptions' => array('width' => '1%')), 'countryname')));
$this->endWidget('zii.widgets.jui.CJuiDialog');
echo CHtml::Button('...', array('onclick' => '$("#country_dialog").dialog("open"); return false;'));
?>
		<?php 
echo $form->error($model, 'countryid');
?>
开发者ID:bylinggha,项目名称:Capella-ERP-Indonesia,代码行数:31,代码来源:_form.php

示例6: actionAdmin

 /**
  * Manages all models.
  */
 public function actionAdmin()
 {
     if ($this->CanAccess("admin")) {
         $model = new Country('search');
         $model->unsetAttributes();
         // clear any default values
         if (isset($_GET['Country'])) {
             $model->attributes = $_GET['Country'];
         }
         $this->render('admin', array('model' => $model));
     } else {
         throw new CHttpException(405, Yii::t('app', 'You do not have permissions to access this page.'));
     }
 }
开发者ID:lidijakralj,项目名称:bober,代码行数:17,代码来源:CountryController.php


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