narsil/Tanshu.Accounts.Contracts/Data Contracts/FoodTableBO.cs
tanshu da929ad036 Breaking Change: Changed Kot/Voucher Table Name to Guid Foreign key
Breaking Change: Renamed Discontinued to IsActive and added NA field to products.
Cleanup: Removed not used attributes
Change: RoleConstants changed to simple string
Feature: Table Create/Edit/Reorder and Modifier Create/Edit Form
Feature: Bills now show the Tax name from the database and not a hack
2014-10-16 16:41:55 +05:30

33 lines
1.1 KiB
C#

using NHibernate.Mapping.ByCode.Conformist;
using NHibernate.Mapping.ByCode;
using System;
namespace Tanshu.Accounts.Entities
{
public class FoodTable
{
public virtual Guid FoodTableID { get; set; }
public virtual string Name { get; set; }
public virtual bool IsActive { get; set; }
public virtual string Location { get; set; }
public virtual string Status { get; set; }
public virtual int SortOrder { get; set; }
public virtual Guid? VoucherID { get; set; }
}
public class FoodTableMap : ClassMapping<FoodTable>
{
public FoodTableMap()
{
Table("FoodTables");
Schema("dbo");
Lazy(true);
Id(x => x.FoodTableID, map => map.Generator(Generators.GuidComb));
Property(x => x.Name, map => { map.NotNullable(true); map.Unique(true); });
Property(x => x.IsActive);
Property(x => x.Location);
Property(x => x.Status);
Property(x => x.VoucherID);
Property(x => x.SortOrder);
}
}
}