@crowdin/app-project-module 0.63.2 → 0.65.0
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/out/index.d.ts +2 -0
- package/out/index.js +4 -2
- package/out/modules/integration/handlers/crowdin-project.js +8 -1
- package/out/modules/integration/handlers/user-errors.js +8 -1
- package/out/modules/integration/index.js +15 -1
- package/out/modules/integration/types.d.ts +4 -0
- package/out/modules/integration/util/cron.d.ts +19 -2
- package/out/modules/integration/util/cron.js +59 -39
- package/out/modules/integration/util/defaults.js +3 -0
- package/out/modules/integration/util/job.d.ts +4 -1
- package/out/modules/integration/util/job.js +155 -29
- package/out/modules/integration/util/types.d.ts +12 -6
- package/out/modules/integration/util/types.js +1 -0
- package/out/storage/index.d.ts +5 -2
- package/out/storage/mysql.d.ts +6 -3
- package/out/storage/mysql.js +42 -4
- package/out/storage/postgre.d.ts +7 -3
- package/out/storage/postgre.js +55 -5
- package/out/storage/sqlite.d.ts +7 -3
- package/out/storage/sqlite.js +42 -4
- package/out/util/credentials-masker.d.ts +1 -1
- package/out/util/credentials-masker.js +34 -32
- package/out/util/index.d.ts +3 -0
- package/out/util/index.js +25 -1
- package/out/util/logger.js +0 -6
- package/out/util/terminus-express.js +4 -2
- package/out/views/main.handlebars +11 -2
- package/package.json +1 -1
|
@@ -5,12 +5,14 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
const express_1 = __importDefault(require("express"));
|
|
7
7
|
const terminus_1 = require("@godaddy/terminus");
|
|
8
|
+
const job_1 = require("../modules/integration/util/job");
|
|
8
9
|
express_1.default.application.baseListen = express_1.default.application.listen;
|
|
9
10
|
express_1.default.application.listen = function (...args) {
|
|
10
|
-
const [
|
|
11
|
-
const server = this.baseListen.call(this, port);
|
|
11
|
+
const [config, callback] = args;
|
|
12
|
+
const server = this.baseListen.call(this, config.port);
|
|
12
13
|
if (callback) {
|
|
13
14
|
callback();
|
|
15
|
+
(0, job_1.reRunInProgressJobs)(config);
|
|
14
16
|
}
|
|
15
17
|
(0, terminus_1.createTerminus)(server, {
|
|
16
18
|
timeout: Infinity,
|
|
@@ -418,7 +418,11 @@
|
|
|
418
418
|
.then(checkResponse)
|
|
419
419
|
.then((res) => {
|
|
420
420
|
project = res;
|
|
421
|
-
const languagesSorted = project.targetLanguages.
|
|
421
|
+
const languagesSorted = project.targetLanguages.map(language => ({
|
|
422
|
+
sourceLanguageId: res.sourceLanguage.editorCode,
|
|
423
|
+
projectEditorLink: res.projectEditorLink,
|
|
424
|
+
...language,
|
|
425
|
+
})).sort((a, b) => a.name.localeCompare(b.name));
|
|
422
426
|
|
|
423
427
|
if (project.inContext && config?.inContext) {
|
|
424
428
|
languagesSorted.push({...project.inContextPseudoLanguage, inContext: true});
|
|
@@ -1143,6 +1147,10 @@
|
|
|
1143
1147
|
modal.innerHTML = getUserErrorDetail(item);
|
|
1144
1148
|
};
|
|
1145
1149
|
|
|
1150
|
+
const formatDate = (field, index, item) => {
|
|
1151
|
+
return item.formattedDate;
|
|
1152
|
+
}
|
|
1153
|
+
|
|
1146
1154
|
table.setTableConfig && table.setTableConfig({
|
|
1147
1155
|
defaultSortingColumn: "createdAt",
|
|
1148
1156
|
defaultSortingDir: "desc",
|
|
@@ -1152,6 +1160,7 @@
|
|
|
1152
1160
|
name: "Date",
|
|
1153
1161
|
isSortable: true,
|
|
1154
1162
|
clickFn: clickRow,
|
|
1163
|
+
formatFn: formatDate,
|
|
1155
1164
|
},
|
|
1156
1165
|
{
|
|
1157
1166
|
field: "action",
|
|
@@ -1199,7 +1208,7 @@
|
|
|
1199
1208
|
} else {
|
|
1200
1209
|
html += `<tr><td>Message</td><td>${sanitizeHTML(error.message)}</td></tr>`;
|
|
1201
1210
|
}
|
|
1202
|
-
html += `<tr><td>Date/time</td><td>${sanitizeHTML(error.
|
|
1211
|
+
html += `<tr><td>Date/time</td><td>${sanitizeHTML(error.formattedDate)}</td></tr>`;
|
|
1203
1212
|
|
|
1204
1213
|
if (data.requestParams) {
|
|
1205
1214
|
html += `<tr><td>Method</td><td>${sanitizeHTML(data.requestParams.method)}</td></tr>`;
|
package/package.json
CHANGED