|
@@ -11,12 +11,12 @@ namespace PRSDesktop;
|
|
|
|
|
|
|
|
public class CustomerReceipts : DynamicDataGrid<Receipt>, IPanel<Receipt>
|
|
public class CustomerReceipts : DynamicDataGrid<Receipt>, IPanel<Receipt>
|
|
|
{
|
|
{
|
|
|
- private bool Outstanding = true;
|
|
|
|
|
|
|
+ //private bool Outstanding = true;
|
|
|
|
|
|
|
|
public CustomerReceipts()
|
|
public CustomerReceipts()
|
|
|
{
|
|
{
|
|
|
Options.AddRange(DynamicGridOption.RecordCount, DynamicGridOption.FilterRows, DynamicGridOption.SelectColumns, DynamicGridOption.MultiSelect);
|
|
Options.AddRange(DynamicGridOption.RecordCount, DynamicGridOption.FilterRows, DynamicGridOption.SelectColumns, DynamicGridOption.MultiSelect);
|
|
|
- AddButton("Show All", PRSDesktop.Resources.view.AsBitmapImage(), ToggleView);
|
|
|
|
|
|
|
+ //AddButton("Show All", PRSDesktop.Resources.view.AsBitmapImage(), ToggleView);
|
|
|
OnBeforeSave += BeforeSave;
|
|
OnBeforeSave += BeforeSave;
|
|
|
}
|
|
}
|
|
|
|
|
|
|
@@ -78,18 +78,18 @@ public class CustomerReceipts : DynamicDataGrid<Receipt>, IPanel<Receipt>
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- private bool ToggleView(Button sender, CoreRow[] rows)
|
|
|
|
|
- {
|
|
|
|
|
- Outstanding = !Outstanding;
|
|
|
|
|
- UpdateButton(sender, PRSDesktop.Resources.view.AsBitmapImage(), Outstanding ? "Show All" : "Outstanding");
|
|
|
|
|
- return true;
|
|
|
|
|
- }
|
|
|
|
|
-
|
|
|
|
|
- protected override void Reload(Filters<Receipt> criteria, Columns<Receipt> columns, ref SortOrder<Receipt> sort,
|
|
|
|
|
- Action<CoreTable, Exception> action)
|
|
|
|
|
- {
|
|
|
|
|
- if (Outstanding)
|
|
|
|
|
- criteria.Add(new Filter<Receipt>(x => x.Reconciled).IsEqualTo(DateTime.MinValue));
|
|
|
|
|
- base.Reload(criteria, columns, ref sort, action);
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ // private bool ToggleView(Button sender, CoreRow[] rows)
|
|
|
|
|
+ // {
|
|
|
|
|
+ // Outstanding = !Outstanding;
|
|
|
|
|
+ // UpdateButton(sender, PRSDesktop.Resources.view.AsBitmapImage(), Outstanding ? "Show All" : "Outstanding");
|
|
|
|
|
+ // return true;
|
|
|
|
|
+ // }
|
|
|
|
|
+ //
|
|
|
|
|
+ // protected override void Reload(Filters<Receipt> criteria, Columns<Receipt> columns, ref SortOrder<Receipt> sort,
|
|
|
|
|
+ // Action<CoreTable, Exception> action)
|
|
|
|
|
+ // {
|
|
|
|
|
+ // if (Outstanding)
|
|
|
|
|
+ // criteria.Add(new Filter<Receipt>(x => x.Reconciled).IsEqualTo(DateTime.MinValue));
|
|
|
|
|
+ // base.Reload(criteria, columns, ref sort, action);
|
|
|
|
|
+ // }
|
|
|
}
|
|
}
|