summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Schmitzer <noreply@maennchen1.de>2017-09-07 14:14:50 +0000
committerDaniel Schmitzer <noreply@maennchen1.de>2017-09-07 14:14:50 +0000
commitd46b9797b56ec59f77935a18b5c33c1d1d8b1be4 (patch)
treea64a14de5373057e62d564ae51d41fb97614f63d
parentb3e5b61bbf98fe7c93186701c6f4b0a396c804f6 (diff)
- Lizenzverwaltung / Modulaktivierung
git-svn-id: https://[internal]/wordpress/plugins/wpsg4@6476 0d5edaf7-2b12-4e95-93f4-047927463d4b
-rw-r--r--views/admin/module.phtml56
-rw-r--r--views/css/admin.css2
2 files changed, 53 insertions, 5 deletions
diff --git a/views/admin/module.phtml b/views/admin/module.phtml
index 5ba4260..514918b 100644
--- a/views/admin/module.phtml
+++ b/views/admin/module.phtml
@@ -110,10 +110,33 @@
</div>
<div class="panel-body">
+ <form method="POST" action="<?php echo WPSG_URL_WP ?>wp-admin/admin.php?page=wpsg-Admin&action=registrierung&noheader=1&do=activatemodul">
+
+ <fieldset>
+ <legend style="padding-top:0px;"><?php echo __('Modulcode aktivieren', 'wpsg'); ?></legend>
+
+ <div class="row">
+ <div class="col-xs-10">
+
+ <input required="required" type="text" class="form-control" name="modulcode" id="modulcode" />
+
+ </div>
+ <div class="col-xs-2">
+
+ <input class="btn btn-primary btn-block" type="submit" class="form-control" value="<?php echo __('Prüfen', 'wpsg'); ?>" />
+
+ </div>
+ </div>
+ </fieldset>
+
+ </form>
+
+ <hr />
+
<?php $wpsg_update_data = wpsg_get_update_data(); ?>
<?php if (wpsg_isSizedArray($wpsg_update_data)) { ?>
- <table class="table">
+ <table class="table modultable">
<thead>
<tr>
<th><?php echo __('Modulname', 'wpsg'); ?></th>
@@ -124,7 +147,17 @@
</thead>
<tbody>
<?php foreach ($wpsg_update_data['modulinfo'] as $modul_key => $modul_info) { ?>
- <tr>
+ <tr style="font-style:normal;" class="
+
+ <?php if ($modul_info['free'] === true) { ?>
+ <?php echo 'active'; ?>
+ <?php } else if ($modul_info['active'] === true) { ?>
+ <?php echo 'success'; ?>
+ <?php } else { ?>
+ <?php echo 'info'; ?>
+ <?php } ?>
+
+ ">
<td><?php echo $modul_info['label']; ?></td>
<td>
@@ -140,7 +173,13 @@
<?php } else if ($modul_info['active'] === true) { ?>
<?php echo __('enthalten', 'wpsg'); ?>
<?php } else { ?>
+
+ <?php if (wpsg_isSizedString($modul_info['url_shop'])) { ?>
<a href="<?php echo $modul_info['url_shop']; ?>" target="_blank"><?php echo __('Modulcode hier erwerben', 'wpsg'); ?></a>
+ <?php } else { ?>
+ <a href="https://shop.maennchen1.de" target="_blank"><?php echo __('Modulcode hier erwerben', 'wpsg'); ?></a>
+ <?php } ?>
+
<?php } ?>
</td>
@@ -151,22 +190,29 @@
if ($this->hasModInstalled($modul_key) && $modul_info['version'] === $this->arAllModule[$modul_key]->version)
{
- echo ' ('.__('aktuell', 'wpsg').')';
+ echo ' - <strong class="wpsg_message_ok">'.__('aktuell', 'wpsg').'</strong>';
}
else if (version_compare($modul_info['version'], WPSG_VERSION) > 0)
{
- echo ' '.wpsg_translate(__('neue Version verfügbar (<a href="#1#">wpShopGermany Update</a> notwendig)', 'wpsg'), WPSG_URL_WP.'wp-admin/plugins.php');
+ echo ' - <strong class="wpsg_error">'.__('neue Version verfügbar', 'wpsg').'</strong><br />'.wpsg_translate(__('<a href="#1#">wpShopGermany Update</a> notwendig', 'wpsg'), WPSG_URL_WP.'wp-admin/plugins.php');
}
+ else if (version_compare($modul_info['version'], $this->arAllModule[$modul_key]->versio) > 0)
+ {
+
+ echo ' - <strong class="wpsg_error">'.__('neue Version verfügbar', 'wpsg').'</strong><br />';
+ echo wpsg_translate(__('Version <a href="#1#">installieren</a>.', 'wpsg'), WPSG_URL_WP.'wp-admin/admin.php?page=wpsg-Admin&action=registrierung&noheader=1&do=installModul&modul='.$modul_key);
+
+ }
?></td>
</tr>
<?php } ?>
</tbody>
</table>
-
+
<?php } else { ?>
<p>
diff --git a/views/css/admin.css b/views/css/admin.css
index e7e8e1d..7bdd8ff 100644
--- a/views/css/admin.css
+++ b/views/css/admin.css
@@ -37,6 +37,7 @@
#wpsg-bs .wpsg_glyphicon_right { float:right; }
#wpsg-bs .wpsg-glyphlink-td > span { margin-left:5px; margin-top:5px; }
#wpsg-bs .wpsg-glyphlink-td:hover { text-decoration:none; }
+#wpsg-bs .wpsg_message_ok { color:green; }
#wpsg-bs .wpsg_error { color:red; }
#wpsg-bs .form-group-sm .form-control { padding-left:8px; }
#wpsg-bs .form-group-text { position:relative; }
@@ -193,6 +194,7 @@
.wpsg_modul_onlyactive { position:absolute; }
.wpsg_modul_onlyactive_glyphicon { position:absolute !important; right:5px; top:7px !important; color:#3c763d; }
.wpsg_modul_search_wrap input[type="checkbox"] { right:25px; top:3px; position:absolute; }
+#wpsg-bs .modultable td { padding:4px 8px !important; }
/* Verwaltung Versandzonen */
.wpsg_table_vz .col_aktion { text-align:right; }