mirror of
https://codeberg.org/artfulrobot/contactcats.git
synced 2025-06-25 19:58:05 +02:00
Add redundant contact_id field for search kit/form builder; add index on category field...
This commit is contained in:
parent
9fee48603b
commit
7b611c343f
7 changed files with 113 additions and 29 deletions
|
@ -13,16 +13,26 @@
|
|||
<required>true</required>
|
||||
<comment>Unique ID, corresponds to contact id</comment>
|
||||
<html>
|
||||
<type>EntityRef</type>
|
||||
<label>Contact</label>
|
||||
<type>Number</type>
|
||||
</html>
|
||||
</field>
|
||||
<primaryKey>
|
||||
<name>id</name>
|
||||
<autoincrement>true</autoincrement>
|
||||
</primaryKey>
|
||||
|
||||
<field>
|
||||
<name>contact_id</name>
|
||||
<type>int unsigned</type>
|
||||
<required>true</required>
|
||||
<comment>Same as id but for FormBuilder</comment>
|
||||
<html>
|
||||
<type>EntityRef</type>
|
||||
<label>Contact</label>
|
||||
</html>
|
||||
</field>
|
||||
<foreignKey>
|
||||
<name>id</name>
|
||||
<name>contact_id</name>
|
||||
<table>civicrm_contact</table>
|
||||
<key>id</key>
|
||||
<onDelete>CASCADE</onDelete>
|
||||
|
@ -30,7 +40,7 @@
|
|||
|
||||
<field>
|
||||
<name>category</name>
|
||||
<type>int unsigned</type>
|
||||
<type>int unsigned</type>
|
||||
<required>true</required>
|
||||
<default>0</default>
|
||||
<pseudoconstant>
|
||||
|
@ -40,10 +50,14 @@
|
|||
<type>Select</type>
|
||||
</html>
|
||||
</field>
|
||||
<index>
|
||||
<name>index_category</name>
|
||||
<fieldName>category</fieldName>
|
||||
</index>
|
||||
|
||||
<field>
|
||||
<name>next_category</name>
|
||||
<type>int unsigned</type>
|
||||
<type>int unsigned</type>
|
||||
<required>true</required>
|
||||
<default>0</default>
|
||||
<pseudoconstant>
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue