Skip to content

Commit

Permalink
Merge pull request #1 from MatthewAden/front-change-for-issue#12217
Browse files Browse the repository at this point in the history
Frontend changes for #12217.
  • Loading branch information
shiyiyue1102 authored Nov 13, 2024
2 parents b10c024 + e91db0c commit d3b6040
Show file tree
Hide file tree
Showing 7 changed files with 32 additions and 22 deletions.
3 changes: 3 additions & 0 deletions console-ui/src/locales/en-US.js
Original file line number Diff line number Diff line change
Expand Up @@ -261,6 +261,9 @@ const I18N_CONF = {
historyCompareTitle: 'History Compare',
historyCompareLastVersion: 'Lasted Release Version',
historyCompareSelectedVersion: 'Selected Version',
publishType: 'Publish Type',
formal: 'Formal Version',
gray: 'Gray Version',
},
HistoryDetail: {
historyDetails: 'History Details',
Expand Down
3 changes: 3 additions & 0 deletions console-ui/src/locales/zh-CN.js
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,9 @@ const I18N_CONF = {
historyCompareTitle: '历史版本比较',
historyCompareLastVersion: '最新版本',
historyCompareSelectedVersion: '当前选中版本',
publishType: '发布类型',
formal: '正式版本',
gray: '灰度版本',
},
HistoryDetail: {
historyDetails: '历史详情',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,7 @@ class ConfigRollback extends React.Component {
toggleMore() {
this.setState({
showmore: !this.state.showmore,
extraInfo: data.extraInfo ? JSON.parse(data.extraInfo) : {},
});
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ class HistoryDetail extends React.Component {
success(result) {
if (result != null) {
const data = result;
const extInfo = data.extInfo ? JSON.parse(data.extInfo) : {};
const grayRule = extInfo.gray_rule ? JSON.parse(extInfo.gray_rule) : {};

self.field.setValue('dataId', data.dataId);
self.field.setValue('content', data.content);
self.field.setValue('appName', self.inApp ? self.edasAppName : data.appName);
Expand All @@ -80,8 +83,8 @@ class HistoryDetail extends React.Component {
self.setState({
currentPublishType: data.publishType,
...(data.publishType === 'gray' && {
grayVersion: JSON.parse(data.extraInfo || '{}').version || '',
grayRule: JSON.parse(data.extraInfo || '{}').expr || '',
grayVersion: grayRule.version || '',
grayRule: grayRule.expr || '',
}),
});
}
Expand Down
18 changes: 9 additions & 9 deletions console/src/main/resources/static/console-ui/public/js/main.js

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions console/src/main/resources/static/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
<link rel="stylesheet" type="text/css" href="console-ui/public/css/icon.css">
<link rel="stylesheet" type="text/css" href="console-ui/public/css/font-awesome.css">
<!-- 第三方css结束 -->
<link href="./css/main.css?e0e49a29a07457c6b302" rel="stylesheet"></head>
<link href="./css/main.css?21f06ce60fe9f44ca3ca" rel="stylesheet"></head>

<body>
<div id="root" style="overflow:hidden"></div>
Expand All @@ -56,6 +56,6 @@
<script src="console-ui/public/js/merge.js"></script>
<script src="console-ui/public/js/loader.js"></script>
<!-- 第三方js结束 -->
<script type="text/javascript" src="./js/main.js?e0e49a29a07457c6b302"></script></body>
<script type="text/javascript" src="./js/main.js?21f06ce60fe9f44ca3ca"></script></body>

</html>
18 changes: 9 additions & 9 deletions console/src/main/resources/static/js/main.js

Large diffs are not rendered by default.

0 comments on commit d3b6040

Please sign in to comment.