您好,欢迎访问三七文档
当前位置:首页 > 商业/管理/HR > 信息化管理 > 采购申请相关bapi
ERPORTZ_CREATE_EBAN.TABLES:EBAN.DATA:BEGINOFLTH_MSG,MESSAGETYPESTRING,ENDOFLTH_MSG.DATA:LTD_MSGLIKESTANDARDTABLEOFLTH_MSG.DATA:BEGINOFIT_EBANOCCURS0,SELTYPEC,BANFNLIKEEBAN-BANFN,采购申请BNFPOLIKEEBAN-BNFPO,请求项目BSARTLIKEEBAN-BSART,凭证类型BSTYPLIKEEBAN-BSTYP,凭证类别LOEKZLIKEEBAN-LOEKZ,删除标识STATULIKEEBAN-STATU,创建标识EKGRPLIKEEBAN-EKGRP,采购组DISPOLIKEEBAN-DISPO,MRP控制者MATNRLIKEEBAN-MATNR,物料WERKSLIKEEBAN-WERKS,工厂PLIFZLIKEEBAN-PLIFZ,计划交货时间LFDATLIKEEBAN-LFDAT,交货日期BADATLIKEEBAN-BADAT,请求日期FRGDTLIKEEBAN-FRGDT,批准日期FIXKZLIKEEBAN-FIXKZ,固定标示PSTYPLIKEEBAN-PSTYP,MENGETYPEI,数量MEINSLIKEEBAN-MEINS,单位MESSAGETYPESTRING,消息INFNRTYPEEBAN-INFNR,信息采购记录MINBMTYPEEINE-MINBM,最小订单量BSTRFLIKEMARC-BSTRF,最小包装量MAKTXTYPESTRING,产品描述FLIEFLIKEEBAN-FLIEF,供应商NAMETYPESTRING,供应商名称EISBELIKEMARC-EISBE,安全库存MMSTALIKEMARC-MMSTA, 物料状态MTSTBLIKET141T-MTSTB,物料状态描述AUSKTLIKEMDEZ-AUSKT,例外信息AUSLTLIKET458B-AUSLT,例外信息文本BISMTLIKEMARA-BISMT,旧物料号EPSTPLIKET163Y-EPSTP,ENDOFIT_EBAN.DATAIT_EBAN1LIKETABLEOFIT_EBANWITHHEADERLINE.DATA:BEGINOFWA_ITAB,WERKSLIKEEBAN-WERKS,工厂BSARTLIKEEBAN-BSART,凭证类别BANFNLIKEEBAN-BANFN,采购申请BNFPOLIKEEBAN-BNFPO,请求项目MATNRLIKEEBAN-MATNR,物料MENGETYPEI,数量MEINSLIKEEBAN-MEINS,EKGRPLIKEEBAN-EKGRP,LFDATLIKEEBAN-LFDAT,交货日期DELTYPEC,BSTYPLIKEEBAN-BSTYP,采购凭证类别韦宝定2012-10-18添加只用于1000工厂ENDOFWA_ITAB,IT_ITABLIKETABLEOFWA_ITABWITHHEADERLINE.DATA:GTH_FIELDCAT_LVCTYPELVC_S_FCAT,GTD_FIELDCAT_LVCTYPELVC_T_FCAT,GTH_FIELDCATTYPELVC_T_FCAT,GTD_FIELDCATTYPELVC_T_FCAT,GTD_FIELDCAT_LVC2TYPELVC_T_FCAT,GST_LAYOUT_LVCTYPELVC_S_LAYO.DATAG_GRIDTYPEREFTOCL_GUI_ALV_GRID.DATA:MY_MESSAGETYPESTRING.SELECTION-SCREENBEGINOFBLOCKBLK01WITHFRAMETITLETEXT-T01.SELECT-OPTIONS:P_WERKSFOREBAN-WERKSOBLIGATORYDEFAULT'1000'.SELECT-OPTIONS:P_BANFNFOREBAN-BANFN,P_BNFPOFOREBAN-BNFPO,P_MATNRFOREBAN-MATNR,P_DISPOFOREBAN-DISPO,P_EKGRPFOREBAN-EKGRP,P_LFDATFOREBAN-LFDAT,P_FIXKZFOREBAN-FIXKZ.SELECTION-SCREENENDOFBLOCKBLK01.SELECTION-SCREENBEGINOFBLOCKBLK02WITHFRAMETITLETEXT-T02.PARAMETERS:RB_1RADIOBUTTONGROUPRG1DEFAULT'X',RB_2RADIOBUTTONGROUPRG1,RB_3RADIOBUTTONGROUPRG1,RB_4RADIOBUTTONGROUPRG1,RB_5RADIOBUTTONGROUPRG1.SELECTION-SCREENENDOFBLOCKBLK02.PARAMETERS:TIPSTYPESTRINGDEFAULT''.IFRB_5='X'.PERFORMGET_EXCEL.ENDIF.IFRB_5'X'.PERFORMGET_DATA.PERFORMSUB_DISPLAY_DATA.ENDIF.INITIALIZATION.IFSY-TCODE='ZPPU060'.LOOPATP_WERKS.P_WERKS-LOW='1200'.MODIFYP_WERKS.ENDLOOP.ENDIF.*&---------------------------------------------------------------------**&FormGET_DATA*&---------------------------------------------------------------------**text*----------------------------------------------------------------------**--p1text*--p2text*----------------------------------------------------------------------*FORMGET_DATA.DATA:BEGINOFWA_MARC,BSTRFLIKEMARC-BSTRF,MATNRLIKEMARC-MATNR,ENDOFWA_MARC,IT_MARCLIKETABLEOFWA_MARCWITHHEADERLINE.IFRB_1='X'.SELECTBANFNBNFPOBSARTBSTYPLOEKZSTATUEKGRPDISPOMATNRWERKSPLIFZLFDATFIXKZMENGEBADATFRGDTINFNRFLIEFMEINSFROMEBANINTOCORRESPONDINGFIELDSOFTABLEIT_EBANWHEREWERKSINP_WERKSANDMATNRINP_MATNRANDBANFNINP_BANFNANDBNFPOINP_BNFPOANDLFDATINP_LFDATANDDISPOINP_DISPOANDEKGRPINP_EKGRPANDFIXKZINP_FIXKZANDBSART='NB'ANDBSTYP='B'ANDSTATU='N'ANDESTKZIN('B','F','U')ANDFIXKZ=''ANDLOEKZ=''ANDEBAKZNE'X'.ELSEIFRB_2='X'.SELECTBANFNBNFPOBSARTBSTYPLOEKZSTATUEKGRPDISPOMATNRWERKSPLIFZLFDATFIXKZMENGEBADATFRGDTINFNRFLIEFMEINSFROMEBANINTOCORRESPONDINGFIELDSOFTABLEIT_EBANWHEREWERKSINP_WERKSANDMATNRINP_MATNRANDBANFNINP_BANFNANDBNFPOINP_BNFPOANDLFDATINP_LFDATANDDISPOINP_DISPOANDEKGRPINP_EKGRPANDFIXKZINP_FIXKZANDBSART='NB'ANDBSTYP='B'ANDSTATUIN('N','B')ANDESTKZIN('B','F','U')ANDFIXKZ='X'ANDLOEKZ=''ANDEBAKZNE'X'.ELSE.SELECTBANFNBNFPOBSARTBSTYPLOEKZSTATUEKGRPDISPOMATNRWERKSPLIFZLFDATFIXKZMENGEBADATFRGDTINFNRFLIEFMEINSPSTYPFROMEBANINTOCORRESPONDINGFIELDSOFTABLEIT_EBANWHEREWERKSINP_WERKSANDMATNRINP_MATNRANDBANFNINP_BANFNANDBNFPOINP_BNFPOANDLFDATINP_LFDATANDDISPOINP_DISPOANDEKGRPINP_EKGRPANDFIXKZINP_FIXKZANDLOEKZNE'X'ANDBSARTIN('NB','Z009')ANDBSTYP='B'ANDSTATU='N'ANDESTKZIN('B','F','U','R')ANDEBAKZ=''ANDLOEKZNE'X'.ENDIF.IFIT_EBAN[]ISNOTINITIAL.DATA:I_NAME1LIKELFA1-NAME1,I_NAME2LIKELFA1-NAME2,I_NAME3LIKELFA1-NAME3,I_NAME4LIKELFA1-NAME4.DATA:I_BSTMILIKEMARC-BSTMI.DATA:IL_TLINELIKETLINEOCCURS0WITHHEADERLINE,VL_TDNAMELIKETHEAD-TDNAME.DATA:IT_MDPSLIKETABLEOFMDPS,IT_MDEZLIKETABLEOFMDEZWITHHEADERLINE,IT_MDSULIKETABLEOFMDSU.LOOPATIT_EBAN.CLEAR:I_NAME1,I_NAME2,I_NAME3,I_BSTMI,I_NAME4.IT_EBAN-SEL='X'.SELECTSINGLEINFNRINTOIT_EBAN-INFNRFROMEINAWHEREMATNR=IT_EBAN-MATNRANDLIFNR=IT_EBAN-FLIEF.*SELECTSINGLE*MINBM*INTOIT_EBAN-MINBM*FROMEINE*WHEREINFNR=IT_EBAN-INFNR.SELECTSINGLEBSTRFBSTMIEISBEMMSTAINTO(IT_EBAN-BSTRF,I_BSTMI,IT_EBAN-EISBE,IT_EBAN-MMSTA)FROMMARCWHEREMATNR=IT_EBAN-MATNRANDWERKSINP_WERKS.SELECTSINGLEMTSTBINTOIT_EBAN-MTSTBFROMT141TWHEREMMSTA=IT_EBAN-MMSTA.SELECTSINGLEBISMTINTOIT_EBAN-BISMTFROMMARAWHEREMATNR=IT_EBAN-MATNR.SELECTSINGLEMAKTXINTOIT_EBAN-MAKTXFROMMAKTWHEREMATNR=IT_EBAN-MATNRANDSPRAS='1'.SELECTSINGLEEPSTPINTOIT_EBAN-EPSTPFROMT163YWHEREPSTYP=IT_EBAN-PSTYPANDSPRAS=1.读取物料的长文本描述VL_TDNAME=IT_EBAN-MATNR.CALLFUNCTION'READ_TEXT'EXPORTINGID='GRUN'LANGUAG
本文标题:采购申请相关bapi
链接地址:https://www.777doc.com/doc-461826 .html