Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,6 @@ Apollo 2.5.0
* [Fix: Bump h2database and snakeyaml version](https://github.com/apolloconfig/apollo/pull/5406)
* [Bugfix: Correct permission target format to appId+env+namespace/cluster](https://github.com/apolloconfig/apollo/pull/5407)
* [Security: Hide password when registering or modifying users](https://github.com/apolloconfig/apollo/pull/5414)
* [Fix: the logical judgment for configuration addition, deletion, and modification.](https://github.com/apolloconfig/apollo/pull/5432)
------------------
All issues and pull requests are [here](https://github.com/apolloconfig/apollo/milestone/16?closed=1)
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ public class ItemBO {
private ItemDTO item;
private boolean isModified;
private boolean isDeleted;
private boolean isNewlyAdded;
private String oldValue;
private String newValue;

Expand Down Expand Up @@ -65,5 +66,11 @@ public void setNewValue(String newValue) {
this.newValue = newValue;
}

public boolean isNewlyAdded() {
return isNewlyAdded;
}

}
public void setNewlyAdded(boolean newlyAdded) {
isNewlyAdded = newlyAdded;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -422,6 +422,7 @@ private ItemBO transformItem2BO(ItemDTO itemDTO, Map<String, String> releaseItem
//new item or modified
if (!StringUtils.isEmpty(key) && (!newValue.equals(oldValue))) {
itemBO.setModified(true);
itemBO.setNewlyAdded(!releaseItems.containsKey(key));
itemBO.setOldValue(oldValue == null ? "" : oldValue);
itemBO.setNewValue(newValue);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -348,11 +348,11 @@
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Namespace.Master.Items.Body.HaveGrayscale' | translate }}"
ng-click="namespace.displayControl.currentOperateBranch=namespace.branchName;namespace.branch.viewType='table'">{{'Component.Namespace.Master.Items.Body.Grayscale' | translate }}</span>
<span class="label label-success" ng-if="config.isModified && !config.oldValue"
<span class="label label-success" ng-if="config.isNewlyAdded"
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Namespace.Master.Items.Body.NewAddedTips' | translate }}">{{'Component.Namespace.Master.Items.Body.NewAdded' | translate }}</span>
<span class="label label-info"
ng-if="config.isModified && config.oldValue && !config.isDeleted"
ng-if="config.isModified && !config.isDeleted && !config.isNewlyAdded"
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Namespace.Master.Items.Body.ModifiedTips' | translate }}">{{'Component.Namespace.Master.Items.Body.Modified' | translate }}</span>
<span class="label label-danger" ng-if="config.isDeleted" data-tooltip="tooltip"
Expand Down Expand Up @@ -480,11 +480,11 @@
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Namespace.Master.Items.Body.HaveGrayscale' | translate }}"
ng-click="namespace.displayControl.currentOperateBranch=namespace.branchName;namespace.branch.viewType='table'">{{'Component.Namespace.Master.Items.Body.Grayscale' | translate }}</span>
<span class="label label-success" ng-if="config.isModified && !config.oldValue"
<span class="label label-success" ng-if="config.isNewlyAdded"
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Namespace.Master.Items.Body.NewAddedTips' | translate }}">{{'Component.Namespace.Master.Items.Body.NewAdded' | translate }}</span>
<span class="label label-info"
ng-if="config.isModified && config.oldValue && !config.isDeleted"
ng-if="config.isModified && !config.isDeleted && !config.isNewlyAdded"
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Namespace.Master.Items.Body.ModifiedTips' | translate }}">{{'Component.Namespace.Master.Items.Body.Modified' | translate }}</span>
<span class="label label-danger" ng-if="config.isDeleted" data-tooltip="tooltip"
Expand Down Expand Up @@ -727,11 +727,11 @@ <h5>{{'Component.Namespace.Master.Items.Body.Public.NoPublished' | translate }}<
ng-click="showText(config.item.key)">
<span ng-bind="config.item.key | limitTo: 250"></span>
<span ng-bind="config.item.key.length > 250 ? '...' :''"></span>
<span class="label label-success" ng-if="config.isModified && !config.oldValue"
<span class="label label-success" ng-if="config.isNewlyAdded"
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Namespace.Master.Items.Body.NewAddedTips' | translate }}">{{'Component.Namespace.Master.Items.Body.NewAdded' | translate }}</span>
<span class="label label-info"
ng-if="config.isModified && config.oldValue && !config.isDeleted"
ng-if="config.isModified && !config.isDeleted && !config.isNewlyAdded"
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Namespace.Master.Items.Body.ModifiedTips' | translate }}">{{'Component.Namespace.Master.Items.Body.Modified' | translate }}</span>
<span class="label label-danger" ng-if="config.isDeleted" data-tooltip="tooltip"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,11 +91,11 @@ <h4 class="modal-title" ng-show="toReleaseNamespace.isBranch && toReleaseNamespa
ng-if="config.item.key && config.isModified">
<td width="20%" title="{{config.item.key}}">
<span ng-bind="config.item.key"></span>
<span class="label label-success" ng-if="config.isModified && !config.oldValue"
<span class="label label-success" ng-if="config.isNewlyAdded"
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Publish.NewAddedTips' | translate }}">{{'Component.Publish.NewAdded' | translate }}</span>
<span class="label label-info"
ng-if="config.isModified && config.oldValue && !config.isDeleted"
ng-if="config.isModified && !config.isDeleted && !config.isNewlyAdded"
data-tooltip="tooltip" data-placement="bottom"
title="{{'Component.Publish.ModifiedTips' | translate }}">{{'Component.Publish.Modified' | translate }}</span>
<span class="label label-danger" ng-if="config.isDeleted" data-tooltip="tooltip"
Expand Down