[Vtigercrm-developers] getDefaultUrl in Vtiger_Module_Model (Vtiger 6.0)
Uma S
uma.s at vtiger.com
Wed Feb 26 10:19:34 GMT 2014
Hi,
Yes, On creating module model using getCleanInstance api module Name is
getting empty. Because the module model is not initialized. We need to
initialize module model name to module Name that is passed.
I have raised a ticket in trac (
http://trac.vtiger.com/cgi-bin/trac.cgi/ticket/7963). Please update if any
observation is missed. We will update fix soon.
On Wed, Feb 26, 2014 at 12:56 PM, Stencel, Maciej <m.stencel at opensaas.pl>wrote:
> Hi,
>
> If You say so it must be truth, but when i insert this code into vtigers
> main index file (for example purposes only). I get two diffrent default
> urls, one ok the other one incorrect:
>
> $model = Vtiger_Module_Model::getCleanInstance('RecycleBin');
> echo $model->getDefaultUrl().'<br>'; // index.php?*module*
> =&view=List&sourceModule=Accounts
>
> $model = Vtiger_Module_Model::getInstance('RecycleBin');
> echo $model->getDefaultUrl().'<br>'; // index.php?*module*=*RecycleBin*
> &view=List&sourceModule=Accounts
> exit;
>
> I have checked it again in the newest vt ver 14032. In attachment is
> index.php that i used for testing it, just switch them for moment.
>
> *Z poważaniem / Best regards*
>
> *Maciej Stencel*
> *Tel: +48 884-997-123*
>
> *m.stencel at opensaas.pl <m.stencel at opensaas.pl>www.OpenSaaS.pl
> <http://www.opensaas.pl/>*
>
>
> 2014-02-25 12:14 GMT+01:00 Uma S <uma.s at vtiger.com>:
>
>> Hi,
>>
>> Name paramater cant be empty, Because getComponentClassName api wich
>> generates module class name, Based on ModuleName passed as default value
>> for module as Vtiger.
>>
>>
>> On Mon, Feb 24, 2014 at 9:36 PM, Stencel, Maciej <m.stencel at opensaas.pl>wrote:
>>
>>> Hi VT team!
>>>
>>> I have a question why when I create Vtiger_Module_Model object using
>>> ::getCleanInstance('modulename');
>>>
>>> getDefaultUrl() will return corrupted default url link. Name parameter
>>> is always empty and hence module parameter in url is empty too, making the
>>> url corrupted.
>>>
>>> If I create the object using getInstance('modulename') everything works
>>> as should.
>>>
>>> I think there is a bug in earlier function, or is there some kind of
>>> wicked philosophy why name parameter there is always empty? ;)
>>>
>>> *Z poważaniem / Best regards*
>>>
>>> *Maciej Stencel*
>>> *Tel: +48 884-997-123*
>>>
>>> *m.stencel at opensaas.pl <m.stencel at opensaas.pl>www.OpenSaaS.pl
>>> <http://www.opensaas.pl/>*
>>>
>>> _______________________________________________
>>> http://www.vtiger.com/
>>>
>>
>>
>>
>> --
>> With
>> Best Regards
>> Uma.S
>> Vtiger Team
>>
>> _______________________________________________
>> http://www.vtiger.com/
>>
>
>
> _______________________________________________
> http://www.vtiger.com/
>
--
With
Best Regards
Uma.S
Vtiger Team
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.vtigercrm.com/pipermail/vtigercrm-developers/attachments/20140226/b6d46ba3/attachment.html>
More information about the vtigercrm-developers
mailing list