public List <T_jhk> GetJhByZydh(long ZyID)
        {
            zydhTableManage zyMan = new zydhTableManage();

            Expression <Func <T_jhk, bool> > where = (c => c.Zydh == ZyID && c.DelFlag == false);
            List <T_jhk> list = zyMan.GetRecord(where);

            if (list.Count != 0)
            {
                return(list);
            }
            else
            {
                return(null);
            }
        }
        /// <summary>
        /// 专业代号,12库来自TDD,17库有单独的基础表
        /// </summary>
        /// <param name="dt"></param>
        /// <param name="nYear"></param>
        /// <param name="lProvinceID"></param>
        private void BuildZYDH(DataTable dt, int nYear, long lProvinceID, long lParentDepartmentID, long lGxID, out List <ListCompareTable> old12ZYDH_list)
        {
            //检查是12库还是17库
            old12ZYDH_list = new List <ListCompareTable>();
            bool flag = false;
            int  i    = 0;

            while ((i < dt.Columns.Count) && !flag)
            {
                if (dt.Columns[i].ColumnName == "ZYMC")  //12库才可能在计划库表中存在ZYMC
                {
                    flag = true;
                }
                else
                {
                    i++;
                }
            }
            if (flag)
            {
                //创建专业类别表
                BuildZYLB(dt, nYear, lProvinceID);
                //根据dt创建专业代号相关的新dt
                DataView  dataView = dt.DefaultView;
                DataTable dt1;
                if (dt.Columns.Contains("TJSXBZ"))
                {
                    dt1 = dataView.ToTable(true, "KLDM", "ZYDH", "ZYDM", "ZYMC", "ZYLB", "TJSXBZ", "XZNX", "TDDW");
                }
                else
                {
                    dt1 = dataView.ToTable(true, "KLDM", "ZYDH", "ZYDM", "ZYMC", "ZYLB", "XZNX", "TDDW");
                }

                zydhTableManage zydhMan = new zydhTableManage();
                zydhMan.KLDM_list              = KLDM_list;
                zydhMan.ZYLBDM_list            = ZYLBDM_list;
                zydhMan.TDDW_list              = TDDW_list;
                zydhMan.XZDM_list              = XZDM_list;
                dt1.Columns["ZYDM"].ColumnName = "ZYLBDM"; //专业代码对应到专业类别代码,ZYLB不要了

                ZYDH_list      = zydhMan.InportOriginData(dt1, nYear, lProvinceID, lParentDepartmentID, lGxID);
                old12ZYDH_list = ZYDH_list;
            }
        }
Beispiel #3
0
        //protected virtual int _DFSSetLine(int nItemPos, int nRowNumX, int nRowNumY, Worksheet ws, ArrayList ItemKeys, ArrayList arrItems, ArrayList arrNames, ArrayList arrValues, ArrayList arrSigns, object tempMan)
        //{
        //    return nRowNumX;
        //}

        protected virtual int DFSSetLine(int nItemPos, int nRowNumX, int nRowNumY, Worksheet ws, ArrayList ItemKeys, ArrayList arrItems, ArrayList arrNames, ArrayList arrValues, ArrayList arrSigns, long ReportTypeID)
        {
            dqdmTableManage   dqMan    = new dqdmTableManage();
            OriginTableManage tableMan = new OriginTableManage();

            for (int i = 0; i < ((ArrayList)arrItems[nItemPos]).Count; i++)
            {
                if (ItemKeys[nItemPos].ToString() == "pcdmTable")
                {
                    continue;
                }

                ArrayList arrNowNames = new ArrayList(); ArrayList arrNowValues = new ArrayList(); ArrayList arrNowSigns = new ArrayList();
                for (int j = 0; j < arrNames.Count; j++)
                {
                    arrNowNames.Add(arrNames[j]);
                    arrNowValues.Add(arrValues[j]);
                    arrNowSigns.Add(arrSigns[j]);
                }

                long   lNowID       = Convert.ToInt64(((ArrayList)arrItems[nItemPos])[i]);
                int    nRowNowNumY  = nRowNumY;
                string sColumnValue = "";
                switch (ItemKeys[nItemPos].ToString())
                {
                case "Department":
                    zydhTableManage   zyMan  = new zydhTableManage();
                    tblDepartmentInfo depart = GetOneRecordbyID <tblDepartmentInfo, long>(lNowID);
                    if (depart.ZYIDs != null && depart.ZYIDs != "" && depart.ZYIDs != " ")
                    {
                        long[] ZyIDs = Array.ConvertAll(depart.ZYIDs.Split(CosValue.SPLITOPERATOR2), long.Parse);
                        if (ZyIDs.Length > 0)
                        {
                            clsExcelApp.SetCellValue(ws, nRowNumX, nRowNowNumY, depart.Name);
                            nRowNowNumY++;
                            int nRowNumXX = nRowNumX;

                            switch (ReportTypeID)
                            {
                            case 1:         //计划库
                                arrNowNames.Add("Zydh"); arrNowValues.Add(0); arrNowSigns.Add(SIGN.Equal); break;

                            case 3:         //批次,第一志愿
                            case 4:
                                arrNowNames.Add("jhk.Zydh"); arrNowValues.Add(0); arrNowSigns.Add(SIGN.Equal); break;

                            default:
                                arrNowNames.Add("Lqzy"); arrNowValues.Add(0); arrNowSigns.Add(SIGN.Equal); break;
                            }
                            for (int j = 0; j < ZyIDs.Length; j++)
                            {
                                arrNowValues[arrNowValues.Count - 1] = ZyIDs[j];
                                Td_zydh zymodel      = GetOneRecordbyID <Td_zydh, long>(ZyIDs[j]);
                                int     nRowNowNumYY = nRowNowNumY;
                                if (zymodel != null)
                                {
                                    clsExcelApp.SetCellValue(ws, nRowNumX, nRowNowNumYY, zymodel.Name); nRowNowNumYY++;
                                    //clsExcelApp.SetCellValue(ws, nRowNumX, nRowNowNumYY, zymodel.Code); nRowNowNumYY++;
                                    nRowNumX = _SetLineCore(nItemPos, nRowNumX, ws, ItemKeys, arrItems, arrNowNames, arrNowValues, arrNowSigns, nRowNowNumYY, ReportTypeID);
                                }
                            }
                            clsExcelApp.UniteCells(ws, nRowNumXX, nRowNowNumY - 1, nRowNumX - 1, nRowNowNumY - 1);
                        }
                    }
                    break;

                case "Province":
                    if (ReportTypeID == 1)     //因为jhk里直接有ProvinceID字段,否则前面要加bmk来找
                    {
                        arrNowNames.Add("ProvinceID");
                    }
                    else
                    {
                        arrNowNames.Add("bmk.ProvinceID");
                    }
                    arrNowValues.Add(lNowID); arrNowSigns.Add(SIGN.Equal);

                    string sProvinceName = dqMan.GetNowNamefromID(lNowID);
                    clsExcelApp.SetCellValue(ws, nRowNumX, nRowNowNumY, sProvinceName);     //省份
                    nRowNowNumY++;
                    nRowNumX = _SetLineCore(nItemPos, nRowNumX, ws, ItemKeys, arrItems, arrNowNames, arrNowValues, arrNowSigns, nRowNowNumY, ReportTypeID);
                    break;

                default:
                    string sNowTableName = ItemKeys[nItemPos].ToString().Replace("Table", "");
                    sNowTableName = "bmk." + sNowTableName.Substring(0, 1).ToUpper() + sNowTableName.Substring(1, sNowTableName.Length - 1);
                    arrNowNames.Add(sNowTableName); arrNowValues.Add(lNowID); arrNowSigns.Add(SIGN.Equal);
                    sColumnValue = tableMan.GetNowNamefromID(lNowID, ItemKeys[nItemPos].ToString());
                    clsExcelApp.SetCellValue(ws, nRowNumX, nRowNowNumY, sColumnValue);
                    nRowNowNumY++;
                    nRowNumX = _SetLineCore(nItemPos, nRowNumX, ws, ItemKeys, arrItems, arrNowNames, arrNowValues, arrNowSigns, nRowNowNumY, ReportTypeID);
                    break;
                }
            }
            return(nRowNumX);
        }
        private void InportOneWholePath(string sNowPath, int nNowYear, long lProvinceID, tblOriginDataPackageInfo model)
        {
            string[] sAllNextPath = Directory.GetFileSystemEntries(sNowPath);
            int      nn           = 1;

            foreach (string sNextPath in sAllNextPath)
            {
                if (Directory.Exists(sNextPath))
                {
                    string ss       = nn.ToString();
                    string sNewPath = sNextPath.Substring(0, sNextPath.LastIndexOf('\\') + 1) + ss;
                    Directory.Move(sNextPath, sNewPath);
                    nn++;
                    InportOneWholePath(sNewPath, nNowYear, lProvinceID, model);
                }
            }
            string[] sNowFileNameSet = GetNowFileSet();
            //打开连接
            string          constr = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + sNowPath + ";Extended Properties=dBASE IV;";
            OleDbConnection con    = new OleDbConnection(constr);

            con.Open();
            //初始化相关的list
            List <ListCompareTable> BYLBDM_list = new List <ListCompareTable>();
            List <ListCompareTable> CCDM_list   = new List <ListCompareTable>();
            List <ListCompareTable> CJXDM_list  = new List <ListCompareTable>();
            List <ListCompareTable> CZLBDM_list = new List <ListCompareTable>();
            List <ListCompareTable> DQDM_list   = new List <ListCompareTable>();

            List <ListCompareTable> HJLBDM_list = new List <ListCompareTable>();
            List <ListCompareTable> JHLBDM_list = new List <ListCompareTable>();
            List <ListCompareTable> JHXZDM_list = new List <ListCompareTable>();
            List <ListCompareTable> KLDM_list   = new List <ListCompareTable>();
            List <ListCompareTable> KMDM_list   = new List <ListCompareTable>();

            List <ListCompareTable> KSLBDM_list = new List <ListCompareTable>();
            List <ListCompareTable> KSLXDM_list = new List <ListCompareTable>();
            List <ListCompareTable> KSTZDM_list = new List <ListCompareTable>();
            List <ListCompareTable> KSZGDM_list = new List <ListCompareTable>();
            List <ListCompareTable> LQFSDM_list = new List <ListCompareTable>();

            List <ListCompareTable> MZDM_list   = new List <ListCompareTable>();
            List <ListCompareTable> PCDM_list   = new List <ListCompareTable>();
            List <ListCompareTable> TDLXDM_list = new List <ListCompareTable>();
            List <ListCompareTable> TDYYDM_list = new List <ListCompareTable>();
            List <ListCompareTable> TJJLDM_list = new List <ListCompareTable>();

            List <ListCompareTable> WYYZDM_list = new List <ListCompareTable>();
            List <ListCompareTable> XTDWDM_list = new List <ListCompareTable>();
            List <ListCompareTable> ZCDM_list   = new List <ListCompareTable>();
            List <ListCompareTable> XZDM_list   = new List <ListCompareTable>();
            List <ListCompareTable> ZJLXDM_list = new List <ListCompareTable>();

            List <ListCompareTable> ZKLXDM_list   = new List <ListCompareTable>();
            List <ListCompareTable> ZYLBDM_list   = new List <ListCompareTable>();
            List <ListCompareTable> ZYTJLXDM_list = new List <ListCompareTable>();
            List <ListCompareTable> ZYTZDM_list   = new List <ListCompareTable>();
            List <ListCompareTable> ZZMMDM_list   = new List <ListCompareTable>();

            List <ListCompareTable> BYXXDM_list = new List <ListCompareTable>();
            List <ListCompareTable> XBDM_list   = new List <ListCompareTable>();

            List <ListCompareTable> TDDW_list = new List <ListCompareTable>();
            List <ListCompareTable> ZYDH_list = new List <ListCompareTable>();

            List <BMKTable>   BMK_list = new List <BMKTable>();
            List <T_jhk>      JHK_list = new List <T_jhk>();
            OriginTableManage man      = new OriginTableManage();
            dqdmTableManage   dqdmMan  = new dqdmTableManage();

            //下面就是一个个表的导入了
            string[] mainColumns = new string[2];
            for (int i = 0; i < sNowFileNameSet.Length; i++)
            {
                string    sNowFileName = sNowFileNameSet[i];
                DataTable dt           = GetDbfDataByODBC(GetPropertyFileName(sNowFileName), sNowPath, con);
                if ((dt != null) && (dt.Rows.Count > 0))
                {
                    //sw.Start();
                    switch (sNowFileName.ToLower())
                    {
                    case "td_bylbdm.dbf":    //毕业类别代码
                        mainColumns[0] = "BYLBDM"; mainColumns[1] = "BYLBMC";
                        BYLBDM_list    = man.InportSimpleTableOriginData <Td_bylbdm, Td_bylbdm_Origin>(dt, nNowYear, lProvinceID, "bylbdmTable", mainColumns);
                        break;

                    case "td_ccdm.dbf":    //层次代码
                        mainColumns[0] = "CCDM"; mainColumns[1] = "CCMC";
                        CCDM_list      = man.InportSimpleTableOriginData <Td_ccdm, Td_ccdm_Origin>(dt, nNowYear, lProvinceID, "ccdmTable", mainColumns);
                        break;

                    case "td_cjxdm.dbf":    //成绩项代码
                        mainColumns[0] = "CJXDM"; mainColumns[1] = "CJXMC";
                        CJXDM_list     = man.InportSimpleTableOriginData <Td_cjxdm, Td_cjxdm_Origin>(dt, nNowYear, lProvinceID, "cjxdmTable", mainColumns);
                        break;

                    case "td_czlbdm.dbf":    //残障类别代码
                        mainColumns[0] = "CZLBDM"; mainColumns[1] = "CZLBMC";
                        CZLBDM_list    = man.InportSimpleTableOriginData <Td_czlbdm, Td_czlbdm_Origin>(dt, nNowYear, lProvinceID, "czlbdmTable", mainColumns);
                        break;

                    case "td_dqdm.dbf":     //地区代码
                        mainColumns[0] = "DQDM"; mainColumns[1] = "DQMC";
                        DQDM_list      = dqdmMan.InportOriginData(dt, nNowYear, lProvinceID, mainColumns);
                        break;

                    case "td_hjlbdm.dbf":     //户籍类别代码
                        mainColumns[0] = "HJLBDM"; mainColumns[1] = "HJLBMC";
                        HJLBDM_list    = man.InportSimpleTableOriginData <Td_hjlbdm, Td_hjlbdm_Origin>(dt, nNowYear, lProvinceID, "hjlbdmTable", mainColumns);
                        break;

                    case "td_jhlbdm.dbf":     //计划类别代码
                        mainColumns[0] = "JHLBDM"; mainColumns[1] = "JHLBMC";
                        JHLBDM_list    = man.InportSimpleTableOriginData <Td_jhlbdm, Td_jhlbdm_Origin>(dt, nNowYear, lProvinceID, "jhlbdmTable", mainColumns);
                        break;

                    case "td_jhxzdm.dbf":     //计划性质代码
                        mainColumns[0] = "JHXZDM"; mainColumns[1] = "JHXZMC";
                        JHXZDM_list    = man.InportSimpleTableOriginData <Td_jhxzdm, Td_jhxzdm_Origin>(dt, nNowYear, lProvinceID, "jhxzdmTable", mainColumns);
                        break;

                    case "td_kldm.dbf":     //科类代码
                        mainColumns[0] = "KLDM"; mainColumns[1] = "KLMC";
                        KLDM_list      = man.InportSimpleTableOriginData <Td_kldm, Td_kldm_Origin>(dt, nNowYear, lProvinceID, "kldmTable", mainColumns);
                        break;

                    case "td_kmdm.dbf":     //科目代码
                        mainColumns[0] = "KMDM"; mainColumns[1] = "KMMC";
                        KMDM_list      = man.InportSimpleTableOriginData <Td_kmdm, Td_kmdm_Origin>(dt, nNowYear, lProvinceID, "kmdmTable", mainColumns);
                        break;

                    case "td_kslbdm.dbf":     //考生类别代码
                        mainColumns[0] = "KSLBDM"; mainColumns[1] = "KSLBMC";
                        KSLBDM_list    = man.InportSimpleTableOriginData <Td_kslbdm, Td_kslbdm_Origin>(dt, nNowYear, lProvinceID, "kslbdmTable", mainColumns);
                        break;

                    case "td_kslxdm.dbf":     //考试类型代码
                        mainColumns[0] = "KSLXDM"; mainColumns[1] = "KSLXMC";
                        KSLXDM_list    = man.InportSimpleTableOriginData <Td_kslxdm, Td_kslxdm_Origin>(dt, nNowYear, lProvinceID, "kslxdmTable", mainColumns);
                        break;

                    case "td_zcdm.dbf":    //政策代码(12有17无)
                        mainColumns[0] = "ZCDM"; mainColumns[1] = "ZCMC";
                        string[] moreColumns1     = { "ZGF" };
                        int[]    moreColumnTypes1 = { CosDataBase.FLOAT_TYPE };
                        KSTZDM_list = man.InportSimpleTableOriginData <Td_kstzdm, Td_kstzdm_Origin>(dt, nNowYear, lProvinceID, "kstzdmTable", mainColumns, moreColumns1, moreColumnTypes1);
                        break;

                    case "td_kstzdm.dbf":    //考生特征代码(17有12无)
                        mainColumns[0] = "KSTZDM"; mainColumns[1] = "KSTZMC";
                        string[] moreColumns2     = { "ZGFS" };
                        int[]    moreColumnTypes2 = { CosDataBase.FLOAT_TYPE };
                        KSTZDM_list = man.InportSimpleTableOriginData <Td_kstzdm, Td_kstzdm_Origin>(dt, nNowYear, lProvinceID, "kstzdmTable", mainColumns, moreColumns2, moreColumnTypes2);
                        break;

                    case "td_kszgdm.dbf":     //考生资格代码
                        mainColumns[0] = "KSZGDM"; mainColumns[1] = "KSZGMC";
                        KSZGDM_list    = man.InportSimpleTableOriginData <Td_kszgdm, Td_kszgdm_Origin>(dt, nNowYear, lProvinceID, "kszgdmTable", mainColumns);
                        break;

                    case "td_lqlxdm.dbf":    //录取类型代码(12)
                        mainColumns[0] = "LQLXDM"; mainColumns[1] = "LQLXMC";
                        LQFSDM_list    = man.InportSimpleTableOriginData <Td_lqfsdm, Td_lqfsdm_Origin>(dt, nNowYear, lProvinceID, "lqfsdmTable", mainColumns);
                        break;

                    case "td_lqfsdm.dbf":     //录取方式代码(17)
                        mainColumns[0] = "LQFSDM"; mainColumns[1] = "LQFSMC";
                        LQFSDM_list    = man.InportSimpleTableOriginData <Td_lqfsdm, Td_lqfsdm_Origin>(dt, nNowYear, lProvinceID, "lqfsdmTable", mainColumns);
                        break;

                    case "td_mzdm.dbf":     //民族代码
                        mainColumns[0] = "MZDM"; mainColumns[1] = "MZMC";
                        MZDM_list      = man.InportSimpleTableOriginData <Td_mzdm, Td_mzdm_Origin>(dt, nNowYear, lProvinceID, "mzdmTable", mainColumns);
                        break;

                    case "td_pcdm.dbf":     //批次代码
                        mainColumns[0] = "PCDM"; mainColumns[1] = "PCMC";
                        PCDM_list      = man.InportSimpleTableOriginData <Td_pcdm, Td_pcdm_Origin>(dt, nNowYear, lProvinceID, "pcdmTable", mainColumns);
                        break;

                    case "td_tdlxdm.dbf":     //投档类型代码
                        mainColumns[0] = "TDLXDM"; mainColumns[1] = "TDLXMC";
                        TDLXDM_list    = man.InportSimpleTableOriginData <Td_tdlxdm, Td_tdlxdm_Origin>(dt, nNowYear, lProvinceID, "tdlxdmTable", mainColumns);
                        break;

                    case "td_tdyydm.dbf":     //退档原因代码
                        mainColumns[0] = "TDYYDM"; mainColumns[1] = "TDYYMC";
                        TDYYDM_list    = man.InportSimpleTableOriginData <Td_tdyydm, Td_tdyydm_Origin>(dt, nNowYear, lProvinceID, "tdyydmTable", mainColumns);
                        break;

                    case "td_tjjldm.dbf":     //体检结论代码
                        mainColumns[0] = "TJJLDM"; mainColumns[1] = "TJJLMC";
                        TJJLDM_list    = man.InportSimpleTableOriginData <Td_tjjldm, Td_tjjldm_Origin>(dt, nNowYear, lProvinceID, "tjjldmTable", mainColumns);
                        break;

                    case "td_wyyzdm.dbf":     //外语语种代码
                        mainColumns[0] = "WYYZDM"; mainColumns[1] = "WYYZMC";
                        WYYZDM_list    = man.InportSimpleTableOriginData <Td_wyyzdm, Td_wyyzdm_Origin>(dt, nNowYear, lProvinceID, "wyyzdmTable", mainColumns);
                        break;

                    case "td_xtdwdm.dbf":     //系统单位代码
                        mainColumns[0] = "XTDWDM"; mainColumns[1] = "XTDWMC";
                        XTDWDM_list    = man.InportSimpleTableOriginData <Td_xtdwdm, Td_xtdwdm_Origin>(dt, nNowYear, lProvinceID, "xtdwdmTable", mainColumns);
                        break;

                    case "td_xzdm.dbf":     //学制代码
                        mainColumns[0] = "XZDM"; mainColumns[1] = "XZMC";
                        XZDM_list      = man.InportSimpleTableOriginData <Td_xzdm, Td_xzdm_Origin>(dt, nNowYear, lProvinceID, "xzdmTable", mainColumns);
                        break;

                    case "td_zjlxdm.dbf":     //证件类型代码
                        mainColumns[0] = "ZJLXDM"; mainColumns[1] = "ZJLXMC";
                        ZJLXDM_list    = man.InportSimpleTableOriginData <Td_zjlxdm, Td_zjlxdm_Origin>(dt, nNowYear, lProvinceID, "zjlxdmTable", mainColumns);
                        break;

                    case "td_zklxdm.dbf":     //招考类型代码
                        mainColumns[0] = "ZKLXDM"; mainColumns[1] = "ZKLXMC";
                        ZKLXDM_list    = man.InportSimpleTableOriginData <Td_zklxdm, Td_zklxdm_Origin>(dt, nNowYear, lProvinceID, "zklxdmTable", mainColumns);
                        break;

                    case "td_zylbdm.dbf":     //专业类别代码 这个表很重要,但是12没有,要从计划库中提取
                        ZYLBDM_list = (new zylbdmTableManage()).InportOriginData(dt, nNowYear, lProvinceID);
                        break;

                    case "td_zytjlxdm.dbf":     //专业调剂类型代码
                        mainColumns[0] = "ZYTJLXDM"; mainColumns[1] = "ZYTJLXMC";
                        ZYTJLXDM_list  = man.InportSimpleTableOriginData <Td_zytjlxdm, Td_zytjlxdm_Origin>(dt, nNowYear, lProvinceID, "zytjlxdmTable", mainColumns);
                        break;

                    case "td_zytzdm.dbf":     //志愿特征代码
                        mainColumns[0] = "ZYTZDM"; mainColumns[1] = "ZYTZMC";
                        ZYTZDM_list    = man.InportSimpleTableOriginData <Td_zytzdm, Td_zytzdm_Origin>(dt, nNowYear, lProvinceID, "zytzdmTable", mainColumns);
                        break;

                    case "td_zzmmdm.dbf":    //政治面貌代码
                        mainColumns[0] = "ZZMMDM"; mainColumns[1] = "ZZMMMC";
                        ZZMMDM_list    = man.InportSimpleTableOriginData <Td_zzmmdm, Td_zzmmdm_Origin>(dt, nNowYear, lProvinceID, "zzmmdmTable", mainColumns);
                        break;

                    case "td_xbdm.dbf":    //性别代码
                        mainColumns[0] = "XBDM"; mainColumns[1] = "XBMC";
                        XBDM_list      = man.InportSimpleTableOriginData <Td_xbdm, Td_xbdm_Origin>(dt, nNowYear, lProvinceID, "xbdmTable", mainColumns);
                        break;

                    case "td_byxxdm.dbf": BYXXDM_list = man.InportSimpleTableOriginData <Td_byxxdm, Td_byxxdm_Origin>(dt, nNowYear, lProvinceID, "byxxdmTable"); break;        //毕业学校代码,这个表原始库中可能没有

                    case "t_tddw.dbf":
                        tddwTableManage tddwMan = new tddwTableManage();
                        tddwMan.PCDM_list   = PCDM_list;
                        tddwMan.KLDM_list   = KLDM_list;
                        tddwMan.JHXZDM_list = JHXZDM_list;
                        tddwMan.JHLBDM_list = JHLBDM_list;
                        TDDW_list           = tddwMan.InportOriginData(dt, nNowYear, lProvinceID, model.GxID);
                        break;

                    case "td_zydh.dbf":     //2017有,2012没有。12的数据来自计划库
                        zydhTableManage zydhMan = new zydhTableManage();
                        zydhMan.CCDM_list   = CCDM_list;
                        zydhMan.KLDM_list   = KLDM_list;
                        zydhMan.XZDM_list   = XZDM_list;
                        zydhMan.ZYLBDM_list = ZYLBDM_list;
                        zydhMan.TDDW_list   = TDDW_list;
                        ZYDH_list           = zydhMan.InportOriginData(dt, nNowYear, lProvinceID, model.ParentDepartmentID, model.GxID);
                        break;

                    case "t_jhk.dbf":
                        jhkTableManage jhkMan = new jhkTableManage();
                        jhkMan.PCDM_list   = PCDM_list;
                        jhkMan.KLDM_list   = KLDM_list;
                        jhkMan.JHXZDM_list = JHXZDM_list;
                        jhkMan.JHLBDM_list = JHLBDM_list;
                        jhkMan.TDDW_list   = TDDW_list;
                        jhkMan.ZYDH_list   = ZYDH_list;
                        jhkMan.ZKLXDM_list = ZKLXDM_list;
                        jhkMan.ZYLBDM_list = ZYLBDM_list;
                        jhkMan.XZDM_list   = XZDM_list;
                        List <ListCompareTable> old12ZYDH_list = new List <ListCompareTable>();
                        JHK_list = jhkMan.InportOriginData(dt, nNowYear, lProvinceID, model.ParentDepartmentID, model.GxID, out old12ZYDH_list);
                        if ((old12ZYDH_list != null) && (old12ZYDH_list.Count > 0))
                        {
                            ZYDH_list = old12ZYDH_list;
                        }
                        break;

                    case "t_bmk.dbf":
                        bmkTableManage bmkMan = new bmkTableManage();

                        bmkMan.BYLBDM_list = BYLBDM_list;
                        bmkMan.CJXDM_list  = CJXDM_list;
                        bmkMan.CZLBDM_list = CZLBDM_list;
                        bmkMan.DQDM_list   = DQDM_list;
                        bmkMan.HJLBDM_list = HJLBDM_list;

                        bmkMan.KLDM_list   = KLDM_list;
                        bmkMan.KMDM_list   = KMDM_list;
                        bmkMan.KSLBDM_list = KSLBDM_list;
                        bmkMan.KSLXDM_list = KSLXDM_list;
                        bmkMan.KSTZDM_list = KSTZDM_list;

                        bmkMan.KSZGDM_list = KSZGDM_list;
                        bmkMan.MZDM_list   = MZDM_list;
                        bmkMan.WYYZDM_list = WYYZDM_list;
                        bmkMan.ZJLXDM_list = ZJLXDM_list;
                        bmkMan.XTDWDM_list = XTDWDM_list;

                        bmkMan.ZZMMDM_list = ZZMMDM_list;
                        bmkMan.BYXXDM_list = BYXXDM_list;
                        bmkMan.XBDM_list   = XBDM_list;

                        BMK_list = bmkMan.InportOriginData(dt, con, sNowPath, nNowYear, lProvinceID, model.GxID);
                        break;

                    case "t_tdd.dbf":
                        tddTableManage tddMan = new tddTableManage();

                        tddMan.BYLBDM_list = BYLBDM_list;
                        tddMan.CCDM_list   = CCDM_list;
                        tddMan.CJXDM_list  = CJXDM_list;
                        tddMan.CZLBDM_list = CZLBDM_list;
                        tddMan.DQDM_list   = DQDM_list;

                        tddMan.HJLBDM_list = HJLBDM_list;
                        tddMan.JHLBDM_list = JHLBDM_list;
                        tddMan.JHXZDM_list = JHXZDM_list;
                        tddMan.KLDM_list   = KLDM_list;
                        tddMan.KMDM_list   = KMDM_list;

                        tddMan.KSLBDM_list = KSLBDM_list;
                        tddMan.KSLXDM_list = KSLXDM_list;
                        tddMan.KSTZDM_list = KSTZDM_list;
                        tddMan.KSZGDM_list = KSZGDM_list;
                        tddMan.LQFSDM_list = LQFSDM_list;

                        tddMan.MZDM_list   = MZDM_list;
                        tddMan.PCDM_list   = PCDM_list;
                        tddMan.TDLXDM_list = TDLXDM_list;
                        tddMan.TDYYDM_list = TDYYDM_list;
                        tddMan.TJJLDM_list = TJJLDM_list;

                        tddMan.WYYZDM_list = WYYZDM_list;
                        tddMan.XTDWDM_list = XTDWDM_list;
                        //tddMan.ZCDM_list = ZCDM_list;
                        tddMan.XZDM_list   = XZDM_list;
                        tddMan.ZJLXDM_list = ZJLXDM_list;

                        tddMan.ZKLXDM_list   = ZKLXDM_list;
                        tddMan.ZYLBDM_list   = ZYLBDM_list;
                        tddMan.ZYTJLXDM_list = ZYTJLXDM_list;
                        tddMan.ZYTZDM_list   = ZYTZDM_list;
                        tddMan.ZZMMDM_list   = ZZMMDM_list;

                        tddMan.BYXXDM_list = BYXXDM_list;
                        tddMan.XBDM_list   = XBDM_list;
                        tddMan.ZYDH_list   = ZYDH_list;
                        tddMan.TDDW_list   = TDDW_list;

                        tddMan.BMK_list = BMK_list;
                        tddMan.JHK_list = JHK_list;

                        BMK_list = tddMan.InportOriginData(dt, con, sNowPath, nNowYear, lProvinceID, model.GxID);
                        break;

                    case "t_zykmx.dbf":
                        zykTableManage zykMan = new zykTableManage();
                        zykMan.PCDM_list   = PCDM_list;
                        zykMan.KLDM_list   = KLDM_list;
                        zykMan.JHXZDM_list = JHXZDM_list;
                        zykMan.JHLBDM_list = JHLBDM_list;
                        zykMan.TDDW_list   = TDDW_list;
                        zykMan.ZYDH_list   = ZYDH_list;
                        zykMan.BMK_list    = BMK_list;
                        zykMan.JHK_list    = JHK_list;
                        zykMan.InportOriginData(dt, nNowYear, lProvinceID);
                        break;

                    case "t_ksjl.dbf":
                        ksjlTableManage ksjlMan = new ksjlTableManage();
                        ksjlMan.BMK_list = BMK_list;
                        ksjlMan.InportOriginData(dt, nNowYear, lProvinceID);
                        break;

                    case "t_kshkcj.dbf":
                    case "t_ksxkcj.dbf":
                        ksxkcjTableManage ksxkcjMan = new ksxkcjTableManage();
                        ksxkcjMan.KMDM_list  = KMDM_list;
                        ksxkcjMan.CJXDM_list = CJXDM_list;
                        ksxkcjMan.BMK_list   = BMK_list;
                        ksxkcjMan.InportOriginData(dt, nNowYear, lProvinceID);
                        break;

                    case "t_tjxx.dbf":
                        tjxxTableManage tjxxMan = new tjxxTableManage();
                        tjxxMan.BMK_list = BMK_list;
                        tjxxMan.InportOriginData(dt, nNowYear, lProvinceID);
                        break;
                    }
                    //sw.Stop();
                    //TimeSpan ts2 = sw.Elapsed;
                }
            }
            con.Close();
        }