Páginas filhas
  • Collection Letter - Financials - P12

Versões comparadas

Chave

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

...

Expandir
titleProcess Description

Initial Parameters: The initial parameters will allow you to filter which customers, the due date range, amount, collection status, branches, bills still to fall due, and to determine the interest and fine calculation date that will be considered for sending the collection letters. It is possible to complement the filters in a customized way; to do this, an entry point (F811QRY see details in the entry points section of this document) must be implemented to allow complementing the query that will consider the default parameters.

Layout selection: You will be presented with a list of the registered collection letter layouts so that you can select which layout will be used for sending. Only one collection letter layout can be sent at a time.

Customer Selection: A list of customers who meet the filter criteria will be presented, so that they can be selected to send the collection letter. All of them will be displayed on screen as selected.

Bill selection: The selection process of the bills that will compose the collection letter follows the criteria defined and suggested in the sending of the letters.

You can also send bills that are to be due. This means adding them as a reminder, not as a dunning. They will be suggested but can be removed from the letter if desired.

It is important to note that with the implementation of the Collection Status Block (see {+}http://tdn.totvs.com/pages/viewpage.action?pageId=381044073+), the bills in a collection status with block set up for the collection letters will not be available in this e-mail sending process. Therefore, they will not be listed for selection. To perform this blocking, a new standard process will be added to the existing ones, and it will be validated at each submission.

In addition, a title is eligible for sending letters as long as it still has an outstanding balance.

Expandir
titleExample of Use

1 - On 03/01/2015, an email was sent with the bills below for the collection, considering due dates more than 10 days late:

Bill

Due date

Days in arrears

DUP

22513

01

02/1/2015

28

DUP

22221

02

01/1/2015

59

DUP

25512

01

12/15/2014

76


2 - On 03/15/2015, the customer paid the two most overdue installments, but did not pay the installment for 02/01/2015. In this way, the unpaid bill will continue to be sent in the new collection letters, with the updated number of days in arrears.

Bill

Due date

Days in arrears

DUP

22513

01

02/1/2015

48


We emphasize that this example considers only the due date, but that the bill must respect all the filter rules.

...

Expandir
titleLayout Definition

Routine: FINA811 - Collection Letter Layout

Each letter sent will be defined according to the collection content, that is, you can include a text of certain content for different collection types.

To this end, ways of configuring the text of the letters and associating them with certain rules will be made available via registration. Only customer characteristics will be available for validation in combination with the from/to filter. If not required, it can be kept blank, so that letters can be sent to any customer.

The letters obey the filters informed in the sending routine, validating the data of the associated client, to the content of the letter. This configuration can use customized fields for its composition.

As for the listing of bills, the columns that are considered the default are below:

  • Bill key – Prefix, number, and installment
  • Due date
  • Days in arrears
  • Original Value
  • Bill balance
  • Fine
  • Interest

There will be the possibility of adding or removing new columns, as long as they are part of the bill receivable (SE1), considering that, because it is an e-mail and/or physical letter, there may be some kind of restriction on the amount of information contained in the letter/sheet.

Regardless of the shipping method selected, email, physical, or both, the letter will contain at the top the shipping data such as the customer's name and address. The address used will be the billing address contained in the customer's record. If this address is blank, the shipment will be sent to the customer's address. In the letter layout, you can set the alignment of the customer's address at the top of the letter.

  - Typing the record header where the sending method is defined, the texts (main letter, greeting and conclusion), as well as the address position (for printed letters).

 - In the footer, there are 2 tabs where you define the fields of the accounts receivable (table SE1) that will be shown in the letter (bill number, amount, due date, etc.), as well as the custom sending rules. In this field, you must enter an expression like the browse filters in Protheus. The Customers Table (SA1) is selected. 

...

  • F811MAILTO: Entry point that allows changing the variable cTo, which contains the e-mail address to which the collection letter will be sent electronically. The Entry Point receives as a parameter an array containing the following structure:

...

Array

...

[1

...

]

...

=

...

concatenated

...

string

...

of

...

A1_FILIAL

...

+

...

A1_COD

...

+

...

A1_LOJA

...

selected

...

Array

...

[2

...

]

...

=

...

Bills

...

array

...

Array

...

[2

...

]

...

[1

...

]

...

=

...

Array

...

of

...

the

...

first

...

bill

...

Array

...

[2

...

]

...

[1

...

]

...

[1

...

]

...

=

...

Process

...

Number

...

of

...

the

...

correction

...

letter

...

selected

...

in

...

the

...

Wizard

...

Array

...

[2

...

]

...

[1

...

]

...

[2

...

]

...

=

...

String

...

with

...

the

...

value

...

referring

...

to

...

the

...

FK7_IDDOC

...

field

...

Array

...

[2

...

]

...

[1

...

]

...

[3

...

]

...

=

...

String

...

of E1_

...

FILORIG

05. TECHNICAL DATA


Expandir
titleDictionaries Implemented

Dictionaries Implemented
File: FWP - Collection Letter

Table

Description

Acronym

FWP

Name

Collection Letters

Mod. Ac. Branch

Exclusive

Mod. Ac. Unit

Exclusive

Mod. Ac. Company

Exclusive

Single key

FWP_FILIAL+FWP_CODCRT

Index

Key

01

FWP_FILIAL+FWP_CODCRT

Field

FWP_FILIAL

Type

Character

Size

8

Description

System Branch

Bill

Branch

Picture

@!

Field Group

033

Field Help

System Branch

Field

FWP_CODCRT

Type

Character

Size

6

Description

Layout code

Bill

Layout Code

Picture

@!

Field Help

Set the collection letter layout code.

Field

FWP_DESCRI

Type

Character

Size

40

Description

Layout description

Bill

Description

Picture

@!

Field Help

Set the collection letter layout description. This description will be displayed in the routine for sending collection letters and in the report of outgoing collection notices.

Field

FWP_STATUS

Type

Character

Size

1

Description

Layout status

Bill

Status

Picture

@!

Validation

Belong("12")

Options List

1=Active; 2=Inactive

Field Help

Defines whether the collection letter layout is active or inactive. Only active layouts can be sent on collection.

Field

FWP_TXTSAU

Type

Character

Size

60

Description

Greeting Text

Bill

Greeting

Field Help

Greeting text to be sent in the collection letter. The greeting text represents the opening of the letter. Example: "Dear customer".

Field

FWP_TXTCRT

Type

Memo

Length

500

Description

Letter text

Bill

Letter Txt

Field Help

The text entered in this field is the text that will be sent in the body of the letter containing the content of the collection.

Field

FWP_TXTCON

Type

Memo

Length

500

Description

Conclusion text

Bill

Conclusion

Field Help

The conclusion text, if informed, will be sent at the end of the letter, as a complement to the collection made or with additional information.

Field

FWP_ENVIO

Type

Character

Size

1

Description

Submission type

Bill

Subm Tp

Picture

@!

Options List

1=E-mail;2=Physical Letter;3=Both

Validation

Belong("123")

Field Help

Collection letter submission type. Options are: E-mail - the letters will be sent to the e-mail registered in the customer registration; Physical letter - the letter will be physically sent, i.e., a printed version will be sent directly to the customer; Both - the letter will be sent in both ways.

Field

FWP_POSVER

Type

Numeric

Size

4

Description

Address' vertical pos

Bill

Vertical Pos

Picture

@E 9999

Field Help

Initial vertical position for the address in pixels. This field is only enabled when the layout's submission method is set to "Physical letter" or "Both".

Field

FWP_POSHOR

Type

Numeric

Size

4

Description

Address' Horizontal P

Bill

Horizontal P

Picture

@E 9999

Field Help

Initial horizontal position for the address in pixels. This field is only enabled when the layout's submission method is set to "Physical letter" or "Both".


File: FWQ – Submission Rules 

Table

Description

Acronym

FWQ

Name

Submission Rules

Mod. Ac. Branch

Exclusive

Mod. Ac. Unit

Exclusive

Mod. Ac. Company

Exclusive

Single key

FWQ_FILIAL+FWQ_LAYOUT

Index

Key

01

FWQ_FILIAL+FWQ_LAYOUT

Field

FWQ_FILIAL

Type

Character

Size

8

Description

System Branch

Title

Branch

Picture

@!

Field Group

033

Field Help

System Branch

Field

FWQ_LAYOUT

Type

Character

Size

6

Description

Layout code

Title

Layout Cd

Picture

@!

Field Help

Code of the Collection Letter layout

Field

FWQ_FILTRA

Type

Character

Size

254

Description

Exp for additional filters

Title

Expression

Picture

@!

Field Help

Filter expression that will be used to filter the bills that can be selected for collection in the Collection Submission routine. The expression will be built based on fields from the Bills Receivable table.


File: FWS – Bills' Data 

Table

Description

Acronym

FWS

Name

Bills' Data

Mod. Ac. Branch

Exclusive

Mod. Ac. Unit

Exclusive

Mod. Ac. Company

Exclusive

Single key

FWS_FILIAL+FWS_LAYOUT+FWS_CAMPO

Index

Key

01

FWS_FILIAL+FWS_LAYOUT+FWS_SEQ+FWS_CAMPO

Field

FWS_FILIAL

Type

Character

Size

8

Description

System branch

Title

Branch

Picture

@!

Field Group

033

Field Help

System Branch

Field

FWS_LAYOUT

Type

Character

Size

6

Description

Layout code

Title

Layout Code

Picture

@!

Field Help

Layout code

Field

FWS_SEQ

Type

Character

Size

4

Description

Fields Sequence

Title

Sequence

Picture

@!

Field Help

This field stores the writing sequence for the fields that will be displayed in the letter sent by e-mail.

Field

FWS_CAMPO

Type

Character

Size

10

Description

Bill field

Title

Field

Picture

@!

Field Help

The field that will be displayed in the body of the collection letter.

Field

FWS_DESCRI

Type

Character

Size

15

Description

Field Description

Title

Description

Field Help

Description of the field that will be presented in the collection letter. If the description is blank, the field's default description will be used.


File: FWT – Letters Sent 

Table

Description

Acronym

FWT

Name

Letters Sent

Mod. Ac. Branch

Exclusive

Mod. Ac. Unit

Exclusive

Mod. Ac. Company

Exclusive

Single key

FWT_FILIAL+FWT_LAYOUT+FWT_PROCES+FWT_CHAVE

Index

Key

01

FWT_FILIAL+FWT_LAYOUT+FWT_PROCES+FWT_CHAVE

Field

FWT_LAYOUT

Type

Character

Size

6

Description

Layout code

Title

Layout Code

Picture

@!

Field Help

Layout code

Field

FWT_DTENVI

Type

Date

Size

8

Description

Sending date

Title

Sending Dt

Field Help

Sending date of the Collection Letter

Field

FWT_CHAVE

Type

Character

Size

32

Description

Document Key

Title

Key

Picture

@!

Field Help

The key of the bill that was sent in the collection letter

Field

FWT_PROCES

Type

Character

Size

32

Description

Process Number

Title

Process

Picture

@!

Field Help

The number of the process in which the collection letter was sent.

Field

FWT_DTREFE

Type

Date

Size

8

Description

Reference Date

Title

Reference Dt.

Field Help

The reference date for correcting values


Question Group (SX1): FINR810

X1_ORDEM

01

X1_PERGUNT

Collection letter from

X1_TIPO

Character

X1_TAMANHO

6

X1_GSC

Get

X1_VAR01

MV_PAR01

X1_F3

FWP

X1_HELP

This defines the initial range for the collection letter layout.

X1_ORDEM

02

X1_PERGUNT

Collection letter to

X1_TIPO

Character

X1_TAMANHO

6

X1_GSC

Get

X1_VAR01

MV_PAR02

X1_F3

FWP

X1_HELP

This defines the final range for the collection letter layout.

X1_ORDEM

03

X1_PERGUNT

Sending date from

X1_TIPO

Date

X1_TAMANHO

8

X1_GSC

Get

X1_VAR01

MV_PAR03

X1_HELP

Define the initial date of the range of collections sent.

X1_ORDEM

04

X1_PERGUNT

Sending date to

X1_TIPO

Date

X1_TAMANHO

8

X1_GSC

Get

X1_VAR01

MV_PAR04

X1_HELP

Define the final date of the range of collections sent.

X1_ORDEM

05

X1_PERGUNT

Customer from

X1_TIPO

Character

X1_TAMANHO

6

X1_GSC

Get

X1_VAR01

MV_PAR05

X1_F3

 SA1

X1_GRPSXG

001

X1_HELP

Define the initial Customer from the range.

X1_ORDEM

06

X1_PERGUNT

Store From

X1_TIPO

Character

X1_TAMANHO

2

X1_GSC

Get

X1_VAR01

MV_PAR06

X1_GRPSXG

002

X1_HELP

Define the initial store from the range.



X1_ORDEM

07

X1_PERGUNT

Customer to

X1_TIPO

Character

X1_TAMANHO

6

X1_GSC

Get

X1_VAR01

MV_PAR07

X1_F3

 SA1

X1_GRPSXG

001

X1_HELP

Define the final Customer from the range.

X1_ORDEM

08

X1_PERGUNT

Store to

X1_TIPO

Character

X1_TAMANHO

2

X1_GSC

Get

X1_VAR01

MV_PAR08

X1_GRPSXG

002

X1_HELP

Define the final store from the range.

X1_ORDEM

09

X1_PERGUNT

Print

X1_TIPO

Character

X1_TAMANHO

1

X1_GSC

Combo

X1_VAR01

MV_PAR09

X1_DEF01

Detailed

X1_DEF02

Summarized

X1_HELP

Defines whether the report will be printed in detailed format (with the complete letter, containing the texts and other details) or in summarized format (with only the records sent on the collection and their breaks).


      Standard Query (SXB): FWP

Description

Collection Letters

Type

Standard Query

List

FWP

Index

Code

Field

Code;Description

Return

FWP_CODCRT 

Expandir
titleAutomatic Execution

For the correct execution of routine *FINA811{*}, you must enter the function parameters as below:

*nOpcAuto{*}  = This parameter is not in use at the moment, send value 0.

*a811Param{*}  = This array must receive the desired filter for selecting records and sending the collection letters. All records returned by the filter will have a collection letter generated. 

Example:

a811Param[01] := From customer code (character type)

a811Param[02] := From customer store (character type)

a811Param[03] := To customer code (character type)

a811Param[04] := To customer store (character type)

a811Param[05] := From issue date (date type) 

a811Param[06] := To issue date (date type)  

a811Param[07] := Reference date (date type)     

a811Param[08] := From value (numeric type)     

a811Param[09] := To value (numeric type)        

a811Param[10] := "2" (character type) - IMPORTANT:  ALWAYS 2 TO PREVENT DISPLAYING THE BRANCH SELECTION SCREEN

a811Param[11] := Bills due (character type, "1" = Yes or "2" = No)

a811Param[12] := Consider value (character type, "1" = Total or  "2" = Balance)

a811Param[13] :="2" (character type) - IMPORTANT: ALWAYS 2 TO PREVENT DISPLAYING THE COLLECTION STATUS SELECTION SCREEN

a811Param[14] := {} (array type) - IMPORTANT: SEND EMPTY ARRAY

a811Param[15] := "" (character type) - IMPORTANT: ALWAYS EMPTY

a811Param[16] := Letter layout code to be used (character type) 

a811Param[17] := Consider blocked customers (A1_MSBLQL) in the filter. Content "1" to consider blocked customers, or "2" to consider only active customers

...