Exemple #1
0
        public bool AddType(ItemTypeObject itemType)
        {
            SqlParameter[] params_ = new SqlParameter[] {
                new SqlParameter("@Name", itemType.Name),
                new SqlParameter("@Description", itemType.Description),
                new SqlParameter("@IsActive", itemType.IsActive),
                new SqlParameter("@AddedBy", itemType.AddedBy),
                new SqlParameter("@DateAdded", itemType.DateAdded),
                new SqlParameter("@IP", Helpers.CustomHelper.GetLocalIPAddress()),
                new SqlParameter("@MAC", Helpers.CustomHelper.GetMACAddress())
            };

            return(Library.ConnectionString.returnCon.executeQuery("spAddTypeItem", params_, CommandType.StoredProcedure));
        }
Exemple #2
0
        public bool ActivateType(ItemTypeObject itemtype)
        {
            SqlParameter[] params_ = new SqlParameter[] {
                new SqlParameter("@id", itemtype.Id),
                new SqlParameter("@Code", itemtype.Code),
                new SqlParameter("@table", "tblItemTypes"),
                new SqlParameter("@IP", Helpers.CustomHelper.GetLocalIPAddress()),
                new SqlParameter("@MAC", Helpers.CustomHelper.GetMACAddress()),
                new SqlParameter("@Module", "ITEM"),
                new SqlParameter("@AddedBy", itemtype.AddedBy),
                new SqlParameter("@DateAdded", itemtype.DateAdded)
            };

            return(Library.ConnectionString.returnCon.executeQuery("spActivateItem", params_, CommandType.StoredProcedure));
        }