I am using nopcommerce 2.60
I need a checkbox for displaying only purchase order orders on button search click.
here are the following steps i did..
I have added new property to OrderListModel
public bool PaymentMethod { get ; set ; }
In order controller, in List() method, i have added the following line
model.PaymentMethod = false;
and in view i have added the following code
<tr>
<td class="adminTitle">
@Html.NopLabelFor(model => model.PaymentMethod):
</td>
<td class="adminData">
@Html.EditorFor(model => Model.PaymentMethod)
</td>
</tr>
in the view i have also added the following in function onDataBinding(e)
PaymentMethod: $('#@Html.FieldIdFor(model => model.PaymentMethod)').val()
The problem is whenever i click on search button or whenever page is loaded for the first time, the model.PaymentMethod is always true....
I need the model.PaymentMethod to change whenever i check or uncheck
May i know what mistake i have done???