Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cutReceipt ignored by iOS - Ionic 3 - TSP100ECO #42

Open
NicolaasZA opened this issue Dec 10, 2019 · 1 comment
Open

cutReceipt ignored by iOS - Ionic 3 - TSP100ECO #42

NicolaasZA opened this issue Dec 10, 2019 · 1 comment

Comments

@NicolaasZA
Copy link

Greetings,

When trying to print receipts using printRasterReceipt, I found that iOS ignores cutReceipt: false, cutting each time.

Looking into StarPRINT.m, I found this line in several functions making use of the RasterObj and the cutReceipt field:
BOOL cutReceipt = ([printObj valueForKey:@"cutReceipt"]) ? YES : NO;

To fix the issue, I modified them:
BOOL cutReceipt = ([[printObj objectForKey:@"cutReceipt"]boolValue]) ? YES : NO;

This changes the way the data sent to the native side is cast and compared.

Does anyone else have this issue?

@petermeester
Copy link

petermeester commented Jan 2, 2022

Hi @NicolaasZA,

I had the same issue. Your fix works for me. Thnx! I've created a pull request to implement your solution in the next release. Hopefully the owner of this repo is still moderating.

Regards,
Peter

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants