Ejemplo n.º 1
0
        public List <NOMP> NOMP_Find(List <NOMP> list)
        {
            List <SqlParameter> parameters = new List <SqlParameter>();
            NOMPTableSet        set        = new NOMPTableSet(list);

            parameters.AddInputParameter("@ENP", SqlDbType.Structured, set.NOMPResultTable);
            List <NOMP> result = Execute_GetList(NomernikNOMPMaterializer.Instance, "NOMP_Find", parameters);

            return(result);
        }
Ejemplo n.º 2
0
        public void NOMP_Save(IEnumerable <NOMP> listNOMP, Nomernik.History nompHistory)
        {
            List <SqlParameter> parameters = new List <SqlParameter>();
            NOMPTableSet        set        = new NOMPTableSet(listNOMP);

            parameters.AddInputParameter("@nompTable", SqlDbType.Structured, set.NOMPResultTable);
            parameters.AddInputParameter("@LoadDate", SqlDbType.DateTime, nompHistory.LoadDate);
            parameters.AddInputParameter("@FileDate", SqlDbType.DateTime, nompHistory.FileDate);
            parameters.AddInputParameter("@UserID", SqlDbType.BigInt, nompHistory.UserID);
            parameters.AddInputParameter("@CountAll", SqlDbType.BigInt, nompHistory.CountAll);
            parameters.AddInputParameter("@CountOur", SqlDbType.BigInt, nompHistory.CountOur);
            parameters.AddInputParameter("@CountChange", SqlDbType.BigInt, listNOMP.Count());
            //в процедуре идет запись данных в таблицу NOMP и истории в NOMPHistory
            Execute_StoredProcedure("NOMP_Save", parameters);
        }