[ Index ] |
PHP Cross Reference of vtigercrm-6.1.0 |
[Summary view] [Print] [Text view]
1 <?php 2 /*+******************************************************************************* 3 * The contents of this file are subject to the vtiger CRM Public License Version 1.0 4 * ("License"); You may not use this file except in compliance with the License 5 * The Original Code is: vtiger CRM Open Source 6 * The Initial Developer of the Original Code is vtiger. 7 * Portions created by vtiger are Copyright (C) vtiger. 8 * All Rights Reserved. 9 * 10 *********************************************************************************/ 11 12 /** 13 * Description of VtigerTaxMeta 14 */ 15 class VtigerTaxMeta extends VtigerCRMActorMeta { 16 protected function getTableFieldList($tableName) { 17 $tableFieldList = array(); 18 19 $factory = WebserviceField::fromArray($this->pearDB,array('tablename'=>$tableName)); 20 $dbTableFields = $factory->getTableFields(); 21 foreach ($dbTableFields as $dbField) { 22 if($dbField->primary_key){ 23 if($this->idColumn === null){ 24 $this->idColumn = $dbField->name; 25 }else{ 26 throw new WebServiceException(WebServiceErrorCode::$UNKOWNENTITY, 27 "Entity table with multi column primary key is not supported"); 28 } 29 } 30 $field = $this->getFieldArrayFromDBField($dbField,$tableName); 31 if(strcasecmp('taxname',$dbField->name) === 0 || strcasecmp('deleted',$dbField->name)) { 32 $field['displaytype'] = 2; 33 } 34 $webserviceField = WebserviceField::fromArray($this->pearDB,$field); 35 $fieldDataType = $this->getFieldType($dbField,$tableName); 36 if($fieldDataType === null){ 37 $fieldDataType = $this->getFieldDataTypeFromDBType($dbField->type); 38 } 39 $webserviceField->setFieldDataType($fieldDataType); 40 if(strcasecmp($fieldDataType,'reference') === 0){ 41 $webserviceField->setReferenceList($this->getReferenceList($dbField)); 42 } 43 array_push($tableFieldList,$webserviceField); 44 } 45 return $tableFieldList; 46 } 47 48 public function getEntityDeletedQuery() { 49 return 'vtiger_inventorytaxinfo.deleted=0'; 50 } 51 52 } 53 ?>
title
Description
Body
title
Description
Body
title
Description
Body
title
Body
Generated: Fri Nov 28 20:08:37 2014 | Cross-referenced by PHPXref 0.7.1 |