コード例 #1
0
 /**
  * Returns all the column names of this table
  *
  * @return array
  */
 static function &fields()
 {
     if (!self::$_fields) {
         self::$_fields = array('id' => array('name' => 'id', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Entity Financial Transaction ID'), 'description' => 'ID', 'required' => true), 'entity_table' => array('name' => 'entity_table', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Entity Table'), 'description' => 'May contain civicrm_financial_item, civicrm_contribution, civicrm_financial_trxn, civicrm_grant, etc', 'required' => true, 'maxlength' => 64, 'size' => CRM_Utils_Type::BIG, 'import' => true, 'where' => 'civicrm_entity_financial_trxn.entity_table', 'headerPattern' => '', 'dataPattern' => '', 'export' => true), 'entity_id' => array('name' => 'entity_id', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Entity ID'), 'required' => true), 'financial_trxn_id' => array('name' => 'financial_trxn_id', 'type' => CRM_Utils_Type::T_INT, 'title' => ts('Financial Transaction Id'), 'FKClassName' => 'CRM_Financial_DAO_FinancialTrxn'), 'amount' => array('name' => 'amount', 'type' => CRM_Utils_Type::T_MONEY, 'title' => ts('Amount'), 'description' => 'allocated amount of transaction to this entity', 'required' => true, 'precision' => array(20, 2), 'import' => true, 'where' => 'civicrm_entity_financial_trxn.amount', 'headerPattern' => '/amount/i', 'dataPattern' => '/^\\d+(\\.\\d{2})?$/', 'export' => true));
     }
     return self::$_fields;
 }
コード例 #2
0
ファイル: EntityFinancialTrxn.php プロジェクト: hguru/224Civi
 /**
  * returns all the column names of this table
  *
  * @access public
  * @return array
  */
 static function &fields()
 {
     if (!self::$_fields) {
         self::$_fields = array('id' => array('name' => 'id', 'type' => CRM_Utils_Type::T_INT, 'required' => true), 'entity_table' => array('name' => 'entity_table', 'type' => CRM_Utils_Type::T_STRING, 'title' => ts('Entity Table'), 'required' => true, 'maxlength' => 64, 'size' => CRM_Utils_Type::BIG, 'import' => true, 'where' => 'civicrm_entity_financial_trxn.entity_table', 'headerPattern' => '', 'dataPattern' => '', 'export' => true), 'entity_id' => array('name' => 'entity_id', 'type' => CRM_Utils_Type::T_INT, 'required' => true), 'financial_trxn_id' => array('name' => 'financial_trxn_id', 'type' => CRM_Utils_Type::T_INT, 'FKClassName' => 'CRM_Financial_DAO_FinancialTrxn'), 'amount' => array('name' => 'amount', 'type' => CRM_Utils_Type::T_MONEY, 'title' => ts('Amount'), 'required' => true, 'import' => true, 'where' => 'civicrm_entity_financial_trxn.amount', 'headerPattern' => '/amount/i', 'dataPattern' => '/^\\d+(\\.\\d{2})?$/', 'export' => true));
     }
     return self::$_fields;
 }