blob: 6e1e24dd390d8fec664ac3d39eb5173fde55e705 [file] [log] [blame]
Gunnar Mills7de38662018-07-18 13:01:48 -05001<loader loading="loading"></loader>
Iftekharul Islamcd789502017-04-19 14:37:55 -05002<div id="configuration-date-time">
beccabroekedf1ab42019-02-15 16:26:38 -06003 <h1>Date and time settings</h1>
4 <div class="column small-12 page-header">
5 <h2>Set date and time manually or configure a Network Time Protocol (NTP) Server</h2>
Gunnar Mills5f0b7762018-09-25 14:10:45 -05006 </div>
7 <form class="time__form" role="form" action="">
Gunnar Mills5f0b7762018-09-25 14:10:45 -05008 <fieldset>
9 <div class="column large-8">
10 <div class="row column">
11 <label class="control-radio" for="ntp-time">Obtain Automatically from a Network Time Protocol (NTP) Server
Gunnar Mills2f955bd2018-10-13 16:56:10 -050012 <input type="radio" id="ntp-time" ng-model="time.mode" value="NTP">
Gunnar Mills5f0b7762018-09-25 14:10:45 -050013 <span class="control__indicator control__indicator-on"></span>
14 </label>
15 </div>
16 <div class="row column date-time__ntp-servers-wrap">
17 <fieldset class="date-time__ntp-servers" ng-repeat="server in ntp.servers track by $index">
Gunnar Mills9e397722018-09-21 10:59:50 -050018 <label for="ntp-server{{$index+1}}">NTP Server Address {{$index+1}} <span ng-if="$first">(Primary)</span></label>
Gunnar Mills5f0b7762018-09-25 14:10:45 -050019 <div class="inline">
Gunnar Mills2f955bd2018-10-13 16:56:10 -050020 <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/>
Gunnar Mills5f0b7762018-09-25 14:10:45 -050021 </div>
22 <button class="date-time__dns-remove inline" ng-click="removeNTPField($index)">Remove</button>
23 </fieldset>
24 </div>
25 <div class="row column date-time__ntp-servers-wrap">
26 <button type="button" class="btn-primary block" ng-click="addNTPField()">Add new NTP server</button>
27 </div>
28 <div class="row column">
29 <label class="control-radio" for="manual-time">Manually set date and time
Gunnar Mills2f955bd2018-10-13 16:56:10 -050030 <input type="radio" id="manual-time" ng-model="time.mode" value="Manual"/>
Gunnar Mills5f0b7762018-09-25 14:10:45 -050031 <span class="control__indicator control__indicator-on"></span>
32 </label>
33 </div>
34 <ul class="date-time__metadata-wrapper">
35 <li class="date-time__metadata-block">
Gunnar Mills2f955bd2018-10-13 16:56:10 -050036 <p class="content-label">BMC <span ng-if="time.owner != 'Split'">and Host</span> Time</p>
Gunnar Mills5f0b7762018-09-25 14:10:45 -050037 <div class="inline">
Gunnar Mills2f955bd2018-10-13 16:56:10 -050038 <input type="date" ng-model="bmc.date" ng-readonly="time.mode == 'NTP'" min="2018-01-01" max="2099-12-31"/>
39 <input type="time" ng-model="bmc.date" ng-readonly="time.mode == 'NTP'" />
Gunnar Mills5f0b7762018-09-25 14:10:45 -050040 <p class="courier-bold">{{bmc.timezone}}</p>
41 </div>
42 </li>
Gunnar Mills2f955bd2018-10-13 16:56:10 -050043 <li class="date-time__metadata-block" ng-if="time.owner == 'Split'">
Gunnar Mills5f0b7762018-09-25 14:10:45 -050044 <p class="content-label">Host Time</p>
45 <div class="inline">
46 <!--- Ideally, would just use one input, datetime-local, but datetime-local is not supported on Firefox.--->
47 <input type="date" ng-model="host.date" min="2018-01-01" max="2099-12-31"/>
48 <input type="time" ng-model="host.date"/>
49 <p class="courier-bold">{{host.timezone}}</p>
50 </div>
51 </li>
52 <li class="date-time__metadata-block">
53 <label class="content-label">Time Owner</label>
Gunnar Mills2f955bd2018-10-13 16:56:10 -050054 <select ng-model="time.owner" class="date-time__owner-dropdown">
55 <option class="courier-bold" ng-repeat="owner in timeOwners">{{owner}}</option>
Gunnar Mills5f0b7762018-09-25 14:10:45 -050056 </select>
57 </li>
58 </ul>
59 </div>
60 </fieldset>
61 <div class="time__submit-wrapper">
62 <button type="button" class="btn-primary inline" ng-click="setTime()">Save settings</button>
63 <button type="button" class="btn-secondary inline" ng-click="refresh()">Cancel</button>
64 </div>
Gunnar Mills5f0b7762018-09-25 14:10:45 -050065 </form>
Gunnar Mills7de38662018-07-18 13:01:48 -050066</div>