@dt-frames/ui 1.0.17 → 1.0.19
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/es/index.js +13 -7
- package/package.json +1 -1
package/es/index.js
CHANGED
|
@@ -3044,11 +3044,7 @@ var _sfc_main$P = defineComponent({
|
|
|
3044
3044
|
props: cProps = {}
|
|
3045
3045
|
} = schema2;
|
|
3046
3046
|
if (isFunction(cProps)) {
|
|
3047
|
-
cProps = (_a = cProps({
|
|
3048
|
-
schema: schema2,
|
|
3049
|
-
formModel,
|
|
3050
|
-
formActionType
|
|
3051
|
-
})) != null ? _a : {};
|
|
3047
|
+
cProps = (_a = cProps(formModel)) != null ? _a : {};
|
|
3052
3048
|
}
|
|
3053
3049
|
if (schema2.component === "Divider") {
|
|
3054
3050
|
cProps = Object.assign({
|
|
@@ -3777,7 +3773,7 @@ function useFormValues({
|
|
|
3777
3773
|
const obj = {};
|
|
3778
3774
|
schema.forEach((item) => {
|
|
3779
3775
|
const { props = {}, name, component } = item;
|
|
3780
|
-
let { defaultValue: defaultValue2, mode, format, treeCheckable } = isFunction(props) ? props() : props;
|
|
3776
|
+
let { defaultValue: defaultValue2, mode, format, treeCheckable } = isFunction(props) ? props({ formModel }) : props;
|
|
3781
3777
|
const names = isString(name) ? [name] : name;
|
|
3782
3778
|
if (defaultValue2 !== null && defaultValue2 !== void 0) {
|
|
3783
3779
|
if (datePickerType.includes(component)) {
|
|
@@ -6984,6 +6980,8 @@ function useSource(opt) {
|
|
|
6984
6980
|
search();
|
|
6985
6981
|
}
|
|
6986
6982
|
function search() {
|
|
6983
|
+
if (!queryPage)
|
|
6984
|
+
return;
|
|
6987
6985
|
const { fetch } = useFetch(queryPage, baseUrl);
|
|
6988
6986
|
loading.onQuerypage.value = true;
|
|
6989
6987
|
fetch(toRaw(baseData)).then((rsp) => {
|
|
@@ -7006,6 +7004,8 @@ function useSource(opt) {
|
|
|
7006
7004
|
});
|
|
7007
7005
|
}
|
|
7008
7006
|
function onAdd(model) {
|
|
7007
|
+
if (!add)
|
|
7008
|
+
return;
|
|
7009
7009
|
const { fetch } = useFetch(add, baseUrl);
|
|
7010
7010
|
return fetch(model, false).then((rsp) => {
|
|
7011
7011
|
if ((rsp == null ? void 0 : rsp.code) === 0)
|
|
@@ -7014,10 +7014,14 @@ function useSource(opt) {
|
|
|
7014
7014
|
});
|
|
7015
7015
|
}
|
|
7016
7016
|
async function onQueryById(id) {
|
|
7017
|
+
if (!queryById)
|
|
7018
|
+
return;
|
|
7017
7019
|
const { fetch } = useFetch(queryById, baseUrl);
|
|
7018
7020
|
return await fetch({ id });
|
|
7019
7021
|
}
|
|
7020
7022
|
function onUpdate(model) {
|
|
7023
|
+
if (!update)
|
|
7024
|
+
return;
|
|
7021
7025
|
const { fetch } = useFetch(update, baseUrl);
|
|
7022
7026
|
return fetch(model, false).then((rsp) => {
|
|
7023
7027
|
if ((rsp == null ? void 0 : rsp.code) === 0)
|
|
@@ -7026,6 +7030,8 @@ function useSource(opt) {
|
|
|
7026
7030
|
});
|
|
7027
7031
|
}
|
|
7028
7032
|
function onDeletes(ids) {
|
|
7033
|
+
if (!deletes)
|
|
7034
|
+
return;
|
|
7029
7035
|
const { fetch } = useFetch(deletes, baseUrl);
|
|
7030
7036
|
fetch(toRaw(ids), false).then((rsp) => {
|
|
7031
7037
|
if ((rsp == null ? void 0 : rsp.code) === 0)
|
|
@@ -8799,7 +8805,7 @@ const _sfc_main$s = /* @__PURE__ */ defineComponent({
|
|
|
8799
8805
|
},
|
|
8800
8806
|
setup(__props) {
|
|
8801
8807
|
const props = __props;
|
|
8802
|
-
const title = "\u9686\u57FA\
|
|
8808
|
+
const title = "\u9686\u57FA\u96C6\u56E2\u6D77\u5916\u7A0E\u52A1\u7CFB\u7EDF";
|
|
8803
8809
|
const { getCollapsedShowTitle } = useMenu();
|
|
8804
8810
|
const getLogoClass = computed(() => {
|
|
8805
8811
|
return [
|