Example #1
0
        public IList<ReworkReleaseTypeMaintainInfo> getReworkReleaseTypeList()
        {
            IList<ReworkReleaseTypeMaintainInfo> reworkReleaseTypeList = new List<ReworkReleaseTypeMaintainInfo>();
            try
            {
                IList<string> tmpReworkReleaseTypeList = processRepository.GetReworkReleaseTypeList();

                foreach (string temp in tmpReworkReleaseTypeList)
                {
                    ReworkReleaseTypeMaintainInfo reworkReleaseType = new ReworkReleaseTypeMaintainInfo();

                    reworkReleaseType = convertToReworkReleaseTypeMaintainInfoFromObj(temp);

                    reworkReleaseTypeList.Add(reworkReleaseType);
                }


            }
            catch (FisException e)
            {
                logger.Error(e.mErrmsg);
                throw e;
            }
            catch (Exception e)
            {
                logger.Error(e.Message);
                throw;
            }

            return reworkReleaseTypeList;
        }
Example #2
0
        private ReworkReleaseTypeMaintainInfo convertToReworkReleaseTypeMaintainInfoFromObj(string temp)
        {
            ReworkReleaseTypeMaintainInfo reworkReleaseType = new ReworkReleaseTypeMaintainInfo();

            reworkReleaseType.ReleaseType = temp;

            return reworkReleaseType;
        }
Example #3
0
        private ReworkReleaseTypeMaintainInfo convertToMaintainInfoFromObj(ReworkReleaseType temp)
        {
            ReworkReleaseTypeMaintainInfo reworkReleaseType = new ReworkReleaseTypeMaintainInfo();

            reworkReleaseType.ReleaseType = temp.ReleaseType;
            reworkReleaseType.Process = temp.Process;
            reworkReleaseType.Cdt = temp.Cdt;

            return reworkReleaseType;
        }
Example #4
0
        public void addReworkReleaseType(IList<string> arrCheckedReworkReleaseType, ReworkReleaseTypeMaintainInfo reworkReleaseTypeProcessInfo)
        {
            try
            {

                IUnitOfWork work = new UnitOfWork();

                processRepository.DeleteReworkReleaseTypeByProcessDefered(work, reworkReleaseTypeProcessInfo.Process);

                for (int i = 0; i < arrCheckedReworkReleaseType.Count(); i++)
                {
                    ReworkReleaseType reworkReleaseTypeObj = new ReworkReleaseType();

                    reworkReleaseTypeObj.ReleaseType = arrCheckedReworkReleaseType[i];

                    reworkReleaseTypeObj.Process = reworkReleaseTypeProcessInfo.Process;

                    processRepository.AddReworkReleaseTypeDefered(work, reworkReleaseTypeObj);

                }

                work.Commit();

            }
            catch (FisException e)
            {
                logger.Error(e.mErrmsg);
                throw e;
            }
            catch (Exception e)
            {
                logger.Error(e.Message);
                throw;
            }
        }