<commit_before><%--
  ~ Copyright 2000-2014 JetBrains s.r.o.
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~ http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License.
  --%>

<%@ include file="/include.jsp" %>

<bs:linkCSS dynamic="${true}">
  /css/admin/adminMain.css
  /css/admin/serverConfig.css
  /plugins/vso-rooms/css/editSettings.css
</bs:linkCSS>
<bs:linkScript>
  /js/bs/testConnection.js
  /plugins/vso-rooms/js/editSettings.js
</bs:linkScript>

<jsp:useBean id="vsoRoomsSettings" scope="request" type="jetbrains.buildServer.vsoRooms.controllers.VSONotificatorSettingsBean"/>

<script type="text/javascript">
  document.observe("dom:loaded", function() {
    VSOTeamRooms.SettingsForm.setupEventHandlers();
    $('account').focus();
  });
</script>

<c:url value="/vso/notificatorSettings.html?edit=1" var="url"/>

<div id="settingsContainer">
  <form action="${url}" method="post" onsubmit="return VSOTeamRooms.SettingsForm.submitSettings()" autocomplete="off">
    <div class="editNotificatorSettingsPage">
      <c:choose>
        <c:when test="${vsoRoomsSettings.paused}">
          <div class="pauseNote" style="margin-bottom: 1em;">
            The notifier is <strong>disabled</strong>. All team room messages are suspended&nbsp;&nbsp;<a class="btn btn_mini" href="#" id="enable-btn">Enable</a>
          </div>
        </c:when>
        <c:otherwise>
          <div style="margin-left: 0.6em;">
            The notifier is <strong>enabled</strong>&nbsp;&nbsp;<a class="btn btn_mini" href="#" id="disable-btn">Disable</a>
          </div>
        </c:otherwise>
      </c:choose>

      <bs:messages key="settingsSaved"/>

      <table class="runnerFormTable">
        <tr>
          <th><label for="account">Account: <l:star/></label></th>
          <td>
            <forms:textField name="account" value="${vsoRoomsSettings.account}"/>
            <span class="error" id="errorAccount"></span>
          </td>
        </tr>
        <tr>
          <th><label for="username">Username: <l:star/></label></th>
          <td>
            <forms:textField name="username" value="${vsoRoomsSettings.username}"/>
            <span class="error" id="errorUsername"></span>
          </td>
        </tr>
        <tr>
          <th><label for="password">Password: <l:star/></label></th>
          <td>
            <forms:passwordField name="password" encryptedPassword="${<PASSWORD>}"/>
            <span class="error" id="errorPassword"></span><commit_msg>notifier settings page cosmetics - .visualstudio.com accoun postfix added - link to customize message templates online doc added<commit_after><%--
  ~ Copyright 2000-2014 JetBrains s.r.o.
  ~
  ~ Licensed under the Apache License, Version 2.0 (the "License");
  ~ you may not use this file except in compliance with the License.
  ~ You may obtain a copy of the License at
  ~
  ~ http://www.apache.org/licenses/LICENSE-2.0
  ~
  ~ Unless required by applicable law or agreed to in writing, software
  ~ distributed under the License is distributed on an "AS IS" BASIS,
  ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  ~ See the License for the specific language governing permissions and
  ~ limitations under the License.
  --%>

<%@ include file="/include.jsp" %>

<bs:linkCSS dynamic="${true}">
  /css/admin/adminMain.css
  /css/admin/serverConfig.css
  /plugins/vso-rooms/css/editSettings.css
</bs:linkCSS>
<bs:linkScript>
  /js/bs/testConnection.js
  /plugins/vso-rooms/js/editSettings.js
</bs:linkScript>

<jsp:useBean id="vsoRoomsSettings" scope="request" type="jetbrains.buildServer.vsoRooms.controllers.VSONotificatorSettingsBean"/>

<script type="text/javascript">
  document.observe("dom:loaded", function() {
    VSOTeamRooms.SettingsForm.setupEventHandlers();
    $('account').focus();
  });
</script>

<c:url value="/vso/notificatorSettings.html?edit=1" var="url"/>

<div id="settingsContainer">
  <form action="${url}" method="post" onsubmit="return VSOTeamRooms.SettingsForm.submitSettings()" autocomplete="off">
    <div class="editNotificatorSettingsPage">
      <c:choose>
        <c:when test="${vsoRoomsSettings.paused}">
          <div class="pauseNote" style="margin-bottom: 1em;">
            The notifier is <strong>disabled</strong>. All team room messages are suspended&nbsp;&nbsp;<a class="btn btn_mini" href="#" id="enable-btn">Enable</a>
          </div>
        </c:when>
        <c:otherwise>
          <div style="margin-left: 0.6em;">
            The notifier is <strong>enabled</strong>&nbsp;&nbsp;<a class="btn btn_mini" href="#" id="disable-btn">Disable</a>
          </div>
        </c:otherwise>
      </c:choose>

      <bs:messages key="settingsSaved"/>

      <table class="runnerFormTable">
        <tr>
          <th><label for="account">Account: <l:star/></label></th>
          <td>
            <forms:textField name="account" value="${vsoRoomsSettings.account}" /> .VISUALSTUDIO.COM
            <span class="error" id="errorAccount"></span>
          </td>
        </tr>
        <tr>
          <th><label for="username">Username: <l:star/></label></th>
          <td>
            <forms:textField name="username" value="${vsoRoomsSettings.username}"/>
            <span class="error" id="errorUsername"></span>
          </td>
        </tr>
        <tr>
          <th><label for="password">Password: <l:star/></label></th>
          <td>
            <forms:passwordField name="password" encryptedPassword="${vsoRoomsSettings.encryptedPassword}"/>
            <span class="error" id="errorPassword"></span>
          </td>
        </tr>
        <tr class="noBorder">
          <td colspan="2">
            The templates for Visual Studio Online notifications
            <a target="_blank" href="<bs:helpUrlPrefix/>/Customizing+Notifications" showdiscardchangesmessage="false">can be customized</a>.
{'fraction_non_alphanumeric': 0.15743532772575783, 'fraction_numerical': 0.005237263926360895, 'mean_word_length': 3.2013333333333334, 'pattern_counts': {'":': 0, '<': 145, '<?xml version=': 0, '>': 145, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3830086', 'n_tokens_mistral': 1961, 'n_tokens_neox': 1890, 'n_words': 430}