PPRuNe Forums

PPRuNe Forums (https://www.pprune.org/)
-   Terms and Endearment (https://www.pprune.org/terms-endearment-38/)
-   -   Roster Pattern Generator (https://www.pprune.org/terms-endearment/656353-roster-pattern-generator.html)

Superpilot 14th Dec 2023 14:17

Roster Pattern Generator
 
RosterPatternGenerator

For those that have a fixed roster pattern and need to know in advance what your working days and off days are going to be, you may find this useful.
It's written in PowerShell. You don't need a Windows machine to run it, you can run online by clicking the above link (though if run locally the output is more pretty).

You can specify two different patterns (one for summer, one for winter). You can also choose the Winter and Summer months. Be sure to change the start date here first:

https://cimg8.ibsrv.net/gimg/pprune....e9f370a335.png

Tio.run output
https://cimg5.ibsrv.net/gimg/pprune....78e429d8e6.png

Script running on PC output:
https://cimg3.ibsrv.net/gimg/pprune....858a3c554a.png

TheBat 15th Dec 2023 16:16

Thanks very much for that. Runs nicely on a local PC.
I see that you have modified the code slightly since the initial release and now is more clear of what and how we can modify the variables.
I initially changed the pattern according to mine, then since it does not change between summer and winter, with my very limited knowledge I had a hard time removing the IF function. Finally ended up in modifying the winter and summer months both to 0, and the trick was done!
Forgive my ignorance, but can this be "converted" to some other code with a basic UI, or is there a way to use it via a browser for example, so it can be used on a mobile phone or other device and without internet?

Superpilot 16th Dec 2023 10:34

You can run this via a mobile web browser (Just click the Play inside circle icon) and copy and paste the results to wherever you need them but Internet needed of course. Offline usage on mobiles would require writing an app unfortunately. Keen to know the need for an offline version though. My use case was simple: Run it, generate the data, save it somewhere to refer to, and that's it for the year.

Admittedly data output can be improved as the current list version might not suit. I can have a go at changing the look if you're interested?

whiskydrinker 16th Dec 2023 11:57

Or you can just use Google calendar 🤷‍♂️


All times are GMT. The time now is 10:06.


Copyright © 2024 MH Sub I, LLC dba Internet Brands. All rights reserved. Use of this site indicates your consent to the Terms of Use.