美文网首页
BILLING PLAN

BILLING PLAN

作者: 阿努比斯1117 | 来源:发表于2018-06-29 12:00 被阅读0次

    使用BDC创建BILLING PLAN后

    CALL FUNCTION 'BILLING_SCHEDULE_READ'
            EXPORTING
              FPLNR = LS_FPLNR-FPLNR
            TABLES
              ZFPLA = LT_FPLA_OLD
              ZFPLT = LT_FPLT_OLD.
    
          LT_FPLA_NEW = LT_FPLA_OLD.
    
    
          LOOP AT LT_ZSD0015T INTO LS_ZSD0015T WHERE BSTKD = GS_CON-BSTKD
                                                  AND POSEX = GS_CON-POSEX.
            LS_FPLT_NEW-MANDT = SY-MANDT.
            LS_FPLT_NEW-FPLNR = LS_FPLNR-FPLNR.
            LS_FPLT_NEW-FPLTR = LS_ZSD0015T-ZXH.
            LS_FPLT_NEW-FAREG = '4'.            
            LS_FPLT_NEW-UPDKZ = 'I'.
            LS_FPLT_NEW-FPTTP = LS_ZSD0015T-FPTTP.
            LS_FPLT_NEW-AFDAT = LS_ZSD0015T-AFDAT.
            LS_FPLT_NEW-FPROZ = LS_ZSD0015T-FPROZ.
            LS_FPLT_NEW-ZTERM = LS_ZSD0015T-ZTERM.
            APPEND LS_FPLT_NEW TO LT_FPLT_NEW.
    
            CLEAR:LS_ZSD0015T,
                  LS_FPLT_NEW.
          ENDLOOP.
    
    
    
          CALL FUNCTION 'BILLING_SCHEDULE_SAVE'
            TABLES
              FPLA_NEW = LT_FPLA_NEW
              FPLA_OLD = LT_FPLA_OLD
              FPLT_NEW = LT_FPLT_NEW
              FPLT_OLD = LT_FPLT_OLD.
    
          COMMIT WORK AND WAIT.
            LS_FPLT_NEW-FAREG = '4'.            
            LS_FPLT_NEW-UPDKZ = 'I'.      
    
    image.png

    相关文章

      网友评论

          本文标题:BILLING PLAN

          本文链接:https://www.haomeiwen.com/subject/snxayftx.html