@mongoosejs/studio 0.0.39 → 0.0.40
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/frontend/public/app.js +6 -4
- package/index.d.ts +7 -0
- package/index.js +3 -0
- package/package.json +6 -6
package/frontend/public/app.js
CHANGED
|
@@ -1644,9 +1644,8 @@ module.exports = app => app.component('models', {
|
|
|
1644
1644
|
} else {
|
|
1645
1645
|
this.filter = {};
|
|
1646
1646
|
delete this.query.search;
|
|
1647
|
-
this.$router.push({ query: this.query });
|
|
1648
1647
|
}
|
|
1649
|
-
await this.loadMoreDocuments();
|
|
1648
|
+
await this.loadMoreDocuments(true);
|
|
1650
1649
|
},
|
|
1651
1650
|
async getDocuments() {
|
|
1652
1651
|
const { docs, schemaPaths, numDocs } = await api.Model.getDocuments({
|
|
@@ -1678,7 +1677,7 @@ module.exports = app => app.component('models', {
|
|
|
1678
1677
|
this.filteredPaths = [...this.schemaPaths];
|
|
1679
1678
|
this.selectedPaths = [...this.schemaPaths];
|
|
1680
1679
|
},
|
|
1681
|
-
async loadMoreDocuments() {
|
|
1680
|
+
async loadMoreDocuments(updateQuery) {
|
|
1682
1681
|
const { docs } = await api.Model.getDocuments({
|
|
1683
1682
|
model: this.currentModel,
|
|
1684
1683
|
filter: this.filter,
|
|
@@ -1689,6 +1688,9 @@ module.exports = app => app.component('models', {
|
|
|
1689
1688
|
if (docs.length < limit) {
|
|
1690
1689
|
this.loadedAllDocs = true;
|
|
1691
1690
|
}
|
|
1691
|
+
if (updateQuery) {
|
|
1692
|
+
this.$router.push({ query: this.query });
|
|
1693
|
+
}
|
|
1692
1694
|
},
|
|
1693
1695
|
addOrRemove(path) {
|
|
1694
1696
|
const exists = this.selectedPaths.findIndex(x => x.path == path.path);
|
|
@@ -10632,7 +10634,7 @@ app.component('app-component', {
|
|
|
10632
10634
|
`,
|
|
10633
10635
|
errorCaptured(err) {
|
|
10634
10636
|
vanillatoasts.create({
|
|
10635
|
-
title: `Error: ${err.message}`,
|
|
10637
|
+
title: `Error: ${err.response?.data?.message || err.message}`,
|
|
10636
10638
|
icon: 'images/failure.jpg',
|
|
10637
10639
|
timeout: 10000,
|
|
10638
10640
|
positionClass: 'bottomRight'
|
package/index.d.ts
ADDED
package/index.js
ADDED
package/package.json
CHANGED
|
@@ -1,13 +1,16 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mongoosejs/studio",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.40",
|
|
4
4
|
"dependencies": {
|
|
5
5
|
"archetype": "0.13.0",
|
|
6
6
|
"csv-stringify": "6.3.0",
|
|
7
7
|
"ejson": "^2.2.3",
|
|
8
8
|
"extrovert": "0.0.24",
|
|
9
9
|
"node-inspect-extracted": "3.x",
|
|
10
|
-
"
|
|
10
|
+
"tailwindcss": "3.4.0",
|
|
11
|
+
"vanillatoasts": "^1.6.0",
|
|
12
|
+
"vue": "3.x",
|
|
13
|
+
"webpack": "5.x"
|
|
11
14
|
},
|
|
12
15
|
"peerDependencies": {
|
|
13
16
|
"bson": "^5.5.1 || 6.x",
|
|
@@ -18,10 +21,7 @@
|
|
|
18
21
|
"axios": "1.2.2",
|
|
19
22
|
"express": "4.x",
|
|
20
23
|
"mocha": "10.2.0",
|
|
21
|
-
"mongoose": "8.x"
|
|
22
|
-
"tailwindcss": "3.4.0",
|
|
23
|
-
"vue": "3.x",
|
|
24
|
-
"webpack": "5.75.0"
|
|
24
|
+
"mongoose": "8.x"
|
|
25
25
|
},
|
|
26
26
|
"scripts": {
|
|
27
27
|
"tailwind": "tailwindcss -o ./frontend/public/tw.css",
|