struts2-jquery

Struts 2 jQuery plugin isSubscribe not working

ε祈祈猫儿з 提交于 2019-12-09 23:32:04
问题 The struts 2 jQuery plugin has a built in publish / subscribe framework. If you define your own publish and subscribe event (for example on a grid) the subscribed function will be called every time the event is published. For details please see (Struts 2 jQuery Subscribe is called more than once) To prevent this, there is a isSubscribed method which can be used. For a grid as: <sjg:grid id="gridtable" onBeforeTopics="before_grid_load" > The JS will be: $.subscribe('before_grid_load', function

Struts2-Jquery Grid CSS Editing [closed]

自闭症网瘾萝莉.ら 提交于 2019-12-09 06:42:26
Closed . This question needs details or clarity . It is not currently accepting answers. Want to improve this question? Add details and clarify the problem by editing this post . Closed 4 years ago . I have a Struts2-jquery Grid component on my webpage. It works perfectly, but how can I edit the CSS rules for the Struts2-jQuery-Grid plugin ? Can I apply my custom CSS rules to this grid view ? To answer your question: how to create a new jquery theme? Just like @Andrea mentioned, You should use jQuery ThemeRoller Define your sj:head like this <%@ taglib prefix="s" uri="/struts-tags"%> <%@

Struts2 jquery Grid ajax data reload on form submit

大城市里の小女人 提交于 2019-12-08 11:08:52
问题 I have a fairly simple use case in which, I have a search form and a Grid The grid is suppose to show some default results on loadSearch.action. When the user enters few criteria in search form and hit submit button then ajax results must be reloaded in the grid below. I am getting the results via post response but not able to show them inside grid. Here is my code <%@ taglib prefix="s" uri="/struts-tags"%><%@ taglib prefix="sx" uri="/struts-dojo-tags" %> <%@ taglib prefix="sj" uri="/struts

How to avoid conflict between two version of Jquery library?

与世无争的帅哥 提交于 2019-12-08 08:48:36
问题 In jsp page, i am using struts2-jquery-plugin-3.2.1.jar (it uses internally jquery-1.6.4.js) and i am using facebox (it uses jquery-1.4.3.min.js). So my struts2-jquery-plugin-3.2.1.jar load first then facebox jquery. but when i put jquery-1.4.3.min.js my struts2-jquery-plugin-3.2.1.jar stops working and when i remove jquery-1.4.3.min.js obviously my facebox stops working. I follow these forum : here and here but not able to fix this problem.One guy advise me to use new version of struts2

stuck in obtaining id of a specific row when users click the delete button of Struts2 jquery grid

社会主义新天地 提交于 2019-12-08 04:30:38
问题 I am developing a small application in struts 2 with Jquery Grid for displaying data results. When i click edit button then the specific row id is coming. But when i click the delete button for deleting that row ,then its id is not coming. How to get the id of row when delete action is performed with the selected row(Struts2 Jquery Grid)? Plz help me for this. myJspFile.jsp <%@ page contentType="text/html; charset=UTF-8"%> <%@ taglib prefix="s" uri="/struts-tags"%> <%@ taglib prefix="sj" uri=

Struts 2 - Intercept an image file uploading with CKEditor

余生颓废 提交于 2019-12-07 12:48:09
问题 I have a CKEditor on different pages of the site, so I settled up the uploads to true and all the configuration stuff for it to work, and the image upload worked just fine for "Send it to the Server" tab. But from here I want to intercept or interact with upload function to be able to upload images not to a folder, but into database with some flags like "page" where is image uploaded, "category" , "cropping" and some another manipulations with them. So how could it be done to intercept this

Hiding a datepicker using jQuery

感情迁移 提交于 2019-12-07 07:15:17
问题 I am using struts2 jquery plugin s datepicker as below <sj:datepicker id="frdate" name="training.fromDate" label="From Date (dd-mm-yyyy)" maxDate="0" /> I want to hide this on certain coditions.I have written a jquery like this. $("#frdate").hide(); //this will hide textbox of datepicker $("label[for='frdate']").hide(); // this will hide label of datepicker But datepicker button still showing? How to hide it using jquery? The generated html code is: <tr> <td class="tdLabel"> <label for=

Using a drop-down list in an editable grid column using Struts2-jQuery-grid plugin

北城余情 提交于 2019-12-07 04:45:16
问题 I'm trying to populate a drop down list in a grid column using the Struts2-jQuery-grid-3.7.0 plugin as follows. <s:url id="dataURL" action="CategoryList" namespace="/admin_side"/> <sjg:gridColumn name="subCategory.category.catName" index="subCategory.category.catName" edittype="select" searchtype="select" formoptions="{label:'Select'}" surl="%{dataURL}" editoptions="{dataUrl : '%{dataURL}'}" editrules="{required: true}" title="Category" width="200" sortable="true" search="true" editable="true

Hiding a datepicker using jQuery

做~自己de王妃 提交于 2019-12-05 16:37:02
I am using struts2 jquery plugin s datepicker as below <sj:datepicker id="frdate" name="training.fromDate" label="From Date (dd-mm-yyyy)" maxDate="0" /> I want to hide this on certain coditions.I have written a jquery like this. $("#frdate").hide(); //this will hide textbox of datepicker $("label[for='frdate']").hide(); // this will hide label of datepicker But datepicker button still showing? How to hide it using jquery? The generated html code is: <tr> <td class="tdLabel"> <label for="frdate" class="label">From Date (dd-mm-yyyy):</label></td> <td><input type="text" name="training.fromDate"

Using a drop-down list in an editable grid column using Struts2-jQuery-grid plugin

眉间皱痕 提交于 2019-12-05 11:36:59
I'm trying to populate a drop down list in a grid column using the Struts2-jQuery-grid-3.7.0 plugin as follows. <s:url id="dataURL" action="CategoryList" namespace="/admin_side"/> <sjg:gridColumn name="subCategory.category.catName" index="subCategory.category.catName" edittype="select" searchtype="select" formoptions="{label:'Select'}" surl="%{dataURL}" editoptions="{dataUrl : '%{dataURL}'}" editrules="{required: true}" title="Category" width="200" sortable="true" search="true" editable="true" sorttype="text"/> And the action where the CategoryList action is mapped is as follows. @Namespace("