I have some custom vtlib created modules which have a UI10 reference field linking them to the Quotes module.
In version 6, if I go to the related list for one of my modules in a Quote record and click the "Add MyModule" button, the UI10 field in the target module is populated with the crmid of this Quote.
With the exact same code, in the vt7 dev version, this does not happen. The target UI10 field remains empty.
Edited
Designs
Child items
0
Show closed items
No child items are currently assigned. Use child items to break down this issue into smaller parts.
Linked items
0
Link issues together to show that they're related.
Learn more.
When clicking the Add Module field it opens into the Quick Create view of the target module. Typing a few characters into the reference field always returns "No results found". The query in the debug log is correct and it should work, yet the result in Firebug from the ajax search is always empty:
{"success":true,"result":[]}
If I go to the Full Form however, typing the same characters into the reference field returns the correct module record.
Still happening with the most recent pull request for the version 7 code. Perhaps this snippet of debug log might be helpful. I am looking at a related list of a vtlib module (called LSLocations) from an Organisation record. I click on the Add LSLocation button and the QuickView Create popup appears but the Organisation field is empty. if I click to go through to the full form this is the same. The field is still not populated.
Thu Jan 19 13:05:55 2017,992 [9176] DEBUG VT - Prepared sql query being executed : SELECT sourcefield,targetfield,sourcevalue,targetvalues,criteria FROM vtiger_picklist_dependency WHERE tabid=?Thu Jan 19 13:05:55 2017,992 [9176] DEBUG VT - Prepared sql query parameters : [50]Thu Jan 19 13:05:55 2017,992 [9176] DEBUG VT - Prepared sql query being executed : SELECT * FROM vtiger_blocks WHERE tabid=? ORDER BY sequenceThu Jan 19 13:05:55 2017,992 [9176] DEBUG VT - Prepared sql query parameters : [50]Thu Jan 19 13:05:55 2017,994 [9176] DEBUG VT - Prepared sql query being executed : select type from vtiger_ws_referencetype where fieldtypeid=?Thu Jan 19 13:05:55 2017,994 [9176] DEBUG VT - Prepared sql query parameters : [] **<<< Note this is empty!!!**Thu Jan 19 13:05:55 2017,994 [9176] DEBUG VT - Prepared sql query being executed : SELECT fieldname, tablename, entityidfield FROM vtiger_entityname WHERE tabid = ?Thu Jan 19 13:05:55 2017,994 [9176] DEBUG VT - Prepared sql query parameters : [50]Thu Jan 19 13:05:55 2017,995 [9176] DEBUG VT - Prepared sql query being executed : SELECT modulename,tablename,entityidfield,fieldname FROM vtiger_entitynameThu Jan 19 13:05:55 2017,997 [9176] DEBUG VT - Prepared sql query being executed : SELECT * FROM vtiger_tab WHERE presence IN (?,?)Thu Jan 19 13:05:55 2017,997 [9176] DEBUG VT - Prepared sql query parameters : [0,2]Thu Jan 19 13:05:56 2017,000 [9176] DEBUG VT - Prepared sql query being executed : SELECT fieldname,modulename,tablename,entityidfield,entityidcolumn from vtiger_entitynameThu Jan 19 13:05:56 2017,003 [9176] DEBUG VT - Prepared sql query being executed : SELECT fieldname,modulename,tablename,entityidfield,entityidcolumn from vtiger_entitynameThu Jan 19 13:05:56 2017,010 [9176] DEBUG VT - Prepared sql query being executed : select type from vtiger_ws_referencetype where fieldtypeid=?Thu Jan 19 13:05:56 2017,010 [9176] DEBUG VT - Prepared sql query parameters : [14]Thu Jan 19 13:05:56 2017,011 [9176] DEBUG VT - Prepared sql query being executed : select type from vtiger_ws_referencetype where fieldtypeid=?Thu Jan 19 13:05:56 2017,011 [9176] DEBUG VT - Prepared sql query parameters : [5]
As mentioned before, if I use the exact same vtlib scripts to create my modules and relationships in vtiger 6.5 it all works as expected.
The vtiger_relatedlists table has changed considerably between version 6 & 7. There are several new columns, one of which specifies a fieldid for the UIType 10 type fields (1:N). using the setRelatedList() vtlib API this column, and others, are not populated but left as NULL.