[IMPLEMENTED] Auto increment in numbers

Hello

we would like it if the numbers gave the possibility to set an auto increment. We have now had the problem a couple of times that we had to create this through the code.

Greetings
Andreas

I am not sure if I will create something for fields directly, but perhaps a counter functionality for scripts.

Hi,

I added a script counter (per app)

usage

ctx.data.number.iv = incrementCounter('abc2');

replace();

Will be deployed soon

1 Like

Hello

that’s cool :slight_smile:
Works flawlessly. Thanks for your work.

And sorry for the long reaction time … Corona sends its regards.

Greetings Andreas

1 Like

I get the following error:
Failed to execute script with javascript error: Object has no method ‘incrementCounter’.

* Object has no method 'incrementCounter'.

Can you pinpoint me to what am I doing wrong?

Which version are you using?

Thanks for the fast response.
Cloud

Okay, I will check if it deployed. I am not sure to be honest. Usually I update the feature requests after deployments. Can you also post your script?

Sure it’s pretty straight forward:

ctx.data.barcodeSuffix.iv = incrementCounter('tru-dev');
replace();
1 Like

@Sebastian
Any update on this? Do you need any further info?

Sorry, not…I think it is just not deployed yet, but I will check it again today and then deploy it.

Hi, I have deployed it.