mirror of https://github.com/apache/archiva.git
display error message if admin user not exists
git-svn-id: https://svn.apache.org/repos/asf/archiva/trunk@1386691 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
b07cc37a20
commit
7d266951b7
|
@ -460,3 +460,8 @@ report.health.result.name=Name
|
|||
report.health.result.problem=Problem
|
||||
report.health.result.message=Message
|
||||
report.result.title=Result
|
||||
|
||||
admin.creation.mandatory=You must create the admin user!
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -644,6 +644,7 @@ function(jquery,ui,sammy,tmpl) {
|
|||
dataType: 'json',
|
||||
success: function(data) {
|
||||
var adminExists = data;
|
||||
window.archivaModel.adminExists=adminExists;
|
||||
var createAdminLink=$("#create-admin-link");
|
||||
if (adminExists == false) {
|
||||
createAdminLink.show();
|
||||
|
|
|
@ -123,6 +123,10 @@ require(["jquery","jquery.tmpl","i18n"], function(jquery,jqueryTmpl,i18n) {
|
|||
mainContent.removeAttr("data-bind");
|
||||
$("#body_content" ).find(".popover" ).hide();
|
||||
clearUserMessages();
|
||||
if(window.archivaModel.adminExists==false){
|
||||
displayErrorMessage($.i18n.prop("admin.creation.mandatory"));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -277,6 +277,7 @@ define("redback.user",["jquery","utils","i18n","jquery.validate","knockout","kno
|
|||
dataType: 'json',
|
||||
success: function(data) {
|
||||
var adminExists = data;
|
||||
window.archivaModel.adminExists=adminExists;
|
||||
if (adminExists == false) {
|
||||
|
||||
window.redbackModel.createUser=true;
|
||||
|
|
Loading…
Reference in New Issue