當前位置: 首頁>>代碼示例>>PHP>>正文


PHP Sql::addtion方法代碼示例

本文整理匯總了PHP中Sql::addtion方法的典型用法代碼示例。如果您正苦於以下問題:PHP Sql::addtion方法的具體用法?PHP Sql::addtion怎麽用?PHP Sql::addtion使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在Sql的用法示例。


在下文中一共展示了Sql::addtion方法的10個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。

示例1: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $cstFieldValidators = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from cst_field_validator";
     Sql::splice($sql, CstFieldValidatorDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $cstFieldValidator = new CstFieldValidator();
         $cstFieldValidator->setId($row['id']);
         $cstFieldValidator->setFieldId($row['field_id']);
         $cstFieldValidator->setValidatorId($row['validator_id']);
         array_push($cstFieldValidators, $cstFieldValidator);
     }
     $stmt->closeCursor();
     return $cstFieldValidators;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:26,代碼來源:CstFieldValidatorDao.php

示例2: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $cstKlasss = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from cst_klass";
     Sql::splice($sql, CstKlassDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $cstKlass = new CstKlass();
         $cstKlass->setId($row['id']);
         $cstKlass->setTble($row['tble']);
         $cstKlass->setKlass($row['klass']);
         $cstKlass->setLabel($row['label']);
         array_push($cstKlasss, $cstKlass);
     }
     $stmt->closeCursor();
     return $cstKlasss;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:27,代碼來源:CstKlassDao.php

示例3: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $tmpProjects = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from tmp_project";
     Sql::splice($sql, TmpProjectDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $tmpProject = new TmpProject();
         $tmpProject->setId($row['id']);
         $tmpProject->setName($row['name']);
         $tmpProject->setCreateTime($row['create_time']);
         $tmpProject->setUpdateTime($row['update_time']);
         array_push($tmpProjects, $tmpProject);
     }
     $stmt->closeCursor();
     return $tmpProjects;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:27,代碼來源:TmpProjectDao.php

示例4: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $metaTables = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from meta_table";
     Sql::splice($sql, MetaTableDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $metaTable = new MetaTable();
         $metaTable->setId($row['id']);
         $metaTable->setDatabaseId($row['database_id']);
         $metaTable->setDatabaseName($row['database_name']);
         $metaTable->setName($row['name']);
         $metaTable->setKeyId($row['key_id']);
         $metaTable->setKeyName($row['key_name']);
         array_push($metaTables, $metaTable);
     }
     $stmt->closeCursor();
     return $metaTables;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:29,代碼來源:MetaTableDao.php

示例5: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $metaFields = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from meta_field";
     Sql::splice($sql, MetaFieldDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $metaField = new MetaField();
         $metaField->setId($row['id']);
         $metaField->setDatabaseId($row['database_id']);
         $metaField->setDatabaseName($row['database_name']);
         $metaField->setKlassId($row['klass_id']);
         $metaField->setKlassName($row['klass_name']);
         $metaField->setLabel($row['label']);
         $metaField->setName($row['name']);
         $metaField->setType($row['type']);
         $metaField->setShortType($row['short_type']);
         $metaField->setGetter($row['getter']);
         $metaField->setSetter($row['setter']);
         $metaField->setColumnId($row['column_id']);
         $metaField->setColumnName($row['column_name']);
         $metaField->setWidth($row['width']);
         $metaField->setLength($row['length']);
         $metaField->setIsKey($row['is_key']);
         $metaField->setIsCondition($row['is_condition']);
         $metaField->setIsRequired($row['is_required']);
         $metaField->setIsRemote($row['is_remote']);
         $metaField->setValidators($row['validators']);
         $metaField->setInputType($row['input_type']);
         array_push($metaFields, $metaField);
     }
     $stmt->closeCursor();
     return $metaFields;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:44,代碼來源:MetaFieldDao.php

示例6: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $metaColumns = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from meta_column";
     Sql::splice($sql, MetaColumnDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $metaColumn = new MetaColumn();
         $metaColumn->setId($row['id']);
         $metaColumn->setDatabaseId($row['database_id']);
         $metaColumn->setDatabaseName($row['database_name']);
         $metaColumn->setTableId($row['table_id']);
         $metaColumn->setTableName($row['table_name']);
         $metaColumn->setName($row['name']);
         $metaColumn->setType($row['type']);
         $metaColumn->setComment($row['comment']);
         $metaColumn->setIsKey($row['is_key']);
         array_push($metaColumns, $metaColumn);
     }
     $stmt->closeCursor();
     return $metaColumns;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:32,代碼來源:MetaColumnDao.php

示例7: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $tmpDataTemplates = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from tmp_data_template";
     Sql::splice($sql, TmpDataTemplateDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $tmpDataTemplate = new TmpDataTemplate();
         $tmpDataTemplate->setId($row['id']);
         $tmpDataTemplate->setDatabaseId($row['database_id']);
         $tmpDataTemplate->setDatabaseName($row['database_name']);
         $tmpDataTemplate->setTableId($row['table_id']);
         $tmpDataTemplate->setTableName($row['table_name']);
         $tmpDataTemplate->setName($row['name']);
         $tmpDataTemplate->setMode($row['mode']);
         $tmpDataTemplate->setContent($row['content']);
         $tmpDataTemplate->setCreateTime($row['create_time']);
         $tmpDataTemplate->setUpdateTime($row['update_time']);
         array_push($tmpDataTemplates, $tmpDataTemplate);
     }
     $stmt->closeCursor();
     return $tmpDataTemplates;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:33,代碼來源:TmpDataTemplateDao.php

示例8: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $cstFields = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from cst_field";
     Sql::splice($sql, CstFieldDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $cstField = new CstField();
         $cstField->setId($row['id']);
         $cstField->setClmn($row['clmn']);
         $cstField->setField($row['field']);
         $cstField->setLabel($row['label']);
         $cstField->setType($row['type']);
         $cstField->setWidth($row['width']);
         $cstField->setLength($row['length']);
         $cstField->setIsCondition($row['is_condition']);
         $cstField->setIsRequired($row['is_required']);
         $cstField->setIsRemote($row['is_remote']);
         array_push($cstFields, $cstField);
     }
     $stmt->closeCursor();
     return $cstFields;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:33,代碼來源:CstFieldDao.php

示例9: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $metaDatabases = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from meta_database";
     Sql::splice($sql, MetaDatabaseDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $metaDatabase = new MetaDatabase();
         $metaDatabase->setId($row['id']);
         $metaDatabase->setName($row['name']);
         $metaDatabase->setUrl($row['url']);
         $metaDatabase->setUsername($row['username']);
         $metaDatabase->setPassword($row['password']);
         $metaDatabase->setType($row['type']);
         $metaDatabase->setCreater($row['creater']);
         $metaDatabase->setUpdater($row['updater']);
         $metaDatabase->setCreateTime($row['create_time']);
         $metaDatabase->setUpdateTime($row['update_time']);
         array_push($metaDatabases, $metaDatabase);
     }
     $stmt->closeCursor();
     return $metaDatabases;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:33,代碼來源:MetaDatabaseDao.php

示例10: results

 /**
  * 查詢記錄集
  * @return array
  */
 static function results($query = null)
 {
     $pdo = Database::pdo();
     $basAttachments = array();
     $params = $query->getParameters();
     $ops = $query->getOperators();
     $sql = "select * from bas_attachment";
     Sql::splice($sql, BasAttachmentDao::$fields, $params, $ops);
     Sql::addtion($sql, $query);
     $stmt = $pdo->prepare($sql);
     Sql::params($stmt, $params);
     $stmt->execute();
     while ($row = $stmt->fetch(PDO::FETCH_ASSOC)) {
         $basAttachment = new BasAttachment();
         $basAttachment->setId($row['id']);
         $basAttachment->setModule($row['module']);
         $basAttachment->setType($row['type']);
         $basAttachment->setName($row['name']);
         $basAttachment->setMime($row['mime']);
         $basAttachment->setSuffix($row['suffix']);
         $basAttachment->setPath($row['path']);
         $basAttachment->setAbsolutePath($row['absolute_path']);
         $basAttachment->setData($row['data']);
         $basAttachment->setStatus($row['status']);
         $basAttachment->setCreater($row['creater']);
         $basAttachment->setUpdater($row['updater']);
         $basAttachment->setCreateTime($row['create_time']);
         $basAttachment->setUpdateTime($row['update_time']);
         array_push($basAttachments, $basAttachment);
     }
     $stmt->closeCursor();
     return $basAttachments;
 }
開發者ID:xlwmin,項目名稱:confusion,代碼行數:37,代碼來源:BasAttachmentDao.php


注:本文中的Sql::addtion方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。