Properties | SourceCde
Title |  |
Original language | DE | Englisch
Created | 27.10.1998 |  | SAP |
Last changed by | 10.03.2003 |  | SAP |
Status | Active |
Attributes
Type | INCLUDE program |
Status | Test program |
Application | Basis |
Package | SVIM | Basis View Maintenance
| Editor lock
txt
    1
    *&--------------------------------------------------------------------*
    2
    *&      FORM COLLAPSE                                                 *
    3
    *&--------------------------------------------------------------------*
    4
    * collapse                                                            *
    5
    *&--------------------------------------------------------------------*
    6
    FORM collapse USING value(c_begin_ix) TYPE i value(c_end_ix) TYPE i.
    7
      LOCAL: extract.
    8
      DATA: first(1) TYPE c VALUE 'X', hf_ind TYPE i, hf_ind2 TYPE i,
    9
            act_ix TYPE i.
    10
    11
      LOOP AT total.
    12
        act_ix = sy-tabix.
    13
        PERFORM select USING <status>-selected.
    14
        CHECK sy-subrc EQ 0.
    15
        CHECK <vim_tot_mkey_beforeX> EQ <vim_mkey_beforeX> AND
    16
              ( vim_mkey_after_exists EQ space OR
    17
                <vim_tot_mkey_afterx> EQ <vim_mkey_afterx> ).
    18
    *    CHECK <vim_tot_mkey_before> EQ <vim_mkey_before> AND
    19
    *          ( vim_mkey_after_exists EQ space OR
    20
    *            <vim_tot_mkey_after> EQ <vim_mkey_after> ).
    21
        IF first NE space.
    22
    * Changed from XB. 12.06.02 BCEK060520/BCEK060521
    23
          <vim_collapsed_keyx> = <vim_xtotal_key>.
    24
    *      vim_collapsed_mainkeys-mainkey = <vim_total_key>.
    25
          if <vim_collapsed_mkey_bfx> ne <vim_tot_mkey_beforex>.
    26
            <vim_collapsed_mkey_bfx> = <vim_tot_mkey_beforex>.
    27
    *      vim_collapsed_mainkeys-mkey_bf = <vim_tot_mkey_before>.
    28
          endif.
    29
          hf_ind = act_ix.
    30
          CLEAR first.
    31
        ENDIF.
    32
    * Changed from XB. 12.06.02 End.
    33
    34
        IF x_header-delmdtflag EQ 'E'.
    35
          CHECK <vim_begdate> LE sy-datum AND
    36
                <vim_enddate> GE sy-datum.
    37
        ELSE.
    38
          CHECK <vim_begdate> GE sy-datum AND
    39
                <vim_enddate> LE sy-datum.
    40
        ENDIF.
    41
        <vim_collapsed_keyx> = <vim_xtotal_key>.
    42
    * changed from Xue. End.
    43
        if <vim_collapsed_mkey_bfx> ne <vim_tot_mkey_beforex>.
    44
          <vim_collapsed_mkey_bfx> = <vim_tot_mkey_beforex>.
    45
        endif.
    46
    *    vim_collapsed_mainkeys-mainkey = <vim_total_key>.
    47
    *    <vim_collapsed_mkey_bfx> = <vim_tot_mkey_beforex>.
    48
    *    vim_collapsed_mainkeys-mkey_bf = <vim_tot_mkey_before>.
    49
    50
    * Change from Xue. End.
    51
        hf_ind = act_ix.
    52
        EXIT.
    53
      ENDLOOP.
    54
      READ TABLE vim_collapsed_mainkeys
    55
                                    with key <vim_collapsed_keyx>
    56
    *                                WITH KEY vim_collapsed_mainkeys-mainkey
    57
                                    BINARY SEARCH
    58
                                    TRANSPORTING NO FIELDS.
    59
      INSERT vim_collapsed_mainkeys INDEX sy-tabix.
    60
      vim_delim_entries-index1 = hf_ind.
    61
      vim_delim_entries-index2 = c_begin_ix.
    62
      vim_delim_entries-index3 = c_begin_ix.
    63
      vim_delim_entries-index_corr = 'X'.
    64
      APPEND vim_delim_entries.
    65
      hf_ind2 = c_begin_ix + 1.
    66
      CLEAR vim_delim_entries.
    67
      LOOP AT extract FROM hf_ind2 TO c_end_ix.
    68
        vim_delim_entries-index3 = sy-tabix.
    69
        APPEND vim_delim_entries.
    70
      ENDLOOP.
    71
      CLEAR vim_old_viewkey.
    72
      TRANSLATE vim_no_mainkey_exists USING vim_no_mkey_not_procsd_patt.
    73
    ENDFORM.                               "collapse