dlt-for-react 1.1.16 → 1.1.18
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/README.md +20 -1
- package/assets/HqCheckButton/index.less +13 -0
- package/assets/HqImage/index.less +11 -0
- package/assets/HqInputPicker/index.less +8 -0
- package/assets/selector/resultview/index.less +53 -0
- package/assets/selector/selectormodal/index.less +15 -0
- package/assets/selector/table/index.less +211 -0
- package/assets/selector/tree/index.less +138 -0
- package/assets/stuSelector/index.less +24 -0
- package/assets/teaSelector/index.less +4 -0
- package/lib/components/HqButton/index.js +95 -0
- package/lib/components/HqCascader/index.js +306 -0
- package/lib/components/HqCheckBox/index.js +375 -0
- package/lib/components/HqCheckButton/index.js +284 -0
- package/lib/components/HqConfirm/index.js +81 -0
- package/lib/components/HqFormItem/FormRules.js +27 -0
- package/lib/components/HqFormItem/index.js +309 -0
- package/lib/components/HqImage/index.js +553 -0
- package/lib/components/HqInputPicker/edit-page.js +585 -0
- package/lib/components/HqInputPicker/index.js +226 -0
- package/lib/components/HqInputPicker/input-const.js +134 -0
- package/lib/components/HqInputPicker/render.js +2496 -0
- package/lib/components/HqInputPicker/setting-checkbox.js +853 -0
- package/lib/components/HqInputPicker/setting-datepicker.js +430 -0
- package/lib/components/HqInputPicker/setting-datetimepicker.js +443 -0
- package/lib/components/HqInputPicker/setting-input.js +555 -0
- package/lib/components/HqInputPicker/setting-inputNumber.js +658 -0
- package/lib/components/HqInputPicker/setting-monthpicker.js +434 -0
- package/lib/components/HqInputPicker/setting-multiSelect.js +533 -0
- package/lib/components/HqInputPicker/setting-nhcascader.js +588 -0
- package/lib/components/HqInputPicker/setting-old-upload.js +428 -0
- package/lib/components/HqInputPicker/setting-radio.js +468 -0
- package/lib/components/HqInputPicker/setting-rangepicker.js +466 -0
- package/lib/components/HqInputPicker/setting-select.js +534 -0
- package/lib/components/HqInputPicker/setting-stu-selector.js +508 -0
- package/lib/components/HqInputPicker/setting-switch.js +274 -0
- package/lib/components/HqInputPicker/setting-tea-selector.js +508 -0
- package/lib/components/HqInputPicker/setting-textarea.js +619 -0
- package/lib/components/HqInputPicker/setting-timepicker.js +437 -0
- package/lib/components/HqInputPicker/setting-upload.js +795 -0
- package/lib/components/HqMultiSelect/index.js +495 -0
- package/lib/components/HqOldUpload/index.js +350 -0
- package/lib/components/HqSelect/getSelectName.js +20 -0
- package/lib/components/HqSelect/index.js +495 -0
- package/lib/components/HqSelector/HqLsrySelector/index.js +269 -267
- package/lib/components/HqSelector/HqRySelector/index.js +4 -2
- package/lib/components/HqSelector/HqWzSelector/index.js +4 -2
- package/lib/components/HqStuSelector/index.js +267 -0
- package/lib/components/HqSwitch/index.js +280 -0
- package/lib/components/HqTeaSelector/index.js +221 -0
- package/lib/components/KyCollapse/index.js +23 -24
- package/lib/components/KyContainerFrame/index.js +2 -2
- package/lib/components/KyEditableTable/component.js +38 -38
- package/lib/components/KyEditableTable/index.js +203 -181
- package/lib/components/KyExcel/index.js +191 -153
- package/lib/components/KyModal/index.js +43 -33
- package/lib/components/KyTable/AddFieldsModal.js +66 -59
- package/lib/components/KyTable/checkButtons.js +3 -13
- package/lib/components/KyTable/index.js +2 -2
- package/lib/components/KyTableCardList/AddFieldsModal.js +280 -282
- package/lib/components/KyTableCardList/index.js +15 -26
- package/lib/components/KyTree/index.js +7 -7
- package/lib/components/KyUpload/index.js +170 -165
- package/lib/components/NHSelector/ListSort/index.js +411 -0
- package/lib/components/NHSelector/index.js +636 -0
- package/lib/components/NHSelector/resultview/index.js +408 -0
- package/lib/components/NHSelector/selectormodal/index.js +303 -0
- package/lib/components/NHSelector/table/index.js +784 -0
- package/lib/components/NHSelector/tree/index.js +554 -0
- package/lib/index.js +164 -36
- package/lib/layouts/LeftMenu/index.js +6 -6
- package/lib/layouts/Login/index-pre.js +107 -103
- package/lib/layouts/Login/index.js +2 -2
- package/lib/layouts/Login/login.js +178 -172
- package/lib/layouts/NavigationBar/index.js +67 -67
- package/lib/layouts/Top/editPassWord.js +84 -64
- package/lib/layouts/Top/index.js +117 -117
- package/lib/layouts/TopMenu/index.js +53 -53
- package/lib/layouts/layout/index.js +115 -118
- package/lib/layouts/mixTop/index.js +95 -95
- package/lib/layouts/settingDrawer/index.js +96 -96
- package/lib/routes/AuthorizedRoute.js +33 -32
- package/lib/utils/NHCore.js +65 -65
- package/package.json +2 -2
- package/lib/utils/createUuid.js +0 -40
- package/lib/utils/getLoginUser.js +0 -10
- package/lib/utils/getSize.js +0 -27
|
@@ -123,27 +123,15 @@ var _react = require("react");
|
|
|
123
123
|
|
|
124
124
|
var _react2 = _interopRequireDefault(_react);
|
|
125
125
|
|
|
126
|
-
var _NHCore = require("../../utils/NHCore");
|
|
127
|
-
|
|
128
126
|
var _classnames = require("classnames");
|
|
129
127
|
|
|
130
128
|
var _classnames2 = _interopRequireDefault(_classnames);
|
|
131
129
|
|
|
132
|
-
var
|
|
133
|
-
|
|
134
|
-
var _NHFetch2 = _interopRequireDefault(_NHFetch);
|
|
135
|
-
|
|
136
|
-
var _getLoginUser = require("../../utils/getLoginUser");
|
|
137
|
-
|
|
138
|
-
var _getLoginUser2 = _interopRequireDefault(_getLoginUser);
|
|
139
|
-
|
|
140
|
-
var _createUuid = require("../../utils/createUuid");
|
|
141
|
-
|
|
142
|
-
var _createUuid2 = _interopRequireDefault(_createUuid);
|
|
130
|
+
var _index = require("../../index");
|
|
143
131
|
|
|
144
132
|
require("../../../assets/components/KyTableCardList/index.less");
|
|
145
133
|
|
|
146
|
-
var
|
|
134
|
+
var _reactCustomScrollbarsPatched = require("react-custom-scrollbars-patched");
|
|
147
135
|
|
|
148
136
|
var _highSearchForm = require("./highSearchForm");
|
|
149
137
|
|
|
@@ -159,10 +147,11 @@ var _KyIcon2 = _interopRequireDefault(_KyIcon);
|
|
|
159
147
|
|
|
160
148
|
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
|
|
161
149
|
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
150
|
+
/*******
|
|
151
|
+
* @description: 科研卡片表格-KyTableCardList
|
|
152
|
+
* @author: 琴时
|
|
153
|
+
*/
|
|
154
|
+
var Search = _input2.default.Search;
|
|
166
155
|
|
|
167
156
|
var KyTableCardList = function (_React$Component) {
|
|
168
157
|
(0, _inherits3.default)(KyTableCardList, _React$Component);
|
|
@@ -176,7 +165,7 @@ var KyTableCardList = function (_React$Component) {
|
|
|
176
165
|
//如果需要自适应高度
|
|
177
166
|
if (!_this.props.autoHeightFlag && document.getElementsByClassName(_this.state.className)) {
|
|
178
167
|
var lastHeight = _this.state.height;
|
|
179
|
-
var height = (0,
|
|
168
|
+
var height = (0, _index.getSuitHeight)(document.getElementsByClassName(_this.state.className)[0]);
|
|
180
169
|
height = _this.props.windowH - 64;
|
|
181
170
|
var titleHeight = _this.props.titleHeight || _this.props.titleHeight === 0 ? _this.props.titleHeight : 40;
|
|
182
171
|
//如果不显示头部,则头部的高度为0
|
|
@@ -207,7 +196,7 @@ var KyTableCardList = function (_React$Component) {
|
|
|
207
196
|
};
|
|
208
197
|
var url_final = baseUrl + "/proData/gridList";
|
|
209
198
|
url_final = url || url_final;
|
|
210
|
-
(0,
|
|
199
|
+
(0, _index.NHFetch)(url_final, "POST", params).then(function (res) {
|
|
211
200
|
if (res) {
|
|
212
201
|
_this.setState({
|
|
213
202
|
hightSearchData: res.data ? res.data.list : []
|
|
@@ -303,7 +292,7 @@ var KyTableCardList = function (_React$Component) {
|
|
|
303
292
|
onDataLoadFinish = _this$props2.onDataLoadFinish;
|
|
304
293
|
|
|
305
294
|
baseUrl = url || baseUrl || window.baseUrl || "";
|
|
306
|
-
(0,
|
|
295
|
+
(0, _index.NHFetch)(baseUrl + "/proData/gridList", "POST", params).then(function (res) {
|
|
307
296
|
_this.setState({
|
|
308
297
|
data: res.data ? res.data.list : [],
|
|
309
298
|
selectedRowKeys: [],
|
|
@@ -360,7 +349,7 @@ var KyTableCardList = function (_React$Component) {
|
|
|
360
349
|
|
|
361
350
|
//如果启用职位范围过滤
|
|
362
351
|
if (rangeFilter) {
|
|
363
|
-
var userId = (0,
|
|
352
|
+
var userId = (0, _index.getLoginUser)() ? (0, _index.getLoginUser)().userId : "";
|
|
364
353
|
params.rangeFilter = { id: userId };
|
|
365
354
|
}
|
|
366
355
|
return params;
|
|
@@ -505,7 +494,7 @@ var KyTableCardList = function (_React$Component) {
|
|
|
505
494
|
|
|
506
495
|
_this.getAction = function (row, action) {
|
|
507
496
|
var action1 = action.filter(function (item) {
|
|
508
|
-
return (item.auth === undefined || (0,
|
|
497
|
+
return (item.auth === undefined || (0, _index.hasAuth)(item.auth)) && (item.isShow === undefined || item.isShow(row));
|
|
509
498
|
});
|
|
510
499
|
var action2 = action1.splice(2);
|
|
511
500
|
var dom = action1.map(function (item, index) {
|
|
@@ -561,7 +550,7 @@ var KyTableCardList = function (_React$Component) {
|
|
|
561
550
|
);
|
|
562
551
|
var temp = _react2.default.createElement(
|
|
563
552
|
_react2.default.Fragment,
|
|
564
|
-
{ key: (0,
|
|
553
|
+
{ key: (0, _index.createUuid)() },
|
|
565
554
|
_react2.default.createElement(_divider2.default, { className: "border", type: "vertical" }),
|
|
566
555
|
_react2.default.createElement(
|
|
567
556
|
_dropdown2.default,
|
|
@@ -606,7 +595,7 @@ var KyTableCardList = function (_React$Component) {
|
|
|
606
595
|
},
|
|
607
596
|
height: _this.props.height, //列表的高度
|
|
608
597
|
width: undefined, //列表的宽度
|
|
609
|
-
className: (0,
|
|
598
|
+
className: (0, _index.createUuid)(),
|
|
610
599
|
tySearchAllField: "", //通用查询的所有字段
|
|
611
600
|
searchValue: "", //通用查询的值
|
|
612
601
|
searchField: "", //通用查询的字段
|
|
@@ -877,7 +866,7 @@ var KyTableCardList = function (_React$Component) {
|
|
|
877
866
|
"div",
|
|
878
867
|
{ className: (0, _classnames2.default)(className, classNamePro) },
|
|
879
868
|
_react2.default.createElement(
|
|
880
|
-
|
|
869
|
+
_reactCustomScrollbarsPatched.Scrollbars,
|
|
881
870
|
{
|
|
882
871
|
className: "custom_scrollbars",
|
|
883
872
|
autoHide: true,
|
|
@@ -77,13 +77,13 @@ var _react = require("react");
|
|
|
77
77
|
|
|
78
78
|
var _react2 = _interopRequireDefault(_react);
|
|
79
79
|
|
|
80
|
-
var
|
|
80
|
+
var _reactCustomScrollbarsPatched = require("react-custom-scrollbars-patched");
|
|
81
81
|
|
|
82
82
|
var _reactDom = require("react-dom");
|
|
83
83
|
|
|
84
84
|
var _reactDom2 = _interopRequireDefault(_reactDom);
|
|
85
85
|
|
|
86
|
-
var
|
|
86
|
+
var _index = require("../../index");
|
|
87
87
|
|
|
88
88
|
var _equalsObj = require("../../utils/equalsObj");
|
|
89
89
|
|
|
@@ -239,7 +239,7 @@ var KyTree = function (_React$Component) {
|
|
|
239
239
|
"a",
|
|
240
240
|
{
|
|
241
241
|
style: { display: "block", color: "inherit" },
|
|
242
|
-
key: (0,
|
|
242
|
+
key: (0, _index.createUuid)(),
|
|
243
243
|
onClick: function onClick() {
|
|
244
244
|
return item.onClick(e.node.props.dataRef, e.node.props.eventKey, e);
|
|
245
245
|
}
|
|
@@ -360,7 +360,7 @@ var KyTree = function (_React$Component) {
|
|
|
360
360
|
_react2.default.createElement(_icon2.default, { className: "trigger", type: collapsed ? "right" : "left" })
|
|
361
361
|
),
|
|
362
362
|
dataList && dataList.length > 0 && _react2.default.createElement(
|
|
363
|
-
|
|
363
|
+
_reactCustomScrollbarsPatched.Scrollbars,
|
|
364
364
|
{
|
|
365
365
|
className: "Ky_scroll",
|
|
366
366
|
style: { width: "100%", height: "100%" }
|
|
@@ -417,7 +417,7 @@ var _initialiseProps = function _initialiseProps() {
|
|
|
417
417
|
var obj = _this3;
|
|
418
418
|
var baseUrl = _this3.props.baseUrl;
|
|
419
419
|
var url = _this3.props.url ? _this3.props.url : (baseUrl || window.baseUrl || "") + "/proData/getTreeList";
|
|
420
|
-
(0,
|
|
420
|
+
(0, _index.NHFetch)(url, "POST", {
|
|
421
421
|
params: _this3.props.params,
|
|
422
422
|
sqlParams: _this3.props.sqlParams,
|
|
423
423
|
sign: _this3.props.sign
|
|
@@ -457,7 +457,7 @@ var _initialiseProps = function _initialiseProps() {
|
|
|
457
457
|
params = treeParam;
|
|
458
458
|
} else {
|
|
459
459
|
var t = new Date().getTime();
|
|
460
|
-
(0,
|
|
460
|
+
(0, _index.NHFetch)(_this3.props.baseUrl + "/proData/queryAllConfig", "GET", t).then(function (res) {
|
|
461
461
|
if (res && res.code === 200) {
|
|
462
462
|
var _treeParam = res.data.tree[_this3.props.sign];
|
|
463
463
|
if (_treeParam) {
|
|
@@ -800,7 +800,7 @@ var _initialiseProps = function _initialiseProps() {
|
|
|
800
800
|
//是否满足显示这个按钮的要求
|
|
801
801
|
if (item.isShow === undefined || item.isShow(e.node.props.dataRef, e.node.props.eventKey, e)) {
|
|
802
802
|
//是否满足权限的要求
|
|
803
|
-
if (item.auth === undefined || (0,
|
|
803
|
+
if (item.auth === undefined || (0, _index.hasAuth)(item.auth)) {
|
|
804
804
|
newMenuList.push(item);
|
|
805
805
|
}
|
|
806
806
|
}
|