vtlib 2.0 released!
November 26th, 2008 by Prasad
I’m happy to announce the release of vtlib 2.0. Thanks to community members for trying out earlier versions and sharing the feedback.
This release has the following changes:
1. New APIs have been introduced to:
a) Set rules for Custom Views (Filters)
b) Setup related list between your module and other modules.
c) Configure Popup selection via field for UIType 10.
d) Register Eventing for your modules (feature available only on vtiger CRM 5.1)
2. New modules can now have module level Settings that can be configured through module manager.
3. API was redesigned to make it simpler to use.
Download URL: http://forge.vtiger.com/frs/?group_id=174&release_id=469
Kindly refer to the documentation for more details which captures the API changes details w.r.t vtlib 1.x
About vtlib:
vtlib is a library to ease new module development for vtiger CRM. vtlib includes APIs to create or modify the backend elements for a module. vtlib includes Module Manager which allows new modules to be packaged into zip files that other vtiger CRM installations can easily install and use.
For vtiger 5.0.4, vtlib is available as a download. This package needs to be installed by developers as well as users who intend to install modules developed using vtlib. In version 5.1, vtlib will be integrated into vtiger CRM download.
Try it out today and share your feedback with us.
Regards,
Prasad




Sounds cool. Cannot for 5.1 to be released so that we can give it all a spin.
Hi Prasad,
great!
I’m happy you shared the information regarding vtlib in general with me (us?). Although I would rate myself as a serious vtiger user, I didn’t quite understand what vtlib was about, now I do! Thanks!
Bye,
Tom
Hi Andrew, Tom,
Thank you.
@Tom: Don’t hesitate to backfire questions if you feel our explanation was not clear at first. It will help us document better.
Regards,
Prasad
vtiger Team
Hi
i have try to use vtilb 2.0 but it look to not run properly
Payslip module it is cretaed , but field Link To non run : it not appear during creation a new PaySlip, i t appear (empty) on detail view.
i have try to modify by hand the value of field linkto inside table vtiger_payslip and afetr this i see in detail view the correct contacts name.
but it still not running in edit or create (the label link to not appear)
where i have made a mistake ?
CarloB
Hi CarloB,
‘Link To’ is a popup selection field like ‘Account Name’ in Contacts module.
Can you please clear the smarty compiled files (*.tpl.php) in (Smarty/templates_c) and give another try creating the Payslip record?
Regards,
Prasad
vtiger Team
Hi
i have try and after i delete the smarty compiliated files , field Link to appear both in create and edit view!
But… it non work properly.
i mean : if i made a search , when i select contact name , nothing appear into the field
if i select sometinhg in first popup page , it work
if i select something not in first popup page , it NOT work
if i click on name to order the list in popup page , it NOT work….
Now, where is my mistake ?
Thanks
CarloB
Hi Carlo,
Thank you for reporting the issues. I will have a look at it and fix it in next release.
Regards,
Prasad
vtiger Team
Hi Prasad!
Does it inclded in current svn?
http://trac.vtiger.com/svn/vtiger/vtigercrm/branches/5.1
Or how it is possible to test vtlib 2.0 with vtiger 5.1?
Thanks,
Maxim.
Hi Makos,
Yes, vtiger 5.1 branches on svn is being integrated with development versions of vtlib
Regards,
Prasad
vtiger Team
Update: Re-uploaded vtlib-2.0.zip today by adding function checkFileAccess which was missing!
Regards,
Prasad
vtiger Team
Hi,
Vtlib 2.0 is a real great API and it’s really easier to create a module, though i have a problem.
I want to create a new module with this API, and add this new module to a module not created with the API, ie “notes”.
API Works fine, but when i try to go on “more information”, i have a php error with get_related_list.
I tried to add the get_related_list generic function to the module and some other modifications, but i can’t make it work.
It’s a shame cause existing modules are really exhaustive and i would like to add related lists to my new modules.
Hope u understand me, excuse my english.
Thanks for that great work u do, but i just have this problem.
jd
checkFileAccess is still buggy:
install new vtiger504
create a few contacts or accounts
install vtlib2
go to contacts page:
Sorry! Attempt to access restricted file
before installing vtlib: could be displayed without error
go to function checkFileAccess
comment last line// die(”Sorry! Attempt to access restricted file.”);
everything is displayed again.
I am sure it is not what is supposed to be done, but it works.
vtlib2 downloaded on dec. 1st.
Klaus
Hi Klaus,
Can you do a favor, in the function checkFileAccess please echo the two paths being compared. This will give more details on the issue.
if(stripos($realfilepath, $rootdirpath) !== 0) {echo "RealPath: $realfilepath <br>";
echo "RootPath: $rootdirpath <br>";
die("Sorry! Attempt to access restricted file.");
}
Regards,
Prasad
vtiger Team
checkFileAccess:
this no longer allows to check out of SVN into a new working directory, without changing config.inc.php, e.g. rootpath.
Up to now, that never created a problem, even if the rootpath was wrong.
Klaus
Hi Klaus,
rootpath will be set during vtiger CRM installation. When you check from SVN and install vtiger CRM it should work fine.
Relying on rootpath to determine file access check will help us in check file being accessed is well within the web directory.
Regards,
Prasad
vtiger Team
Hi Prasad,
this is a misunderstanding.
AFTER installation I handle my code changes in MY SVN.
Now, it is no longer possible to check out into another working directory without changing rootpath.
No problem if one knows that it has to be changed.
regards,
Klaus
Hi Prasad.
How can I do an attachment with the vtlib and the UI type 61.
Thanks.
Momo