mirror of
https://github.com/haiwen/seahub.git
synced 2025-09-06 01:12:03 +00:00
@@ -155,15 +155,17 @@ define([
|
||||
|
||||
$('[name="email"]', $form).select2($.extend(
|
||||
Common.contactInputOptionsForSelect2(), {
|
||||
width: '280px'
|
||||
width: '275px',
|
||||
containerCss: {'margin-bottom': '5px'},
|
||||
placeholder: gettext("Search users or enter emails and press Enter")
|
||||
}));
|
||||
|
||||
$form.submit(function() {
|
||||
var emails = $('[name="email"]', $form).val();
|
||||
var emails = $.trim($('[name="email"]', $form).val());
|
||||
var $error = $('.error', $form);
|
||||
var $submitBtn = $('[type="submit"]', $form);
|
||||
|
||||
if (!emails.length) {
|
||||
if (!emails) {
|
||||
$error.html(gettext("It is required.")).show();
|
||||
return false;
|
||||
}
|
||||
@@ -178,7 +180,7 @@ define([
|
||||
}),
|
||||
type: 'POST',
|
||||
dataType: 'json',
|
||||
data: {'email': emails},
|
||||
data: {'email': emails.split(',')},
|
||||
traditional: true,
|
||||
beforeSend: Common.prepareCSRFToken,
|
||||
success: function(data) {
|
||||
|
Reference in New Issue
Block a user