public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadEmpBeneficiariesList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadEmpBeneficiaries obj in uploadEmpBeneficiariesList)
            {
                EEmpBeneficiaries EmpBeneficiaries = new EEmpBeneficiaries();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    EmpBeneficiaries.EmpBeneficiariesID = obj.EmpBeneficiariesID;
                    uploadDB.select(dbConn, EmpBeneficiaries);
                }

                obj.ExportToObject(EmpBeneficiaries);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    EmpBeneficiaries.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    uploadDB.insert(dbConn, EmpBeneficiaries);
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, EmpBeneficiaries);
                }
                tempDB.delete(dbConn, obj);
            }
        }
        public virtual void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadEmpPayList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadEmpRecurringPayment obj in uploadEmpPayList)
            {
                EEmpRecurringPayment empRP = new EEmpRecurringPayment();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    empRP.EmpRPID = obj.EmpRPID;
                    uploadDB.select(dbConn, empRP);
                }

                obj.ExportToObject(empRP);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    empRP.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    AND andTerms = new AND();
                    andTerms.add(new Match("EmpRPEffFr", "<=", empRP.EmpRPEffFr));
                    andTerms.add(new Match("PayCodeID", empRP.PayCodeID));

                    EEmpRecurringPayment lastObj = (EEmpRecurringPayment)AppUtils.GetLastObj(dbConn, EEmpRecurringPayment.db, "EmpRPEffFr", empRP.EmpID, andTerms);
                    if (lastObj != null)
                    {
                        if (lastObj.EmpRPEffTo.Ticks == 0)
                        {
                            lastObj.EmpRPEffTo = empRP.EmpRPEffFr.AddDays(-1);
                            uploadDB.update(dbConn, lastObj);
                        }
                    }

                    if (obj.UploadEmpAccID > 0)
                    {
                        empRP.EmpAccID = ParseTemp.GetEmpBankAccIDFromUploadEmpBankAccID(dbConn, obj.UploadEmpAccID);
                    }
                    uploadDB.insert(dbConn, empRP);
                    //DBFilter emplastPosFilter = new DBFilter();
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, empRP);
                }

                tempDB.delete(dbConn, obj);
            }
        }
Пример #3
0
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadEmppQualificationList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadEmpQualification obj in uploadEmppQualificationList)
            {
                EEmpQualification empQualification = new EEmpQualification();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    empQualification.EmpQualificationID = obj.EmpQualificationID;
                    uploadDB.select(dbConn, empQualification);
                }

                obj.ExportToObject(empQualification);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    //AND andTerms = new AND();
                    //andTerms.add(new Match("EmpQualificationFrom", "<=", empQualification.EmpQualificationFrom));
                    //andTerms.add(new Match("QualificationID", empQualification.QualificationID));

                    //EEmpQualification lastObj = (EEmpQualification)AppUtils.GetLastObj(dbConn, EEmpQualification.db, "EmpQualificationFrom", empQualification.EmpID, andTerms);
                    //if (lastObj != null)
                    //    if (lastObj.EmpQualificationTo.Ticks == 0)
                    //    {
                    //        lastObj.EmpQualificationTo = empQualification.EmpQualificationFrom.AddDays(-1);
                    //        uploadDB.update(dbConn, lastObj);
                    //    }

                    empQualification.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    uploadDB.insert(dbConn, empQualification);
                    //DBFilter emplastPosFilter = new DBFilter();
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, empQualification);
                }
                tempDB.delete(dbConn, obj);
            }
        }
Пример #4
0
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadEmpBankAccList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadEmpBankAccount obj in uploadEmpBankAccList)
            {
                EEmpBankAccount empBankAcc = new EEmpBankAccount();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    empBankAcc.EmpBankAccountID = obj.EmpBankAccountID;
                    uploadDB.select(dbConn, empBankAcc);
                }

                obj.ExportToObject(empBankAcc);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    empBankAcc.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    uploadDB.insert(dbConn, empBankAcc);
                    obj.EmpBankAccountID = empBankAcc.EmpBankAccountID;
                    tempDB.update(dbConn, obj);
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, empBankAcc);
                }
                if (empBankAcc.EmpAccDefault)
                {
                    DBFilter filter = new DBFilter();
                    filter.add(new Match("EmpBankAccountID", "<>", empBankAcc.EmpBankAccountID));
                    filter.add(new Match("EmpID", empBankAcc.EmpID));
                    filter.add(new Match("EmpAccDefault", "<>", false));
                    EEmpBankAccount t = new EEmpBankAccount();
                    t.EmpAccDefault = false;
                    uploadDB.updateByTemplate(dbConn, t, filter);
                }
                tempDB.delete(dbConn, obj);
            }
        }
Пример #5
0
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadEmpTerminationList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadEmpTermination obj in uploadEmpTerminationList)
            {
                EEmpTermination empTermination = new EEmpTermination();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    empTermination.EmpTermID = obj.EmpTermID;
                    uploadDB.select(dbConn, empTermination);
                }

                obj.ExportToObject(empTermination);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    empTermination.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    uploadDB.insert(dbConn, empTermination);

                    //  Upload Employee Status to Terminated
                    EEmpPersonalInfo empInfo = new EEmpPersonalInfo();
                    empInfo.EmpID     = empTermination.EmpID;
                    empInfo.EmpStatus = "T";
                    EEmpPersonalInfo.db.update(dbConn, empInfo);
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, empTermination);
                    //  Upload Employee Status to Terminated
                    EEmpPersonalInfo empInfo = new EEmpPersonalInfo();
                    empInfo.EmpID     = empTermination.EmpID;
                    empInfo.EmpStatus = "T";
                    EEmpPersonalInfo.db.update(dbConn, empInfo);
                }
                tempDB.delete(dbConn, obj);
            }
        }
Пример #6
0
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadEmpPoRList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadEmpPlaceOfResidence obj in uploadEmpPoRList)
            {
                EEmpPlaceOfResidence empPoR = new EEmpPlaceOfResidence();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    empPoR.EmpPoRID = obj.EmpPoRID;
                    uploadDB.select(dbConn, empPoR);
                }

                obj.ExportToObject(empPoR);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    DBFilter             emplastPosFilter = new DBFilter();
                    EEmpPlaceOfResidence lastObj          = (EEmpPlaceOfResidence)AppUtils.GetLastObj(dbConn, uploadDB, "EmpPoRFrom", empPoR.EmpID, new Match("EmpPoRFrom", "<", empPoR.EmpPoRFrom));
                    if (lastObj != null)
                    {
                        if (lastObj.EmpPoRTo.Ticks == 0)
                        {
                            lastObj.EmpPoRTo = empPoR.EmpPoRFrom.AddDays(-1);
                            uploadDB.update(dbConn, lastObj);
                        }
                    }
                    empPoR.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    uploadDB.insert(dbConn, empPoR);
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, empPoR);
                }
                tempDB.delete(dbConn, obj);
            }
        }
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadLeaveAppList = tempDB.select(dbConn, sessionFilter);

            //Dictionary<int, DateTime> recalLeaveBalanceDateList = new Dictionary<int, DateTime>();

            foreach (EUploadLeaveApplication obj in uploadLeaveAppList)
            {
                ELeaveApplication leaveApplication = new ELeaveApplication();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    leaveApplication.LeaveAppID = obj.LeaveAppID;
                    uploadDB.select(dbConn, leaveApplication);
                }

                obj.ExportToObject(leaveApplication);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    leaveApplication.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);

                    uploadDB.insert(dbConn, leaveApplication);
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, leaveApplication);
                }
                tempDB.delete(dbConn, obj);
            }

            //foreach (int EmpID in recalLeaveBalanceDateList.Keys)
            //{
            //    HROne.LeaveCalc.LeaveBalanceCalc leaaveBalCal = new HROne.LeaveCalc.LeaveBalanceCalc(dbConn, EmpID);
            //    leaaveBalCal.RecalculateAfter(recalLeaveBalanceDateList[EmpID]);

            //}
        }
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadEmpRosterTableGroupList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadEmpRosterTableGroup obj in uploadEmpRosterTableGroupList)
            {
                EEmpRosterTableGroup EmpRosterTableGroup = new EEmpRosterTableGroup();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    EmpRosterTableGroup.EmpRosterTableGroupID = obj.EmpRosterTableGroupID;
                    uploadDB.select(dbConn, EmpRosterTableGroup);
                }

                obj.ExportToObject(EmpRosterTableGroup);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    EmpRosterTableGroup.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    //DBFilter emplastPosFilter = new DBFilter();
                    //EEmpRosterTableGroup lastObj = (EEmpRosterTableGroup)AppUtils.GetLastObj(dbConn, uploadDB, "EmpRosterTableGroupEffFr", EmpRosterTableGroup.EmpID, new Match("EmpRosterTableGroupEffFr", "<", EmpRosterTableGroup.EmpRosterTableGroupEffFr));
                    //if (lastObj != null)
                    //    if (lastObj.EmpRosterTableGroupEffTo.Ticks == 0)
                    //    {
                    //        lastObj.EmpRosterTableGroupEffTo = EmpRosterTableGroup.EmpRosterTableGroupEffFr.AddDays(-1);
                    //        uploadDB.update(dbConn, lastObj);
                    //    }
                    uploadDB.insert(dbConn, EmpRosterTableGroup);
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, EmpRosterTableGroup);
                }
                tempDB.delete(dbConn, obj);
            }
        }
Пример #9
0
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();
            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            ArrayList uploadEmpAVCList = tempDB.select(dbConn, sessionFilter);
            foreach (EUploadEmpAVCPlan obj in uploadEmpAVCList)
            {
                EEmpAVCPlan empAVCPlan = new EEmpAVCPlan();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    empAVCPlan.EmpAVCID = obj.EmpAVCID;
                    uploadDB.select(dbConn, empAVCPlan);
                }

                obj.ExportToObject(empAVCPlan);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    empAVCPlan.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    DBFilter emplastPosFilter = new DBFilter();
                    EEmpAVCPlan lastObj = (EEmpAVCPlan)AppUtils.GetLastObj(dbConn, uploadDB, "EmpAVCEffFr", empAVCPlan.EmpID, new Match("EmpAVCEffFr", "<", empAVCPlan.EmpAVCEffFr));
                    if (lastObj != null)
                        if (lastObj.EmpAVCEffTo.Ticks == 0)
                        {
                            lastObj.EmpAVCEffTo = empAVCPlan.EmpAVCEffFr.AddDays(-1);
                            uploadDB.update(dbConn, lastObj);
                        }
                    uploadDB.insert(dbConn, empAVCPlan);


                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, empAVCPlan);
                }
                tempDB.delete(dbConn, obj);
            }
        }
Пример #10
0
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadEmpFinalPayList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadEmpFinalPayment obj in uploadEmpFinalPayList)
            {
                EEmpFinalPayment EmpFinalPay = new EEmpFinalPayment();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    EmpFinalPay.EmpFinalPayID = obj.EmpFinalPayID;
                    uploadDB.select(dbConn, EmpFinalPay);
                }

                obj.ExportToObject(EmpFinalPay);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    EmpFinalPay.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    if (obj.UploadEmpAccID > 0)
                    {
                        EmpFinalPay.EmpAccID = ParseTemp.GetEmpBankAccIDFromUploadEmpBankAccID(dbConn, obj.UploadEmpAccID);
                    }
                    uploadDB.insert(dbConn, EmpFinalPay);
                    //DBFilter emplastPosFilter = new DBFilter();
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, EmpFinalPay);
                }
                tempDB.delete(dbConn, obj);
            }
        }
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadLeaveBalanceAdjustment obj in uploadList)
            {
                ELeaveBalanceAdjustment leaveBalanceAdjustment = new ELeaveBalanceAdjustment();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    leaveBalanceAdjustment.LeaveBalAdjID = obj.LeaveBalAdjID;
                    uploadDB.select(dbConn, leaveBalanceAdjustment);
                }

                obj.ExportToObject(leaveBalanceAdjustment);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    leaveBalanceAdjustment.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    uploadDB.insert(dbConn, leaveBalanceAdjustment);
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, leaveBalanceAdjustment);
                }

                tempDB.delete(dbConn, obj);
            }
        }
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadCompensationLeaveEntitle obj in uploadList)
            {
                ECompensationLeaveEntitle compLeaveEntitle = new ECompensationLeaveEntitle();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    compLeaveEntitle.CompensationLeaveEntitleID = obj.CompensationLeaveEntitleID;
                    uploadDB.select(dbConn, compLeaveEntitle);
                }

                obj.ExportToObject(compLeaveEntitle);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    compLeaveEntitle.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    uploadDB.insert(dbConn, compLeaveEntitle);
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, compLeaveEntitle);
                }

                tempDB.delete(dbConn, obj);
            }
        }
Пример #13
0
        public void ImportToDatabase(int UploadEmpID)
        {
            DBFilter sessionFilter = new DBFilter();

            sessionFilter.add(new Match("SessionID", m_SessionID));
            if (UploadEmpID > 0)
            {
                sessionFilter.add(new Match("UploadEmpID", UploadEmpID));
            }
            ArrayList uploadEmpCostCenterList = tempDB.select(dbConn, sessionFilter);

            foreach (EUploadEmpCostCenter obj in uploadEmpCostCenterList)
            {
                EEmpCostCenter empCostCenter = new EEmpCostCenter();

                if (obj.ImportActionStatus != ImportDBObject.ImportActionEnum.INSERT)
                {
                    empCostCenter.EmpCostCenterID = obj.EmpCostCenterID;
                    uploadDB.select(dbConn, empCostCenter);
                }

                obj.ExportToObject(empCostCenter);

                if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.INSERT)
                {
                    empCostCenter.EmpID = ParseTemp.GetEmpIDFromUploadEmpID(dbConn, obj.UploadEmpID);
                    EEmpCostCenter lastObj = (EEmpCostCenter)AppUtils.GetLastObj(dbConn, EEmpCostCenter.db, "EmpCostCenterEffFr", empCostCenter.EmpID, new Match("EmpCostCenterEffFr", "<", empCostCenter.EmpCostCenterEffFr));
                    if (lastObj != null)
                    {
                        if (lastObj.EmpCostCenterEffTo.Ticks == 0)
                        {
                            lastObj.EmpCostCenterEffTo = empCostCenter.EmpCostCenterEffFr.AddDays(-1);
                            uploadDB.update(dbConn, lastObj);
                        }
                    }
                    uploadDB.insert(dbConn, empCostCenter);

                    DBFilter uploadEmpCostCenterFilter = new DBFilter();
                    uploadEmpCostCenterFilter.add(new Match("UploadEmpCostCenterID", obj.UploadEmpCostCenterID));
                    ArrayList uploadEmpCostCenterDetailList = EUploadEmpCostCenterDetail.db.select(dbConn, uploadEmpCostCenterFilter);
                    foreach (EUploadEmpCostCenterDetail uploadEmpCostCenterDetail in uploadEmpCostCenterDetailList)
                    {
                        uploadEmpCostCenterDetail.EmpCostCenterID = empCostCenter.EmpCostCenterID;
                        EEmpCostCenterDetail empCostCenterDetail = new EEmpCostCenterDetail();
                        ImportDBObject.CopyObjectProperties(uploadEmpCostCenterDetail, empCostCenterDetail);
                        uploadDetailDB.insert(dbConn, empCostCenterDetail);
                        EUploadEmpCostCenterDetail.db.delete(dbConn, uploadEmpCostCenterDetail);
                    }
                }
                else if (obj.ImportActionStatus == ImportDBObject.ImportActionEnum.UPDATE)
                {
                    uploadDB.update(dbConn, empCostCenter);

                    DBFilter empCostCenterDetailFilter = new DBFilter();
                    empCostCenterDetailFilter.add(new Match("EmpCostCenterID", empCostCenter.EmpCostCenterID));
                    uploadDetailDB.delete(dbConn, empCostCenterDetailFilter);

                    DBFilter uploadEmpCostCenterDetailFilter = new DBFilter();
                    uploadEmpCostCenterDetailFilter.add(new Match("UploadEmpCostCenterID", obj.UploadEmpCostCenterID));
                    ArrayList uploadEmpCostCenterDetailList = EUploadEmpCostCenterDetail.db.select(dbConn, uploadEmpCostCenterDetailFilter);
                    foreach (EUploadEmpCostCenterDetail uploadEmpCostCenterDetail in uploadEmpCostCenterDetailList)
                    {
                        EEmpCostCenterDetail empCostCenterDetail = new EEmpCostCenterDetail();
                        ImportDBObject.CopyObjectProperties(uploadEmpCostCenterDetail, empCostCenterDetail);
                        uploadDetailDB.insert(dbConn, empCostCenterDetail);
                        EUploadEmpCostCenterDetail.db.delete(dbConn, uploadEmpCostCenterDetail);
                    }
                }
                tempDB.delete(dbConn, obj);
            }
        }