コード例 #1
0
        private bool RunProcess()
        {
            MRPBIZ bizMRP = new MRPBIZ();

            ProcessDTO dtoProcess = new ProcessDTO();

            dtoProcess.PROCESS_NO       = (NZString)m_strMRPNo;
            dtoProcess.PROCESS_TYPE     = (NZString)CONST_STR_PROCESS_NAME;
            dtoProcess.STATUS           = (NZString)"S";
            dtoProcess.DESCRIPTION      = (NZString)txtRemark.Text.Trim();
            dtoProcess.START_PRCS_TIME  = (NZDateTime)DateTime.Now;
            dtoProcess.END_PRCS_TIME    = null;
            dtoProcess.FILTER_TIMESTAMP = (NZDateTime)DateTime.Now;
            dtoProcess.FILE_NAME        = null;
            dtoProcess.MD5SUM           = null;
            dtoProcess.IS_CANCEL        = (NZDecimal)0;
            dtoProcess.CANCEL_DATE      = null;
            dtoProcess.CANCEL_BY        = null;
            dtoProcess.CANCEL_MACHINE   = null;
            dtoProcess.PROCESS_DATE     = (NZDateTime)DateTime.Now.Date;
            dtoProcess.PROCESS_BY       = (NZString)Common.CurrentUserInfomation.UserCD;
            dtoProcess.PROCESS_MACHINE  = (NZString)Common.CurrentUserInfomation.Machine;
            dtoProcess.RESERVE1         = null;
            dtoProcess.RESERVE2         = null;

            GenerateMRPDTO dtoMRP = new GenerateMRPDTO();

            dtoMRP.START_DATE       = (NZDateTime)dtpStartDate.Value;
            dtoMRP.RECOVER_DURATION = (NZInt)bizMRP.GetDefaultRecoverDuration();
            dtoMRP.ITEM_FLAG        = (NZBoolean)chkItemFlag.Checked;
            dtoMRP.ITEM_CD_FROM     = (NZString)txtItemCodeFrom.Text.Trim();
            dtoMRP.ITEM_CD_TO       = (NZString)txtItemCodeTo.Text.Trim();
            dtoMRP.USER_CD          = Common.CurrentUserInfomation.UserCD;
            dtoMRP.MACHINE          = Common.CurrentUserInfomation.Machine;

            bizMRP.SimulateMRP(dtoProcess, dtoMRP);

            return(true);
        }