Skip to content
Code-Schnipsel Gruppen Projekte
Bestätigt Commit 7c510d65 erstellt von Henning Leutz's avatar Henning Leutz :martial_arts_uniform:
Dateien durchsuchen

refactor: #11 - target

Übergeordneter 6f80ae1e
No related branches found
No related tags found
Keine zugehörigen Merge Requests gefunden
......@@ -56,6 +56,24 @@
</label>
</td>
</tr>
<tr>
<td>
<label class="field-container">
<span class="field-container-item">
{{target}}
</span>
<select class="field-container-field" name="target">
<option value="">{{targetNone}}</option>
<option value="_self">{{targetSelf}}</option>
<option value="frame">{{targetFrame}}</option>
<option value="popup">{{targetPopup}}</option>
<option value="_blank">{{targetBlank}}</option>
<option value="_top">{{targetTop}}</option>
<option value="_parent">{{targetParent}}</option>
</select>
</label>
</td>
</tr>
<tr>
<td>
<label class="field-container">
......
......@@ -59,6 +59,15 @@ define('package/quiqqer/menu/bin/Controls/Independent/Items/Custom', [
prev : QUILocale.get(lg, 'tpl.rel.prev'),
search : QUILocale.get(lg, 'tpl.rel.search'),
tag : QUILocale.get(lg, 'tpl.rel.tag'),
target : QUILocale.get(lg, 'tpl.target'),
targetNone : QUILocale.get(lg, 'tpl.target.none'),
targetSelf : QUILocale.get(lg, 'tpl.target.self'),
targetFrame : QUILocale.get(lg, 'tpl.target.frame'),
targetPopup : QUILocale.get(lg, 'tpl.target.popup'),
targetBlank : QUILocale.get(lg, 'tpl.target.blank'),
targetTop : QUILocale.get(lg, 'tpl.target.top'),
targetParent: QUILocale.get(lg, 'tpl.target.parent')
}));
let title = this.getAttribute('title');
......@@ -132,10 +141,11 @@ define('package/quiqqer/menu/bin/Controls/Independent/Items/Custom', [
title: this.$Title.getValue(),
icon : Form.elements.icon.value,
data : {
url : Form.elements.url.value,
rel : Form.elements.rel.value,
click: Form.elements.click.value,
name : this.$Name.getValue()
url : Form.elements.url.value,
rel : Form.elements.rel.value,
target: Form.elements.target.value,
click : Form.elements.click.value,
name : this.$Name.getValue()
}
};
}
......
......@@ -16,6 +16,24 @@
</label>
</td>
</tr>
<tr>
<td>
<label class="field-container">
<span class="field-container-item">
{{target}}
</span>
<select class="field-container-field" name="target">
<option value="">{{targetNone}}</option>
<option value="_self">{{targetSelf}}</option>
<option value="frame">{{targetFrame}}</option>
<option value="popup">{{targetPopup}}</option>
<option value="_blank">{{targetBlank}}</option>
<option value="_top">{{targetTop}}</option>
<option value="_parent">{{targetParent}}</option>
</select>
</label>
</td>
</tr>
<tr>
<td>
<label class="field-container">
......
......@@ -53,6 +53,15 @@ define('package/quiqqer/menu/bin/Controls/Independent/Items/Site', [
prev : QUILocale.get(lg, 'tpl.rel.prev'),
search : QUILocale.get(lg, 'tpl.rel.search'),
tag : QUILocale.get(lg, 'tpl.rel.tag'),
target : QUILocale.get(lg, 'tpl.target'),
targetNone : QUILocale.get(lg, 'tpl.target.none'),
targetSelf : QUILocale.get(lg, 'tpl.target.self'),
targetFrame : QUILocale.get(lg, 'tpl.target.frame'),
targetPopup : QUILocale.get(lg, 'tpl.target.popup'),
targetBlank : QUILocale.get(lg, 'tpl.target.blank'),
targetTop : QUILocale.get(lg, 'tpl.target.top'),
targetParent: QUILocale.get(lg, 'tpl.target.parent')
}));
let data = this.getAttribute('data');
......@@ -86,8 +95,9 @@ define('package/quiqqer/menu/bin/Controls/Independent/Items/Site', [
return {
data: {
site: Form.elements.site.value,
rel : Form.elements.rel.value
site : Form.elements.site.value,
target: Form.elements.target.value,
rel : Form.elements.rel.value
}
};
}
......
......@@ -56,6 +56,24 @@
</label>
</td>
</tr>
<tr>
<td>
<label class="field-container">
<span class="field-container-item">
{{target}}
</span>
<select class="field-container-field" name="target">
<option value="">{{targetNone}}</option>
<option value="_self">{{targetSelf}}</option>
<option value="frame">{{targetFrame}}</option>
<option value="popup">{{targetPopup}}</option>
<option value="_blank">{{targetBlank}}</option>
<option value="_top">{{targetTop}}</option>
<option value="_parent">{{targetParent}}</option>
</select>
</label>
</td>
</tr>
<tr>
<td>
<label class="field-container">
......
......@@ -56,6 +56,15 @@ define('package/quiqqer/menu/bin/Controls/Independent/Items/Url', [
prev : QUILocale.get(lg, 'tpl.rel.prev'),
search : QUILocale.get(lg, 'tpl.rel.search'),
tag : QUILocale.get(lg, 'tpl.rel.tag'),
target : QUILocale.get(lg, 'tpl.target'),
targetNone : QUILocale.get(lg, 'tpl.target.none'),
targetSelf : QUILocale.get(lg, 'tpl.target.self'),
targetFrame : QUILocale.get(lg, 'tpl.target.frame'),
targetPopup : QUILocale.get(lg, 'tpl.target.popup'),
targetBlank : QUILocale.get(lg, 'tpl.target.blank'),
targetTop : QUILocale.get(lg, 'tpl.target.top'),
targetParent: QUILocale.get(lg, 'tpl.target.parent')
}));
let title = this.getAttribute('title');
......@@ -129,9 +138,10 @@ define('package/quiqqer/menu/bin/Controls/Independent/Items/Url', [
title: this.$Title.getValue(),
icon : Form.elements.icon.value,
data : {
url : Form.elements.url.value,
name: this.$Name.getValue(),
rel : Form.elements.rel.value
url : Form.elements.url.value,
target: Form.elements.target.value,
name : this.$Name.getValue(),
rel : Form.elements.rel.value
}
};
}
......
......@@ -476,5 +476,38 @@
]]></en>
</locale>
<locale name="tpl.target">
<de><![CDATA[Zielseite (target)]]></de>
<en><![CDATA[Target]]></en>
</locale>
<locale name="tpl.target.none">
<de><![CDATA[Standard (Kein target)]]></de>
<en><![CDATA[Default (No target)]]></en>
</locale>
<locale name="tpl.target.self">
<de><![CDATA[Gleiches Fenster (_self)]]></de>
<en><![CDATA[Same window (_self)]]></en>
</locale>
<locale name="tpl.target.frame">
<de><![CDATA[Frame]]></de>
<en><![CDATA[Frame]]></en>
</locale>
<locale name="tpl.target.popup">
<de><![CDATA[Pop-up Fenster]]></de>
<en><![CDATA[Popup window)]]></en>
</locale>
<locale name="tpl.target.blank">
<de><![CDATA[Neues Fenster (_blank)]]></de>
<en><![CDATA[New window (_blank)]]></en>
</locale>
<locale name="tpl.target.top">
<de><![CDATA[Oberstes Fenster (_top)]]></de>
<en><![CDATA[Top window (_top)]]></en>
</locale>
<locale name="tpl.target.parent">
<de><![CDATA[Oberes Fenster (_parent)]]></de>
<en><![CDATA[Parent window (_parent)]]></en>
</locale>
</groups>
</locales>
\ No newline at end of file
......@@ -133,6 +133,20 @@ public function getRel(): string
return '';
}
/**
* @return string
*/
public function getTarget(): string
{
$data = $this->getCustomData();
if (is_array($data) && isset($data['target'])) {
return $data['target'];
}
return '';
}
/**
* @return mixed
*/
......
0% oder .
You are about to add 0 people to the discussion. Proceed with caution.
Bearbeitung dieser Nachricht zuerst beenden!
Bitte registrieren oder zum Kommentieren