@titaui/pc 1.12.9-beta.3 → 1.12.9-beta.6

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.
@@ -25,7 +25,7 @@ var _default = /*#__PURE__*/function () {
25
25
  _createClass(_default, [{
26
26
  key: "highlight",
27
27
  value: function highlight(cb) {
28
- if (this.isUnAssigned()) cb(_menus.PAGE_UNASSIGNED_DEMOFREE);else if (this.isAssigned()) cb(_menus.PAGE_ASSIGNED_DEMOFREE);else if (this.isReserved()) cb(_menus.PAGE_RESERVED_DEMOFREE);else if (this.isDone()) cb(_menus.PAGE_DONE_DEMOFREE);else if (this.isIgnore()) cb(_menus.PAGE_IGNORED_DEMOFREE);else if (this.isChart()) cb(_menus.PAGE_CHARTS_DEMOFREE);else if (this.isRechargeList()) cb(_menus.PAGE_RECHARGE_LIST);else if (this.isRechargeStatistics()) cb(_menus.PAGE_RECHARGE_STATISTICS);else if (this.isRechargeStatus()) cb(_menus.PAGE_RECHARGE_STATUS);else if (this.isDueDateOrder()) cb(_menus.PAGE_DUEDATE_ORDER);
28
+ if (this.isUnAssigned()) cb(_menus.PAGE_UNASSIGNED_DEMOFREE);else if (this.isAssigned()) cb(_menus.PAGE_ASSIGNED_DEMOFREE);else if (this.isReserved()) cb(_menus.PAGE_RESERVED_DEMOFREE);else if (this.isDone()) cb(_menus.PAGE_DONE_DEMOFREE);else if (this.isIgnore()) cb(_menus.PAGE_IGNORED_DEMOFREE);else if (this.isChart()) cb(_menus.PAGE_CHARTS_DEMOFREE);else if (this.isRechargeList()) cb(_menus.PAGE_RECHARGE_LIST);else if (this.isRechargeStatistics()) cb(_menus.PAGE_RECHARGE_STATISTICS);else if (this.isRechargeStatus()) cb(_menus.PAGE_RECHARGE_STATUS);else if (this.isDueDateOrder()) cb(_menus.PAGE_DUEDATE_ORDER);else if (this.isAllCustomer()) cb(_menus.PAGE_ALL_CUSTOMER);else if (this.isPublicCustomer()) cb(_menus.PAGE_PUBLIC_CUSTOMER);else if (this.isMyCustomer()) cb(_menus.PAGE_MY_CUSTOMER);
29
29
  }
30
30
  }, {
31
31
  key: "isChart",
@@ -102,6 +102,24 @@ var _default = /*#__PURE__*/function () {
102
102
  search = _this$history$locatio5.search;
103
103
  return pathname.match(/demofree/) && search.match(/selected[\s]*?=[\s]*?ignore/);
104
104
  }
105
+ }, {
106
+ key: "isPublicCustomer",
107
+ value: function isPublicCustomer() {
108
+ var pathname = this.history.location.pathname;
109
+ return pathname.match(/demofree\/customer\/public/);
110
+ }
111
+ }, {
112
+ key: "isMyCustomer",
113
+ value: function isMyCustomer() {
114
+ var pathname = this.history.location.pathname;
115
+ return pathname.match(/demofree\/customer\/my/);
116
+ }
117
+ }, {
118
+ key: "isAllCustomer",
119
+ value: function isAllCustomer() {
120
+ var pathname = this.history.location.pathname;
121
+ return pathname.match(/demofree\/customer\/all/);
122
+ }
105
123
  }]);
106
124
 
107
125
  return _default;
@@ -3,7 +3,7 @@
3
3
  Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
- exports.defaultRefObject = exports["default"] = exports.PAGE_UNASSIGNED_DEMOFREE = exports.PAGE_RESERVED_DEMOFREE = exports.PAGE_RECHARGE_STATUS = exports.PAGE_RECHARGE_STATISTICS = exports.PAGE_RECHARGE_LIST = exports.PAGE_IGNORED_DEMOFREE = exports.PAGE_DUEDATE_ORDER = exports.PAGE_DONE_DEMOFREE = exports.PAGE_CHARTS_DEMOFREE = exports.PAGE_ASSIGNED_DEMOFREE = void 0;
6
+ exports.defaultRefObject = exports["default"] = exports.PAGE_UNASSIGNED_DEMOFREE = exports.PAGE_RESERVED_DEMOFREE = exports.PAGE_RECHARGE_STATUS = exports.PAGE_RECHARGE_STATISTICS = exports.PAGE_RECHARGE_LIST = exports.PAGE_PUBLIC_CUSTOMER = exports.PAGE_MY_CUSTOMER = exports.PAGE_IGNORED_DEMOFREE = exports.PAGE_DUEDATE_ORDER = exports.PAGE_DONE_DEMOFREE = exports.PAGE_CHARTS_DEMOFREE = exports.PAGE_CHARTS = exports.PAGE_ASSIGNED_DEMOFREE = exports.PAGE_ALL_CUSTOMER = void 0;
7
7
 
8
8
  var _index = require("../../components/menu-tree/tree-node/index");
9
9
 
@@ -40,6 +40,14 @@ var PAGE_IGNORED_DEMOFREE = "ignore";
40
40
  exports.PAGE_IGNORED_DEMOFREE = PAGE_IGNORED_DEMOFREE;
41
41
  var PAGE_CHARTS_DEMOFREE = "charts";
42
42
  exports.PAGE_CHARTS_DEMOFREE = PAGE_CHARTS_DEMOFREE;
43
+ var PAGE_ALL_CUSTOMER = "allCustomer";
44
+ exports.PAGE_ALL_CUSTOMER = PAGE_ALL_CUSTOMER;
45
+ var PAGE_PUBLIC_CUSTOMER = "publicCustomer";
46
+ exports.PAGE_PUBLIC_CUSTOMER = PAGE_PUBLIC_CUSTOMER;
47
+ var PAGE_MY_CUSTOMER = "myCustomer";
48
+ exports.PAGE_MY_CUSTOMER = PAGE_MY_CUSTOMER;
49
+ var PAGE_CHARTS = "charts";
50
+ exports.PAGE_CHARTS = PAGE_CHARTS;
43
51
  var PAGE_RECHARGE_LIST = "rechargeList";
44
52
  exports.PAGE_RECHARGE_LIST = PAGE_RECHARGE_LIST;
45
53
  var PAGE_DUEDATE_ORDER = "dueDateOrder";
@@ -91,6 +99,31 @@ var DemoMenuData = /*#__PURE__*/function () {
91
99
  href: "#/demofree/list?selected=ignore",
92
100
  isShow: this.isManager === EManagerType.Manager
93
101
  }]
102
+ }, {
103
+ icon: "KH-help",
104
+ label: "公海资源",
105
+ key: "customer",
106
+ href: "#/demofree/customer/public",
107
+ isShow: true,
108
+ children: [{
109
+ icon: "",
110
+ label: "全部客户",
111
+ key: PAGE_ALL_CUSTOMER,
112
+ href: "#/demofree/customer/all",
113
+ isShow: this.isManager === EManagerType.ReCharge || this.isManager === EManagerType.Manager
114
+ }, {
115
+ icon: "",
116
+ label: "公海资源",
117
+ key: PAGE_PUBLIC_CUSTOMER,
118
+ href: "#/demofree/customer/public",
119
+ isShow: this.isManager !== EManagerType.ReCharge
120
+ }, {
121
+ icon: "",
122
+ label: "我的资源",
123
+ key: PAGE_MY_CUSTOMER,
124
+ href: "#/demofree/customer/my",
125
+ isShow: this.isManager !== EManagerType.ReCharge
126
+ }]
94
127
  }, {
95
128
  icon: "KH-help",
96
129
  label: "客户续费",
@@ -89,3 +89,16 @@
89
89
  line-height: 26px;
90
90
  font-family: -apple-system, Arial, Verdana, Helvetica Neue, Helvetica, sans-serif, PingFang SC, Microsoft YaHei;
91
91
  }
92
+
93
+ .app-center__drawer {
94
+ transform: translateY(54px);
95
+ }
96
+
97
+ .app-center__drawer .drawer-content-wrapper,
98
+ .app-center__drawer .drawer-content {
99
+ border-radius: 24px;
100
+ }
101
+
102
+ .app-center__drawer .drawer-mask {
103
+ border-radius: 24px 24px 0 0;
104
+ }
@@ -43,7 +43,7 @@ var AppCenter = function AppCenter(props) {
43
43
  var _useState = (0, _react.useState)(function () {
44
44
  var menus = (0, _utils.getMenus)();
45
45
  return menus.filter(function (menu) {
46
- return menu.key !== "dynamic";
46
+ return menu.code !== "dynamic";
47
47
  });
48
48
  }),
49
49
  _useState2 = _slicedToArray(_useState, 1),
@@ -92,6 +92,16 @@ var AppCenter = function AppCenter(props) {
92
92
 
93
93
  closeAppCenter();
94
94
  }, [currentAppId]);
95
+
96
+ var onAppSelectHandler = function onAppSelectHandler(app) {
97
+ if (app.type === "page") {
98
+ window.location.href = "".concat(window.BSGlobal.apiPath, "/").concat(app.href);
99
+ return;
100
+ }
101
+
102
+ setCurrentAppId(app.id);
103
+ };
104
+
95
105
  return /*#__PURE__*/_react["default"].createElement(_drawer["default"], {
96
106
  className: "".concat(precls, "__drawer"),
97
107
  placement: "top",
@@ -109,7 +119,7 @@ var AppCenter = function AppCenter(props) {
109
119
  return /*#__PURE__*/_react["default"].createElement("div", {
110
120
  className: "".concat(precls, "__app-item"),
111
121
  onClick: function onClick() {
112
- return setCurrentAppId(app.id);
122
+ return onAppSelectHandler(app);
113
123
  }
114
124
  }, /*#__PURE__*/_react["default"].createElement("span", {
115
125
  className: (0, _classnames["default"])("".concat(precls, "__app-item-icon"), "".concat(precls, "__app-item-icon--").concat(app.iconName))
@@ -14,11 +14,10 @@
14
14
  display: inline-flex;
15
15
  justify-content: space-between;
16
16
  align-items: center;
17
- min-width: 204px;
18
17
  height: 54px;
19
18
  border-radius: 0px 0px 0px 24px;
20
19
  box-sizing: border-box;
21
- padding-left: 20px;
20
+ padding: 0 20px;
22
21
  cursor: default;
23
22
  }
24
23
 
@@ -54,7 +53,6 @@
54
53
  font-size: 24px;
55
54
  color: #ffffff;
56
55
  padding: 2px;
57
- margin-right: 14px;
58
56
  border-radius: 8px;
59
57
  cursor: pointer;
60
58
  }
@@ -65,6 +63,8 @@
65
63
 
66
64
  .titaui-nav-top__left-dynamic {
67
65
  position: relative;
66
+ margin-right: -6px;
67
+ margin-left: 20px;
68
68
  }
69
69
 
70
70
  .titaui-nav-top__left-dynamic-feed-num {
@@ -85,6 +85,10 @@
85
85
  font-weight: 400;
86
86
  }
87
87
 
88
+ .titaui-nav-top__left-app-center {
89
+ margin-right: 12px;
90
+ }
91
+
88
92
  .titaui-nav-top__line {
89
93
  width: 1px;
90
94
  min-width: 1px;