Skip to content

Commit

Permalink
new look
Browse files Browse the repository at this point in the history
  • Loading branch information
grosminet49 committed Jan 17, 2020
1 parent 5122f35 commit ea09279
Show file tree
Hide file tree
Showing 108 changed files with 115 additions and 2,113 deletions.
73 changes: 71 additions & 2 deletions desktop/js/vigilancemeteo.js
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,76 @@
* You should have received a copy of the GNU General Public License
* along with Jeedom. If not, see <http://www.gnu.org/licenses/>.
*/
$("#butCol").click(function(){
$("#hidCol").toggle("slow");
document.getElementById("listCol").classList.toggle('col-lg-12');
document.getElementById("listCol").classList.toggle('col-lg-10');
});

$(".li_eqLogic").on('click', function (event) {
if (event.ctrlKey) {
var type = $('body').attr('data-page')
var url = '/index.php?v=d&m='+type+'&p='+type+'&id='+$(this).attr('data-eqlogic_id')
window.open(url).focus()
} else {
jeedom.eqLogic.cache.getCmd = Array();
if ($('.eqLogicThumbnailDisplay').html() != undefined) {
$('.eqLogicThumbnailDisplay').hide();
}
$('.eqLogic').hide();
if ('function' == typeof (prePrintEqLogic)) {
prePrintEqLogic($(this).attr('data-eqLogic_id'));
}
if (isset($(this).attr('data-eqLogic_type')) && isset($('.' + $(this).attr('data-eqLogic_type')))) {
$('.' + $(this).attr('data-eqLogic_type')).show();
} else {
$('.eqLogic').show();
}
$(this).addClass('active');
$('.nav-tabs a:not(.eqLogicAction)').first().click()
$.showLoading()
jeedom.eqLogic.print({
type: isset($(this).attr('data-eqLogic_type')) ? $(this).attr('data-eqLogic_type') : eqType,
id: $(this).attr('data-eqLogic_id'),
status : 1,
error: function (error) {
$.hideLoading();
$('#div_alert').showAlert({message: error.message, level: 'danger'});
},
success: function (data) {
$('body .eqLogicAttr').value('');
if(isset(data) && isset(data.timeout) && data.timeout == 0){
data.timeout = '';
}
$('body').setValues(data, '.eqLogicAttr');
if ('function' == typeof (printEqLogic)) {
printEqLogic(data);
}
if ('function' == typeof (addCmdToTable)) {
$('.cmd').remove();
for (var i in data.cmd) {
addCmdToTable(data.cmd[i]);
}
}
$('body').delegate('.cmd .cmdAttr[data-l1key=type]', 'change', function () {
jeedom.cmd.changeType($(this).closest('.cmd'));
});

$('body').delegate('.cmd .cmdAttr[data-l1key=subType]', 'change', function () {
jeedom.cmd.changeSubType($(this).closest('.cmd'));
});
addOrUpdateUrl('id',data.id);
$.hideLoading();
modifyWithoutSave = false;
setTimeout(function(){
modifyWithoutSave = false;
},1000)
}
});
}
return false;
});

$('#btnSearchCity').on('click', function () {
$('#md_modal').dialog({title: "{{Trouver la ville}}"});
$('#md_modal').load('index.php?v=d&plugin=vigilancemeteo&modal=searchCity').dialog('open');
Expand All @@ -29,7 +98,7 @@ $('#typeEq').change(function(){
$('#geolocEq').show();
$('#surfEq').hide();
$('#mswEq').hide();
$('#breezeEq').hide();
$('#breezeEq').hide();
}
if (text == 'air') {
$('#portEq').hide();
Expand All @@ -38,7 +107,7 @@ $('#typeEq').change(function(){
$('#geolocEq').show();
$('#surfEq').hide();
$('#mswEq').hide();
$('#breezeEq').show();
$('#breezeEq').show();
}
if (text == 'maree') {
$('#portEq').show();
Expand Down
78 changes: 44 additions & 34 deletions desktop/php/vigilancemeteo.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,44 +9,54 @@
?>

<div class="row row-overflow">
<div class="col-lg-2 col-md-3 col-sm-4">
<div class="bs-sidebar">
<ul id="ul_eqLogic" class="nav nav-list bs-sidenav">
<a class="btn btn-default eqLogicAction" style="width : 100%;margin-top : 5px;margin-bottom: 5px;" data-action="add"><i class="fas fa-plus-circle"></i> {{Ajouter un équipement}}</a>
<li class="filter" style="margin-bottom: 5px;"><input class="filter form-control input-sm" placeholder="{{Rechercher}}" style="width: 100%"/></li>
<?php
foreach ($eqLogics as $eqLogic) {
echo '<li class="cursor li_eqLogic" data-eqLogic_id="' . $eqLogic->getId() . '"><a>' . $eqLogic->getHumanName(true) . '</a></li>';
}
?>
</ul>
</div>
<div class="col-lg-2 col-sm-3 col-sm-4" id="hidCol" style="display: none;">
<div class="bs-sidebar">
<ul id="ul_eqLogic" class="nav nav-list bs-sidenav">
<li class="filter" style="margin-bottom: 5px;"><input class="filter form-control input-sm" placeholder="{{Rechercher}}" style="width: 100%"/></li>
<?php
foreach ($eqLogics as $eqLogic) {
echo '<li class="cursor li_eqLogic" data-eqLogic_id="' . $eqLogic->getId() . '"><a>' . $eqLogic->getHumanName(true) . '</a></li>';
}
?>
</ul>
</div>
</div>

<div class="col-lg-12 eqLogicThumbnailDisplay" id="listCol">
<legend><i class="fas fa-cog"></i> {{Gestion}}</legend>
<div class="eqLogicThumbnailContainer logoPrimary">

<div class="cursor eqLogicAction logoSecondary" data-action="add">
<i class="fas fa-plus-circle"></i>
<br/>
<span>{{Ajouter}}</span>
</div>
<div class="cursor eqLogicAction logoSecondary" data-action="gotoPluginConf">
<i class="fas fa-wrench"></i>
<br/>
<span>{{Configuration}}</span>
</div>

<div class="col-lg-10 col-md-9 col-sm-8 eqLogicThumbnailDisplay" style="border-left: solid 1px #EEE; padding-left: 25px;">
<legend>{{Mes Vigilances Météo}}
</legend>
<div class="eqLogicThumbnailContainer">
<div class="cursor eqLogicAction" data-action="add" style="background-color : #ffffff; height : 200px;margin-bottom : 10px;padding : 5px;border-radius: 2px;width : 160px;margin-left : 10px;" >
<center>
<i class="fas fa-plus-circle" style="font-size : 7em;color:#00979c;"></i>
</center>
<span style="font-size : 1.1em;position:relative; top : 15px;word-break: break-all;white-space: pre-wrap;word-wrap: break-word;"><center>Ajouter</center></span>
</div>
<?php
foreach ($eqLogics as $eqLogic) {
$opacity = ($eqLogic->getIsEnable()) ? '' : jeedom::getConfiguration('eqLogic:style:noactive');
echo '<div class="eqLogicDisplayCard cursor" data-eqLogic_id="' . $eqLogic->getId() . '" style="background-color : #ffffff ; height : 200px;margin-bottom : 10px;padding : 5px;border-radius: 2px;width : 160px;margin-left : 10px;' . $opacity . '" >';
echo "<center>";
echo '<img src="plugins/vigilancemeteo/doc/images/vigilancemeteo_icon.png" height="105" width="95" />';
echo "</center>";
echo '<span style="font-size : 1.1em;position:relative; top : 15px;word-break: break-all;white-space: pre-wrap;word-wrap: break-word;"><center>' . $eqLogic->getHumanName(true, true) . '</center></span>';
echo '</div>';
}
?>
</div>
</div>

<input class="form-control" placeholder="{{Rechercher}}" id="in_searchEqlogic" />

<legend><i class="fas fa-home" id="butCol"></i> {{Mes Equipements}}</legend>
<div class="eqLogicThumbnailContainer">
<?php
foreach ($eqLogics as $eqLogic) {
$opacity = ($eqLogic->getIsEnable()) ? '' : jeedom::getConfiguration('eqLogic:style:noactive');
echo '<div class="eqLogicDisplayCard cursor" data-eqLogic_id="' . $eqLogic->getId() . '" style="background-color : #ffffff ; height : 200px;margin-bottom : 10px;padding : 5px;border-radius: 2px;width : 160px;margin-left : 10px;' . $opacity . '" >';
echo "<center>";
echo '<img src="plugins/vigilancemeteo/plugin_info/vigilancemeteo_icon.png" height="105" width="95" />';
echo "</center>";
echo '<span style="font-size : 1.1em;position:relative; top : 15px;word-break: break-all;white-space: pre-wrap;word-wrap: break-word;"><center>' . $eqLogic->getHumanName(true, true) . '</center></span>';
echo '</div>';
}
?>
</div>
</div>


<div class="col-lg-10 col-md-9 col-sm-8 eqLogic" style="border-left: solid 1px #EEE; padding-left: 25px;display: none;">
<a class="btn btn-success eqLogicAction pull-right" data-action="save"><i class="fas fa-check-circle"></i> {{Sauvegarder}}</a>
Expand Down
29 changes: 0 additions & 29 deletions doc/de_DE/air.asciidoc

This file was deleted.

9 changes: 0 additions & 9 deletions doc/de_DE/changelog.asciidoc

This file was deleted.

11 changes: 0 additions & 11 deletions doc/de_DE/faq.asciidoc

This file was deleted.

46 changes: 0 additions & 46 deletions doc/de_DE/index.asciidoc

This file was deleted.

23 changes: 0 additions & 23 deletions doc/de_DE/indexuv.asciidoc

This file was deleted.

17 changes: 0 additions & 17 deletions doc/de_DE/maree.asciidoc

This file was deleted.

13 changes: 0 additions & 13 deletions doc/de_DE/plage.asciidoc

This file was deleted.

35 changes: 0 additions & 35 deletions doc/de_DE/pluie1h.asciidoc

This file was deleted.

Loading

0 comments on commit ea09279

Please sign in to comment.