Commit 664f6206 authored by Florian Azizian's avatar Florian Azizian
Browse files

FEAT #16982 TIME 0:30 (back) signature position is mandatory for sign_yousign

parent 5c7b5fab
......@@ -365,6 +365,9 @@ class DocumentController
if ($hasElectronicSignature && $workflow['signatureMode'] == 'stamp' && $workflow['mode'] == 'sign') {
return $response->withStatus(400)->withJson(['errors' => "Body workflow[{$key}] signatureMode cannot be stamp after an electronic signature", 'lang' => 'stampInTheMiddleImpossible']);
}
if ($workflow['externalInformations']['role'] == 'sign_yousign' && empty($workflow['signaturePositions'])) {
return $response->withStatus(400)->withJson(['errors' => "Body workflow[{$key}] signaturePositions must be set for sign_yousign role"]);
}
if (!empty($workflow['signaturePositions'])) {
if (!Validator::arrayType()->validate($workflow['signaturePositions'])) {
return $response->withStatus(400)->withJson(['errors' => "Body workflow[{$key}] signaturePositions is not an array"]);
......
Supports Markdown
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