@titaui/pc 1.5.78 → 1.5.82
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/lib/components/avatar/index.js +1 -9
- package/lib/components/change-okr/Filter.js +65 -133
- package/lib/components/change-okr/Item.js +0 -6
- package/lib/components/change-okr/filterTab.js +0 -2
- package/lib/components/change-okr/index.js +2 -2
- package/lib/components/checkbox/index.js +3 -4
- package/lib/components/communication/CommunicationRecord.js +161 -116
- package/lib/components/communication/ConvertUserName.js +1 -1
- package/lib/components/communication/index.js +28 -53
- package/lib/components/communication/style.js +25 -21
- package/lib/components/dropdown-layer/icon-item.js +3 -5
- package/lib/components/dropdown-layer/index.css +0 -16
- package/lib/components/dropdown-layer/index.js +14 -21
- package/lib/components/emotionsSelector/style.js +1 -1
- package/lib/components/form/form-fields/input/index.css +0 -11
- package/lib/components/form/form-fields/input/index.js +1 -3
- package/lib/components/grid-page/personal-info/index.js +4 -4
- package/lib/components/mblog/components/MblogAction.js +6 -10
- package/lib/components/mblog/index.js +11 -24
- package/lib/components/mblog/style.js +8 -8
- package/lib/components/okr-detail/components/header/index.css +0 -4
- package/lib/components/okr-detail/components/header/o-cycle.js +2 -2
- package/lib/components/okr-detail/components/okr-tree/tree-node/e-kr-node/index.js +8 -15
- package/lib/components/okr-flow/child-node/work-node.js +1 -7
- package/lib/components/okr-period-selector/select-cycle.js +151 -139
- package/lib/components/okr-progress-detail/index.css +0 -1
- package/lib/components/okr-review/ReviewPop/components/ReviewBody/index.js +5 -5
- package/lib/components/okr-review/ReviewPop/index.js +4 -4
- package/lib/components/period-selector/common.js +4 -149
- package/lib/components/period-selector/components/selector/index.js +38 -103
- package/lib/components/period-selector/components/selector/style.js +9 -23
- package/lib/components/period-selector/index.js +28 -29
- package/lib/components/popup/index.js +1 -3
- package/lib/components/radio/index.css +0 -5
- package/lib/components/radio/radio.js +4 -12
- package/lib/components/table/index.css +1 -0
- package/lib/components/upload/components/uploadedPreview.js +54 -62
- package/lib/components/upload/index.js +57 -89
- package/lib/components/upload/style.js +7 -7
- package/lib/components/upload/type.js +15 -15
- package/lib/components/upvote/index.js +14 -37
- package/lib/components/user-selector/export-modules/field-tree-selector/index.css +0 -4
- package/lib/components/user-selector/export-modules/field-tree-selector/index.js +24 -50
- package/lib/components/user-selector/export-modules/field-tree-selector/single-selector/index.js +2 -11
- package/lib/components/user-selector/layout/index.css +1 -1
- package/lib/index.js +5 -49
- package/lib/pages/home-page/components/data-list/nav-selector/index.js +0 -18
- package/lib/pages/home-page/components/data-list/table/utils-function.js +3 -6
- package/lib/utils/auth.js +5 -46
- package/lib/utils/bs-global.js +2 -26
- package/lib/utils/tools.js +20 -140
- package/package.json +2 -2
- package/lib/components/avatar/icon-avatar/index.css +0 -15
- package/lib/components/avatar/icon-avatar/index.js +0 -50
- package/lib/components/avatar/num-avatar/index.css +0 -12
- package/lib/components/avatar/num-avatar/index.js +0 -34
- package/lib/components/button/admin-button/default.js +0 -35
- package/lib/components/button/admin-button/drop-down-arrow.js +0 -93
- package/lib/components/button/admin-button/index.css +0 -86
- package/lib/components/button/admin-button/index.js +0 -40
- package/lib/components/button/admin-button/primary.js +0 -33
- package/lib/components/button/admin-button/secondary.js +0 -35
- package/lib/components/button/default-button/index.css +0 -49
- package/lib/components/button/default-button/index.js +0 -51
- package/lib/components/button/export-button/index.css +0 -51
- package/lib/components/button/export-button/index.js +0 -81
- package/lib/components/button/images/daoru.svg +0 -18
- package/lib/components/button/index.js +0 -23
- package/lib/components/button/interface.js +0 -5
- package/lib/components/communication/index.css +0 -63
- package/lib/components/create-okr/animation/check-animation.js +0 -2746
- package/lib/components/create-okr/constant.js +0 -27
- package/lib/components/create-okr/createCycle.js +0 -171
- package/lib/components/create-okr/createSuccessCmp.js +0 -233
- package/lib/components/create-okr/createSuccessCmpWrapper.js +0 -20
- package/lib/components/create-okr/fields/date-cycle.js +0 -98
- package/lib/components/create-okr/fields/index.css +0 -346
- package/lib/components/create-okr/fields/index.js +0 -17
- package/lib/components/create-okr/fields/input-with-err-popup.js +0 -57
- package/lib/components/create-okr/fields/o-new-name.js +0 -197
- package/lib/components/create-okr/fields/okr-case.js +0 -98
- package/lib/components/create-okr/fields/okr-classify.js +0 -51
- package/lib/components/create-okr/fields/okr-create-suggest.js +0 -147
- package/lib/components/create-okr/fields/okr-new-user-selector.js +0 -106
- package/lib/components/create-okr/fields/okr-parent.js +0 -157
- package/lib/components/create-okr/fields/okr-type-detail.js +0 -196
- package/lib/components/create-okr/fields/okr-type.js +0 -131
- package/lib/components/create-okr/fields/okr-visibility-detail.js +0 -224
- package/lib/components/create-okr/fields/okr-visibility.js +0 -169
- package/lib/components/create-okr/img/check-normal.svg +0 -29
- package/lib/components/create-okr/img/check-right.svg +0 -16
- package/lib/components/create-okr/img/check-wrong.svg +0 -29
- package/lib/components/create-okr/img/create-success-head.png +0 -0
- package/lib/components/create-okr/img/create-success-left-quotation.svg +0 -14
- package/lib/components/create-okr/img/create-success-message.svg +0 -1
- package/lib/components/create-okr/img/create-success-right-quotation.svg +0 -14
- package/lib/components/create-okr/img/create-success-shadow.svg +0 -23
- package/lib/components/create-okr/img/example.svg +0 -11
- package/lib/components/create-okr/img/hand.svg +0 -12
- package/lib/components/create-okr/img/kr-add.svg +0 -12
- package/lib/components/create-okr/img/left-quotation.svg +0 -12
- package/lib/components/create-okr/img/light.svg +0 -1
- package/lib/components/create-okr/img/pack-up.js +0 -28
- package/lib/components/create-okr/img/qr-code.png +0 -0
- package/lib/components/create-okr/img/right-quotation.svg +0 -12
- package/lib/components/create-okr/img/shower.png +0 -0
- package/lib/components/create-okr/img/target.svg +0 -19
- package/lib/components/create-okr/img/teach-okr.svg +0 -17
- package/lib/components/create-okr/img/wave.png +0 -0
- package/lib/components/create-okr/img/weight.svg +0 -12
- package/lib/components/create-okr/index.css +0 -446
- package/lib/components/create-okr/index.js +0 -911
- package/lib/components/create-okr/interface.js +0 -5
- package/lib/components/create-okr/kr-items/index.css +0 -180
- package/lib/components/create-okr/kr-items/kr-item-weight.js +0 -194
- package/lib/components/create-okr/kr-items/krDatas.js +0 -299
- package/lib/components/create-okr/kr-items/krItem.js +0 -167
- package/lib/components/create-okr/objectType.js +0 -273
- package/lib/components/create-okr/request-api.js +0 -220
- package/lib/components/create-okr/style.js +0 -100
- package/lib/components/create-okr/utils/getCreateOkrSurpassPercent.js +0 -124
- package/lib/components/create-okr/utils/helper.js +0 -99
- package/lib/components/create-okr/utils/index.js +0 -23
- package/lib/components/dynamic/components/condition-render/index.js +0 -20
- package/lib/components/dynamic/components/dangerous-html/index.js +0 -22
- package/lib/components/dynamic/components/dynamic-search-input/index.css +0 -78
- package/lib/components/dynamic/components/dynamic-search-input/index.js +0 -192
- package/lib/components/dynamic/components/obj-status/index.css +0 -22
- package/lib/components/dynamic/components/obj-status/index.js +0 -38
- package/lib/components/dynamic/components/percent/index.css +0 -21
- package/lib/components/dynamic/components/percent/index.js +0 -38
- package/lib/components/dynamic/components/title/index.css +0 -35
- package/lib/components/dynamic/components/title/index.js +0 -59
- package/lib/components/dynamic/constant.js +0 -96
- package/lib/components/dynamic/context/index.js +0 -13
- package/lib/components/dynamic/dynamic-item/components/header/index.css +0 -101
- package/lib/components/dynamic/dynamic-item/components/header/index.js +0 -294
- package/lib/components/dynamic/dynamic-item/components/icon/index.css +0 -10
- package/lib/components/dynamic/dynamic-item/components/icon/index.js +0 -35
- package/lib/components/dynamic/dynamic-item/dynamic-align/img/dynamic-align.svg +0 -22
- package/lib/components/dynamic/dynamic-item/dynamic-align/img/dynamic-relative.svg +0 -22
- package/lib/components/dynamic/dynamic-item/dynamic-align/index.css +0 -95
- package/lib/components/dynamic/dynamic-item/dynamic-align/index.js +0 -173
- package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.css +0 -54
- package/lib/components/dynamic/dynamic-item/dynamic-announcement/index.js +0 -107
- package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.css +0 -48
- package/lib/components/dynamic/dynamic-item/dynamic-assessment/index.js +0 -89
- package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.css +0 -96
- package/lib/components/dynamic/dynamic-item/dynamic-create-o/index.js +0 -171
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.css +0 -67
- package/lib/components/dynamic/dynamic-item/dynamic-kr/index.js +0 -110
- package/lib/components/dynamic/dynamic-item/dynamic-milestone/constant.js +0 -16
- package/lib/components/dynamic/dynamic-item/dynamic-milestone/img/milestone.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.css +0 -111
- package/lib/components/dynamic/dynamic-item/dynamic-milestone/index.js +0 -158
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.css +0 -95
- package/lib/components/dynamic/dynamic-item/dynamic-progress/index.js +0 -215
- package/lib/components/dynamic/dynamic-item/dynamic-project/constant.js +0 -16
- package/lib/components/dynamic/dynamic-item/dynamic-project/img/project.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-project/index.css +0 -91
- package/lib/components/dynamic/dynamic-item/dynamic-project/index.js +0 -125
- package/lib/components/dynamic/dynamic-item/dynamic-relative/img/dynamic-relative.svg +0 -22
- package/lib/components/dynamic/dynamic-item/dynamic-relative/index.css +0 -95
- package/lib/components/dynamic/dynamic-item/dynamic-relative/index.js +0 -192
- package/lib/components/dynamic/dynamic-item/dynamic-replay/index.css +0 -138
- package/lib/components/dynamic/dynamic-item/dynamic-replay/index.js +0 -183
- package/lib/components/dynamic/dynamic-item/dynamic-report/index.css +0 -153
- package/lib/components/dynamic/dynamic-item/dynamic-report/index.js +0 -138
- package/lib/components/dynamic/dynamic-item/dynamic-reward/index.css +0 -97
- package/lib/components/dynamic/dynamic-item/dynamic-reward/index.js +0 -207
- package/lib/components/dynamic/dynamic-item/dynamic-share/index.css +0 -54
- package/lib/components/dynamic/dynamic-item/dynamic-share/index.js +0 -107
- package/lib/components/dynamic/dynamic-item/dynamic-task/constant.js +0 -50
- package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-cancel.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-delay.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-done.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-pause.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-progress.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-unaccept.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/img/task-unstart.png +0 -0
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.css +0 -111
- package/lib/components/dynamic/dynamic-item/dynamic-task/index.js +0 -164
- package/lib/components/dynamic/dynamic-item/index.css +0 -128
- package/lib/components/dynamic/dynamic-item/index.js +0 -352
- package/lib/components/dynamic/dynamic-like-ranking/image/like-ranking.svg +0 -23
- package/lib/components/dynamic/dynamic-like-ranking/image/ranking-1.png +0 -0
- package/lib/components/dynamic/dynamic-like-ranking/image/ranking-2.png +0 -0
- package/lib/components/dynamic/dynamic-like-ranking/image/ranking-3.png +0 -0
- package/lib/components/dynamic/dynamic-like-ranking/index.css +0 -126
- package/lib/components/dynamic/dynamic-like-ranking/index.js +0 -157
- package/lib/components/dynamic/dynamic-like-ranking/item.js +0 -107
- package/lib/components/dynamic/dynamic-like-ranking/mock.js +0 -84
- package/lib/components/dynamic/dynamic-liking/image/like-dynamic.svg +0 -30
- package/lib/components/dynamic/dynamic-liking/index.css +0 -81
- package/lib/components/dynamic/dynamic-liking/index.js +0 -76
- package/lib/components/dynamic/dynamic-liking/item.js +0 -90
- package/lib/components/dynamic/dynamic-liking/mock.js +0 -83
- package/lib/components/dynamic/dynamic-list/index.css +0 -36
- package/lib/components/dynamic/dynamic-list/index.js +0 -61
- package/lib/components/dynamic/dynamic-topping/image/quotationMark.svg +0 -16
- package/lib/components/dynamic/dynamic-topping/image/topIcon.svg +0 -30
- package/lib/components/dynamic/dynamic-topping/index.css +0 -130
- package/lib/components/dynamic/dynamic-topping/index.js +0 -78
- package/lib/components/dynamic/dynamic-topping/interface.js +0 -5
- package/lib/components/dynamic/dynamic-topping/item.js +0 -138
- package/lib/components/dynamic/dynamic-topping/request-api.js +0 -36
- package/lib/components/dynamic/dynamic.css +0 -204
- package/lib/components/dynamic/dynamic.js +0 -391
- package/lib/components/dynamic/export-module/index.js +0 -33
- package/lib/components/dynamic/img/dynamic-P1.svg +0 -15
- package/lib/components/dynamic/img/dynamic-P2.svg +0 -15
- package/lib/components/dynamic/img/dynamic-P3.svg +0 -15
- package/lib/components/dynamic/img/dynamic-P4.svg +0 -15
- package/lib/components/dynamic/img/dynamic-P5.svg +0 -15
- package/lib/components/dynamic/img/dynamic-delay.svg +0 -17
- package/lib/components/dynamic/img/dynamic-desire.svg +0 -61
- package/lib/components/dynamic/img/dynamic-empty.png +0 -0
- package/lib/components/dynamic/img/dynamic-end.svg +0 -17
- package/lib/components/dynamic/img/dynamic-left-quoto.svg +0 -13
- package/lib/components/dynamic/img/dynamic-loading.gif +0 -0
- package/lib/components/dynamic/img/dynamic-normal.svg +0 -17
- package/lib/components/dynamic/img/dynamic-promise.svg +0 -61
- package/lib/components/dynamic/img/dynamic-reword.svg +0 -24
- package/lib/components/dynamic/img/dynamic-right-quoto.svg +0 -13
- package/lib/components/dynamic/img/dynamic-risk.svg +0 -17
- package/lib/components/dynamic/img/dynamic-submit-delay.svg +0 -16
- package/lib/components/dynamic/img/dynamic-submit-normal.svg +0 -18
- package/lib/components/dynamic/img/dynamic-top.svg +0 -14
- package/lib/components/dynamic/index.js +0 -27
- package/lib/components/dynamic/interface.js +0 -5
- package/lib/components/dynamic/quick-operation/components/create-announcement/index.css +0 -25
- package/lib/components/dynamic/quick-operation/components/create-announcement/index.js +0 -37
- package/lib/components/dynamic/quick-operation/components/create-okr/index.css +0 -25
- package/lib/components/dynamic/quick-operation/components/create-okr/index.js +0 -37
- package/lib/components/dynamic/quick-operation/components/create-share/index.css +0 -25
- package/lib/components/dynamic/quick-operation/components/create-share/index.js +0 -37
- package/lib/components/dynamic/quick-operation/components/create-task/index.css +0 -25
- package/lib/components/dynamic/quick-operation/components/create-task/index.js +0 -42
- package/lib/components/dynamic/quick-operation/img/create-announcement.png +0 -0
- package/lib/components/dynamic/quick-operation/img/create-okr.png +0 -0
- package/lib/components/dynamic/quick-operation/img/create-share.png +0 -0
- package/lib/components/dynamic/quick-operation/img/create-task.png +0 -0
- package/lib/components/dynamic/quick-operation/index.css +0 -51
- package/lib/components/dynamic/quick-operation/index.js +0 -112
- package/lib/components/dynamic/request-api.js +0 -92
- package/lib/components/dynamic/util.js +0 -140
- package/lib/components/file-list/components/single-file/index.css +0 -84
- package/lib/components/file-list/components/single-file/index.js +0 -115
- package/lib/components/file-list/img/new-file-list-doc.svg +0 -1
- package/lib/components/file-list/img/new-file-list-other.svg +0 -1
- package/lib/components/file-list/img/new-file-list-pdf.svg +0 -1
- package/lib/components/file-list/img/new-file-list-ppt.svg +0 -1
- package/lib/components/file-list/img/new-file-list-radio.svg +0 -1
- package/lib/components/file-list/img/new-file-list-video.svg +0 -1
- package/lib/components/file-list/img/new-file-list-xls.svg +0 -1
- package/lib/components/file-list/index.css +0 -5
- package/lib/components/file-list/index.js +0 -61
- package/lib/components/file-list/interface.js +0 -5
- package/lib/components/file-list/util.js +0 -78
- package/lib/components/img-viewer/icon/enlarge.js +0 -30
- package/lib/components/img-viewer/icon/left-rotate.js +0 -46
- package/lib/components/img-viewer/icon/right-rotate.js +0 -44
- package/lib/components/img-viewer/icon/shrink.js +0 -37
- package/lib/components/img-viewer/image/loading.gif +0 -0
- package/lib/components/img-viewer/index.css +0 -155
- package/lib/components/img-viewer/index.js +0 -228
- package/lib/components/img-viewer/interface.js +0 -5
- package/lib/components/img-viewer/util.js +0 -16
- package/lib/components/publish-dynamic-modal/index.js +0 -13
- package/lib/components/publish-dynamic-modal/interface.js +0 -5
- package/lib/components/publish-dynamic-modal/publish-dynamic-modal.css +0 -3
- package/lib/components/publish-dynamic-modal/publish-dynamic-modal.js +0 -191
- package/lib/components/publish-dynamic-modal/requist-api.js +0 -48
- package/lib/components/search-key-handle/index.js +0 -39
- package/lib/components/upload/img/doc.svg +0 -1
- package/lib/components/upload/img/other.svg +0 -1
- package/lib/components/upload/img/pdf.svg +0 -1
- package/lib/components/upload/img/ppt.svg +0 -1
- package/lib/components/upload/img/radio.svg +0 -1
- package/lib/components/upload/img/video.svg +0 -1
- package/lib/components/upload/img/xls.svg +0 -1
- package/lib/components/upload/index.css +0 -26
- package/lib/components/upload/util.js +0 -102
- package/lib/components-v1/buttonv2/ButtonLinked.js +0 -35
- package/lib/components-v1/buttonv2/ButtonOutlined.js +0 -64
- package/lib/components-v1/buttonv2/ButtonRounded.js +0 -101
- package/lib/components-v1/buttonv2/DefaultButton.js +0 -86
- package/lib/components-v1/buttonv2/index.js +0 -37
- package/lib/components-v1/buttonv2/style/style.js +0 -53
- package/lib/components-v1/buttonv2/style/theme.css +0 -3
- package/lib/components-v1/confirm/index.js +0 -158
- package/lib/pages/dynamic/index.css +0 -5
- package/lib/pages/dynamic/index.js +0 -25
- package/lib/pages/like-ranking/column.js +0 -141
- package/lib/pages/like-ranking/filter-buttons/department.js +0 -44
- package/lib/pages/like-ranking/filter-buttons/group.js +0 -34
- package/lib/pages/like-ranking/filter-buttons/index.css +0 -19
- package/lib/pages/like-ranking/filter-buttons/index.js +0 -44
- package/lib/pages/like-ranking/filter-buttons/modular.js +0 -110
- package/lib/pages/like-ranking/filter-buttons/name.js +0 -73
- package/lib/pages/like-ranking/filter-buttons/search-dropdown/index.css +0 -27
- package/lib/pages/like-ranking/filter-buttons/search-dropdown/index.js +0 -38
- package/lib/pages/like-ranking/filter-buttons/timer.js +0 -56
- package/lib/pages/like-ranking/image/dynamic-empty.png +0 -0
- package/lib/pages/like-ranking/image/loading.gif +0 -0
- package/lib/pages/like-ranking/image/ranking-1.png +0 -0
- package/lib/pages/like-ranking/image/ranking-2.png +0 -0
- package/lib/pages/like-ranking/image/ranking-3.png +0 -0
- package/lib/pages/like-ranking/index.css +0 -185
- package/lib/pages/like-ranking/index.js +0 -252
- package/lib/pages/like-ranking/mock.js +0 -366
- package/lib/pages/like-ranking/request-api.js +0 -15
- package/lib/utils/format-time.js +0 -161
- package/lib/utils/helpers.js +0 -41
- package/lib/utils/roundWeight.js +0 -105
- package/yarn-error.log +0 -15894
|
@@ -1,366 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.userPariseinfos = exports.data = void 0;
|
|
7
|
-
var data = [{
|
|
8
|
-
"user": {
|
|
9
|
-
big: null,
|
|
10
|
-
color: "#b9cc4f",
|
|
11
|
-
hasAvatar: false,
|
|
12
|
-
large: null,
|
|
13
|
-
medium: null,
|
|
14
|
-
normal: null,
|
|
15
|
-
original: null,
|
|
16
|
-
small: null
|
|
17
|
-
},
|
|
18
|
-
"ranking": 1,
|
|
19
|
-
"name": '杨亮',
|
|
20
|
-
"departmentId": 0,
|
|
21
|
-
"departmentName": "默认部门",
|
|
22
|
-
"userId": 560000215,
|
|
23
|
-
"primaryDepartment": "默认部门",
|
|
24
|
-
"primaryDepartmentId": 0,
|
|
25
|
-
"likeNums": 1400
|
|
26
|
-
}, {
|
|
27
|
-
"user": {
|
|
28
|
-
big: null,
|
|
29
|
-
color: "#b9cc4f",
|
|
30
|
-
hasAvatar: false,
|
|
31
|
-
large: null,
|
|
32
|
-
medium: null,
|
|
33
|
-
normal: null,
|
|
34
|
-
original: null,
|
|
35
|
-
small: null
|
|
36
|
-
},
|
|
37
|
-
"ranking": 2,
|
|
38
|
-
"name": '杨亮',
|
|
39
|
-
"departmentId": 0,
|
|
40
|
-
"departmentName": "默认部门",
|
|
41
|
-
"userId": 560000215,
|
|
42
|
-
"primaryDepartment": "默认部门",
|
|
43
|
-
"primaryDepartmentId": 0,
|
|
44
|
-
"likeNums": 140
|
|
45
|
-
}, {
|
|
46
|
-
"user": {
|
|
47
|
-
big: null,
|
|
48
|
-
color: "#b9cc4f",
|
|
49
|
-
hasAvatar: false,
|
|
50
|
-
large: null,
|
|
51
|
-
medium: null,
|
|
52
|
-
normal: null,
|
|
53
|
-
original: null,
|
|
54
|
-
small: null
|
|
55
|
-
},
|
|
56
|
-
"ranking": 3,
|
|
57
|
-
"name": '杨亮',
|
|
58
|
-
"departmentId": 0,
|
|
59
|
-
"departmentName": "默认部门",
|
|
60
|
-
"userId": 560000215,
|
|
61
|
-
"primaryDepartment": "默认部门",
|
|
62
|
-
"primaryDepartmentId": 0,
|
|
63
|
-
"likeNums": 14000
|
|
64
|
-
}, {
|
|
65
|
-
"user": {
|
|
66
|
-
big: null,
|
|
67
|
-
color: "#b9cc4f",
|
|
68
|
-
hasAvatar: false,
|
|
69
|
-
large: null,
|
|
70
|
-
medium: null,
|
|
71
|
-
normal: null,
|
|
72
|
-
original: null,
|
|
73
|
-
small: null
|
|
74
|
-
},
|
|
75
|
-
"ranking": 4,
|
|
76
|
-
"name": '杨亮',
|
|
77
|
-
"departmentId": 0,
|
|
78
|
-
"departmentName": "默认部门",
|
|
79
|
-
"userId": 560000215,
|
|
80
|
-
"primaryDepartment": "默认部门",
|
|
81
|
-
"primaryDepartmentId": 0,
|
|
82
|
-
"likeNums": 14000000
|
|
83
|
-
}];
|
|
84
|
-
exports.data = data;
|
|
85
|
-
var userPariseinfos = [{
|
|
86
|
-
"user": {
|
|
87
|
-
"userId": 560000209,
|
|
88
|
-
"userType": 0,
|
|
89
|
-
"name": "张昊",
|
|
90
|
-
"email": "zhanghao@ceshi.com",
|
|
91
|
-
"managerId": 0,
|
|
92
|
-
"jobState": 1,
|
|
93
|
-
"departmentId": 1641,
|
|
94
|
-
"departmentName": "请问",
|
|
95
|
-
"postition": null,
|
|
96
|
-
"subType": 0,
|
|
97
|
-
"hasSubordinates": false,
|
|
98
|
-
"avatar": {
|
|
99
|
-
"original": null,
|
|
100
|
-
"small": null,
|
|
101
|
-
"medium": null,
|
|
102
|
-
"big": null,
|
|
103
|
-
"normal": null,
|
|
104
|
-
"large": null,
|
|
105
|
-
"hasAvatar": false,
|
|
106
|
-
"color": "#f5b168"
|
|
107
|
-
},
|
|
108
|
-
"staffCode": "111"
|
|
109
|
-
},
|
|
110
|
-
"ranking": 1,
|
|
111
|
-
"oneLevelDepName": "请问",
|
|
112
|
-
"pariseNums": 1
|
|
113
|
-
}, {
|
|
114
|
-
"user": {
|
|
115
|
-
"userId": 510000002,
|
|
116
|
-
"userType": 0,
|
|
117
|
-
"name": "yangliang",
|
|
118
|
-
"email": "b496a604-8645-45be-a1e0-bc3a0f0a88c3_210813_192219@virtual.account",
|
|
119
|
-
"managerId": 0,
|
|
120
|
-
"jobState": 1,
|
|
121
|
-
"departmentId": 0,
|
|
122
|
-
"departmentName": "默认部门",
|
|
123
|
-
"postition": "地方时有人天天味儿",
|
|
124
|
-
"subType": 0,
|
|
125
|
-
"hasSubordinates": false,
|
|
126
|
-
"avatar": {
|
|
127
|
-
"original": null,
|
|
128
|
-
"small": null,
|
|
129
|
-
"medium": null,
|
|
130
|
-
"big": null,
|
|
131
|
-
"normal": null,
|
|
132
|
-
"large": null,
|
|
133
|
-
"hasAvatar": false,
|
|
134
|
-
"color": "#7eb6e0"
|
|
135
|
-
},
|
|
136
|
-
"staffCode": null
|
|
137
|
-
},
|
|
138
|
-
"ranking": 2,
|
|
139
|
-
"oneLevelDepName": "默认部门",
|
|
140
|
-
"pariseNums": 0
|
|
141
|
-
}, {
|
|
142
|
-
"user": {
|
|
143
|
-
"userId": 510000003,
|
|
144
|
-
"userType": 0,
|
|
145
|
-
"name": "杨亮",
|
|
146
|
-
"email": "935d5dc8-941e-4864-86c7-3e51769ae4ef_210813_192356@virtual.account",
|
|
147
|
-
"managerId": 0,
|
|
148
|
-
"jobState": 1,
|
|
149
|
-
"departmentId": 0,
|
|
150
|
-
"departmentName": "默认部门",
|
|
151
|
-
"postition": "是大V服务认为",
|
|
152
|
-
"subType": 0,
|
|
153
|
-
"hasSubordinates": false,
|
|
154
|
-
"avatar": {
|
|
155
|
-
"original": null,
|
|
156
|
-
"small": null,
|
|
157
|
-
"medium": null,
|
|
158
|
-
"big": null,
|
|
159
|
-
"normal": null,
|
|
160
|
-
"large": null,
|
|
161
|
-
"hasAvatar": false,
|
|
162
|
-
"color": "#a1a5ee"
|
|
163
|
-
},
|
|
164
|
-
"staffCode": null
|
|
165
|
-
},
|
|
166
|
-
"ranking": 3,
|
|
167
|
-
"oneLevelDepName": "默认部门",
|
|
168
|
-
"pariseNums": 0
|
|
169
|
-
}, {
|
|
170
|
-
"user": {
|
|
171
|
-
"userId": 560000210,
|
|
172
|
-
"userType": 0,
|
|
173
|
-
"name": "张昊下属",
|
|
174
|
-
"email": "zhanghao@ceshi1.com",
|
|
175
|
-
"managerId": 560000209,
|
|
176
|
-
"jobState": 1,
|
|
177
|
-
"departmentId": 1642,
|
|
178
|
-
"departmentName": "不错吧",
|
|
179
|
-
"postition": null,
|
|
180
|
-
"subType": 0,
|
|
181
|
-
"hasSubordinates": false,
|
|
182
|
-
"avatar": {
|
|
183
|
-
"original": null,
|
|
184
|
-
"small": null,
|
|
185
|
-
"medium": null,
|
|
186
|
-
"big": null,
|
|
187
|
-
"normal": null,
|
|
188
|
-
"large": null,
|
|
189
|
-
"hasAvatar": false,
|
|
190
|
-
"color": "#f0c75a"
|
|
191
|
-
},
|
|
192
|
-
"staffCode": "9898976"
|
|
193
|
-
},
|
|
194
|
-
"ranking": 4,
|
|
195
|
-
"oneLevelDepName": "sfsdfsdf",
|
|
196
|
-
"pariseNums": 0
|
|
197
|
-
}, {
|
|
198
|
-
"user": {
|
|
199
|
-
"userId": 560000211,
|
|
200
|
-
"userType": 0,
|
|
201
|
-
"name": "sad发",
|
|
202
|
-
"email": "fcfb078f-3159-4d13-8da2-46ee4e60ccf1@titavirtual.tt",
|
|
203
|
-
"managerId": 0,
|
|
204
|
-
"jobState": 1,
|
|
205
|
-
"departmentId": 0,
|
|
206
|
-
"departmentName": "默认部门",
|
|
207
|
-
"postition": "海棠依旧苦于他",
|
|
208
|
-
"subType": 0,
|
|
209
|
-
"hasSubordinates": false,
|
|
210
|
-
"avatar": {
|
|
211
|
-
"original": null,
|
|
212
|
-
"small": null,
|
|
213
|
-
"medium": null,
|
|
214
|
-
"big": null,
|
|
215
|
-
"normal": null,
|
|
216
|
-
"large": null,
|
|
217
|
-
"hasAvatar": false,
|
|
218
|
-
"color": "#8dc8ea"
|
|
219
|
-
},
|
|
220
|
-
"staffCode": "333"
|
|
221
|
-
},
|
|
222
|
-
"ranking": 5,
|
|
223
|
-
"oneLevelDepName": "默认部门",
|
|
224
|
-
"pariseNums": 0
|
|
225
|
-
}, {
|
|
226
|
-
"user": {
|
|
227
|
-
"userId": 560000212,
|
|
228
|
-
"userType": 0,
|
|
229
|
-
"name": "QW",
|
|
230
|
-
"email": "65ddbb05-87e9-4413-9297-9c579bac6540@titavirtual.tt",
|
|
231
|
-
"managerId": 0,
|
|
232
|
-
"jobState": 1,
|
|
233
|
-
"departmentId": 1640,
|
|
234
|
-
"departmentName": "阿松大123",
|
|
235
|
-
"postition": null,
|
|
236
|
-
"subType": 0,
|
|
237
|
-
"hasSubordinates": false,
|
|
238
|
-
"avatar": {
|
|
239
|
-
"original": null,
|
|
240
|
-
"small": null,
|
|
241
|
-
"medium": null,
|
|
242
|
-
"big": null,
|
|
243
|
-
"normal": null,
|
|
244
|
-
"large": null,
|
|
245
|
-
"hasAvatar": false,
|
|
246
|
-
"color": "#7eb6e0"
|
|
247
|
-
},
|
|
248
|
-
"staffCode": "444"
|
|
249
|
-
},
|
|
250
|
-
"ranking": 6,
|
|
251
|
-
"oneLevelDepName": "访问v",
|
|
252
|
-
"pariseNums": 0
|
|
253
|
-
}, {
|
|
254
|
-
"user": {
|
|
255
|
-
"userId": 560000213,
|
|
256
|
-
"userType": 0,
|
|
257
|
-
"name": "测试1",
|
|
258
|
-
"email": "736059fd-9bb3-430d-84f4-d3f267e0f2ac@titavirtual.tt",
|
|
259
|
-
"managerId": 0,
|
|
260
|
-
"jobState": 1,
|
|
261
|
-
"departmentId": 0,
|
|
262
|
-
"departmentName": "默认部门",
|
|
263
|
-
"postition": null,
|
|
264
|
-
"subType": 0,
|
|
265
|
-
"hasSubordinates": false,
|
|
266
|
-
"avatar": {
|
|
267
|
-
"original": null,
|
|
268
|
-
"small": null,
|
|
269
|
-
"medium": null,
|
|
270
|
-
"big": null,
|
|
271
|
-
"normal": null,
|
|
272
|
-
"large": null,
|
|
273
|
-
"hasAvatar": false,
|
|
274
|
-
"color": "#a1a5ee"
|
|
275
|
-
},
|
|
276
|
-
"staffCode": "555"
|
|
277
|
-
},
|
|
278
|
-
"ranking": 7,
|
|
279
|
-
"oneLevelDepName": "默认部门",
|
|
280
|
-
"pariseNums": 0
|
|
281
|
-
}, {
|
|
282
|
-
"user": {
|
|
283
|
-
"userId": 560000214,
|
|
284
|
-
"userType": 0,
|
|
285
|
-
"name": "测试2",
|
|
286
|
-
"email": "534a2922-2e59-4998-a055-00a35a6a1a23@titavirtual.tt",
|
|
287
|
-
"managerId": 0,
|
|
288
|
-
"jobState": 1,
|
|
289
|
-
"departmentId": 1637,
|
|
290
|
-
"departmentName": "不错吧1111111111111",
|
|
291
|
-
"postition": null,
|
|
292
|
-
"subType": 0,
|
|
293
|
-
"hasSubordinates": false,
|
|
294
|
-
"avatar": {
|
|
295
|
-
"original": null,
|
|
296
|
-
"small": null,
|
|
297
|
-
"medium": null,
|
|
298
|
-
"big": null,
|
|
299
|
-
"normal": null,
|
|
300
|
-
"large": null,
|
|
301
|
-
"hasAvatar": false,
|
|
302
|
-
"color": "#c4a1ee"
|
|
303
|
-
},
|
|
304
|
-
"staffCode": "666"
|
|
305
|
-
},
|
|
306
|
-
"ranking": 8,
|
|
307
|
-
"oneLevelDepName": "sfsdfsdf",
|
|
308
|
-
"pariseNums": 0
|
|
309
|
-
}, {
|
|
310
|
-
"user": {
|
|
311
|
-
"userId": 560000215,
|
|
312
|
-
"userType": 0,
|
|
313
|
-
"name": "导入人",
|
|
314
|
-
"email": "b6057d12-4074-4b50-b799-880e94c34962@titavirtual.tt",
|
|
315
|
-
"managerId": 560000209,
|
|
316
|
-
"jobState": 1,
|
|
317
|
-
"departmentId": 0,
|
|
318
|
-
"departmentName": "默认部门",
|
|
319
|
-
"postition": null,
|
|
320
|
-
"subType": 0,
|
|
321
|
-
"hasSubordinates": false,
|
|
322
|
-
"avatar": {
|
|
323
|
-
"original": null,
|
|
324
|
-
"small": null,
|
|
325
|
-
"medium": null,
|
|
326
|
-
"big": null,
|
|
327
|
-
"normal": null,
|
|
328
|
-
"large": null,
|
|
329
|
-
"hasAvatar": false,
|
|
330
|
-
"color": "#b9cc4f"
|
|
331
|
-
},
|
|
332
|
-
"staffCode": "777"
|
|
333
|
-
},
|
|
334
|
-
"ranking": 9,
|
|
335
|
-
"oneLevelDepName": "默认部门",
|
|
336
|
-
"pariseNums": 0
|
|
337
|
-
}, {
|
|
338
|
-
"user": {
|
|
339
|
-
"userId": 560000217,
|
|
340
|
-
"userType": 0,
|
|
341
|
-
"name": "新家群",
|
|
342
|
-
"email": "29e1e1c5-41e8-4250-9f50-aa7fda56d8e4@titavirtual.tt",
|
|
343
|
-
"managerId": 0,
|
|
344
|
-
"jobState": 1,
|
|
345
|
-
"departmentId": 0,
|
|
346
|
-
"departmentName": "默认部门",
|
|
347
|
-
"postition": null,
|
|
348
|
-
"subType": 0,
|
|
349
|
-
"hasSubordinates": false,
|
|
350
|
-
"avatar": {
|
|
351
|
-
"original": null,
|
|
352
|
-
"small": null,
|
|
353
|
-
"medium": null,
|
|
354
|
-
"big": null,
|
|
355
|
-
"normal": null,
|
|
356
|
-
"large": null,
|
|
357
|
-
"hasAvatar": false,
|
|
358
|
-
"color": "#f79c6f"
|
|
359
|
-
},
|
|
360
|
-
"staffCode": "888"
|
|
361
|
-
},
|
|
362
|
-
"ranking": 10,
|
|
363
|
-
"oneLevelDepName": "默认部门",
|
|
364
|
-
"pariseNums": 0
|
|
365
|
-
}];
|
|
366
|
-
exports.userPariseinfos = userPariseinfos;
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.getRanking = void 0;
|
|
7
|
-
|
|
8
|
-
var _request = require("../../utils/request");
|
|
9
|
-
|
|
10
|
-
// /api/v1/{tenant_id}/{user_id}/praise/getRanking
|
|
11
|
-
var getRanking = function getRanking(data) {
|
|
12
|
-
return (0, _request.rpost)("v1")("praise/getRanking", data);
|
|
13
|
-
};
|
|
14
|
-
|
|
15
|
-
exports.getRanking = getRanking;
|
package/lib/utils/format-time.js
DELETED
|
@@ -1,161 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.showNextMonthFirstDay = exports.showMonthLastDay = exports.showMonthFirstDay = exports.showNextWeekFirstDay = exports.showWeekLastDay = exports.showWeekFirstDay = exports.getNextDayOfYear = exports.getFirstDayOfYear = exports.timeFormat = exports.getTimeString = void 0;
|
|
7
|
-
|
|
8
|
-
var getTimeString = function getTimeString(time, nowTime) {
|
|
9
|
-
if (!time) {
|
|
10
|
-
return "暂未更新";
|
|
11
|
-
}
|
|
12
|
-
|
|
13
|
-
var timeDateObj = new Date(time);
|
|
14
|
-
var timeMilliSecond = timeDateObj.getTime();
|
|
15
|
-
var timeYear = timeDateObj.getFullYear();
|
|
16
|
-
var timeMonth = timeDateObj.getMonth() + 1;
|
|
17
|
-
var timeDate = timeDateObj.getDate();
|
|
18
|
-
var timeHours = timeDateObj.getHours();
|
|
19
|
-
var timeMinutes = timeDateObj.getMinutes();
|
|
20
|
-
var nowMilliSecond = nowTime.getTime();
|
|
21
|
-
var nowYear = nowTime.getFullYear();
|
|
22
|
-
var nowDate = nowTime.getDate();
|
|
23
|
-
var secondDiff = Math.floor((nowMilliSecond - timeMilliSecond) / 1000);
|
|
24
|
-
|
|
25
|
-
if (secondDiff <= 3) {
|
|
26
|
-
return "刚刚";
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
if (secondDiff < 60) {
|
|
30
|
-
return "".concat(secondDiff, "\u79D2\u524D");
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
if (secondDiff < 60 * 60) {
|
|
34
|
-
return "".concat(Math.floor(secondDiff / 60), "\u5206\u949F\u524D");
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
if (secondDiff < 60 * 60 * 24) {
|
|
38
|
-
return "".concat(Math.floor(secondDiff / (60 * 60)), "\u5C0F\u65F6\u524D");
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
if (secondDiff < 60 * 60 * 24 * 2 && nowDate - 1 === timeDate) {
|
|
42
|
-
return "\u6628\u5929 ".concat(timeHours + ":" + timeMinutes);
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
if (secondDiff < 60 * 60 * 24 * 3 && nowDate - 2 === timeDate) {
|
|
46
|
-
return "\u524D\u5929 ".concat(timeHours + ":" + timeMinutes);
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
if (timeYear === nowYear) {
|
|
50
|
-
return "".concat(timeMonth, "\u6708").concat(timeDate, "\u65E5 ").concat(timeHours < 10 ? "0" + timeHours : timeHours, ":").concat(timeMinutes < 10 ? "0" + timeMinutes : timeMinutes);
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
return "".concat(timeYear, "\u5E74").concat(timeMonth, "\u6708").concat(timeDate, "\u65E5 ").concat(timeHours < 10 ? "0" + timeHours : timeHours, ":").concat(timeMinutes < 10 ? "0" + timeMinutes : timeMinutes);
|
|
54
|
-
}; // 日期格式化,返回值形式为yy-mm-dd
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
exports.getTimeString = getTimeString;
|
|
58
|
-
|
|
59
|
-
var timeFormat = function timeFormat(NowDate) {
|
|
60
|
-
var date = new Date(NowDate);
|
|
61
|
-
var y = date.getFullYear(); //年
|
|
62
|
-
|
|
63
|
-
var m = date.getMonth() + 1; //月
|
|
64
|
-
|
|
65
|
-
var d = date.getDate(); //日
|
|
66
|
-
|
|
67
|
-
return y + "-" + m + "-" + d;
|
|
68
|
-
}; // 获取当年第一天
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
exports.timeFormat = timeFormat;
|
|
72
|
-
|
|
73
|
-
var getFirstDayOfYear = function getFirstDayOfYear() {
|
|
74
|
-
var date = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : new Date();
|
|
75
|
-
date.setDate(1);
|
|
76
|
-
date.setMonth(0);
|
|
77
|
-
return timeFormat(date);
|
|
78
|
-
}; // 获取明年第一天
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
exports.getFirstDayOfYear = getFirstDayOfYear;
|
|
82
|
-
|
|
83
|
-
var getNextDayOfYear = function getNextDayOfYear() {
|
|
84
|
-
var date = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : new Date();
|
|
85
|
-
date.setFullYear(date.getFullYear() + 1);
|
|
86
|
-
return getFirstDayOfYear(date);
|
|
87
|
-
}; // 本周第一天
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
exports.getNextDayOfYear = getNextDayOfYear;
|
|
91
|
-
|
|
92
|
-
var showWeekFirstDay = function showWeekFirstDay() {
|
|
93
|
-
var Nowdate = new Date();
|
|
94
|
-
var weekDay = Nowdate.getDay() || 7; // @ts-ignore
|
|
95
|
-
|
|
96
|
-
var WeekFirstDay = new Date(Nowdate - (weekDay - 1) * 86400000);
|
|
97
|
-
var M = Number(WeekFirstDay.getMonth()) + 1;
|
|
98
|
-
return WeekFirstDay.getFullYear() + "-" + M + "-" + WeekFirstDay.getDate();
|
|
99
|
-
}; // 本周最后一天
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
exports.showWeekFirstDay = showWeekFirstDay;
|
|
103
|
-
|
|
104
|
-
var showWeekLastDay = function showWeekLastDay() {
|
|
105
|
-
var Nowdate = new Date();
|
|
106
|
-
var weekDay = Nowdate.getDay() || 7; // @ts-ignore
|
|
107
|
-
|
|
108
|
-
var WeekFirstDay = new Date(Nowdate - (weekDay - 1) * 86400000); // @ts-ignore
|
|
109
|
-
|
|
110
|
-
var WeekLastDay = new Date((WeekFirstDay / 1000 + 6 * 86400) * 1000);
|
|
111
|
-
var M = Number(WeekLastDay.getMonth()) + 1;
|
|
112
|
-
return WeekLastDay.getFullYear() + "-" + M + "-" + WeekLastDay.getDate();
|
|
113
|
-
}; // 下周第一天
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
exports.showWeekLastDay = showWeekLastDay;
|
|
117
|
-
|
|
118
|
-
var showNextWeekFirstDay = function showNextWeekFirstDay() {
|
|
119
|
-
var Nowdate = new Date();
|
|
120
|
-
var weekDay = Nowdate.getDay() || 7; // @ts-ignore
|
|
121
|
-
|
|
122
|
-
var WeekFirstDay = new Date(Nowdate - (weekDay - 1) * 86400000); // @ts-ignore
|
|
123
|
-
|
|
124
|
-
var WeekLastDay = new Date((WeekFirstDay / 1000 + 7 * 86400) * 1000);
|
|
125
|
-
var M = Number(WeekLastDay.getMonth()) + 1;
|
|
126
|
-
return WeekLastDay.getFullYear() + "-" + M + "-" + WeekLastDay.getDate();
|
|
127
|
-
}; // 本月第一天
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
exports.showNextWeekFirstDay = showNextWeekFirstDay;
|
|
131
|
-
|
|
132
|
-
var showMonthFirstDay = function showMonthFirstDay() {
|
|
133
|
-
var Nowdate = new Date();
|
|
134
|
-
var MonthFirstDay = new Date(Nowdate.getFullYear(), Nowdate.getMonth(), 1);
|
|
135
|
-
var M = Number(MonthFirstDay.getMonth()) + 1;
|
|
136
|
-
return MonthFirstDay.getFullYear() + "-" + M + "-" + MonthFirstDay.getDate();
|
|
137
|
-
}; // 本月最后一天
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
exports.showMonthFirstDay = showMonthFirstDay;
|
|
141
|
-
|
|
142
|
-
var showMonthLastDay = function showMonthLastDay() {
|
|
143
|
-
var Nowdate = new Date();
|
|
144
|
-
var MonthNextFirstDay = new Date(Nowdate.getFullYear(), Nowdate.getMonth() + 1, 1); // @ts-ignore
|
|
145
|
-
|
|
146
|
-
var MonthLastDay = new Date(MonthNextFirstDay - 86400000);
|
|
147
|
-
var M = Number(MonthLastDay.getMonth()) + 1;
|
|
148
|
-
return MonthLastDay.getFullYear() + "-" + M + "-" + MonthLastDay.getDate();
|
|
149
|
-
}; // 下个月第一天
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
exports.showMonthLastDay = showMonthLastDay;
|
|
153
|
-
|
|
154
|
-
var showNextMonthFirstDay = function showNextMonthFirstDay() {
|
|
155
|
-
var Nowdate = new Date();
|
|
156
|
-
var MonthFirstDay = new Date(Nowdate.getFullYear(), Nowdate.getMonth() + 1, 1);
|
|
157
|
-
var M = Number(MonthFirstDay.getMonth()) + 1;
|
|
158
|
-
return MonthFirstDay.getFullYear() + "-" + M + "-" + MonthFirstDay.getDate();
|
|
159
|
-
};
|
|
160
|
-
|
|
161
|
-
exports.showNextMonthFirstDay = showNextMonthFirstDay;
|
package/lib/utils/helpers.js
DELETED
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.cssSupport = cssSupport;
|
|
7
|
-
exports.getUploadMaxSize = getUploadMaxSize;
|
|
8
|
-
exports.getTenantInfo = getTenantInfo;
|
|
9
|
-
exports.isDingDing = void 0;
|
|
10
|
-
|
|
11
|
-
var _bsGlobal = require("./bs-global");
|
|
12
|
-
|
|
13
|
-
function cssSupport(attr, value) {
|
|
14
|
-
var element = document.createElement('div');
|
|
15
|
-
|
|
16
|
-
if (attr in element.style) {
|
|
17
|
-
element.style[attr] = value;
|
|
18
|
-
return element.style[attr] === value;
|
|
19
|
-
} else {
|
|
20
|
-
return false;
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
function getUploadMaxSize() {
|
|
25
|
-
var info = (0, _bsGlobal.getBSGlobal)('tenantInfo');
|
|
26
|
-
var isDingDing = info.Source == 861;
|
|
27
|
-
var isDingZhi = window['dingZhiSize'] && window['dingZhiSize'].indexOf(info.Id) != -1;
|
|
28
|
-
if (isDingDing) return 20;
|
|
29
|
-
if (isDingZhi) return 100;
|
|
30
|
-
return 50;
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
function getTenantInfo() {
|
|
34
|
-
return (0, _bsGlobal.getBSGlobal)('tenantInfo');
|
|
35
|
-
}
|
|
36
|
-
|
|
37
|
-
var isDingDing = function isDingDing() {
|
|
38
|
-
return getTenantInfo().Source == 861;
|
|
39
|
-
};
|
|
40
|
-
|
|
41
|
-
exports.isDingDing = isDingDing;
|
package/lib/utils/roundWeight.js
DELETED
|
@@ -1,105 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
|
|
3
|
-
Object.defineProperty(exports, "__esModule", {
|
|
4
|
-
value: true
|
|
5
|
-
});
|
|
6
|
-
exports.RoundWeight = RoundWeight;
|
|
7
|
-
exports.ReCalibratePrecision = ReCalibratePrecision;
|
|
8
|
-
exports.AccAdd = AccAdd;
|
|
9
|
-
exports.AccMul = AccMul;
|
|
10
|
-
|
|
11
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) { symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); } keys.push.apply(keys, symbols); } return keys; }
|
|
12
|
-
|
|
13
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; }
|
|
14
|
-
|
|
15
|
-
function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
|
|
16
|
-
|
|
17
|
-
function RoundWeight(value) {
|
|
18
|
-
var _value = Number(value);
|
|
19
|
-
|
|
20
|
-
if (Number.isInteger(_value)) {
|
|
21
|
-
return _value.toFixed(0);
|
|
22
|
-
} else if (_value >= 99.96) {
|
|
23
|
-
return 100;
|
|
24
|
-
} else {
|
|
25
|
-
return _value.toFixed(1);
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
/**
|
|
29
|
-
*
|
|
30
|
-
* @description 收集一组含有权重的数据,如果找到其中一个权重有小数点,那么全都是小数点后一位,否则就全是整数
|
|
31
|
-
* @export
|
|
32
|
-
* @param {any[]} milepostData
|
|
33
|
-
* @returns any[]
|
|
34
|
-
*/
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
function ReCalibratePrecision(milepostData) {
|
|
38
|
-
// NOTE 后端返回的数据不一定是整数
|
|
39
|
-
var index = milepostData.findIndex(function (_ref) {
|
|
40
|
-
var krWeight = _ref.krWeight;
|
|
41
|
-
return !Number.isInteger(Number(krWeight));
|
|
42
|
-
});
|
|
43
|
-
|
|
44
|
-
if (index !== -1) {
|
|
45
|
-
return milepostData.map(function (data) {
|
|
46
|
-
return _objectSpread(_objectSpread({}, data), {}, {
|
|
47
|
-
krWeight: Number(data.krWeight).toFixed(1)
|
|
48
|
-
});
|
|
49
|
-
});
|
|
50
|
-
} else {
|
|
51
|
-
return milepostData;
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
function AccAdd(arg1, arg2) {
|
|
56
|
-
var r1, r2, m, c;
|
|
57
|
-
|
|
58
|
-
try {
|
|
59
|
-
r1 = arg1.toString().split(".")[1].length;
|
|
60
|
-
} catch (e) {
|
|
61
|
-
r1 = 0;
|
|
62
|
-
}
|
|
63
|
-
|
|
64
|
-
try {
|
|
65
|
-
r2 = arg2.toString().split(".")[1].length;
|
|
66
|
-
} catch (e) {
|
|
67
|
-
r2 = 0;
|
|
68
|
-
}
|
|
69
|
-
|
|
70
|
-
c = Math.abs(r1 - r2);
|
|
71
|
-
m = Math.pow(10, Math.max(r1, r2));
|
|
72
|
-
|
|
73
|
-
if (c > 0) {
|
|
74
|
-
var cm = Math.pow(10, c);
|
|
75
|
-
|
|
76
|
-
if (r1 > r2) {
|
|
77
|
-
arg1 = Number(arg1.toString().replace(".", ""));
|
|
78
|
-
arg2 = Number(arg2.toString().replace(".", "")) * cm;
|
|
79
|
-
} else {
|
|
80
|
-
arg1 = Number(arg1.toString().replace(".", "")) * cm;
|
|
81
|
-
arg2 = Number(arg2.toString().replace(".", ""));
|
|
82
|
-
}
|
|
83
|
-
} else {
|
|
84
|
-
arg1 = Number(arg1.toString().replace(".", ""));
|
|
85
|
-
arg2 = Number(arg2.toString().replace(".", ""));
|
|
86
|
-
}
|
|
87
|
-
|
|
88
|
-
return (arg1 + arg2) / m;
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
function AccMul(arg1, arg2) {
|
|
92
|
-
var m = 0,
|
|
93
|
-
s1 = arg1.toString(),
|
|
94
|
-
s2 = arg2.toString();
|
|
95
|
-
|
|
96
|
-
try {
|
|
97
|
-
m += s1.split(".")[1].length;
|
|
98
|
-
} catch (e) {}
|
|
99
|
-
|
|
100
|
-
try {
|
|
101
|
-
m += s2.split(".")[1].length;
|
|
102
|
-
} catch (e) {}
|
|
103
|
-
|
|
104
|
-
return Number(s1.replace(".", "")) * Number(s2.replace(".", "")) / Math.pow(10, m);
|
|
105
|
-
}
|