@bit-sun/business-component 4.0.7 → 4.0.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@bit-sun/business-component",
3
- "version": "4.0.7",
3
+ "version": "4.0.8",
4
4
  "scripts": {
5
5
  "start": "dumi dev",
6
6
  "docs:build": "dumi build",
@@ -1,18 +1,16 @@
1
1
  <?xml version="1.0" encoding="UTF-8"?>
2
- <svg width="34px" height="34px" viewBox="0 0 34 34" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
3
- <title>矩形</title>
4
- <g id="列表功能" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
5
- <g id="星澜-搜索-搜索功能" transform="translate(-1865.000000, -297.000000)">
6
- <g id="搜索组件-样式一" transform="translate(230.000000, 284.000000)">
7
- <g id="确定备份-2" transform="translate(1636.000000, 14.000000)">
8
- <path d="M4.55801813,-4.10857923e-16 L27.4419819,1.84149388e-16 C29.0269041,-1.06996098e-16 29.6016352,0.165023309 30.181059,0.474902584 C30.7604829,0.78478186 31.2152181,1.2395171 31.5250974,1.81894097 C31.8349767,2.39836484 32,2.97309593 32,4.55801813 L32,27.4419819 C32,29.0269041 31.8349767,29.6016352 31.5250974,30.181059 C31.2152181,30.7604829 30.7604829,31.2152181 30.181059,31.5250974 C29.6016352,31.8349767 29.0269041,32 27.4419819,32 L4.55801813,32 C2.97309593,32 2.39836484,31.8349767 1.81894097,31.5250974 C1.2395171,31.2152181 0.78478186,30.7604829 0.474902584,30.181059 C0.165023309,29.6016352 2.03054919e-16,29.0269041 -3.49474794e-16,27.4419819 L1.22766259e-16,4.55801813 C-7.13307317e-17,2.97309593 0.165023309,2.39836484 0.474902584,1.81894097 C0.78478186,1.2395171 1.2395171,0.78478186 1.81894097,0.474902584 C2.39836484,0.165023309 2.97309593,2.38720285e-16 4.55801813,-4.10857923e-16 Z" id="矩形" stroke="#D9D9D9" stroke-width="0.888888889"></path>
9
- <g id="scanning" transform="translate(8.000000, 8.000000)" fill="#000000" fill-rule="nonzero">
10
- <g id="编组">
11
- <path d="M6.7386444,0 L9.31914658,0.00400859106 C10.1203579,0.00538861113 10.7694605,0.676782175 10.7705276,1.50523181 L10.7714968,1.94016563 C11.2713795,2.15465212 11.7449087,2.42965745 12.1821713,2.75942463 L12.5276921,2.55398355 C13.2221154,2.14077391 14.108963,2.38638205 14.5106808,3.10316266 L15.8040818,5.41212013 C16.1892138,6.09972811 15.990279,6.97849852 15.3500104,7.41792671 L15.2710204,7.46803431 L14.9240458,7.67497861 C14.9836517,8.24420078 14.9763827,8.82244228 14.8983619,9.39717628 L15.1435702,9.54399151 C15.8102761,9.94190072 16.0614337,10.8082131 15.716369,11.5197335 L15.6761471,11.5974003 L14.4646437,13.7670587 C14.079817,14.4564299 13.2419875,14.7161258 12.5538606,14.3593303 L12.4782628,14.3172399 L12.1434032,14.1168096 C11.7223166,14.4300773 11.2678576,14.692352 10.7889425,14.8984879 L10.7889425,15.4947682 C10.7899403,16.2891527 10.1930007,16.9472128 9.42624347,16.9969935 L9.33368462,17 L6.75318244,16.9959914 C5.95216,16.9946121 5.30313532,16.3235232 5.30180138,15.4952693 L5.30034758,14.7762254 C4.90043094,14.5820591 4.5195493,14.3484795 4.16298822,14.0787278 L3.54463691,14.4465175 C2.85008695,14.8596428 1.96320036,14.6137998 1.56164819,13.8968373 L0.268247179,11.5883809 C-0.117195104,10.9006602 0.0817705641,10.0215335 0.722318635,9.58207327 L0.80130867,9.53196569 L1.43032121,9.15766204 C1.38186108,8.68163998 1.37943806,8.20010611 1.42595979,7.71957437 L0.727649258,7.30217819 C0.0607645902,6.90443662 -0.19061709,6.03808438 0.154365869,5.32643616 L0.195072383,5.2487694 L1.40657575,3.07911102 C1.7914024,2.38973985 2.62923197,2.13004387 3.31735886,2.48683938 L3.39247208,2.52892975 L4.00113138,2.89220974 C4.39780188,2.57239271 4.82771303,2.29929047 5.28290193,2.0779615 L5.28290193,1.50573288 C5.28164777,0.711155235 5.87865691,0.0527989874 6.64560094,0.00300645504 L6.73815978,0 L6.7386444,0 Z M6.73670598,1.50322752 L6.73815978,3.03150881 L5.90270707,3.43788133 C5.54507128,3.61175466 5.20730414,3.8262151 4.89619006,4.0772541 L4.12373551,4.70059245 L2.70239975,3.85176997 L2.66605465,3.83072478 L1.45455128,6.00038316 L2.96650749,6.90282076 L2.87249482,7.86939606 C2.83614972,8.24470187 2.83760352,8.6235152 2.87588705,8.99882099 L2.97571491,9.97191026 L1.52675689,10.8347629 L2.81967328,13.1432193 L4.2584547,12.2878828 L5.02170182,12.8656232 C5.3027003,13.0784515 5.60293338,13.2627017 5.9182143,13.4158045 L6.75269782,13.8211749 L6.75560543,15.4927639 L9.33562302,15.4967725 L9.33416922,13.8958352 L10.2306817,13.5100068 C10.6067559,13.348282 10.9636539,13.1424989 11.2943817,12.8966899 L12.0571442,12.3299732 L13.2056494,13.0154449 L14.4161836,10.8452855 L13.3229229,10.1918826 L13.4586113,9.18922982 C13.5191865,8.74076695 13.5259709,8.28679224 13.4789646,7.83632505 L13.3771983,6.86273469 L14.5460567,6.16523712 L13.2526557,3.85678072 L12.0896125,4.54976861 L11.3258808,3.97403247 C10.9812567,3.71415335 10.6081041,3.4973506 10.2142053,3.32814572 L9.31963118,2.94432162 L9.31672357,1.50723611 L6.73670598,1.50322752 L6.73670598,1.50322752 Z M9.63026065,5.81849263 C11.020555,6.64989539 11.4971522,8.48836517 10.6954144,9.92731453 C10.31057,10.6180868 9.67584239,11.1222493 8.93115445,11.3286616 C8.18646651,11.5350739 7.39296008,11.4267887 6.72556016,11.0276771 C5.33544167,10.1961028 4.85907177,8.35767345 5.66089098,6.91885517 C6.04573388,6.22821897 6.68037324,5.72415423 7.42494422,5.51774917 C8.16951519,5.3113441 8.9629043,5.41954018 9.63026065,5.81849263 L9.63026065,5.81849263 Z M6.91988529,7.6694668 C6.5185962,8.38978735 6.75708884,9.31005529 7.45294678,9.72638311 C7.78629255,9.92588707 8.18270902,9.98005276 8.55473096,9.87692908 C8.92675291,9.7738054 9.24380592,9.5218675 9.4359355,9.17670291 C9.82059563,8.48612828 9.61887592,7.60527314 8.97556421,7.16638665 L8.90287401,7.11978659 L8.82776082,7.07819729 C8.14078385,6.72100469 7.30360294,6.98045534 6.91988529,7.6694668 L6.91988529,7.6694668 Z" id="形状"></path>
12
- </g>
13
- </g>
14
- </g>
15
- </g>
2
+ <svg width="24px" height="24px" viewBox="0 0 24 24" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
3
+ <title>蒙版@1x</title>
4
+ <defs>
5
+ <polygon id="path-1" points="1.97175609e-13 0 24 0 24 24 1.97175609e-13 24"></polygon>
6
+ </defs>
7
+ <g id="【销售订单】-列表" stroke="none" stroke-width="1" fill="none" fill-rule="evenodd">
8
+ <g id="编组-13备份">
9
+ <mask id="mask-2" fill="white">
10
+ <use xlink:href="#path-1"></use>
11
+ </mask>
12
+ <use id="蒙版" fill="#FAFAFA" opacity="0" xlink:href="#path-1"></use>
13
+ <path d="M11.0539833,6 L12.9893599,6.00306539 C13.5902684,6.0041207 14.0770953,6.51753931 14.0778957,7.15105962 L14.0786226,7.48365607 C14.4535346,7.64767515 14.8086815,7.85797334 15.1366285,8.11014825 L15.3957691,7.95304625 C15.9165865,7.6370624 16.5817222,7.82488039 16.8830106,8.37300674 L17.8530614,10.1386801 C18.1419103,10.664498 17.9927093,11.3364989 17.5125078,11.6725322 L17.4532653,11.7108498 L17.1930343,11.8691013 C17.2377388,12.3043888 17.232287,12.7465735 17.1737714,13.186076 L17.3576776,13.2983464 C17.857707,13.60263 18.0460753,14.2651041 17.7872767,14.809208 L17.7571103,14.8686002 L16.8484828,16.5277508 C16.5598628,17.0549169 15.9314906,17.253508 15.4153954,16.9806644 L15.3586971,16.9484776 L15.1075524,16.7952074 C14.7917375,17.034765 14.4508932,17.235328 14.0917069,17.3929614 L14.0917069,17.8489404 C14.0924552,18.4564109 13.6447505,18.9596333 13.0696826,18.9977009 L13.0002635,19 L11.0648868,18.9969346 C10.46412,18.9958799 9.97735149,18.4826942 9.97635104,17.8493235 L9.97526069,17.2994665 C9.67532321,17.1509864 9.38966197,16.9723666 9.12224117,16.766086 L8.65847768,17.0473369 C8.13756521,17.3632563 7.47240027,17.1752586 7.17123614,16.6269932 L6.20118538,14.8617031 C5.91210367,14.335799 6.06132792,13.6635256 6.54173898,13.3274678 L6.6009815,13.2891502 L7.0727409,13.002918 C7.03639581,12.6389012 7.03457855,12.2706694 7.06946985,11.9032039 L6.54573694,11.5840186 C6.04557344,11.2798633 5.85703718,10.6173586 6.1157744,10.0731571 L6.14630429,10.0137648 L7.05493181,8.35461431 C7.3435518,7.82744812 7.97192398,7.62885707 8.48801915,7.9017007 L8.54435406,7.93388746 L9.00084853,8.2116898 C9.29835141,7.96712383 9.62078477,7.75828095 9.96217645,7.58902938 L9.96217645,7.15144279 C9.96123583,6.54382459 10.4089927,6.0403757 10.9842007,6.00229905 L11.0536198,6 L11.0539833,6 Z M11.0525295,7.14952693 L11.0536198,8.31821262 L10.4270303,8.62896808 C10.1588035,8.76193003 9.90547811,8.92592919 9.67214254,9.11790019 L9.09280163,9.5945707 L8.02679981,8.94547115 L7.99954099,8.92937778 L7.09091346,10.5885283 L8.22488062,11.2786276 L8.15437112,12.0177735 C8.12711229,12.304772 8.12820264,12.5944528 8.15691528,12.8814513 L8.23178618,13.6255784 L7.14506767,14.2854069 L8.11475496,16.0506971 L9.19384102,15.3966163 L9.76627637,15.8384178 C9.97702523,16.0011688 10.2022,16.142066 10.4386607,16.2591446 L11.0645234,16.5691337 L11.0667041,17.8474077 L13.0017173,17.8504731 L13.0006269,16.6262269 L13.6730113,16.3311816 C13.9550669,16.2075098 14.2227404,16.0501462 14.4707863,15.8621747 L15.0428581,15.428803 L15.904237,15.9529873 L16.8121377,14.2934536 L15.9921922,13.7937926 L16.0939585,13.0270581 C16.1393899,12.6841159 16.1444782,12.3369588 16.1092234,11.9924839 L16.0328987,11.2479736 L16.9095425,10.7145931 L15.9394918,8.9493029 L15.0672094,9.47923482 L14.4944106,9.038966 C14.2359425,8.84023491 13.9560781,8.67444458 13.6606539,8.54505261 L12.9897234,8.25154006 L12.9875427,7.15259232 L11.0525295,7.14952693 L11.0525295,7.14952693 Z M13.2226955,10.4494355 C14.2654163,11.0852141 14.6228641,12.4911028 14.0215608,13.5914758 C13.7329275,14.1197135 13.2568818,14.5052495 12.6983658,14.6630942 C12.1398499,14.8209389 11.5447201,14.7381326 11.0441701,14.4329295 C10.0015813,13.7970198 9.64430382,12.3911621 10.2456682,11.2908893 C10.5343004,10.7627557 11.0102799,10.3772944 11.5687082,10.2194552 C12.1271364,10.0616161 12.7221782,10.1443543 13.2226955,10.4494355 L13.2226955,10.4494355 Z M11.189914,11.8648864 C10.8889471,12.4157197 11.0678166,13.119454 11.5897101,13.4378224 C11.8397194,13.5903842 12.1370318,13.6318051 12.4160482,13.5529458 C12.6950647,13.4740865 12.9328544,13.2814281 13.0769516,13.0174787 C13.3654467,12.4893922 13.2141569,11.8157971 12.7316732,11.480178 L12.6771555,11.4445427 L12.6208206,11.4127391 C12.1055879,11.1395918 11.4777022,11.3379953 11.189914,11.8648864 L11.189914,11.8648864 Z" id="形状" fill="#4C4E4D" fill-rule="nonzero" mask="url(#mask-2)"></path>
16
14
  </g>
17
15
  </g>
18
16
  </svg>
@@ -225,4 +225,8 @@
225
225
  }
226
226
  }
227
227
  }
228
+
229
+ .ant-dropdown-link {
230
+ cursor: pointer;
231
+ }
228
232
  }
@@ -450,7 +450,7 @@ export default (props: any) => {
450
450
  x: props.overScrollX || 'max-content',
451
451
  y: props?.overScrollY || height,
452
452
  },
453
- bordered: value.bordered || false,
453
+ bordered: value.bordered || true,
454
454
  sticky: true,
455
455
  rowClassName: (record: object | null | undefined, index: number) =>
456
456
  index % 2 === 0 ? 'table_base' : 'table_odd',
@@ -536,87 +536,57 @@ export default (props: any) => {
536
536
  ]);
537
537
  }
538
538
 
539
- actionsRender = actionsRender.concat([
540
- {
541
- type: 'text',
542
- props: {
543
- children: (
544
- <a>
545
- {isFullScreen ? (
546
- <Tooltip title="取消全屏">
547
- <img
548
- onClick={() => {
549
- ShowFullScreen();
550
- }}
551
- width={32}
552
- src={scanning}
553
- />
554
- </Tooltip>
555
- ) : (
556
- <Tooltip title="全屏">
557
- <img
558
- onClick={() => {
559
- ShowFullScreen();
560
- }}
561
- width={32}
562
- src={quanping}
563
- />
564
- </Tooltip>
565
- )}
566
- </a>
567
- ),
568
- },
569
- },
570
- {
571
- type: 'text',
572
- props: {
573
- children: (
574
- <span className="ant-dropdown-link">
575
- <Dropdown
576
- overlay={
577
- <Menu>
578
- <Menu.Item>
579
- <div
580
- onClick={sortTableRef?.current?.showModal}
581
- style={{ fontSize: 14, textAlign: 'center' }}
582
- >
583
- 列设置
584
- </div>
585
- </Menu.Item>
586
- {!value?.searchConfig?.isHidden && (
587
- <Menu.Item>
588
- <SearchItemTable
589
- ref={searchTableRef}
590
- setShowSearchFields={setShowSearchFields}
591
- showSearchFields={showSearchFields}
592
- datasource={value?.fields || []}
593
- bsTableCode={bsTableCode}
594
- />
595
- </Menu.Item>
596
- )}
597
- {value?.exportConfig?.settingColumns && (
598
- <Menu.Item>
599
- <div
600
- onClick={exportTableRef?.current?.showModal}
601
- style={{ fontSize: 14, textAlign: 'center' }}
602
- >
603
- 导出字段设置
604
- </div>
605
- </Menu.Item>
606
- )}
607
- </Menu>
608
- }
609
- placement="bottomRight"
610
- >
611
- <div className="ant-dropdown-link">
612
- <img width={32} src={shezhi} />
613
- </div>
614
- </Dropdown>
615
- </span>
616
- ),
617
- },
618
- },
619
- ]);
539
+ // actionsRender = actionsRender.concat([
540
+ // {
541
+ // type: 'text',
542
+ // props: {
543
+ // children: (
544
+ // <span className="ant-dropdown-link">
545
+ // <Dropdown
546
+ // overlay={
547
+ // <Menu>
548
+ // <Menu.Item>
549
+ // <div
550
+ // onClick={sortTableRef?.current?.showModal}
551
+ // style={{ fontSize: 14, textAlign: 'center' }}
552
+ // >
553
+ // 列设置
554
+ // </div>
555
+ // </Menu.Item>
556
+ // {!value?.searchConfig?.isHidden && (
557
+ // <Menu.Item>
558
+ // <SearchItemTable
559
+ // ref={searchTableRef}
560
+ // setShowSearchFields={setShowSearchFields}
561
+ // showSearchFields={showSearchFields}
562
+ // datasource={value?.fields || []}
563
+ // bsTableCode={bsTableCode}
564
+ // />
565
+ // </Menu.Item>
566
+ // )}
567
+ // {value?.exportConfig?.settingColumns && (
568
+ // <Menu.Item>
569
+ // <div
570
+ // onClick={exportTableRef?.current?.showModal}
571
+ // style={{ fontSize: 14, textAlign: 'center' }}
572
+ // >
573
+ // 导出字段设置
574
+ // </div>
575
+ // </Menu.Item>
576
+ // )}
577
+ // </Menu>
578
+ // }
579
+ // placement="bottomRight"
580
+ // >
581
+ // <div className="ant-dropdown-link">
582
+ // <img width={32} src={shezhi} />
583
+ // </div>
584
+ // </Dropdown>
585
+ // </span>
586
+ // ),
587
+ // },
588
+ // },
589
+ // ]);
620
590
  if (value.rowSelection) {
621
591
  value.rowSelection.columnWidth = 50;
622
592
  }
@@ -688,7 +658,19 @@ export default (props: any) => {
688
658
  rowSelection: false, // 默认无多选
689
659
  ...handleTimeValue(),
690
660
  tableProps: setTableProps(),
691
- columns: getColumns(),
661
+ columns: [...getColumns(), {
662
+ key: 'setting',
663
+ title: <span className="ant-dropdown-link">
664
+ <div onClick={sortTableRef?.current?.showModal} className="ant-dropdown-link">
665
+ <img style={{position: 'relative', left: '-7px'}} width={24} src={shezhi} />
666
+ </div>
667
+ </span>,
668
+ width: '24px',
669
+ fixed: 'right',
670
+ render: ({ text, record }: any) => {
671
+ return ' '
672
+ },
673
+ }],
692
674
  fields: [...showSearchFields],
693
675
  ref: props.forwardedRef || refs,
694
676
  isFullScreen,
@@ -52,6 +52,37 @@
52
52
  word-break: keep-all;
53
53
  }
54
54
 
55
+ .ant-radio-button-wrapper > .ant-radio-button {
56
+ font-size: 12px;
57
+ font-weight: 400;
58
+ }
59
+
60
+ .ant-radio-button-wrapper {
61
+ padding: 0 8px;
62
+ border: 0;
63
+ background: #F0F0F0;
64
+ color: #A3A3A3;
65
+ line-height: 24px;
66
+ }
67
+
68
+ .ant-radio-button-wrapper:not(:first-child)::before {
69
+ display: none;
70
+ }
71
+
72
+ .ant-radio-group.ant-radio-group-outline .ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled) {
73
+ line-height: 20px;
74
+ font-weight: 500;
75
+ border: 0;
76
+ background: #FFFFFF;
77
+ border: 2px #F0F0F0 solid;
78
+ height: 24px;
79
+ color: #131415;
80
+ }
81
+
82
+ .ant-radio-button-wrapper:first-child {
83
+ border: 0px;
84
+ }
85
+
55
86
 
56
87
  html,
57
88
  body {
@@ -157,7 +188,7 @@ body {
157
188
  .ant-table-thead
158
189
  > tr
159
190
  > th {
160
- min-width: 60px;
191
+ min-width: 30px;
161
192
  }
162
193
 
163
194
  .ant-table.ant-table-middle
@@ -292,7 +323,7 @@ body {
292
323
  .ant-table-tbody
293
324
  > tr
294
325
  > td.ant-table-cell {
295
- min-width: 60px;
326
+ min-width: 30px;
296
327
  }
297
328
  .ant-table-sticky-scroll {
298
329
  position: fixed !important;
@@ -436,7 +467,7 @@ body {
436
467
  .ant-table-thead
437
468
  > tr
438
469
  > th {
439
- min-width: 60px;
470
+ min-width: 30px;
440
471
  }
441
472
 
442
473
  .ant-table.ant-table-middle