zoukankan      html  css  js  c++  java
  • 单档——状态码显示设置,状态码更改链表更新

    范例(cxmt631),状态码显示设置(某状态下不显示某些状态码,即有些状态是不可直接更改的为另一种状态的),更改完状态码后同步更新数据表的指定字段;

    1)在cxmt631_statechange 中的statechange.before_menu 下,置入程序:

        
          #add-point:menu前 name="statechange.before_menu"
     
          CASE g_xmabuc_m.xmabucstus
               WHEN "X"
                     CALL cl_set_act_visible("report,factory,Load,pass,valid",FALSE)
               WHEN "01"
                     CALL cl_set_act_visible("Loading,pass",FALSE)
               WHEN "02"
                     CALL cl_set_act_visible("pass",FALSE)
               WHEN "03"
                    CALL cl_set_act_visible("report",FALSE)
               WHEN "04"
                  CALL cl_set_act_visible("factory,report",FALSE)
          END CASE
          #end add-point
          
            

    以上的report、factory等,为功能编号,具体见azzi850;

    01、02、03、04、X,为状态码编码;

    2)每一个状态更改时都同时更新数据表的相关字段,同样是在cxmt631_statechange 下:

    ON ACTION invalid
             IF cl_auth_chk_act("invalid") THEN
                LET lc_state = "X"
                #add-point:action控制 name="statechange.invalid"
                update xmabuc_t set xmabuc004 = lc_state where xmabucdocno = g_xmabuc_m.xmabucdocno and xmabucent = g_enterprise
                if not cl_null(g_xmabuc_m.xmabuc009) then
                    update xmen_t set xmenua003 = lc_state where xmenent = g_enterprise and xmendocno = g_xmabuc_m.xmabuc009
                end if
                #end add-point
             END IF
             EXIT MENU
          ON ACTION report
             IF cl_auth_chk_act("report") THEN
                LET lc_state = "01"
                #add-point:action控制 name="statechange.report"
                update xmabuc_t set xmabuc004 = lc_state where xmabucdocno = g_xmabuc_m.xmabucdocno and xmabucent = g_enterprise
                if not cl_null(g_xmabuc_m.xmabuc009) then
                    update xmen_t set xmenua003 = lc_state where xmenent = g_enterprise and xmendocno = g_xmabuc_m.xmabuc009
                end if
                #end add-point
             END IF
             EXIT MENU
    
          ON ACTION factory
             IF cl_auth_chk_act("factory") THEN
                LET lc_state = "02"
                #add-point:action控制 name="statechange.factory"
                update xmabuc_t set xmabuc004 = lc_state where xmabucdocno = g_xmabuc_m.xmabucdocno and xmabucent = g_enterprise
                if not cl_null(g_xmabuc_m.xmabuc009) then
                    update xmen_t set xmenua003 = lc_state where xmenent = g_enterprise and xmendocno = g_xmabuc_m.xmabuc009
                end if
                #end add-point
             END IF
             EXIT MENU
    
          ON ACTION loading
             IF cl_auth_chk_act("loading") THEN
                LET lc_state = "03"
                #add-point:action控制 name="statechange.loading"
                update xmabuc_t set xmabuc004 = lc_state where xmabucdocno = g_xmabuc_m.xmabucdocno and xmabucent = g_enterprise
                if not cl_null(g_xmabuc_m.xmabuc009) then
                    update xmen_t set xmenua003 = lc_state where xmenent = g_enterprise and xmendocno = g_xmabuc_m.xmabuc009
                end if
                #end add-point
             END IF
             EXIT MENU
    
          ON ACTION pass
             IF cl_auth_chk_act("pass") THEN
                LET lc_state = "04"
                #add-point:action控制 name="statechange.pass"
                update xmabuc_t set xmabuc004 = lc_state where xmabucdocno = g_xmabuc_m.xmabucdocno and xmabucent = g_enterprise
                if not cl_null(g_xmabuc_m.xmabuc009) then
                    update xmen_t set xmenua003 = lc_state where xmenent = g_enterprise and xmendocno = g_xmabuc_m.xmabuc009
                end if
                #end add-point
             END IF
             EXIT MENU
    

      

  • 相关阅读:
    从C#下使用WM_COPYDATA传输数据说到Marshal的应用
    关于C#中实现两个应用程序消息通讯的问题
    内核模块/lib/modules/2.6.2426server/build: No such file or directory. Stop.
    关于BUILD_BUG_ON
    __user && address_space(1)
    Linux Namespaces机制——实现
    inetsw_array的定义中有四个元素IPPROTO_TCP,IPPROTO_UDP,IPPROTO_ICMP,IPPROTO_IP
    需求调研中有效沟通系列如何确认需求?
    ITSM & ITIL QQ群 2月28日讨论 ITIL中什么最重要和优先级最高的聊天记录和总结
    .NET平台下开发HelpDesk(服务台)的广泛应用前景分析
  • 原文地址:https://www.cnblogs.com/xiaoli9627/p/6841139.html
Copyright © 2011-2022 走看看