|
@@ -1,4 +1,5 @@
|
|
|
using System;
|
|
|
+using System.Collections.Generic;
|
|
|
using System.Linq;
|
|
|
using InABox.Core;
|
|
|
|
|
@@ -6,15 +7,32 @@ namespace Comal.Classes
|
|
|
{
|
|
|
public class BillLineLink : EntityLink<BillLine>
|
|
|
{
|
|
|
- [NullEditor]
|
|
|
+ [PopupEditor(typeof(BillLine))]
|
|
|
public override Guid ID { get; set; }
|
|
|
|
|
|
[RequiredColumn]
|
|
|
public BillLink BillLink { get; set; }
|
|
|
}
|
|
|
|
|
|
+ internal class BillLineLookups : EntityLookup<BillLine>
|
|
|
+ {
|
|
|
+ public override Filter<BillLine>? DefineFilter() => null;
|
|
|
+
|
|
|
+ public override SortOrder<BillLine>? DefineSortOrder() => null;
|
|
|
+
|
|
|
+ public override Columns<BillLine> DefineColumns()
|
|
|
+ {
|
|
|
+ return base.DefineColumns().Add(x => x.BillLink.Number).Add(x => x.Description);
|
|
|
+ }
|
|
|
+
|
|
|
+ public override string FormatLookup(Dictionary<string, object?> values, IEnumerable<string> exclude)
|
|
|
+ {
|
|
|
+ return base.FormatLookup(values, exclude);
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
[UserTracking(typeof(Bill))]
|
|
|
- public class BillLine : Entity, IPersistent, IRemotable, IOneToMany<Bill>, ITaxable, ILicense<AccountsPayableLicense>, IPostableFragment<Bill>
|
|
|
+ public class BillLine : Entity, IPersistent, IRemotable, IOneToMany<Bill>, ITaxable, ILicense<AccountsPayableLicense>, IPostableFragment<Bill>, IEntityLookup<BillLine, BillLineLookups>
|
|
|
{
|
|
|
[RequiredColumn]
|
|
|
[EntityRelationship(DeleteAction.Cascade)]
|