程序包含INCLUDE 使用------------------------------------------隔开
*&---------------------------------------------------------------------*
*& Report ZMMR012
*&---------------------------------------------------------------------*
*&
*&---------------------------------------------------------------------*
REPORT zppr105.
TABLES: rm61h, ekko, marc, plaf, ioitem, mara.
SELECTION-SCREEN BEGIN OF BLOCK blk1 WITH FRAME TITLE TEXT-001.
PARAMETERS: p_werks TYPE rm61h-werks OBLIGATORY DEFAULT '3100'.
SELECT-OPTIONS: s_dispo FOR rm61h-dispo,
s_matnr FOR rm61h-matnr,
s_ekgrp FOR marc-ekgrp,
s_fevor FOR marc-fevor,
s_mtart FOR mara-mtart,
s_matkl FOR mara-matkl,
s_kdauf FOR ioitem-kdauf MATCHCODE OBJECT vmva,
s_kdpos FOR ioitem-kdpos.
PARAMETERS: p_sdatv TYPE rm61p-sdatv,
p_pertr TYPE rm61p-pertr,
p_beskz TYPE rm61p-beskz DEFAULT 'F' OBLIGATORY,
p_fixkz TYPE rm61p-fixkz DEFAULT 'X' AS CHECKBOX,
p_kzzuo TYPE rm61p-kzzuo DEFAULT 'X' AS CHECKBOX.
SELECT-OPTIONS: s_mbeskz FOR marc-beskz NO-EXTENSION NO INTERVALS DEFAULT 'F' , " OBLIGATORY,
s_msobsl FOR marc-sobsl NO-EXTENSION NO INTERVALS.
SELECTION-SCREEN END OF BLOCK blk1.
INCLUDE zppr105top.
INCLUDE zppr105f01.
INITIALIZATION.
PERFORM frm_init_fcat.
AT SELECTION-SCREEN.
PERFORM FRM_JURISD. " 权限检查
START-OF-SELECTION.
PERFORM frm_get_data.
END-OF-SELECTION.
PERFORM frm_show_data.
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
*&---------------------------------------------------------------------*
*& 包含 ZPPR105TOP
*&---------------------------------------------------------------------*
CONSTANTS: cv_vpauft(4) TYPE c VALUE 'VP '. "Vorplanungsauftrag
TYPES: BEGIN OF tp_output.
INCLUDE STRUCTURE plaf.
TYPES: box TYPE xfeld,
lock TYPE xfeld,
lockusr TYPE sy-msgv1,
fixkz TYPE mdba-fixkz,
* zzbednr TYPE mdba-zzbednr,
ekgrp TYPE marc-ekgrp,
fevor TYPE marc-fevor,
mtart TYPE mara-mtart,
matkl TYPE mara-matkl,
maktx TYPE makt-maktx,
mbeskz TYPE marc-beskz,
msobsl TYPE marc-sobsl,
wrkst TYPE mara-wrkst,
zcpgg TYPE mara-zcpgg,
aufnr_t TYPE string,
cy_seqnr_t TYPE string,
zhhbz TYPE eban-zhhbz,
rcol TYPE char4, " 颜色
fstyle TYPE lvc_t_styl,
msg TYPE char100.
TYPES: END OF tp_output.
TYPES: BEGIN OF tp_material,
matnr TYPE marc-matnr,
fevor TYPE marc-fevor,
ekgrp TYPE marc-ekgrp,
mtart TYPE mara-mtart,
matkl TYPE mara-matkl,
maktx TYPE makt-maktx,
beskz TYPE marc-beskz,
sobsl TYPE marc-sobsl,
wrkst TYPE mara-wrkst,
zcpgg TYPE mara