当前位置 : 主页 > 手机开发 > harmonyos >

基于每个组件检查BOM递归

来源:互联网 收集:自由互联 发布时间:2023-10-08
PARAMETERS : p_matnr type matnr MODIF ID Z1 , p_idnrk type idnrk MODIF ID Z2 . *---- Struktur zum Beschaffen der Dispostufe aus Materialstamm data : begin of tma29v occurs 0 . include structure ma29v . data : end of tma29v . *---- Dispostuf
PARAMETERS 
:  
p_matnr  
type  
matnr MODIF  
ID  
Z1 
, 

             p_idnrk  
type idnrk MODIF  
ID Z2 
. 




 
*---- Struktur zum Beschaffen der Dispostufe aus Materialstamm 

 
data 
:  
begin  
of tma29v  
occurs  
0 
. 

           
include  
structure ma29v 
. 

 
data 
:  
end  
of tma29v 
. 


 
*---- Dispostufenvergabe 

 
data 
:  
begin  
of tmc29u  
occurs  
0 
. 

           
include  
structure mc29u 
. 

 
data 
:  
end  
of tmc29u 
. 



 
*---- Struktur zum Beschaffen der Dispostufe von Materialien ( INPUT ) 

 
data 
:  
begin  
of tpre03  
occurs  
0 
. 

           
include  
structure pre03 
. 

 
data 
:  
end  
of tpre03 
. 


     
clear  
: tma29v 
, 

            tmc29u 
, 

            tpre03 
. 


     
refresh  
: tma29v 
, 

              tmc29u 
, 

              tpre03 
. 


 tpre03 
-MATNR  
= p_matnr 
. 

 
append tpre03 
. 


   
call  
function  
'MATERIAL_READ_DISST' 

          
tables ima29v  
= tma29v 

                ipre03  
= tpre03 
. 


     
loop  
at tma29v 
. 

        
move-corresponding tma29v  
to tmc29u 
. 

        
append tmc29u 
. 

     
endloop 
. 


     
call  
function  
'CS_RC_RECURSIVITY_CHECK' 

          
exporting  eidnrk             
= p_idnrk 

                    emode              
=  
'1' 

          
tables     headertab          
= tmc29u 

          
exceptions recursivity_found  
=  
1 
. 


     
if sy 
-subrc <>  
0 
. 

        
message i000 
( 
26 
)  
with  
'BOM递归错误!' 
. 

     
endif 
.
上一篇:abap 指针使用的一个小例子
下一篇:没有了
网友评论