Páginas filhas
  • Configurador EAI 2.0

Versões comparadas

Chave

  • Esta linha foi adicionada.
  • Esta linha foi removida.
  • A formatação mudou.

...

Bloco de código
languagejs
titleJSON Configuração
collapsetrue
{
	"_expandables": null,
	"integrationId": "52644D93-0D83-49D5-8D38-3B1030CA74A1",
	"name": "TOTVS Obras e Projetos x BackOffice Protheus",
	"description": "Integração TOTVS Obras e Projetos com o Back-Office PROTHEUSA gestão de obras e projetos é feita exclusivamente no TOP que libera movimentações de compra e venda para os módulos Protheus responsáveis por todo o controle de BackOffice. ",
	"documentationUrl": "http://tdn.totvs.com/display/public/integracoes/TOTVS+TOPINT/DI_MANUAL_TOTVS_TOP_BackOffice_Protheus_EAI2.0",
	"routes": {
		"items": [{
				"_expandables": null,
				"transactionsFlow": {
					"items": [{
							"transactionId": "ACCOUNTPAYABLEDOCUMENT",
							"version": "2.000",
							"direction": "send"
						}, {
				{
					"transactionId": "TASKCOSTASSIGNMENTS",
							"version": "1.000",
							"direction": "send"
						}, {
				{
					"transactionId": "ACCOUNTRECEIVABLEDOCUMENT",
							"version": "2.000",
							"direction": "send"
						}, {
				{
					"transactionId": "BALANCEBASELINEENTRY",
							"version": "1.000",
							"direction": "send"
						}, {
				{
					"transactionId": "CONTRACT",
							"version": "1.000",
							"direction": "send"
						}, {
				{
					"transactionId": "COSTCENTER",
							"version": "2.000",
							"direction": "receive"
						}, {
				{
					"transactionId": "CURRENCY",
							"version": "2.001",
							"direction": "receive"
						}, {
				{
					"transactionId": "CURRENCYQUOTATION",
							"version": "2.001",
							"direction": "receive"
						}, {
				{
					"transactionId": "CUSTOMERVENDOR",
							"version": "2.002",
							"direction": "receive"
						}, {
				{
					"transactionId": "DOCUMENTTRACEABILITYORDER",
							"version": "1.000",
							"direction": "send"
						}, {
				{
					"transactionId": "DOCUMENTTRACEABILITYREQUESTS",
							"version": "1.000",
							"direction": "send"
						}, {
				{
					"transactionId": "FINANCIALNATURE",
							"version": "2.000",
							"direction": "receive"
						}, {
				{
					"transactionId": "ITEM",
							"version": "2.001",
							"direction": "receive"
						}, {
				{
					"transactionId": "ITEMCOSTING",
							"version": "1.000",
							"direction": "receive"
						}, {
				{
					"transactionId": "ORDER",
							"version": "3.005007",
							"direction": "send"
						}, {
				{
					"transactionId": "PAYMENTCONDITION",
							"version": "2.000",
							"direction": "receive"
						},{
				{
					"transactionId": "PROJECT",
							"version": "2.000001",
							"direction": "send"
						}, {
				{
					"transactionId": "PROJECTREQUEST",
							"version": "21.001009",
							"direction": "send"
						}, {
				{
					"transactionId": "REQUESTSTEPPROJECT",
							"version": "12.009000",
							"direction": "send"
						}, {
				{
					"transactionId": "STEPPROJECTSTOCKGROUP",
							"version": "21.000",
							"direction": "sendreceive"
						}, {
				{
					"transactionId": "STOCKGROUPSTOCKTURNOVER",
							"version": "1.000001",
							"direction": "receive"
						}, {
				{
					"transactionId": "STOCKTURNOVERSUBPROJECT",
							"version": "12.001000",
							"direction": "receivesend"
						}, {
				{
					"transactionId": "SUBPROJECTTASKPROJECT",
							"version": "2.000",
							"direction": "send"
						}, {
				{
					"transactionId": "TASKPROJECTUNITOFMEASURE",
							"version": "2.000",
							"direction": "sendreceive"
						}, {
				{
					"transactionId": "UNITOFMEASUREWAREHOUSE",
							"version": "21.000",
							"direction": "receive"
						}, {
				{
					"transactionId": "WAREHOUSEORDERASSIGNMENTSINFORMATION",
							"version": "1.000",
							"direction": "receivesend"
				},
				{}
					"transactionId": "ORDERASSIGNMENTSINFORMATION",]
					"version": "1.000"},
					"direction": "send"
				}]
			},
			"applicationPair": {
					"sourceApplication": {
						"name": "RM",
						"description": "RM",
						"productCode": "RM",
						"productVersion": "12.1.17",
						"isHost": true,
						"paramEndpoints": {
							"general": {
								"metadata": "/params/1.0/metadatarm/configurator/v1/PrjConfiguraIntegracaoAPI/Metadata",
								"values": "/params/1.0/valuerm/configurator/v1/PrjConfiguraIntegracaoAPI/Values"
							},
							"transaction": {
								"metadata": "/transactionParams",
								"values": "/transactionValues"
							}
						},
					
					
					"appId": "RM@RM",
						"sourceApplication": "RM",
					
					"msgValidation": "skip",
						"portName": "EAISERVICESOAP",
						"wsdlUrl": "https://totvslabs.carol.ai:8443/api/v1/totvssm/receiveMessage?WSDL",
						"user": "totvslabs/rm/[email protected]mestre",
						"password": "Foobar1!totvs",
						"monitorUrl": ""
					},
					"destinationApplication": {
           					 "name": "PROTHEUS",
         					 "description": "PROTHEUS",
          					  "productCode": "PROTHEUS",
          					"productVersion": "12.1.17",
					"  "isHost": false,
         					   "paramEndpoints": {
        							      "general": {
			        							        "metadata": "/params/1.0PMSINTEGRATION/configurator/v1/parms/general/TOPXProtheus/metadata",
         							       "values": "/params/1.0/value"
/PMSINTEGRATION/configurator/v1/parms/general/TOPXProtheus/values"
          						    },
						             				 "transaction": {
              							  "metadata": "/transactionParams",
              							  "values": "/transactionValues"
             						 }
          					    },	
					
					
					""appId": "P12_1718@PROTHEUS",
					
					"sourceApplication": "P12_1718",
						"msgValidation": "skip",
						"portName": "EAISERVICESOAP",
						"wsdlUrl": "http://187.94.56.206:8051/EAIService/MEX?wsdl",
						"user": "mestre",
						"password": "totvs",
						"monitorUrl": ""
									}
				}
			}
		}]
	}
}

Bloco de código
languagexml
titleJSON Metadados dos Parâmetros
collapsetrue
{
	    "hasNext": false,
	    "items": [
	{
		"_expandables": null,
		        {
            "name": "param1STATUSPRJ_EMANDAMENTO",
		            "label": "Agrupar ItensIntegrar Projetos em andamento?",
		            "datatype": "combo",
		            "options": [{
			
                {
                    "value": "1.01True",
			                    "label": "Solicitação de Compra"
		},
		{
			Sim"
                },
                {
                    "value": "1.02",
			"label": "Pedido de Compra"
		},
		{
			"value": "1.03",
			"label": "Ordem de Compra"
		}]
	},
	{
		"name": "param2",
		"label": "Mascara do Fornecedor",
		"datatype": "text"
	},
	{
		"name": "param3",
		"label": "Tipo de Documento",
		"datatype": "NUMBER"
	},
	{
		"name": "param4",
		"label": "Observações",
		"datatype": "textarea"
	},
	{
		"name": "param5",
		"label": "Data de Início contábil",
		"datatype": "date"
	}]
}
Bloco de código
languagexml
titleJSON Values dos Parâmetros
collapsetrue
{
	"hasNext": false,
	"items": [{
		"name": "param1",
		"value": "1.01"
	},
	{
		"name": "param2",
		"value": "####"
	},
	{
		"name": "param3",
		"value": 30.5
	},
	{
		"name": "param4",
		"value": ""
	},
	{
		"name": "param5",
		"value": "2017-09-01T00:00:00"
	}]
}

Parâmetros de Adapters

False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "STATUSPRJ_PARALISADO",
            "label": "Integrar Projetos paralizados?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "STATUSPRJ_CONCLUIDO",
            "label": "Integrar Projetos concluídos?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "STATUSPRJ_AEXECUTAR",
            "label": "Integrar Projetos a executar?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "STATUSPRJ_EMNEGOCIACAO",
            "label": "Integrar Projetos em negociação?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "STATUSPRJ_REVISADO",
            "label": "Integrar Projetos revisados?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "STATUSPRJ_CANCELADO",
            "label": "Integrar Projetos cancelados?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "PRJ_EXPORTAVALORTRF",
            "label": "Exportar valor da tarefa?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "PRJ_AGLUTINAITENSSC",
            "label": "Aglutinar itens de SC?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "PRJ_AGLUTINAITENSSA",
            "label": "Aglutinar itens de SA?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "PRJ_AGLUTINAITENSPEDIDO",
            "label": "Aglutinar itens de Pedidos?",
            "datatype": "combo",
            "options": [
                {
                    "value": "True",
                    "label": "Sim"
                },
                {
                    "value": "False",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "PRODUTOPADRAO",
            "label": "Produto Padrão",
            "datatype": "text",
            "options": null
        },
        {
            "name": "MOEDAPADRAO",
            "label": "Moeda Padrão",
            "datatype": "text",
            "options": null
        },
        {
            "name": "CONSWSAPROPRIACAOPROTHEUS",
            "label": "Utilizar novo modelo de Apropriações de Custo?",
            "datatype": "combo",
            "options": [
                {
                    "value": "1",
                    "label": "Sim"
                },
                {
                    "value": "0",
                    "label": "Não"
                }
            ]
        },
        {
            "name": "PRJ_URLAPIRESTPROTHEUS",
            "label": "URL da API de Apropriação Protheus",
            "datatype": "text",
            "options": null
        },
        {
            "name": "PRJ_USRAPIRESTPROTHEUS",
            "label": "Usuário de autenticação Protheus",
            "datatype": "text",
            "options": null
        },
        {
            "name": "PRJ_PASSAPIRESTPROTHEUS",
            "label": "Senha de autenticação Protheus",
            "datatype": "text",
            "options": null
        }
    ]
}
Bloco de código
languagexml
titleJSON Values dos Parâmetros
collapsetrue
{
    "hasNext": false,
    "items": [
        {
            "name": "STATUSPRJ_EMANDAMENTO",
            "value": "True"
        },
        {
            "name": "STATUSPRJ_PARALISADO",
            "value": "True"
        },
        {
            "name": "STATUSPRJ_CONCLUIDO",
            "value": "False"
        },
        {
            "name": "STATUSPRJ_AEXECUTAR",
            "value": "True"
        },
        {
            "name": "STATUSPRJ_EMNEGOCIACAO",
            "value": "True"
        },
        {
            "name": "STATUSPRJ_REVISADO",
            "value": "True"
        },
        {
            "name": "STATUSPRJ_CANCELADO",
            "value": "True"
        },
        {
            "name": "PRJ_EXPORTAVALORTRF",
            "value": "False"
        },
        {
            "name": "PRJ_AGLUTINAITENSSC",
            "value": "True"
        },
        {
            "name": "PRJ_AGLUTINAITENSSA",
            "value": "True"
        },
        {
            "name": "PRJ_AGLUTINAITENSPEDIDO",
            "value": "True"
        },
        {
            "name": "PRODUTOPADRAO",
            "value": ""
        },
        {
            "name": "MOEDAPADRAO",
            "value": ""
        },
        {
            "name": "CONSWSAPROPRIACAOPROTHEUS",
            "value": "0"
        },
        {
            "name": "PRJ_URLAPIRESTPROTHEUS",
            "value": "HTTP://[Server]:[Port]"
        },
        {
            "name": "PRJ_USRAPIRESTPROTHEUS",
            "value": "mestre"
        },
        {
            "name": "PRJ_PASSAPIRESTPROTHEUS",
            "value": "totvs"
        }
    ]
}


Parâmetros de Adapters

  • Mascara de produto - parametro de estoque
  • Máscara de cliente fornecedor  - parâmetro de financeiro
  • Status de projeto  - parâmetro de gestão de projetos
  • MASCARA DE PRODUTO - PARAMETRO DE ESTOQUE
  • MASCARA DE CLIENTE FORNECEDOR  - PARAMETRO DE FINANCEIRO
  • STATUS DE PROJETO  - PARAMETRO DE GESTÃO DE PROJETOS

Questões a analisar

  • Hoje o configurador so permite selecionar um pacote por vez, mesmo o cliente necessitando fazer a configuração de múltiplos.
  • Como os desenvolvedores saberiam os adapters existentes ou pacotes , sem um fonte centralizador? Página no tdnsem um fonte centralizador? Página no tdn?
    • As informações presentes no JSon não deveriam ser adicionados em uma base de dados que permita consulta e transformados em JSon somente no momento da consulta?
  • Como os desenvolvedores farão para montar um ambiente de simulação, onde eles testem os seus JSons?
    • Devemos disponibilizar um Mock para usarem?
  • No JASON de metadados teremos a tag para bloquear a edição?
  • JSON de configuração ficara no repositorio totvsmsg? se sim nem todos tem acesso. Se sim, em qual pasta?
  • Versão da mensagem configurada conforme a versão dos produtos.
  • Como configurar um parâmetro RM com base em uma configuração do Protheus?
    • Ex.: Para saber se devemos configurar o Produto como global devemos consultar no Protheus qual o compartilhamento do mesmo.
      • Para viabilizar este comportamento é necessário já possuir o caminho do URL do sistema de destino, talvez pre-configurando o par de Apps antes da configuração do pacote.
  • Como será informado para as APIs de transaction qual o tipo de pacote (sou backoffice ou vertical?) e a versão do produto e da mensagem que será aplicada??
    • Isso será informado na URL? Esta solução não tem boa manutenção, tendo que alterar todos os JSons caso precise ser passado novo parametro e deverá passar queryparams no método POST.

Pontos Legados (Vamos descontinuar?):Processos Especificos da Integração do TOP

1 - Configurador do TOP deletava triggers Stored;

...

Parâmetros Integração do TOP

AplicaçãoTabelaParâmetroTipoValor DefalutClassificaçãoCondiçãoObservação
Integração Cli/ForHCPARAMETROCLIFORAUTOINCBooleanFalseIntegração
   



HCPARAMETROSIZECODCFOInt
 

Integração
  


Integração Centro CustosHCPARAMETROCENTROCUSTOAUTOINCBooleanFalseIntegração
  


Integração Loca EstoqueHCPARAMETROMASCARACODLOCString
 

Integração
 
 


Integração Cotação MoedasHCPARAMETROSMOEDAPADRAOString
 

Integração
 

Utilizado no
rececimento
recebimento da Cotação de Moedas como moeda de referência
Integração ProjetosHCPARAMETROSSTATUSPRJ_EMANDAMENTOBooleanTrue
Integração 
Adapter
 
Envia
  


HCPARAMETROSSTATUSPRJ_PARALISADOBooleanTrue
Integração  
Adapter


 
HCPARAMETROSSTATUSPRJ_AEXECUTARBooleanTrue
Integração  
Adapter


HCPARAMETROSSTATUSPRJ_EMNEGOCIACAOBooleanTrue
Integração  
Adapter
  



HCPARAMETROSSTATUSPRJ_REVISADOBooleanTrue
Integração  
Adapter


 
HCPARAMETROSSTATUSPRJ_CANCELADOBooleanTrue
Integração 
Adapter

Integração TarefasHCPARAMETROSPRJ_EXPORTAVALORTRFBooleanFalse
Integração
Adapter
 
Envia
 

Integração SolicitaçõesHCPARAMETROSPRJ_AGLUTINAITENSSCBooleanTrueIntegração
    



HCPARAMETROSPRJ_AGLUTINAITENSPEDIDOBooleanTrueIntegração
  



HCPARAMETROSPRJ_AGLUTINAITENSSABooleanTrueIntegração
  


Cliente / FornecedorFPARAM1001String##;L######Adapter
 
Recebe
  


FPARAMString##########Adapter
 

Se  CLIFORAUTOINC = True e SIZECODCFO não definido ou 0(zero)
 

FPARAMStringReplica('#', SIZECODCFO)Adapter
 

Se  CLIFORAUTOINC = True e SIZECODCFO maior que 0(zero)
 

FPARAM1030Int0Adapter
 
RecebeSe  CLIFORAUTOINC = True adiciona 1
Centro de CustosGCCUPARMASCARACCString
 

Adapter
 
RecebeSe CENTROCUSTOAUTOINC = False adiciona a máscara em branco.
 

GCCUPARString#######Adapter
 

Se CENTROCUSTOAUTOINC = True
 

GCCUPARLOOKUPTODOSBooleanFAdapter
  
 



FPARAM1050Int3Adapter
 

Rateio
 

FPARAM67Int0Adapter
 

Informar Conta/Caixa na Inclusão
 

FPARAM83Int0Adapter
 

Default Contábil do Lançamento
Local de Estoque TPARMASCLOCALStringQQQQQQQAdapter
 
RecebeAjusta se houver valor informar em MASCARACODLOC
Solicitações e PedidosMPARAMETROAGRUPARITENSMOVIMENTOPORPRODUTOInt0Adapter
 
EnviaEste parâmetro
tambem
é marcado o valor string com 1
 

MPARAMETROINTEGRADONUCLEUSInt1Adapter
 

Este parâmetro
tambem
é marcado o valor string com 1
 

MPARAMETROUTILIZARATEIOCCInt1Adapter
 

Utiliza movimento de cotação
 

MPARAMETROUSATIPOMOVNUCLEUSCOTACAOInt0Adapter
 

Utiliza movimento de histórico
 

MPARAMETROUSANUCLEUSTIPOMOVHISTORICOInt1Adapter
 

Utiliza movimento de solicitação de compras
 

MPARAMETROUSANUCLEUSTIPOMOVCOMPRA2Int1Adapter
 

Descrição do parâmetro
 

MPARAMETRONOMENUCLEUSTIPOMOVREQStringSolicitação de ArmazémAdapter
 

Descrição do parâmetro
 

MPARAMETRONOMENUCLEUSTIPOMOVCOMPRA2StringSolicitação de CompraAdapter
 

Desativa o rateiro de tarefas na geração de todos os pedidos
 

MPARAMETROAGRUPARITENSMOVIMENTOPORPRODUTOInt1Adapter
 

Desativa solicitação de compras em todos os projetos
 

MPARAMETRONAOUSANUCLEUSTIPOMOVCOMPRAInt0Adapter
 

Tipo de movimento para solicitação de armazém
 

MPARAMETROTIPOMOVESTOQUEString1.1.01Adapter
 

Código do movimento de solicitação de compras
 

MPARAMETRONUCLEUSTIPOMOVREQString1.1.01Adapter
 

Código do Movimento de histórico de solicitação de compras
 

MPARAMETRONUCLEUSTIPOMOVHISTORICOString1.1.02Adapter
 

Movimento de solicitação de compra
 

MPARAMETRONUCLEUSTIPOMOVCOMPRA2String1.1.03Adapter
 

Código do movimento de solicitação de cotação
 

MPARAMETROTIPOMOVNUCLEUSCOTACAOString1.1.04Adapter
 

Código do movimento de adiantamentos a pagar
 

MPARAMETRONUCLEUSTIPOMOVADIAString1.2.02Adapter
 

Tipo de movimento para título a receber
 

MPARAMETRONUCLEUSTIPOMOVADIACNTRECString2.2.03Adapter
 

Inibe o envio de obra e etapas no pedido extra
 

MPARAMETROEXIBEETAPAPEDIDOEXTRAInt0Adapter
 
 


FinanceiroMPARAMETROFLUXUSTIPODOCLINHABASEStringPRAdapter
 
EnviaTipo de documento de lançamentos de linha base
 

MPARAMETROFLUXUSTIPODOCLINHABASEEDITAVELInt0Adapter
 

Tipo de documento de linha base não pode ser editado
 

MPARAMETROFLUXUSTIPODOCSALDOStringPRAdapter
 

Tipo de documento de saldo
 

MPARAMETROFLUXUSTIPODOCSALDOEDITAVELInt0Adapter
 

Tipo de documento de saldo não pode ser editado