Hi all,
I have a big problem because i lost 1 week. My problem is that I want to show my custom module in Case module with a subpanel. But I can't.
This is my [u]sugarlog.txt[/u]:
- [b]Tue Oct 22 09:35:39 2013 [3048][1][FATAL] Bad subpanel definition, it has incorrect value for get_subpanel_data property act_products_sub_cases.[/b]
I read this post but this not is my problem. http://forums.sugarcrm.com/f3/issue-s...
I show you my code:
[u]Varderfs:[/u]
[CODE]
'act_products_sub_cases',
'type' => 'link',
'relationship' => 'cases_act_products',
'source' => 'non-db',
'vname' => 'LBL_PRODUCTS_PANEL',
);
?>
[/CODE]
[u]Layoutdefs:[/u]
[CODE]
100,
'module' => 'act_Products',
'subpanel_name' => 'default',
'sort_order' => 'asc',
'sort_by' => 'id',
'title_key' => 'LBL_PRODUCTS_PANEL',
'get_subpanel_data' => 'act_products_sub_cases',
'top_buttons' =>
array (
0 =>
array (
'widget_class' => 'SubPanelTopButtonQuickCreate',
),
),
);
?>
[/CODE]
[u]Relationship:[/u]
[CODE]
'one-to-many',
'relationships' =>
array (
'cases_act_products' =>
array (
'lhs_module' => 'Cases',
'lhs_table' => 'cases',
'lhs_key' => 'id',
'rhs_module' => 'act_Products',
'rhs_table' => 'act_products',
'rhs_key' => 'id',
'relationship_type' => 'many-to-many',
'join_table' => 'cases_act_products_c',
'join_key_lhs' => 'cases_act_setcases_prod', // cases act_setcases_prod
'join_key_rhs' => 'cases_act_setprod_cases', // prod act_setprod_cases
),
),
'table' => 'cases_act_products_c',
'fields' =>
array (
0 =>
array (
'name' => 'id',
'type' => 'varchar',
'len' => 36,
),
1 =>
array (
'name' => 'date_modified',
'type' => 'datetime',
),
2 =>
array (
'name' => 'deleted',
'type' => 'bool',
'len' => '1',
'default' => '0',
'required' => true,
),
3 =>
array (
'name' => 'cases_act_setcases_prod',
'type' => 'varchar',
'len' => 36,
),
4 =>
array (
'name' => 'cases_act_setprod_cases',
'type' => 'varchar',
'len' => 36,
),
),
'indices' =>
array (
0 =>
array (
'name' => 'cases_act_setcases_prodpk',
'type' => 'primary',
'fields' =>
array (
0 => 'id',
),
),
1 =>
array (
'name' => 'cases_act_setcases_prod_a',
'type' => 'index',
'fields' =>
array (
0 => 'cases_act_setcases_prod',
),
),
2 =>
array (
'name' => 'cases_act_setcases_prod_b',
'type' => 'alternate_key',
'fields' =>
array (
0 => 'cases_act_setprod_cases',
),
),
),
);
?>
[/CODE]
A lot of thanks.
(from jordizsp)
I have a big problem because i lost 1 week. My problem is that I want to show my custom module in Case module with a subpanel. But I can't.
This is my [u]sugarlog.txt[/u]:
- [b]Tue Oct 22 09:35:39 2013 [3048][1][FATAL] Bad subpanel definition, it has incorrect value for get_subpanel_data property act_products_sub_cases.[/b]
I read this post but this not is my problem. http://forums.sugarcrm.com/f3/issue-s...
I show you my code:
[u]Varderfs:[/u]
[CODE]
'act_products_sub_cases',
'type' => 'link',
'relationship' => 'cases_act_products',
'source' => 'non-db',
'vname' => 'LBL_PRODUCTS_PANEL',
);
?>
[/CODE]
[u]Layoutdefs:[/u]
[CODE]
100,
'module' => 'act_Products',
'subpanel_name' => 'default',
'sort_order' => 'asc',
'sort_by' => 'id',
'title_key' => 'LBL_PRODUCTS_PANEL',
'get_subpanel_data' => 'act_products_sub_cases',
'top_buttons' =>
array (
0 =>
array (
'widget_class' => 'SubPanelTopButtonQuickCreate',
),
),
);
?>
[/CODE]
[u]Relationship:[/u]
[CODE]
'one-to-many',
'relationships' =>
array (
'cases_act_products' =>
array (
'lhs_module' => 'Cases',
'lhs_table' => 'cases',
'lhs_key' => 'id',
'rhs_module' => 'act_Products',
'rhs_table' => 'act_products',
'rhs_key' => 'id',
'relationship_type' => 'many-to-many',
'join_table' => 'cases_act_products_c',
'join_key_lhs' => 'cases_act_setcases_prod', // cases act_setcases_prod
'join_key_rhs' => 'cases_act_setprod_cases', // prod act_setprod_cases
),
),
'table' => 'cases_act_products_c',
'fields' =>
array (
0 =>
array (
'name' => 'id',
'type' => 'varchar',
'len' => 36,
),
1 =>
array (
'name' => 'date_modified',
'type' => 'datetime',
),
2 =>
array (
'name' => 'deleted',
'type' => 'bool',
'len' => '1',
'default' => '0',
'required' => true,
),
3 =>
array (
'name' => 'cases_act_setcases_prod',
'type' => 'varchar',
'len' => 36,
),
4 =>
array (
'name' => 'cases_act_setprod_cases',
'type' => 'varchar',
'len' => 36,
),
),
'indices' =>
array (
0 =>
array (
'name' => 'cases_act_setcases_prodpk',
'type' => 'primary',
'fields' =>
array (
0 => 'id',
),
),
1 =>
array (
'name' => 'cases_act_setcases_prod_a',
'type' => 'index',
'fields' =>
array (
0 => 'cases_act_setcases_prod',
),
),
2 =>
array (
'name' => 'cases_act_setcases_prod_b',
'type' => 'alternate_key',
'fields' =>
array (
0 => 'cases_act_setprod_cases',
),
),
),
);
?>
[/CODE]
A lot of thanks.
(from jordizsp)
