<!DOCTYPE html>
<html class="loading" lang="en" data-textdirection="ltr">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=0, minimal-ui">
    <title>@ViewData["Title"] | Empowered Forex Trader</title>
    <link rel="apple-touch-icon" href="~/images/apple-icon120.png">
    <link rel="shortcut icon" type="image/x-icon" href="~/favicon.ico">
    <link href="https://fonts.googleapis.com/css?family=Montserrat:300,300i,400,400i,500,500i%7COpen+Sans:300,300i,400,400i,600,600i,700,700i" rel="stylesheet">
    <!-- BEGIN VENDOR CSS-->
    <link rel="stylesheet" type="text/css" href="~/css/bootstrap.css">
    <link rel="stylesheet" type="text/css" href="~/fonts/feather/style.min.css">
    <link rel="stylesheet" type="text/css" href="~/fonts/font-awesome/css/font-awesome.min.css">
    <link rel="stylesheet" type="text/css" href="~/fonts/flag-icon-css/css/flag-icon.min.css">
    <link rel="stylesheet" type="text/css" href="~/css/pace.css">
    <link rel="stylesheet" type="text/css" href="~/css/unslider.css">
    <link rel="stylesheet" type="text/css" href="~/css/climacons.min.css">
    <link rel="stylesheet" type="text/css" href="~/css/minimal/_all.css">
    <link rel="stylesheet" type="text/css" href="~/css/square/_all.css">
    <link rel="stylesheet" type="text/css" href="~/css/flat/_all.css">
    <link rel="stylesheet" type="text/css" href="~/css/line/_all.css">
    <link rel="stylesheet" type="text/css" href="~/css/polaris/polaris.css">
    <link rel="stylesheet" type="text/css" href="~/css/futurico/futurico.css">
    <link rel="stylesheet" type="text/css" href="~/css/icheck/custom.css">
    <link rel="stylesheet" type="text/css" href="~/css/toogle.css" />
    <link href="~/css/bootstrap-datetimepicker.css" rel="stylesheet" />
    <!-- END VENDOR CSS-->
    <!-- BEGIN STACK CSS-->
    <link rel="stylesheet" type="text/css" href="~/css/bootstrap-extended.css">
    <link rel="stylesheet" type="text/css" href="~/css/colors.css">
    <link rel="stylesheet" type="text/css" href="~/css/components.css">
    <!-- END STACK CSS-->
    <!-- BEGIN Page Level CSS-->
    <link rel="stylesheet" type="text/css" href="~/css/horizontal-menu.css">
    <link rel="stylesheet" type="text/css" href="~/css/toastr.css">
    <!-- END Page Level CSS-->
    <!-- BEGIN Custom CSS-->
    <link rel="stylesheet" type="text/css" href="~/css/style.css">
    <link rel="stylesheet" href="~/css/toogle.css" type="text/css" />
    <!-- END Custom CSS-->
</head>
<body class="horizontal-layout horizontal-menu 2-columns menu-expanded" data-open="click" data-menu="horizontal-menu" data-col="2-columns">
    <!-- fixed-top-->
    <nav class="header-navbar navbar-expand-md navbar navbar-with-menu navbar-static-top navbar-light navbar-shadow navbar-border navbar-brand-center">
        <div class="navbar-wrapper">
            <div class="navbar-header">
                <ul class="nav navbar-nav flex-row">
                    <li class="nav-item mobile-menu d-md-none mr-auto">
                        <a class="nav-link nav-menu-main menu-toggle hidden-xs" href="#"><i class="ft-menu font-large-1"></i></a>
                    </li>
                    <li class="nav-item">
                        <a class="navbar-brand" href="@Url.Action("Guru", "Home")">
                            <img class="brand-logo" alt="stack admin logo" src="~/images/logo192.png">
                        </a>
                    </li>
                    <li class="nav-item d-md-none">
                        <a class="nav-link open-navbar-container" data-toggle="collapse" data-target="#navbar-mobile"><i class="fa fa-ellipsis-v"></i></a>
                    </li>
                </ul>
            </div>
            <div class="navbar-container container center-layout">
                <div class="collapse navbar-collapse" id="navbar-mobile">
                    <ul class="nav navbar-nav mr-auto float-left">
                        <li class="nav-item d-none d-md-block"><a class="nav-link nav-link-expand" href="#"><i class="ficon ft-maximize"></i></a></li>
                    </ul>
                    <ul class="nav navbar-nav float-right">
                        <li class="dropdown dropdown-notification nav-item">
                            <a class="nav-link nav-link-label" href="#" data-toggle="dropdown"><i class="ficon ft-mail"></i><span class="badge badge-pill badge-default badge-warning badge-default badge-up">0</span></a>
                            <ul class="dropdown-menu dropdown-menu-media dropdown-menu-right">
                                <li class="dropdown-menu-header">
                                    <h6 class="dropdown-header m-0"><span class="grey darken-2">Messages</span><span class="notification-tag badge badge-default badge-warning float-right m-0">0 New</span></h6>
                                </li>
                                <li class="scrollable-container media-list">
                                    <a href="javascript:void(0)">
                                        <div class="media">
                                            <div class="media-body">
                                                <p class="notification-text font-small-3 text-muted">No messages</p>
                                            </div>
                                        </div>
                                    </a>
                                </li>
                                <li class="dropdown-menu-footer"><a class="dropdown-item text-muted text-center" href="javascript:void(0)">Read all messages</a></li>
                            </ul>
                        </li>
                        <li class="dropdown dropdown-user nav-item">
                            <a class="dropdown-toggle nav-link dropdown-user-link" href="#" data-toggle="dropdown">
                                @if (Model.IsImpersonated)
                                {
                                    <span class="avatar avatar-online" title="User being impersonated">
                                        <img src="~/images/avatar-empty-black.png" alt="avatar">
                                        <i class="ft-eye impersonated"></i>
                                    </span>
                                }
                                else
                                {
                                    <span class="avatar avatar-online">
                                        <img src="~/images/avatar-empty-black.png" alt="avatar">
                                        <i></i>
                                    </span>
                                }
                                <span class="user-name">@Model.LoggedUserFullName</span>
                            </a>
                            <div class="dropdown-menu dropdown-menu-right">
                                <a class="dropdown-item" href="#"><i class="ft-mail"></i> My Inbox</a>
                                <div class="dropdown-divider"></div>
                                @if (!String.IsNullOrEmpty(Model.Impersonator))
                                {
                                    <a class="dropdown-item" href="@Url.Action("ReturnAdminPanel", "UserManagement")"><i class="ft-log-out"></i> Back to Admin Panel</a>
                                }
                                <a class="dropdown-item" href="@Url.Action("Logout", "Login")"><i class="ft-power"></i> Logout</a>
                            </div>
                        </li>
                    </ul>
                </div>
            </div>
        </div>
    </nav>
    <!-- ////////////////////////////////////////////////////////////////////////////-->
    <!-- Horizontal navigation-->
    <div class="header-navbar navbar-expand-sm navbar navbar-horizontal navbar-fixed navbar-light navbar-without-dd-arrow navbar-shadow menu-border" role="navigation" data-menu="menu-wrapper">
        <!-- Horizontal menu content-->
        <div class="navbar-container main-menu-content container center-layout" data-menu="menu-container">
            <!-- include ../../../includes/mixins-->
            <ul class="nav navbar-nav" id="main-menu-navigation" data-menu="menu-navigation">
                <li class="dropdown mega-dropdown nav-item" data-menu="megamenu">
                    <a class="dropdown-toggle nav-link mx-1" href="@Url.Action("Guru","Home")"><i class="ft-toggle-right"></i><span>Guru</span></a>
                </li>
                <li class="dropdown mega-dropdown nav-item" data-menu="megamenu">
                    <a class="dropdown-toggle nav-link mx-1" href="#" data-toggle="dropdown"><i class="ft-activity"></i><span>Expert Advisors</span></a>
                    <ul class="mega-dropdown-menu dropdown-menu row">
                        <li class="col-md-3" data-mega-col="col-md-3">
                            <ul class="drilldown-menu">
                                <li class="menu-list">
                                    <ul class="mega-menu-sub">
                                        <li>
                                            <a class="dropdown-item" href="@Url.Action("ViewExpertAdvisors","ExpertAdvisor")">View Expert Advisors</a>
                                        </li>
                                    </ul>
                                </li>
                            </ul>
                        </li>
                        <li class="col-md-3" data-mega-col="col-md-3">
                            <ul class="drilldown-menu">
                                <li class="menu-list">
                                    <ul class="mega-menu-sub">
                                        <li>
                                            <a class="dropdown-item" href="@Url.Action("AddExpertAdvisor", "ExpertAdvisor")">Add New Expert Advisor</a>

                                        </li>
                                    </ul>
                                </li>
                            </ul>
                        </li>
                    </ul>
                </li>
                <li class="dropdown mega-dropdown nav-item" data-menu="megamenu">
                    <a class="dropdown-toggle nav-link mx-1" href="#" data-toggle="dropdown"><i class="ft-link-2"></i><span>Scripts</span></a>
                    <ul class="mega-dropdown-menu dropdown-menu row">
                        <li class="col-md-3" data-mega-col="col-md-3">
                            <ul class="drilldown-menu">
                                <li class="menu-list">
                                    <ul class="mega-menu-sub">
                                        <li>
                                            <a class="dropdown-item" href="@Url.Action("ViewScripts","Script")">View Scripts</a>
                                        </li>
                                    </ul>
                                </li>
                            </ul>
                        </li>
                        <li class="col-md-3" data-mega-col="col-md-3">
                            <ul class="drilldown-menu">
                                <li class="menu-list">
                                    <ul class="mega-menu-sub">
                                        <li>
                                            <a class="dropdown-item" href="@Url.Action("AddScript","Script")">Add Scripts</a>
                                        </li>
                                    </ul>
                                </li>
                            </ul>
                        </li>
                    </ul>
                </li>
                <li class="dropdown mega-dropdown nav-item" data-menu="megamenu">
                    <a class="dropdown-toggle nav-link mx-1" href="#" data-toggle="dropdown"><i class="ft-radio"></i><span>Signals</span></a>
                    <ul class="mega-dropdown-menu dropdown-menu row">
                        <li class="col-md-3" data-mega-col="col-md-3">
                            <ul class="drilldown-menu">
                                <li class="menu-list">
                                    <ul class="mega-menu-sub">
                                        <li>
                                            <a class="dropdown-item" href="@Url.Action("ViewSignals", "Signal")">View Signals</a>
                                        </li>
                                    </ul>
                                </li>
                            </ul>
                        </li>
                        <li class="col-md-3" data-mega-col="col-md-3">
                            <ul class="drilldown-menu">
                                <li class="menu-list">
                                    <ul class="mega-menu-sub">
                                        <li>
                                            <a class="dropdown-item" href="@Url.Action("AddSignal", "Signal")">Add Signals</a>
                                        </li>
                                    </ul>
                                </li>
                            </ul>
                        </li>
                    </ul>
                </li>
                <li class="dropdown mega-dropdown nav-item" data-menu="megamenu">
                    <a class="dropdown-toggle nav-link mx-1" href="#" data-toggle="dropdown"><i class="fa fa-address-book"></i><span>Templates</span></a>
                    <ul class="mega-dropdown-menu dropdown-menu row">
                        <li class="col-md-3" data-mega-col="col-md-3">
                            <ul class="drilldown-menu">
                                <li class="menu-list">
                                    <ul class="mega-menu-sub">
                                        <li>
                                            <a class="dropdown-item" href="@Url.Action("ViewTemplates", "Template")">View Templates</a>
                                        </li>
                                    </ul>
                                </li>
                            </ul>
                        </li>
                        <li class="col-md-3" data-mega-col="col-md-3">
                            <ul class="drilldown-menu">
                                <li class="menu-list">
                                    <ul class="mega-menu-sub">
                                        <li>
                                            <a class="dropdown-item" href="@Url.Action("AddTemplate", "Template")">Add Templates</a>
                                        </li>
                                    </ul>
                                </li>
                            </ul>
                        </li>
                    </ul>
                </li>
            </ul>
        </div>
        <!-- /horizontal menu content-->
    </div>
    <!-- Horizontal navigation-->
    <partial name="_CookieConsentPartial" />
    <div class="pb-3">
        @RenderBody()
    </div>
    <!-- ////////////////////////////////////////////////////////////////////////////-->
    <footer class="footer fixed-bottom footer-light footer-border">
        <div class="clearfix blue-grey lighten-2 text-sm-center mb-0 px-2 container center-layout">
            <div class="float-md-left d-block d-md-inline-block copyright">Copyright  &copy; @DateTime.Today.Date.Year.ToString() Empowered Forex Trader - All rights reserved. </div>
        </div>
    </footer>
    <script src="~/js/jquery-3.3.1.js"></script>
    <script src="~/js/vendor.js"></script>
    <script type="text/javascript" src="~/js/jquery.sticky.js"></script>
    <script src="~/js/unslider-min.js"></script>
    <link rel="stylesheet" type="text/css" href="~/css/palette-climacon.css">
    <link rel="stylesheet" type="text/css" href="~/fonts/simple-line-icons/style.min.css">
    <script src="~/js/icheck.min.js"></script>
    <script src="~/js/moment-with-locales.min.js"></script>
    <script src="~/js/jqBootstrapValidation.js"></script>
    <script src="~/js/bootstrap-datetimepicker.min.js"></script>
    <script src="~/js/jquery.unobtrusive-ajax.min.js"></script>
    <script src="~/js/toastr.min.js"></script>
    <script src="~/js/app-menu.js"></script>
    <script src="~/js/app.js"></script>
    <script src="~/js/site.js"></script>
    <script type="text/javascript">
        $(document).ready(function () {

            var success = null;
            var error = null;
            error = '@ViewBag.Error'
            success = '@ViewBag.Success';

            if (success != '') {
                toastr.success(success, '@ViewData["Title"] | Empowered Forex Trader');
            }
            else if (error != '') {
                toastr.error(error, '@ViewData["Title"] | Empowered Forex Trader');
            }

            $(".checkbox_expert").click(function () {
                $.ajax({
                    url: '/ExpertAdvisor/ToggleExpertAdvisor',
                    type: 'POST',
                    data: { id: $(this).attr('id') }

                });
            });

            $(".checkbox_scripts").click(function () {
                $.ajax({
                    url: '/Script/ToggleScript',
                    type: 'POST',
                    data: { id: $(this).attr('id') }

                });
            });

            $(".checkbox_signal").click(function () {
                $.ajax({
                    url: '/Signal/ToggleSignal',
                    type: 'POST',
                    data: { signalId: $(this).attr('id') }

                });
            });

        });


        /* Template Helper Functions */
         function toggleTemplate(_templateId) {
            $.ajax({
                type: "post",
                url: '@Url.Action("ToggleTemplate", "Template")',
                data: { id: _templateId },
                cache: false,
                success: function (result) {
                    window.location.reload();
                },
            });
        }


    </script>
</body>
</html>