updating a security thing
This commit is contained in:
@@ -20,7 +20,7 @@ namespace Swarmops.Frontend.Automation
|
||||
|
||||
People matches = People.FromSingle(Person.FromIdentity(Int32.Parse(personId)));
|
||||
|
||||
matches = Authorization.FilterPeopleToMatchAuthority(matches, CurrentUser.GetAuthority());
|
||||
matches = matches.GetVisiblePeopleByAuthority(CurrentUser.GetAuthority());
|
||||
|
||||
if (matches.Count == 1) // still allowed
|
||||
{
|
||||
|
||||
@@ -21,11 +21,11 @@ namespace Swarmops.Frontend.Automation
|
||||
|
||||
People matches = People.FromNamePattern(pattern);
|
||||
|
||||
matches = Authorization.FilterPeopleToMatchAuthority(matches, CurrentUser.GetAuthority());
|
||||
matches = matches.GetVisiblePeopleByAuthority(CurrentUser.GetAuthority());
|
||||
|
||||
if (matches.Count > 20)
|
||||
if (matches.Count > 10)
|
||||
{
|
||||
matches.RemoveRange(20, matches.Count - 20);
|
||||
matches.RemoveRange(10, matches.Count - 10);
|
||||
}
|
||||
|
||||
List<string> jsonPeople = new List<string>();
|
||||
|
||||
@@ -60,8 +60,8 @@
|
||||
|
||||
var autoCompleteLoader = function(param,success,error){
|
||||
var q = param.q || '';
|
||||
if (q.length <= 3) {
|
||||
return false;
|
||||
if (q.length < 3) {
|
||||
success (null);
|
||||
}
|
||||
$.ajax({
|
||||
url: '/Automation/Json-SearchPeoplePattern.aspx',
|
||||
@@ -71,7 +71,6 @@
|
||||
namePattern: q
|
||||
},
|
||||
success: function(data){
|
||||
console.log(data);
|
||||
success(data);
|
||||
},
|
||||
error: function(){
|
||||
|
||||
Reference in New Issue
Block a user