Forum

November 2nd, 2014
A A A
Avatar

Lost password?
Advanced Search

— Forum Scope —




— Match —





— Forum Options —





Minimum search word length is 3 characters - maximum search word length is 84 characters

The forums are currently locked and only available for read only access
sp_Feed Topic RSS sp_TopicIcon
struts2 jQuery Grid dropdown unable to populate data
31/08/2011
18:55
Avatar
JQuery Interest
Member
Members
Forum Posts: 3
Member Since:
31/08/2011
sp_UserOfflineSmall Offline

Hi guys,

In my Edit Grid functionality my dropdown menu is unable to populate data and i still cannot resolve even though i was looking at this thread /blog/?page_id=393/help/strut2-jquery-plugin-grid-table-2-questions . So I need your help as I my new to this.

Basically in my Action class

public class CategoryAction extends ActionSupport {
    private static final long serialVersionUID = 3643090482804105068L;
    private List<String> category;   
    public String execute() throws Exception{            
        generalDelegate util = new generalDelegate();    
        category = util.retrieveCategory();
        System.out.println("+++++++++");
        return "success";
    }
    public List<String> getCategory() {
        return category;
    }
}

the category return the following result [Toothpaste, Body Bath, Shampoo, Shaver Cream, Hand Soap, Facial Wash, Hair Dressing]

In my Struts.xml

        <action name="jsonCategoryAction" class="general.CategoryAction">
            <result type="json" name="success">Category.jsp</result>
        </action>    

and in my Category.jsp

<%@ taglib prefix="s" uri="/struts-tags"%>
<s:select list="category" theme="simple"/>

while lastly my Main.jsp

<s:url id="selectCategoryUrl" action="jsonCategoryAction" />

                    <sjg:gridColumn
                        name="category1"
                        index="category1"
                        title="Item Category"
                        sortable="true"
                        editable="true"
                        edittype="select"
                        editoptions="{ dataUrl : '%{selectCategoryUrl}' }" />  

Pls guide me where did i go wrong.... Thanks a lot Cry

03/09/2011
09:02
Avatar
JQuery Interest
Member
Members
Forum Posts: 3
Member Since:
31/08/2011
sp_UserOfflineSmall Offline

Hi Guys,  Base on my finding, the problem may lies on the dataURL as It seem that i cannot retrieve the dropdown menu in the Category.jsp

Forum Timezone: Europe/Sofia

Most Users Ever Online: 715

Currently Online:
80 Guest(s)

Currently Browsing this Page:
1 Guest(s)

Top Posters:

OlegK: 1255

markw65: 179

kobruleht: 144

phicarre: 132

YamilBracho: 124

Renso: 118

Member Stats:

Guest Posters: 447

Members: 11373

Moderators: 2

Admins: 1

Forum Stats:

Groups: 1

Forums: 8

Topics: 10592

Posts: 31289

Newest Members:

, razia, Prankie, psky, praveen neelam, greg.valainis@pa-tech.com

Moderators: tony: 7721, Rumen[Trirand]: 81

Administrators: admin: 66

Comments are closed.
Privacy Policy   Terms and Conditions   Contact Information