Page 1 of 1
Extra variables for templates 27/09/2021 at 14:47 #141700 | |
KymriskaDraken
![]() 963 posts |
I've been working with Pascal to update some of the timetables to use information from the Misc tab rather than tuyping everything manually into the Train Description field. However, a lot of the train information has to be entered in the 'wrong' box as the 'right' one doesn't exist. For instance we have to put the days that the train runs, operator, and name (if it has one). If we could have a couple of extra variables it would be helpful. Perhaps those boxes could be labelled User Defined 1, 2 and 3, and the variable name for the description field would be something like $userDefined 1, $userDefined 2, and $userDefined3. Kev Log in to reply |
Extra variables for templates 28/09/2021 at 15:24 #141711 | |
Dionysusnu
![]() 576 posts ![]() |
Operator is already a field. Running days could be a dedicated field if we ever got DOTW integration in timetables. User defined fields would definitely be nice too. A related issue is that there's no good way to do optional fields. If I want to leave out the operator, for example because I don't know it on a freight train, then I'll end up with an awkward whitespace in the description. My solution is to make the operator field "GWR ", but that's not great. I'm also not sure if there's a good easy solution for this though. Example: "$destName ($operator $stock)" If I leave out the operator, I'll get "Westbury ( 158)" which looks awkward. Solution: "$destName ($operator$stock)" So I enter "GWR " as the operator. But then if I forget the trailing space there, I'll get "Westbury (GWR158)" which is also awkward. Last edited: 28/09/2021 at 15:28 by Dionysusnu Reason: None given Log in to reply |
Extra variables for templates 28/09/2021 at 16:26 #141712 | |
Steamer
![]() 3958 posts ![]() |
Mantis 34753 raised as a feature request for additional fields in the Misc tab.
"Don't stress/ relax/ let life roll off your backs./ Except for death and paying taxes/ everything in life.../ is only for now." (Avenue Q) Log in to reply |