Exemple #1
0
        public CierreCajaRpt GetDetailReport(CierreCajaInfo item)
        {
            if (item == null)
            {
                return(null);
            }

            CierreCajaRpt doc = new CierreCajaRpt();

            List <CierreCajaPrint> pList = new List <CierreCajaPrint>();

            CierreCajaPrint obj = CierreCajaPrint.New(item);

            List <LineaCajaPrint> pLineaCajas = new List <LineaCajaPrint>();

            foreach (CashLineInfo child in item.LineaCajas)
            {
                pLineaCajas.Add(LineaCajaPrint.New(child));
            }

            pList.Add(obj);
            doc.SetDataSource(pList);
            doc.Subreports["SubLineasCaja"].SetDataSource(pLineaCajas);

            doc.SetParameterValue("Empresa", Schema.Name);

            return(doc);
        }
Exemple #2
0
        public CierreCajaListRpt GetListReport(CierreCajaList list)
        {
            if (list.Count == 0)
            {
                return(null);
            }

            CierreCajaListRpt doc = new CierreCajaListRpt();

            List <CierreCajaPrint> pList = new List <CierreCajaPrint>();

            foreach (CierreCajaInfo item in list)
            {
                pList.Add(CierreCajaPrint.New(item));;
            }

            doc.SetDataSource(pList);

            FormatHeader(doc);

            return(doc);
        }