Beispiel #1
0
    Boolean ImportFile(string strFilePath1)
    {
        string    _yrmo      = ddlYrmo.SelectedItem.Text;
        bool      importStat = false;
        ImportDAL iObj       = new ImportDAL();

        try
        {
            DataSet           ds   = new DataSet();
            ImportExcelReport tObj = new ImportExcelReport();
            ds = tObj.importHTH(strFilePath1, _yrmo);
            parseDataSet pObj = new parseDataSet();
            pObj.parseHTH(ds, _yrmo);
            counter    = iObj.insertHTHHeadcounts(_yrmo);
            importStat = true;
            int _counter = iObj.getImportCount("HTH", _yrmo);
            Session["taskId"] = Convert.ToInt32(Session["taskId"]) + 1;
            Audit.auditUserTaskI(Session.SessionID, Session["mid"].ToString(), Session["taskId"].ToString(), "ANTHEM", "Anthem Billing Reconciliation", "Headcount", "International HTH Report Import", _yrmo, _counter);
        }
        catch (Exception ex)
        {
            iObj.Rollback("HTH", _yrmo);
            throw ex;
        }
        finally
        {
            File.Delete(strFilePath1);
            FileUpload1.FilePost.InputStream.Flush();
            FileUpload1.FilePost.InputStream.Close();
            FileUpload1.FilePost.InputStream.Dispose();
        }
        return(importStat);
    }
    protected bool importfile(string strFilePath1)
    {
        bool   status = false;
        string yrmo   = ddlYrmo.Text;

        //ImportText adpImport = new ImportText();

        try
        {
            //adpImport.ParseADP(strFilePath1);
            ImportCobra.importADPDetail(yrmo, strFilePath1);
            status = true;
            ImportDAL iobj = new ImportDAL();
            int       _cnt = iobj.getImportCount("ADP", yrmo);
            Session["taskId"] = Convert.ToInt32(Session["taskId"]) + 1;
            Audit.auditUserTaskI(Session.SessionID, Session["mid"].ToString(), Session["taskId"].ToString(), "ANTHEM", "Anthem Billing Reconciliation", "ADP_Details", "ADP Cobra Import", yrmo, _cnt);
        }
        catch (Exception e)
        {
            ImportDAL iObj = new ImportDAL();
            iObj.Rollback("ADP", yrmo);
            throw e;
        }
        finally
        {
            File.Delete(strFilePath1);
        }
        return(status);
    }
    Boolean ImportFile(string strFilePath1)
    {
        string _yrmo      = ddlYrmo.SelectedItem.Text;
        bool   importStat = false;

        ImportDAL iObj = new ImportDAL();

        try
        {
            DataSet           ds   = new DataSet();
            ImportExcelReport tObj = new ImportExcelReport();
            ds = tObj.importAnthemBill(strFilePath1);
            parseDataSet pObj = new parseDataSet();
            pObj.parseAnthem(ds, _yrmo);
            counter    = iObj.insertAnthemHeadcounts(_yrmo);
            importStat = true;
            int _counter = iObj.getImportCount("ANTH", _yrmo);
            Session["taskId"] = Convert.ToInt32(Session["taskId"]) + 1;
            Audit.auditUserTaskI(Session.SessionID, Session["mid"].ToString(), Session["taskId"].ToString(), "ANTHEM", "Anthem Billing Reconciliation", "billing_details", "Anthem Bill Import", _yrmo, _counter);
        }
        catch (Exception ex)
        {
            File.Delete(strFilePath1);
            iObj.Rollback("ANTH", _yrmo);
            throw ex;
        }
        finally
        {
            File.Delete(strFilePath1);
        }
        return(importStat);
    }
    protected bool importfile(string filepath)
    {
        bool       status   = false;
        string     yrmo     = ddlYrmo.Text;
        ImportText grImport = new ImportText();

        try
        {
            grImport.ParseGRS(filepath);
            grImport.importGRSRecords(yrmo);
            status = true;
            ImportDAL iobj = new ImportDAL();
            int       _cnt = iobj.getImportCount("GRS", yrmo);
            Session["taskId"] = Convert.ToInt32(Session["taskId"]) + 1;
            Audit.auditUserTaskI(Session.SessionID, Session["mid"].ToString(), Session["taskId"].ToString(), "ANTHEM", "Anthem Billing Reconciliation", "HeadCounts", "GRS Report Import", yrmo, _cnt);
        }
        catch (Exception e)
        {
            ImportDAL iObj = new ImportDAL();
            iObj.Rollback("GRS", yrmo);
            throw e;
        }
        finally
        {
            ImportTextDAL storeData = new ImportTextDAL();
            storeData.deleteStage("GRS");
            File.Delete(filepath);
        }
        return(status);
    }
    protected bool importfile(string filepath)
    {
        string     yrmo      = ddlYrmo.SelectedItem.Text.ToString();
        bool       status    = false;
        ImportText boaImport = new ImportText();

        try
        {
            boaImport.parseBOA(filepath);
            status = true;
            ImportDAL iobj = new ImportDAL();
            int       _cnt = iobj.getImportCount("BOA", yrmo);
            Session["taskId"] = Convert.ToInt32(Session["taskId"]) + 1;
            Audit.auditUserTaskI(Session.SessionID, Session["mid"].ToString(), Session["taskId"].ToString(), "ANTHEM", "Anthem Claims Reconciliation", "BOAStatement", "BOA Statement Import", yrmo, _cnt);
        }
        catch (Exception e)
        {
            status = false;
            throw e;
        }
        return(status);
    }