开发者

Handle combo box events in smart GWT?

开发者 https://www.devze.com 2023-03-26 17:43 出处:网络
class CompanyDataSource extends DataSource { public CompanyDataSource(String id) { setRecordXPath(\"/List/datasource\");
   class CompanyDataSource extends DataSource {

        public CompanyDataSource(String id) {
            setRecordXPath("/List/datasource");
            setID(id);

            DataSourceTextField companyName = new DataSourceTextField("scr开发者_JAVA百科een",
                    "Screen");

            companyName.setValueMap("Google", "EBW", "IBM");
            DataSourceFloatField price = new DataSourceFloatField(
                    "screenInstance", "ScreenInstance");
            price.setValueMap("10.5", "2.1", "9.8");
            // price.setPrimaryKey(true);
            setFields(companyName, price);
            setDataURL("/datasource.data.xml");
        }
    }

This is my DataSource which I am using to display two combo boxes on my ListGrid. Though I am populating price combo box using hardcoded values but I intend to do it dynamically on the selection of companyName combo box values.

Is there any way to handle the selection of companyName combo box value?

0

精彩评论

暂无评论...
验证码 换一张
取 消