mirror of
https://github.com/ONLYOFFICE/server.git
synced 2026-04-07 14:04:35 +08:00
[info] Add license start date info; For bug 71491
This commit is contained in:
@ -210,17 +210,17 @@
|
||||
</tr>
|
||||
<tr>
|
||||
<td id="build-type">Type:</td>
|
||||
<td><span id="lic-valid-type">Valid: </span><span id="lic-valid"></span></td>
|
||||
<td><span>Start date: </span><span id="lic-start"></span></td>
|
||||
<td id="lic-limit-edit"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td id="build-version">Version:</td>
|
||||
<td id="trial"></td>
|
||||
<td><span id="lic-valid-type">Valid: </span><span id="lic-valid"></span></td>
|
||||
<td id="lic-limit-view"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td id="build-date">Release date:</td>
|
||||
<td></td>
|
||||
<td id="trial"></td>
|
||||
<td></td>
|
||||
</tr>
|
||||
</table>
|
||||
@ -321,11 +321,19 @@
|
||||
var licType = licenseInfo.type;
|
||||
elem = document.getElementById('lic-valid');
|
||||
elem.innerText = licdate.toLocaleDateString();
|
||||
var isInvalid = 2 === licType || 1 === licType || 6 === licType || 16 === licType || 11 === licType;
|
||||
var isInvalid = 2 === licType || 1 === licType || 6 === licType || 11 === licType;
|
||||
var isUpdateUnavailible = !isLimited && new Date(serverInfo.date) > licdate;
|
||||
if (isInvalid || isUpdateUnavailible) {
|
||||
elem.classList.add('critical');
|
||||
}
|
||||
if (licenseInfo.startDate) {
|
||||
var licdateStart = new Date(licenseInfo.startDate);
|
||||
elem = document.getElementById('lic-start');
|
||||
elem.innerText = licdateStart.toLocaleDateString();
|
||||
if (16 === licType || licdateStart > new Date()) {
|
||||
elem.classList.add('critical');
|
||||
}
|
||||
}
|
||||
|
||||
elem = document.getElementById('trial');
|
||||
elem.innerText = (licenseInfo.mode & 1) ? 'Trial' : '';
|
||||
|
||||
Reference in New Issue
Block a user