-
Notifications
You must be signed in to change notification settings - Fork 321
Fix command select using key OR value for selected #3052
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: alpha
Are you sure you want to change the base?
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1671,7 +1671,8 @@ public function toHtml($_version = 'dashboard', $_options = '') { | |
| $coupleArray = explode('|', $element); | ||
| $cmdValue = $this->getCmdValue(); | ||
| if (is_object($cmdValue) && $cmdValue->getType() == 'info') { | ||
| if ($cmdValue->execCmd() == $coupleArray[0] || $cmdValue->execCmd() == $coupleArray[1]) { | ||
| $keySeclected = intval($this->getConfiguration('listValueSelected', 0)); | ||
| if ($cmdValue->execCmd() == $coupleArray[$keySeclected]) { | ||
|
||
| $listOption .= '<option value="' . $coupleArray[0] . '" selected>' . $coupleArray[1] . '</option>'; | ||
| $foundSelect = true; | ||
| } else { | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -122,6 +122,12 @@ | |
| ?> | ||
| </div> | ||
| </div> | ||
| <div class="form-group"> | ||
| <label class="col-xs-4 control-label">{{Sélection par index de valeur}}</label> | ||
| <div class="col-xs-8"> | ||
| <input type="checkbox" class="cmdAttr" data-l1key="configuration" data-l2key="listValueSelected" /> | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe a select input will be more appropriate.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sure. |
||
| </div> | ||
| </div> | ||
| <?php } ?> | ||
| <div class="form-group"> | ||
| <label class="col-xs-4 control-label">{{Dernière exécution par}}</label> | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$keySelected (instead of $keySeclected)