@nomalism-com/api 0.16.21 → 0.16.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.
|
@@ -6,6 +6,7 @@ export import IFindLinesInPrisonResponse = Entity.IFindLinesInPrisonResponse;
|
|
|
6
6
|
export import ICheckLineInPrisonOptions = Entity.ICheckLineInPrisonOptions;
|
|
7
7
|
export import ICheckLinesInPrisonLinesRequest = Entity.ICheckLinesInPrisonLinesRequest;
|
|
8
8
|
export import ICheckLinesInPrisonRequest = Entity.ICheckLinesInPrisonRequest;
|
|
9
|
+
export import ICreateLinesInPrisonRequest = Entity.ICreateLinesInPrisonRequest;
|
|
9
10
|
export declare const checkLineInPrisonOptions: readonly ["Por confirmar", "Devolver a stock", "Quebrar", "Devolver a fornecedor"];
|
|
10
11
|
export default class Repository implements Entity.IApi {
|
|
11
12
|
route: string;
|
|
@@ -17,4 +18,5 @@ export default class Repository implements Entity.IApi {
|
|
|
17
18
|
findLinesInPrison(): Promise<IFindLinesInPrisonResponse[]>;
|
|
18
19
|
findLinesInPrisonProviders(): Promise<shared.IFindMinifiedResponse[]>;
|
|
19
20
|
checkLinesInPrison(data: ICheckLinesInPrisonRequest): Promise<void>;
|
|
21
|
+
createLinesInPrison(data: ICreateLinesInPrisonRequest): Promise<string>;
|
|
20
22
|
}
|
|
@@ -110,6 +110,19 @@ var Repository = (function () {
|
|
|
110
110
|
});
|
|
111
111
|
});
|
|
112
112
|
};
|
|
113
|
+
Repository.prototype.createLinesInPrison = function (data) {
|
|
114
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
115
|
+
var response;
|
|
116
|
+
return __generator(this, function (_a) {
|
|
117
|
+
switch (_a.label) {
|
|
118
|
+
case 0: return [4, this.api.post("".concat(this.route, "create_lines"), data)];
|
|
119
|
+
case 1:
|
|
120
|
+
response = _a.sent();
|
|
121
|
+
return [2, response.data];
|
|
122
|
+
}
|
|
123
|
+
});
|
|
124
|
+
});
|
|
125
|
+
};
|
|
113
126
|
return Repository;
|
|
114
127
|
}());
|
|
115
128
|
exports.default = Repository;
|
package/package.json
CHANGED
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
"typescript",
|
|
10
10
|
"helper"
|
|
11
11
|
],
|
|
12
|
-
"version": "0.16.
|
|
12
|
+
"version": "0.16.22",
|
|
13
13
|
"main": "dist/index.js",
|
|
14
14
|
"types": "./dist/index.d.ts",
|
|
15
15
|
"files": [
|
|
@@ -47,7 +47,7 @@
|
|
|
47
47
|
"typescript": "^5.3.3"
|
|
48
48
|
},
|
|
49
49
|
"dependencies": {
|
|
50
|
-
"@nomalism-com/types": "^0.16.
|
|
50
|
+
"@nomalism-com/types": "^0.16.34",
|
|
51
51
|
"axios": "^0.27.2"
|
|
52
52
|
}
|
|
53
53
|
}
|