Commit af377b2a authored by Rafael Monnerat's avatar Rafael Monnerat

Prevent random failure using earliestTime()

If start date and stop date, just use DateTime() it can make the packing
list generated divergent by saving the form.

DateTime() includes hour, minutes and seconds, but ERP5 UI don't.
parent 3c356997
......@@ -91,8 +91,8 @@ sale_order = portal.sale_order_module.newContent(\n
source_administration=my_organisation.getRelativeUrl(),\n
delivery_mode=\'delivery_mode/air\',\n
order=\'order/normal\',\n
start_date=DateTime(),\n
stop_date=DateTime()+1,\n
start_date=DateTime().earliestTime(),\n
stop_date=DateTime().earliestTime()+1,\n
)\n
sale_order.setPriceCurrency(currency.getRelativeUrl())\n
sale_order.setIncoterm(\'incoterm/cpt\')\n
......
786
\ No newline at end of file
787
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment