Reputation: 213
Is it possible to import .csv fields into custom created modules in SugarCRM?
I have created several custom modules, but I can't find an import button for csv fields.
Thanks!
OK, I've just found a working solution: Link: http://www.sugarcrm.com/forums/f148/how-add-import-option-custom-modules-45612/
Add the below line in modules//.php file.
Code:
var $importable = true;
Create the file menu.ext.php in "custom\modules\\Ext\Menus" with below code.
Code:
<?php
if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point');
if(ACLController::checkAccess('<Module Name>', 'import', true)) $module_menu[]=Array("index.php?module=Import&action=Step1&import_module=<Module Name>&return_module=<Module Name>&return_action=index", "Import","Import", '<Module Name>');
?>
This will add import menu item in the shortcut menu.
Upvotes: 3
Views: 3087
Reputation: 1
thanks for the solution. Only one thing, the rigth route at "Create the file menu.ext.php in "custom\modules\Ext\Menus" with below code" is "custom\Extension\modules\Ext\Menus"
With this, it work fine for me.
Upvotes: 0
Reputation: 13
I know this may be old but you can download a sample when you click import and it will show you how to do this. It will show your custom fields.
Upvotes: 0
Reputation: 213
Another possibility (way easier) is to check the button for "Importing" when building a new custom module via the module builder!
Upvotes: 2