Add controlField metadata for ChainSelect fields
authorColeman Watts <coleman@civicrm.org>
Mon, 30 Dec 2019 20:32:22 +0000 (15:32 -0500)
committerColeman Watts <coleman@civicrm.org>
Mon, 30 Dec 2019 20:32:22 +0000 (15:32 -0500)
CRM/Core/CodeGen/Specification.php
CRM/Core/DAO/Address.php
xml/schema/Core/Address.xml

index 17bfc45a5571a95fd14dacc9e83c4ce0b46bdb22..27468db7685413f38d773eb6e16def074616f758 100644 (file)
@@ -383,6 +383,7 @@ class CRM_Core_CodeGen_Specification {
         'type',
         'formatType',
         'label',
+        'controlField',
         /* Fixme: prior to CRM-13497 these were in a flat structure
         // CRM-13497 moved them to be nested within 'html' but there's no point
         // making that change in the DAOs right now since we are in the process of
index 8afdc271b8ffe8e682e2665e680b9e6ea4fe06a0..7eebf319884c319596c7162152fe4db7947c66b5 100644 (file)
@@ -6,7 +6,7 @@
  *
  * Generated from xml/schema/CRM/Core/Address.xml
  * DO NOT EDIT.  Generated by CRM_Core_CodeGen
- * (GenCodeChecksum:4e3b66ed828527539c525b2ffc71e606)
+ * (GenCodeChecksum:ec9f95b3b9d7cb430a52e5b367d735fc)
  */
 
 /**
@@ -568,6 +568,7 @@ class CRM_Core_DAO_Address extends CRM_Core_DAO {
           'FKClassName' => 'CRM_Core_DAO_County',
           'html' => [
             'type' => 'ChainSelect',
+            'controlField' => 'state_province_id',
           ],
           'pseudoconstant' => [
             'table' => 'civicrm_county',
@@ -589,6 +590,7 @@ class CRM_Core_DAO_Address extends CRM_Core_DAO {
           'FKClassName' => 'CRM_Core_DAO_StateProvince',
           'html' => [
             'type' => 'ChainSelect',
+            'controlField' => 'country_id',
           ],
           'pseudoconstant' => [
             'table' => 'civicrm_state_province',
index 183a1af5b09a671663178f595a2ef75cdf09a27e..97ea97b3753a86cc2817fc27f954977802e8ba3f 100644 (file)
     </pseudoconstant>
     <html>
       <type>ChainSelect</type>
+      <controlField>state_province_id</controlField>
     </html>
     <add>1.1</add>
   </field>
     <localize_context>province</localize_context>
     <html>
       <type>ChainSelect</type>
+      <controlField>country_id</controlField>
     </html>
     <add>1.1</add>
   </field>