picker-db 4.16.0 → 5.0.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/.nvmrc +1 -1
- package/eslint.config.mjs +54 -0
- package/modules/picker/schemas/conversation.js +0 -1
- package/modules/picker/schemas/customer.js +0 -2
- package/modules/picker/schemas/driver.js +0 -2
- package/modules/picker/schemas/notification.js +0 -11
- package/package.json +3 -11
- package/.eslintignore +0 -9
- package/.eslintrc.json +0 -35
package/.nvmrc
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
v22.14.0
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import neostandard from "neostandard";
|
|
2
|
+
import babelParser from "@babel/eslint-parser";
|
|
3
|
+
|
|
4
|
+
export default [
|
|
5
|
+
{
|
|
6
|
+
ignores: ["build/*", "!build/index.js", "dist/*", "bundle.js", ".*/**", ".*"],
|
|
7
|
+
},
|
|
8
|
+
...neostandard(),
|
|
9
|
+
{
|
|
10
|
+
languageOptions: {
|
|
11
|
+
parser: babelParser,
|
|
12
|
+
parserOptions: {
|
|
13
|
+
requireConfigFile: false,
|
|
14
|
+
ecmaVersion: 2018,
|
|
15
|
+
},
|
|
16
|
+
globals: {
|
|
17
|
+
// Node.js
|
|
18
|
+
process: "readonly",
|
|
19
|
+
require: "readonly",
|
|
20
|
+
module: "writable",
|
|
21
|
+
exports: "writable",
|
|
22
|
+
__dirname: "readonly",
|
|
23
|
+
__filename: "readonly",
|
|
24
|
+
// Mocha
|
|
25
|
+
describe: "readonly",
|
|
26
|
+
it: "readonly",
|
|
27
|
+
before: "readonly",
|
|
28
|
+
beforeEach: "readonly",
|
|
29
|
+
after: "readonly",
|
|
30
|
+
afterEach: "readonly",
|
|
31
|
+
},
|
|
32
|
+
},
|
|
33
|
+
rules: {
|
|
34
|
+
"no-console": "warn",
|
|
35
|
+
"no-use-before-define": "warn",
|
|
36
|
+
"no-var": "error",
|
|
37
|
+
"prefer-const": "error",
|
|
38
|
+
"capitalized-comments": ["error", "always"],
|
|
39
|
+
"@stylistic/spaced-comment": "warn",
|
|
40
|
+
"@stylistic/comma-dangle": [
|
|
41
|
+
"error",
|
|
42
|
+
{
|
|
43
|
+
arrays: "always-multiline",
|
|
44
|
+
objects: "always-multiline",
|
|
45
|
+
imports: "always-multiline",
|
|
46
|
+
exports: "always-multiline",
|
|
47
|
+
functions: "always-multiline",
|
|
48
|
+
},
|
|
49
|
+
],
|
|
50
|
+
"@stylistic/quotes": ["error", "double"],
|
|
51
|
+
"@stylistic/semi": ["error", "always"],
|
|
52
|
+
},
|
|
53
|
+
},
|
|
54
|
+
];
|
|
@@ -22,34 +22,25 @@ module.exports = (connection) => {
|
|
|
22
22
|
}, // ID of the event that triggered the notification
|
|
23
23
|
eventType: {
|
|
24
24
|
type: String,
|
|
25
|
-
index: true,
|
|
26
25
|
}, // Notification type
|
|
27
26
|
title: { type: String },
|
|
28
27
|
message: { type: String },
|
|
29
28
|
messageHtml: { type: String }, // Html version of the message
|
|
30
29
|
provider: {
|
|
31
30
|
type: String,
|
|
32
|
-
index: true,
|
|
33
|
-
sparse: true,
|
|
34
31
|
},
|
|
35
32
|
via: {
|
|
36
33
|
type: String,
|
|
37
34
|
required: true,
|
|
38
|
-
index: true,
|
|
39
|
-
sparse: true,
|
|
40
35
|
enum: _.keys(VIA),
|
|
41
36
|
},
|
|
42
37
|
sentStatus: {
|
|
43
38
|
type: String,
|
|
44
39
|
enum: ["success", "failed"],
|
|
45
|
-
index: true,
|
|
46
|
-
sparse: true,
|
|
47
40
|
},
|
|
48
41
|
isAdminNotification: {
|
|
49
42
|
type: Boolean,
|
|
50
43
|
default: false,
|
|
51
|
-
index: true,
|
|
52
|
-
sparse: true,
|
|
53
44
|
},
|
|
54
45
|
isRead: {
|
|
55
46
|
type: Boolean,
|
|
@@ -72,8 +63,6 @@ module.exports = (connection) => {
|
|
|
72
63
|
},
|
|
73
64
|
deviceToken: {
|
|
74
65
|
type: String,
|
|
75
|
-
index: true,
|
|
76
|
-
sparse: true,
|
|
77
66
|
},
|
|
78
67
|
}, { timestamp: true });
|
|
79
68
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "picker-db",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"description": "Picker DB services",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"scripts": {
|
|
@@ -9,17 +9,9 @@
|
|
|
9
9
|
"author": "edison_andre_9@hotmail.com",
|
|
10
10
|
"license": "ISC",
|
|
11
11
|
"devDependencies": {
|
|
12
|
-
"babel-
|
|
12
|
+
"@babel/eslint-parser": "^7.23.0",
|
|
13
13
|
"chai": "^4.2.0",
|
|
14
|
-
"
|
|
15
|
-
"eslint-config-standard": "^14.1.1",
|
|
16
|
-
"eslint-plugin-import": "^2.22.0",
|
|
17
|
-
"eslint-plugin-node": "^11.1.0",
|
|
18
|
-
"eslint-plugin-promise": "^4.2.1",
|
|
19
|
-
"eslint-plugin-standard": "^4.0.1",
|
|
20
|
-
"mocha": "^8.1.3",
|
|
21
|
-
"nyc": "^15.1.0",
|
|
22
|
-
"standard": "^14.3.4"
|
|
14
|
+
"neostandard": "^0.13.0"
|
|
23
15
|
},
|
|
24
16
|
"dependencies": {
|
|
25
17
|
"lodash": "^4.17.20",
|
package/.eslintignore
DELETED
package/.eslintrc.json
DELETED
|
@@ -1,35 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": [
|
|
3
|
-
"standard"
|
|
4
|
-
],
|
|
5
|
-
"parserOptions": {
|
|
6
|
-
"ecmaVersion": 2018
|
|
7
|
-
},
|
|
8
|
-
"env": {
|
|
9
|
-
"es6": true,
|
|
10
|
-
"node": true,
|
|
11
|
-
"mocha": true
|
|
12
|
-
},
|
|
13
|
-
"parser": "babel-eslint",
|
|
14
|
-
"rules": {
|
|
15
|
-
"no-console": "warn",
|
|
16
|
-
"no-use-before-define": "warn",
|
|
17
|
-
"spaced-comment": "warn",
|
|
18
|
-
"comma-dangle": [
|
|
19
|
-
"error",
|
|
20
|
-
{
|
|
21
|
-
"arrays": "always-multiline",
|
|
22
|
-
"objects": "always-multiline",
|
|
23
|
-
"imports": "always-multiline",
|
|
24
|
-
"exports": "always-multiline",
|
|
25
|
-
"functions": "always-multiline"
|
|
26
|
-
}
|
|
27
|
-
],
|
|
28
|
-
"quotes": ["error", "double"],
|
|
29
|
-
"semi": ["error", "always"],
|
|
30
|
-
"capitalized-comments": ["error", "always"],
|
|
31
|
-
"no-var": "error",
|
|
32
|
-
"prefer-const": "error"
|
|
33
|
-
}
|
|
34
|
-
}
|
|
35
|
-
|