Skip to content

Commit

Permalink
Merge pull request #4 from MechComp/master
Browse files Browse the repository at this point in the history
Sync 2020-05-07
  • Loading branch information
MechComp committed May 7, 2020
2 parents 08557bd + eeb2631 commit 7e34229
Show file tree
Hide file tree
Showing 27 changed files with 1,091 additions and 1,437 deletions.
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Welcome to software license manager 👋
![Version](https://img.shields.io/badge/version-5.5.0-blue.svg?cacheSeconds=2592000)
![Version](https://img.shields.io/badge/version-5.5.2-blue.svg?cacheSeconds=2592000)
[![Documentation](https://img.shields.io/badge/documentation-yes-brightgreen.svg)](https://documenter.getpostman.com/view/307939/6tjU1FL?version=latest)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://github.com/michelve/software-license-manager/blob/master/LICENSE.md)

Expand Down Expand Up @@ -89,7 +89,7 @@ Changelog: [View changelog](https://github.com/michelve/software-license-manager

<img src="https://raw.githubusercontent.com/michelve/software-license-manager/master/public/assets/images/previews/export.png?raw=true" width="800" alt="Software License Manager" />

<img src="https://raw.githubusercontent.com/michelve/software-license-manager/master/public/assets/images/previews/my-account-lics-opened.png?raw=true" alt="Software License Manager" width="800" />
<img src="https://raw.githubusercontent.com/michelve/software-license-manager/1bf014b84300ba58e7ce614c25f9976c7fab6cb1/public/assets/images/previews/my-account-lics-opened.png" alt="Software License Manager" width="800" />


## 📝 License
Expand Down
2 changes: 1 addition & 1 deletion _config.yml
Original file line number Diff line number Diff line change
@@ -1 +1 @@
theme: jekyll-theme-minimal
theme: jekyll-theme-cayman
325 changes: 148 additions & 177 deletions admin/slm-add-licenses.php

Large diffs are not rendered by default.

7 changes: 4 additions & 3 deletions admin/slm-dashboard-widgets.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,10 @@
}

add_action('wp_dashboard_setup', 'slm_add_dashboard_widgets');
add_action('admin_bar_menu', 'add_toolbar_items', 100);

if (null !== SLM_Helper_Class::slm_get_option('slm_adminbar') && SLM_Helper_Class::slm_get_option('slm_adminbar') == 1) {
add_action('admin_bar_menu', 'add_toolbar_items', 100);
}
/**
* Add a widget to the dashboard.
*
Expand All @@ -22,8 +24,7 @@ function slm_add_dashboard_widgets()
);
}

function add_toolbar_items($admin_bar)
{
function add_toolbar_items($admin_bar){
$admin_bar->add_menu(array(
'id' => 'slm-menu',
'title' => '<span class="ab-icon"></span>' . __('SLM', 'softwarelicensemanager'),
Expand Down
30 changes: 16 additions & 14 deletions admin/slm-lic-settings.php
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@ function slm_general_settings(){
global $slm_debug_logger;
$slm_debug_logger->reset_log_file("log.txt");
$slm_debug_logger->reset_log_file("log-cron-job.txt");
echo '<div id="message" class="updated fade"><p>Debug log files have been reset!</p></div>';
echo '<div id="message" class="updated fade"><p>
'.__( 'Debug log files have been reset!', 'softwarelicensemanager' ) .'
</p></div>';
}

if (isset($_POST['slm_save_settings'])) {
Expand Down Expand Up @@ -51,7 +53,7 @@ function slm_general_settings(){
);
update_option('slm_plugin_options', $options);

echo ' <div id="message" class="updated fade"> <p>Options Updated!</p> </div>';
echo ' <div id="message" class="updated fade"> <p>'.__( 'Options updated!', 'softwarelicensemanager' ).'</p> </div>';
}

$options = get_option('slm_plugin_options');
Expand Down Expand Up @@ -81,19 +83,19 @@ function slm_general_settings(){
<div id="icon-options-general" class="icon32"></div>
<h2 class="nav-tab-wrapper">
<a href="<?php echo admin_url('admin.php?page=' . 'slm_settings') ?>" class="nav-tab <?php echo ($tab == 'general_settings') ? 'nav-tab-active' : '' ?>">
<?php echo __('General Settings', 'slm'); ?>
<?php echo __('General Settings', 'softwarelicensemanager'); ?>
</a>

<a href="<?php echo admin_url('admin.php?page=' . 'slm_settings' . '&tab=integrations') ?>" class="nav-tab <?php echo ($tab == 'integrations') ? 'nav-tab-active' : '' ?>">
<?php echo __('Integrations', 'slm'); ?>
<?php echo __('Integrations', 'softwarelicensemanager'); ?>
</a>

<a href="<?php echo admin_url('admin.php?page=' . 'slm_settings' . '&tab=debug') ?>" class="nav-tab <?php echo ($tab == 'debug') ? 'nav-tab-active' : '' ?>">
<?php echo __('Debugging settings', 'slm'); ?>
<?php echo __('Debugging settings', 'softwarelicensemanager'); ?>
</a>

<a href="<?php echo admin_url('admin.php?page=' . 'slm_settings' . '&tab=emails') ?>" class="nav-tab <?php echo ($tab == 'emails') ? 'nav-tab-active' : '' ?>">
<?php echo __('Emails', 'slm'); ?>
<?php echo __('Emails', 'softwarelicensemanager'); ?>
</a>

</h2>
Expand Down Expand Up @@ -121,14 +123,14 @@ function slm_general_settings(){
<table class="form-table">
<tr valign="top">
<th scope="row"><?php _e('Secret Key for License Creation', 'softwarelicensemanager'); ?></th>
<td><textarea name="lic_creation_secret" rows="2" cols="50"><?php echo $secret_key; ?>
<td><textarea name="lic_creation_secret" rows="2" cols="50" readonly><?php echo $secret_key; ?>
</textarea>
<p class=" description"><?php _e('This secret key will be used to authenticate any license creation request. You can change it with something random.', 'softwarelicensemanager'); ?></p>
</td>
</tr>
<tr valign="top">
<th scope="row"><?php _e('Secret Key for License Verification Requests', 'softwarelicensemanager'); ?></th>
<td><textarea name="lic_verification_secret" rows="2" cols="50"><?php echo $secret_verification_key; ?></textarea>
<td><textarea name="lic_verification_secret" rows="2" cols="50" readonly><?php echo $secret_verification_key; ?></textarea>
<p class="description"><?php _e('This secret key will be used to authenticate any license verification request from customer\'s site. Important! Do not change this value once your customers start to use your product(s)!', 'softwarelicensemanager'); ?></p>
</td>
</tr>
Expand Down Expand Up @@ -168,7 +170,7 @@ function slm_general_settings(){
<th scope="row"></th>
<td>
<input name="slm_adminbar" type="checkbox" <?php if ($options['slm_adminbar'] != '') echo ' checked="checked"'; ?> value="1" />
<?php _e('Disable stats in licenses overview page.', 'softwarelicensemanager'); ?></td>
<?php _e('Enable admin bar shortcut link', 'softwarelicensemanager'); ?></td>
</tr>

<tr>
Expand All @@ -181,7 +183,7 @@ function slm_general_settings(){
</tr>

<tr>
<th scope="row"></th>
<th scope="row">Bootstrap library</th>
<td>
<input name="slm_conflictmode" type="checkbox" <?php if ($options['slm_conflictmode'] != '') echo ' checked="checked"'; ?> value="1" />
<?php _e('Enable Bootstrap javascript libray.', 'softwarelicensemanager'); ?></td>
Expand All @@ -207,13 +209,13 @@ function slm_general_settings(){
<input name="slm_woo_downloads" type="checkbox" <?php if ($options['slm_woo_downloads'] != '') echo ' checked="checked"'; ?> value="1" />
<?php _e('Disable woocommerce download page. Process downloads though license order info page.', 'softwarelicensemanager'); ?></td>
</tr>
<tr valign="top">
<!-- <tr valign="top">
<th scope="row"> <?php _e('Download Manager Support', 'softwarelicensemanager'); ?></th>
<td>
<input name="slm_dl_manager" type="checkbox" <?php if ($options['slm_dl_manager'] != '') echo ' checked="checked"'; ?> value="1" />
<?php _e('Download Manager Plugin – Adds a simple download manager to your WordPress blog.', 'softwarelicensemanager'); ?>
</td>
</tr>
</tr> -->
<tr valign="top">
<th scope="row"> <?php _e('WP eStores Support', 'softwarelicensemanager'); ?></th>
<td>
Expand All @@ -230,10 +232,10 @@ function slm_general_settings(){
<div class=" inside">
<table class="form-table">
<tr valign="top">
<th scope="row"> <?php _e('Enable Debug Logging', 'softwarelicensemanager'); ?></th>
<th scope="row"> <?php echo __('Enable Debug Logging', 'softwarelicensemanager'); ?></th>
<td>
<p class="description"><input name="enable_debug" type="checkbox" <?php if ($options['enable_debug'] != '') echo ' checked="checked"'; ?> value="1" />
<?php _e('If checked, debug output will be written to log files (keep it disabled unless you are troubleshooting).', ' softwarelicensemanager '); ?></p>
<?php echo __('If checked, debug output will be written to log files.', ' softwarelicensemanager '); ?></p>
</td>
</tr>
</table>
Expand Down
4 changes: 2 additions & 2 deletions admin/slm-list-licenses-class.php
Original file line number Diff line number Diff line change
Expand Up @@ -394,12 +394,12 @@ public static function set_screen($status, $option, $value)

public function slm_add_admin_menu()
{
$icon_svg = SLM_ASSETS_URL . 'images/slm_logo_small.svg';
$icon_svg = SLM_ASSETS_URL . 'icons/logo/slm_small.svg';

add_menu_page("SLM", "SLM", SLM_MANAGEMENT_PERMISSION, SLM_MAIN_MENU_SLUG, "slm_manage_licenses_menu", $icon_svg);
$hook = add_submenu_page(SLM_MAIN_MENU_SLUG, "Manage Licenses", "Manage Licenses", SLM_MANAGEMENT_PERMISSION, SLM_MAIN_MENU_SLUG, "slm_manage_licenses_menu");

add_submenu_page(SLM_MAIN_MENU_SLUG, "Add License", "Add Licenses", SLM_MANAGEMENT_PERMISSION, 'slm_manage_license', "slm_add_licenses_menu");
add_submenu_page(SLM_MAIN_MENU_SLUG, __( 'Create license', 'softwarelicensemanager'), __( 'Create license', 'softwarelicensemanager') , SLM_MANAGEMENT_PERMISSION, 'slm_manage_license', "slm_add_licenses_menu");
add_submenu_page(SLM_MAIN_MENU_SLUG, "Subscribers", "Subscribers", SLM_MANAGEMENT_PERMISSION, 'slm_subscribers', "slm_subscribers_menu");
add_submenu_page(SLM_MAIN_MENU_SLUG, "Tools", "Tools", SLM_MANAGEMENT_PERMISSION, 'slm_admin_tools', "slm_admin_tools_menu");
add_submenu_page(SLM_MAIN_MENU_SLUG, "Settings", "Settings", SLM_MANAGEMENT_PERMISSION, 'slm_settings', "slm_settings_menu");
Expand Down
Binary file added i18n/languages/softwarelicensemanager-es_ES.mo
Binary file not shown.
Loading

0 comments on commit 7e34229

Please sign in to comment.