projects
/
civicrm-core.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
CRM-17663 - Configurable cache time per dashlet & auto-refresh
[civicrm-core.git]
/
CRM
/
Core
/
DAO
/
AddressFormat.php
diff --git
a/CRM/Core/DAO/AddressFormat.php
b/CRM/Core/DAO/AddressFormat.php
index 4da6c20e0aef6998feefca545ecd45dd893e3685..3e31107d9e14eb1b5fa2d318ea5d3a1d0e20c6b5 100644
(file)
--- a/
CRM/Core/DAO/AddressFormat.php
+++ b/
CRM/Core/DAO/AddressFormat.php
@@
-41,18
+41,6
@@
class CRM_Core_DAO_AddressFormat extends CRM_Core_DAO {
* @var string
*/
static $_tableName = 'civicrm_address_format';
* @var string
*/
static $_tableName = 'civicrm_address_format';
- /**
- * static instance to hold the field values
- *
- * @var array
- */
- static $_fields = null;
- /**
- * static instance to hold the FK relationships
- *
- * @var string
- */
- static $_links = null;
/**
* static value to see if we should log any modifications to
* this table in the civicrm_log table
/**
* static value to see if we should log any modifications to
* this table in the civicrm_log table
@@
-87,8
+75,8
@@
class CRM_Core_DAO_AddressFormat extends CRM_Core_DAO {
* @return array
*/
static function &fields() {
* @return array
*/
static function &fields() {
- if (!
(self::$_fields
)) {
-
self::$_fields
= array(
+ if (!
isset(Civi::$statics[__CLASS__]['fields']
)) {
+
Civi::$statics[__CLASS__]['fields']
= array(
'id' => array(
'name' => 'id',
'type' => CRM_Utils_Type::T_INT,
'id' => array(
'name' => 'id',
'type' => CRM_Utils_Type::T_INT,
@@
-103,8
+91,9
@@
class CRM_Core_DAO_AddressFormat extends CRM_Core_DAO {
'description' => 'The format of an address',
) ,
);
'description' => 'The format of an address',
) ,
);
+ CRM_Core_DAO_AllCoreTables::invoke(__CLASS__, 'fields_callback', Civi::$statics[__CLASS__]['fields']);
}
}
- return
self::$_fields
;
+ return
Civi::$statics[__CLASS__]['fields']
;
}
/**
* Return a mapping from field-name to the corresponding key (as used in fields()).
}
/**
* Return a mapping from field-name to the corresponding key (as used in fields()).