@randstad-uca/aws-sns-publisher 1.0.20 → 1.0.22

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -38,3 +38,12 @@ export declare const validEventTypes: {
38
38
  mail: string;
39
39
  push: string;
40
40
  };
41
+ export declare const validDocumentStatus: {
42
+ enviado: string;
43
+ rechazado: string;
44
+ firmado: string;
45
+ anulado: string;
46
+ pendienteEnvio: string;
47
+ incompleto: string;
48
+ pendienteFirma: string;
49
+ };
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.validEventTypes = exports.validApiNames = void 0;
3
+ exports.validDocumentStatus = exports.validEventTypes = exports.validApiNames = void 0;
4
4
  /**
5
5
  * Valid API names
6
6
  */
@@ -41,3 +41,12 @@ exports.validEventTypes = {
41
41
  mail: 'mail',
42
42
  push: 'push',
43
43
  };
44
+ exports.validDocumentStatus = {
45
+ enviado: 'enviado',
46
+ rechazado: 'rechazado',
47
+ firmado: 'firmado',
48
+ anulado: 'anulado',
49
+ pendienteEnvio: 'pendiente envio',
50
+ incompleto: 'incompleto',
51
+ pendienteFirma: 'pendiente firma'
52
+ };
@@ -5,10 +5,12 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.SetDocumentStatusSchema = void 0;
7
7
  const joi_1 = __importDefault(require("joi"));
8
+ const constants_1 = require("../constants");
9
+ const statusValues = Object.values(constants_1.validDocumentStatus);
8
10
  exports.SetDocumentStatusSchema = joi_1.default.object({
9
11
  CanCod: joi_1.default.number().integer().required(),
10
12
  estado: joi_1.default.string()
11
- .valid('enviado', 'rechazado', 'firmado', 'anulado', 'pendiente envio', 'incompleto', 'pendiente firma')
13
+ .valid(...statusValues)
12
14
  .required(),
13
15
  })
14
16
  .unknown(false)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@randstad-uca/aws-sns-publisher",
3
- "version": "1.0.20",
3
+ "version": "1.0.22",
4
4
  "description": "AWS SNS Publisher",
5
5
  "main": "./build/index.js",
6
6
  "types": "./build/index.d.ts",