jQWidgets Forums

jQuery UI Widgets Forums Grid DisplayField in Grid not displaying

Tagged: ,

This topic contains 2 replies, has 2 voices, and was last updated by  Hristo 6 years, 7 months ago.

Viewing 3 posts - 1 through 3 (of 3 total)
  • Author
  • DisplayField in Grid not displaying #102182

    CXXXV
    Participant

    I believe I have followed the demos correctly. However, the display field in the Grid does not show. Below are the sections of the code I think are relevant. The column in quetion is “ORIGINATION”.

    Please look and advice. Thanks.

    Source for the foriegn values:

         	var addSource ={
    			type: 'POST',
    			datatype: "json",
    			datafields: [
    							{ name: 'ADDID', type:'integer'},
    							{ name: 'ADDNAME', type:'string'},
    						],	
    			url: 'get_trans_lookups.php',
                    data: {
                        featureClass: 'P',
                        style: 'full',
                        maxRows: 250,
                        QUERY: 'ADDRESS'
                    }								
    		};			
    		
    		var addAdapter = new $.jqx.dataAdapter(addSource,{autoBind: true});
    

    Source for Grid records:

    
    
    		var source ={
    			datatype: "json",
    			localdata: transData,
    			datafields: [
    				{ name: 'TID', type:'integer'},
    				{ name: 'START_DATE', type:'date'},
    				{ name: 'APPT_TIME', type:'date'},
    				{ name: 'RIDER_ID', type: 'string' },
    				{ name: 'ORIGVAL', value: 'ORIG', values:{source: addAdapter.records, value: 'ADDID', name: 'ADDNAME'}},						{ name: 'DEST1', type: 'string' },
    				{ name: 'DR1', type: 'string' },
    				{ name: 'DEST2', type: 'string' },							
    				{ name: 'DR2', type: 'string' },
    				{ name: 'DEST3', type: 'string' },
    				{ name: 'DR3', type: 'string' },							
    				{ name: 'VEH_ID', type: 'string' },
    				{ name: 'COMP', type: 'bool' },
    				{ name: 'CANTRIP', type: 'bool' },
    				],	
    		    ID: 'TID',					
    			async: false
    		};			
    
    		var dataAdapter = new $.jqx.dataAdapter(source);

    Definition of column in Grid:

    			{ text: 'ORIGINATION',  align: 'center', datafield: 'ORIG',  displayfield: 'ORIGVAL', columntype: 'dropdownlist', cellsalign: 'center', width: 164, cellclassname: cellclassname,
    			
    				createeditor: function (row, value, editor) {editor.jqxDropDownList({source: addAdapter, displayMember: 'ADDNAME', valueMember: 'ADDID', width: 300 })						
    						}				
    			
    			},	
    DisplayField in Grid not displaying #102207

    CXXXV
    Participant

    Anyone with an answer.

    DisplayField in Grid not displaying #102211

    Hristo
    Participant

    Hello CXXXV,

    Could you clarify it?
    Is there any error message in the console?
    I tested this example and it seems to work fine.

    Best Regards,
    Hristo Hristov

    jQWidgets team
    http://www.jqwidgets.com

Viewing 3 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic.