public SystemUser_PrivilegeEntity ByPrivilegeNameGetInfo(SystemUser_PrivilegeEntity entity) { CustomDataCommand command = DataCommandManager.CreateCustomDataCommandFromConfig("ByPrivilegeNameGetInfo"); command.SetParameterValue("@PrivilegeName", entity.PrivilegeName); command.SetParameterValue("@SysNo", entity.SysNo); SystemUser_PrivilegeEntity result = command.ExecuteEntity<SystemUser_PrivilegeEntity>(); return result; }
public int ByPrivilegeNameGetInfo(string privilegeName,string sysno) { int SysNo; int.TryParse(sysno,out SysNo); SystemUser_PrivilegeEntity entity = new SystemUser_PrivilegeEntity() { PrivilegeName = privilegeName, SysNo = SysNo }; SystemUser_PrivilegeEntity cheEntity = SystemUser_PrivilegeFacade.ByPrivilegeNameGetInfo(entity); if (cheEntity == null || cheEntity.SysNo == 0) { return 1; } return 0; }
public int Create(SystemUser_PrivilegeEntity obj) { obj.InDate = DateTime.Now; obj.InUser = WebContext.LoginUser.UserName; obj.Status = 0; if (obj.SysNo == 0) { return SystemUser_PrivilegeFacade.InsertSystemUser_Privilege(obj); } else { return SystemUser_PrivilegeFacade.UpdateSystemUser_Privilege(obj); } }
public int InsertSystemUser_Privilege(SystemUser_PrivilegeEntity entity) { CustomDataCommand command = DataCommandManager.CreateCustomDataCommandFromConfig("InsertSystemUser_Privilege"); command.SetParameterValue("@PrivilegeName", entity.PrivilegeName); command.SetParameterValue("@PageAlice", entity.PageAlice); command.SetParameterValue("@ParentSysNo", entity.ParentSysNo); command.SetParameterValue("@Status", entity.Status); command.SetParameterValue("@InUser", entity.InUser); command.SetParameterValue("@InDate", entity.InDate); object obj = command.ExecuteScalar(); if (obj != null) return Convert.ToInt32(obj); else return 0; }
public int UpdateSystemUser_Privilege(SystemUser_PrivilegeEntity entity) { return ObjectFactory<ISystemUser_PrivilegeDataAccess>.Instance.UpdateSystemUser_Privilege(entity); }
public SystemUser_PrivilegeEntity ByPrivilegeNameGetInfo(SystemUser_PrivilegeEntity entity) { return ObjectFactory<ISystemUser_PrivilegeDataAccess>.Instance.ByPrivilegeNameGetInfo(entity); }
public int UpdateSystemUser_Privilege(SystemUser_PrivilegeEntity entity) { CustomDataCommand command = DataCommandManager.CreateCustomDataCommandFromConfig("UpdateSystemUser_Privilege"); command.SetParameterValue("@SysNo", entity.SysNo); command.SetParameterValue("@PrivilegeName", entity.PrivilegeName); command.SetParameterValue("@PageAlice", entity.PageAlice); command.SetParameterValue("@ParentSysNo", entity.ParentSysNo); command.SetParameterValue("@Status", entity.Status); command.SetParameterValue("@InUser", entity.InUser); command.SetParameterValue("@InDate", entity.InDate); return command.ExecuteNonQuery(); }
public static int UpdateSystemUser_Privilege(SystemUser_PrivilegeEntity entity) { return RestClient.Post<int>("SystemUser_PrivilegeService/UpdateSystemUser_Privilege", entity); }
public static SystemUser_PrivilegeEntity ByPrivilegeNameGetInfo(SystemUser_PrivilegeEntity entity) { return RestClient.Post<SystemUser_PrivilegeEntity>("SystemUser_PrivilegeService/ByPrivilegeNameGetInfo", entity); }