@smallwei/avue 3.8.3 → 3.8.5
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/dist/avue.js +2 -2
- package/dist/avue.js.map +1 -1
- package/dist/avue.min.js +2 -2
- package/es/core/detail.mjs +2 -1
- package/es/index.mjs +2 -1
- package/es/locale/index.mjs +2 -1
- package/es/packages/element-plus/chat/index.vue +6 -5
- package/es/packages/element-plus/count-up/index.vue +7 -5
- package/es/plugin/export/index.mjs +2 -1
- package/es/utils/util.mjs +6 -3
- package/es/version.mjs +1 -1
- package/es/version.ts +1 -1
- package/lib/core/detail.js +39 -8
- package/lib/index.js +36 -2
- package/lib/locale/index.js +38 -4
- package/lib/packages/element-plus/chat/index.vue +6 -5
- package/lib/packages/element-plus/count-up/index.vue +7 -5
- package/lib/plugin/export/index.js +36 -2
- package/lib/utils/util.js +42 -9
- package/lib/version.js +1 -1
- package/lib/version.ts +1 -1
- package/package.json +1 -1
package/es/core/detail.mjs
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { validatenull } from '../utils/validate.mjs';
|
|
2
2
|
import { getPasswordChar, getDicValue, getAsVal, detailDataType } from '../utils/util.mjs';
|
|
3
3
|
import { DIC_SPLIT, DIC_SHOW_SPLIT, DATE_LIST, MULTIPLE_LIST, ARRAY_VALUE_LIST, } from '../global/variable.mjs';
|
|
4
|
-
import
|
|
4
|
+
import * as __avueImportModule0 from 'dayjs';
|
|
5
|
+
const dayjs = __avueImportModule0.default || __avueImportModule0;
|
|
5
6
|
export const detail = (row = {}, column = {}, option = {}, dic = []) => {
|
|
6
7
|
let result = row[column.prop];
|
|
7
8
|
const type = column.type;
|
package/es/index.mjs
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import components from "./ui/index.mjs";
|
|
2
2
|
import { version } from "./version.mjs";
|
|
3
|
-
import
|
|
3
|
+
import * as __avueImportModule0 from "axios";
|
|
4
|
+
const axios = __avueImportModule0.default || __avueImportModule0;
|
|
4
5
|
import { validatenull } from "./utils/validate.mjs";
|
|
5
6
|
import { randomId, deepClone, dataURLtoFile, findObject, validData, findArray, findNode, setPx, isJson, downFile, loadScript, } from "./utils/util.mjs";
|
|
6
7
|
import contextmenu from "./packages/core/directive/contextmenu.mjs";
|
package/es/locale/index.mjs
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import enLang from './lang/en.mjs';
|
|
2
2
|
import zhLang from './lang/zh.mjs';
|
|
3
3
|
import defaultLang from './lang/zh-cn.mjs';
|
|
4
|
-
import
|
|
4
|
+
import * as __avueImportModule0 from 'lodash/merge';
|
|
5
|
+
const _merge = __avueImportModule0.default || __avueImportModule0;
|
|
5
6
|
const DEFAULT_LOCALE = 'zh-cn';
|
|
6
7
|
const RE_NARGS = /(%|)\{([0-9a-zA-Z_]+)\}/g;
|
|
7
8
|
const format = (string = '', ...args) => {
|
|
@@ -192,11 +192,12 @@
|
|
|
192
192
|
</div>
|
|
193
193
|
</template>
|
|
194
194
|
|
|
195
|
-
<script>
|
|
196
|
-
import create from "../../../core/create.mjs";
|
|
197
|
-
import locale from "../../../core/locale.mjs";
|
|
198
|
-
import
|
|
199
|
-
|
|
195
|
+
<script>
|
|
196
|
+
import create from "../../../core/create.mjs";
|
|
197
|
+
import locale from "../../../core/locale.mjs";
|
|
198
|
+
import * as __avueImportModule0 from 'dayjs';
|
|
199
|
+
const dayjs = __avueImportModule0.default || __avueImportModule0;
|
|
200
|
+
export default create({
|
|
200
201
|
name: "chat",
|
|
201
202
|
mixins: [locale],
|
|
202
203
|
data () {
|
|
@@ -2,10 +2,12 @@
|
|
|
2
2
|
<span>{{end}}</span>
|
|
3
3
|
</template>
|
|
4
4
|
|
|
5
|
-
<script>
|
|
6
|
-
import
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
<script>
|
|
6
|
+
import * as __avueImportModule0 from "countup.js";
|
|
7
|
+
const CountUp = __avueImportModule0.default || __avueImportModule0;
|
|
8
|
+
import create from "../../../core/create.mjs";
|
|
9
|
+
|
|
10
|
+
export default create({
|
|
9
11
|
name: "count-up",
|
|
10
12
|
props: {
|
|
11
13
|
animation: {
|
|
@@ -104,4 +106,4 @@ export default create({
|
|
|
104
106
|
},
|
|
105
107
|
|
|
106
108
|
});
|
|
107
|
-
</script>
|
|
109
|
+
</script>
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
/* eslint-disable */
|
|
2
2
|
import { isJson, downFile, validData } from '../../utils/util.mjs';
|
|
3
3
|
import packages from '../../core/packages.mjs';
|
|
4
|
-
import
|
|
4
|
+
import * as __avueImportModule0 from 'dayjs';
|
|
5
|
+
const dayjs = __avueImportModule0.default || __avueImportModule0;
|
|
5
6
|
const XLSX = window.XLSX;
|
|
6
7
|
export default {
|
|
7
8
|
buildHeader(revealList) {
|
package/es/utils/util.mjs
CHANGED
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
import { validatenull } from './validate.mjs';
|
|
2
2
|
import { CHILDREN_LIST, DIC_PROPS, typeList } from '../global/variable.mjs';
|
|
3
|
-
import
|
|
4
|
-
|
|
5
|
-
import
|
|
3
|
+
import * as __avueImportModule0 from 'lodash/get';
|
|
4
|
+
const _get = __avueImportModule0.default || __avueImportModule0;
|
|
5
|
+
import * as __avueImportModule1 from 'lodash/set';
|
|
6
|
+
const _set = __avueImportModule1.default || __avueImportModule1;
|
|
7
|
+
import * as __avueImportModule2 from 'lodash/cloneDeep';
|
|
8
|
+
const _cloneDeep = __avueImportModule2.default || __avueImportModule2;
|
|
6
9
|
export const isMediaType = (url, type) => {
|
|
7
10
|
if (validatenull(url))
|
|
8
11
|
return;
|
package/es/version.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version = '3.8.
|
|
1
|
+
export const version = '3.8.5';
|
package/es/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version = '3.8.
|
|
1
|
+
export const version = '3.8.5'
|
package/lib/core/detail.js
CHANGED
|
@@ -1,13 +1,44 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
5
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
36
|
exports.detail = void 0;
|
|
7
37
|
const validate_js_1 = require("../utils/validate.js");
|
|
8
38
|
const util_js_1 = require("../utils/util.js");
|
|
9
39
|
const variable_js_1 = require("../global/variable.js");
|
|
10
|
-
const
|
|
40
|
+
const __avueImportModule0 = __importStar(require("dayjs"));
|
|
41
|
+
const dayjs = __avueImportModule0.default || __avueImportModule0;
|
|
11
42
|
const detail = (row = {}, column = {}, option = {}, dic = []) => {
|
|
12
43
|
let result = row[column.prop];
|
|
13
44
|
const type = column.type;
|
|
@@ -42,13 +73,13 @@ const detail = (row = {}, column = {}, option = {}, dic = []) => {
|
|
|
42
73
|
}
|
|
43
74
|
else if (variable_js_1.DATE_LIST.includes(type) && column.format) {
|
|
44
75
|
const format = column.format;
|
|
45
|
-
const formatValue = (
|
|
76
|
+
const formatValue = dayjs().format('YYYY-MM-DD');
|
|
46
77
|
if (['dates', 'years', 'months'].includes(type)) {
|
|
47
78
|
if (typeof result === 'string') {
|
|
48
79
|
result = result.split(',');
|
|
49
80
|
}
|
|
50
81
|
if (Array.isArray(result)) {
|
|
51
|
-
result = result.map((date) => (
|
|
82
|
+
result = result.map((date) => dayjs(date).format(format)).join(column.separator || ',');
|
|
52
83
|
}
|
|
53
84
|
}
|
|
54
85
|
else if (type.indexOf('range') !== -1) {
|
|
@@ -57,13 +88,13 @@ const detail = (row = {}, column = {}, option = {}, dic = []) => {
|
|
|
57
88
|
date1 = `${formatValue} ${date1}`;
|
|
58
89
|
date2 = `${formatValue} ${date2}`;
|
|
59
90
|
}
|
|
60
|
-
result = [(
|
|
91
|
+
result = [dayjs(date1).format(format), dayjs(date2).format(format)].join(column.separator || '~');
|
|
61
92
|
}
|
|
62
93
|
else {
|
|
63
94
|
if (type === 'time') {
|
|
64
95
|
result = `${formatValue} ${result}`;
|
|
65
96
|
}
|
|
66
|
-
result = (
|
|
97
|
+
result = dayjs(result).format(format);
|
|
67
98
|
}
|
|
68
99
|
}
|
|
69
100
|
}
|
package/lib/index.js
CHANGED
|
@@ -1,4 +1,37 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
2
35
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
37
|
};
|
|
@@ -6,7 +39,8 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
6
39
|
exports.install = void 0;
|
|
7
40
|
const index_js_1 = __importDefault(require("./ui/index.js"));
|
|
8
41
|
const version_js_1 = require("./version.js");
|
|
9
|
-
const
|
|
42
|
+
const __avueImportModule0 = __importStar(require("axios"));
|
|
43
|
+
const axios = __avueImportModule0.default || __avueImportModule0;
|
|
10
44
|
const validate_js_1 = require("./utils/validate.js");
|
|
11
45
|
const util_js_1 = require("./utils/util.js");
|
|
12
46
|
const contextmenu_js_1 = __importDefault(require("./packages/core/directive/contextmenu.js"));
|
|
@@ -121,7 +155,7 @@ const install = function (app, opts = {}) {
|
|
|
121
155
|
});
|
|
122
156
|
return result;
|
|
123
157
|
};
|
|
124
|
-
app.config.globalProperties.$axios = opts.axios ||
|
|
158
|
+
app.config.globalProperties.$axios = opts.axios || axios;
|
|
125
159
|
};
|
|
126
160
|
exports.install = install;
|
|
127
161
|
const Avue = {
|
package/lib/locale/index.js
CHANGED
|
@@ -1,4 +1,37 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
2
35
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
37
|
};
|
|
@@ -7,7 +40,8 @@ exports.getLocaleCode = exports.getLocale = exports.i18n = exports.use = exports
|
|
|
7
40
|
const en_js_1 = __importDefault(require("./lang/en.js"));
|
|
8
41
|
const zh_js_1 = __importDefault(require("./lang/zh.js"));
|
|
9
42
|
const zh_cn_js_1 = __importDefault(require("./lang/zh-cn.js"));
|
|
10
|
-
const
|
|
43
|
+
const __avueImportModule0 = __importStar(require("lodash/merge"));
|
|
44
|
+
const _merge = __avueImportModule0.default || __avueImportModule0;
|
|
11
45
|
const DEFAULT_LOCALE = 'zh-cn';
|
|
12
46
|
const RE_NARGS = /(%|)\{([0-9a-zA-Z_]+)\}/g;
|
|
13
47
|
const format = (string = '', ...args) => {
|
|
@@ -77,12 +111,12 @@ const resolveRegisteredLocale = (code) => {
|
|
|
77
111
|
return null;
|
|
78
112
|
};
|
|
79
113
|
const buildLocaleState = (code) => {
|
|
80
|
-
const merged = (
|
|
114
|
+
const merged = _merge({}, zh_cn_js_1.default);
|
|
81
115
|
const resolved = resolveRegisteredLocale(code);
|
|
82
116
|
if (resolved) {
|
|
83
117
|
return {
|
|
84
118
|
code: resolved.code,
|
|
85
|
-
locale: (
|
|
119
|
+
locale: _merge({}, merged, resolved.locale)
|
|
86
120
|
};
|
|
87
121
|
}
|
|
88
122
|
return {
|
|
@@ -129,7 +163,7 @@ const use = function (locale, override) {
|
|
|
129
163
|
currentLang = localeState.locale;
|
|
130
164
|
const extraLocale = typeof locale === 'string' ? override : locale;
|
|
131
165
|
if (isPlainObject(extraLocale)) {
|
|
132
|
-
currentLang = (
|
|
166
|
+
currentLang = _merge({}, currentLang, extraLocale);
|
|
133
167
|
}
|
|
134
168
|
return currentLang;
|
|
135
169
|
};
|
|
@@ -192,11 +192,12 @@
|
|
|
192
192
|
</div>
|
|
193
193
|
</template>
|
|
194
194
|
|
|
195
|
-
<script>
|
|
196
|
-
import create from "../../../core/create.js";
|
|
197
|
-
import locale from "../../../core/locale.js";
|
|
198
|
-
import
|
|
199
|
-
|
|
195
|
+
<script>
|
|
196
|
+
import create from "../../../core/create.js";
|
|
197
|
+
import locale from "../../../core/locale.js";
|
|
198
|
+
import * as __avueImportModule0 from 'dayjs';
|
|
199
|
+
const dayjs = __avueImportModule0.default || __avueImportModule0;
|
|
200
|
+
export default create({
|
|
200
201
|
name: "chat",
|
|
201
202
|
mixins: [locale],
|
|
202
203
|
data () {
|
|
@@ -2,10 +2,12 @@
|
|
|
2
2
|
<span>{{end}}</span>
|
|
3
3
|
</template>
|
|
4
4
|
|
|
5
|
-
<script>
|
|
6
|
-
import
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
<script>
|
|
6
|
+
import * as __avueImportModule0 from "countup.js";
|
|
7
|
+
const CountUp = __avueImportModule0.default || __avueImportModule0;
|
|
8
|
+
import create from "../../../core/create.js";
|
|
9
|
+
|
|
10
|
+
export default create({
|
|
9
11
|
name: "count-up",
|
|
10
12
|
props: {
|
|
11
13
|
animation: {
|
|
@@ -104,4 +106,4 @@ export default create({
|
|
|
104
106
|
},
|
|
105
107
|
|
|
106
108
|
});
|
|
107
|
-
</script>
|
|
109
|
+
</script>
|
|
@@ -1,12 +1,46 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
/* eslint-disable */
|
|
3
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
4
|
+
if (k2 === undefined) k2 = k;
|
|
5
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
6
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
7
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
8
|
+
}
|
|
9
|
+
Object.defineProperty(o, k2, desc);
|
|
10
|
+
}) : (function(o, m, k, k2) {
|
|
11
|
+
if (k2 === undefined) k2 = k;
|
|
12
|
+
o[k2] = m[k];
|
|
13
|
+
}));
|
|
14
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
15
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
16
|
+
}) : function(o, v) {
|
|
17
|
+
o["default"] = v;
|
|
18
|
+
});
|
|
19
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
20
|
+
var ownKeys = function(o) {
|
|
21
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
22
|
+
var ar = [];
|
|
23
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
24
|
+
return ar;
|
|
25
|
+
};
|
|
26
|
+
return ownKeys(o);
|
|
27
|
+
};
|
|
28
|
+
return function (mod) {
|
|
29
|
+
if (mod && mod.__esModule) return mod;
|
|
30
|
+
var result = {};
|
|
31
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
32
|
+
__setModuleDefault(result, mod);
|
|
33
|
+
return result;
|
|
34
|
+
};
|
|
35
|
+
})();
|
|
3
36
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
37
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
38
|
};
|
|
6
39
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
40
|
const util_js_1 = require("../../utils/util.js");
|
|
8
41
|
const packages_js_1 = __importDefault(require("../../core/packages.js"));
|
|
9
|
-
const
|
|
42
|
+
const __avueImportModule0 = __importStar(require("dayjs"));
|
|
43
|
+
const dayjs = __avueImportModule0.default || __avueImportModule0;
|
|
10
44
|
const XLSX = window.XLSX;
|
|
11
45
|
exports.default = {
|
|
12
46
|
buildHeader(revealList) {
|
|
@@ -172,7 +206,7 @@ exports.default = {
|
|
|
172
206
|
prop: []
|
|
173
207
|
};
|
|
174
208
|
_params.header = this.buildHeader(params.columns);
|
|
175
|
-
_params.title = params.title || (
|
|
209
|
+
_params.title = params.title || dayjs().format('YYYY-MM-DD HH:mm:ss');
|
|
176
210
|
const callback = (list) => {
|
|
177
211
|
list.forEach((ele) => {
|
|
178
212
|
if (ele.children && ele.children instanceof Array) {
|
package/lib/utils/util.js
CHANGED
|
@@ -1,7 +1,37 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var
|
|
3
|
-
|
|
4
|
-
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
14
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
15
|
+
}) : function(o, v) {
|
|
16
|
+
o["default"] = v;
|
|
17
|
+
});
|
|
18
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
19
|
+
var ownKeys = function(o) {
|
|
20
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
21
|
+
var ar = [];
|
|
22
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
23
|
+
return ar;
|
|
24
|
+
};
|
|
25
|
+
return ownKeys(o);
|
|
26
|
+
};
|
|
27
|
+
return function (mod) {
|
|
28
|
+
if (mod && mod.__esModule) return mod;
|
|
29
|
+
var result = {};
|
|
30
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
31
|
+
__setModuleDefault(result, mod);
|
|
32
|
+
return result;
|
|
33
|
+
};
|
|
34
|
+
})();
|
|
5
35
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
36
|
exports.validData = exports.clearVal = exports.blankVal = exports.arraySort = exports.getPasswordChar = exports.findNode = exports.findArray = exports.filterParams = exports.getDicValue = exports.detailDataType = exports.setPx = exports.getColumn = exports.deepClone = exports.isJson = exports.getObjType = exports.loadScript = exports.uuid = exports.isMediaType = void 0;
|
|
7
37
|
exports.getFixed = getFixed;
|
|
@@ -15,9 +45,12 @@ exports.findObject = findObject;
|
|
|
15
45
|
exports.randomId = randomId;
|
|
16
46
|
const validate_js_1 = require("./validate.js");
|
|
17
47
|
const variable_js_1 = require("../global/variable.js");
|
|
18
|
-
const
|
|
19
|
-
const
|
|
20
|
-
const
|
|
48
|
+
const __avueImportModule0 = __importStar(require("lodash/get"));
|
|
49
|
+
const _get = __avueImportModule0.default || __avueImportModule0;
|
|
50
|
+
const __avueImportModule1 = __importStar(require("lodash/set"));
|
|
51
|
+
const _set = __avueImportModule1.default || __avueImportModule1;
|
|
52
|
+
const __avueImportModule2 = __importStar(require("lodash/cloneDeep"));
|
|
53
|
+
const _cloneDeep = __avueImportModule2.default || __avueImportModule2;
|
|
21
54
|
const isMediaType = (url, type) => {
|
|
22
55
|
if ((0, validate_js_1.validatenull)(url))
|
|
23
56
|
return;
|
|
@@ -52,10 +85,10 @@ function getAsVal(obj, bind = '') {
|
|
|
52
85
|
const result = (0, exports.deepClone)(obj);
|
|
53
86
|
if ((0, validate_js_1.validatenull)(bind))
|
|
54
87
|
return result;
|
|
55
|
-
return (
|
|
88
|
+
return _get(obj, bind);
|
|
56
89
|
}
|
|
57
90
|
function setAsVal(obj, bind = '', value) {
|
|
58
|
-
(
|
|
91
|
+
_set(obj, bind, value);
|
|
59
92
|
return obj;
|
|
60
93
|
}
|
|
61
94
|
const loadScript = (type = 'js', url, dom = 'body') => {
|
|
@@ -234,7 +267,7 @@ const isJson = (str) => {
|
|
|
234
267
|
};
|
|
235
268
|
exports.isJson = isJson;
|
|
236
269
|
const deepClone = (data) => {
|
|
237
|
-
return (
|
|
270
|
+
return _cloneDeep(data);
|
|
238
271
|
};
|
|
239
272
|
exports.deepClone = deepClone;
|
|
240
273
|
const getColumn = (column) => {
|
package/lib/version.js
CHANGED
package/lib/version.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
export const version = '3.8.
|
|
1
|
+
export const version = '3.8.5'
|