@zgfe/modules-event 0.1.5-event.6 → 0.1.5-event.8

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.
@@ -112,8 +112,6 @@ var EventTable = function EventTable(props) {
112
112
  },
113
113
  source: 'EVENT',
114
114
  url: searchData.analysisSubject ? '/zg/web/v2/data/eventSubjectDetail' : '/zg/web/v2/data/appEventBatch',
115
- downloadUrl: searchData.analysisSubject ? '/zg/web/v2/data/eventSubjectDetailDownLoad' : undefined,
116
- downloadFileName: '',
117
115
  analysisSubject: searchData.analysisSubject ? searchData.analysisSubject : undefined
118
116
  }, _objectSpread(_objectSpread({
119
117
  source: 'EVENT'
@@ -151,7 +149,7 @@ var EventTable = function EventTable(props) {
151
149
  if (searchData.id && !searchData.dimension || !searchData.id) {
152
150
  seriesNames.push(base64.encode('事件'));
153
151
  }
154
- var fname = "\u4E8B\u4EF6_".concat((searchData === null || searchData === void 0 ? void 0 : searchData.name) ? getEventAliasName(searchData === null || searchData === void 0 ? void 0 : searchData.name, eventGroupList) : '事件概览');
152
+ var fname = "\u4E8B\u4EF6\u5206\u6790-".concat((searchData === null || searchData === void 0 ? void 0 : searchData.name) ? getEventAliasName(searchData === null || searchData === void 0 ? void 0 : searchData.name, eventGroupList) : '事件概览');
155
153
  var params = _objectSpread(_objectSpread({
156
154
  appId: currentApp === null || currentApp === void 0 ? void 0 : currentApp.appId,
157
155
  platform: (currentApp === null || currentApp === void 0 ? void 0 : currentApp.platform) || 0
@@ -4,7 +4,7 @@ function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o =
4
4
  function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
5
5
  function _iterableToArrayLimit(r, l) { var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }
6
6
  function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
7
- import React, { useState } from 'react';
7
+ import React, { useState, useEffect } from 'react';
8
8
  import { Form, Button } from 'antd';
9
9
  import { BizUserGroupHeader, BizSelect } from '@zgfe/business-lib';
10
10
  import EventFilter from '../../components/eventFilter';
@@ -37,6 +37,17 @@ var TopPanel = /*#__PURE__*/React.forwardRef(function (props, ref) {
37
37
  var countChange = function countChange(count) {
38
38
  setmarginStyle(count > 0 ? true : false);
39
39
  };
40
+ useEffect(function () {
41
+ console.log('value===', value);
42
+ if (value) {
43
+ var analysisSubject = value.analysisSubject;
44
+ setAnalysisSubjectType({
45
+ value: analysisSubject && analysisSubject.analysisSubjectType,
46
+ label: analysisSubject && analysisSubject.analysisSubjectType === 'user' ? 'user' : 'event'
47
+ });
48
+ console.log('setAnalysisSubjectType useEffect', analysisSubjectType);
49
+ }
50
+ }, []);
40
51
  var _Form$useForm = Form.useForm(),
41
52
  _Form$useForm2 = _slicedToArray(_Form$useForm, 1),
42
53
  form = _Form$useForm2[0];
@@ -62,7 +73,8 @@ var TopPanel = /*#__PURE__*/React.forwardRef(function (props, ref) {
62
73
  subjectId: allData.analysisSubject.subjectId,
63
74
  subjectName: allData.analysisSubject.subjectName,
64
75
  subjectAlias: allData.analysisSubject.subjectAlias,
65
- unit: allData.analysisSubject.unit
76
+ unit: allData.analysisSubject.unit,
77
+ analysisSubjectType: analysisSubjectType.value
66
78
  };
67
79
  }
68
80
  if (data.filterConditions) {
@@ -104,6 +116,10 @@ var TopPanel = /*#__PURE__*/React.forwardRef(function (props, ref) {
104
116
  filters: value === null || value === void 0 ? void 0 : value.filters,
105
117
  eventGroupId: value === null || value === void 0 ? void 0 : value.eventGroupId
106
118
  },
119
+ analysisSubjectType: {
120
+ value: 'event',
121
+ label: '事件属性'
122
+ },
107
123
  analysisSubject: {
108
124
  subjectId: '12',
109
125
  subjectName: '12321',
@@ -13,9 +13,10 @@ interface analysisSubject {
13
13
  unit?: string;
14
14
  subjectAlias?: string;
15
15
  subjectName?: string;
16
+ analysisSubjectType?: string;
16
17
  }
17
18
  interface analysisSubjectType {
18
- value?: number;
19
+ value?: string;
19
20
  user?: string;
20
21
  }
21
22
  export interface FormDataProps {
package/es/types.d.ts CHANGED
@@ -15,6 +15,7 @@ export interface AnalysisSubject {
15
15
  unit?: string;
16
16
  subjectAlias?: string;
17
17
  subjectName?: string;
18
+ analysisSubjectType?: string;
18
19
  }
19
20
  export interface eventProps {
20
21
  id?: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@zgfe/modules-event",
3
- "version": "0.1.5-event.6",
3
+ "version": "0.1.5-event.8",
4
4
  "scripts": {
5
5
  "start": "dumi dev",
6
6
  "docs:build": "dumi build",
@@ -49,7 +49,7 @@
49
49
  "react": "^16.12.0 || ^17.0.0",
50
50
  "yorkie": "^2.0.0"
51
51
  },
52
- "gitHead": "aebace3cbd33d0e4c705d6d57946120b3f4f05b6",
52
+ "gitHead": "4265dcdd96ef76e01da1a92f19d8268c69665033",
53
53
  "dependencies": {
54
54
  "react-copy-to-clipboard": "^5.1.0",
55
55
  "react-highlight": "^0.15.0"