hfn-components 0.3.3 → 0.3.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/index.css +1 -1
- package/es/component.mjs +3 -1
- package/es/components/elTable/index.d.ts +22 -3
- package/es/components/elTable/src/columnDeal.vue.d.ts +13 -3
- package/es/components/elTable/src/columnDeal.vue.mjs +6 -3
- package/es/components/elTable/src/elTable.d.ts +6 -1
- package/es/components/elTable/src/elTable.mjs +4 -0
- package/es/components/elTable/src/elTable.vue.d.ts +22 -3
- package/es/components/elTable/src/elTable.vue.mjs +56 -6
- package/es/components/elTable/src/elTable.vue2.mjs +5 -0
- package/es/components/htTarget/index.d.ts +41 -14
- package/es/components/htTarget/src/htTarget.d.ts +17 -1
- package/es/components/htTarget/src/htTarget.mjs +11 -2
- package/es/components/htTarget/src/htTarget.vue.d.ts +41 -14
- package/es/components/htTarget/src/htTarget.vue.mjs +10 -6
- package/es/components/htTarget/src/htTarget.vue2.mjs +60 -15
- package/es/components/htTarget/style/index.d.ts +1 -0
- package/es/components/htTarget/style/index.mjs +1 -0
- package/es/constants/table.d.ts +1 -0
- package/es/constants/table.mjs +2 -1
- package/es/constants/target.d.ts +4 -10
- package/es/constants/target.mjs +34 -34
- package/package.json +1 -1
- package/theme-chalk/ht-target.css +1 -0
- package/theme-chalk/index.css +1 -1
- package/theme-chalk/src/index.scss +2 -1
- package/theme-chalk/src/target.scss +20 -0
package/dist/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.echart-box{display:flex;flex-direction:column;height:100%;position:relative;width:100%}.echart-content{flex:auto}.echart-lenged{box-sizing:border-box;display:flex;flex-wrap:wrap;font-size:12px;height:auto;margin-top:6px;padding-right:22px;position:relative;width:100%;z-index:999}.bg-span{height:2px;width:14px}.bg-span,.bg-span-bar{display:inline-block;margin-right:6px}.bg-span-bar{border-radius:2px;height:10px;width:16px}.span-box{cursor:pointer;margin-left:5px;margin-right:6px}.noData,.span-box{align-items:center;display:flex}.noData{bottom:0;color:#ccc;font-size:16px;justify-content:center;position:absolute}._100,.noData{height:100%;width:100%}
|
|
1
|
+
.echart-box{display:flex;flex-direction:column;height:100%;position:relative;width:100%}.echart-content{flex:auto}.echart-lenged{box-sizing:border-box;display:flex;flex-wrap:wrap;font-size:12px;height:auto;margin-top:6px;padding-right:22px;position:relative;width:100%;z-index:999}.bg-span{height:2px;width:14px}.bg-span,.bg-span-bar{display:inline-block;margin-right:6px}.bg-span-bar{border-radius:2px;height:10px;width:16px}.span-box{cursor:pointer;margin-left:5px;margin-right:6px}.noData,.span-box{align-items:center;display:flex}.noData{bottom:0;color:#ccc;font-size:16px;justify-content:center;position:absolute}._100,.noData{height:100%;width:100%}.dialog{padding:24px!important;width:860px!important}.factor-content{display:flex;flex-direction:column;flex-wrap:wrap;height:380px;width:100%}.factor_item{display:flex;margin-bottom:10px;width:33.33%}.check_item{display:flex;justify-content:space-between}
|
package/es/component.mjs
CHANGED
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import { HtElTable } from './components/elTable/index.mjs';
|
|
2
2
|
import { HtChart } from './components/chart/index.mjs';
|
|
3
3
|
import { HtPieChart } from './components/pieChart/index.mjs';
|
|
4
|
+
import { HtTarget } from './components/htTarget/index.mjs';
|
|
4
5
|
|
|
5
6
|
var Components = [
|
|
6
7
|
// HtTable,
|
|
7
8
|
HtChart,
|
|
8
9
|
HtElTable,
|
|
9
|
-
HtPieChart
|
|
10
|
+
HtPieChart,
|
|
11
|
+
HtTarget
|
|
10
12
|
];
|
|
11
13
|
|
|
12
14
|
export { Components as default };
|
|
@@ -706,9 +706,18 @@ export declare const HtElTable: import("hfn-components/es/utils").SFCWithInstall
|
|
|
706
706
|
readonly money_name: "金额(元)";
|
|
707
707
|
};
|
|
708
708
|
readonly convertKey: (data: any, key: string) => any;
|
|
709
|
+
readonly TARGET_HEAD_KEY: {
|
|
710
|
+
name: string;
|
|
711
|
+
key: string;
|
|
712
|
+
}[];
|
|
713
|
+
readonly TARGET_END_KEY: {
|
|
714
|
+
name: string;
|
|
715
|
+
key: string;
|
|
716
|
+
dealType: string;
|
|
717
|
+
}[];
|
|
709
718
|
ColumnDeal: import("vue").DefineComponent<{
|
|
710
719
|
readonly dealType: {
|
|
711
|
-
readonly type: import("vue").PropType<"
|
|
720
|
+
readonly type: import("vue").PropType<"colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot">;
|
|
712
721
|
readonly default: "";
|
|
713
722
|
};
|
|
714
723
|
readonly text: {
|
|
@@ -723,6 +732,10 @@ export declare const HtElTable: import("hfn-components/es/utils").SFCWithInstall
|
|
|
723
732
|
readonly type: ObjectConstructor;
|
|
724
733
|
readonly default: () => void;
|
|
725
734
|
};
|
|
735
|
+
readonly slot: {
|
|
736
|
+
readonly type: StringConstructor;
|
|
737
|
+
readonly default: "";
|
|
738
|
+
};
|
|
726
739
|
}, {
|
|
727
740
|
readonly CLOUMN_DEAL: {
|
|
728
741
|
basicText4: (val: string | number | undefined) => string;
|
|
@@ -736,10 +749,11 @@ export declare const HtElTable: import("hfn-components/es/utils").SFCWithInstall
|
|
|
736
749
|
notProcessed: null;
|
|
737
750
|
other: null;
|
|
738
751
|
customDeal: null;
|
|
752
|
+
customSlot: null;
|
|
739
753
|
};
|
|
740
754
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
741
755
|
readonly dealType: {
|
|
742
|
-
readonly type: import("vue").PropType<"
|
|
756
|
+
readonly type: import("vue").PropType<"colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot">;
|
|
743
757
|
readonly default: "";
|
|
744
758
|
};
|
|
745
759
|
readonly text: {
|
|
@@ -754,11 +768,16 @@ export declare const HtElTable: import("hfn-components/es/utils").SFCWithInstall
|
|
|
754
768
|
readonly type: ObjectConstructor;
|
|
755
769
|
readonly default: () => void;
|
|
756
770
|
};
|
|
771
|
+
readonly slot: {
|
|
772
|
+
readonly type: StringConstructor;
|
|
773
|
+
readonly default: "";
|
|
774
|
+
};
|
|
757
775
|
}>>, {
|
|
758
776
|
readonly text: string | number | undefined;
|
|
759
|
-
readonly dealType: "
|
|
777
|
+
readonly dealType: "colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot";
|
|
760
778
|
readonly dealFunction: Function;
|
|
761
779
|
readonly row: Record<string, any>;
|
|
780
|
+
readonly slot: string;
|
|
762
781
|
}, {}>;
|
|
763
782
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
764
783
|
readonly dataSource: {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
declare const _default: import("vue").DefineComponent<{
|
|
2
2
|
readonly dealType: {
|
|
3
|
-
readonly type: import("vue").PropType<"
|
|
3
|
+
readonly type: import("vue").PropType<"colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot">;
|
|
4
4
|
readonly default: "";
|
|
5
5
|
};
|
|
6
6
|
readonly text: {
|
|
@@ -15,6 +15,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
15
15
|
readonly type: ObjectConstructor;
|
|
16
16
|
readonly default: () => void;
|
|
17
17
|
};
|
|
18
|
+
readonly slot: {
|
|
19
|
+
readonly type: StringConstructor;
|
|
20
|
+
readonly default: "";
|
|
21
|
+
};
|
|
18
22
|
}, {
|
|
19
23
|
readonly CLOUMN_DEAL: {
|
|
20
24
|
basicText4: (val: string | number | undefined) => string;
|
|
@@ -28,10 +32,11 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
28
32
|
notProcessed: null;
|
|
29
33
|
other: null;
|
|
30
34
|
customDeal: null;
|
|
35
|
+
customSlot: null;
|
|
31
36
|
};
|
|
32
37
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
33
38
|
readonly dealType: {
|
|
34
|
-
readonly type: import("vue").PropType<"
|
|
39
|
+
readonly type: import("vue").PropType<"colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot">;
|
|
35
40
|
readonly default: "";
|
|
36
41
|
};
|
|
37
42
|
readonly text: {
|
|
@@ -46,10 +51,15 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
46
51
|
readonly type: ObjectConstructor;
|
|
47
52
|
readonly default: () => void;
|
|
48
53
|
};
|
|
54
|
+
readonly slot: {
|
|
55
|
+
readonly type: StringConstructor;
|
|
56
|
+
readonly default: "";
|
|
57
|
+
};
|
|
49
58
|
}>>, {
|
|
50
59
|
readonly text: string | number | undefined;
|
|
51
|
-
readonly dealType: "
|
|
60
|
+
readonly dealType: "colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot";
|
|
52
61
|
readonly dealFunction: Function;
|
|
53
62
|
readonly row: Record<string, any>;
|
|
63
|
+
readonly slot: string;
|
|
54
64
|
}, {}>;
|
|
55
65
|
export default _default;
|
|
@@ -1,11 +1,12 @@
|
|
|
1
1
|
import _sfc_main from './columnDeal.vue2.mjs';
|
|
2
|
-
import { openBlock, createElementBlock, toDisplayString, createElementVNode, normalizeStyle } from 'vue';
|
|
2
|
+
import { openBlock, createElementBlock, toDisplayString, createElementVNode, normalizeStyle, renderSlot } from 'vue';
|
|
3
3
|
import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.mjs';
|
|
4
4
|
|
|
5
5
|
const _hoisted_1 = { key: 0 };
|
|
6
6
|
const _hoisted_2 = { key: 1 };
|
|
7
7
|
const _hoisted_3 = ["innerHTML"];
|
|
8
8
|
const _hoisted_4 = { key: 3 };
|
|
9
|
+
const _hoisted_5 = { key: 4 };
|
|
9
10
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
10
11
|
return _ctx.dealType === "notProcessed" || _ctx.dealType === "other" ? (openBlock(), createElementBlock(
|
|
11
12
|
"div",
|
|
@@ -26,9 +27,11 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
26
27
|
])) : _ctx.dealType === "customDeal" ? (openBlock(), createElementBlock("div", {
|
|
27
28
|
key: 2,
|
|
28
29
|
innerHTML: _ctx.dealFunction(_ctx.row, _ctx.text)
|
|
29
|
-
}, null, 8, _hoisted_3)) : (openBlock(), createElementBlock(
|
|
30
|
+
}, null, 8, _hoisted_3)) : _ctx.dealType === "customSlot" ? (openBlock(), createElementBlock("div", _hoisted_4, [
|
|
31
|
+
renderSlot(_ctx.$slots, _ctx.slot)
|
|
32
|
+
])) : (openBlock(), createElementBlock(
|
|
30
33
|
"div",
|
|
31
|
-
|
|
34
|
+
_hoisted_5,
|
|
32
35
|
toDisplayString(_ctx.text !== void 0 ? $setup.CLOUMN_DEAL[_ctx.dealType](_ctx.text) : "-"),
|
|
33
36
|
1
|
|
34
37
|
/* TEXT */
|
|
@@ -6,6 +6,7 @@ export interface ElTableColumns {
|
|
|
6
6
|
dealFunction?: Function;
|
|
7
7
|
width: string | number;
|
|
8
8
|
customizeLabel?: string;
|
|
9
|
+
slot?: string;
|
|
9
10
|
}
|
|
10
11
|
export declare const elTableProps: {
|
|
11
12
|
readonly dataSource: {
|
|
@@ -27,7 +28,7 @@ export declare const elTableProps: {
|
|
|
27
28
|
};
|
|
28
29
|
export declare const columnDealProps: {
|
|
29
30
|
readonly dealType: {
|
|
30
|
-
readonly type: PropType<"
|
|
31
|
+
readonly type: PropType<"colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot">;
|
|
31
32
|
readonly default: "";
|
|
32
33
|
};
|
|
33
34
|
readonly text: {
|
|
@@ -42,6 +43,10 @@ export declare const columnDealProps: {
|
|
|
42
43
|
readonly type: ObjectConstructor;
|
|
43
44
|
readonly default: () => void;
|
|
44
45
|
};
|
|
46
|
+
readonly slot: {
|
|
47
|
+
readonly type: StringConstructor;
|
|
48
|
+
readonly default: "";
|
|
49
|
+
};
|
|
45
50
|
};
|
|
46
51
|
export type ElTableProps = ExtractPropTypes<typeof elTableProps>;
|
|
47
52
|
export type ColumnDealProps = ExtractPropTypes<typeof columnDealProps>;
|
|
@@ -706,9 +706,18 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
706
706
|
readonly money_name: "金额(元)";
|
|
707
707
|
};
|
|
708
708
|
readonly convertKey: (data: any, key: string) => any;
|
|
709
|
+
readonly TARGET_HEAD_KEY: {
|
|
710
|
+
name: string;
|
|
711
|
+
key: string;
|
|
712
|
+
}[];
|
|
713
|
+
readonly TARGET_END_KEY: {
|
|
714
|
+
name: string;
|
|
715
|
+
key: string;
|
|
716
|
+
dealType: string;
|
|
717
|
+
}[];
|
|
709
718
|
ColumnDeal: import("vue").DefineComponent<{
|
|
710
719
|
readonly dealType: {
|
|
711
|
-
readonly type: import("vue").PropType<"
|
|
720
|
+
readonly type: import("vue").PropType<"colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot">;
|
|
712
721
|
readonly default: "";
|
|
713
722
|
};
|
|
714
723
|
readonly text: {
|
|
@@ -723,6 +732,10 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
723
732
|
readonly type: ObjectConstructor;
|
|
724
733
|
readonly default: () => void;
|
|
725
734
|
};
|
|
735
|
+
readonly slot: {
|
|
736
|
+
readonly type: StringConstructor;
|
|
737
|
+
readonly default: "";
|
|
738
|
+
};
|
|
726
739
|
}, {
|
|
727
740
|
readonly CLOUMN_DEAL: {
|
|
728
741
|
basicText4: (val: string | number | undefined) => string;
|
|
@@ -736,10 +749,11 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
736
749
|
notProcessed: null;
|
|
737
750
|
other: null;
|
|
738
751
|
customDeal: null;
|
|
752
|
+
customSlot: null;
|
|
739
753
|
};
|
|
740
754
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
741
755
|
readonly dealType: {
|
|
742
|
-
readonly type: import("vue").PropType<"
|
|
756
|
+
readonly type: import("vue").PropType<"colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot">;
|
|
743
757
|
readonly default: "";
|
|
744
758
|
};
|
|
745
759
|
readonly text: {
|
|
@@ -754,11 +768,16 @@ declare const _default: import("vue").DefineComponent<{
|
|
|
754
768
|
readonly type: ObjectConstructor;
|
|
755
769
|
readonly default: () => void;
|
|
756
770
|
};
|
|
771
|
+
readonly slot: {
|
|
772
|
+
readonly type: StringConstructor;
|
|
773
|
+
readonly default: "";
|
|
774
|
+
};
|
|
757
775
|
}>>, {
|
|
758
776
|
readonly text: string | number | undefined;
|
|
759
|
-
readonly dealType: "
|
|
777
|
+
readonly dealType: "colorPercentage" | "percentage" | "basicText4" | "notProcessed" | "colorText" | "percentage4" | "absPercentage" | "thoundsandText2" | "thoundsandText4" | "other" | "customDeal" | "customSlot";
|
|
760
778
|
readonly dealFunction: Function;
|
|
761
779
|
readonly row: Record<string, any>;
|
|
780
|
+
readonly slot: string;
|
|
762
781
|
}, {}>;
|
|
763
782
|
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {}, string, import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
764
783
|
readonly dataSource: {
|
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import _sfc_main from './elTable.vue2.mjs';
|
|
2
|
-
import { withDirectives, openBlock, createBlock, withCtx, createElementBlock, Fragment, renderList } from 'vue';
|
|
2
|
+
import { withDirectives, openBlock, createBlock, withCtx, createElementBlock, Fragment, renderList, createElementVNode, toDisplayString, renderSlot } from 'vue';
|
|
3
3
|
import _export_sfc from '../../../_virtual/_plugin-vue_export-helper.mjs';
|
|
4
4
|
|
|
5
|
+
const _hoisted_1 = { key: 0 };
|
|
6
|
+
const _hoisted_2 = { key: 0 };
|
|
7
|
+
const _hoisted_3 = { key: 1 };
|
|
8
|
+
const _hoisted_4 = { key: 1 };
|
|
5
9
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
6
10
|
return withDirectives((openBlock(), createBlock($setup["ElTable"], {
|
|
7
11
|
data: $setup.props.dataSource,
|
|
@@ -23,17 +27,63 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
23
27
|
resizable: "",
|
|
24
28
|
key: item.key,
|
|
25
29
|
prop: item.key,
|
|
26
|
-
label: item.customizeLabel ? item.customizeLabel : $setup.TABLE_KEY[item.key],
|
|
27
30
|
width: item.width
|
|
28
31
|
}, {
|
|
32
|
+
header: withCtx(() => [
|
|
33
|
+
item.customizeLabel ? (openBlock(), createElementBlock("span", _hoisted_1, [
|
|
34
|
+
item.customizeLabel === "target" ? (openBlock(), createElementBlock("div", _hoisted_2, [
|
|
35
|
+
createElementVNode(
|
|
36
|
+
"div",
|
|
37
|
+
null,
|
|
38
|
+
toDisplayString($setup.TARGET_HEAD_KEY.filter((items) => items.key === item.key.split("_")[0])[0].name),
|
|
39
|
+
1
|
|
40
|
+
/* TEXT */
|
|
41
|
+
),
|
|
42
|
+
createElementVNode(
|
|
43
|
+
"div",
|
|
44
|
+
null,
|
|
45
|
+
toDisplayString($setup.TARGET_END_KEY.filter((items) => items.key === item.key.split("_")[1])[0].name),
|
|
46
|
+
1
|
|
47
|
+
/* TEXT */
|
|
48
|
+
)
|
|
49
|
+
])) : (openBlock(), createElementBlock(
|
|
50
|
+
"div",
|
|
51
|
+
_hoisted_3,
|
|
52
|
+
toDisplayString(item.customizeLabel),
|
|
53
|
+
1
|
|
54
|
+
/* TEXT */
|
|
55
|
+
))
|
|
56
|
+
])) : (openBlock(), createElementBlock("span", _hoisted_4, [
|
|
57
|
+
createElementVNode(
|
|
58
|
+
"div",
|
|
59
|
+
null,
|
|
60
|
+
toDisplayString($setup.TABLE_KEY[item.key]),
|
|
61
|
+
1
|
|
62
|
+
/* TEXT */
|
|
63
|
+
)
|
|
64
|
+
]))
|
|
65
|
+
]),
|
|
29
66
|
default: withCtx((scope) => [
|
|
30
67
|
item.dealType === "other" ? (openBlock(), createBlock($setup["ColumnDeal"], {
|
|
31
68
|
key: 0,
|
|
32
69
|
dealType: scope.row.dealType,
|
|
33
70
|
text: $setup.convertKey(scope.row, item.key)
|
|
34
|
-
}, null, 8, ["dealType", "text"])) : (openBlock(), createBlock($setup["ColumnDeal"], {
|
|
71
|
+
}, null, 8, ["dealType", "text"])) : item.dealType === "customSlot" ? (openBlock(), createBlock($setup["ColumnDeal"], {
|
|
35
72
|
key: 1,
|
|
36
73
|
dealType: item.dealType,
|
|
74
|
+
slot: item.slot
|
|
75
|
+
}, {
|
|
76
|
+
[item.slot]: withCtx(() => [
|
|
77
|
+
renderSlot(_ctx.$slots, item.slot, {
|
|
78
|
+
text: $setup.convertKey(scope.row, item.key),
|
|
79
|
+
row: scope.row
|
|
80
|
+
})
|
|
81
|
+
]),
|
|
82
|
+
_: 2
|
|
83
|
+
/* DYNAMIC */
|
|
84
|
+
}, 1032, ["dealType", "slot"])) : (openBlock(), createBlock($setup["ColumnDeal"], {
|
|
85
|
+
key: 2,
|
|
86
|
+
dealType: item.dealType,
|
|
37
87
|
text: $setup.convertKey(scope.row, item.key),
|
|
38
88
|
row: scope.row,
|
|
39
89
|
"deal-function": item.dealFunction
|
|
@@ -41,14 +91,14 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
41
91
|
]),
|
|
42
92
|
_: 2
|
|
43
93
|
/* DYNAMIC */
|
|
44
|
-
}, 1032, ["prop", "
|
|
94
|
+
}, 1032, ["prop", "width"]);
|
|
45
95
|
}),
|
|
46
96
|
128
|
|
47
97
|
/* KEYED_FRAGMENT */
|
|
48
98
|
))
|
|
49
99
|
]),
|
|
50
|
-
_:
|
|
51
|
-
/*
|
|
100
|
+
_: 3
|
|
101
|
+
/* FORWARDED */
|
|
52
102
|
}, 8, ["data", "header-cell-style"])), [
|
|
53
103
|
[$setup["vLoading"], $setup.props.loading]
|
|
54
104
|
]);
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { defineComponent } from 'vue';
|
|
2
2
|
import { ElTable, ElTableColumn, vLoading } from 'element-plus';
|
|
3
3
|
import { TABLE_KEY, convertKey } from '../../../constants/table.mjs';
|
|
4
|
+
import { TARGET_HEAD_KEY, TARGET_END_KEY } from '../../../constants/target.mjs';
|
|
4
5
|
import '../../../constants/chartConfig.mjs';
|
|
5
6
|
import ColumnDeal from './columnDeal.vue.mjs';
|
|
6
7
|
import { elTableProps } from './elTable.mjs';
|
|
@@ -21,6 +22,10 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
21
22
|
return TABLE_KEY;
|
|
22
23
|
}, get convertKey() {
|
|
23
24
|
return convertKey;
|
|
25
|
+
}, get TARGET_HEAD_KEY() {
|
|
26
|
+
return TARGET_HEAD_KEY;
|
|
27
|
+
}, get TARGET_END_KEY() {
|
|
28
|
+
return TARGET_END_KEY;
|
|
24
29
|
}, ColumnDeal };
|
|
25
30
|
Object.defineProperty(__returned__, "__isScriptSetup", { enumerable: false, value: true });
|
|
26
31
|
return __returned__;
|
|
@@ -1,31 +1,43 @@
|
|
|
1
|
-
export declare const HtTarget: import("hfn-components/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
1
|
+
export declare const HtTarget: import("hfn-components/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
2
|
+
readonly dialogShow: {
|
|
3
|
+
readonly type: BooleanConstructor;
|
|
4
|
+
readonly default: false;
|
|
5
|
+
};
|
|
6
|
+
readonly targetData: {
|
|
7
|
+
readonly type: import("vue").PropType<import("./src/htTarget").target[]>;
|
|
8
|
+
readonly default: readonly [];
|
|
9
|
+
};
|
|
10
|
+
}, {
|
|
11
|
+
props: import("@vue/shared").LooseRequired<{
|
|
12
|
+
readonly targetData: import("./src/htTarget").target[];
|
|
13
|
+
readonly dialogShow: boolean;
|
|
14
|
+
readonly onChoiceTarget?: ((...args: any[]) => any) | undefined;
|
|
15
|
+
readonly onChoiceCancel?: ((...args: any[]) => any) | undefined;
|
|
16
|
+
} & {}>;
|
|
17
|
+
emit: (event: "choiceTarget" | "choiceCancel", ...args: any[]) => void;
|
|
2
18
|
targetHead: import("vue").Ref<{
|
|
3
19
|
name: string;
|
|
4
20
|
key: string;
|
|
5
21
|
}[]>;
|
|
6
|
-
allfoot: import("vue").Ref<
|
|
7
|
-
name: string;
|
|
8
|
-
key: string;
|
|
9
|
-
slot: string;
|
|
10
|
-
excludeKey?: undefined;
|
|
11
|
-
} | {
|
|
22
|
+
allfoot: import("vue").Ref<{
|
|
12
23
|
name: string;
|
|
13
24
|
key: string;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
})[]>;
|
|
25
|
+
dealType: string;
|
|
26
|
+
}[]>;
|
|
17
27
|
selectedHead: import("vue").Ref<string>;
|
|
18
28
|
checkList: import("vue").Ref<string[]>;
|
|
29
|
+
dialogShow: import("vue").Ref<boolean>;
|
|
19
30
|
typeTag: import("vue").Ref<string>;
|
|
20
|
-
aaa: import("vue").Ref<boolean>;
|
|
21
31
|
headChange: () => void;
|
|
22
32
|
selectedTree: import("vue").Ref<Record<string, string[]>>;
|
|
23
33
|
selectedList: import("vue").Ref<{
|
|
24
34
|
name: string;
|
|
25
35
|
key: string;
|
|
36
|
+
dealType: string;
|
|
26
37
|
}[]>;
|
|
27
|
-
selectedTarget: (val: string, type: string) => void;
|
|
38
|
+
selectedTarget: (val: string, headKey: string, type: string) => void;
|
|
28
39
|
deleteItem: (key: string) => void;
|
|
40
|
+
confirmTarge: () => void;
|
|
29
41
|
readonly ElDialog: import("element-plus/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
30
42
|
readonly appendToBody: BooleanConstructor;
|
|
31
43
|
readonly appendTo: import("element-plus/es/utils").EpPropFinalized<(new (...args: any[]) => string & {}) | (() => string) | ((new (...args: any[]) => string & {}) | (() => string))[], unknown, unknown, "body", boolean>;
|
|
@@ -1972,8 +1984,23 @@ export declare const HtTarget: import("hfn-components/es/utils").SFCWithInstall<
|
|
|
1972
1984
|
readonly BASIC_KEY: {
|
|
1973
1985
|
name: string;
|
|
1974
1986
|
key: string;
|
|
1975
|
-
|
|
1987
|
+
dealType: string;
|
|
1976
1988
|
}[];
|
|
1977
|
-
},
|
|
1989
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("choiceTarget" | "choiceCancel")[], "choiceTarget" | "choiceCancel", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
1990
|
+
readonly dialogShow: {
|
|
1991
|
+
readonly type: BooleanConstructor;
|
|
1992
|
+
readonly default: false;
|
|
1993
|
+
};
|
|
1994
|
+
readonly targetData: {
|
|
1995
|
+
readonly type: import("vue").PropType<import("./src/htTarget").target[]>;
|
|
1996
|
+
readonly default: readonly [];
|
|
1997
|
+
};
|
|
1998
|
+
}>> & {
|
|
1999
|
+
onChoiceTarget?: ((...args: any[]) => any) | undefined;
|
|
2000
|
+
onChoiceCancel?: ((...args: any[]) => any) | undefined;
|
|
2001
|
+
}, {
|
|
2002
|
+
readonly targetData: import("./src/htTarget").target[];
|
|
2003
|
+
readonly dialogShow: boolean;
|
|
2004
|
+
}, {}>> & Record<string, any>;
|
|
1978
2005
|
export default HtTarget;
|
|
1979
2006
|
export * from './src/htTarget.vue';
|
|
@@ -1 +1,17 @@
|
|
|
1
|
-
|
|
1
|
+
import { ExtractPropTypes, PropType } from 'vue';
|
|
2
|
+
export interface target {
|
|
3
|
+
name: string;
|
|
4
|
+
key: string;
|
|
5
|
+
dealType: string;
|
|
6
|
+
}
|
|
7
|
+
export declare const targetProps: {
|
|
8
|
+
readonly dialogShow: {
|
|
9
|
+
readonly type: BooleanConstructor;
|
|
10
|
+
readonly default: false;
|
|
11
|
+
};
|
|
12
|
+
readonly targetData: {
|
|
13
|
+
readonly type: PropType<target[]>;
|
|
14
|
+
readonly default: readonly [];
|
|
15
|
+
};
|
|
16
|
+
};
|
|
17
|
+
export type TargetProps = ExtractPropTypes<typeof targetProps>;
|
|
@@ -1,31 +1,43 @@
|
|
|
1
|
-
declare const _default: import("vue").DefineComponent<{
|
|
1
|
+
declare const _default: import("vue").DefineComponent<{
|
|
2
|
+
readonly dialogShow: {
|
|
3
|
+
readonly type: BooleanConstructor;
|
|
4
|
+
readonly default: false;
|
|
5
|
+
};
|
|
6
|
+
readonly targetData: {
|
|
7
|
+
readonly type: import("vue").PropType<import("./htTarget").target[]>;
|
|
8
|
+
readonly default: readonly [];
|
|
9
|
+
};
|
|
10
|
+
}, {
|
|
11
|
+
props: import("@vue/shared").LooseRequired<{
|
|
12
|
+
readonly targetData: import("./htTarget").target[];
|
|
13
|
+
readonly dialogShow: boolean;
|
|
14
|
+
readonly onChoiceTarget?: ((...args: any[]) => any) | undefined;
|
|
15
|
+
readonly onChoiceCancel?: ((...args: any[]) => any) | undefined;
|
|
16
|
+
} & {}>;
|
|
17
|
+
emit: (event: "choiceTarget" | "choiceCancel", ...args: any[]) => void;
|
|
2
18
|
targetHead: import("vue").Ref<{
|
|
3
19
|
name: string;
|
|
4
20
|
key: string;
|
|
5
21
|
}[]>;
|
|
6
|
-
allfoot: import("vue").Ref<
|
|
7
|
-
name: string;
|
|
8
|
-
key: string;
|
|
9
|
-
slot: string;
|
|
10
|
-
excludeKey?: undefined;
|
|
11
|
-
} | {
|
|
22
|
+
allfoot: import("vue").Ref<{
|
|
12
23
|
name: string;
|
|
13
24
|
key: string;
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
})[]>;
|
|
25
|
+
dealType: string;
|
|
26
|
+
}[]>;
|
|
17
27
|
selectedHead: import("vue").Ref<string>;
|
|
18
28
|
checkList: import("vue").Ref<string[]>;
|
|
29
|
+
dialogShow: import("vue").Ref<boolean>;
|
|
19
30
|
typeTag: import("vue").Ref<string>;
|
|
20
|
-
aaa: import("vue").Ref<boolean>;
|
|
21
31
|
headChange: () => void;
|
|
22
32
|
selectedTree: import("vue").Ref<Record<string, string[]>>;
|
|
23
33
|
selectedList: import("vue").Ref<{
|
|
24
34
|
name: string;
|
|
25
35
|
key: string;
|
|
36
|
+
dealType: string;
|
|
26
37
|
}[]>;
|
|
27
|
-
selectedTarget: (val: string, type: string) => void;
|
|
38
|
+
selectedTarget: (val: string, headKey: string, type: string) => void;
|
|
28
39
|
deleteItem: (key: string) => void;
|
|
40
|
+
confirmTarge: () => void;
|
|
29
41
|
readonly ElDialog: import("element-plus/es/utils").SFCWithInstall<import("vue").DefineComponent<{
|
|
30
42
|
readonly appendToBody: BooleanConstructor;
|
|
31
43
|
readonly appendTo: import("element-plus/es/utils").EpPropFinalized<(new (...args: any[]) => string & {}) | (() => string) | ((new (...args: any[]) => string & {}) | (() => string))[], unknown, unknown, "body", boolean>;
|
|
@@ -1972,7 +1984,22 @@ declare const _default: import("vue").DefineComponent<{}, {
|
|
|
1972
1984
|
readonly BASIC_KEY: {
|
|
1973
1985
|
name: string;
|
|
1974
1986
|
key: string;
|
|
1975
|
-
|
|
1987
|
+
dealType: string;
|
|
1976
1988
|
}[];
|
|
1977
|
-
},
|
|
1989
|
+
}, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, ("choiceTarget" | "choiceCancel")[], "choiceTarget" | "choiceCancel", import("vue").PublicProps, Readonly<import("vue").ExtractPropTypes<{
|
|
1990
|
+
readonly dialogShow: {
|
|
1991
|
+
readonly type: BooleanConstructor;
|
|
1992
|
+
readonly default: false;
|
|
1993
|
+
};
|
|
1994
|
+
readonly targetData: {
|
|
1995
|
+
readonly type: import("vue").PropType<import("./htTarget").target[]>;
|
|
1996
|
+
readonly default: readonly [];
|
|
1997
|
+
};
|
|
1998
|
+
}>> & {
|
|
1999
|
+
onChoiceTarget?: ((...args: any[]) => any) | undefined;
|
|
2000
|
+
onChoiceCancel?: ((...args: any[]) => any) | undefined;
|
|
2001
|
+
}, {
|
|
2002
|
+
readonly targetData: import("./htTarget").target[];
|
|
2003
|
+
readonly dialogShow: boolean;
|
|
2004
|
+
}, {}>;
|
|
1978
2005
|
export default _default;
|
|
@@ -17,13 +17,17 @@ const _hoisted_6 = { class: "dialog-footer" };
|
|
|
17
17
|
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
18
18
|
return openBlock(), createElementBlock("div", null, [
|
|
19
19
|
createVNode($setup["ElDialog"], {
|
|
20
|
-
modelValue: $setup.
|
|
21
|
-
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => $setup.
|
|
22
|
-
class: "dialog"
|
|
20
|
+
modelValue: $setup.dialogShow,
|
|
21
|
+
"onUpdate:modelValue": _cache[4] || (_cache[4] = ($event) => $setup.dialogShow = $event),
|
|
22
|
+
class: "dialog",
|
|
23
|
+
onClose: _cache[5] || (_cache[5] = ($event) => $setup.emit("choiceCancel"))
|
|
23
24
|
}, {
|
|
24
25
|
footer: withCtx(() => [
|
|
25
26
|
createElementVNode("div", _hoisted_6, [
|
|
26
|
-
createVNode($setup["ElButton"], {
|
|
27
|
+
createVNode($setup["ElButton"], {
|
|
28
|
+
onClick: $setup.confirmTarge,
|
|
29
|
+
type: "primary"
|
|
30
|
+
}, {
|
|
27
31
|
default: withCtx(() => [
|
|
28
32
|
createTextVNode(" Confirm ")
|
|
29
33
|
]),
|
|
@@ -105,7 +109,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
105
109
|
key: item.key
|
|
106
110
|
}, [
|
|
107
111
|
createVNode($setup["ElCheckbox"], {
|
|
108
|
-
onChange: ($event) => $setup.selectedTarget(item.key, "target"),
|
|
112
|
+
onChange: ($event) => $setup.selectedTarget(item.key, $setup.selectedHead, "target"),
|
|
109
113
|
disabled: $setup.checkList.includes(item.key),
|
|
110
114
|
label: item.name,
|
|
111
115
|
value: item.key
|
|
@@ -136,7 +140,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
|
|
136
140
|
key: item.key
|
|
137
141
|
}, [
|
|
138
142
|
createVNode($setup["ElCheckbox"], {
|
|
139
|
-
onChange: ($event) => $setup.selectedTarget(item.key, "basic"),
|
|
143
|
+
onChange: ($event) => $setup.selectedTarget(item.key, $setup.selectedHead, "basic"),
|
|
140
144
|
disabled: $setup.checkList.includes(item.key),
|
|
141
145
|
label: item.name,
|
|
142
146
|
value: item.key
|
|
@@ -1,19 +1,24 @@
|
|
|
1
|
-
import { defineComponent, ref, onMounted } from 'vue';
|
|
1
|
+
import { defineComponent, ref, onMounted, watch } from 'vue';
|
|
2
2
|
import { ElDialog, ElButton, ElRow, ElCol, ElRadioGroup, ElRadio, ElCheckboxGroup, ElCheckbox, ElRadioButton } from 'element-plus';
|
|
3
|
+
import { targetProps } from './htTarget.mjs';
|
|
3
4
|
import { TARGET_HEAD_KEY, TARGET_END_KEY, BASIC_KEY } from '../../../constants/target.mjs';
|
|
4
5
|
import '../../../constants/chartConfig.mjs';
|
|
5
6
|
import cloneDeep from 'lodash.clonedeep';
|
|
6
7
|
|
|
7
8
|
var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
8
9
|
__name: "htTarget",
|
|
9
|
-
|
|
10
|
+
props: targetProps,
|
|
11
|
+
emits: ["choiceTarget", "choiceCancel"],
|
|
12
|
+
setup(__props, { expose: __expose, emit: __emit }) {
|
|
10
13
|
__expose();
|
|
14
|
+
const props = __props;
|
|
15
|
+
const emit = __emit;
|
|
11
16
|
const targetHead = ref(cloneDeep(TARGET_HEAD_KEY));
|
|
12
17
|
const allfoot = ref(cloneDeep(TARGET_END_KEY));
|
|
13
18
|
const selectedHead = ref("lastOneMonth");
|
|
14
19
|
const checkList = ref([]);
|
|
20
|
+
const dialogShow = ref(false);
|
|
15
21
|
const typeTag = ref("target");
|
|
16
|
-
const aaa = ref(true);
|
|
17
22
|
onMounted(() => {
|
|
18
23
|
let startYear = 2018;
|
|
19
24
|
const nowYear = (/* @__PURE__ */ new Date()).getFullYear();
|
|
@@ -25,7 +30,36 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
25
30
|
startYear++;
|
|
26
31
|
}
|
|
27
32
|
});
|
|
33
|
+
watch(
|
|
34
|
+
() => props.dialogShow,
|
|
35
|
+
(val) => {
|
|
36
|
+
dialogShow.value = val;
|
|
37
|
+
}
|
|
38
|
+
);
|
|
39
|
+
watch(
|
|
40
|
+
() => props.targetData,
|
|
41
|
+
(val) => {
|
|
42
|
+
val.forEach((item) => {
|
|
43
|
+
if (item.key.startsWith("basic_")) {
|
|
44
|
+
const strSplit = item.key.split("_");
|
|
45
|
+
selectedTarget(strSplit[1], "", "basic");
|
|
46
|
+
} else {
|
|
47
|
+
const strSplit = item.key.split("_");
|
|
48
|
+
selectedTarget(strSplit[1], strSplit[0], "target");
|
|
49
|
+
}
|
|
50
|
+
});
|
|
51
|
+
},
|
|
52
|
+
{ deep: true }
|
|
53
|
+
);
|
|
28
54
|
const headChange = () => {
|
|
55
|
+
if (selectedHead.value === "thisWeek" || selectedHead.value === "thisMonth") {
|
|
56
|
+
allfoot.value = [
|
|
57
|
+
{ name: "\u6536\u76CA", key: "return", dealType: "color_text_precent" },
|
|
58
|
+
{ name: "\u5E74\u5316\u6536\u76CA", key: "yearReturn", dealType: "color_text_precent" }
|
|
59
|
+
];
|
|
60
|
+
} else {
|
|
61
|
+
allfoot.value = cloneDeep(TARGET_END_KEY);
|
|
62
|
+
}
|
|
29
63
|
if (selectedTree.value[selectedHead.value]) {
|
|
30
64
|
checkList.value = selectedTree.value[selectedHead.value];
|
|
31
65
|
} else {
|
|
@@ -34,24 +68,26 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
34
68
|
};
|
|
35
69
|
const selectedTree = ref({});
|
|
36
70
|
const selectedList = ref([]);
|
|
37
|
-
const selectedTarget = (val, type) => {
|
|
71
|
+
const selectedTarget = (val, headKey, type) => {
|
|
38
72
|
let itemObj = {
|
|
39
73
|
name: "",
|
|
40
|
-
key: ""
|
|
74
|
+
key: "",
|
|
75
|
+
dealType: ""
|
|
41
76
|
};
|
|
42
77
|
if (type === "target") {
|
|
43
|
-
if (selectedTree.value[
|
|
44
|
-
selectedTree.value[
|
|
78
|
+
if (selectedTree.value[headKey]) {
|
|
79
|
+
selectedTree.value[headKey].push(val);
|
|
45
80
|
} else {
|
|
46
|
-
selectedTree.value[
|
|
81
|
+
selectedTree.value[headKey] = [val];
|
|
47
82
|
}
|
|
48
|
-
const filterHead = TARGET_HEAD_KEY.filter((item) => item.key ===
|
|
83
|
+
const filterHead = TARGET_HEAD_KEY.filter((item) => item.key === headKey);
|
|
49
84
|
const filterFoot = TARGET_END_KEY.filter((item) => item.key === val);
|
|
50
85
|
const headName = filterHead.length > 0 ? filterHead[0].name : "";
|
|
51
86
|
const footName = filterFoot.length > 0 ? filterFoot[0].name : "";
|
|
52
87
|
itemObj = {
|
|
53
88
|
name: headName + footName,
|
|
54
|
-
key: `${
|
|
89
|
+
key: `${headKey}_${val}`,
|
|
90
|
+
dealType: footName ? filterFoot[0].dealType : ""
|
|
55
91
|
};
|
|
56
92
|
}
|
|
57
93
|
if (type === "basic") {
|
|
@@ -64,22 +100,31 @@ var _sfc_main = /* @__PURE__ */ defineComponent({
|
|
|
64
100
|
const footName = filterFoot.length > 0 ? filterFoot[0].name : "";
|
|
65
101
|
itemObj = {
|
|
66
102
|
name: footName,
|
|
67
|
-
key: `
|
|
103
|
+
key: `basic_${val}`,
|
|
104
|
+
dealType: footName ? filterFoot[0].dealType : ""
|
|
68
105
|
};
|
|
69
106
|
}
|
|
70
107
|
selectedList.value.push(itemObj);
|
|
71
108
|
};
|
|
72
109
|
const deleteItem = (key) => {
|
|
73
|
-
|
|
74
|
-
const keyList = key.split("+");
|
|
75
|
-
console.log(keyList);
|
|
110
|
+
const keyList = key.split("_");
|
|
76
111
|
if (selectedHead.value === keyList[0]) {
|
|
77
112
|
checkList.value = checkList.value.filter((item) => item !== keyList[1]);
|
|
78
113
|
}
|
|
79
114
|
selectedTree.value[keyList[0]] = selectedTree.value[keyList[0]].filter((item) => item !== keyList[1]);
|
|
80
115
|
selectedList.value = selectedList.value.filter((item) => item.key !== key);
|
|
81
116
|
};
|
|
82
|
-
const
|
|
117
|
+
const confirmTarge = () => {
|
|
118
|
+
const selectedTable = selectedList.value.map((item) => {
|
|
119
|
+
return {
|
|
120
|
+
name: item.name,
|
|
121
|
+
key: `${item.key}`,
|
|
122
|
+
dealType: item.dealType
|
|
123
|
+
};
|
|
124
|
+
});
|
|
125
|
+
emit("choiceTarget", selectedTable);
|
|
126
|
+
};
|
|
127
|
+
const __returned__ = { props, emit, targetHead, allfoot, selectedHead, checkList, dialogShow, typeTag, headChange, selectedTree, selectedList, selectedTarget, deleteItem, confirmTarge, get ElDialog() {
|
|
83
128
|
return ElDialog;
|
|
84
129
|
}, get ElButton() {
|
|
85
130
|
return ElButton;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import 'hfn-components/theme-chalk/src/target.scss';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import 'hfn-components/theme-chalk/src/target.scss';
|
package/es/constants/table.d.ts
CHANGED
package/es/constants/table.mjs
CHANGED
|
@@ -139,7 +139,8 @@ const CLOUMN_DEAL = {
|
|
|
139
139
|
thoundsandText4,
|
|
140
140
|
notProcessed: null,
|
|
141
141
|
other: null,
|
|
142
|
-
customDeal: null
|
|
142
|
+
customDeal: null,
|
|
143
|
+
customSlot: null
|
|
143
144
|
};
|
|
144
145
|
const convertKey = (data, key) => {
|
|
145
146
|
const newKey = key.replace(/([A-Z])/g, "_$1").toLowerCase();
|
package/es/constants/target.d.ts
CHANGED
|
@@ -2,19 +2,13 @@ export declare const TARGET_HEAD_KEY: {
|
|
|
2
2
|
name: string;
|
|
3
3
|
key: string;
|
|
4
4
|
}[];
|
|
5
|
-
export declare const TARGET_END_KEY:
|
|
5
|
+
export declare const TARGET_END_KEY: {
|
|
6
6
|
name: string;
|
|
7
7
|
key: string;
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
} | {
|
|
11
|
-
name: string;
|
|
12
|
-
key: string;
|
|
13
|
-
slot: string;
|
|
14
|
-
excludeKey: string;
|
|
15
|
-
})[];
|
|
8
|
+
dealType: string;
|
|
9
|
+
}[];
|
|
16
10
|
export declare const BASIC_KEY: {
|
|
17
11
|
name: string;
|
|
18
12
|
key: string;
|
|
19
|
-
|
|
13
|
+
dealType: string;
|
|
20
14
|
}[];
|
package/es/constants/target.mjs
CHANGED
|
@@ -13,42 +13,42 @@ const TARGET_HEAD_KEY = [
|
|
|
13
13
|
{ name: "\u6210\u7ACB\u4EE5\u6765", key: "cucmulative" }
|
|
14
14
|
];
|
|
15
15
|
const TARGET_END_KEY = [
|
|
16
|
-
{ name: "\u6536\u76CA", key: "
|
|
17
|
-
{ name: "\u5E74\u5316\u6536\u76CA", key: "
|
|
18
|
-
{ name: "\u8D85\u989D\u6536\u76CA", key: "
|
|
19
|
-
{ name: "\u8D85\u989D\u5E74\u5316\u6536\u76CA", key: "
|
|
20
|
-
{ name: "\u5E74\u5316\u6CE2\u52A8\u7387", key: "
|
|
21
|
-
{ name: "\u8D85\u989D\u5E74\u5316\u6CE2\u52A8\u7387", key: "
|
|
22
|
-
{ name: "\u590F\u666E\u6BD4\u7387", key: "
|
|
23
|
-
{ name: "\u8D85\u989D\u590F\u666E\u6BD4\u7387", key: "
|
|
24
|
-
{ name: "\u5361\u739B\u6BD4\u7387", key: "
|
|
25
|
-
{ name: "\u8D85\u989D\u5361\u739B\u6BD4\u7387", key: "
|
|
26
|
-
{ name: "\u7D22\u63D0\u8BFA\u6BD4\u7387", key: "
|
|
27
|
-
{ name: "\u4E0B\u884C\u6807\u51C6\u5DEE", key: "
|
|
28
|
-
{ name: "\u4E0B\u884C\u98CE\u9669", key: "
|
|
29
|
-
{ name: "\u6700\u5927\u56DE\u64A4", key: "
|
|
30
|
-
{ name: "\u8D85\u989D\u6700\u5927\u56DE\u64A4", key: "
|
|
31
|
-
{ name: "\u6700\u5927\u56DE\u64A4\u56DE\u8865\u671F\uFF08\u5929\uFF09", key: "
|
|
32
|
-
{ name: "Alpha", key: "
|
|
33
|
-
{ name: "Beta", key: "
|
|
34
|
-
{ name: "\u8DDF\u8E2A\u8BEF\u5DEE", key: "
|
|
35
|
-
{ name: "\u4FE1\u606F\u6BD4\u7387", key: "
|
|
36
|
-
{ name: "\u504F\u5EA6", key: "
|
|
37
|
-
{ name: "\u5CF0\u5EA6", key: "
|
|
38
|
-
{ name: "VaR\uFF0895%\u7F6E\u4FE1\uFF09", key: "
|
|
39
|
-
{ name: "\u5468\u80DC\u7387", key: "
|
|
40
|
-
{ name: "\u6708\u80DC\u7387", key: "
|
|
16
|
+
{ name: "\u6536\u76CA", key: "return", dealType: "colorPercentage" },
|
|
17
|
+
{ name: "\u5E74\u5316\u6536\u76CA", key: "yearReturn", dealType: "colorPercentage" },
|
|
18
|
+
{ name: "\u8D85\u989D\u6536\u76CA", key: "excessReturn", dealType: "colorPercentage" },
|
|
19
|
+
{ name: "\u8D85\u989D\u5E74\u5316\u6536\u76CA", key: "excessYearReturn", dealType: "colorPercentage" },
|
|
20
|
+
{ name: "\u5E74\u5316\u6CE2\u52A8\u7387", key: "vol", dealType: "percentage" },
|
|
21
|
+
{ name: "\u8D85\u989D\u5E74\u5316\u6CE2\u52A8\u7387", key: "excessVol", dealType: "percentage" },
|
|
22
|
+
{ name: "\u590F\u666E\u6BD4\u7387", key: "sharpeRatio", dealType: "basicText4" },
|
|
23
|
+
{ name: "\u8D85\u989D\u590F\u666E\u6BD4\u7387", key: "excessSharpeRatio", dealType: "basicText4" },
|
|
24
|
+
{ name: "\u5361\u739B\u6BD4\u7387", key: "calmarRatio", dealType: "basicText4" },
|
|
25
|
+
{ name: "\u8D85\u989D\u5361\u739B\u6BD4\u7387", key: "excessCalmarRatio", dealType: "basicText4" },
|
|
26
|
+
{ name: "\u7D22\u63D0\u8BFA\u6BD4\u7387", key: "sortinoRatio", dealType: "basicText4" },
|
|
27
|
+
{ name: "\u4E0B\u884C\u6807\u51C6\u5DEE", key: "downsideStd", dealType: "percentage" },
|
|
28
|
+
{ name: "\u4E0B\u884C\u98CE\u9669", key: "downsideDev", dealType: "percentage" },
|
|
29
|
+
{ name: "\u6700\u5927\u56DE\u64A4", key: "maxDrawdown", dealType: "percentage" },
|
|
30
|
+
{ name: "\u8D85\u989D\u6700\u5927\u56DE\u64A4", key: "excessMaxDrawdown", dealType: "percentage" },
|
|
31
|
+
{ name: "\u6700\u5927\u56DE\u64A4\u56DE\u8865\u671F\uFF08\u5929\uFF09", key: "maxDrawdownDays", dealType: "notProcessed" },
|
|
32
|
+
{ name: "Alpha", key: "alpha", dealType: "colorPercentage" },
|
|
33
|
+
{ name: "Beta", key: "beta", dealType: "basicText4" },
|
|
34
|
+
{ name: "\u8DDF\u8E2A\u8BEF\u5DEE", key: "trackingError", dealType: "percentage" },
|
|
35
|
+
{ name: "\u4FE1\u606F\u6BD4\u7387", key: "informationRatio", dealType: "basicText4" },
|
|
36
|
+
{ name: "\u504F\u5EA6", key: "skew", dealType: "basicText4" },
|
|
37
|
+
{ name: "\u5CF0\u5EA6", key: "kurt", dealType: "basicText4" },
|
|
38
|
+
{ name: "VaR\uFF0895%\u7F6E\u4FE1\uFF09", key: "cVaR", dealType: "basicText4" },
|
|
39
|
+
{ name: "\u5468\u80DC\u7387", key: "positiveRatio", dealType: "percentage" },
|
|
40
|
+
{ name: "\u6708\u80DC\u7387", key: "monthlyPositiveRatio", dealType: "percentage" }
|
|
41
41
|
];
|
|
42
42
|
const BASIC_KEY = [
|
|
43
|
-
{ name: "\u7BA1\u7406\u4EBA", key: "
|
|
44
|
-
{ name: "\u7B56\u7565", key: "strategyOne",
|
|
45
|
-
{ name: "\u5355\u4F4D\u51C0\u503C", key: "
|
|
46
|
-
{ name: "\u5355\u4F4D\u51C0\u503C\u6DA8\u8DCC\u5E45", key: "navPriceChange",
|
|
47
|
-
{ name: "\u7D2F\u8BA1\u51C0\u503C", key: "cumulativeNavWithdrawal",
|
|
48
|
-
{ name: "\u6210\u7ACB\u65E5\u671F", key: "inceptionDate",
|
|
49
|
-
{ name: "\u5C01\u95ED\u671F", key: "closedPeriod",
|
|
50
|
-
{ name: "\u5F00\u653E\u65E5", key: "openDay",
|
|
51
|
-
{ name: "\u5907\u6848\u53F7/\u4EE3\u7801", key: "registerNumber",
|
|
43
|
+
{ name: "\u7BA1\u7406\u4EBA", key: "advisor", dealType: "" },
|
|
44
|
+
{ name: "\u7B56\u7565", key: "strategyOne", dealType: "" },
|
|
45
|
+
{ name: "\u5355\u4F4D\u51C0\u503C", key: "nav", dealType: "" },
|
|
46
|
+
{ name: "\u5355\u4F4D\u51C0\u503C\u6DA8\u8DCC\u5E45", key: "navPriceChange", dealType: "" },
|
|
47
|
+
{ name: "\u7D2F\u8BA1\u51C0\u503C", key: "cumulativeNavWithdrawal", dealType: "" },
|
|
48
|
+
{ name: "\u6210\u7ACB\u65E5\u671F", key: "inceptionDate", dealType: "" },
|
|
49
|
+
{ name: "\u5C01\u95ED\u671F", key: "closedPeriod", dealType: "" },
|
|
50
|
+
{ name: "\u5F00\u653E\u65E5", key: "openDay", dealType: "" },
|
|
51
|
+
{ name: "\u5907\u6848\u53F7/\u4EE3\u7801", key: "registerNumber", dealType: "" }
|
|
52
52
|
];
|
|
53
53
|
|
|
54
54
|
export { BASIC_KEY, TARGET_END_KEY, TARGET_HEAD_KEY };
|
package/package.json
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
.dialog{padding:24px!important;width:860px!important}.factor-content{display:flex;flex-direction:column;flex-wrap:wrap;height:380px;width:100%}.factor_item{display:flex;margin-bottom:10px;width:33.33%}.check_item{display:flex;justify-content:space-between}
|
package/theme-chalk/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.echart-box{display:flex;flex-direction:column;height:100%;position:relative;width:100%}.echart-content{flex:auto}.echart-lenged{box-sizing:border-box;display:flex;flex-wrap:wrap;font-size:12px;height:auto;margin-top:6px;padding-right:22px;position:relative;width:100%;z-index:999}.bg-span{height:2px;width:14px}.bg-span,.bg-span-bar{display:inline-block;margin-right:6px}.bg-span-bar{border-radius:2px;height:10px;width:16px}.span-box{cursor:pointer;margin-left:5px;margin-right:6px}.noData,.span-box{align-items:center;display:flex}.noData{bottom:0;color:#ccc;font-size:16px;justify-content:center;position:absolute}._100,.noData{height:100%;width:100%}
|
|
1
|
+
.echart-box{display:flex;flex-direction:column;height:100%;position:relative;width:100%}.echart-content{flex:auto}.echart-lenged{box-sizing:border-box;display:flex;flex-wrap:wrap;font-size:12px;height:auto;margin-top:6px;padding-right:22px;position:relative;width:100%;z-index:999}.bg-span{height:2px;width:14px}.bg-span,.bg-span-bar{display:inline-block;margin-right:6px}.bg-span-bar{border-radius:2px;height:10px;width:16px}.span-box{cursor:pointer;margin-left:5px;margin-right:6px}.noData,.span-box{align-items:center;display:flex}.noData{bottom:0;color:#ccc;font-size:16px;justify-content:center;position:absolute}._100,.noData{height:100%;width:100%}.dialog{padding:24px!important;width:860px!important}.factor-content{display:flex;flex-direction:column;flex-wrap:wrap;height:380px;width:100%}.factor_item{display:flex;margin-bottom:10px;width:33.33%}.check_item{display:flex;justify-content:space-between}
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
@use './chart.scss';
|
|
1
|
+
@use './chart.scss';
|
|
2
|
+
@use './target.scss'
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
.dialog {
|
|
2
|
+
width: 860px !important;
|
|
3
|
+
padding: 24px !important;
|
|
4
|
+
}
|
|
5
|
+
.factor-content {
|
|
6
|
+
width: 100%;
|
|
7
|
+
height: 380px;
|
|
8
|
+
display: flex;
|
|
9
|
+
flex-wrap: wrap;
|
|
10
|
+
flex-direction: column;
|
|
11
|
+
}
|
|
12
|
+
.factor_item {
|
|
13
|
+
width: 33.33%;
|
|
14
|
+
margin-bottom: 10px;
|
|
15
|
+
display: flex;
|
|
16
|
+
}
|
|
17
|
+
.check_item {
|
|
18
|
+
display: flex;
|
|
19
|
+
justify-content: space-between;
|
|
20
|
+
}
|