-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCodeunit_0000000244.txt
84 lines (75 loc) · 2.96 KB
/
Codeunit_0000000244.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
OBJECT Codeunit 244 Item Jnl.-B.Post+Print
{
OBJECT-PROPERTIES
{
Date=09/07/12;
Time=12:00:00 PM;
Version List=NAVW17.00;
}
PROPERTIES
{
TableNo=233;
OnRun=BEGIN
ItemJnlBatch.COPY(Rec);
Code;
Rec := ItemJnlBatch;
END;
}
CODE
{
VAR
Text000@1000 : TextConst 'ENU=Do you want to post the journals and print the posting report?;ESM=¨Confirma que desea registrar los diarios e imprimir el informe de registro?;FRC=D‚sirez-vous reporter le journal et imprimer le rapport?;ENC=Do you want to post the journals and print the posting report?';
Text001@1001 : TextConst 'ENU=The journals were successfully posted.;ESM=Se han registrado correctamente los diarios.;FRC=Le journal a ‚t‚ report‚ avec succŠs.;ENC=The journals were successfully posted.';
Text002@1002 : TextConst 'ENU="It was not possible to post all of the journals. ";ESM="No ha sido posible registrar todos los diarios. ";FRC="Il a ‚t‚ impossible de reporter tous les journaux. ";ENC="It was not possible to post all of the journals. "';
Text003@1003 : TextConst 'ENU=The journals that were not successfully posted are now marked.;ESM=Los diarios que no se han registrado est n marcados.;FRC=Les journaux qui n''ont pas ‚t‚ report‚s sont maintenant indiqu‚s.;ENC=The journals that were not successfully posted are now marked.';
ItemJnlTemplate@1004 : Record 82;
ItemJnlBatch@1005 : Record 233;
ItemJnlLine@1006 : Record 83;
ItemReg@1007 : Record 46;
WhseReg@1010 : Record 7313;
ItemJnlPostBatch@1008 : Codeunit 23;
JnlWithErrors@1009 : Boolean;
LOCAL PROCEDURE Code@1();
BEGIN
WITH ItemJnlBatch DO BEGIN
ItemJnlTemplate.GET("Journal Template Name");
ItemJnlTemplate.TESTFIELD("Posting Report ID");
IF NOT CONFIRM(Text000,FALSE) THEN
EXIT;
FIND('-');
REPEAT
ItemJnlLine."Journal Template Name" := "Journal Template Name";
ItemJnlLine."Journal Batch Name" := Name;
ItemJnlLine."Line No." := 1;
CLEAR(ItemJnlPostBatch);
IF ItemJnlPostBatch.RUN(ItemJnlLine) THEN BEGIN
MARK(FALSE);
IF ItemReg.GET(ItemJnlPostBatch.GetItemRegNo) THEN BEGIN
ItemReg.SETRECFILTER;
REPORT.RUN(ItemJnlTemplate."Posting Report ID",FALSE,FALSE,ItemReg);
END;
IF WhseReg.GET(ItemJnlPostBatch.GetWhseRegNo) THEN BEGIN
WhseReg.SETRECFILTER;
REPORT.RUN(ItemJnlTemplate."Whse. Register Report ID",FALSE,FALSE,WhseReg);
END;
END ELSE BEGIN
MARK(TRUE);
JnlWithErrors := TRUE;
END;
UNTIL NEXT = 0;
IF NOT JnlWithErrors THEN
MESSAGE(Text001)
ELSE
MESSAGE(
Text002 +
Text003);
IF NOT FIND('=><') THEN BEGIN
RESET;
Name := '';
END;
END;
END;
BEGIN
END.
}
}