jobsys-explore 1.0.21 → 1.0.23
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/.changeset/dry-feet-float.md +5 -0
- package/.changeset/odd-forks-drop.md +5 -0
- package/CHANGELOG.md +33 -0
- package/components/uploader/ExUploader.jsx +10 -3
- package/components/utils.js +2 -2
- package/dist/jobsys-explore.cjs +6 -6
- package/dist/jobsys-explore.cjs.map +1 -1
- package/dist/jobsys-explore.js +487 -483
- package/dist/jobsys-explore.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,38 @@
|
|
|
1
1
|
# jobsys-explore
|
|
2
2
|
|
|
3
|
+
## 1.0.23
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Build
|
|
8
|
+
- Drop the unused property
|
|
9
|
+
- Fix clear error in ExSearch
|
|
10
|
+
- Add init and beforeSubmit
|
|
11
|
+
- Add disabled and readonly for ex form
|
|
12
|
+
- Fix exupload
|
|
13
|
+
- Add ex-decorator
|
|
14
|
+
- clone the options before traverse
|
|
15
|
+
- Upgrade useFormFormat
|
|
16
|
+
- Add useFindParentValues
|
|
17
|
+
- Fix upload file
|
|
18
|
+
- Fix beforeSubmit
|
|
19
|
+
|
|
20
|
+
## 1.0.22
|
|
21
|
+
|
|
22
|
+
### Patch Changes
|
|
23
|
+
|
|
24
|
+
- Build
|
|
25
|
+
- Drop the unused property
|
|
26
|
+
- Fix clear error in ExSearch
|
|
27
|
+
- Add init and beforeSubmit
|
|
28
|
+
- Add disabled and readonly for ex form
|
|
29
|
+
- Fix exupload
|
|
30
|
+
- Add ex-decorator
|
|
31
|
+
- Upgrade useFormFormat
|
|
32
|
+
- Add useFindParentValues
|
|
33
|
+
- Fix upload file
|
|
34
|
+
- Fix beforeSubmit
|
|
35
|
+
|
|
3
36
|
## 1.0.21
|
|
4
37
|
|
|
5
38
|
### Patch Changes
|
|
@@ -99,7 +99,7 @@ export default defineComponent({
|
|
|
99
99
|
const defaultUploadUrl = uploaderProvider.uploadUrl || ""
|
|
100
100
|
const defaultFileItem = uploaderProvider.defaultFileItem || {}
|
|
101
101
|
|
|
102
|
-
const { url: urlKey, path: pathKey } = defaultFileItem
|
|
102
|
+
const { url: urlKey, path: pathKey, name: nameKey } = defaultFileItem
|
|
103
103
|
|
|
104
104
|
const state = reactive({
|
|
105
105
|
fileList: [],
|
|
@@ -147,9 +147,16 @@ export default defineComponent({
|
|
|
147
147
|
}
|
|
148
148
|
|
|
149
149
|
const getModelValue = () => {
|
|
150
|
-
const fileList = state.fileList
|
|
150
|
+
const fileList = state.fileList
|
|
151
|
+
.filter((item) => item.status === "done" || !!item[nameKey] || !!item[pathKey])
|
|
152
|
+
.map((item) => pick(item, Object.keys(defaultFileItem)))
|
|
151
153
|
if (isSingle.value) {
|
|
152
|
-
return
|
|
154
|
+
return (
|
|
155
|
+
fileList[0] || {
|
|
156
|
+
[pathKey]: "",
|
|
157
|
+
[urlKey]: "",
|
|
158
|
+
}
|
|
159
|
+
)
|
|
153
160
|
}
|
|
154
161
|
|
|
155
162
|
return fileList || []
|
package/components/utils.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { isFunction, isString } from "lodash-es"
|
|
1
|
+
import { cloneDeep, isFunction, isString } from "lodash-es"
|
|
2
2
|
import { watch } from "vue"
|
|
3
3
|
import { useFetch } from "../hooks"
|
|
4
4
|
|
|
@@ -104,7 +104,7 @@ export const defaultOptionsProps = {
|
|
|
104
104
|
*/
|
|
105
105
|
export const prepareOptions = (options) => {
|
|
106
106
|
options = isFunction(options) ? options() : options
|
|
107
|
-
options = options.map((op) => {
|
|
107
|
+
options = cloneDeep(options).map((op) => {
|
|
108
108
|
if (op.children?.length) {
|
|
109
109
|
op.children = prepareOptions(op.children)
|
|
110
110
|
}
|