2019-08-23 11:39:42 +00:00
|
|
|
<div class="modal-container modal-container-hiden" id="modal-setting-<?php echo $SCENEID ?>">
|
|
|
|
<div class="modal">
|
|
|
|
<div class="close">
|
|
|
|
<i class="fa fa-times"></i>
|
|
|
|
</div>
|
2019-10-13 08:07:51 +00:00
|
|
|
<h4 class="mb-4"><?php $LANGMNG->echo('t_editScene')?></h4>
|
2019-08-23 11:39:42 +00:00
|
|
|
<form method="post">
|
|
|
|
<div class="field">
|
2019-10-13 08:07:51 +00:00
|
|
|
<div class="label"><?php $LANGMNG->echo('w_title');?>:</div>
|
2019-08-23 11:39:42 +00:00
|
|
|
<input type="text" class="input" name="sceneName" value="<?php echo $SCENE['name']; ?>"/>
|
|
|
|
</div>
|
|
|
|
<div class="field">
|
2019-10-13 08:07:51 +00:00
|
|
|
<div class="label"><?php $LANGMNG->echo('w_icon');?>:</div>
|
2019-08-23 11:39:42 +00:00
|
|
|
<select class="input fa" name="sceneIcon">
|
2019-10-13 08:07:51 +00:00
|
|
|
<option value=""><?php $LANGMNG->echo('w_no').$LANGMNG->get('w_icon');?></option>
|
2019-08-23 11:39:42 +00:00
|
|
|
<option value="f0eb" <?php ECHO ($SCENE['icon'] == "f0eb" ? 'selected="selected"' : ''); ?>> - fa-lightbulb-o</option>
|
|
|
|
<option value="f2dc" <?php ECHO ($SCENE['icon'] == "f2dc" ? 'selected="selected"' : ''); ?>> - fa-snowflake-o</option>
|
|
|
|
<option value="f0e7" <?php ECHO ($SCENE['icon'] == "f0e7" ? 'selected="selected"' : ''); ?>> - fa-bolt</option>
|
|
|
|
<option value="f2c7" <?php ECHO ($SCENE['icon'] == "f2c7" ? 'selected="selected"' : ''); ?>> - fa-thermometer-full</option>
|
|
|
|
<option value="f236" <?php ECHO ($SCENE['icon'] == "f236" ? 'selected="selected"' : ''); ?>> - fa-bed</option>
|
|
|
|
<option value="f185" <?php ECHO ($SCENE['icon'] == "f185" ? 'selected="selected"' : ''); ?>> - fa-sun-o</option>
|
|
|
|
<option value="f2db" <?php ECHO ($SCENE['icon'] == "f2db" ? 'selected="selected"' : ''); ?>> - fa-microchip</option>
|
|
|
|
<option value="f011" <?php ECHO ($SCENE['icon'] == "f011" ? 'selected="selected"' : ''); ?>> - fa-power-off</option>
|
|
|
|
<option value="f011" <?php ECHO ($SCENE['icon'] == "f011" ? 'selected="selected"' : ''); ?>> - fa-desktop</option>
|
|
|
|
</select>
|
|
|
|
</div>
|
|
|
|
<div class="field px-2">
|
|
|
|
<?php
|
|
|
|
$i = 0;
|
|
|
|
foreach($SCENE['doSomething'] as $subDeviceId => $subDeviceData){ ?>
|
|
|
|
<div id="scene-<?php echo $SCENEID; ?>-content">
|
|
|
|
<div class="label"><?php echo $subDeviceData['name']; ?></div>
|
|
|
|
<select class="input" name="devices[<?php echo $subDeviceId; ?>]">
|
|
|
|
<option value="0" <?php ECHO ($subDeviceData['state'] == "0" ? 'selected="selected"' : ''); ?>>off</option>
|
|
|
|
<option value="1" <?php ECHO ($subDeviceData['state'] == "1" ? 'selected="selected"' : ''); ?>>on</option>
|
|
|
|
</select>
|
|
|
|
<button name="remove" type="button" class="button is-danger fa" data-scene-id="<?php echo $SCENEID; ?>"></button>
|
|
|
|
</div>
|
|
|
|
<?php
|
|
|
|
$i++;
|
|
|
|
} ?>
|
|
|
|
</div>
|
2019-10-13 08:07:51 +00:00
|
|
|
<input type="submit" class="button" name="saveDevice" value="<?php $LANGMNG->echo('b_edit');?>"/>
|
|
|
|
<input type="button" class="button is-danger" onClick="ajaxPost('ajax',{scene_id:'<?php echo $SCENEID ?>', 'action':'delete'}, this, true);" name="saveDevice" value="<?php $LANGMNG->echo('b_remove');?>"/>
|
2019-08-23 11:39:42 +00:00
|
|
|
</form>
|
|
|
|
</div>
|
|
|
|
</div>
|