2009年3月12日星期四

Re: [fw-mvc] Zend_Dojo_Form_Element_FilteringSelect won't work in 1.7.6

-- Sudheer Satyanarayana <sudheer.s@binaryvibes.co.in> wrote
(on Friday, 06 March 2009, 04:01 PM +0530):
> As soon as I upgraded to 1.7.6, the
> Zend_Dojo_Form_Element_FilteringSelect elements stopped working. The
> widget is appearing on the page. But the data store is not attached to
> the widget. Thus, the data is empty on the field.
>
> Did someone else encounter the same issue?

There's an issue in the tracker about this, and it has a proposed patch;
I'll try and get to it today so that it releases with 1.7.7 on Monday.


> Here's my code:
> Bootstrap:
> Zend_Dojo::enableView($view);
> $view->dojo()->setLocalPath($frontController->getBaseUrl() .
> '/js/dojo/dojo/dojo.js');
> $view->dojo()->addLayer('/js/dojo/custom/layer.js');
> $view->dojo()
> ->addStyleSheetModule('dijit.themes.tundra');
>
> Sample form element code:
> $branchId = new Zend_Dojo_Form_Element_FilteringSelect('branchId');
> $branchId->setLabel('Assign To Branch')
> ->setAutoComplete(true)
> ->setStoreId('branchStore')
> ->setStoreType('dojo.data.ItemFileReadStore')
> ->setStoreParams(array('url'=>'/lead/assigntobranch'))
> ->setAttrib("searchAttr", "branchName")
> ->setAttrib('displayedValue', $userBranch)
> ->setRequired(true);
>
> The data is available in the right format at '/lead/assigntobranch'.
>
> Layout:
> echo $this->dojo()->addStylesheetModule('dijit.themes.tundra');
> <body class="tundra">
>
> Other Zend_Dojo_Form elements are working well. Is any change required
> in client code in 1.7.6?
>
> --
>
> With warm regards,
> Sudheer. S
> Business: http://binaryvibes.co.in, Tech stuff: http://techchorus.net, Personal: http://sudheer.net
>
>

--
Matthew Weier O'Phinney
Software Architect | matthew@zend.com
Zend Framework | http://framework.zend.com/

没有评论: