astock Posted May 12, 2020 Share Posted May 12, 2020 Is it possible to transfer the last value of a field into the field of a new page? Example: The final balance yesterday is the opening balance today. Link to comment Share on other sites More sharing options...
kongondo Posted May 12, 2020 Share Posted May 12, 2020 I am not sure what you mean by the last value of a field, so my response may not be relevant to your issue. Unless you are using some sort of version control, there is not concept of last value of field in ProcessWire. This just means that the current value of the field is the last value, so to speak. Could you expound a little bit on your context? I am guessing maybe it is something like this? Page A: Has a field share_price that changes dynamically/regularly At the end of business (or start of business next day) you create a page to store yesterdays last recorded share price Page Share Price Monday: Has field share_price_monday Etc for other days Page Share Price Tuesday: Has field share_price_tuesday Page Share Price Wednesday: Has field share_price_wednesday etc... For dynamic 'transfer' (copying of the value) you will need a hook. To trigger the hook on a non-event (for instance triggering the hook to run at the time 11:59), you will need to set up a cron job. There are modules in the forums that can do this. Link to comment Share on other sites More sharing options...
astock Posted May 12, 2020 Author Share Posted May 12, 2020 It was a bad example of mine. Strictly speaking, it is the last mileage. The last driver enters his last mileage at the end of the trip. That should be the beginning mileage for the next driver. So it could happen that several drivers have several entries on one day. Link to comment Share on other sites More sharing options...
astock Posted July 13, 2020 Author Share Posted July 13, 2020 Since my last post I have been dealing with the problem. I try to ask the question differently. Is it possible to display the last value that a user has entered in the admin template? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now