Exemplo n.º 1
0
        public FlowChartDetailGetByMasterInfo QueryFunPlant(int id)
        {
            var masterItem = flowChartMasterRepository.GetById(id);

            FlowChartDetailGetByMasterInfo detailInfo = new FlowChartDetailGetByMasterInfo();

            detailInfo.BU_D_Name     = masterItem.System_Project.System_BU_D.BU_D_Name;
            detailInfo.Project_Name  = masterItem.System_Project.Project_Name;
            detailInfo.Part_Types    = masterItem.Part_Types;
            detailInfo.Product_Phase = masterItem.System_Project.Product_Phase;


            //var list = systemUserOrgRepository.GetChildFunPlant(orgUID);
            //var dtoList = AutoMapper.Mapper.Map<List<SystemOrgDTO>>(list);
            ////为功能厂加上OP类型,以区分不同OP类型相同功能厂
            //foreach (var item in dtoList)
            //{
            //    item.Organization_Name = optype + "_" + item.Organization_Name;
            //}
            //detailInfo.SystemOrgDTOList = dtoList;
            List <SystemFunctionPlantDTO> dtoList = new List <SystemFunctionPlantDTO>();
            var projectItem = systemProjectRepository.GetById(masterItem.Project_UID);
            var list        = systemFunctionPlantRepository.GetMany(m => m.OPType_OrganizationUID == projectItem.Organization_UID).OrderBy(m => m.FunPlant).ToList();

            dtoList = AutoMapper.Mapper.Map <List <SystemFunctionPlantDTO> >(list);
            //为功能厂加上OP类型,以区分不同OP类型相同功能厂
            foreach (var item in dtoList)
            {
                item.FunPlant += "_" + item.OP_Types;
            }
            detailInfo.SystemFunctionPlantDTOList = dtoList;
            return(detailInfo);
        }
Exemplo n.º 2
0
        public FlowChartDetailGetByMasterInfo QueryBindBomByMasterId(int id)
        {
            var masterItem = flowChartMasterRepository.GetById(id);

            FlowChartDetailGetByMasterInfo detailInfo = new FlowChartDetailGetByMasterInfo();

            detailInfo.BU_D_Name     = masterItem.System_Project.System_BU_D.BU_D_Name;
            detailInfo.Project_Name  = masterItem.System_Project.Project_Name;
            detailInfo.Part_Types    = masterItem.Part_Types;
            detailInfo.Product_Phase = masterItem.System_Project.Product_Phase;

            return(detailInfo);
        }