Hi
I have a custom module created with the "Module Builder" related to "Accounts" and I want to select that relationship in the Edit view. In vardefs:
MyModule_sugar.php:Code:'account_name' => array ( 'name' => 'account_name', 'rname' => 'name', 'id_name' => 'account_id', 'vname' => 'LBL_ACCOUNT_NAME', 'join_name' => 'accounts', 'type' => 'relate', 'link' => 'accounts', 'table' => 'accounts', 'isnull' => 'true', 'module' => 'Accounts', 'dbType' => 'varchar', 'len' => '255', 'source' => 'non-db', 'unified_search' => true, ), 'account_id' => array ( 'name' => 'account_id', 'rname' => 'id', 'id_name' => 'account_id', 'vname' => 'LBL_ACCOUNT_ID', 'type' => 'relate', 'table' => 'accounts', 'isnull' => 'true', 'module' => 'Accounts', 'dbType' => 'id', 'reportable' => false, 'source' => 'non-db', 'massupdate' => false, 'duplicate_merge' => 'disabled', 'hideacl' => true, ),
language/en_us.lang:Code:var $account_name; var $account_id; var $relationship_fields = Array('account_id'=> 'accounts');
When creating a new entry in my custom module "Account Name" is there and when save it the relationship is correct. But in Detail view "Account Name" is empty. When editing this entry it is also blank and when select some other account it creates the new relationship. How to view/fetch that relationship in detail view and edit view?Code:'LBL_ACCOUNT_NAME' => 'Account Name:', 'LBL_ACCOUNT_ID' => 'Account ID:',
SugarCRM Version 5.0.0g (Build 3391)


LinkBack URL
About LinkBacks



Reply With Quote

Bookmarks