Manufacturing order (Version 1)
Endpoints
Create / update MO
/mes/companies/{companycode}/establishments/{establishmentcode}/mos |
Parameters
Type | Name | Description | Schema | Associated rules |
---|---|---|---|---|
Path |
companyCode |
Current context company code |
string |
|
Path |
establishmentCode |
Current context establishment code |
string |
|
Body |
body |
Manufacturing order |
Get one MO
/mes/companies/{companycode}/establishments/{establishmentcode}/mos/{code} |
Parameters
Type | Name | Description | Schema | Associated rules |
---|---|---|---|---|
Path |
companyCode |
Current context company code |
string |
|
Path |
establishmentCode |
Current context establishment code |
string |
|
Path |
code |
Mo code to retrieve |
string |
Delete MO
/mes/companies/{companycode}/establishments/{establishmentcode}/mos/{code} |
Parameters
Type | Name | Description | Schema | Associated rules |
---|---|---|---|---|
Path |
companyCode |
Current context company code |
string |
|
Path |
establishmentCode |
Current context establishment code |
string |
|
Path |
code |
Entity public uuid code to delete |
string |
Data structure
MO
Description of a manufacturing order (MO).
Name | Description | Value | Associated rules |
---|---|---|---|
companyCode |
Current company code |
string |
|
establishmentCode |
Current establishment code |
string |
|
moNb |
string |
||
lineCode |
Line code |
string |
|
lineConfigurationCode |
Line configuration code |
string |
|
itemCode |
Item code |
string |
|
batchCode |
string |
||
quantity |
Quantity |
double |
|
unitCode |
Unit code |
string |
|
plannedBeginDateTime |
datetime (ISO-8601) |
||
plannedEndDateTime |
datetime (ISO-8601) |
||
descriptionComment |
string |
||
moHeaderCriterionValues |
|||
seqNumberInDay |
integer |
||
state |
string (AWAITING, IN_PROGRESS, FINISHED, SUSPENDED) |
||
childMos |
< integer > list |
||
realBeginDate |
datetime (ISO-8601) |
||
realEndDate |
datetime (ISO-8601) |
||
quantityDone |
double |
||
quantityFinal |
double |
MoHeaderCriterionValue
Name | Value | Associated rules |
---|---|---|
criterionCode |
string |
|
dataEntryMode |
string (UNI, BOR, LIS) |
|
minValue |
string |
|
maxValue |
string |
Rules
R1
moNb should contain 12 characters or less.
Those characters can be letters or numbers.
If a manufactoring order (MO) exists for companyCode, establishmentCode and moNb as external id, this MO will be updated.
Otherwise a new MO is created.
If moNb is not set, a new MO is created without external id. This MO will not be updated or deleted using webservices.
If MO already exists and has already been started, it cannot be updated.
If MO has been splitted (MO scheduling feature), it cannot be updated.
R2
lineCode should refer to a resource that exists for these companyCode and establishmentCode.
This resource should be a production line.
R3
If lineConfigurationCode is set, it should be be configuration of lineCode.
If lineConfigurationCode is not set, there should be a configuration of lineCode that can produce itemCode.
R5
batchCode is optional; if it is set, and if there is no batch with this code, the batch is created.
R7
unitCode should exist and should be lineCode cadency unit or there should be a conversion between unitCode and lineCode cadency unit.
R8
Either plannedBeginDateTime or plannedEndDateTime should be set.
If both plannedBeginDateTime and plannedEndDateTime are set, begin date should be before end date.
R9
If criterionCode in moHeaderCriterionValues does not exist, values for this criterion are ignored.
R15
state can have the following values :
-
AWAITING : MO is ready to be started
-
IN_PROGRESS : MO is in progress
-
SUSPENDED : MO is suspended
-
FINISHED : MO is finished
R16
childMos is set when the MO ha been splitted in the MES MO scheduling. In that case, childMos has the list of "children mos" number, the ones created from the split.
R19
If criterionCode in moHeaderCriterionValues exists and criterion type is string, minValue in moHeaderCriterionValues should be a string without forbidden special caracter and should match existing values.
R20
If criterionCode in moHeaderCriterionValues exists and criterion type is date, minValue in moHeaderCriterionValues should be a date with format 'YYYY-MM-DD'.
R21
If criterionCode in moHeaderCriterionValues exists and criterion type is numeric, minValue in moHeaderCriterionValues should be a number (positive or negative).