chain-saasui 1.0.10-alpha.0 → 1.0.10-alpha.2

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.
@@ -12,3 +12,4 @@
12
12
  @import './form.scss';
13
13
  @import './button.scss';
14
14
  @import './space.scss';
15
+ @import './steps.scss';
@@ -8,12 +8,12 @@
8
8
  border-radius: 8px;
9
9
  // overflow-y: inherit;
10
10
  }
11
- .saas-page-table-header {
11
+ .saas-page-table__header {
12
12
  // margin-bottom: 16px;
13
13
  flex-shrink: 0;
14
14
  }
15
15
 
16
- .saas-page-table-menu {
16
+ .saas-page-table__menu {
17
17
  display: flex;
18
18
  align-items: center;
19
19
  font-size: 16px;
@@ -22,22 +22,32 @@
22
22
  margin-bottom: 16px;
23
23
  }
24
24
 
25
- .saas-page-table-menu.hasClose {
25
+ .saas-page-table__menu.hasClose {
26
26
  font-weight: 400;
27
27
  }
28
- .saas-page-table-back_title {
28
+ .saas-page-table__back-title {
29
29
  margin-right: 16px;
30
30
  }
31
- .saas-page-table-title_line {
31
+ .saas-page-table__title-line {
32
32
  height: 14px;
33
33
  width: 1px;
34
34
  background: #dbdee7;
35
35
  margin-right: 16px;
36
36
  }
37
- .saas-page-table-sub {
37
+ .saas-page-table--hasButton .saas-page-table__footer {
38
+ padding-top: 16px;
39
+ padding-bottom: 16px;
40
+ margin: 0 -16px -16px;
41
+ text-align: center;
42
+ box-shadow: 8px 0 12px 0 rgba(161, 165, 178, 0.1);
43
+ border-radius: 0;
44
+ border-top: 1px solid #dbdee7;
45
+ }
46
+
47
+ .saas-page-table__sub {
38
48
  margin-top: 8px;
39
49
  }
40
- .saas-page-title-line {
50
+ .saas-page-header__line {
41
51
  // display: none;
42
52
  display: inline-block;
43
53
  width: 4px;
@@ -47,12 +57,12 @@
47
57
  vertical-align: middle;
48
58
  }
49
59
 
50
- .saas-page-table-backbox {
60
+ .saas-page-table__backbox {
51
61
  display: flex;
52
62
  align-items: center;
53
63
  top: 24px;
54
64
  }
55
- .saas-page-table-back {
65
+ .saas-page-table__back {
56
66
  display: flex;
57
67
  align-items: center;
58
68
  border-radius: 50%;
@@ -68,18 +78,18 @@
68
78
  background: rgb(247, 249, 251);
69
79
  }
70
80
  }
71
- .saas-page-table-title {
81
+ .saas-page-table__title {
72
82
  flex: 1;
73
83
  }
74
- .saas-page-table-form {
84
+ .saas-page-table__form {
75
85
  // margin-bottom: 16px;
76
86
  }
77
87
 
78
- .saas-page-table-content {
88
+ .saas-page-table__content {
79
89
  flex: 1;
80
90
  min-height: 300px;
81
91
  }
82
- .saas-page-table-footer {
92
+ .saas-page-table__footer {
83
93
  flex-shrink: 0;
84
94
  }
85
95
 
@@ -0,0 +1,129 @@
1
+ .saas-steps {
2
+ display: flex;
3
+ width: 100%;
4
+ font-size: 14px;
5
+ flex-direction: row;
6
+ align-items: center;
7
+
8
+ .saas-steps-item {
9
+ position: relative;
10
+ flex: 1;
11
+ overflow: hidden;
12
+ // padding-bottom: 16px;
13
+ white-space: nowrap;
14
+ }
15
+ }
16
+
17
+ /* 垂直方向样式 */
18
+ .saas-steps.vertical {
19
+ flex-direction: column;
20
+ }
21
+
22
+ .saas-steps-item:last-child {
23
+ flex: none;
24
+ }
25
+
26
+ .saas-steps-item-tail {
27
+ position: absolute;
28
+ top: 16px;
29
+ left: 16px;
30
+ width: calc(100% - 32px);
31
+ height: 1px;
32
+ background-color: #f0f0f0;
33
+ }
34
+
35
+ .vertical .saas-steps-item-tail {
36
+ width: 1px;
37
+ height: calc(100% - 32px);
38
+ left: 16px;
39
+ top: 32px;
40
+ }
41
+
42
+ .saas-steps-item-finish .saas-steps-item-tail {
43
+ background-color: #1890ff;
44
+ }
45
+
46
+ .saas-steps-item-icon {
47
+ width: 24px;
48
+ height: 24px;
49
+ margin-right: 8px;
50
+ background: #fff;
51
+ border: 1px solid #dbdee7;
52
+ border-radius: 50%;
53
+ line-height: 22px;
54
+ text-align: center;
55
+ font-size: 14px;
56
+ color: #dbdee7;
57
+ display: inline-block;
58
+ }
59
+
60
+ .saas-steps-item-active .saas-steps-item-icon {
61
+ border-color: #28b86a;
62
+ background-color: #28b86a;
63
+ color: #fff;
64
+ }
65
+
66
+ .saas-steps-item-finish .saas-steps-item-icon {
67
+ border-color: #28b86a;
68
+ color: #28b86a;
69
+ line-height: 25px;
70
+ }
71
+
72
+ .saas-steps-custom-icon {
73
+ font-size: 20px;
74
+ }
75
+
76
+ .saas-steps-item-content {
77
+ position: relative;
78
+ display: inline-block;
79
+ vertical-align: top;
80
+ }
81
+
82
+ .saas-steps-item-title {
83
+ color: #7c808a;
84
+ font-weight: normal;
85
+ overflow: hidden;
86
+ }
87
+
88
+ .saas-steps-item-active .saas-steps-item-title {
89
+ color: #0e1822;
90
+ }
91
+
92
+ .saas-steps-item-finish .saas-steps-item-title {
93
+ color: #0e1822;
94
+ }
95
+
96
+ .saas-steps-item-description {
97
+ color: rgba(0, 0, 0, 0.45);
98
+ font-size: 14px;
99
+ margin-top: 4px;
100
+ }
101
+
102
+ /* 对勾图标样式 */
103
+ .anticon {
104
+ display: inline-block;
105
+ width: 1em;
106
+ height: 1em;
107
+ fill: currentColor;
108
+ }
109
+
110
+ .saas-steps-item-title:after {
111
+ background: #dbdde7;
112
+ content: '';
113
+ display: block;
114
+ height: 1px;
115
+ left: 100%;
116
+ position: absolute;
117
+ top: 12px;
118
+ width: 9999px;
119
+ margin-left: 16px;
120
+ }
121
+ .saas-steps-item:not(:first-of-type) {
122
+ padding-left: 16px;
123
+ }
124
+ .saas-steps-item:last-of-type {
125
+ .saas-steps-item-title:after {
126
+ content: '';
127
+ display: none;
128
+ }
129
+ }
@@ -57,6 +57,10 @@ export default {
57
57
  return {};
58
58
  },
59
59
  },
60
+ index: {
61
+ type: Number,
62
+ default: 0,
63
+ },
60
64
  },
61
65
 
62
66
  data() {
@@ -90,10 +94,10 @@ export default {
90
94
  };
91
95
  },
92
96
  handleCommand(command) {
93
- this.$emit('action', command, this.row);
97
+ this.$emit('action', command, { ...this.row, _index: this.index });
94
98
  },
95
99
  handelClick(command) {
96
- this.$emit('action', command, this.row);
100
+ this.$emit('action', command, { ...this.row, _index: this.index });
97
101
  },
98
102
  },
99
103
  };
@@ -109,6 +109,26 @@ export default {
109
109
  return obj.label || '-';
110
110
  }
111
111
  },
112
+ filterOptions() {
113
+ return this.options
114
+ .filter(f => {
115
+ if (f.show === false) return false;
116
+ if (f.options && Array.isArray(f.options)) {
117
+ const visibleOptions = f.options.filter(option => option.show !== false);
118
+ return visibleOptions.length > 0;
119
+ }
120
+ return f.show !== false;
121
+ })
122
+ .map(f => {
123
+ if (f.options && Array.isArray(f.options)) {
124
+ return {
125
+ ...f,
126
+ options: f.options.filter(option => option.show !== false),
127
+ };
128
+ }
129
+ return f;
130
+ });
131
+ },
112
132
  },
113
133
  methods: {
114
134
  flattenOptions(options) {
@@ -1,20 +1,20 @@
1
1
  <template>
2
- <div class="saas-page-table">
3
- <div class="saas-page-table-header">
2
+ <div :class="['saas-page-table', { 'saas-page-table--hasButton': showFooterButton }]">
3
+ <div class="saas-page-table__header">
4
4
  <template v-if="showHeader">
5
5
  <div v-if="$slots.header">
6
6
  <slot name="header"></slot>
7
7
  </div>
8
- <div v-else class="saas-page-table-menu" :class="{ hasClose: showClose }">
8
+ <div v-else class="saas-page-table__menu" :class="{ hasClose: showClose }">
9
9
  <template v-if="showClose">
10
- <div class="saas-page-table-back" @click="goBack">
10
+ <div class="saas-page-table__back" @click="goBack">
11
11
  <span class="el-icon-arrow-left"></span>
12
12
  </div>
13
- <span class="saas-page-table-back_title">{{ $t('atSalaryFileImport.return') }}</span>
14
- <span class="saas-page-table-title_line"></span>
13
+ <span class="saas-page-table__back-title">{{ $t('atSalaryFileImport.return') }}</span>
14
+ <span class="saas-page-table__title-line"></span>
15
15
  </template>
16
- <span v-if="!showClose" class="saas-page-title-line"></span>
17
- <span class="saas-page-table-title">
16
+ <span v-if="!showClose" class="saas-page-header__line"></span>
17
+ <span class="saas-page-table__title">
18
18
  <template v-if="$slots.title">
19
19
  <slot name="title"></slot>
20
20
  </template>
@@ -23,15 +23,20 @@
23
23
  <slot name="header-append"></slot>
24
24
  </div>
25
25
  </template>
26
- <div class="saas-page-table-form">
26
+ <div class="saas-page-table__form">
27
27
  <slot name="form"></slot>
28
28
  </div>
29
29
  </div>
30
- <div class="saas-page-table-content">
30
+ <div class="saas-page-table__content">
31
31
  <slot></slot>
32
32
  </div>
33
- <div class="saas-page-table-footer">
34
- <slot name="footer"></slot>
33
+ <div class="saas-page-table__footer">
34
+ <slot name="footer">
35
+ <template v-if="showFooterButton">
36
+ <el-button @click="handleClose">{{ cancelText }}</el-button>
37
+ <el-button :loading="loadingBtn" type="primary" @click="handleSubmit" v-preventReClick="5000">{{ confirmText }}</el-button>
38
+ </template>
39
+ </slot>
35
40
  </div>
36
41
  </div>
37
42
  </template>
@@ -88,6 +93,10 @@ export default {
88
93
  type: Boolean,
89
94
  default: true,
90
95
  },
96
+ showFooterButton: {
97
+ type: Boolean,
98
+ default: false,
99
+ },
91
100
  },
92
101
  data() {
93
102
  return {};
@@ -0,0 +1,53 @@
1
+ <template>
2
+ <div class="saas-steps">
3
+ <div
4
+ class="saas-steps-item"
5
+ v-for="(step, index) in steps"
6
+ :key="index"
7
+ :class="{
8
+ 'saas-steps-item-active': active === index,
9
+ 'saas-steps-item-finish': active > index,
10
+ 'saas-steps-item-custom': step.icon,
11
+ }">
12
+ <div class="saas-steps-item-icon">
13
+ <span class="saas-steps-icon" v-if="!step.icon">
14
+ <template v-if="active > index">
15
+ <svg viewBox="64 64 896 896" class="anticon">
16
+ <path
17
+ d="M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 0 0-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.2 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"></path>
18
+ </svg>
19
+ </template>
20
+ <template v-else>{{ index + 1 }}</template>
21
+ </span>
22
+ <span class="saas-steps-custom-icon" v-else>
23
+ <slot :name="`icon-${index}`"></slot>
24
+ </span>
25
+ </div>
26
+ <div class="saas-steps-item-content">
27
+ <div class="saas-steps-item-title">{{ step.label }}</div>
28
+ <div class="saas-steps-item-description" v-if="step.description">{{ step.description }}</div>
29
+ </div>
30
+ </div>
31
+ </div>
32
+ </template>
33
+
34
+ <script>
35
+ export default {
36
+ name: 'SSteps',
37
+ props: {
38
+ active: {
39
+ type: Number,
40
+ default: 0,
41
+ },
42
+ steps: {
43
+ type: Array,
44
+ required: true,
45
+ },
46
+ direction: {
47
+ type: String,
48
+ default: 'horizontal', // 'horizontal' 或 'vertical'
49
+ validator: value => ['horizontal', 'vertical'].includes(value),
50
+ },
51
+ },
52
+ };
53
+ </script>
@@ -18,7 +18,7 @@
18
18
  </template>
19
19
  <template v-else-if="column.type === 'operate'" #default="scope">
20
20
  <slot :name="column.value" v-bind="getBindProps(scope)">
21
- <s-table-buttons :list="column.actionList" :row="scope.row" @action="handleAction"></s-table-buttons>
21
+ <s-table-buttons :list="column.actionList" :row="scope.row" :index="scope.$index" @action="handleAction"></s-table-buttons>
22
22
  </slot>
23
23
  </template>
24
24
  <template v-else-if="column.type === 'unit'" #default="scope">
@@ -104,8 +104,8 @@ export default {
104
104
  getIndex($index) {
105
105
  return this.indexMethod ? this.indexMethod($index) : $index + 1;
106
106
  },
107
- handleAction(actionName, row) {
108
- this.$emit('action', actionName, row, this.column);
107
+ handleAction(actionName, row, column) {
108
+ this.$emit('action', actionName, row, column);
109
109
  },
110
110
  },
111
111
  };
@@ -9,6 +9,7 @@ import SMessagebox from './SMessagebox/index';
9
9
  import STable from './STable/index';
10
10
  import SContainer from './SContainer/index';
11
11
  import STablecolumn from './STable/STablecolumn';
12
+ import SSteps from './SSteps/index';
12
13
  import * as BaseComponents from './SForm';
13
14
  import * as Pages from './SPage';
14
15
  import * as Buttons from './SButton';
@@ -24,6 +25,7 @@ const components = {
24
25
  STable,
25
26
  SContainer,
26
27
  STablecolumn,
28
+ SSteps,
27
29
  ...Pages,
28
30
  ...Buttons,
29
31
  ...Spaces,
package/lib/css/index.css CHANGED
@@ -1 +1 @@
1
- @charset "UTF-8";.saas-card,.saas-dialog .el-dialog{border-radius:6px}.saas-dialog-footer,.saas-drawer-footer{height:auto;text-align:right}.saas-detail-sub,.saas-page-table-sub{margin-top:8px}.saas-dialog .el-dialog__body{padding:0}.saas-dialog ::v-deep .el-dialog__footer{padding:12px 24px 20px}.saas-dialog .el-dialog__header{border-bottom:1px solid #dbdee7;padding:12px 16px}.saas-dialog .el-dialog__footer{padding:8px 16px;border-top:1px solid #dbdee7}.saas-dialog .el-dialog__headerbtn{top:16px}.content-no-padding .saas-dialog-content{padding:0}.saas-dialog-auto{max-height:calc(85vh - 100px);overflow-y:auto}.saas-dialog-content{padding:16px}.saas-drawer .el-drawer__body{display:flex}.saas-drawer-content{flex:1;padding:24px;overflow-y:auto}.saas-drawer-footer{padding:16px 24px;border-top:1px #efefef solid}.saas-dialog .submit-form .el-form-item__content,.saas-drawer .submit-form .el-form-item__content{line-height:normal}.saas-dialog .submit-form .el-form-item__label,.saas-drawer .submit-form .el-form-item__label{line-height:normal;font-weight:500}.saas-detail{background:#fff;height:100%;display:flex;flex-direction:column;position:relative}.saas-detail-top{flex:1;overflow-y:auto;overflow-x:auto}.saas-detail-header{display:flex;padding:24px 64px;position:sticky;background:#fff;top:0;z-index:10}.saas-detail-title{display:flex;align-items:center;font-size:16px;font-weight:600;color:#0e1822}.saas-title-line{display:inline-block;width:4px;height:16px;background:#28b86a;margin-right:8px;vertical-align:middle}.saas-detail-backbox{display:flex;align-items:center;position:absolute;left:24px;top:24px}.saas-detail-back{display:flex;align-items:center;border-radius:50%;border:1px solid #dbdee7;width:24px;height:24px;justify-content:center;color:#a1a5b2;cursor:pointer}.saas-detail-back:hover{background:#f7f9fb}.saas-detail-content{padding:0 64px 24px;flex:1}.saas-detail-footer{padding:16px 24px;background:#fff;text-align:center;box-shadow:8px 0 12px 0 rgba(161,165,178,.1);border-radius:0;border-top:1px solid #dbdee7;z-index:5}.saas-unit-danger,.saas-unit-info,.saas-unit-primary,.saas-unit-success,.saas-unit-warning{width:8px;height:8px;border-radius:2px}.saas-unit{display:flex;align-items:center;gap:6px;white-space:nowrap;color:#0e1822;font-size:14px}.saas-unit-primary{background-color:#1890ff}.saas-unit-info{background-color:#a1a5b2}.saas-unit-success{background-color:#2ecc71}.saas-unit-danger{background-color:#ff3b30}.saas-unit-warning{background-color:#f90}.saas-unit-link{text-decoration:underline;cursor:pointer}.saas-unit-link:hover{color:#1890ff}.saas-unit-text{width:0;flex:1}.saas-card{border:1px solid #dbdee7;margin-bottom:24px}.saas-card.hidden-card{border-bottom:none}.saas-card.hidden-card .saas-card-header{border-radius:6px}.saas-card-header{display:flex;background:#f7f9fb;border-radius:6px 6px 0 0;border-bottom:1px solid #dbdee7;font-weight:500;font-size:16px;color:#0e1822;padding:8px 16px;align-items:center}.saas-card-title{flex:1}.saas-card-title .el-button--text{padding:0}.saas-card-content{padding:16px}.saas-card-icon{cursor:pointer;margin-right:8px}.saas-group{display:flex;overflow-x:auto;min-height:50px;padding-bottom:4px}.saas-group div{box-sizing:border-box}.saas-group::-webkit-scrollbar{width:3px;height:4px;background-color:#fff;cursor:pointer}.saas-group::-webkit-scrollbar-thumb{background-color:rgba(144,147,153,.2)}.saas-group::-webkit-scrollbar-thumb:hover{background-color:rgba(144,147,153,.5)}.saas-group::-webkit-scrollbar-track{background-color:#fff}.saas-sort-group{display:flex;border-radius:6px;margin-right:8px;background:#f7f9fb}.saas-sort-item{width:136px;background:#f7f9fb;border:1px solid #f7f9fb;text-align:center;padding:8px 4px;position:relative;cursor:pointer;border-radius:6px;display:flex;flex-direction:column;align-items:center;justify-content:center}.saas-sort-item .title{font-weight:600;font-size:16px;color:#0e1822;line-height:24px}.saas-sort-item .text{font-size:14px;color:#7b8089;line-height:22px;max-width:100%}.saas-sort-item img{display:none;position:absolute;width:16px;right:-1px;top:-1px}.saas-sort-item.active{border:1px solid #28b86a;border-radius:6px;background:#f4fbf8}.saas-sort-item.active .title{color:#28b86a}.saas-sort-item.active img{display:block}.message-box-overlay{position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.5);display:flex;align-items:center;justify-content:center;z-index:4999}.message-box,.saas-page-table{background:#fff;position:relative;border-radius:8px}.message-box{padding:32px 24px 24px;width:480px}.message-box .el-icon-close{position:absolute;top:16px;right:16px;cursor:pointer}.message-box__header{font-weight:600;font-size:16px;color:#333;line-height:24px;margin-bottom:8px}.message-box__content{margin-bottom:24px;color:#5c616a}.message-box__footer{display:flex;justify-content:flex-end}.message-box__input{width:100%;padding:6px}.message-box_icon{color:#f90;display:flex;font-size:24px}.message-box_main{display:flex;gap:8px}.message-box_right{flex:1;width:0}.saas-page-table{height:calc(100% - 16px);display:flex;flex-direction:column;padding:16px}.saas-page-table-header{flex-shrink:0}.saas-page-table-menu{display:flex;align-items:center;font-size:16px;font-weight:600;color:#0e1822;margin-bottom:16px}.saas-page-table-menu.hasClose{font-weight:400}.saas-page-table-back_title{margin-right:16px}.saas-page-table-title_line{height:14px;width:1px;background:#dbdee7;margin-right:16px}.saas-page-title-line{display:inline-block;width:4px;height:16px;background:#28b86a;margin-right:8px;vertical-align:middle}.saas-page-table-backbox{display:flex;align-items:center;top:24px}.saas-page-table-back,.saas-steptop-btn{align-items:center;display:flex}.saas-page-table-back{border-radius:50%;border:1px solid #dbdee7;width:24px;height:24px;justify-content:center;color:#a1a5b2;cursor:pointer;margin-right:8px}.saas-page-table-back:hover{background:#f7f9fb}.saas-page-table-title{flex:1}.saas-page-table-content{flex:1;min-height:300px}.saas-page-table-footer{flex-shrink:0}.saas-page__button{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap}.saas-table-buttons{display:flex;gap:0 8px;flex-wrap:wrap;align-items:center}.saas-table-buttons .el-button+.el-button{margin-left:0}.saas-table-buttons .smart-More{font-weight:bolder}.saas-container{display:flex;flex-direction:column;height:100%;flex:1}.saas-container-content{flex:1;min-height:300px}.saas-input .el-input-group__append{padding:0;background:#f7f9fb;color:#0e1822}.el-button.saas-button-text,.saas-button.saas-button__icon{padding-right:8px;padding-left:8px}.saas-input-number,.saas-select-input{display:inline-block;width:100%}.saas-text-mode{display:inline}.el-button.saas-button-text{color:#0e1822;display:inline-flex;align-items:center;outline:0;background-color:transparent}.el-button.saas-button-text:focus,.el-button.saas-button-text:hover{background-color:#f7f9fb}.no-gap>.el-button.saas-button-text{margin:0}.saas-space{display:inline-flex}.saas-space.saas-horizontal{flex-direction:row}.saas-space.saas-vertical{flex-direction:column}.saas-space-item{display:inline-flex}
1
+ @charset "UTF-8";.saas-card,.saas-dialog .el-dialog{border-radius:6px}.saas-dialog-footer,.saas-drawer-footer{height:auto;text-align:right}.saas-dialog .el-dialog__body{padding:0}.saas-dialog ::v-deep .el-dialog__footer{padding:12px 24px 20px}.saas-dialog .el-dialog__header{border-bottom:1px solid #dbdee7;padding:12px 16px}.saas-dialog .el-dialog__footer{padding:8px 16px;border-top:1px solid #dbdee7}.saas-dialog .el-dialog__headerbtn{top:16px}.content-no-padding .saas-dialog-content{padding:0}.saas-dialog-auto{max-height:calc(85vh - 100px);overflow-y:auto}.saas-dialog-content{padding:16px}.saas-drawer .el-drawer__body{display:flex}.saas-drawer-content{flex:1;padding:24px;overflow-y:auto}.saas-drawer-footer{padding:16px 24px;border-top:1px #efefef solid}.saas-dialog .submit-form .el-form-item__content,.saas-drawer .submit-form .el-form-item__content{line-height:normal}.saas-dialog .submit-form .el-form-item__label,.saas-drawer .submit-form .el-form-item__label{line-height:normal;font-weight:500}.saas-detail{background:#fff;height:100%;display:flex;flex-direction:column;position:relative}.saas-detail-top{flex:1;overflow-y:auto;overflow-x:auto}.saas-detail-header{display:flex;padding:24px 64px;position:sticky;background:#fff;top:0;z-index:10}.saas-detail-title{display:flex;align-items:center;font-size:16px;font-weight:600;color:#0e1822}.saas-detail-sub{margin-top:8px}.saas-title-line{display:inline-block;width:4px;height:16px;background:#28b86a;margin-right:8px;vertical-align:middle}.saas-detail-backbox{display:flex;align-items:center;position:absolute;left:24px;top:24px}.saas-detail-back{display:flex;align-items:center;border-radius:50%;border:1px solid #dbdee7;width:24px;height:24px;justify-content:center;color:#a1a5b2;cursor:pointer}.saas-detail-back:hover{background:#f7f9fb}.saas-detail-content{padding:0 64px 24px;flex:1}.saas-detail-footer{padding:16px 24px;background:#fff;text-align:center;box-shadow:8px 0 12px 0 rgba(161,165,178,.1);border-radius:0;border-top:1px solid #dbdee7;z-index:5}.saas-unit-danger,.saas-unit-info,.saas-unit-primary,.saas-unit-success,.saas-unit-warning{width:8px;height:8px;border-radius:2px}.saas-unit{display:flex;align-items:center;gap:6px;white-space:nowrap;color:#0e1822;font-size:14px}.saas-unit-primary{background-color:#1890ff}.saas-unit-info{background-color:#a1a5b2}.saas-unit-success{background-color:#2ecc71}.saas-unit-danger{background-color:#ff3b30}.saas-unit-warning{background-color:#f90}.saas-unit-link{text-decoration:underline;cursor:pointer}.saas-unit-link:hover{color:#1890ff}.saas-unit-text{width:0;flex:1}.saas-card{border:1px solid #dbdee7;margin-bottom:24px}.saas-card.hidden-card{border-bottom:none}.saas-card.hidden-card .saas-card-header{border-radius:6px}.saas-card-header{display:flex;background:#f7f9fb;border-radius:6px 6px 0 0;border-bottom:1px solid #dbdee7;font-weight:500;font-size:16px;color:#0e1822;padding:8px 16px;align-items:center}.saas-card-title{flex:1}.saas-card-title .el-button--text{padding:0}.saas-card-content{padding:16px}.saas-card-icon{cursor:pointer;margin-right:8px}.saas-group{display:flex;overflow-x:auto;min-height:50px;padding-bottom:4px}.saas-group div{box-sizing:border-box}.saas-group::-webkit-scrollbar{width:3px;height:4px;background-color:#fff;cursor:pointer}.saas-group::-webkit-scrollbar-thumb{background-color:rgba(144,147,153,.2)}.saas-group::-webkit-scrollbar-thumb:hover{background-color:rgba(144,147,153,.5)}.saas-group::-webkit-scrollbar-track{background-color:#fff}.saas-sort-group{display:flex;border-radius:6px;margin-right:8px;background:#f7f9fb}.saas-sort-item{width:136px;background:#f7f9fb;border:1px solid #f7f9fb;text-align:center;padding:8px 4px;position:relative;cursor:pointer;border-radius:6px;display:flex;flex-direction:column;align-items:center;justify-content:center}.saas-sort-item .title{font-weight:600;font-size:16px;color:#0e1822;line-height:24px}.saas-sort-item .text{font-size:14px;color:#7b8089;line-height:22px;max-width:100%}.saas-sort-item img{display:none;position:absolute;width:16px;right:-1px;top:-1px}.saas-sort-item.active{border:1px solid #28b86a;border-radius:6px;background:#f4fbf8}.saas-sort-item.active .title{color:#28b86a}.saas-sort-item.active img{display:block}.message-box-overlay{position:fixed;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.5);display:flex;align-items:center;justify-content:center;z-index:4999}.message-box,.saas-page-table{background:#fff;border-radius:8px}.message-box{padding:32px 24px 24px;width:480px;position:relative}.message-box .el-icon-close{position:absolute;top:16px;right:16px;cursor:pointer}.message-box__header{font-weight:600;font-size:16px;color:#333;line-height:24px;margin-bottom:8px}.message-box__content{margin-bottom:24px;color:#5c616a}.message-box__footer{display:flex;justify-content:flex-end}.message-box__input{width:100%;padding:6px}.message-box_icon{color:#f90;display:flex;font-size:24px}.message-box_main{display:flex;gap:8px}.message-box_right{flex:1;width:0}.saas-page-table{height:calc(100% - 16px);display:flex;flex-direction:column;position:relative;padding:16px}.saas-page-table__header{flex-shrink:0}.saas-page-table__menu{display:flex;align-items:center;font-size:16px;font-weight:600;color:#0e1822;margin-bottom:16px}.saas-page-table__menu.hasClose{font-weight:400}.saas-page-table__back-title{margin-right:16px}.saas-page-table__title-line{height:14px;width:1px;background:#dbdee7;margin-right:16px}.saas-page-table--hasButton .saas-page-table__footer{padding-top:16px;padding-bottom:16px;margin:0 -16px -16px;text-align:center;box-shadow:8px 0 12px 0 rgba(161,165,178,.1);border-radius:0;border-top:1px solid #dbdee7}.saas-page-table__sub{margin-top:8px}.saas-page-header__line{display:inline-block;width:4px;height:16px;background:#28b86a;margin-right:8px;vertical-align:middle}.saas-page-table__backbox{display:flex;align-items:center;top:24px}.saas-page-table__back,.saas-steptop-btn{align-items:center;display:flex}.saas-page-table__back{border-radius:50%;border:1px solid #dbdee7;width:24px;height:24px;justify-content:center;color:#a1a5b2;cursor:pointer;margin-right:8px}.saas-page-table__back:hover{background:#f7f9fb}.saas-page-table__title{flex:1}.saas-page-table__content{flex:1;min-height:300px}.saas-page-table__footer{flex-shrink:0}.saas-page__button{display:flex;align-items:center;justify-content:space-between;flex-wrap:wrap}.saas-table-buttons{display:flex;gap:0 8px;flex-wrap:wrap;align-items:center}.saas-table-buttons .el-button+.el-button{margin-left:0}.saas-table-buttons .smart-More{font-weight:bolder}.saas-container{display:flex;flex-direction:column;height:100%;flex:1}.saas-container-content{flex:1;min-height:300px}.saas-input .el-input-group__append{padding:0;background:#f7f9fb;color:#0e1822}.el-button.saas-button-text,.saas-button.saas-button__icon{padding-right:8px;padding-left:8px}.saas-input-number,.saas-select-input{display:inline-block;width:100%}.saas-text-mode{display:inline}.el-button.saas-button-text{color:#0e1822;display:inline-flex;align-items:center;outline:0;background-color:transparent}.el-button.saas-button-text:focus,.el-button.saas-button-text:hover{background-color:#f7f9fb}.no-gap>.el-button.saas-button-text{margin:0}.saas-space{display:inline-flex}.saas-space.saas-horizontal{flex-direction:row}.saas-space.saas-vertical{flex-direction:column}.saas-space-item{display:inline-flex}.saas-steps{display:flex;width:100%;font-size:14px;flex-direction:row;align-items:center}.saas-steps .saas-steps-item{position:relative;flex:1;overflow:hidden;white-space:nowrap}.saas-steps.vertical{flex-direction:column}.saas-steps-item:last-child{flex:none}.saas-steps-item-tail{position:absolute;top:16px;left:16px;width:calc(100% - 32px);height:1px;background-color:#f0f0f0}.vertical .saas-steps-item-tail{width:1px;height:calc(100% - 32px);left:16px;top:32px}.saas-steps-item-finish .saas-steps-item-tail{background-color:#1890ff}.saas-steps-item-icon{width:24px;height:24px;margin-right:8px;background:#fff;border:1px solid #dbdee7;border-radius:50%;line-height:22px;text-align:center;font-size:14px;color:#dbdee7;display:inline-block}.saas-steps-item-active .saas-steps-item-icon{border-color:#28b86a;background-color:#28b86a;color:#fff}.saas-steps-item-finish .saas-steps-item-icon{border-color:#28b86a;color:#28b86a;line-height:25px}.saas-steps-custom-icon{font-size:20px}.saas-steps-item-content{position:relative;display:inline-block;vertical-align:top}.saas-steps-item-title{color:#7c808a;font-weight:400;overflow:hidden}.saas-steps-item-active .saas-steps-item-title,.saas-steps-item-finish .saas-steps-item-title{color:#0e1822}.saas-steps-item-description{color:rgba(0,0,0,.45);font-size:14px;margin-top:4px}.anticon{display:inline-block;width:1em;height:1em;fill:currentColor}.saas-steps-item-title:after{background:#dbdde7;content:"";display:block;height:1px;left:100%;position:absolute;top:12px;width:9999px;margin-left:16px}.saas-steps-item:not(:first-of-type){padding-left:16px}.saas-steps-item:last-of-type .saas-steps-item-title:after{content:"";display:none}
@@ -1 +1 @@
1
- module.exports=function(t){var e={};function s(a){if(e[a])return e[a].exports;var n=e[a]={i:a,l:!1,exports:{}};return t[a].call(n.exports,n,n.exports,s),n.l=!0,n.exports}return s.m=t,s.c=e,s.d=function(t,e,a){s.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:a})},s.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},s.t=function(t,e){if(1&e&&(t=s(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var a=Object.create(null);if(s.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var n in t)s.d(a,n,function(e){return t[e]}.bind(null,n));return a},s.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return s.d(e,"a",e),e},s.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},s.p="",s(s.s=3)}([function(t,e){t.exports=require("chain-lodash")},function(t,e){t.exports=require("element-ui")},function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgBAMAAACBVGfHAAAAAXNSR0IArs4c6QAAADBQTFRFAAAAIK9wML9wKLdoKLdwKLdsKbhpKLlqKLdqKLhrKLdpKLhrKbhrKLhqKblqKLhqgtDn1gAAAA90Uk5TABAQICBAcH+An6C/z9/vjSAyHgAAAJdJREFUKM9dzs0JwkAUReGDIkwJFmELwmA/giXYQVpICa5sw417dy4FN+IPyc0YZ2Jy7/Lw8XhUKmuPkbSg/159qUbl6kQ7Jw8n7eTKeykdxqReSHcyuSXAWnqSyeaken6RPmQSVz1QQybn2f4LJDJpYg+GkMgPlJDIVpMwvMtAPAQPheAEJzjBCU5wghOc4AQnOMGJh9AB/uTa5S04zqUAAAAASUVORK5CYII="},function(t,e,s){"use strict";s.r(e);var a={};s.r(a),s.d(a,"SInput",(function(){return P})),s.d(a,"SSelect",(function(){return N})),s.d(a,"SInputNumber",(function(){return G})),s.d(a,"SSwitch",(function(){return U}));var n={};s.r(n),s.d(n,"SPageButton",(function(){return K})),s.d(n,"SPagedetail",(function(){return z}));var l={};s.r(l),s.d(l,"STableButtons",(function(){return A})),s.d(l,"SButtonText",(function(){return J})),s.d(l,"SButton",(function(){return T}));var i={};s.r(i),s.d(i,"SSpace",(function(){return Q})),s.d(i,"SSpaceItem",(function(){return W}));var o=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-drawer",t._g(t._b({staticClass:"saas-drawer",attrs:{wrapperClosable:!1,visible:t.show},on:{"update:visible":function(e){t.show=e}}},"el-drawer",t.bindProps,!1),t.$listeners),[t.$slots.title?s("template",{slot:"title"},[t._t("title")],2):t._e(),t._v(" "),s("div",{staticClass:"saas-drawer-content"},[t._t("default")],2),t._v(" "),t.showFooter?s("div",{staticClass:"saas-drawer-footer"},[t.$slots.footer?t._t("footer"):[t.showCancelButton?s("el-button",{on:{click:t.handleClose}},[t._v(t._s(t.cancelText))]):t._e(),t._v(" "),t.showConfirmButton?s("el-button",{directives:[{name:"preventReClick",rawName:"v-preventReClick",value:5e3,expression:"5000"}],attrs:{loading:t.loadingBtn,type:"primary"},on:{click:t.handleSubmit}},[t._v("\n "+t._s(t.confirmText)+"\n ")]):t._e()]],2):t._e()],2)};o._withStripped=!0;var r=s(1),u=s(0);function c(t,e,s,a,n,l,i,o){var r,u="function"==typeof t?t.options:t;if(e&&(u.render=e,u.staticRenderFns=s,u._compiled=!0),a&&(u.functional=!0),l&&(u._scopeId="data-v-"+l),i?(r=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),n&&n.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(i)},u._ssrRegister=r):n&&(r=o?function(){n.call(this,(u.functional?this.parent:this).$root.$options.shadowRoot)}:n),r)if(u.functional){u._injectStyles=r;var c=u.render;u.render=function(t,e){return r.call(e),c(t,e)}}else{var p=u.beforeCreate;u.beforeCreate=p?[].concat(p,r):[r]}return{exports:t,options:u}}var p=c({name:"SDrawer",props:{...r.Drawer.props,showFooter:{type:Boolean,default:()=>!0},size:{type:[String,Number],default:()=>"800px"},wrapperClosable:{type:Boolean,default:()=>!1},loadingBtn:{type:Boolean,default:()=>!1},appendToBody:{type:Boolean,default:!0},showCancelButton:{type:Boolean,default:!0},showConfirmButton:{type:Boolean,default:!0},confirmText:{type:String,default(){return this.$t("buttonGroup.sure")}},cancelText:{type:String,default(){return this.$t("buttonGroup.cancel")}}},data:()=>({}),computed:{show:{get(){return this.visible},set(t){this.$emit("update:visible",t)}},bindProps(){return Object(u.omit)(this.$props,["visible"])}},deactivated(){this.handleClose()},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("update:visible",!1),this.$emit("close")}}},o,[],!1,null,null,null).exports,d=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-dialog",t._g(t._b({staticClass:"saas-dialog",attrs:{"close-on-click-modal":!1,visible:t.show},on:{"update:visible":function(e){t.show=e}}},"el-dialog",t.bindProps,!1),t.$listeners),[t.$slots.title?s("template",{slot:"title"},[t._t("title")],2):t._e(),t._v(" "),s("div",{staticClass:"saas-dialog-content",class:{"saas-dialog-auto":t.isAuto}},[t._t("default")],2),t._v(" "),t.showFooter?s("template",{slot:"footer"},[t.$slots.footer?t._t("footer"):s("div",[t.showCancelButton?s("el-button",{on:{click:t.handleClose}},[t._v(t._s(t.cancelText))]):t._e(),t._v(" "),t.showConfirmButton?s("el-button",{directives:[{name:"preventReClick",rawName:"v-preventReClick",value:5e3,expression:"5000"}],attrs:{loading:t.loadingBtn,type:"primary"},on:{click:t.handleSubmit}},[t._v("\n "+t._s(t.confirmText)+"\n ")]):t._e()],1)],2):t._e()],2)};d._withStripped=!0;var h=c({name:"SDialog",props:{...r.Dialog.props,showFooter:{type:Boolean,default:()=>!0},width:{type:[String,Number],default:()=>"600px"},loadingBtn:{type:Boolean,default:()=>!1},visible:{type:Boolean,default:!1},showCancelButton:{type:Boolean,default:()=>!0},showConfirmButton:{type:Boolean,default:()=>!0},confirmText:{type:String,default(){return this.$t("buttonGroup.sure")}},cancelText:{type:String,default(){return this.$t("buttonGroup.cancel")}},isAuto:{type:Boolean,default:!0}},data:()=>({}),computed:{show:{get(){return this.visible},set(t){this.$emit("update:visible",t)}},bindProps(){return Object(u.omit)(this.$props,["visible"])}},deactivated(){this.handleClose()},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("update:visible",!1),this.$emit("close")}}},d,[],!1,null,null,null).exports,m=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-page-table"},[s("div",{staticClass:"saas-page-table-header"},[t.showHeader?[t.$slots.header?s("div",[t._t("header")],2):s("div",{staticClass:"saas-page-table-menu",class:{hasClose:t.showClose}},[t.showClose?[s("div",{staticClass:"saas-page-table-back",on:{click:t.goBack}},[s("span",{staticClass:"el-icon-arrow-left"})]),t._v(" "),s("span",{staticClass:"saas-page-table-back_title"},[t._v(t._s(t.$t("atSalaryFileImport.return")))]),t._v(" "),s("span",{staticClass:"saas-page-table-title_line"})]:t._e(),t._v(" "),t.showClose?t._e():s("span",{staticClass:"saas-page-title-line"}),t._v(" "),s("span",{staticClass:"saas-page-table-title"},[t.$slots.title?[t._t("title")]:s("span",[t._v(t._s(t.title))])],2),t._v(" "),t._t("header-append")],2)]:t._e(),t._v(" "),s("div",{staticClass:"saas-page-table-form"},[t._t("form")],2)],2),t._v(" "),s("div",{staticClass:"saas-page-table-content"},[t._t("default")],2),t._v(" "),s("div",{staticClass:"saas-page-table-footer"},[t._t("footer")],2)])};m._withStripped=!0;var f=c({name:"SPagetable",props:{showHeader:{type:Boolean,default:()=>!0},showFooter:{type:Boolean,default:()=>!0},showClose:{type:Boolean,default:()=>!1},loadingBtn:{type:Boolean,default:()=>!1},computeStyle:{type:Object,default:()=>({width:"1000px",margin:"0 auto"})},title:{type:String,default(){return this.$t("saasmenu."+this.$route.meta.code)}},titleSub:{type:String,default:""},confirmText:{type:String,default(){return this.$t("buttonGroup.sure")}},cancelText:{type:String,default(){return this.$t("buttonGroup.cancel")}},showTitle:{type:Boolean,default:!0}},data:()=>({}),computed:{show:{get(){return this.visible},set(t){this.$emit("update:visible",t)}}},deactivated(){this.handleClose()},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("close")},goBack(){this.$emit("close")}}},m,[],!1,null,"9ce252bc",null).exports,v=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-unit"},[s("span",{class:"saas-unit-"+t.typeCom}),t._v(" "),s("span",{class:["saas-unit-text",{"saas-unit-link":t.isLink}],on:{click:t.handleClick}},[t._t("default",[t._v("\n "+t._s(t.getValue)+"\n ")])],2)])};v._withStripped=!0;var _=c({name:"SUnit",props:{value:[String,Number],type:{type:String,default:""},options:{type:Array,default:()=>[]},props:{type:Object,default:()=>({value:"value",label:"label",style:"style",type:"",isShowCode:!1})},isLink:Boolean},data:()=>({}),computed:{typeCom(){if(Object(u.isEmpty)(this.value))return this.type||"primary";{const t=this.props.style||"style";return Object(u.getOptionValue)(this.options,this.value,{...this.props,label:t})||"primary"}},getValue(){if(!Object(u.isEmpty)(this.value)){const t=Object(u.getOptionValue)(this.options,this.value,this.props);return Object(u.formatIfJson)(t)}return""}},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("close")},goBack(){this.$emit("close")},handleClick(t){this.$emit("click",t)}}},v,[],!1,null,"26c2158e",null).exports,b=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{class:["saas-card",{"hidden-card":!t.isShow}]},[s("div",{staticClass:"saas-card-header"},[t.isCollapse?s("span",{class:[t.isShow?"el-icon-caret-bottom":"el-icon-caret-right","saas-card-icon"],on:{click:t.handleCollapse}}):t._e(),t._v(" "),s("div",{staticClass:"saas-card-title"},[t._t("title",[t._v("\n "+t._s(t.title)+"\n ")])],2)]),t._v(" "),s("div",{directives:[{name:"show",rawName:"v-show",value:t.isShow,expression:"isShow"}],staticClass:"saas-card-content"},[t._t("default")],2)])};b._withStripped=!0;var g=c({name:"SCard",props:{title:{type:String,default:""},titleSub:{type:String,default:""},isCollapse:{type:Boolean,default:!1}},data:()=>({isShow:!0}),computed:{},deactivated(){},methods:{handleCollapse(){this.isShow=!this.isShow}}},b,[],!1,null,"5ed7dbbb",null).exports,y=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"saas-group"},t._l(t.list,(function(e,n){return a("div",{key:n,staticClass:"saas-sort-group"},t._l(e.children,(function(n,l){return a("div",{key:l,staticClass:"saas-sort-item",class:{active:t.getActive(n,e)},on:{click:function(s){return t.handleClick(n,e)}}},[a("div",{staticClass:"title",style:t.getSortStyle(n)},[t._v(t._s(t.formatValue(n,t.data)))]),t._v(" "),a("div",{staticClass:"text"},[a("span",[t._t("default",[t._v("\n "+t._s(n.label)+"\n "),n.tip?a("el-tooltip",{attrs:{content:n.tip}},[a("div",{attrs:{slot:"content"},domProps:{innerHTML:t._s(n.tip)},slot:"content"}),t._v(" "),a("i",{staticClass:"smart-info-filled",staticStyle:{color:"#a1a5b2","margin-left":"4px"}})]):t._e()],{item:n})],2)]),t._v(" "),a("img",{attrs:{src:s(2),alt:"",srcset:""}})])})),0)})),0)};y._withStripped=!0;var w=c({name:"SGroup",props:{title:{type:String,default:""},list:{type:Array,default:()=>[]},data:{type:Object,default:()=>({})},isActive:{type:Function,default:null}},data:()=>({}),computed:{},deactivated(){},methods:{getSortStyle(t){let e={};if("percent"===t.type){const s=this.data[t.field];e.color=s<=30?"#FF3B30":s<=60?"#FF9900":"#28B86A"}return e},handleClick(t,e){this.$emit("tab-click",t,e)},getActive(t,e){return!!this.isActive&&this.isActive(t,e)},formatValue:(t,e)=>t.formatValue?t.formatValue(t,e):e[t.value]}},y,[],!1,null,"4f2996b7",null).exports,S=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("transition",{attrs:{name:"el-fade-in-linear"}},[t.visible?s("div",{staticClass:"message-box-overlay"},[s("div",{staticClass:"message-box"},[t.showClose?s("i",{staticClass:"el-icon-close",on:{click:t.handleClose}}):t._e(),t._v(" "),s("div",{staticClass:"message-box_main"},[s("div",{staticClass:"message-box_icon"},[s("span",{staticClass:"el-icon-warning"})]),t._v(" "),s("div",{staticClass:"message-box_right"},[s("div",{staticClass:"message-box__header"},[s("span",{staticClass:"message-box__title"},[t._v(t._s(t.title))])]),t._v(" "),s("div",{staticClass:"message-box__content"},[t.message&&0==t.dangerouslyUseHTMLString?s("div",[t._v(t._s(t.message))]):t._e(),t._v(" "),t.message&&t.dangerouslyUseHTMLString?s("div",{domProps:{innerHTML:t._s(t.message)}}):t._e(),t._v(" "),t.showInput?s("el-input",{staticClass:"message-box__input",attrs:{placeholder:t.inputPlaceholder},model:{value:t.inputValue,callback:function(e){t.inputValue=e},expression:"inputValue"}}):t._e()],1)])]),t._v(" "),s("div",{staticClass:"message-box__footer"},[t.showCancelButton?s("el-button",{attrs:{size:"mini"},on:{click:t.handleCancel}},[t._v(t._s(t.cancelText))]):t._e(),t._v(" "),s("el-button",{attrs:{type:"primary",size:"mini"},on:{click:t.handleConfirm}},[t._v(t._s(t.confirmText))])],1)])]):t._e()])};S._withStripped=!0;var C=c({name:"SMessageBox",props:{},data:()=>({visible:!1,title:"",message:"",showInput:!1,inputValue:"",inputPlaceholder:"",showCancelButton:!1,resolve:null,reject:null,confirmText:"",cancelText:"",dangerouslyUseHTMLString:!1,showClose:!1}),methods:{open(t){return this.title=t.title,this.message=t.message||"",this.showClose=!!Object(u.isEmpty)(t.showClose)||t.showClose,this.showInput=t.showInput||!1,this.dangerouslyUseHTMLString=t.dangerouslyUseHTMLString||!1,this.inputPlaceholder=t.inputPlaceholder||"",this.showCancelButton=!!Object(u.isEmpty)(t.showCancelButton)||t.showCancelButton,this.confirmText=t.confirmText,this.cancelText=t.cancelText,this.showClose=t.showClose,this.visible=!0,this.inputValue="",new Promise((t,e)=>{this.resolve=t,this.reject=e})},handleConfirm(){this.visible=!1,this.showInput?this.resolve(this.inputValue):this.resolve(!0)},handleCancel(){this.visible=!1,this.reject("cancel")},handleClose(){this.visible=!1,this.reject("close")}}},S,[],!1,null,null,null).exports;var x=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-table",t._g(t._b({ref:"saasTable",staticClass:"saas-table"},"el-table",t.$props,!1),t.$listeners),[t._t("default"),t._v(" "),t._l(t.columns,(function(e){return s("STablecolumn",{key:e.value,attrs:{column:e,"min-width":t.minWidth},on:{action:t.handleColumnAction},scopedSlots:t._u([{key:e.value,fn:function(s){return[t._t(e.value,null,null,t.getBindProps(s,e))]}}],null,!0)})}))],2)};x._withStripped=!0;var $=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-table-column",t._b({scopedSlots:t._u(["index"===t.column.type?{key:"default",fn:function(e){var s=e.$index,a=e.row;return[t._t("default",[t._v("\n "+t._s(t.getIndex(s))+"\n ")],{index:t.getIndex(s),row:a})]}}:"operate"===t.column.type?{key:"default",fn:function(e){return[t._t(t.column.value,[s("s-table-buttons",{attrs:{list:t.column.actionList,row:e.row},on:{action:t.handleAction}})],null,t.getBindProps(e))]}}:"unit"===t.column.type?{key:"default",fn:function(e){return[t._t(t.column.value,[s("s-unit",{attrs:{value:e.row[t.column.value],options:t.column.options}})],null,t.getBindProps(e))]}}:{key:"default",fn:function(e){return[t._t(t.column.value,[t._v("\n "+t._s(t.selectValue(e.row))+"\n ")],null,t.getBindProps(e))]}}],null,!0)},"el-table-column",t.columnProps,!1),[s("template",{slot:"header"},[t.$slots["header-"+t.column.value]?t._t("header-"+t.column.value,[t._v("\n "+t._s(t.column.label)+"\n ")],{column:t.column}):[s("span",[t._v(t._s(t.column.label))]),t._v(" "),t.column.tip?s("el-tooltip",{attrs:{placement:"top",content:t.column.tip}},[s("i",{staticClass:"smart-info-filled",staticStyle:{color:"#a1a5b2","margin-left":"6px"}})]):t._e()]],2)],2)};$._withStripped=!0;var B=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-table-buttons"},[t._l(t.buttonList,(function(e,a){return[s("el-tooltip",{key:a,attrs:{disabled:!e.tip,placement:"top",content:e.tip}},[s("s-button",t._b({on:{click:function(s){return t.handelClick(e.action)}}},"s-button",t.finalAttrs(e.attrs),!1),[t._v(t._s(e.label))])],1)]})),t._v(" "),t.dropdownList.length?s("el-dropdown",{on:{command:t.handleCommand}},[s("s-button",t._b({},"s-button",t.btnProps,!1),["more"==t.moreType?s("i",{staticClass:"smart-More"}):"text"==t.moreType?[t._v("\n "+t._s(t.text)+"\n "),s("i",{staticClass:"el-icon-arrow-down"})]:t._e()],2),t._v(" "),s("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},t._l(t.dropdownList,(function(e,a){return s("el-dropdown-item",t._b({key:a,attrs:{command:e.action}},"el-dropdown-item",t.finalAttrs(e.attrs),!1),[s("el-tooltip",{attrs:{disabled:!e.tip,placement:"top",content:e.tip}},[s("span",[t._v(t._s(e.label))])])],1)})),1)],1):t._e()],2)};B._withStripped=!0;var k=function(){var t=this,e=t.$createElement;return(t._self._c||e)("el-button",t._g(t._b({class:["saas-button",t.getButtonType],attrs:{type:t.buttonTypeComputed},on:{click:t.handleClick}},"el-button",t.$attrs,!1),t.filterListeners),[t._t("default")],2)};k._withStripped=!0;var T=c({name:"SButton",props:{type:{type:String,default:"default"}},computed:{buttonTypeComputed(){return"icon"===this.type?"default":this.type},getButtonType(){return this.type?"saas-button__"+this.type:""},filterListeners(){return Object(u.omit)(this.$listeners,["click"])}},methods:{handleClick(t){t.currentTarget.blur(),this.$emit("click",t)}}},k,[],!1,null,null,null).exports,A=c({name:"STableButtons",components:{SButton:T},props:{list:{type:Array,default:()=>[]},maxLength:{type:Number,default:2},moreType:{type:String,default:"more"},text:{type:String,default(){return this.$t("buttonGroup.more")}},row:{type:Object,default:()=>({})}},data:()=>({btnProps:{size:"mini",type:"text"}}),computed:{showList(){return this.list.filter(t=>{const e=!!Object(u.isEmpty)(t.show)||t.show;return"function"==typeof e?e(this.row):Boolean(e)})},buttonList(){return this.showList.slice(0,this.maxLength)},dropdownList(){return this.showList.slice(this.maxLength)}},methods:{finalAttrs(t={}){return{...this.btnProps,...t}},handleCommand(t){this.$emit("action",t,this.row)},handelClick(t){this.$emit("action",t,this.row)}}},B,[],!1,null,null,null).exports,V=c({name:"STablecolumn",components:{STableButton:A,SUnit:_},props:{column:Object,minWidth:{type:[Number,String],default:150}},data:()=>({}),computed:{columnProps(){const{type:t=null,fixed:e=null,width:s,minWidth:a}=this.column;return{...this.column,fixed:e||("operate"===t?"right":null),width:s||null,"min-width":s?null:a||this.minWidth,prop:this.column.value,label:this.column.label,showOverflowTooltip:null==this.column.showOverflowTooltip||this.column.showOverflowTooltip,index:this.column.indexMethod||null}}},methods:{selectValue(t){let e="";const{options:s=[],type:a="txt"}=this.column,n=t[this.column.value];if(this.column.formatValue)return this.column.formatValue(t,this.column);switch(a){case"select":let t=s.find(t=>t.value==n)||{};e=Object(u.formatIfJson)(t.label);break;case"time":e=Object(u.formatSubmitTime)(n,"DD/MM/YYYY");break;default:e=Object(u.formatIfJson)(n)}return Object(u.isEmpty)(e)?e=this.column.defaultValue||"-":e.length>500&&(e=e.slice(0,500)+"..."),e},getBindProps(t){return{...t,column:this.column}},getIndex(t){return this.indexMethod?this.indexMethod(t):t+1},handleAction(t,e){this.$emit("action",t,e,this.column)}}},$,[],!1,null,null,null).exports,O=c({name:"STable",props:{...r.Table.props,border:{type:Boolean,default:!0},columns:{type:Array,default:()=>[]},minWidth:{type:[Number,String],default:150}},components:{STablecolumn:V},data:()=>({}),computed:{},mounted(){this.$nextTick(()=>{this.doLayout()})},deactivated(){},methods:{handleColumnAction(t,e,s){this.$emit("action",t,e,s)},getBindProps:(t,e)=>({...t,column:e}),doLayout(){this.$refs.saasTable.doLayout()}}},x,[],!1,null,null,null).exports,j=function(){var t=this.$createElement,e=this._self._c||t;return e("div",{staticClass:"saas-container"},[e("div",{staticClass:"saas-container-header"},[this._t("header")],2),this._v(" "),e("div",{staticClass:"saas-container-content"},[this._t("default")],2),this._v(" "),e("div",{staticClass:"saas-container-footer"},[this._t("footer")],2)])};j._withStripped=!0;var I=c({name:"SContainer",props:{title:{type:String,default:""},titleSub:{type:String,default:""}},data:()=>({}),computed:{},deactivated(){},methods:{}},j,[],!1,null,"2036a697",null).exports,E=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-input",class:{"saas-text-mode":"text"===t.from}},["text"===t.from?s("span",{staticClass:"saas-input-text"},[t._v(t._s(t.textValue))]):s("el-input",t._g(t._b({model:{value:t.newValue,callback:function(e){t.newValue=e},expression:"newValue"}},"el-input",t.attrs,!1),t.onEvents),[t.$slots.prepend?s("template",{slot:"prepend"},[t._t("prepend")],2):t._e(),t._v(" "),t.$slots.append?s("template",{slot:"append"},[t._t("append")],2):t._e()],2)],1)};E._withStripped=!0;var L={props:{value:{type:[String,Number,Array],default:""},mode:{type:String,default:"FORM"},clearable:{type:Boolean,default:!0},from:{type:String,default:"input"},placeholder:{type:String,default(){return this.$t("selectGroup.pleaseSelect")}},componentType:{type:String,default:"input"}},computed:{newValue:{get(){return Object(u.isEmpty)(this.value)||null==this.value?"":String(this.value)},set(t){this.$emit("input",t)}},textValue(){if("select"==this.componentType){const t=this.flattenOptions(this.options);if(this.multiple){const e=t.filter(t=>this.newValue.includes(t.value)).map(t=>t.label);return e.length>1?`${e[0]} +${e.length-1}`:e[0]||"-"}return(t.find(t=>t.value==this.newValue)||{}).label||"-"}return this.newValue||"-"},attrs(){const t=Object.assign({},this.defaultAttrs,this.$props,this.$attrs),e=["value","from"];return Object.keys(t).filter(t=>!e.includes(t)).reduce((e,s)=>(e[s]=t[s],e),{})},onEvents(){return this.$listeners}},methods:{flattenOptions(t){const e=[];return t.forEach(t=>{t.options?e.push(...t.options):e.push(t)}),e}}},P=c({name:"SInput",mixins:[L],props:{...Object(u.omit)(r.Input.props,["value","clearable","maxlength"]),maxlength:{type:Number,default:120},placeholder:{type:String,default(){return this.$t("InputPlaceholder.pleasemsg")}}},computed:{}},E,[],!1,null,"0b51b93c",null).exports,M=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-select",class:{"saas-text-mode":"text"===t.from}},["text"===t.from?s("span",{staticClass:"input-text"},[t._v(t._s(t.textValue))]):s("el-select",t._g(t._b({staticClass:"saas-select-input",attrs:{filterable:"",clearable:""},model:{value:t.newValue,callback:function(e){t.newValue=e},expression:"newValue"}},"el-select",t.attrs,!1),t.onEvents),[t._l(t.optionsList,(function(e){return[e.options?s("el-option-group",{key:e.value,attrs:{label:e.label}},t._l(e.options,(function(t){return s("el-option",{key:t.value,attrs:{disabled:t.disabled,label:t.label,value:t.value}})})),1):s("el-option",{key:e.value,attrs:{disabled:e.disabled,label:e.label,value:e.value}})]}))],2)],1)};M._withStripped=!0;var N=c({name:"SSelect",mixins:[L],props:{...Object(u.omit)(r.Select.props,["value","clearable"]),value:{type:[String,Number,Array]},clearable:{type:Boolean,default:()=>!0},placeholder:{type:String,default(){return this.$t("selectGroup.pleaseSelect")}},from:{type:String,default:"select"},options:{type:Array,default:()=>[]},componentType:{type:String,default:"select"},props:{type:Object,default:()=>({label:"label",value:"value"})}},data:()=>({}),computed:{newValue:{get(){let t=this.multiple?[]:"";return this.multiple?t=(this.value||[]).map(t=>null!=t?String(t):""):Object(u.isEmpty)(this.value)||null==this.value||(t=String(this.value)),t},set(t){this.$emit("input",t)}},optionsList(){return this.options.map(t=>{const e=this.formatOptions(t);let s=e.options;return e.options&&(s=e.options.map(this.formatOptions)),{...e,options:s}})},textValue(){const t=this.multiple,e=this.flattenOptions(this.optionsList||[]);if(t){const t=e.filter(t=>this.newValue.includes(t.value)).map(t=>t.label);return t.length>1?`${t[0]} +${t.length-1}`:t[0]}return(e.find(t=>t.value==this.newValue)||{}).label||"-"}},methods:{flattenOptions(t){const e=[];return t.forEach(t=>{t.options?e.push(...t.options):e.push(t)}),e},formatOptions(t){const e=this.props&&this.props.value||"value",s=this.props&&this.props.label||"label",a=t[e],n=t[s],l=t.options||null;return{...t,value:Object(u.isEmpty)(a)?"":String(a),label:Object(u.formatIfJson)(n),options:l}}}},M,[],!1,null,"0c1640be",null).exports,F=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-input-number",class:{"saas-text-mode":"text"===t.from}},["text"===t.from?s("span",{staticClass:"saas-input-number-text"},[t._v(t._s(t.textValue))]):s("el-input",t._g(t._b({model:{value:t.internalValue,callback:function(e){t.internalValue=e},expression:"internalValue"}},"el-input",t.attrs,!1),t.mergedListeners),[t.$slots.prepend?s("template",{slot:"prepend"},[t._t("prepend")],2):t._e(),t._v(" "),t.$slots.append?s("template",{slot:"append"},[t._t("append")],2):t._e()],2)],1)};F._withStripped=!0;var G=c({name:"SInputNumber",mixins:[L],props:{...Object(u.omit)(r.Input.props,["value","clearable"]),value:{type:[String,Number],default:""},placeholder:{type:String,default(){return this.$t("InputPlaceholder.pleasemsg")}},componentType:{type:String,default:"inputNumber"},min:{type:Number,default:-1/0},max:{type:Number,default:1/0},allowDecimal:{type:Boolean,default:!1},precision:{type:Number,default:0}},data(){return{internalValue:Object(u.isEmpty)(this.value)?"":String(this.value)}},computed:{mergedListeners(){return{...this.onEvents,input:this.handleInput,blur:this.handleBlur}}},watch:{value(t){"text"!==this.from&&(this.internalValue=this.formatInputValue(t))}},methods:{handleInput(t){let e=t;if(this.allowDecimal){e=t.replace(/[^-?\d.]/g,"");const s=(e.match(/\./g)||[]).length;if(s>1){const t=e.indexOf(".");e=e.substring(0,t+1)+e.substring(t+1).replace(/\./g,"")}if(s>0&&this.precision>=0){const t=e.split(".");t[1]&&t[1].length>this.precision&&(e=t[0]+"."+t[1].substring(0,this.precision))}}else e=t.replace(/[^-?\d]/g,"");const s=(e.match(/-/g)||[]).length;let a;s>1&&(e=e.replace(/-/g,""),e="-"+e),1!==s||e.startsWith("-")||(e=e.replace(/-/g,""),e="-"+e),e.startsWith("0")&&e.length>1&&!e.startsWith("-")&&(e=e.replace(/^0+/,"0"),e.length>1&&"."!==e[1]&&(e=e.replace(/^0+/,""))),e.startsWith("-0")&&e.length>2&&("."!==e[2]&&(e=e.replace(/^(-)0+/,"$1")),"-"===e&&(e="-0")),this.internalValue=e,a=""===e||"-"===e?"":this.allowDecimal?parseFloat(e):parseInt(e,10),this.$emit("input",a)},handleBlur(){let t,e=this.internalValue;if(""===e||"-"===e)return this.$emit("input",""),this.internalValue="",void this.$emit("blur","");this.allowDecimal?(t=parseFloat(e),this.precision>=0&&(t=parseFloat(t.toFixed(this.precision)))):t=parseInt(e,10),t<this.min?t=this.min:t>this.max&&(t=this.max),this.allowDecimal&&this.precision,this.internalValue=t.toString(),this.$emit("input",t),this.$emit("blur",t)},formatInputValue:t=>""===t||null==t?"":String(t)}},F,[],!1,null,null,null).exports,R=function(){var t=this,e=t.$createElement;return(t._self._c||e)("el-switch",t._g(t._b({model:{value:t.newValue,callback:function(e){t.newValue=e},expression:"newValue"}},"el-switch",t.attrs,!1),t.onEvents))};R._withStripped=!0;var U=c({name:"SSwitch",mixins:[L],props:{...Object(u.omit)(r.Input.props,["value"]),activeValue:{type:[Boolean,String,Number],default:1},inactiveValue:{type:[Boolean,String,Number],default:0},componentType:{type:String,default:"select"}},computed:{newValue:{get(){return this.value},set(t){this.$emit("input",t)}}}},R,[],!1,null,null,null).exports,K=c({name:"SPageButton",props:{gap:{type:[Number,String],default:8},direction:{type:String,default:"horizontal",validator:t=>["horizontal","vertical"].includes(t)},align:{type:String,default:"center"},wrap:{type:Boolean,default:!1}},computed:{directionClass(){return"horizontal"===this.direction?"saas-horizontal":"saas-vertical"}},render(t){const e=(this.$slots.default||[]).filter(t=>t.tag),s={gap:"number"==typeof this.gap?this.gap+"px":this.gap,alignItems:this.align};return t("div",{class:["saas-page__button",this.directionClass],style:s},e.map((t,e)=>(t.key=e,t)))}},void 0,void 0,!1,null,null,null).exports,D=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-detail"},[s("div",{staticClass:"saas-detail-top"},[s("div",{staticClass:"saas-detail-header"},[s("div",{staticClass:"saas-detail-backbox"},[t.showClose?s("div",{staticClass:"saas-detail-back",on:{click:t.goBack}},[s("span",{staticClass:"el-icon-arrow-left"})]):t._e()]),t._v(" "),s("div",{staticClass:"saas-detail-titlebox",style:t.computeStyle},[s("div",{staticClass:"saas-detail-title"},[s("span",{staticClass:"saas-title-line"}),t._v(" "),t.$slots.title?[t._t("title")]:s("span",[t._v("\n "+t._s(t.title)+"\n ")])],2),t._v(" "),t.titleSub?s("div",{staticClass:"saas-detail-sub"},[t._v(t._s(t.titleSub))]):t._e()]),t._v(" "),t._t("header-append")],2),t._v(" "),s("div",{staticClass:"saas-detail-content"},[t._t("default")],2)]),t._v(" "),t.showFooter?[s("div",{staticClass:"saas-detail-footer"},[t.$slots.footer?t._t("footer"):[s("el-button",{on:{click:t.handleClose}},[t._v(t._s(t.cancelText))]),t._v(" "),s("el-button",{directives:[{name:"preventReClick",rawName:"v-preventReClick",value:5e3,expression:"5000"}],attrs:{loading:t.loadingBtn,type:"primary"},on:{click:t.handleSubmit}},[t._v(t._s(t.confirmText))])]],2)]:t._e()],2)};D._withStripped=!0;var z=c({name:"SPagedetail",props:{showFooter:{type:Boolean,default:()=>!0},showClose:{type:Boolean,default:()=>!0},loadingBtn:{type:Boolean,default:()=>!1},computeStyle:{type:Object,default:()=>({width:"1000px",margin:"0 auto"})},title:{type:String,default:""},titleSub:{type:String,default:""},confirmText:{type:String,default(){return this.$t("buttonGroup.sure")}},cancelText:{type:String,default(){return this.$t("buttonGroup.cancel")}}},data:()=>({}),computed:{show:{get(){return this.visible},set(t){this.$emit("update:visible",t)}}},deactivated(){this.handleClose()},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("close")},goBack(){this.$emit("close")}}},D,[],!1,null,"063e3770",null).exports,q=function(){var t=this.$createElement;return(this._self._c||t)("el-button",this._g(this._b({staticClass:"saas-button-text",attrs:{type:this.buttonTypeComputed},on:{click:this.handleClick}},"el-button",this.$attrs,!1),this.filterListeners),[this._t("default")],2)};q._withStripped=!0;var J=c({name:"SButtonText",props:{path:String,query:Object,type:{type:String,default:"text"}},computed:{buttonTypeComputed(){return"link"===this.type?"text":this.type},filterListeners(){return Object(u.omit)(this.$listeners,["click"])}},methods:{handleClick(t){t.currentTarget.blur(),"link"===this.type&&this.path?this.push():this.$emit("click",t)},push(){let t=this.$router.resolve({path:this.path,query:this.query});window.open(t.href,"_blank")}}},q,[],!1,null,null,null).exports,H=function(){var t=this.$createElement;return(this._self._c||t)("div",{staticClass:"saas-space-item"},[this._t("default")],2)};H._withStripped=!0;var W=c({name:"SSpaceItem"},H,[],!1,null,null,null).exports,Q=c({name:"SSpace",components:{SpaceItem:W},props:{gap:{type:[Number,String],default:8},direction:{type:String,default:"horizontal",validator:t=>["horizontal","vertical"].includes(t)},align:{type:String,default:"center"},wrap:{type:Boolean,default:!1}},computed:{directionClass(){return"horizontal"===this.direction?"saas-horizontal":"saas-vertical"}},render(t){const e=(this.$slots.default||[]).filter(t=>t.tag),s={gap:"number"==typeof this.gap?this.gap+"px":this.gap,flexWrap:this.wrap?"wrap":"nowrap",alignItems:this.align};return t("div",{class:["saas-space",this.directionClass],style:s},e.map((e,s)=>t(W,{key:s},[e])))}},void 0,void 0,!1,null,null,null).exports;const Y={SDrawer:p,SDialog:h,SUnit:_,SCard:g,SGroup:w,SPagetable:f,STable:O,SContainer:I,STablecolumn:V,...n,...l,...i,...a},X=function(t){X.installed||Object.keys(Y).forEach(e=>{t.component(Y[e].name,Y[e])})};"undefined"!=typeof window&&window.Vue&&X(window.Vue);e.default={version:"1.0.0",install:X,SMessagebox:class{constructor(t,e,s=C){if(!t)throw new Error("[MessageBox] Vue instance is required");if(!s)throw new Error("[MessageBox] Vue component is required");this.Vue=t,this.i18n=e,this.Component=s,this.instance=null}_t(t){return this.i18n?this.i18n.t(t):t}_createInstance(){const t=this.Vue.extend(this.Component);this.instance=new t({el:document.createElement("div")}),document.body.appendChild(this.instance.$el)}_getInstance(){return this.instance||this._createInstance(),this.instance}alert(t){return this._getInstance().open({...t,title:t.title||this._t("deletemsg.hint"),confirmText:t.confirmText||this._t("buttonGroup.sure"),cancelText:t.cancelText||this._t("buttonGroup.cancel"),message:t.message,showCancelButton:!1})}confirm(t){return this._getInstance().open({...t,title:t.title||this._t("deletemsg.hint"),confirmText:t.confirmText||this._t("buttonGroup.sure"),cancelText:t.cancelText||this._t("buttonGroup.cancel"),message:t.message})}prompt(t){return this._getInstance().open({...t,title:t.title||this._t("deletemsg.hint"),confirmText:t.confirmText||this._t("buttonGroup.sure"),cancelText:t.cancelText||this._t("buttonGroup.cancel"),message:t.message,showInput:!0})}},...Y}}]).default;
1
+ module.exports=function(t){var e={};function s(a){if(e[a])return e[a].exports;var n=e[a]={i:a,l:!1,exports:{}};return t[a].call(n.exports,n,n.exports,s),n.l=!0,n.exports}return s.m=t,s.c=e,s.d=function(t,e,a){s.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:a})},s.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},s.t=function(t,e){if(1&e&&(t=s(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var a=Object.create(null);if(s.r(a),Object.defineProperty(a,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var n in t)s.d(a,n,function(e){return t[e]}.bind(null,n));return a},s.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return s.d(e,"a",e),e},s.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},s.p="",s(s.s=3)}([function(t,e){t.exports=require("chain-lodash")},function(t,e){t.exports=require("element-ui")},function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgBAMAAACBVGfHAAAAAXNSR0IArs4c6QAAADBQTFRFAAAAIK9wML9wKLdoKLdwKLdsKbhpKLlqKLdqKLhrKLdpKLhrKbhrKLhqKblqKLhqgtDn1gAAAA90Uk5TABAQICBAcH+An6C/z9/vjSAyHgAAAJdJREFUKM9dzs0JwkAUReGDIkwJFmELwmA/giXYQVpICa5sw417dy4FN+IPyc0YZ2Jy7/Lw8XhUKmuPkbSg/159qUbl6kQ7Jw8n7eTKeykdxqReSHcyuSXAWnqSyeaken6RPmQSVz1QQybn2f4LJDJpYg+GkMgPlJDIVpMwvMtAPAQPheAEJzjBCU5wghOc4AQnOMGJh9AB/uTa5S04zqUAAAAASUVORK5CYII="},function(t,e,s){"use strict";s.r(e);var a={};s.r(a),s.d(a,"SInput",(function(){return M})),s.d(a,"SSelect",(function(){return G})),s.d(a,"SInputNumber",(function(){return z})),s.d(a,"SSwitch",(function(){return K}));var n={};s.r(n),s.d(n,"SPageButton",(function(){return D})),s.d(n,"SPagedetail",(function(){return J}));var i={};s.r(i),s.d(i,"STableButtons",(function(){return A})),s.d(i,"SButtonText",(function(){return W})),s.d(i,"SButton",(function(){return T}));var l={};s.r(l),s.d(l,"SSpace",(function(){return X})),s.d(l,"SSpaceItem",(function(){return Y}));var o=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-drawer",t._g(t._b({staticClass:"saas-drawer",attrs:{wrapperClosable:!1,visible:t.show},on:{"update:visible":function(e){t.show=e}}},"el-drawer",t.bindProps,!1),t.$listeners),[t.$slots.title?s("template",{slot:"title"},[t._t("title")],2):t._e(),t._v(" "),s("div",{staticClass:"saas-drawer-content"},[t._t("default")],2),t._v(" "),t.showFooter?s("div",{staticClass:"saas-drawer-footer"},[t.$slots.footer?t._t("footer"):[t.showCancelButton?s("el-button",{on:{click:t.handleClose}},[t._v(t._s(t.cancelText))]):t._e(),t._v(" "),t.showConfirmButton?s("el-button",{directives:[{name:"preventReClick",rawName:"v-preventReClick",value:5e3,expression:"5000"}],attrs:{loading:t.loadingBtn,type:"primary"},on:{click:t.handleSubmit}},[t._v("\n "+t._s(t.confirmText)+"\n ")]):t._e()]],2):t._e()],2)};o._withStripped=!0;var r=s(1),u=s(0);function c(t,e,s,a,n,i,l,o){var r,u="function"==typeof t?t.options:t;if(e&&(u.render=e,u.staticRenderFns=s,u._compiled=!0),a&&(u.functional=!0),i&&(u._scopeId="data-v-"+i),l?(r=function(t){(t=t||this.$vnode&&this.$vnode.ssrContext||this.parent&&this.parent.$vnode&&this.parent.$vnode.ssrContext)||"undefined"==typeof __VUE_SSR_CONTEXT__||(t=__VUE_SSR_CONTEXT__),n&&n.call(this,t),t&&t._registeredComponents&&t._registeredComponents.add(l)},u._ssrRegister=r):n&&(r=o?function(){n.call(this,(u.functional?this.parent:this).$root.$options.shadowRoot)}:n),r)if(u.functional){u._injectStyles=r;var c=u.render;u.render=function(t,e){return r.call(e),c(t,e)}}else{var p=u.beforeCreate;u.beforeCreate=p?[].concat(p,r):[r]}return{exports:t,options:u}}var p=c({name:"SDrawer",props:{...r.Drawer.props,showFooter:{type:Boolean,default:()=>!0},size:{type:[String,Number],default:()=>"800px"},wrapperClosable:{type:Boolean,default:()=>!1},loadingBtn:{type:Boolean,default:()=>!1},appendToBody:{type:Boolean,default:!0},showCancelButton:{type:Boolean,default:!0},showConfirmButton:{type:Boolean,default:!0},confirmText:{type:String,default(){return this.$t("buttonGroup.sure")}},cancelText:{type:String,default(){return this.$t("buttonGroup.cancel")}}},data:()=>({}),computed:{show:{get(){return this.visible},set(t){this.$emit("update:visible",t)}},bindProps(){return Object(u.omit)(this.$props,["visible"])}},deactivated(){this.handleClose()},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("update:visible",!1),this.$emit("close")}}},o,[],!1,null,null,null).exports,d=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-dialog",t._g(t._b({staticClass:"saas-dialog",attrs:{"close-on-click-modal":!1,visible:t.show},on:{"update:visible":function(e){t.show=e}}},"el-dialog",t.bindProps,!1),t.$listeners),[t.$slots.title?s("template",{slot:"title"},[t._t("title")],2):t._e(),t._v(" "),s("div",{staticClass:"saas-dialog-content",class:{"saas-dialog-auto":t.isAuto}},[t._t("default")],2),t._v(" "),t.showFooter?s("template",{slot:"footer"},[t.$slots.footer?t._t("footer"):s("div",[t.showCancelButton?s("el-button",{on:{click:t.handleClose}},[t._v(t._s(t.cancelText))]):t._e(),t._v(" "),t.showConfirmButton?s("el-button",{directives:[{name:"preventReClick",rawName:"v-preventReClick",value:5e3,expression:"5000"}],attrs:{loading:t.loadingBtn,type:"primary"},on:{click:t.handleSubmit}},[t._v("\n "+t._s(t.confirmText)+"\n ")]):t._e()],1)],2):t._e()],2)};d._withStripped=!0;var h=c({name:"SDialog",props:{...r.Dialog.props,showFooter:{type:Boolean,default:()=>!0},width:{type:[String,Number],default:()=>"600px"},loadingBtn:{type:Boolean,default:()=>!1},visible:{type:Boolean,default:!1},showCancelButton:{type:Boolean,default:()=>!0},showConfirmButton:{type:Boolean,default:()=>!0},confirmText:{type:String,default(){return this.$t("buttonGroup.sure")}},cancelText:{type:String,default(){return this.$t("buttonGroup.cancel")}},isAuto:{type:Boolean,default:!0}},data:()=>({}),computed:{show:{get(){return this.visible},set(t){this.$emit("update:visible",t)}},bindProps(){return Object(u.omit)(this.$props,["visible"])}},deactivated(){this.handleClose()},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("update:visible",!1),this.$emit("close")}}},d,[],!1,null,null,null).exports,m=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{class:["saas-page-table",{"saas-page-table--hasButton":t.showFooterButton}]},[s("div",{staticClass:"saas-page-table__header"},[t.showHeader?[t.$slots.header?s("div",[t._t("header")],2):s("div",{staticClass:"saas-page-table__menu",class:{hasClose:t.showClose}},[t.showClose?[s("div",{staticClass:"saas-page-table__back",on:{click:t.goBack}},[s("span",{staticClass:"el-icon-arrow-left"})]),t._v(" "),s("span",{staticClass:"saas-page-table__back-title"},[t._v(t._s(t.$t("atSalaryFileImport.return")))]),t._v(" "),s("span",{staticClass:"saas-page-table__title-line"})]:t._e(),t._v(" "),t.showClose?t._e():s("span",{staticClass:"saas-page-header__line"}),t._v(" "),s("span",{staticClass:"saas-page-table__title"},[t.$slots.title?[t._t("title")]:s("span",[t._v(t._s(t.title))])],2),t._v(" "),t._t("header-append")],2)]:t._e(),t._v(" "),s("div",{staticClass:"saas-page-table__form"},[t._t("form")],2)],2),t._v(" "),s("div",{staticClass:"saas-page-table__content"},[t._t("default")],2),t._v(" "),s("div",{staticClass:"saas-page-table__footer"},[t._t("footer",[t.showFooterButton?[s("el-button",{on:{click:t.handleClose}},[t._v(t._s(t.cancelText))]),t._v(" "),s("el-button",{directives:[{name:"preventReClick",rawName:"v-preventReClick",value:5e3,expression:"5000"}],attrs:{loading:t.loadingBtn,type:"primary"},on:{click:t.handleSubmit}},[t._v(t._s(t.confirmText))])]:t._e()])],2)])};m._withStripped=!0;var f=c({name:"SPagetable",props:{showHeader:{type:Boolean,default:()=>!0},showFooter:{type:Boolean,default:()=>!0},showClose:{type:Boolean,default:()=>!1},loadingBtn:{type:Boolean,default:()=>!1},computeStyle:{type:Object,default:()=>({width:"1000px",margin:"0 auto"})},title:{type:String,default(){return this.$t("saasmenu."+this.$route.meta.code)}},titleSub:{type:String,default:""},confirmText:{type:String,default(){return this.$t("buttonGroup.sure")}},cancelText:{type:String,default(){return this.$t("buttonGroup.cancel")}},showTitle:{type:Boolean,default:!0},showFooterButton:{type:Boolean,default:!1}},data:()=>({}),computed:{show:{get(){return this.visible},set(t){this.$emit("update:visible",t)}}},deactivated(){this.handleClose()},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("close")},goBack(){this.$emit("close")}}},m,[],!1,null,"8d654078",null).exports,v=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-unit"},[s("span",{class:"saas-unit-"+t.typeCom}),t._v(" "),s("span",{class:["saas-unit-text",{"saas-unit-link":t.isLink}],on:{click:t.handleClick}},[t._t("default",[t._v("\n "+t._s(t.getValue)+"\n ")])],2)])};v._withStripped=!0;var _=c({name:"SUnit",props:{value:[String,Number],type:{type:String,default:""},options:{type:Array,default:()=>[]},props:{type:Object,default:()=>({value:"value",label:"label",style:"style",type:"",isShowCode:!1})},isLink:Boolean},data:()=>({}),computed:{typeCom(){if(Object(u.isEmpty)(this.value))return this.type||"primary";{const t=this.props.style||"style";return Object(u.getOptionValue)(this.options,this.value,{...this.props,label:t})||"primary"}},getValue(){if(!Object(u.isEmpty)(this.value)){const t=Object(u.getOptionValue)(this.options,this.value,this.props);return Object(u.formatIfJson)(t)}return""}},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("close")},goBack(){this.$emit("close")},handleClick(t){this.$emit("click",t)}}},v,[],!1,null,"26c2158e",null).exports,b=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{class:["saas-card",{"hidden-card":!t.isShow}]},[s("div",{staticClass:"saas-card-header"},[t.isCollapse?s("span",{class:[t.isShow?"el-icon-caret-bottom":"el-icon-caret-right","saas-card-icon"],on:{click:t.handleCollapse}}):t._e(),t._v(" "),s("div",{staticClass:"saas-card-title"},[t._t("title",[t._v("\n "+t._s(t.title)+"\n ")])],2)]),t._v(" "),s("div",{directives:[{name:"show",rawName:"v-show",value:t.isShow,expression:"isShow"}],staticClass:"saas-card-content"},[t._t("default")],2)])};b._withStripped=!0;var g=c({name:"SCard",props:{title:{type:String,default:""},titleSub:{type:String,default:""},isCollapse:{type:Boolean,default:!1}},data:()=>({isShow:!0}),computed:{},deactivated(){},methods:{handleCollapse(){this.isShow=!this.isShow}}},b,[],!1,null,"5ed7dbbb",null).exports,y=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("div",{staticClass:"saas-group"},t._l(t.list,(function(e,n){return a("div",{key:n,staticClass:"saas-sort-group"},t._l(e.children,(function(n,i){return a("div",{key:i,staticClass:"saas-sort-item",class:{active:t.getActive(n,e)},on:{click:function(s){return t.handleClick(n,e)}}},[a("div",{staticClass:"title",style:t.getSortStyle(n)},[t._v(t._s(t.formatValue(n,t.data)))]),t._v(" "),a("div",{staticClass:"text"},[a("span",[t._t("default",[t._v("\n "+t._s(n.label)+"\n "),n.tip?a("el-tooltip",{attrs:{content:n.tip}},[a("div",{attrs:{slot:"content"},domProps:{innerHTML:t._s(n.tip)},slot:"content"}),t._v(" "),a("i",{staticClass:"smart-info-filled",staticStyle:{color:"#a1a5b2","margin-left":"4px"}})]):t._e()],{item:n})],2)]),t._v(" "),a("img",{attrs:{src:s(2),alt:"",srcset:""}})])})),0)})),0)};y._withStripped=!0;var w=c({name:"SGroup",props:{title:{type:String,default:""},list:{type:Array,default:()=>[]},data:{type:Object,default:()=>({})},isActive:{type:Function,default:null}},data:()=>({}),computed:{},deactivated(){},methods:{getSortStyle(t){let e={};if("percent"===t.type){const s=this.data[t.field];e.color=s<=30?"#FF3B30":s<=60?"#FF9900":"#28B86A"}return e},handleClick(t,e){this.$emit("tab-click",t,e)},getActive(t,e){return!!this.isActive&&this.isActive(t,e)},formatValue:(t,e)=>t.formatValue?t.formatValue(t,e):e[t.value]}},y,[],!1,null,"4f2996b7",null).exports,S=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("transition",{attrs:{name:"el-fade-in-linear"}},[t.visible?s("div",{staticClass:"message-box-overlay"},[s("div",{staticClass:"message-box"},[t.showClose?s("i",{staticClass:"el-icon-close",on:{click:t.handleClose}}):t._e(),t._v(" "),s("div",{staticClass:"message-box_main"},[s("div",{staticClass:"message-box_icon"},[s("span",{staticClass:"el-icon-warning"})]),t._v(" "),s("div",{staticClass:"message-box_right"},[s("div",{staticClass:"message-box__header"},[s("span",{staticClass:"message-box__title"},[t._v(t._s(t.title))])]),t._v(" "),s("div",{staticClass:"message-box__content"},[t.message&&0==t.dangerouslyUseHTMLString?s("div",[t._v(t._s(t.message))]):t._e(),t._v(" "),t.message&&t.dangerouslyUseHTMLString?s("div",{domProps:{innerHTML:t._s(t.message)}}):t._e(),t._v(" "),t.showInput?s("el-input",{staticClass:"message-box__input",attrs:{placeholder:t.inputPlaceholder},model:{value:t.inputValue,callback:function(e){t.inputValue=e},expression:"inputValue"}}):t._e()],1)])]),t._v(" "),s("div",{staticClass:"message-box__footer"},[t.showCancelButton?s("el-button",{attrs:{size:"mini"},on:{click:t.handleCancel}},[t._v(t._s(t.cancelText))]):t._e(),t._v(" "),s("el-button",{attrs:{type:"primary",size:"mini"},on:{click:t.handleConfirm}},[t._v(t._s(t.confirmText))])],1)])]):t._e()])};S._withStripped=!0;var C=c({name:"SMessageBox",props:{},data:()=>({visible:!1,title:"",message:"",showInput:!1,inputValue:"",inputPlaceholder:"",showCancelButton:!1,resolve:null,reject:null,confirmText:"",cancelText:"",dangerouslyUseHTMLString:!1,showClose:!1}),methods:{open(t){return this.title=t.title,this.message=t.message||"",this.showClose=!!Object(u.isEmpty)(t.showClose)||t.showClose,this.showInput=t.showInput||!1,this.dangerouslyUseHTMLString=t.dangerouslyUseHTMLString||!1,this.inputPlaceholder=t.inputPlaceholder||"",this.showCancelButton=!!Object(u.isEmpty)(t.showCancelButton)||t.showCancelButton,this.confirmText=t.confirmText,this.cancelText=t.cancelText,this.showClose=t.showClose,this.visible=!0,this.inputValue="",new Promise((t,e)=>{this.resolve=t,this.reject=e})},handleConfirm(){this.visible=!1,this.showInput?this.resolve(this.inputValue):this.resolve(!0)},handleCancel(){this.visible=!1,this.reject("cancel")},handleClose(){this.visible=!1,this.reject("close")}}},S,[],!1,null,null,null).exports;var x=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-table",t._g(t._b({ref:"saasTable",staticClass:"saas-table"},"el-table",t.$props,!1),t.$listeners),[t._t("default"),t._v(" "),t._l(t.columns,(function(e){return s("STablecolumn",{key:e.value,attrs:{column:e,"min-width":t.minWidth},on:{action:t.handleColumnAction},scopedSlots:t._u([{key:e.value,fn:function(s){return[t._t(e.value,null,null,t.getBindProps(s,e))]}}],null,!0)})}))],2)};x._withStripped=!0;var $=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("el-table-column",t._b({scopedSlots:t._u(["index"===t.column.type?{key:"default",fn:function(e){var s=e.$index,a=e.row;return[t._t("default",[t._v("\n "+t._s(t.getIndex(s))+"\n ")],{index:t.getIndex(s),row:a})]}}:"operate"===t.column.type?{key:"default",fn:function(e){return[t._t(t.column.value,[s("s-table-buttons",{attrs:{list:t.column.actionList,row:e.row,index:e.$index},on:{action:t.handleAction}})],null,t.getBindProps(e))]}}:"unit"===t.column.type?{key:"default",fn:function(e){return[t._t(t.column.value,[s("s-unit",{attrs:{value:e.row[t.column.value],options:t.column.options}})],null,t.getBindProps(e))]}}:{key:"default",fn:function(e){return[t._t(t.column.value,[t._v("\n "+t._s(t.selectValue(e.row))+"\n ")],null,t.getBindProps(e))]}}],null,!0)},"el-table-column",t.columnProps,!1),[s("template",{slot:"header"},[t.$slots["header-"+t.column.value]?t._t("header-"+t.column.value,[t._v("\n "+t._s(t.column.label)+"\n ")],{column:t.column}):[s("span",[t._v(t._s(t.column.label))]),t._v(" "),t.column.tip?s("el-tooltip",{attrs:{placement:"top",content:t.column.tip}},[s("i",{staticClass:"smart-info-filled",staticStyle:{color:"#a1a5b2","margin-left":"6px"}})]):t._e()]],2)],2)};$._withStripped=!0;var B=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-table-buttons"},[t._l(t.buttonList,(function(e,a){return[s("el-tooltip",{key:a,attrs:{disabled:!e.tip,placement:"top",content:e.tip}},[s("s-button",t._b({on:{click:function(s){return t.handelClick(e.action)}}},"s-button",t.finalAttrs(e.attrs),!1),[t._v(t._s(e.label))])],1)]})),t._v(" "),t.dropdownList.length?s("el-dropdown",{on:{command:t.handleCommand}},[s("s-button",t._b({},"s-button",t.btnProps,!1),["more"==t.moreType?s("i",{staticClass:"smart-More"}):"text"==t.moreType?[t._v("\n "+t._s(t.text)+"\n "),s("i",{staticClass:"el-icon-arrow-down"})]:t._e()],2),t._v(" "),s("el-dropdown-menu",{attrs:{slot:"dropdown"},slot:"dropdown"},t._l(t.dropdownList,(function(e,a){return s("el-dropdown-item",t._b({key:a,attrs:{command:e.action}},"el-dropdown-item",t.finalAttrs(e.attrs),!1),[s("el-tooltip",{attrs:{disabled:!e.tip,placement:"top",content:e.tip}},[s("span",[t._v(t._s(e.label))])])],1)})),1)],1):t._e()],2)};B._withStripped=!0;var k=function(){var t=this,e=t.$createElement;return(t._self._c||e)("el-button",t._g(t._b({class:["saas-button",t.getButtonType],attrs:{type:t.buttonTypeComputed},on:{click:t.handleClick}},"el-button",t.$attrs,!1),t.filterListeners),[t._t("default")],2)};k._withStripped=!0;var T=c({name:"SButton",props:{type:{type:String,default:"default"}},computed:{buttonTypeComputed(){return"icon"===this.type?"default":this.type},getButtonType(){return this.type?"saas-button__"+this.type:""},filterListeners(){return Object(u.omit)(this.$listeners,["click"])}},methods:{handleClick(t){t.currentTarget.blur(),this.$emit("click",t)}}},k,[],!1,null,null,null).exports,A=c({name:"STableButtons",components:{SButton:T},props:{list:{type:Array,default:()=>[]},maxLength:{type:Number,default:2},moreType:{type:String,default:"more"},text:{type:String,default(){return this.$t("buttonGroup.more")}},row:{type:Object,default:()=>({})},index:{type:Number,default:0}},data:()=>({btnProps:{size:"mini",type:"text"}}),computed:{showList(){return this.list.filter(t=>{const e=!!Object(u.isEmpty)(t.show)||t.show;return"function"==typeof e?e(this.row):Boolean(e)})},buttonList(){return this.showList.slice(0,this.maxLength)},dropdownList(){return this.showList.slice(this.maxLength)}},methods:{finalAttrs(t={}){return{...this.btnProps,...t}},handleCommand(t){this.$emit("action",t,{...this.row,_index:this.index})},handelClick(t){this.$emit("action",t,{...this.row,_index:this.index})}}},B,[],!1,null,null,null).exports,V=c({name:"STablecolumn",components:{STableButton:A,SUnit:_},props:{column:Object,minWidth:{type:[Number,String],default:150}},data:()=>({}),computed:{columnProps(){const{type:t=null,fixed:e=null,width:s,minWidth:a}=this.column;return{...this.column,fixed:e||("operate"===t?"right":null),width:s||null,"min-width":s?null:a||this.minWidth,prop:this.column.value,label:this.column.label,showOverflowTooltip:null==this.column.showOverflowTooltip||this.column.showOverflowTooltip,index:this.column.indexMethod||null}}},methods:{selectValue(t){let e="";const{options:s=[],type:a="txt"}=this.column,n=t[this.column.value];if(this.column.formatValue)return this.column.formatValue(t,this.column);switch(a){case"select":let t=s.find(t=>t.value==n)||{};e=Object(u.formatIfJson)(t.label);break;case"time":e=Object(u.formatSubmitTime)(n,"DD/MM/YYYY");break;default:e=Object(u.formatIfJson)(n)}return Object(u.isEmpty)(e)?e=this.column.defaultValue||"-":e.length>500&&(e=e.slice(0,500)+"..."),e},getBindProps(t){return{...t,column:this.column}},getIndex(t){return this.indexMethod?this.indexMethod(t):t+1},handleAction(t,e,s){this.$emit("action",t,e,s)}}},$,[],!1,null,null,null).exports,O=c({name:"STable",props:{...r.Table.props,border:{type:Boolean,default:!0},columns:{type:Array,default:()=>[]},minWidth:{type:[Number,String],default:150}},components:{STablecolumn:V},data:()=>({}),computed:{},mounted(){this.$nextTick(()=>{this.doLayout()})},deactivated(){},methods:{handleColumnAction(t,e,s){this.$emit("action",t,e,s)},getBindProps:(t,e)=>({...t,column:e}),doLayout(){this.$refs.saasTable.doLayout()}}},x,[],!1,null,null,null).exports,j=function(){var t=this.$createElement,e=this._self._c||t;return e("div",{staticClass:"saas-container"},[e("div",{staticClass:"saas-container-header"},[this._t("header")],2),this._v(" "),e("div",{staticClass:"saas-container-content"},[this._t("default")],2),this._v(" "),e("div",{staticClass:"saas-container-footer"},[this._t("footer")],2)])};j._withStripped=!0;var I=c({name:"SContainer",props:{title:{type:String,default:""},titleSub:{type:String,default:""}},data:()=>({}),computed:{},deactivated(){},methods:{}},j,[],!1,null,"2036a697",null).exports,E=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-steps"},t._l(t.steps,(function(e,a){return s("div",{key:a,staticClass:"saas-steps-item",class:{"saas-steps-item-active":t.active===a,"saas-steps-item-finish":t.active>a,"saas-steps-item-custom":e.icon}},[s("div",{staticClass:"saas-steps-item-icon"},[e.icon?s("span",{staticClass:"saas-steps-custom-icon"},[t._t("icon-"+a)],2):s("span",{staticClass:"saas-steps-icon"},[t.active>a?[s("svg",{staticClass:"anticon",attrs:{viewBox:"64 64 896 896"}},[s("path",{attrs:{d:"M912 190h-69.9c-9.8 0-19.1 4.5-25.1 12.2L404.7 724.5 207 474a32 32 0 0 0-25.1-12.2H112c-6.7 0-10.4 7.7-6.3 12.9l273.9 347c12.8 16.2 37.4 16.2 50.2 0l488.4-618.9c4.1-5.1.4-12.8-6.3-12.8z"}})])]:[t._v(t._s(a+1))]],2)]),t._v(" "),s("div",{staticClass:"saas-steps-item-content"},[s("div",{staticClass:"saas-steps-item-title"},[t._v(t._s(e.label))]),t._v(" "),e.description?s("div",{staticClass:"saas-steps-item-description"},[t._v(t._s(e.description))]):t._e()])])})),0)};E._withStripped=!0;var L=c({name:"SSteps",props:{active:{type:Number,default:0},steps:{type:Array,required:!0},direction:{type:String,default:"horizontal",validator:t=>["horizontal","vertical"].includes(t)}}},E,[],!1,null,null,null).exports,P=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-input",class:{"saas-text-mode":"text"===t.from}},["text"===t.from?s("span",{staticClass:"saas-input-text"},[t._v(t._s(t.textValue))]):s("el-input",t._g(t._b({model:{value:t.newValue,callback:function(e){t.newValue=e},expression:"newValue"}},"el-input",t.attrs,!1),t.onEvents),[t.$slots.prepend?s("template",{slot:"prepend"},[t._t("prepend")],2):t._e(),t._v(" "),t.$slots.append?s("template",{slot:"append"},[t._t("append")],2):t._e()],2)],1)};P._withStripped=!0;var N={props:{value:{type:[String,Number,Array],default:""},mode:{type:String,default:"FORM"},clearable:{type:Boolean,default:!0},from:{type:String,default:"input"},placeholder:{type:String,default(){return this.$t("selectGroup.pleaseSelect")}},componentType:{type:String,default:"input"}},computed:{newValue:{get(){return Object(u.isEmpty)(this.value)||null==this.value?"":String(this.value)},set(t){this.$emit("input",t)}},textValue(){if("select"==this.componentType){const t=this.flattenOptions(this.options);if(this.multiple){const e=t.filter(t=>this.newValue.includes(t.value)).map(t=>t.label);return e.length>1?`${e[0]} +${e.length-1}`:e[0]||"-"}return(t.find(t=>t.value==this.newValue)||{}).label||"-"}return this.newValue||"-"},attrs(){const t=Object.assign({},this.defaultAttrs,this.$props,this.$attrs),e=["value","from"];return Object.keys(t).filter(t=>!e.includes(t)).reduce((e,s)=>(e[s]=t[s],e),{})},onEvents(){return this.$listeners}},methods:{flattenOptions(t){const e=[];return t.forEach(t=>{t.options?e.push(...t.options):e.push(t)}),e}}},M=c({name:"SInput",mixins:[N],props:{...Object(u.omit)(r.Input.props,["value","clearable","maxlength"]),maxlength:{type:Number,default:120},placeholder:{type:String,default(){return this.$t("InputPlaceholder.pleasemsg")}}},computed:{}},P,[],!1,null,"0b51b93c",null).exports,F=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-select",class:{"saas-text-mode":"text"===t.from}},["text"===t.from?s("span",{staticClass:"input-text"},[t._v(t._s(t.textValue))]):s("el-select",t._g(t._b({staticClass:"saas-select-input",attrs:{filterable:"",clearable:""},model:{value:t.newValue,callback:function(e){t.newValue=e},expression:"newValue"}},"el-select",t.attrs,!1),t.onEvents),[t._l(t.optionsList,(function(e){return[e.options?s("el-option-group",{key:e.value,attrs:{label:e.label}},t._l(e.options,(function(t){return s("el-option",{key:t.value,attrs:{disabled:t.disabled,label:t.label,value:t.value}})})),1):s("el-option",{key:e.value,attrs:{disabled:e.disabled,label:e.label,value:e.value}})]}))],2)],1)};F._withStripped=!0;var G=c({name:"SSelect",mixins:[N],props:{...Object(u.omit)(r.Select.props,["value","clearable"]),value:{type:[String,Number,Array]},clearable:{type:Boolean,default:()=>!0},placeholder:{type:String,default(){return this.$t("selectGroup.pleaseSelect")}},from:{type:String,default:"select"},options:{type:Array,default:()=>[]},componentType:{type:String,default:"select"},props:{type:Object,default:()=>({label:"label",value:"value"})}},data:()=>({}),computed:{newValue:{get(){let t=this.multiple?[]:"";return this.multiple?t=(this.value||[]).map(t=>null!=t?String(t):""):Object(u.isEmpty)(this.value)||null==this.value||(t=String(this.value)),t},set(t){this.$emit("input",t)}},optionsList(){return this.options.map(t=>{const e=this.formatOptions(t);let s=e.options;return e.options&&(s=e.options.map(this.formatOptions)),{...e,options:s}})},textValue(){const t=this.multiple,e=this.flattenOptions(this.optionsList||[]);if(t){const t=e.filter(t=>this.newValue.includes(t.value)).map(t=>t.label);return t.length>1?`${t[0]} +${t.length-1}`:t[0]}return(e.find(t=>t.value==this.newValue)||{}).label||"-"},filterOptions(){return this.options.filter(t=>{if(!1===t.show)return!1;if(t.options&&Array.isArray(t.options)){return t.options.filter(t=>!1!==t.show).length>0}return!1!==t.show}).map(t=>t.options&&Array.isArray(t.options)?{...t,options:t.options.filter(t=>!1!==t.show)}:t)}},methods:{flattenOptions(t){const e=[];return t.forEach(t=>{t.options?e.push(...t.options):e.push(t)}),e},formatOptions(t){const e=this.props&&this.props.value||"value",s=this.props&&this.props.label||"label",a=t[e],n=t[s],i=t.options||null;return{...t,value:Object(u.isEmpty)(a)?"":String(a),label:Object(u.formatIfJson)(n),options:i}}}},F,[],!1,null,"29b2c16b",null).exports,R=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-input-number",class:{"saas-text-mode":"text"===t.from}},["text"===t.from?s("span",{staticClass:"saas-input-number-text"},[t._v(t._s(t.textValue))]):s("el-input",t._g(t._b({model:{value:t.internalValue,callback:function(e){t.internalValue=e},expression:"internalValue"}},"el-input",t.attrs,!1),t.mergedListeners),[t.$slots.prepend?s("template",{slot:"prepend"},[t._t("prepend")],2):t._e(),t._v(" "),t.$slots.append?s("template",{slot:"append"},[t._t("append")],2):t._e()],2)],1)};R._withStripped=!0;var z=c({name:"SInputNumber",mixins:[N],props:{...Object(u.omit)(r.Input.props,["value","clearable"]),value:{type:[String,Number],default:""},placeholder:{type:String,default(){return this.$t("InputPlaceholder.pleasemsg")}},componentType:{type:String,default:"inputNumber"},min:{type:Number,default:-1/0},max:{type:Number,default:1/0},allowDecimal:{type:Boolean,default:!1},precision:{type:Number,default:0}},data(){return{internalValue:Object(u.isEmpty)(this.value)?"":String(this.value)}},computed:{mergedListeners(){return{...this.onEvents,input:this.handleInput,blur:this.handleBlur}}},watch:{value(t){"text"!==this.from&&(this.internalValue=this.formatInputValue(t))}},methods:{handleInput(t){let e=t;if(this.allowDecimal){e=t.replace(/[^-?\d.]/g,"");const s=(e.match(/\./g)||[]).length;if(s>1){const t=e.indexOf(".");e=e.substring(0,t+1)+e.substring(t+1).replace(/\./g,"")}if(s>0&&this.precision>=0){const t=e.split(".");t[1]&&t[1].length>this.precision&&(e=t[0]+"."+t[1].substring(0,this.precision))}}else e=t.replace(/[^-?\d]/g,"");const s=(e.match(/-/g)||[]).length;let a;s>1&&(e=e.replace(/-/g,""),e="-"+e),1!==s||e.startsWith("-")||(e=e.replace(/-/g,""),e="-"+e),e.startsWith("0")&&e.length>1&&!e.startsWith("-")&&(e=e.replace(/^0+/,"0"),e.length>1&&"."!==e[1]&&(e=e.replace(/^0+/,""))),e.startsWith("-0")&&e.length>2&&("."!==e[2]&&(e=e.replace(/^(-)0+/,"$1")),"-"===e&&(e="-0")),this.internalValue=e,a=""===e||"-"===e?"":this.allowDecimal?parseFloat(e):parseInt(e,10),this.$emit("input",a)},handleBlur(){let t,e=this.internalValue;if(""===e||"-"===e)return this.$emit("input",""),this.internalValue="",void this.$emit("blur","");this.allowDecimal?(t=parseFloat(e),this.precision>=0&&(t=parseFloat(t.toFixed(this.precision)))):t=parseInt(e,10),t<this.min?t=this.min:t>this.max&&(t=this.max),this.allowDecimal&&this.precision,this.internalValue=t.toString(),this.$emit("input",t),this.$emit("blur",t)},formatInputValue:t=>""===t||null==t?"":String(t)}},R,[],!1,null,null,null).exports,U=function(){var t=this,e=t.$createElement;return(t._self._c||e)("el-switch",t._g(t._b({model:{value:t.newValue,callback:function(e){t.newValue=e},expression:"newValue"}},"el-switch",t.attrs,!1),t.onEvents))};U._withStripped=!0;var K=c({name:"SSwitch",mixins:[N],props:{...Object(u.omit)(r.Input.props,["value"]),activeValue:{type:[Boolean,String,Number],default:1},inactiveValue:{type:[Boolean,String,Number],default:0},componentType:{type:String,default:"select"}},computed:{newValue:{get(){return this.value},set(t){this.$emit("input",t)}}}},U,[],!1,null,null,null).exports,D=c({name:"SPageButton",props:{gap:{type:[Number,String],default:8},direction:{type:String,default:"horizontal",validator:t=>["horizontal","vertical"].includes(t)},align:{type:String,default:"center"},wrap:{type:Boolean,default:!1}},computed:{directionClass(){return"horizontal"===this.direction?"saas-horizontal":"saas-vertical"}},render(t){const e=(this.$slots.default||[]).filter(t=>t.tag),s={gap:"number"==typeof this.gap?this.gap+"px":this.gap,alignItems:this.align};return t("div",{class:["saas-page__button",this.directionClass],style:s},e.map((t,e)=>(t.key=e,t)))}},void 0,void 0,!1,null,null,null).exports,q=function(){var t=this,e=t.$createElement,s=t._self._c||e;return s("div",{staticClass:"saas-detail"},[s("div",{staticClass:"saas-detail-top"},[s("div",{staticClass:"saas-detail-header"},[s("div",{staticClass:"saas-detail-backbox"},[t.showClose?s("div",{staticClass:"saas-detail-back",on:{click:t.goBack}},[s("span",{staticClass:"el-icon-arrow-left"})]):t._e()]),t._v(" "),s("div",{staticClass:"saas-detail-titlebox",style:t.computeStyle},[s("div",{staticClass:"saas-detail-title"},[s("span",{staticClass:"saas-title-line"}),t._v(" "),t.$slots.title?[t._t("title")]:s("span",[t._v("\n "+t._s(t.title)+"\n ")])],2),t._v(" "),t.titleSub?s("div",{staticClass:"saas-detail-sub"},[t._v(t._s(t.titleSub))]):t._e()]),t._v(" "),t._t("header-append")],2),t._v(" "),s("div",{staticClass:"saas-detail-content"},[t._t("default")],2)]),t._v(" "),t.showFooter?[s("div",{staticClass:"saas-detail-footer"},[t.$slots.footer?t._t("footer"):[s("el-button",{on:{click:t.handleClose}},[t._v(t._s(t.cancelText))]),t._v(" "),s("el-button",{directives:[{name:"preventReClick",rawName:"v-preventReClick",value:5e3,expression:"5000"}],attrs:{loading:t.loadingBtn,type:"primary"},on:{click:t.handleSubmit}},[t._v(t._s(t.confirmText))])]],2)]:t._e()],2)};q._withStripped=!0;var J=c({name:"SPagedetail",props:{showFooter:{type:Boolean,default:()=>!0},showClose:{type:Boolean,default:()=>!0},loadingBtn:{type:Boolean,default:()=>!1},computeStyle:{type:Object,default:()=>({width:"1000px",margin:"0 auto"})},title:{type:String,default:""},titleSub:{type:String,default:""},confirmText:{type:String,default(){return this.$t("buttonGroup.sure")}},cancelText:{type:String,default(){return this.$t("buttonGroup.cancel")}}},data:()=>({}),computed:{show:{get(){return this.visible},set(t){this.$emit("update:visible",t)}}},deactivated(){this.handleClose()},methods:{handleSubmit(){this.$emit("confirm")},handleClose(){this.$emit("close")},goBack(){this.$emit("close")}}},q,[],!1,null,"063e3770",null).exports,H=function(){var t=this.$createElement;return(this._self._c||t)("el-button",this._g(this._b({staticClass:"saas-button-text",attrs:{type:this.buttonTypeComputed},on:{click:this.handleClick}},"el-button",this.$attrs,!1),this.filterListeners),[this._t("default")],2)};H._withStripped=!0;var W=c({name:"SButtonText",props:{path:String,query:Object,type:{type:String,default:"text"}},computed:{buttonTypeComputed(){return"link"===this.type?"text":this.type},filterListeners(){return Object(u.omit)(this.$listeners,["click"])}},methods:{handleClick(t){t.currentTarget.blur(),"link"===this.type&&this.path?this.push():this.$emit("click",t)},push(){let t=this.$router.resolve({path:this.path,query:this.query});window.open(t.href,"_blank")}}},H,[],!1,null,null,null).exports,Q=function(){var t=this.$createElement;return(this._self._c||t)("div",{staticClass:"saas-space-item"},[this._t("default")],2)};Q._withStripped=!0;var Y=c({name:"SSpaceItem"},Q,[],!1,null,null,null).exports,X=c({name:"SSpace",components:{SpaceItem:Y},props:{gap:{type:[Number,String],default:8},direction:{type:String,default:"horizontal",validator:t=>["horizontal","vertical"].includes(t)},align:{type:String,default:"center"},wrap:{type:Boolean,default:!1}},computed:{directionClass(){return"horizontal"===this.direction?"saas-horizontal":"saas-vertical"}},render(t){const e=(this.$slots.default||[]).filter(t=>t.tag),s={gap:"number"==typeof this.gap?this.gap+"px":this.gap,flexWrap:this.wrap?"wrap":"nowrap",alignItems:this.align};return t("div",{class:["saas-space",this.directionClass],style:s},e.map((e,s)=>t(Y,{key:s},[e])))}},void 0,void 0,!1,null,null,null).exports;const Z={SDrawer:p,SDialog:h,SUnit:_,SCard:g,SGroup:w,SPagetable:f,STable:O,SContainer:I,STablecolumn:V,SSteps:L,...n,...i,...l,...a},tt=function(t){tt.installed||Object.keys(Z).forEach(e=>{t.component(Z[e].name,Z[e])})};"undefined"!=typeof window&&window.Vue&&tt(window.Vue);e.default={version:"1.0.0",install:tt,SMessagebox:class{constructor(t,e,s=C){if(!t)throw new Error("[MessageBox] Vue instance is required");if(!s)throw new Error("[MessageBox] Vue component is required");this.Vue=t,this.i18n=e,this.Component=s,this.instance=null}_t(t){return this.i18n?this.i18n.t(t):t}_createInstance(){const t=this.Vue.extend(this.Component);this.instance=new t({el:document.createElement("div")}),document.body.appendChild(this.instance.$el)}_getInstance(){return this.instance||this._createInstance(),this.instance}alert(t){return this._getInstance().open({...t,title:t.title||this._t("deletemsg.hint"),confirmText:t.confirmText||this._t("buttonGroup.sure"),cancelText:t.cancelText||this._t("buttonGroup.cancel"),message:t.message,showCancelButton:!1})}confirm(t){return this._getInstance().open({...t,title:t.title||this._t("deletemsg.hint"),confirmText:t.confirmText||this._t("buttonGroup.sure"),cancelText:t.cancelText||this._t("buttonGroup.cancel"),message:t.message})}prompt(t){return this._getInstance().open({...t,title:t.title||this._t("deletemsg.hint"),confirmText:t.confirmText||this._t("buttonGroup.sure"),cancelText:t.cancelText||this._t("buttonGroup.cancel"),message:t.message,showInput:!0})}},...Z}}]).default;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "chain-saasui",
3
- "version": "1.0.10-alpha.0",
3
+ "version": "1.0.10-alpha.2",
4
4
  "description": "chain-saasui",
5
5
  "author": "Saas",
6
6
  "license": "MIT",