This document explains the work order reference number.
The reference number is not meant to be a unique number generated in WMS (we use the WO# for that).
It is a field that allows the customer to ADD their own reference number if required.
So that the field is not left blank, WMS works as per below:
Work Order created Ad Hoc which is a semi-unique reference number made up of day & time (to the minute only)
The 1st 3 digits are the day of the year, and the next 4 digits are the time of day. 11/01/2018 at 7 am will read 011070
Work Order created via Sale Order which is reference number matches invoice number from Sale Order