cnhis-design-vue 2.1.71 → 2.1.72

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.
Files changed (93) hide show
  1. package/CHANGELOG.md +489 -395
  2. package/es/affix/index.js +8 -8
  3. package/es/age/index.js +10 -10
  4. package/es/alert/index.js +8 -8
  5. package/es/anchor/index.js +8 -8
  6. package/es/auto-complete/index.js +8 -8
  7. package/es/avatar/index.js +8 -8
  8. package/es/back-top/index.js +8 -8
  9. package/es/badge/index.js +8 -8
  10. package/es/base/index.js +8 -8
  11. package/es/big-table/index.js +68 -68
  12. package/es/breadcrumb/index.js +8 -8
  13. package/es/button/index.js +22 -22
  14. package/es/calendar/index.js +8 -8
  15. package/es/captcha/index.js +3 -3
  16. package/es/card/index.js +8 -8
  17. package/es/carousel/index.js +8 -8
  18. package/es/cascader/index.js +8 -8
  19. package/es/checkbox/index.js +9 -9
  20. package/es/col/index.js +8 -8
  21. package/es/collapse/index.js +8 -8
  22. package/es/color-picker/index.js +1 -1
  23. package/es/comment/index.js +8 -8
  24. package/es/config-provider/index.js +8 -8
  25. package/es/date-picker/index.js +8 -8
  26. package/es/descriptions/index.js +8 -8
  27. package/es/divider/index.js +8 -8
  28. package/es/drag-layout/index.js +3 -3
  29. package/es/drawer/index.js +8 -8
  30. package/es/dropdown/index.js +8 -8
  31. package/es/editor/index.js +1 -1
  32. package/es/ellipsis/index.js +1 -1
  33. package/es/empty/index.js +8 -8
  34. package/es/fabric-chart/index.js +9 -9
  35. package/es/form/index.js +8 -8
  36. package/es/form-model/index.js +8 -8
  37. package/es/form-table/index.js +66 -66
  38. package/es/index/index.js +394 -394
  39. package/es/input/index.js +9 -9
  40. package/es/input-number/index.js +8 -8
  41. package/es/layout/index.js +8 -8
  42. package/es/list/index.js +8 -8
  43. package/es/locale-provider/index.js +8 -8
  44. package/es/map/index.js +9 -9
  45. package/es/mentions/index.js +8 -8
  46. package/es/menu/index.js +8 -8
  47. package/es/message/index.js +8 -8
  48. package/es/multi-chat/index.js +76 -76
  49. package/es/multi-chat-client/index.js +70 -70
  50. package/es/multi-chat-history/index.js +4 -4
  51. package/es/multi-chat-record/index.js +14 -14
  52. package/es/multi-chat-setting/index.js +22 -22
  53. package/es/multi-chat-sip/index.js +1 -1
  54. package/es/notification/index.js +8 -8
  55. package/es/page-header/index.js +8 -8
  56. package/es/pagination/index.js +8 -8
  57. package/es/popconfirm/index.js +8 -8
  58. package/es/popover/index.js +8 -8
  59. package/es/progress/index.js +8 -8
  60. package/es/radio/index.js +9 -9
  61. package/es/rate/index.js +8 -8
  62. package/es/result/index.js +8 -8
  63. package/es/row/index.js +8 -8
  64. package/es/scale-container/index.js +1 -1
  65. package/es/scale-view/index.js +27 -27
  66. package/es/select/index.js +12 -12
  67. package/es/select-label/index.js +11 -11
  68. package/es/select-person/index.js +2 -2
  69. package/es/shortcut-setter/index.js +10 -10
  70. package/es/skeleton/index.js +8 -8
  71. package/es/slider/index.js +8 -8
  72. package/es/space/index.js +8 -8
  73. package/es/spin/index.js +8 -8
  74. package/es/statistic/index.js +8 -8
  75. package/es/steps/index.js +8 -8
  76. package/es/switch/index.js +8 -8
  77. package/es/table-filter/index.js +49 -49
  78. package/es/tabs/index.js +8 -8
  79. package/es/tag/index.js +9 -9
  80. package/es/time-picker/index.js +8 -8
  81. package/es/timeline/index.js +8 -8
  82. package/es/tooltip/index.js +8 -8
  83. package/es/transfer/index.js +8 -8
  84. package/es/tree/index.js +8 -8
  85. package/es/tree-select/index.js +8 -8
  86. package/es/upload/index.js +8 -8
  87. package/es/utils/time-domain.js +30 -0
  88. package/es/verification-code/index.js +2 -2
  89. package/lib/cui.common.js +347 -317
  90. package/lib/cui.umd.js +347 -317
  91. package/lib/cui.umd.min.js +5 -5
  92. package/package.json +1 -1
  93. package/src/utils/time-domain.js +59 -3
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "cnhis-design-vue",
3
- "version": "2.1.71",
3
+ "version": "2.1.72",
4
4
  "description": "前端业务UI库",
5
5
  "keyword": "cnhis-design-vue vue cnhis",
6
6
  "homepage": "http://dv.cnhis.com/",
@@ -60,6 +60,62 @@ const timeDomain = {
60
60
  return [start, end];
61
61
  },
62
62
 
63
+ LAST_YEAR() {
64
+ const start = moment()
65
+ .add(-1, 'y')
66
+ .startOf('year');
67
+ const end = moment()
68
+ .add(-1, 'y')
69
+ .endOf('year');
70
+ return [start, end];
71
+ },
72
+
73
+ LAST_MONTH() {
74
+ const start = moment()
75
+ .add(-1, 'M')
76
+ .startOf('month');
77
+ const end = moment()
78
+ .add(-1, 'M')
79
+ .endOf('month');
80
+ return [start, end];
81
+ },
82
+
83
+ LAST_WEEK() {
84
+ const start = moment()
85
+ .add(-1, 'w')
86
+ .startOf('week');
87
+ const end = moment()
88
+ .add(-1, 'w')
89
+ .endOf('week');
90
+ return [start, end];
91
+ },
92
+
93
+ THIS_QUARTER() {
94
+ const start = moment().startOf('quarter');
95
+ const end = moment().endOf('quarter');
96
+ return [start, end];
97
+ },
98
+
99
+ NEXT_QUARTER() {
100
+ const start = moment()
101
+ .add(1, 'Q')
102
+ .startOf('quarter');
103
+ const end = moment()
104
+ .add(1, 'Q')
105
+ .endOf('quarter');
106
+ return [start, end];
107
+ },
108
+
109
+ LAST_QUARTER() {
110
+ const start = moment()
111
+ .add(-1, 'Q')
112
+ .startOf('quarter');
113
+ const end = moment()
114
+ .add(-1, 'Q')
115
+ .endOf('quarter');
116
+ return [start, end];
117
+ },
118
+
63
119
  NEXT_WEEK() {
64
120
  return timeDomain.getNextWeek(1);
65
121
  },
@@ -179,9 +235,9 @@ const timeDomain = {
179
235
 
180
236
  getTimeDomain(type, format) {
181
237
  if (timeDomain[type]) {
182
- let res = timeDomain[type]();
183
- if(typeof format === 'string'){
184
- return res.map(v => v.format(type))
238
+ let res = timeDomain[type]();
239
+ if (typeof format === 'string') {
240
+ return res.map(v => v.format(type));
185
241
  }
186
242
  return res;
187
243
  } else {