Commit 4c0a7548 authored by lepdou's avatar lepdou

update

parent ce97c549
...@@ -16,21 +16,19 @@ import java.util.List; ...@@ -16,21 +16,19 @@ import java.util.List;
@RestController @RestController
public class CommitController { public class CommitController {
private final static int COMMIT_HISTORY_PAGE_SIZE = 10;
@Autowired @Autowired
private CommitService commitService; private CommitService commitService;
@RequestMapping(value = "/apps/{appId}/envs/{env}/clusters/{clusterName}/namespaces/{namespaceName}/commits") @RequestMapping(value = "/apps/{appId}/envs/{env}/clusters/{clusterName}/namespaces/{namespaceName}/commits")
public List<CommitDTO> find(@PathVariable String appId, @PathVariable String env, public List<CommitDTO> find(@PathVariable String appId, @PathVariable String env,
@PathVariable String clusterName, @PathVariable String namespaceName, @PathVariable String clusterName, @PathVariable String namespaceName,
@RequestParam int page){ @RequestParam(defaultValue = "0") int page, @RequestParam(defaultValue = "10") int size){
if (page < 0){ if (page < 0){
page = 0; page = 0;
} }
return commitService.find(appId, Env.valueOf(env), clusterName, namespaceName, page, COMMIT_HISTORY_PAGE_SIZE); return commitService.find(appId, Env.valueOf(env), clusterName, namespaceName, page, size);
} }
......
...@@ -234,7 +234,7 @@ ...@@ -234,7 +234,7 @@
Key Key
</th> </th>
<th> <th>
value Value
</th> </th>
<th> <th>
备注 备注
...@@ -540,7 +540,7 @@ ...@@ -540,7 +540,7 @@
</label> </label>
<div class="col-sm-10"> <div class="col-sm-10">
<textarea type="text" class="form-control" rows="6" ng-model="item.value" <textarea type="text" class="form-control" rows="6" ng-model="item.value"
ng-required="true" ng-show="tableViewOperType != 'retrieve'"> ng-show="tableViewOperType != 'retrieve'">
</textarea> </textarea>
<p ng-bind="item.value" ng-show="tableViewOperType == 'retrieve'"></p> <p ng-bind="item.value" ng-show="tableViewOperType == 'retrieve'"></p>
</div> </div>
......
...@@ -110,7 +110,7 @@ application_module.controller("ConfigNamespaceController", ...@@ -110,7 +110,7 @@ application_module.controller("ConfigNamespaceController",
} }
namespace.commitPage += 1; namespace.commitPage += 1;
}, function (result) { }, function (result) {
toastr.error(AppUtil.errorMsg(result), "加载提交历史记录出错"); toastr.error(AppUtil.errorMsg(result), "加载修改历史记录出错");
}); });
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment