CE PLUS - Nota 001944

Módulo: DOC. IMPORTAÇÃO

Funcionalidade: Custo Efetivo

Data/Hora da Publicação: 16/08/2006 00:00:00

Data/Hora Última Alteração: 20/06/2011 13:09:28

Descrição da Nota: DUMPING AO CONVERTER MOEDA NO CUSTO EFETIVO

Sintoma

Melhoria nas mensagens do modo Batch Input Via Shift F9.

 

 

Solução

Inserida verificação de consistencia para verificar autorização quando

o usuario tentar ultilizar o Shift F9.

 

Versões Tratadas

6.0


Pré-Requisitos

Produto:

Nota

Descrição

FUNÇÃO DE CONVERSÃO DE VALORES EM DIFERENTES MOEDAS

Informações Complementares

----------------------------------------------------------------------------------------------------

Nota Número 01944 Data: 16/08/2006 Hora: 15:04:00

----------------------------------------------------------------------------------------------------

 

----------------------------------------------------------------------------------------------------

Nota Número              : 01944

Categoria                : Erro de Programa

Prioridade               : Alta

Versão PW.CE             : 6.0

Pacote                   : 00024

Agrupamento              : 00127

----------------------------------------------------------------------------------------------------

Referência às notas relacionadas:

Número - Ordem - Versão - Pacote - Descrição Breve

 

01400  - 00001 - 6.0    - 00023  - FUNÇÃO DE CONVERSÃO DE VALORES EM DIFERENTES MOEDAS

----------------------------------------------------------------------------------------------------

DUMPING AO CONVERTER MOEDA NO CUSTO EFETIVO

----------------------------------------------------------------------------------------------------

Palavras Chave:

DUMP - CUSTO EFETIVO - MONTANTE CONVERTE - CONVERSÃO DE MOEDA

DIVISÃO POR ZERO

----------------------------------------------------------------------------------------------------

Objetos da nota:

FUNC /PWS/ZYGL_MONTANTE_CONVERTE

 

----------------------------------------------------------------------------------------------------

Modificações efetuadas em FUNC /PWS/ZYGL_MONTANTE_CONVERTE

 

...

              exch_rate  = exch_rate

              return     = return.

      IF exch_rate-exch_rate_v IS INITIAL.

        e_defator   = exch_rate-from_factor.

        e_parafator = exch_rate-to_factor.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        if not exch_rate-exch_rate is initial.

* << Fim da inclusão

        e_txc       = 1 / exch_rate-exch_rate.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        endif.

        if not e_parafator is initial .

* << Fim da inclusão

        e_montante  = ( ( e_txc * e_defator ) / e_parafator ) *

                                                  i_montante.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        endif.

* << Fim da inclusão

        e_defator   = exch_rate-to_factor.

        e_parafator = exch_rate-from_factor.

      ELSE.

        e_defator   = exch_rate-from_factor_v.

        e_parafator = exch_rate-to_factor_v.

        e_txc       = exch_rate-exch_rate_v.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        if not e_parafator is initial.

* << Fim da inclusão

        e_montante  = ( ( e_txc * e_defator ) / e_parafator ) *

                                                  i_montante.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        endif.

* << Fim da inclusão

        e_defator   = exch_rate-to_factor_v.

        e_parafator = exch_rate-from_factor_v.

      ENDIF.

  ELSE.

    CALL FUNCTION 'BAPI_EXCHANGERATE_GETDETAIL  '

...

 

...

                return     = return.

      IF NOT exch_rate-exch_rate_v = 0.

        e_txc       = exch_rate-exch_rate_v.

        e_defator   = exch_rate-from_factor_v.

        e_parafator = exch_rate-to_factor_v.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        if not e_parafator is initial .

* << Fim da inclusão

        e_montante  = ( ( e_txc * e_defator ) / e_parafator ) *

                                                    i_montante.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        endif.

* << Fim da inclusão

        e_defator   = exch_rate-to_factor_v.

        e_parafator = exch_rate-from_factor_v.

      ELSE.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        if not exch_rate-exch_rate is initial .

* << Fim da inclusão

        e_txc       = 1 / exch_rate-exch_rate.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        endif.

* << Fim da inclusão

        e_defator   = exch_rate-to_factor.

        e_parafator = exch_rate-from_factor.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        if not e_defator is initial.

* << Fim da inclusão

      e_montante  = ( ( e_txc / e_defator ) * e_parafator ) *

                                                    i_montante.

      ENDIF.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

      ENDIF.

* << Fim da inclusão

    ELSE.

      e_txc       = exch_rate-exch_rate.

      e_defator   = exch_rate-from_factor.

      e_parafator = exch_rate-to_factor.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        if not e_defator is initial.

* << Fim da inclusão

      e_montante  = ( ( e_txc / e_defator ) * e_parafator ) * i_montante

.

* >> Início da inclusão: FUNCTION /PWS/ZYGL_MONTANTE_CONVERTE

        endif.

* << Fim da inclusão

    ENDIF.

  ENDIF.

ENDFUNCTION.