SHARE
TWEET

Untitled

a guest Nov 18th, 2019 121 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. * IMPORTING IV_BANK_ACC_NUMBER TYPE ZWL_BANK_ACC_NUMBER Numer rachunku bankowego
  2. * RETURNING RV_MASK            TYPE ZWL_MASK_VALUE  Wartość maski
  3.  
  4. METHOD get_mask.
  5.  
  6.     READ TABLE me->o_model->get_masks( ) INTO DATA(ls_mask) WITH KEY key = iv_bank_acc_number+2(8).
  7.     IF sy-subrc = 0.
  8.       rv_mask = ls_mask-value.
  9.     ENDIF.
  10.  
  11. ENDMETHOD.
  12.  
  13.  
  14. * IMPORTING IV_MASK             TYPE ZWL_MASK_VALUE Wartość maski
  15. * IMPORTING IV_BANK_ACC_NUMBER  TYPE ZWL_BANK_ACC_NUMBER    Numer rachunku bankowego
  16. * RETURNING RV_BANK_ACC_NUMBER  TYPE ZWL_BANK_ACC_NUMBER    Zamaskowany numer rachunku
  17. * EXCEPTION ZCX_WL_TAXPAYER     Biała Lista: klasa wyjątków
  18.  
  19. METHOD mask_key.
  20.  
  21.     DATA(lv_mask) = iv_mask.
  22.     DATA lv_masked_bank_acc_n LIKE iv_bank_acc_number.
  23.     DATA(lv_char_for_mask) = me->get_file_char_for_mask( ).
  24.  
  25.     lv_masked_bank_acc_n = iv_mask.
  26.  
  27.     DO strlen( lv_masked_bank_acc_n ) TIMES.
  28.  
  29.       DATA(lv_index) = sy-index - 1.
  30.  
  31.       IF sy-index = 100.
  32.         "Błąd podczas maskowania NRB &1.
  33.         RAISE EXCEPTION TYPE zcx_wl_taxpayer MESSAGE ID c_msg_id TYPE 'E' NUMBER '002' WITH iv_bank_acc_number.
  34.       ENDIF.
  35.  
  36.       IF lv_masked_bank_acc_n+lv_index(1) = lv_char_for_mask. "Default Y
  37.         lv_masked_bank_acc_n+lv_index(1) = iv_bank_acc_number+lv_index(1).
  38.       ENDIF.
  39.  
  40.     ENDDO.
  41.  
  42.     rv_bank_acc_number = lv_masked_bank_acc_n.
  43.  
  44.   ENDMETHOD.
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
Not a member of Pastebin yet?
Sign Up, it unlocks many cool features!
 
Top