Skip to content

Commit

Permalink
feature(single-lifetime-license-support)
Browse files Browse the repository at this point in the history
  • Loading branch information
leonvandebroek committed Mar 14, 2024
1 parent 1d7b399 commit d9fb170
Show file tree
Hide file tree
Showing 128 changed files with 15,629 additions and 49 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,3 +10,4 @@ node_modules/
/js/retentionAssistant.js*
/js/settings.js*
/js/termsAgreement.js*
/certificates
18 changes: 16 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -243,10 +243,24 @@
### Fix
- Fixes issue where upon updating the snippet-settings are reset.

## 3.0.0 - 2024-02-17
## 3.0.0 - 2024-02-25
### Features
- More insight into your subscription information for the configured license key(s)
- View product- and productlevel that are supported within your subscription
- Enhanced status display for your subscription
- App no longer requires entering a new licensekey when your subscription renewes. The latest licensekey is automatically fetched based on the initial licensekey that is configured.
- Support for the upcoming new Sendent products
- Support for the upcoming new Sendent products

## 3.0.1 - 2024-02-26
### Bugfix
- Minor bugfix after release.

## 3.0.3 - 2024-02-27
### Bugfix
- Minor bugfix to fix issues where the "Outlook Add-in version information" block would not work properly.

## 3.0.4 - 2024-03-09
### Bugfix
- Minor bugfix to fix issues where the "Outlook Add-in version information" block would not work properly.
- Fix for license status not being shown properly for some users.
- Fix for darkmode compatibility.
16 changes: 8 additions & 8 deletions appinfo/info.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
<name>Sendent</name>
<summary lang="en">Sendent allows you to securely exchange files and emails</summary>
<description lang="en">Sendent now securely exchanges files and emails, integrating with both Microsoft Outlook and Microsoft Teams. This enhanced capability allows users to seamlessly conduct their work, not only within their preferred email environment but also within the collaborative framework of Microsoft Teams. Whether sharing privacy-sensitive documents, content, or handling attachments that exceed standard email size constraints, Sendent ensures a streamlined and secure communication experience. All files are directed to your Nextcloud instance, empowering you to control and manage access permissions effectively.</description>
<version>3.0.0</version>
<licence>agplv3</licence>
<author mail="support@sendent.nl" homepage="https://www.sendent.nl">Sendent B.V.</author>
<version>3.0.4</version>
<licence>agpl</licence>
<author mail="support@sendent.com" homepage="https://www.sendent.com">Sendent B.V.</author>
<namespace>Sendent</namespace>

<category>integration</category>
Expand All @@ -15,11 +15,11 @@
<website>https://www.sendent.com</website>
<bugs>https://sendent.com/resources/support</bugs>
<repository>https://github.com/Sendent-B-V/Sendent-App-for-Nextcloud.git</repository>
<screenshot>https://download.sendent.nl/serverapp/1.0.0/sendentbanner.png</screenshot>
<screenshot>https://download.sendent.nl/serverapp/1.0.0/sharefilesuploading.png</screenshot>
<screenshot>https://download.sendent.nl/serverapp/1.0.0/sharefilesfiles.png</screenshot>
<screenshot>https://download.sendent.nl/serverapp/1.0.0/publicshare.png</screenshot>
<screenshot>https://download.sendent.nl/serverapp/1.0.0/publicsharedate.png</screenshot>
<screenshot>https://download.sendent.com/serverapp/1.0.0/sendentbanner.png</screenshot>
<screenshot>https://download.sendent.com/serverapp/1.0.0/sharefilesuploading.png</screenshot>
<screenshot>https://download.sendent.com/serverapp/1.0.0/sharefilesfiles.png</screenshot>
<screenshot>https://download.sendent.com/serverapp/1.0.0/publicshare.png</screenshot>
<screenshot>https://download.sendent.com/serverapp/1.0.0/publicsharedate.png</screenshot>

<dependencies>
<nextcloud min-version="25" max-version="28"/>
Expand Down
20 changes: 15 additions & 5 deletions css/style.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,18 @@


#hello {
color: red;
}
.badge {
background-color: darkblue;
color: white;
padding: 0px 4px 0px 4px;
margin-left:5px;
text-align: center;
height:24px;
font-size:10px;
border-radius: 5px;
}
.personal-settings-setting-box, .license-settings-setting-box, .dependency-settings-setting-box{
position:relative;
}
Expand Down Expand Up @@ -76,7 +88,6 @@
display: inline-flex;
font-size:medium;
border-radius: var(--border-radius-large) var(--border-radius-large) 0px 0px;
background: white;
min-width: 110px !important;
max-width: 220px;
min-height: 40px;
Expand All @@ -88,9 +99,8 @@
display: inline-flex;
font-weight: bold;
font-size:medium;
border-bottom: 1px solid black;
border-bottom: 2px solid blue;
border-radius: var(--border-radius-large) var(--border-radius-large) 0px 0px;
background: whitesmoke;
min-width: 110px !important;
max-width: 220px;
min-height: 40px;
Expand Down Expand Up @@ -180,13 +190,13 @@ label{
grid-column-end:e;
}
.errorStatus{
color:darkred;
color:red;
}
.warningStatus{
color:darkorange;
}
.okStatus{
color:darkblue;
color:green;
}
.licensekeyvalueinput {
line-height: 40px;
Expand Down
20 changes: 11 additions & 9 deletions lib/Controller/LicenseApiController.php
Original file line number Diff line number Diff line change
Expand Up @@ -198,6 +198,7 @@ public function showForNCGroup(string $ncgroup = ''): DataResponse {
$level = $result[0]->getLevel();
$group = $result[0]->getNcgroup();
$product = $result[0]->getProduct();
$istrial = $result[0]->getIstrial();
$statusKind = "";
$status = "";

Expand Down Expand Up @@ -255,31 +256,32 @@ public function showForNCGroup(string $ncgroup = ''): DataResponse {
$status = $this->l->t("Current amount of active users exceeds licensed amount. Additional users trying to use Sendent will be prevented from doing so.");
$statusKind = "userlimit";
}
return new DataResponse(new LicenseStatus($status, $statusKind, $level,$licensekey, $dateExpiration, $dateLastCheck, $email, $group));
return new DataResponse(new LicenseStatus($status, $statusKind, $level,$licensekey, $dateExpiration, $dateLastCheck, $email, $istrial, $group));
}
elseif (count($result) > 0 && $result[0]->getLevel() == "Error_incomplete") {
$email = $result[0]->getEmail();
$licensekey = $result[0]->getLicensekey();
$group = $result[0]->getNcgroup();
$status = $this->l->t('Missing (or incorrect) email address or license key. %1$sContact support%2$s to get your correct license information.', ["<a href='mailto:[email protected]' style='color:blue'>", "</a>"]);
return new DataResponse(new LicenseStatus($status, "error_incomplete" ,"-", $licensekey, "-", "-", $email, $group));
return new DataResponse(new LicenseStatus($status, "error_incomplete" ,"-", $licensekey, "-", "-", $email, "-", 0, $group));
}
elseif (count($result) > 0 && $result[0]->getLevel() == License::ERROR_VALIDATING) {
$email = $result[0]->getEmail();
$licensekey = $result[0]->getLicensekey();
$group = $result[0]->getNcgroup();
return new DataResponse(new LicenseStatus($this->l->t("Cannot verify your license. Please make sure your licensekey and email address are correct before you try to 'Activate license'."), "error_validating","-", $licensekey, "-", "-", $email, $group));
$istrial = $result[0]->getIstrial();
return new DataResponse(new LicenseStatus($this->l->t("Cannot verify your license. Please make sure your licensekey and email address are correct before you try to 'Activate license'."), "error_validating","-", $licensekey, "-", "-", $email, "-", $istrial, $group));
}
else {
return new DataResponse(new LicenseStatus($this->l->t("No license configured"), "nolicense" ,"-", "-", "-", "-", "-"));
return new DataResponse(new LicenseStatus($this->l->t("No license configured"), "nolicense" ,"-", "-", "-", "-", "-", "-", 0,"-"));
}
}
else {
return new DataResponse(new LicenseStatus($this->l->t("No license configured"), "nolicense" ,"-", "-", "-", "-", "-"));
return new DataResponse(new LicenseStatus($this->l->t("No license configured"), "nolicense" ,"-", "-", "-", "-", "-", "-", 0, "-"));
}
} catch (Exception $e) {
$this->logger->error('Cannot verify license');
return new DataResponse(new LicenseStatus($this->l->t("Cannot verify your license. Please make sure your licensekey and email address are correct before you try to 'Activate license'."), "fatal" ,"-", "-", "-", "-", "-"));
return new DataResponse(new LicenseStatus($this->l->t("Cannot verify your license. Please make sure your licensekey and email address are correct before you try to 'Activate license'."), "fatal" ,"-", "-", "-", "-","-","-", 0, $ncgroup));
}
}
/**
Expand Down Expand Up @@ -407,7 +409,7 @@ public function showForNCGroupInternal(string $ncgroup = ''): DataResponse {
$product = $result[0]->getProduct();
$istrial = $result[0]->getIstrial();
$status = $this->l->t('Missing (or incorrect) email address or license key. %1$sContact support%2$s to get your correct license information.', ["<a href='mailto:[email protected]' style='color:blue'>", "</a>"]);
return new DataResponse(new LicenseStatus($status, "error_incomplete" ,"-", $licensekey, "-", "-", $email, "-", "-", $group));
return new DataResponse(new LicenseStatus($status, "error_incomplete" ,"-", $licensekey, "-", "-", $email, "-", 0, $group));
}
elseif (count($result) > 0 && $result[0]->getLevel() == License::ERROR_VALIDATING) {
$email = $result[0]->getEmail();
Expand All @@ -422,11 +424,11 @@ public function showForNCGroupInternal(string $ncgroup = ''): DataResponse {
return new DataResponse(new LicenseStatus($this->l->t("Cannot verify your license. Please make sure your licensekey and email address are correct before you try to 'Activate license'."), "error_validating",$level, $licensekey, $dateExpiration, $dateLastCheck, $email, $product, $istrial, $group));
}
else {
return new DataResponse(new LicenseStatus($this->l->t("No license configured"), "nolicense" ,"-", "-", "-", "-", "-", "-", "-"));
return new DataResponse(new LicenseStatus($this->l->t("No license configured"), "nolicense" ,"-", "-", "-", "-", "-", "-", 0, "-"));
}
}
else {
return new DataResponse(new LicenseStatus($this->l->t("No license configured"), "nolicense" ,"-", "-", "-", "-", "-", "-", "-"));
return new DataResponse(new LicenseStatus($this->l->t("No license configured"), "nolicense" ,"-", "-", "-", "-", "-", "-", 0, "-"));
}
} catch (Exception $e) {
$this->logger->error('Cannot verify license');
Expand Down
4 changes: 1 addition & 3 deletions lib/Controller/StatusApiController.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,9 +65,7 @@ public function index(): DataResponse {

// Renews license if needed
if ($result->isCheckNeeded()) {

$result = $this->licensemanager->renewLicense($result);

}

// Gets all license status information
Expand All @@ -90,7 +88,7 @@ public function index(): DataResponse {
$status = "Valid";
}
$statusobj->licenseaction = $status;

$appVersionVSTO = $this->appVersionClient->latest('vstoaddin');
$appVersionNCApp = $this->appVersionClient->latest('ncapp');

Expand Down
Binary file added releases/3.0.4/sendent.zip
Binary file not shown.
Loading

0 comments on commit d9fb170

Please sign in to comment.