17de38662SGunnar Mills<loader loading="loading"></loader>
2cd789508SIftekharul Islam<div id="configuration-date-time">
3cd789508SIftekharul Islam  <div class="row column">
4b7ea2790SGunnar Mills    <h1>Date and time settings</h1>
5cd789508SIftekharul Islam  </div>
6b7ea2790SGunnar Mills  <form class="time__form" role="form" action="">
77de38662SGunnar Mills    <div class="page-header">
877039a5eSGunnar Mills      <h2 class="bold h4">Set date and time manually or configure a Network Time Protocol (NTP) Server</h2>
97de38662SGunnar Mills    </div>
107de38662SGunnar Mills    <fieldset>
117de38662SGunnar Mills      <div class="column large-8">
12b7ea2790SGunnar Mills        <div class="row column">
13b7ea2790SGunnar Mills          <label class="control-radio" for="ntp-time">Obtain Automatically from a Network Time Protocol (NTP) Server
14*2f955bd8SGunnar Mills            <input type="radio" id="ntp-time" ng-model="time.mode" value="NTP">
15b7ea2790SGunnar Mills            <span class="control__indicator control__indicator-on"></span>
16b7ea2790SGunnar Mills          </label>
17b7ea2790SGunnar Mills        </div>
18b7ea2790SGunnar Mills        <div class="row column date-time__ntp-servers-wrap">
19b7ea2790SGunnar Mills          <fieldset class="date-time__ntp-servers" ng-repeat="server in ntp.servers track by $index">
209e397721SGunnar Mills            <label for="ntp-server{{$index+1}}">NTP Server Address {{$index+1}} <span ng-if="$first">(Primary)</span></label>
2190121f3fSGunnar Mills            <div class="inline">
22*2f955bd8SGunnar Mills              <input id="ntp-server{{$index+1}}" type="text" ng-readonly="time.mode != 'NTP'" ng-model="server" ng-blur="ntp.servers[$index] = server" set-focus-on-new-input/>
2390121f3fSGunnar Mills            </div>
2490121f3fSGunnar Mills            <button class="date-time__dns-remove inline" ng-click="removeNTPField($index)">Remove</button>
25b7ea2790SGunnar Mills          </fieldset>
2690121f3fSGunnar Mills        </div>
2790121f3fSGunnar Mills        <div class="row column date-time__ntp-servers-wrap">
2890121f3fSGunnar Mills          <button type="button" class="btn-primary block" ng-click="addNTPField()">Add new NTP server</button>
29b7ea2790SGunnar Mills        </div>
30b7ea2790SGunnar Mills        <div class="row column">
31b7ea2790SGunnar Mills          <label class="control-radio" for="manual-time">Manually set date and time
32*2f955bd8SGunnar Mills            <input type="radio" id="manual-time" ng-model="time.mode" value="Manual"/>
33b7ea2790SGunnar Mills            <span class="control__indicator control__indicator-on"></span>
34b7ea2790SGunnar Mills          </label>
35b7ea2790SGunnar Mills        </div>
367de38662SGunnar Mills        <ul class="date-time__metadata-wrapper">
377de38662SGunnar Mills          <li class="date-time__metadata-block">
38*2f955bd8SGunnar Mills            <p class="content-label">BMC <span ng-if="time.owner != 'Split'">and Host</span> Time</p>
39b7ea2790SGunnar Mills            <div class="inline">
40*2f955bd8SGunnar Mills              <input type="date" ng-model="bmc.date" ng-readonly="time.mode == 'NTP'" min="2018-01-01" max="2099-12-31"/>
41*2f955bd8SGunnar Mills              <input type="time" ng-model="bmc.date" ng-readonly="time.mode == 'NTP'" />
42b7ea2790SGunnar Mills              <p class="courier-bold">{{bmc.timezone}}</p>
43b7ea2790SGunnar Mills            </div>
447de38662SGunnar Mills          </li>
45*2f955bd8SGunnar Mills          <li class="date-time__metadata-block" ng-if="time.owner == 'Split'">
4683dcedf1SGunnar Mills            <p class="content-label">Host Time</p>
47b7ea2790SGunnar Mills            <div class="inline">
48b7ea2790SGunnar Mills              <!--- Ideally, would just use one input, datetime-local, but datetime-local is not supported on Firefox.--->
49b7ea2790SGunnar Mills              <input type="date" ng-model="host.date" min="2018-01-01" max="2099-12-31"/>
50b7ea2790SGunnar Mills              <input type="time" ng-model="host.date"/>
51b7ea2790SGunnar Mills              <p class="courier-bold">{{host.timezone}}</p>
52b7ea2790SGunnar Mills            </div>
5383dcedf1SGunnar Mills          </li>
54c74d434cSGunnar Mills          <li class="date-time__metadata-block">
55b7ea2790SGunnar Mills          <label class="content-label">Time Owner</label>
56*2f955bd8SGunnar Mills          <select ng-model="time.owner" class="date-time__owner-dropdown">
57*2f955bd8SGunnar Mills            <option class="courier-bold" ng-repeat="owner in timeOwners">{{owner}}</option>
58b7ea2790SGunnar Mills          </select>
59c74d434cSGunnar Mills          </li>
607de38662SGunnar Mills        </ul>
617de38662SGunnar Mills      </div>
627de38662SGunnar Mills    </fieldset>
63b7ea2790SGunnar Mills    <div class="time__submit-wrapper">
64b7ea2790SGunnar Mills      <button type="button" class="btn-primary inline" ng-click="setTime()">Save settings</button>
65b7ea2790SGunnar Mills      <button type="button" class="btn-secondary inline" ng-click="refresh()">Cancel</button>
66b7ea2790SGunnar Mills    </div>
67*2f955bd8SGunnar Mills    <p class="success-msg" ng-show="success" role="alert">Success! Time changed!</p>
68*2f955bd8SGunnar Mills    <p class="set_time_error error-msg" ng-show="error" role="alert">Error setting time!</p>
69b7ea2790SGunnar Mills  </form>
70cd789508SIftekharul Islam</div>
71