0
Good afternoon dear, I have an append that creates a dynamic list, however I need to do an if when it selects an option in specific it activates the if condition that returns a modal, I don’t know jquery, if anyone knows Gradeco a lot, I haven’t found anywhere how to do it.
Follow the append I’m trying to create:
$("#ulFiltroHomePeriodo").append("<li><a href=\"#\" onclick=\"seHome.atualizaPeriodoLabel('" + o.Value + "', '" + o.Text + "')\" data-value=" + o.Value + ">" + o.Text + "</a></li>")
This is the if I need to do:
if (o.Value == "porPeriodo") {
$("#ulFiltroHomePeriodo").on("click", function () {
$("#ModalDatasContainer").modal().show();
});
}
This option is " selected " through a checkbox ?
– Leo
No, it comes from a dynamic dropdown list, that append assembles the list and the.Value are the Enumerators with the options, these options generate dynamic reports, but in this case I need to set an initial date and an end, I created the modal to select the dates, however I don’t know how to make him select only that option inside the if. Currently the modal appear in all options.
– Jonathan Igor Bockorny Pereira