law-common 10.72.22 → 10.72.23
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.
- package/dist/src/api/interface/billing.create.dto.interface.js +3 -3
- package/dist/src/entities/enums/file-format.enum.js +4 -4
- package/dist/src/enums/index.d.ts +1 -0
- package/dist/src/enums/index.js +1 -0
- package/dist/src/exceptions/impl/app-badrequest.exception.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.billingDocumentFileUploadConfig = void 0;
|
|
4
|
-
const
|
|
4
|
+
const file_format_enum_1 = require("../../entities/enums/file-format.enum");
|
|
5
5
|
exports.billingDocumentFileUploadConfig = [
|
|
6
6
|
{
|
|
7
7
|
name: "invoiceDocument",
|
|
8
|
-
size:
|
|
8
|
+
size: file_format_enum_1.fileFormatConfig[file_format_enum_1.FileFormatEnum.PDF].defaultSize,
|
|
9
9
|
count: 1,
|
|
10
10
|
isRequired: true,
|
|
11
|
-
format: [...
|
|
11
|
+
format: [...file_format_enum_1.fileFormatConfig[file_format_enum_1.FileFormatEnum.PDF].mimeTypes, ...file_format_enum_1.fileFormatConfig[file_format_enum_1.FileFormatEnum.JPEG].mimeTypes],
|
|
12
12
|
},
|
|
13
13
|
];
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.fileFormatConfig = exports.FileFormatEnum = void 0;
|
|
4
|
-
const
|
|
5
|
-
const
|
|
4
|
+
const enums_1 = require("../../enums");
|
|
5
|
+
const exceptions_1 = require("../../exceptions");
|
|
6
6
|
var FileFormatEnum;
|
|
7
7
|
(function (FileFormatEnum) {
|
|
8
8
|
FileFormatEnum["PDF"] = "application/pdf";
|
|
@@ -57,8 +57,8 @@ exports.fileFormatConfig = {
|
|
|
57
57
|
function defaultSize(format) {
|
|
58
58
|
const size = FileFormatEnum.sizeMap.get(format);
|
|
59
59
|
if (size === undefined) {
|
|
60
|
-
throw new
|
|
61
|
-
key:
|
|
60
|
+
throw new exceptions_1.AppBadRequestException({
|
|
61
|
+
key: enums_1.ErrorKeyEnum.DEFAULT_SIZE,
|
|
62
62
|
message: [`No default size set for format: ${format}`],
|
|
63
63
|
});
|
|
64
64
|
}
|
package/dist/src/enums/index.js
CHANGED
|
@@ -17,3 +17,4 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
17
17
|
__exportStar(require("./currency.enum"), exports);
|
|
18
18
|
__exportStar(require("./time.unit.enum"), exports);
|
|
19
19
|
__exportStar(require("./column-order.enum"), exports);
|
|
20
|
+
__exportStar(require("./error.key.enum"), exports);
|