12345678910111213141516171819202122232425262728293031323334353637 |
- using System;
- using System.Linq.Expressions;
- using InABox.Core;
- namespace Comal.Classes
- {
-
- public class DataEntryTagRoleEmployeeCrossGenerator : AutoEntityCrossGenerator<IDataEntryTagDistributionEmployee, DataEntryTagRole, EmployeeRole>
- {
- public override Expression<Func<DataEntryTagRole, Guid>> LeftProperty => x => x.Tag.ID;
- public override Expression<Func<IDataEntryTagDistributionEmployee, Guid>> LeftMapping => x => x.Tag.ID;
- public override Expression<Func<DataEntryTagRole, Guid>> LeftLink => x => x.Role.ID;
- public override Expression<Func<EmployeeRole, Guid>> RightProperty => x => x.EmployeeLink.ID;
- public override Expression<Func<IDataEntryTagDistributionEmployee, Guid>> RightMapping => x => x.Employee.ID;
- public override Expression<Func<EmployeeRole, Guid>> RightLink => x => x.RoleLink.ID;
- public override bool Distinct => true;
- public override Column<IDataEntryTagDistributionEmployee>[] IDColumns => new Column<IDataEntryTagDistributionEmployee>[]
- {
- new Column<IDataEntryTagDistributionEmployee>(x => x.Tag.ID),
- new Column<IDataEntryTagDistributionEmployee>(x => x.Employee.ID)
- };
- }
-
- [AutoEntity(typeof(DataEntryTagRoleEmployeeCrossGenerator))]
- public class DataEntryTagRoleEmployee : Entity, IRemotable, IPersistent, IDataEntryTagDistributionEmployee, ILicense<DataEntryLicense>
- {
- public EmployeeLink Employee { get; set; }
- public DataEntryTagLink Tag { get; set; }
- }
- }
|