Skip to content

Commit 73d6bda

Browse files
authored
Merge pull request #5092 from jumpserver/dev
merge: v4.10.4-lts
2 parents 3934b45 + e83e442 commit 73d6bda

File tree

43 files changed

+249
-124
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+249
-124
lines changed

.prettierrc

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
{
2+
"printWidth": 100,
3+
"tabWidth": 2,
4+
"useTabs": false,
5+
"singleQuote": true,
6+
"semi": false,
7+
"trailingComma": "none",
8+
"bracketSpacing": true,
9+
"arrowParens": "avoid",
10+
"endOfLine": "lf"
11+
}

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM jumpserver/lina-base:20250616_083043 AS stage-build
1+
FROM jumpserver/lina-base:20250709_063112 AS stage-build
22

33
ARG VERSION
44
ENV VERSION=$VERSION

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
"deepmerge": "^4.2.2",
3939
"dompurify": "^3.1.6",
4040
"echarts": "4.7.0",
41-
"element-ui": "2.15.14",
41+
"elementui-lts": "^2.16.0",
4242
"eslint-plugin-html": "^6.0.0",
4343
"highlight.js": "^11.9.0",
4444
"install": "^0.13.0",
@@ -103,7 +103,6 @@
103103
"compression-webpack-plugin": "^6.1.1",
104104
"connect": "3.6.6",
105105
"deasync": "^0.1.29",
106-
"element-theme-chalk": "^2.13.1",
107106
"eslint": "^5.15.3",
108107
"eslint-plugin-vue": "5.2.2",
109108
"eslint-plugin-vue-i18n": "^0.3.0",
@@ -113,6 +112,7 @@
113112
"less-loader": "^5.0.0",
114113
"lint-staged": "^10.1.2",
115114
"mockjs": "1.0.1-beta3",
115+
"pretty-bytes": "^5.6.0",
116116
"runjs": "^4.3.2",
117117
"sass": "~1.32.6",
118118
"sass-loader": "^7.1.0",

src/components/Apps/GrantedAssets/index.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -85,6 +85,7 @@ export default {
8585
hasTree: true,
8686
columnsExtra: ['view_account'],
8787
columnsExclude: ['spec_info'],
88+
columns: ['id', 'name', 'address', 'platform', 'view_account', 'actions'],
8889
columnsShow: {
8990
min: ['name', 'address', 'accounts'],
9091
default: ['name', 'address', 'platform', 'view_account', 'actions']

src/components/Common/QuickActions/action.vue

Lines changed: 17 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,23 @@
11
<template>
22
<tr>
3-
<td>{{ getActionTitle(action) }}</td>
43
<td>
5-
<el-popover
6-
:content="action.attrs.tip"
7-
:disabled="!action.attrs.showTip"
8-
placement="left-end"
9-
trigger="hover"
10-
>
11-
<span slot="reference">
12-
<component
13-
:is="iType"
14-
v-model="action.attrs.model"
15-
:title="label"
16-
v-bind="action.attrs"
17-
v-on="callbacks"
18-
>
19-
{{ label }}
20-
</component>
21-
</span>
22-
</el-popover>
4+
{{ getActionTitle(action) }}
5+
<el-tooltip v-if="action.attrs.showTip" :content="action.attrs.tip" :open-delay="500" effect="dark">
6+
<i class="fa fa-question-circle-o" />
7+
</el-tooltip>
8+
</td>
9+
<td>
10+
<span slot="reference">
11+
<component
12+
:is="iType"
13+
v-model="action.attrs.model"
14+
:title="label"
15+
v-bind="action.attrs"
16+
v-on="callbacks"
17+
>
18+
{{ label }}
19+
</component>
20+
</span>
2321
</td>
2422
</tr>
2523
</template>

src/components/Table/AutoDataTable/utils.js

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -20,18 +20,18 @@ export class TableColumnsGenerator {
2020
this.vm = vm
2121
}
2222

23-
dynamicActionWidth() {
24-
console.log(i18n.locale)
25-
if (i18n.locale === 'zh-hans' || i18n.locale === 'zh-hant') {
26-
return '100px'
27-
}
23+
// dynamicActionWidth() {
24+
// console.log(i18n.locale)
25+
// if (i18n.locale === 'zh-hans' || i18n.locale === 'zh-hant') {
26+
// return '100px'
27+
// }
2828

29-
if (i18n.locale === 'ja' || i18n.locale === 'ko') {
30-
return '120px'
31-
}
29+
// if (i18n.locale === 'ja' || i18n.locale === 'ko') {
30+
// return '120px'
31+
// }
3232

33-
return '160px'
34-
}
33+
// return '160px'
34+
// }
3535

3636
generateColumns() {
3737
const config = _.cloneDeep(this.config)
@@ -135,7 +135,7 @@ export class TableColumnsGenerator {
135135
prop: 'actions',
136136
label: i18n.t('Actions'),
137137
align: 'center',
138-
width: this.dynamicActionWidth(),
138+
width: '120px',
139139
formatter: ActionsFormatter,
140140
fixed: 'right',
141141
formatterArgs: {}

src/components/Table/CardTable/Panel.vue

Lines changed: 11 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4,29 +4,29 @@
44
{{ $t('Enterprise') }}
55
</span>
66
<el-row class="panel">
7-
<el-col v-if="d.icon" :span="8" class="image">
7+
<el-col v-if="d.icon" :span="d.icon ? 8 : 0" class="image">
88
<img
99
v-if="d.icon.startsWith('/') || d.icon.startsWith('data:')"
1010
:alt="d.display_name"
1111
:src="d.icon"
1212
>
1313
<Icon v-else :icon="d.icon" />
1414
</el-col>
15-
<el-col :span="16" class="text-zone">
15+
<el-col :span="d.icon ? 16 : 24" class="text-zone">
1616
<div class="one-line">
1717
<b>{{ d.display_name }}</b>
18-
<el-tag v-if="d.version" size="mini" style="margin-left: 5px">
19-
{{ d.version }}
20-
</el-tag>
21-
</div>
22-
<div :title="d.comment " class="comment">
23-
{{ d.comment }}
2418
</div>
2519
<div class="tag-zone">
20+
<el-tag v-if="d.version" size="mini" style="margin-left: 5px; background-color: #ecf5ff; color: #409eff;">
21+
{{ d.version }}
22+
</el-tag>
2623
<el-tag v-for="tag of d.tags" :key="tag" size="mini">
2724
{{ capitalize(tag) }}
2825
</el-tag>
2926
</div>
27+
<div :title="d.comment " class="comment">
28+
{{ d.comment }}
29+
</div>
3030
</el-col>
3131
</el-row>
3232
</div>
@@ -107,22 +107,20 @@ export default {
107107
108108
.comment {
109109
display: -webkit-box;
110-
height: 120px;
110+
margin-top: 10px;
111111
font-size: 12px;
112-
padding: 10px 0;
113112
cursor: pointer;
114113
overflow: hidden;
115114
-webkit-line-clamp: 4;
116-
-webkit-box-flex: 1;
117115
-webkit-box-orient: vertical;
118-
text-align: left;
119116
}
120117
121118
.tag-zone {
122119
display: flex;
123-
height: 30%;
124120
align-items: center;
125121
cursor: pointer;
122+
margin-top: 10px;
123+
margin-left: -5px;
126124
}
127125
}
128126
}

src/components/Table/CardTable/index.vue

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -248,6 +248,10 @@ export default {
248248
display: flex;
249249
justify-content: left;
250250
flex-wrap: wrap;
251+
252+
.el-card .el-card__body div {
253+
height: inherit;
254+
}
251255
}
252256
253257
.el-col, div {

src/components/Table/DrawerListTable/index.vue

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -196,26 +196,33 @@ export default {
196196
}
197197
198198
let title = this.title
199+
199200
if (!title && this.resource) {
200201
title = this.resource
201202
}
203+
202204
if (!title) {
203205
title = this.$route.meta?.title
204206
title = title.replace('List', '').replace('列表', '')
205207
title = _.trimEnd(title, 's')
206208
}
209+
207210
if (!title) {
208211
title = this.$t('NoTitle')
209212
}
213+
210214
let actionLabel = ''
215+
211216
if (action === 'clone' || action === 'create') {
212217
actionLabel = this.$t('Create')
213218
} else if (action === 'update') {
214219
actionLabel = this.$t('Update')
215220
} else if (action === 'detail') {
216221
actionLabel = this.$t('Detail')
217222
}
223+
218224
title = actionLabel + this.$t('WordSep') + toLowerCaseExcludeAbbr(title)
225+
219226
return title
220227
},
221228
getDefaultDrawer(action) {

src/components/Table/TableFormatters/AccountConnectFormatter.vue

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ export default {
6060
asset=${assetId}
6161
&account=${row.id}
6262
&protocol=${protocol}
63+
&org_id=${this.$store.getters.currentOrg.id}
6364
`.replace(/\s+/g, '')
6465
},
6566
asset: null,

0 commit comments

Comments
 (0)