Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
HTML
<STYLE TYPE='text/css'>
#loading
    {
    display:none;
    left: 20%;
    position: absolute;
    top: 25%;
    width: 100%;
    z-index: 1000;
    }
  
    #loadingcontent
    {
    height: 60%;
    left: 50%;
    top: 50%;
    width: 60%;
    }
  
    #loadingspinner
    {
    top: 50%;
    width: 30%;
 }
</STYLE>
<script src='http://ajax.googleapis.com/ajax/libs/jquery/1.7.1/jquery.min.js'></script> 
<div id="loading">
<div id="loadingcontent">
<span id='loadingspinner' class='aui-icon aui-icon-wait'>Loading...</span>
</div>
</div>

<div id='feedback-main-div' style='font-size: 14px; font-family: Arial,Helvetica,FreeSans,sans-serif'>
<div id='feedback-error'></div>

<form class="aui" enctype='multipart/form-data' id='feedback-form' name='feedback-form' target='feedback-response' method='post' action='https://jira.teamlead.ru/plugins/servlet/feedback/create'>

<input type='hidden' name='form-index' id='form-index' value='1'/>

 
<div>
<select id='feedback-issue-type' data-placeholder="Тип обращения..." name='feedback-issue-type'>
<option value='25' selected >Покупка продуктов или услуг</option>
<option value='10'>Техническая консультация</option>
<option value='27'>Ошибка в работе приложения</option>
<option value='1'>Сбой всей системы</option>
<option value='4'>Улучшение или Идея</option>
<option value='25'>Сотрудничество с нами</option>
<option value='25'>Вопрос в бухгалтерию</option>
    </select>
<script>
AJS.$("#feedback-issue-type").auiSelect2();
</script>
</div>
 
 
<br> <div><input class="text long-field" type='text' id='feedback-summary' name='feedback-summary' class='feedback-summary' placeholder='Тема обращения' value=''/></div>
<br> <div style='display:none;'><input type='text' id='feedback-language' name='feedback-language' class='feedback-language' placeholder='Выберите язык (en/ru)' value='ru'/></div>

<div><TEXTAREA class="textarea long-field" id='feedback-body' name='feedback-body' ROWS='5' placeholder='Тут можно указать подробности...'></TEXTAREA>
</div>

<br>
<div>
<select id="feedback-fix-version" multiple data-placeholder="Выберите продукты..." name='feedback-fix-version'>
<option value='13020'>JIRA</option>
<option value='13021'>Confluence</option>
<option value='21821'>CRM for JIRA</option>
<option value='22120'>JIRA Service Desk</option>
<option value='13027'>JIRA Agile</option>
<option value='21228'>Stash</option>
<option value='13025'>Bamboo</option>
<option value='13024'>Crucible</option>
<option value='13023'>FishEye</option>
<option value='13022'>Crowd</option>
<option value='16920'>Bitbucket</option>
<option value='19729'>Feedback for JIRA</option>
<option value='21820'>Werewolf forJIRA</option>
<option value='21822'>Calendar for JIRA</option>
<option value='23320'>Tempo Timesheet</option>
<option value='13029'>Team Calendars for Confluence</option>
<option value='13028'>Capture for JIRA</option>
<option value='23922'>Questions for Confluence</option>
<option value='19723'>Локализация JIRA</option>
<option value='19724'>Локализация Confluence</option>
<option value='19726'>Локализация Agile</option>
<option value='19727'>Локализация Tempo</option>
<option value='21920'>Локализация JIRA Service Desk</option>
    </select>
<script>
AJS.$("#feedback-fix-version").auiSelect2();
</script>
 
</div>
<br>
<div>
<input class="text" type='text' id='feedback-email' name='feedback-email' placeholder='E-mail для ответа' size='38' value=''/>
</div>
<br>
<div>
<input class="text" type='file' id='feedback-attachment' name='feedback-attachment' size='38' />
</div>
<br>
<div align="left"> 
<input class="aui-button aui-button-primary" type='button' value=' Отправить ' onclick='addFeedback()'/>
</div>
</form>
</div>
 
<iframe id='feedback-response' name='feedback-response' frameborder='no' style='display: none;' width='500' height='250'></iframe>
 
<script type='text/javascript'>
jQuery(window).load(function()
{
   jQuery('#feedback-main-div').show();
   jQuery('#feedback-new-issue-div').hide();
   jQuery('#feedback-response').hide();
   jQuery('#feedback-new-issue-button').click(function ()
   {
    jQuery('#feedback-form')[0].reset();
    jQuery('#feedback-main-div').show();
    jQuery('#feedback-new-issue-div').hide();
    jQuery('#feedback-response').hide();
   });
});

function addFeedback() {
if ( document.getElementById('feedback-attachment').files.length > 0 )
{
var attachSize = document.getElementById('feedback-attachment').files[0].size; 
if ( attachSize > 1000000 * 10 )
{ var message = message + '<div>Attachment size exceeds the allowable limit</div>'; jQuery('#feedback-error').html(message); return false; }}
   var summary = jQuery('#feedback-summary').val();
   var email = jQuery('#feedback-email').val();
   if (summary == '' || email == '')
   {
    var message = '';
    if (summary == '')
    {
     message = message + '<div>Введите тему обращения</div>';
    }
    if (email == '')
    {
     message = message + '<div>Введите E-mail для ответа</div>';
    }
    jQuery('#feedback-error').html(message);
    return false;
}
   jQuery('#feedback-error').html('');
   jQuery('#feedback-main-div').hide();
   jQuery('#loading').fadeIn();
   jQuery('#feedback-response').show();
   jQuery('#feedback-form').submit();
   jQuery('#feedback-response').on("load", function() {
   jQuery('#feedback-new-issue-div').show();
   jQuery('#loading').fadeOut();
}); 
   return false;
}
</script>