@cocreate/file 1.9.8 → 1.9.10
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/CHANGELOG.md +16 -0
- package/demo/index.html +3 -3
- package/package.json +5 -5
- package/src/client.js +3 -3
- package/src/server.js +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,19 @@
|
|
|
1
|
+
## [1.9.10](https://github.com/CoCreate-app/CoCreate-file/compare/v1.9.9...v1.9.10) (2023-11-03)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* favicon.ico path ([d624243](https://github.com/CoCreate-app/CoCreate-file/commit/d62424361f2f55ee06ee6489a2c51f7e431c2639))
|
|
7
|
+
* update dependencies to the lates versions ([109bee3](https://github.com/CoCreate-app/CoCreate-file/commit/109bee3e9f120ec64c8bb1242b5c488bcab32475))
|
|
8
|
+
* update method to use object.update etc ([d412fe0](https://github.com/CoCreate-app/CoCreate-file/commit/d412fe0413483e69acd8a7e9817cfcfed50ed52c))
|
|
9
|
+
|
|
10
|
+
## [1.9.9](https://github.com/CoCreate-app/CoCreate-file/compare/v1.9.8...v1.9.9) (2023-10-25)
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Bug Fixes
|
|
14
|
+
|
|
15
|
+
* bump dependencies ([e785667](https://github.com/CoCreate-app/CoCreate-file/commit/e785667854cbc76da7650ff99fc39eb18387b843))
|
|
16
|
+
|
|
1
17
|
## [1.9.8](https://github.com/CoCreate-app/CoCreate-file/compare/v1.9.7...v1.9.8) (2023-10-22)
|
|
2
18
|
|
|
3
19
|
|
package/demo/index.html
CHANGED
|
@@ -6,9 +6,9 @@
|
|
|
6
6
|
<!-- CoCreate Favicon -->
|
|
7
7
|
<link
|
|
8
8
|
rel="icon"
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
type="image/png"
|
|
10
|
+
sizes="32x32"
|
|
11
|
+
href="../assets/favicon.ico" />
|
|
12
12
|
<link rel="manifest" href="/manifest.webmanifest" />
|
|
13
13
|
</head>
|
|
14
14
|
<body>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cocreate/file",
|
|
3
|
-
"version": "1.9.
|
|
3
|
+
"version": "1.9.10",
|
|
4
4
|
"description": "A headless file uploader that uses HTML5 attributes for customization. Allows easy upload of files to server.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"file",
|
|
@@ -59,9 +59,9 @@
|
|
|
59
59
|
"webpack-log": "^3.0.1"
|
|
60
60
|
},
|
|
61
61
|
"dependencies": {
|
|
62
|
-
"@cocreate/actions": "^1.
|
|
63
|
-
"@cocreate/config": "^1.6.
|
|
64
|
-
"@cocreate/render": "^1.
|
|
65
|
-
"@cocreate/utils": "^1.
|
|
62
|
+
"@cocreate/actions": "^1.12.1",
|
|
63
|
+
"@cocreate/config": "^1.6.6",
|
|
64
|
+
"@cocreate/render": "^1.29.1",
|
|
65
|
+
"@cocreate/utils": "^1.26.2"
|
|
66
66
|
}
|
|
67
67
|
}
|
package/src/client.js
CHANGED
|
@@ -385,7 +385,7 @@ async function upload(element, data) {
|
|
|
385
385
|
}
|
|
386
386
|
}
|
|
387
387
|
|
|
388
|
-
Data.method =
|
|
388
|
+
Data.method = Data.type + '.update'
|
|
389
389
|
let response = await Crud.send(Data)({
|
|
390
390
|
array,
|
|
391
391
|
object,
|
|
@@ -459,7 +459,7 @@ async function Import(element, data) {
|
|
|
459
459
|
|
|
460
460
|
if (data.length) {
|
|
461
461
|
for (let i = 0; i < data.length; i++) {
|
|
462
|
-
data[i].method =
|
|
462
|
+
data[i].method = data[i].type + '.create'
|
|
463
463
|
data[i] = await Crud.send(data[i])
|
|
464
464
|
}
|
|
465
465
|
}
|
|
@@ -502,7 +502,7 @@ async function Export(element, data) {
|
|
|
502
502
|
|
|
503
503
|
if (Data.type === 'key')
|
|
504
504
|
Data.type = 'object'
|
|
505
|
-
Data.method =
|
|
505
|
+
Data.method = Data.type + '.read'
|
|
506
506
|
Data = await Crud.send(Data)
|
|
507
507
|
data.push(...Data[Data.type])
|
|
508
508
|
|
package/src/server.js
CHANGED
|
@@ -413,13 +413,13 @@ module.exports = async function file(CoCreateConfig, configPath, match) {
|
|
|
413
413
|
let response;
|
|
414
414
|
if (!data.object._id && !data.$filter) {
|
|
415
415
|
response = await crud.send({
|
|
416
|
-
method: 'create
|
|
416
|
+
method: 'object.create',
|
|
417
417
|
...config,
|
|
418
418
|
...data
|
|
419
419
|
})
|
|
420
420
|
} else {
|
|
421
421
|
response = await crud.send({
|
|
422
|
-
method: 'update
|
|
422
|
+
method: 'object.update',
|
|
423
423
|
...config,
|
|
424
424
|
...data,
|
|
425
425
|
upsert: true
|