If you want to edit a node, and use publish_on date, fields are empty even if you choosed a date previously.
So I made a patch to fix it
FYI, an issue is open for Drupal 6 : http://drupal.org/node/1159880
As far as I can tell, the values aren't even getting into the db. Am I crazy?
Actually, it looks to me like the 'time' field is required in order for the publishing info to get inserted. I undid your patch and everything worked.
In #1 you referred to #1159880: Scheduler fields are empty on node edit form. I do not understand your original problem but are you saying that 1159880 is the same thing?
The value is range in the table scheduler. The module works like that, but if you edit an existing node, the "publish_on date" is empty even if you define one.
With this patch, the field is filled if a value exists in the database for the node selected.
Is this still a problem? I still do not understand the scenario which you tried to describe above, sorry.
However, I can see in your patch that for nid you want to use $form['nid']['#value'] instead of $form['#node']->nid (ie. $node->nid). So are you saying that in your case $form['#node'] is not set but $form['nid']['#value'] is ok?
Does this happen when creating a new node or editing an existing one? Are you generating the nodes via some other import method?
Until we understand the problem and can replicate it, we cannot proceed to review the patch, hence changing the status.
Closing this issue. No response from the original poster for 5 months.
The fields in the scheduler db are displayed in the node edit form. If you still have a problem, please re-open and acurately describe the steps needed to reproduce this error, using a clean drupal7 install with a minimal number of others modules.
Drupal is a registered trademark of Dries Buytaert.