@using PantheonRA.BackOffice.Enums

<input type="hidden" id="cancelLoc" value="@Loc.Cancel" />
<input type="hidden" id="deleteLoc" value="@Loc.Delete" />
<input type="hidden" id="closeLoc" value="@Loc.Close" />
<input type="hidden" id="deleteWholeDocumentIsNotLastOneLoc" value="@Loc.DeleteWholeDocumentIsNotLastOne" />

<div class="modal inmodal fade modal-z-index-3000" id="deleteWarningModal" tabindex="-1" role="dialog" aria-hidden="true" data-keyboard="false" data-backdrop="static">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-body">
                <div class="row">
                    <div class="col-xs-11">
                        <span id="deleteWarningMessage"></span>
                    </div>
                    <div class="col-xs-1 text-right">
                        <i class="fa fa-times clickable-icon" data-dismiss="modal" title="@Loc.Close"></i>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-t-sm m-b-sm" data-dismiss="modal" id="cancelDeleteDocument">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.Abandon</strong>
                            <p class="no-margins">@Loc.AbandonActionAndContinue</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" data-dismiss="modal" id="continueDeleteDocument" onclick="continueDelete()">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10">
                            <strong>@Loc.Continue</strong>
                            <p class="no-margins">@Loc.ContinueAndChangeOrDeleteDocument</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" data-dismiss="modal" id="continueAndDeleteBPBIDocuments" onclick="" hidden>
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10">
                            <strong>@Loc.ContinueAndDeleteBPBI</strong>
                            <p class="no-margins">@Loc.ContinueAndDeleteBPBIText</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" onclick="openDeleteWarningHelp()">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-help icon-full-size"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.ViewInstructions</strong>
                            <p class="no-margins">@Loc.ViewInstructionsDescription</p>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<div class="modal inmodal fade" id="deleteOrderWarningModal" tabindex="-1" role="dialog" aria-hidden="true" data-keyboard="false" data-backdrop="static">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-body">
                <div class="row">
                    <div class="col-xs-11">
                        <span id="deleteOrderWarningMessage"></span>
                    </div>
                    <div class="col-xs-1 text-right">
                        <i class="fa fa-times clickable-icon" data-dismiss="modal" title="@Loc.Close"></i>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-t-sm m-b-sm" data-dismiss="modal" id="cancelDeleteDocument">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.Abandon</strong>
                            <p class="no-margins">@Loc.AbandonActionAndContinue</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" data-dismiss="modal" id="continueOrderDeleteDocument" onclick="continueOrderDelete(false)">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10">
                            <strong>@Loc.Continue</strong>
                            <p class="no-margins">@Loc.ContinueAndChangeOrDeleteDocument</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" data-dismiss="modal" id="continueOrderDeleteBPBIDocument" onclick="continueOrderDelete(true)">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10">
                            <strong>@Loc.ContinueAndDeleteBPBI</strong>
                            <p class="no-margins">@Loc.ContinueAndDeleteBPBIText</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" onclick="openDeleteWarningHelp()">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-help icon-full-size"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.ViewInstructions</strong>
                            <p class="no-margins">@Loc.ViewInstructionsDescription</p>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<div class="modal inmodal fade" id="deleteNotPossibleModal" tabindex="-1" role="dialog" aria-hidden="true" data-keyboard="false" data-backdrop="static">
    <div class="modal-dialog modal-50" role="document">
        <div class="modal-content">
            <div class="modal-body text-center">
                <div class="row">
                    <div class="col-xs-offset-3 col-xs-6">
                        <div class="icon-remove-file icon-lg m-b-sm"></div>
                    </div>
                </div>
                <div class="row m-t-sm">
                    <span id="deleteNotPossibleMessage"></span>
                </div>
                <div class="row m-t-sm">
                    <button type="button" class="btn btn-primary" data-dismiss="modal"><i class="fa fa-check m-r-xs"></i>@Loc.Close</button>
                </div>
            </div>
        </div>
    </div>
</div>

<div class="modal inmodal fade" id="deleteNotLastDocModal" tabindex="-1" role="dialog" aria-hidden="true" data-keyboard="false" data-backdrop="static">
    <div class="modal-dialog modal-50" role="document">
        <div class="modal-content">
            <div class="modal-body text-center">
                <div class="row">
                    <div class="col-xs-offset-3 col-xs-6">
                        <div class="icon-remove-file icon-lg m-b-sm"></div>
                    </div>
                </div>
                <div class="row m-t-sm">
                    <span>@Loc.DeleteWholeDocumentIsNotLastOne</span>
                </div>
                <div class="row m-t-sm">
                    <button type="button" class="btn btn-primary btn-outline" data-dismiss="modal"><i class="fa fa-times"></i><span class="m-l-xs">@Loc.Cancel</span></button>
                    <button type="button" class="btn btn-primary" data-dismiss="modal" onclick="deleteNotLastDoc()"><i class="fa fa-check m-r-xs"></i>@Loc.Delete</button>
                </div>
            </div>
        </div>
    </div>
</div>

<div class="modal inmodal fade" id="deleteInternalDocWarningModal" tabindex="-1" role="dialog" aria-hidden="true" data-keyboard="false" data-backdrop="static">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-body">
                <span id="deleteInternalDocWarningMessage"></span>
                <div class="well well-sm well-bg clickable-icon m-t-sm m-b-sm" data-dismiss="modal" id="cancelDeleteInternalDocument" title="@Loc.Close">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.CancelDeleteInternalDocument</strong>
                            <p class="no-margins">@Loc.AbandonChangeOrDeleteInternalDocument</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" data-dismiss="modal" id="continueDeleteInternalDoc" onclick="deleteWithInternalDoc()">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.Continue</strong>
                            <p class="no-margins">@Loc.ContinueChangeOrDeleteDocument</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" onclick="openDeleteWarningHelp()">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-help icon-full-size"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.ViewInstructions</strong>
                            <p class="no-margins">@Loc.ViewInstructionsDescription</p>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<div class="modal inmodal fade" id="deleteWarningPlanItemsModal" tabindex="-1" role="dialog" aria-hidden="true" data-keyboard="false" data-backdrop="static">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-body">
                <div class="iris-title m-b-sm">
                    <div class="row">
                        <div class="col-xs-11 padding-right-none">
                            <span><strong>@Loc.OrderIdentChangeNotAllowed</strong></span>
                        </div>
                        <div class="col-xs-1 pull-right">
                            <i class="fa fa-times clickable-icon m-l-xs" data-dismiss="modal" title="@Loc.Close"></i>
                        </div>
                    </div>
                </div>
                <span>@Loc.OrderIdentsAreConnectedToPlan</span>
                <div class="row m-t-sm">
                    <div class="col-xs-12">
                        <div class="project-list">
                            <table id="planItemsGrid" class="list-table">
                                <thead>
                                    <tr>
                                        <th width="75%">@Loc.AcKey</th>
                                        <th width="25%">@Loc.PositionShort</th>
                                    </tr>
                                </thead>
                            </table>
                        </div>
                    </div>
                </div>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-primary m-r-md" data-dismiss="modal"><i class="fa fa-check m-r-xs"></i>@Loc.Close</button>
            </div>
        </div>
    </div>
</div>

<div class="modal inmodal fade" id="documentFiscalizedCannotDeleteWarningModal" tabindex="-1" role="dialog" aria-hidden="true" data-keyboard="false" data-backdrop="static" style="z-index: 2051 !important;">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-body">
                <div class="iris-title m-b-sm">
                    <div class="row">
                        <div class="col-xs-11 padding-right-none">
                            <span><strong>IRIS 1005460 - @Loc.CannotDeleteOrChangeFiscalizedDocument</strong></span>
                        </div>
                        <div class="col-xs-1 pull-right">
                            <i class="fa fa-times clickable-icon m-l-xs" data-dismiss="modal" title="@Loc.Close"></i>
                        </div>
                    </div>
                </div>
                <span>@Loc.CannotDeleteOrChangeFiscalizedDocument</span>
                <div class="well well-sm well-bg clickable-icon m-t-sm m-b-sm" data-dismiss="modal" id="cancelDeleteFiscalizedDocument">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.Abandon</strong>
                            <p class="no-margins">@Loc.CannotDeleteOrChangeFiscalizedDocument</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" onclick="window.open('@Loc.HelpUrl@HelpIds.FiscalizedDocumentCannotDelete', '_blank')">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.ViewInstructions</strong>
                            <p class="no-margins">@Loc.ViewInstructionsDescription</p>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>

<div class="modal inmodal fade modal-z-index-3000" id="invoiceHasAdvancePaymentConnectionsModal" tabindex="-1" role="dialog" aria-hidden="true" data-keyboard="false" data-backdrop="static">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-body">
                <div class="iris-title m-b-sm">
                    <div class="row">
                        <div class="col-xs-11 padding-right-none">
                            <strong><span id="invoiceHasAdvancePaymentConnectionsModalTitle"></span></strong>
                        </div>
                        <div class="col-xs-1 pull-right">
                            <i class="fa fa-times clickable-icon m-l-xs" data-dismiss="modal" title="@Loc.Close"></i>
                        </div>
                    </div>
                </div>
                <span id="invoiceHasAdvancePaymentConnectionsModalMsg"></span>
                <div class="well well-sm well-bg clickable-icon m-t-sm m-b-sm" data-dismiss="modal" id="cancelConnectionWithOriginalDocument">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.CancelConnectionWithOriginalDocument</strong>
                            <p class="no-margins">@Loc.AdvancePaymentCancelConnectionWithOriginalDocument</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-t-sm m-b-sm" data-dismiss="modal" id="continueInvoiceHasAdvancePaymentConnections">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.Continue</strong>
                            <p class="no-margins">@Loc.ContinueWithWork</p>
                        </div>
                    </div>
                </div>
                <div class="well well-sm well-bg clickable-icon m-b-sm" onclick="window.open('@SiteHelpAttributeHelper.GetHelpUrl(HelpIds.MoveHasConnectedAdvancePayment)', '_blank')">
                    <div class="row">
                        <div class="col-xs-2">
                            <div class="icon-arrow-right"></div>
                        </div>
                        <div class="col-xs-10 well-text-margin">
                            <strong>@Loc.ViewInstructions</strong>
                            <p class="no-margins">@Loc.ViewInstructionsDescription</p>
                        </div>
                    </div>
                </div>
            </div>
        </div>
    </div>
</div>