Help with Advanced PDF/HTML coding

Hi everyone.

I have an issue with the check PDF/HTML template.

So when it comes to checks, the company I work for uses this pre printed format (guess almost every company has this same type of check) which includes space for listing the accounts involved in the transaction.

Help with Advanced PDF/HTML coding

That space should basically look like what Printing GL Impact looks like.

I´ve gotten this far

Help with Advanced PDF/HTML coding

The problem is those amounts in parenthesis (negatives) should be listed on the other column as positives.

This is the code I have up to this point. I’ve been trying to somewhat copy the functionality of the GL Impact print on the corresponding NS Template. There are some other elements, but mainly spacing so that the variables used on this template land on the proper space on the pre printed check.

<!– Start of code –>

<tr><td style=”width: 550px;”>${check.account}</td>
<td style=”width: 156px; border: none”>&nbsp;</td>
<td style=”width: 149px;”>${check.total}</td>
</tr>
<#if check.expense?has_content || check.item?has_content><!– start expenses –><#list check.expense as expense>
<tr>
<td style=”width: 550px;”>${expense.account}</td>
<td style=”width: 156px; border: none”>${expense.amount}</td>
<td style=”width: 149px;”>&nbsp;</td>
</tr>
</#list></#if><!– end expenses –>
<!– start line –><#list check.line as line>
<#assign line_account = line.account><#assign line_creditamount = line.creditamount><#assign line_debitamount = line.debitamount>
<tr>
<td style=”width: 550px;”>${line_account}</td>
<td style=”width: 156px; border: none”>${line_creditamount}</td>
<td style=”width: 148px;”>${line_debitamount}</td>
</tr>
</#list>
<!– end of code –>

 

I’m not trying to converrt from positive to negative… In fact those values are negative, but are being shown on the wrong column which causes them to appear in Parenthesis.

Basically what happens is, the value (L409.64) is representing a negative value but on a debit column, instead it should show as a positive on the credit column, or so… I’m no expert in accounting, but thats my understanding.

Ex.

Account | Debit | Credit

Charge1 | (L409.64) |

Should read

Account | Debit | Credit

Charge1 | | L409.64

As a matter of fact… When I go to check the GL Impact it does place them correctly. All values as positives on the proper column.

Help with Advanced PDF/HTML coding

 

Can anyone help me check the code or give me any ideas on how to implement this GL Impact print functionality on a easier way?
Rookie Asked on April 26, 2023 in Other.
Add Comment
1 Answer(s)

You don’t look far off – what are you getting with your current code?

Advanced Answered on May 3, 2023.
Add Comment

Your Answer

By posting your answer, you agree to the privacy policy and terms of service.
  • This site made possible by our sponsors:   Tipalti   Celigo   SuiteMigration   Become a Sponsor