or
<
form
data-bind
=
"submit: submitJbSearch"
>
<
ul
data-role
=
"listview"
>
<
li
>
<
label
>Job
<
input
type
=
"text"
placeholder
=
"Job Number"
data-bind
=
"value: test"
/>
</
label
>
</
li
>
<
li
>
<
label
>Status
<
select
data-bind
=
"options: statuses"
>
</
select
>
</
label
>
</
li
>
<
li
>
<
label
>Customer
<
input
type
=
"text"
placeholder
=
"Customer"
/>
</
label
>
</
li
>
<
li
>
<
label
>PO#
<
input
type
=
"text"
placeholder
=
"PO#"
/>
</
label
>
</
li
>
</
ul
>
</
form
>
<
a
href
=
"#"
data-bind
=
"click: submitJbSearch"
data-role
=
"button"
>Submit</
a
>
'<
li
><
label
><
input
type
=
"checkbox"
data-#=ns#
field
=
"#=columns[col].field#"
data-#=ns#
index
=
"#=columns[col].index#"
/>#=columns[col].title#</
label
></
li
>'+
'<
li
><
input
type
=
"checkbox"
data-#=ns#
field
=
"#=columns[col].field#"
data-#=ns#
index
=
"#=columns[col].index#"
/>#=columns[col].title#</
li
>'
// First put the label BEFORE the input
var
chkIdCounter = 1;
$(
"label > input[type='checkbox']"
).each(
function
() {
$(
this
).attr(
"id"
,
"labeledCheckBox"
+ chkIdCounter);
$(
this
).parent().attr(
"for"
,
"labeledCheckBox"
+ chkIdCounter++);
$(
this
).insertBefore($(
this
).parent().parent().find($(
this
).parent()));});
/* then hide the input and display a sprite in place */
input[type=
"checkbox"
]
{
position
:
absolute
;
display
:
none
;
}
input[type=
"checkbox"
]:checked ~ label::before
{
background-position
:
0
-20px
;
}
/* skin-specific sprite */
input[type=
"checkbox"
] ~ label::before
{
background-image
:
url
(
'itesoft/radios.png'
);
}
grid.destroy();
$("#grid").empty();
and then re-create the grid using the same code that I used to initialize the grid in the first place, however this appears to have the issue that when the data is reloading the reordable facility on the grid ceases to function.
Does anyone know of a way where I can re-load a grid with new data and a new set of columns without the re-odering isue?
Thanks
Craig