public MainMaintenanceViewModel(ICompanyServiceAgent serviceAgent) { this._serviceAgent = serviceAgent; CompanyTypeList = GetCompanyTypes(); CompanyCodeList = GetCompanyCodes(); SetAsEmptySelection(); CompanyList = new BindingList <Company>(); //disable new row feature... CompanyList.AllowNew = false; //make sure of session authentication... if (XERP.Client.ClientSessionSingleton.Instance.SessionIsAuthentic)//make sure user has rights to UI... { DoFormsAuthentication(); } else {//User is not authenticated... RegisterToReceiveMessages <bool>(MessageTokens.StartUpLogInToken.ToString(), OnStartUpLogIn); FormIsEnabled = false; } AllowNew = true; AllowRowPaste = true; }
public CodeSearchViewModel(ICompanyServiceAgent serviceAgent) { this._serviceAgent = serviceAgent; SearchObject = new CompanyCode(); ResultList = new BindingList <CompanyCode>(); SelectedList = new BindingList <CompanyCode>(); //make sure of session authentication... if (XERP.Client.ClientSessionSingleton.Instance.SessionIsAuthentic)//make sure user has rights to UI... { DoFormsAuthentication(); } else {//User is not authenticated... RegisterToReceiveMessages <bool>(MessageTokens.StartUpLogInToken.ToString(), OnStartUpLogIn); FormIsEnabled = false; //we will do forms authentication once the log in returns a valid System User... } }
public MainSearchViewModel(ICompanyServiceAgent serviceAgent) { this._serviceAgent = serviceAgent; CompanyTypeList = GetCompanyTypes(); CompanyCodeList = GetCompanyCodes(); SearchObject = new Company(); ResultList = new BindingList <Company>(); SelectedList = new BindingList <Company>(); //make sure of session authentication... if (XERP.Client.ClientSessionSingleton.Instance.SessionIsAuthentic)//make sure user has rights to UI... { DoFormsAuthentication(); } else {//User is not authenticated... RegisterToReceiveMessages <bool>(MessageTokens.StartUpLogInToken.ToString(), OnStartUpLogIn); FormIsEnabled = false; } }
public CompaniesController(ICompanyServiceAgent companyServiceAgent) { _companyServiceAgent = companyServiceAgent; }