Custom Fields in ME31K , ME32K , ME33K

Custom Fields in ME31K , ME32K , ME33K

As we know the enhancement to the screen is not impossible but it is not supportedbecause we need some S_DEVELOP authorisation and modify some of the Standard table with z fields .That why please consider this document only if water is above your head and is a critical requirement of client

1) Create a Project using CMOD Tcode.

2) Give the enhancement name MM06E005.

3) Go to component Tab.

 

 

4) go to SAPMM06E                       0201 (This is for Header if you want to add tab on Header)

go to layout and design the screen according to your requirement

 

 

It seems you have created your screen. Now go back to PBO and create a module with any name I name it as PBO so as to remove any confusion as described below. Just double click to create it will ask you to create with some name like this ZXM06O01 or whatever just press enter to create save it in your request.

 

 

Now we are reaching towards the conclusion as we are going to play with the data we are going to insert in our fields.

 

First of all in the first screen you will see    EXIT_SAPMM06E_006 double click on that you will find

INCLUDE ZXM06U36-> double click on that->it will ask to create and save it in your request. This is the first exit which is executed so we will export our values from there. After implementing this exit just put a hard break point and for testing execute me33k with->enter agreement number -> execute.

Click on Header our breakpoint will be triggered. This indicates everything is fine (ALL IS WELL).See the below screen the Yellow field is our custom field. Now from here we will export our values so do like this

 

IF i_ekko–zvat is NOT INITIAL.
FREE MEMORY ID ‘ZVAT’.
zvat = i_ekko–zvat.
EXPORT zvat to MEMORY id ‘ZVAT’ .
ENDIF.

IF i_ekko–zdelivery is NOT INITIAL.
FREE MEMORY ID ‘ZDELIVERY’.
zdelivery = i_ekko–zdelivery.
EXPORT zdelivery to MEMORY id ‘ZDELIVERY’ .
ENDIF.

IF i_ekko–ZFREIGHT is NOT INITIAL.
FREE MEMORY ID ‘ZFREIGHT’.
ZFREIGHT = i_ekko–ZFREIGHT.
EXPORT ZFREIGHT to MEMORY id ‘ZFREIGHT’ .
ENDIF.

 


 

In the above part you have exported the values but so as to store this values in table you need to go to the PBO which we have created.It will lead to ZXM06O01 which system has automatically created .

Now here we will manipulate our custom screen like storing the values in standard table or your z table. We will import the value which have been exported earlier.

 

IF sy–tcode EQ ‘ME21N’ OR sy–tcode EQ ‘ME22N’ OR sy–tcode EQ ‘ME23N’.

  

     DATA: zvat TYPE zvat.

     DATA: zdelivery(30) TYPE c.

     DATA: zfreight(50) TYPE c.

     DATA: i_trtyp .

 

     IMPORT zvat TO zvat FROM MEMORY ID ‘ZVAT’.

     IMPORT zdelivery TO zdelivery FROM MEMORY ID ‘ZDELIVERY’.

     IMPORT zfreight TO zfreight FROM MEMORY ID ‘ZFREIGHT’.

 

     IMPORT i_trtyp TO i_trtyp FROM MEMORY ID ‘I_TRTYP’.

 

     ekko_ci–zvat = zvat.

     ekko_ci–zdelivery = zdelivery.

     ekko_ci–zfreight = zfreight.

 

     IF i_trtyp = ‘A’.

**   if sy-tcode = ‘ME23N’ OR sy-tcode EQ ‘ME29N’..

       LOOP AT SCREEN.

         IF screen–group1 = ‘VAT’ OR screen–name = ‘EKKO_CI-ZVAT’.

           screen–input = 0.

         ENDIF.

 

         IF screen–group1 = ‘DEL’ OR screen–name = ‘EKKO_CI-ZDELIVERY’.

           screen–input = 0.

         ENDIF.

 

         IF screen–group1 = ‘FRT’ OR screen–name = ‘EKKO_CI-ZFREIGHT’..

           screen–input = 0.

         ENDIF.

         MODIFY SCREEN.

       ENDLOOP.

**  endif.

     ENDIF.

 

     IF i_trtyp <> ‘A’.

**   if sy-tcode = ‘ME23N’ OR sy-tcode EQ ‘ME29N’..

       LOOP AT SCREEN.

         IF screen–group1 = ‘VAT’ OR screen–name = ‘EKKO_CI-ZVAT’.

           screen–input = 1.

         ENDIF.

 

         IF screen–group1 = ‘DEL’ OR screen–name = ‘EKKO_CI-ZDELIVERY’.

           screen–input = 1.

         ENDIF.

 

         IF screen–group1 = ‘FRT’ OR screen–name = ‘EKKO_CI-ZFREIGHT’..

           screen–input = 1.

         ENDIF.

         MODIFY SCREEN.

       ENDLOOP.

**  endif.

     ENDIF.

 

   ENDIF.

 

Now as per the document everything has been explained regarding storing and retrieving the values from fields. You might have noticed that I have used the zvat field in ekko_ci which is the standard. For doing this you will require S_DEVELOP Authorization to append standard table with your Z feild so consult your basis team soon you get authorization do like this go to se11-> ekko ->scroll down to find CI_EKKODB structure for more explanation find the screen shot

 

 

double click on this CI_EKKODB it will ask you to create the structure -> click on yes button ->the following screen will be displayed.

 

 

now create the z data element  for your fields and enter it save it and activate it.

Now you are ready with the custom fields in Header and your standard table will look like this.

 

  • 0
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 打赏
    打赏
  • 0
    评论
### 回答1: Custom Elements 在迭代中的应用 Custom Elements 是 Web Components 的一部分,它允许开发者创建自定义的 HTML 元素,并在页面中使用。在迭代开发中,Custom Elements 可以帮助开发者更好地组织和管理页面中的元素,提高代码的可维护性和可扩展性。 通过使用 Custom Elements,开发者可以将页面中的元素封装成自定义的组件,然后在页面中使用这些组件。这样可以将页面中的代码分解成更小的模块,使得代码更易于理解和维护。此外,Custom Elements 还可以与其他 Web Components 技术(如 Shadow DOM 和 HTML Templates)一起使用,进一步提高代码的可重用性和可扩展性。 总之,Custom Elements 在迭代开发中的应用非常广泛,它可以帮助开发者更好地组织和管理页面中的元素,提高代码的可维护性和可扩展性。 ### 回答2: 在迭代r中,custom elements是Web组件规范的一部分,它允许开发者创建自定义的HTML元素和标签,以便在网页中使用。custom elements使用了Shadow DOM和HTML Templates来实现这一功能。 通过使用custom elements,开发者可以将自定义的HTML元素定义为一个类,该类继承自HTMLElement类,并包含一些自定义的行为和属性。然后,开发者可以在网页中使用这个自定义的HTML元素,就像使用内置的HTML元素一样。为了在使用这个自定义元素时控制其样式和行为,开发者可以使用Shadow DOM来隔离该元素的样式和DOM。这样,在不同的自定义元素中,相同的样式和DOM结构会得到重用,从而提高了代码的可维护性。 另外,使用custom elements,开发者可以为自定义元素添加生命周期方法,如connectedCallback、disconnectedCallback等。这些方法可以在自定义元素被添加到文档树或从文档树中移除时被调用,开发者可以在这些方法中执行一些初始化或清理的操作。 custom elements的另一个特性是可以为自定义元素定义自定义属性,这些属性可以通过JavaScript来操作,并且能够与其他属性或DOM节点进行绑定,实现更加灵活的交互和功能。 总之,custom elements为开发者提供了一种创建和使用自定义HTML元素的方式,使得代码更加模块化和可重用,同时提供了更多的控制权和灵活性。这对于构建大型Web应用程序和组件库非常有帮助。 ### 回答3: Custom Elements是一种Web技术,它允许我们创建自定义HTML元素,这些元素具有自己的行为和功能。在迭代R中,Custom Elements得到了进一步的改进和扩展。 首先,在迭代R中,Custom Elements的生命周期方法得到了改进。我们可以使用connectedCallback()方法来指定当自定义元素被连接到文档的DOM时所执行的操作。同样地,我们可以使用disconnectedCallback()方法来指定当自定义元素从文档的DOM中移除时所执行的操作。这些改进使得在自定义元素的生命周期中执行特定的操作变得更加灵活和可定制。 其次,在迭代R中,Custom Elements的CSS作用域得到了加强。我们可以使用::part伪类选择器来选择和控制Custom Elements的内部部分,这使得我们可以更好地封装和组织自定义元素的样式。此外,我们还可以使用::theme()伪类选择器来根据用户主题偏好来调整Custom Elements的外观。 第三,在迭代R中,Custom Elements的继承功能得到了改进。我们可以通过extends属性来让一个自定义元素继承另一个自定义元素,从而实现代码和功能的重用。这种继承机制使得开发者可以更方便地创建类似的自定义元素,并且可以从父元素继承一些通用的功能。 总而言之,在迭代R中,Custom Elements在生命周期方法、CSS作用域和继承功能等方面都获得了改进和扩展。这些改进使得开发者能够更好地创建和控制自定义HTML元素,为用户提供更丰富和可定制的Web体验。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

ChampaignWolf

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值