Sign: Dollar $

General support regarding TimeTrex, such as
configuring policies/taxes or processing payroll.
Post Reply
reloded
Posts: 52
Joined: Mon Aug 13, 2007 10:24 pm

Sign: Dollar $

Post by reloded »

Hi.
How do I get rid of the $ sign in my reports? This is under Net Pay at the bottom of the payslip.
I am so praying its not a locale configuration thing coz I've had my share of problems with them.
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Post by shaunw »

Are you looking to get rid of it, or change it to your locale currency sign?

Currently TimeTrex doesn't support other signs at this time, it is coming soon though.
reloded
Posts: 52
Joined: Mon Aug 13, 2007 10:24 pm

Post by reloded »

Okay. Am waiting for that. In the mean time, can I rid the dollar sign since Timetrex writes the name of the currency i.e. After net pay. E.g. 2000 KES
So thats why I don't need the dollar sign.
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Post by shaunw »

Are you referring to the dollar sign on the pay stubs?
reloded
Posts: 52
Joined: Mon Aug 13, 2007 10:24 pm

Post by reloded »

Yes, the ones on the pay stubs
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Post by shaunw »

Edit this file:

classes/modules/pay_stub/PayStubFactory.class.php

search for: '$
(single quote, dollar sign)

It should be in there about 3 times, you can try replacing it with the sign of your choice.
reloded
Posts: 52
Joined: Mon Aug 13, 2007 10:24 pm

Post by reloded »

Hi.
I edited that file and found only TWO occurrences of '$ .
I deleted them and put another symbol but the dollar sign is still appearing on the pay stubs. I put the = sign and even the British POUND sign but still the $ sign kept showing.
I deleted the symbol completely and left only a space (blank). But still $ sign is displaying.
shaunw
Posts: 7839
Joined: Tue Sep 19, 2006 2:22 pm

Post by shaunw »

Okay, try this then, edit:

classes/modules/core/TTi18n.class.php

Near the bottom around line 650-680 you will see:

Code: Select all

return $currency_code_left_str . self::getLocaleHandler()->formatCurrency( $amount, I18Nv2_CURRENCY_LOCAL ) . $currency_code_right_str;
Change to:

Code: Select all

return $currency_code_left_str . self::getLocaleHandler()->formatCurrency( $amount, I18Nv2_CURRENCY_LOCAL, '<currency symbol here>' ) . $currency_code_right_str;
That should work better for you.
reloded
Posts: 52
Joined: Mon Aug 13, 2007 10:24 pm

Post by reloded »

Worked! :D
Thanks Shauwn. You the coolest dude ever! 8)
Post Reply