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


PHP QQN::Peopledetails方法代码示例

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


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

示例1: getGoogleContacts

 protected function getGoogleContacts()
 {
     $objContacts = new GetContacts();
     $arrContacts = $objContacts->GetGContacts($this->txtUser, $this->txtPassword);
     $contactCount = sizeof($arrContacts);
     foreach ($arrContacts as $person) {
         $count = Peopledetails::QueryCount(QQ::Equal(QQN::Peopledetails()->Email, $person['contactMail']));
         if ($count != 0) {
             $objPerson = Peopledetails::QuerySingle(QQ::Equal(QQN::Peopledetails()->Email, $person['contactMail']));
         } else {
             $objPerson = new Peopledetails();
         }
         $objPerson->FullName = $person['contactName'];
         $objPerson->Phone = $person['contactPhone'];
         $objPerson->Address = $person['contactAddr'];
         $objPerson->Email = $person['contactMail'];
         $objPerson->Save();
     }
     QApplication::DisplayAlert('Successfully imported ' . $contactCount . 'contacts from Google Contacts');
 }
开发者ID:sarapsg,项目名称:prayuj,代码行数:20,代码来源:ImportContacts.php

示例2: MetaDataBinder

 public function MetaDataBinder()
 {
     $condition = QQ::Equal(QQN::Peopledetails()->Owner, $_SESSION['User']);
     // Remember!  We need to first set the TotalItemCount, which will affect the calcuation of LimitClause below
     if ($this->Paginator) {
         $this->TotalItemCount = Peopledetails::QueryCount($condition);
     }
     // Setup the $objClauses Array
     $objClauses = array();
     // If a column is selected to be sorted, and if that column has a OrderByClause set on it, then let's add
     // the OrderByClause to the $objClauses array
     if ($objClause = $this->OrderByClause) {
         array_push($objClauses, $objClause);
     }
     // Add the LimitClause information, as well
     if ($objClause = $this->LimitClause) {
         array_push($objClauses, $objClause);
     }
     // Set the DataSource to be a Query result from Peopledetails, given the clauses above
     //$condition = QQ::Equal(QQN::Peopledetails()->Owner,$_SESSION['User']);
     $this->DataSource = Peopledetails::QueryArray($condition, $objClauses);
     //$this->DataSource = Peopledetails::LoadAll($objClauses);
 }
开发者ID:sarapsg,项目名称:prayuj,代码行数:23,代码来源:PeopledetailsDataGrid.class.php

示例3: LendBasket

 protected function LendBasket()
 {
     foreach ($this->objBasket->GetBasket() as $item) {
         $objItem = Myassets::QuerySingle(QQ::Equal(QQN::Myassets()->Id, $item->Id));
         $objPerson = Peopledetails::QuerySingle(QQ::Equal(QQN::Peopledetails()->Id, $this->strBorrower));
         $objShareDetails = new Sharedetails();
         $objShareDetails->Asin = $objItem->Asin;
         $objShareDetails->Email = $objPerson->Email;
         /*Logic to get the return date*/
         $today = new QDateTime(QDateTime::Now);
         $daySpan = new QDateTimeSpan();
         $daySpan->AddDays(30);
         $returnDate = $today->Add($daySpan);
         $objShareDetails->TakenDate = QDateTime::Now(false);
         $objShareDetails->ReturnDate = $returnDate;
         $objShareDetails->Title = $objItem->Title;
         $objShareDetails->FullName = $objPerson->FullName;
         $objShareDetails->Save();
     }
 }
开发者ID:sarapsg,项目名称:prayuj,代码行数:20,代码来源:ShareAssets.php

示例4: LoadById

 /**
  * Load a single Peopledetails object,
  * by Id Index(es)
  * @param integer $intId
  * @return Peopledetails
  */
 public static function LoadById($intId)
 {
     return Peopledetails::QuerySingle(QQ::Equal(QQN::Peopledetails()->Id, $intId));
 }
开发者ID:sarapsg,项目名称:prayuj,代码行数:10,代码来源:PeopledetailsGen.class.php

示例5: GetContacts

 public static function GetContacts($strKeyword = null)
 {
     if (!is_null($strKeyword)) {
         $condition = QQ::AndCondition(QQ::OrCondition(QQ::Like(QQN::Peopledetails()->FullName, '%' . $strKeyword . '%'), QQ::Like(QQN::Peopledetails()->Email, '%' . $strKeyword . '%'), QQ::Like(QQN::Peopledetails()->Address, '%' . $strKeyword . '%'), QQ::Like(QQN::Peopledetails()->Phone, '%' . $strKeyword . '%')), QQ::Equal(QQN::Peopledetails()->Owner, $_SESSION['User']));
         $objPeopleArray = Peopledetails::QueryArray($condition);
         return $objPeopleArray;
     } else {
         $condition = QQ::Equal(QQN::Peopledetails()->Owner, $_SESSION['User']);
         $objPeopleArray = Peopledetails::QueryArray($condition);
         return $objPeopleArray;
     }
 }
开发者ID:sarapsg,项目名称:prayuj,代码行数:12,代码来源:peopledetails_list.php

示例6: ResolveContentItem

 /**
  * Used internally by the Meta-based Add Column tools.
  *
  * Given a QQNode or a Text String, this will return a Peopledetails-based QQNode.
  * It will also verify that it is a proper Peopledetails-based QQNode, and will throw an exception otherwise.
  *
  * @param mixed $mixContent
  * @return QQNode
  */
 protected function ResolveContentItem($mixContent)
 {
     if ($mixContent instanceof QQNode) {
         if (!$mixContent->_ParentNode) {
             throw new QCallerException('Content QQNode cannot be a Top Level Node');
         }
         if ($mixContent->_RootTableName == 'peopledetails') {
             if ($mixContent instanceof QQReverseReferenceNode && !$mixContent->_PropertyName) {
                 throw new QCallerException('Content QQNode cannot go through any "To Many" association nodes.');
             }
             $objCurrentNode = $mixContent;
             while ($objCurrentNode = $objCurrentNode->_ParentNode) {
                 if (!$objCurrentNode instanceof QQNode) {
                     throw new QCallerException('Content QQNode cannot go through any "To Many" association nodes.');
                 }
                 if ($objCurrentNode instanceof QQReverseReferenceNode && !$objCurrentNode->_PropertyName) {
                     throw new QCallerException('Content QQNode cannot go through any "To Many" association nodes.');
                 }
             }
             return $mixContent;
         } else {
             throw new QCallerException('Content QQNode has a root table of "' . $mixContent->_RootTableName . '". Must be a root of "peopledetails".');
         }
     } else {
         if (is_string($mixContent)) {
             switch ($mixContent) {
                 case 'Id':
                     return QQN::Peopledetails()->Id;
                 case 'FullName':
                     return QQN::Peopledetails()->FullName;
                 case 'Address':
                     return QQN::Peopledetails()->Address;
                 case 'Phone':
                     return QQN::Peopledetails()->Phone;
                 case 'Email':
                     return QQN::Peopledetails()->Email;
                 case 'Owner':
                     return QQN::Peopledetails()->Owner;
                 default:
                     throw new QCallerException('Simple Property not found in PeopledetailsDataGrid content: ' . $mixContent);
             }
         } else {
             if ($mixContent instanceof QQAssociationNode) {
                 throw new QCallerException('Content QQNode cannot go through any "To Many" association nodes.');
             } else {
                 throw new QCallerException('Invalid Content type');
             }
         }
     }
 }
开发者ID:sarapsg,项目名称:prayuj,代码行数:59,代码来源:PeopledetailsDataGridGen.class.php


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