-
12 Jun 2008 3:49 AM #121
Hi Saki,
I tried to use your nice extension with store but when i click outside the LovCombo it clears the value of the field
What I am doing wrong?
Code:var propertyType = new Ext.ux.form.LovCombo({ id:'lovcombo', width:170, hideLabel:true, maxHeight:200, store:stores.type,displayField:"tip",valueField:"id",hiddenName:'tip',typeAhead:true, triggerAction:'all',mode:'local',emptyText:'Тип на имота' }); stores.type = new Ext.data.Store({ url: FOLDERS.domainRoot+'data.php?action=get&useQuery=1', reader: new Ext.data.JsonReader( {totalProperty: 'totalCount',root: 'data'}, [{name: 'id'},{name: 'tip'}] ) }); stores.type.load();
-
12 Jun 2008 2:31 PM #122
When I submit a form with a LovCombo, the value that's getting POST'ed to my PHP url is the display value, not the hidden value. Is there a way around this, or am I missing something?
-
12 Jun 2008 2:57 PM #123
Do you set hiddenName? Same applies for normal combo.
Jozef Sakalos, aka Saki
A lot of valuable info at:
Saki's Extensions and Plugins
Saki's Extensions and Plugins Docs
Saki's Examples, Latest: Grid in Card Layout
Saki's Blog, Featured: Writing a Big Application in Ext, Latest: Grid MultiSearch Plugin Video
-
12 Jun 2008 2:59 PM #124
Try to turn off typeAhead. If it doesn't help post a complete showcase please. Also, compare where you code differs from example code http://lovcombo.extjs.eu
Jozef Sakalos, aka Saki
A lot of valuable info at:
Saki's Extensions and Plugins
Saki's Extensions and Plugins Docs
Saki's Examples, Latest: Grid in Card Layout
Saki's Blog, Featured: Writing a Big Application in Ext, Latest: Grid MultiSearch Plugin Video
-
12 Jun 2008 11:58 PM #125
I'm sorry. The problem was in the data from the store. After 1 hour in debug I found my error. Sorry for the misunderstanding!
-
13 Jun 2008 6:58 AM #126
Can you provide some documentation or something or to tell me how is the right way to setValue(). I tried combo.setValue("2,3,4") but it only clears the combo
-
14 Jun 2008 3:52 AM #127
Documentation is in the comments of the source.
Jozef Sakalos, aka Saki
A lot of valuable info at:
Saki's Extensions and Plugins
Saki's Extensions and Plugins Docs
Saki's Examples, Latest: Grid in Card Layout
Saki's Blog, Featured: Writing a Big Application in Ext, Latest: Grid MultiSearch Plugin Video
-
16 Jun 2008 3:49 PM #128
great extension! it works for me pretty well for the most part except in internet explorer 6 where the dropdown's overflow isn't being hidden properly in the case of where the combo's width is smaller than the text involved. renders fine in firefox though, of course.
anyone have any ideas? this is stock ext 2.0.2 css.
-
17 Jun 2008 12:40 AM #129
Doctype in IE? ... I have no other clue ...
Jozef Sakalos, aka Saki
A lot of valuable info at:
Saki's Extensions and Plugins
Saki's Extensions and Plugins Docs
Saki's Examples, Latest: Grid in Card Layout
Saki's Blog, Featured: Writing a Big Application in Ext, Latest: Grid MultiSearch Plugin Video
-
17 Jun 2008 7:19 AM #130
no doctype specified like what the wiki suggests. this occurs in ie6 and ie7. if you have the time, here's a test case:
i'm sure it's just a css overflow issue but i'm having a hard time figuring out all of the ie css quirks and workarounds.Code:<html> <head> <title>Example</title> <script type="text/javascript" src="../ext-2.0.2/adapter/ext/ext-base.js"></script> <script type="text/javascript" src="../ext-2.0.2/ext-all-debug.js"></script> <script type="text/javascript" src="../js/contrib/Ext.ux.form.LovCombo.js"></script> <link rel="stylesheet" type="text/css" href="../ext-2.0.2/resources/css/ext-all.css" /> <link rel="stylesheet" type="text/css" href="../css/Ext.ux.form.LovCombo.css" /> <script type="text/javascript"> Ext.onReady(function(){ var attrstore = new Ext.data.SimpleStore({ storeId: 'CGR', id: 1, name: 'Cultural Group Categories', valueType: 'list', fields: ['label', 'value'], data: [["African-American","AFR"],["Anglo-American","ANG"],["Arab-American (includes Middle East and N. Africa)","ARB"],["Asian-American (includes Proper and Southeast)","ASN"],["Caribbean-American","CAR"],["Euro-American","EUR"],["Pacific Islander & American Indians","IAI"],["Jewish-Americans","JEH"],["Latino-Americans","LAT"],["Middle Asian-Americans","MAS"],["Mediterranean-Americans","MED"],["Multiethnic","MTE"],["No Cultural Group (No cultural group label has been used in this item)","NCG"]] }); var dd = new Ext.ux.form.LovCombo({ autoCreate: true, fieldLabel: 'lovcombo', store: attrstore, multiSelect: true, displayField: 'label', valueField: 'value', mode: 'local', triggerAction: 'all', selectOnFocus: true, hiddenName: 'dd-hidden', anchor: '90% -18' }); var viewport = new Ext.Viewport({ layout:'border', items: [ new Ext.Panel({region: 'north', html: 'header'}), new Ext.FormPanel({region: 'west', width: 170, labelAlign: 'top', split: true, items: [dd]}), new Ext.Panel({id: 'center', region: 'center'}), new Ext.Panel({region: 'east', html: 'east', width: 170}) ] }); }); </script> </head> <body> </body> </html>


Reply With Quote
