3ca8b29e04
Regression: PrintLocation added the compare methods back Breaking: Kot.Code is now integers Breaking: Kot Update is now via Stored Procedure to get DB Values Breaking: Reprints Insert is now via Stored Procedure to get DV Values Breaking: Voucher.BillID and KotID are now integers Breaking: Voucher Insert/Update is now via Stored Procedures to get DV Values also Dirty Checking for Voucher has been overwritten to set dirty for LastEditDate update Fix: Login forms simplified Feature: PrintLocation and Products are cached application wide.
36 lines
897 B
C#
36 lines
897 B
C#
using Tanshu.Accounts.Repository;
|
|
using Tanshu.Accounts.Contracts;
|
|
|
|
namespace Tanshu.Accounts.PointOfSale
|
|
{
|
|
class MsrLogin : ILogin
|
|
{
|
|
//private static readonly Tanshu.Logging.SqlLogger log = new Tanshu.Logging.SqlLogger(System.Reflection.MethodBase.GetCurrentMethod().DeclaringType);
|
|
public bool LoginUser()
|
|
{
|
|
return LoginUser(true);
|
|
}
|
|
|
|
static bool LoginUser(bool setSession)
|
|
{
|
|
using (var frm = new MsrLoginForm(false))
|
|
{
|
|
frm.ShowDialog();
|
|
var user = frm.User();
|
|
if (user != null && setSession)
|
|
{
|
|
Session.User = user;
|
|
}
|
|
return user != null;
|
|
}
|
|
|
|
}
|
|
|
|
public bool LogoutUser()
|
|
{
|
|
Session.User = null;
|
|
return true;
|
|
}
|
|
}
|
|
}
|