Mr.Combet Webshell
Your IP :
216.73.216.136
Server IP :
103.233.58.157
Server :
Windows NT WIN-4PGF72KEHKB 10.0 build 17763 (Windows Server 2016) AMD64
Server Software :
Microsoft-IIS/10.0
PHP Version :
7.3.25
Add File :
Submit
Add Directory :
Submit
Dir :
C:
/
inetpub
/
wwwroot
/
mapqa
/
Views
/
Groups
/
View File Name :
Create.cshtml
@{ ViewBag.Title = "IFF Create"; Layout = "~/Views/Shared/_Layout.cshtml"; } @model RER_Project.DataAccess.ViewModels.Groups.GroupsViewModel <div class="row wrapper border-bottom white-bg page-heading"> <div class="col-md-8"> <ol class="breadcrumb"> <li class="active"> <strong>Create IFF</strong> </li> </ol> </div> </div> <div class="wrapper wrapper-content animated fadeInRight"> <div class="row"> <div class="col-lg-12"> <div class="ibox float-e-margins"> <div class="ibox-content"> <label style="font-size: medium"><b>Create</b></label> <hr /> <form id="CreateGroupForm"> <div id="eror_msg"></div> <div class="row"> <div class="form-group col-md-6"> <label><strong>Province</strong></label> <select type="text" class="form-control required" name="ProvinceId" id="ProvinceId" data-api="/province/select/threeStates"></select> </div> <div class="form-group col-md-6"> <label><strong>Atoll:</strong></label> <select type="text" class="form-control required" name="DistrictId" id="DistrictId" data-api="/districts/select" disabled=""></select> </div> </div> <div class="row"> <div class="form-group col-md-6"> <label><strong>Island:</strong></label> <select type="text" class="form-control required" id="MunicipalityId" name="MunicipalityId" data-api="/municipality/select" disabled=""></select> </div> @* <div class="form-group col-md-6"> <label><strong>Ward No</strong></label> <input pattern="\d*" oninput="validity.valid||(value='');" class="required form-control" id="WardNo" name="Ward" min="1" /> </div>*@ </div> <!--<div class="row">--> @* <div class="form-group col-md-6"> <label><strong>Settlement</strong></label> <input type="text" class="form-control" id="Settlement" name="Settlement" /> </div>*@ @*<div class="form-group col-md-6"> <label><strong>Group No</strong></label> <input pattern="\d*" oninput="validity.valid||(value='');" step="1" type="text" class="required form-control" id="GroupNo" name="GroupNo" /> </div>*@ <!--</div>--> <div class="row"> <div class="form-group col-md-6"> <label><strong>IFF Name</strong> </label> <input type="text" class="required form-control" id="GroupName" name="GroupName" /> </div> <div class="form-group col-md-6"> <label><strong>Contact Person Name</strong></label> <input type="text" class="required form-control" id="ContactPerson" name="ContactPerson" /> </div> @* <div class="form-group col-md-6"> <label><strong>Number of Beneficiary</strong></label> <input type="text" maxlength="4" pattern="\d*" oninput="validity.valid||(value='');" class="required form-control" id="BeneficiaryNo" name="BeneficiariesNo" /> </div>*@ </div> <!--<div class="row">--> @*<div class="form-group col-md-6"> <label><strong>Commodity</strong></label> <select type="text" class="form-control required" id="CommodityId" name="CommodityId" data-api="/commodity/select"></select> </div>*@ @*<div class="form-group col-md-6"> <label><strong>Contact Person Name</strong></label> <input type="text" class="required form-control" id="ContactPerson" name="ContactPerson" /> </div>*@ <!--</div>--> <div class="row"> @*<div class="form-group col-md-6"> <label><strong>Investment Option</strong> </label> <select type="text" class="form-control required" id="InvestmentOptionId" name="InvestmentOptionId" data-api="/investment-option/select" onchange="showDiv(this)"></select> </div>*@ <div class="form-group col-md-6"> <label><strong>Contact Person Number</strong></label> <input pattern="\d*" maxlength="10" oninput="validity.valid||(value='');" step="1" type="text" class="required form-control" id="ContactNo" name="ContactNo" min="0" /> </div> <div class="form-group col-md-6"> <label><strong>Date</strong></label> <input type="date" class="form-control" id="EnglishDate" name="EnglishDate"> </div> </div> <div class="row"> @* <div class="form-group col-md-6"> <label><strong>B.S.</strong></label> <input type="text" class="form-control required" id="nepaliDatePickcer"> <input type="text" style="display:none" class="form-control" id="to-picker"> </div>*@ </div> @*<input type="hidden" id="nepaliDate" name="NepaliDate" /> <input type="hidden" id="realEnglishDate" name="EnglishDate" /> <input type="hidden" id="IsWindowsLocking" name="WindowsInvestmentName" />*@ @*</form>*@ @*<form id="CreateWindowInvestementOption">*@ <!--<div class="row" id="windowInvestment" hidden> <div class="form-group col-md-6"> <strong><label id="lblwindowInvestment"> Window Investment </label></strong> </div> <div class="form-group col-md-12"> <table id="tb" class="table table-striped table-bordered"> <thead> <tr> <th> <span id="lblGroupType"> </span> </th> <th> Samriddhi Grant </th> <th class="palikaOShowHide"> Palika / O </th> <th> Proposed Amount </th> </tr> </thead> <tbody> <tr>--> @*<td> <select type="text" class="form-control required" id="CommodityId" name="CommodityId" data-api="/commodity/select"></select> </td>*@ <!--<td> <div class="inputWithIcon"> <input type="text" class="curr form-control required currencyFormatter" onkeypress="return isNumberKey(this,event)" maxlength="11" name="GroupCo" id="GroupCo"> <span><strong>Rs</strong></span> </div>--> @*<input onkeypress="return isNumberKey(event)" type="text" maxlength="7" id="GroupCo" class="form-control" name="GroupCo" />*@ <!--</td> <td> <div class="inputWithIcon"> <input type="text" class="curr form-control required currencyFormatter" onkeypress="return isNumberKey(this,event)" maxlength="11" name="Samriddhi" id="Samriddhi"> <span><strong>Rs</strong></span> </div>--> @* <input onkeypress="return isNumberKey(event)" type="text" maxlength="7" id="Samriddhi" class="form-control" name="Samriddhi" />*@ <!--</td> <td class="palikaOShowHide"> <div class="inputWithIcon"> <input type="text" class="curr form-control palikaOShowHide currencyFormatter" onkeypress="return isNumberKey(this,event)" maxlength="11" name="PalikaO" id="PalikaO"> <span><strong>Rs</strong></span> </div>--> @* <input onkeypress="return isNumberKey(event)" maxlength="7" type="text" id="PalikaO" class="form-control palikaOShowHide" name="PalikaO" />*@ <!--</td> <td> <div class="inputWithIcon"> <input type="text" class="curr form-control required currencyFormatter" disabled onkeypress="return isNumberKey(this,event)" maxlength="11" name="ProposedGrant" id="ProposedGrant"> <span><strong>Rs</strong></span> </div>--> @*<input onkeypress="return isNumberKey(event)" type="text" maxlength="7" id="ProposedGrant" class="form-control" name="ProposedGrant" />*@ <!--</td> </tr> </tbody> </table> </div> </div>--> <!--<div class="row" id="window1AndUnLocking" hidden> <div class="form-group col-md-6"> <strong><label> Window 1(Unlocking)Investment </label></strong> </div> <div class="form-group col-md-12"> <table id="tb1" class="table table-striped table-bordered"> <thead> <tr> <th> Group / Co </th> <th> Samriddhi Grant </th> <th class="palikaOShowHide"> Palika / O </th> <th> Proposed Amount </th> </tr> </thead> <tbody> <tr> <td> <div class="inputWithIcon"> <input type="text" class="curr form-control required currencyFormatter" onkeypress="return isNumberKey(this,event)" maxlength="11" name="GroupCo" id="GroupCo2"> <span><strong>Rs</strong></span> </div>--> @* <input onkeypress="return isNumberKey(event)" type="text" maxlength="7" class="form-control" id="GroupCo2" name="GroupCo" />*@ <!--</td> <td> <div class="inputWithIcon"> <input type="text" class="curr form-control required currencyFormatter" onkeypress="return isNumberKey(this,event)" maxlength="11" name="Samriddhi" id="Samriddhi2"> <span><strong>Rs</strong></span> </div>--> @* <input onkeypress="return isNumberKey(event)" type="text" maxlength="7" class="form-control" id="Samriddhi2" name="Samriddhi" />*@ <!--</td> <td class="palikaOShowHide"> <div class="inputWithIcon"> <input type="text" class="curr form-control required currencyFormatter" onkeypress="return isNumberKey(this,event)" maxlength="11" name="PalikaO" id="PalikaO2"> <span><strong>Rs</strong></span> </div>--> @* <input onkeypress="return isNumberKey(event)" type="text" class="form-control " id="PalikaO2" name="PalikaO" />*@ <!--</td> <td> <div class="inputWithIcon"> <input type="text" class="curr form-control required currencyFormatter" disabled onkeypress="return isNumberKey(this,event)" maxlength="11" name="ProposedGrant" id="ProposedGrant2"> <span><strong>Rs</strong></span> </div>--> @* <input onkeypress="return isNumberKey(event)" type="text" maxlength="7" class="form-control" id="ProposedGrant2" name="ProposedGrant" />*@ <!--</td> </tr> </tbody> </table> </div> </div>--> </form> @*<div class="row"> <div class="form-group col-md-6"> <label><strong>B.S.</strong></label> <input type="text" class="form-control required" id="nepaliDatePickcer"> <input type="text" style="display:none" class="form-control" id="to-picker"> </div> <div class="form-group col-md-6"> <label><strong>A.D.</strong></label> <input type="text" class="form-control" id="englishDate" disabled=""> </div> </div>*@ <div class="row"> <div class="form-group col-md-2 pull-right"> <input type="button" value="Save" class="btn btn-primary" id="SubmitButton" /><span> </span> <a href="/groups" class="btn btn-default">Back</a> </div> </div> </div> </div> </div> </div> </div> <script src="~/Scripts/jquery.min.js"></script> <script src="~/Scripts/NepaliDatePicker/jquery.nepaliDatePicker.min.js"></script> <link href="~/Content/NepaliDatePicker/nepaliDatePicker.min.css" rel="stylesheet" /> <script> $(document).ready(function () { window.initializeSelectApis(); window.initializeCascadeLocation(); }) @*function showDiv(select) { $("#lblGroupType").text("Group / Co (Rs)"); if (select.value == 4) { $("#lblGroupType").text("Service Provider (Rs)"); $("#PalikaO").show(); } if (select.value == 5) { $("#lblGroupType").text("Trader (Rs)"); $("#PalikaO").hide(); $(".palikaOShowHide").hide(); } if (select.value == 6) { $("#lblGroupType").text("Company"); $("#PalikaO").hide(); $(".palikaOShowHide").hide(); } if (select.value == 3) { $("#lblwindowInvestment").text("Window 1 Investment"); $("#window1AndUnLocking").show(); $("#PalikaO").show(); $(".palikaOShowHide").show(); } else { $("#window1AndUnLocking").hide(); } if (select.value == 1 || select.value == 2) { $("#PalikaO").show(); $(".palikaOShowHide").show(); } if (select.value == "") { $("#windowInvestment").hide(); resetField(); } else { $("#windowInvestment").show(); } }*@ @*function resetField() { document.getElementById('ProposedGrant').value = ""; document.getElementById('GroupCo').value = ""; document.getElementById('Samriddhi').value = ""; document.getElementById('PalikaO').value = ""; $('#CommodityId').get(0).selectedIndex = 0; }*@ $("#CommodityId").on("change", function () { var commodity = $("#CommodityId option:selected").text(); $("#selectedCommodityval").val($("#CommodityId option:selected").val()); if ($("#CommodityId option:selected").val() == "") { $("#selectedCommodity").text(""); } else { $("#selectedCommodity").text(commodity); } }) @*var currentDate = new Date(); var currentNepaliDate = calendarFunctions.getBsDateByAdDate(currentDate.getFullYear(), currentDate.getMonth() + 1, currentDate.getDate()); var formatedNepaliDate = calendarFunctions.bsDateFormat("%y-%M-%d", currentNepaliDate.bsYear, currentNepaliDate.bsMonth, currentNepaliDate.bsDate); var threeMonthAgo = new Date(new Date().getFullYear(), new Date().getMonth() - 3, new Date().getDate()); var get3MonthOldNepaliDate = calendarFunctions.getBsDateByAdDate(threeMonthAgo.getFullYear(), threeMonthAgo.getMonth() + 1, threeMonthAgo.getDate()); var get3MonthOldformatedNepaliDate = calendarFunctions.bsDateFormat("%y-%M-%d", get3MonthOldNepaliDate.bsYear, get3MonthOldNepaliDate.bsMonth, get3MonthOldNepaliDate.bsDate); $("#nepaliDatePickcer").nepaliDatePicker({ dateFormat: "%y-%M-%d", closeOnDateSelect: true, minDate: get3MonthOldformatedNepaliDate, maxDate: formatedNepaliDate }); $("#nepaliDatePickcer").on("dateSelect", function (event) { var datePickerData = event.datePickerData; $("#realEnglishDate").val(datePickerData.adDate.toLocaleDateString()); $("#englishDate").val(datePickerData.adDate.toLocaleDateString()); debugger; $("#nepaliDate").val(datePickerData.bsYear + "-" + datePickerData.bsMonth + "-" + datePickerData.bsDate); //$("#nepaliDatePickcer").calendarFunctions.bsDateFormat("%y %m, %d %D", 2074, 11, 9); })*@ @*$("#GroupCo").bind("change paste keyup", function () { var groupCo = removeCommaFromString($('#GroupCo').val()); var palikaO = removeCommaFromString($('#PalikaO').val()); var samriddhi = removeCommaFromString($('#Samriddhi').val()); var total = groupCo + palikaO + samriddhi; $('#ProposedGrant').val(getNumberWithComma(total)); }) $("#Samriddhi").bind("change paste keyup", function () { var groupCo = removeCommaFromString($('#GroupCo').val()); var palikaO = removeCommaFromString($('#PalikaO').val()); var samriddhi = removeCommaFromString($('#Samriddhi').val()); var total = groupCo + palikaO + samriddhi; $('#ProposedGrant').val(getNumberWithComma(total)); }) $("#PalikaO").bind("change paste keyup", function () { var groupCo = removeCommaFromString($('#GroupCo').val()); var palikaO = removeCommaFromString($('#PalikaO').val()); var samriddhi = removeCommaFromString($('#Samriddhi').val()); var total = groupCo + palikaO + samriddhi; $('#ProposedGrant').val(getNumberWithComma(total)); }) $("#GroupCo2").bind("change paste keyup", function () { var groupCo = removeCommaFromString($('#GroupCo2').val()); var palikaO = removeCommaFromString($('#PalikaO2').val()); var samriddhi = removeCommaFromString($('#Samriddhi2').val()); var total = groupCo + palikaO + samriddhi; $('#ProposedGrant2').val(getNumberWithComma(total)); }) $("#Samriddhi2").bind("change paste keyup", function () { var groupCo = removeCommaFromString($('#GroupCo2').val()); var palikaO = removeCommaFromString($('#PalikaO2').val()); var samriddhi = removeCommaFromString($('#Samriddhi2').val()); var total = groupCo + palikaO + samriddhi; $('#ProposedGrant2').val(getNumberWithComma(total)); }) $("#PalikaO2").bind("change paste keyup", function () { var groupCo = removeCommaFromString($('#GroupCo2').val()); var palikaO = removeCommaFromString($('#PalikaO2').val()); var samriddhi = removeCommaFromString($('#Samriddhi2').val()); var total = groupCo + palikaO + samriddhi; $('#ProposedGrant2').val(getNumberWithComma(total)); }) *@ $("#SubmitButton").off("click").on("click", function () { function request(model) { const url = "/group/create"; const data = JSON.stringify(model); return window.getAjaxRequest(url, "POST", data); } const form = $("#CreateGroupForm"); $.validator.unobtrusive.parse(form); if (!form.valid()) { return false; }; if (!window.confirmAction()) { return; }; WorkForce.loader.show(); function getModel() { return ({ //InvestmentOption: getInvestmentOptionList(), GroupVM: window.serializeForm(form) }) } @*function getInvestmentOptionList() { var investmentOptionList = []; var optionIdVal = $("#InvestmentOptionId option:selected").val(); commodityId = document.getElementById('CommodityId').value; proposedGrant = removeCommaFromString(document.getElementById('ProposedGrant').value); groupCo = removeCommaFromString(document.getElementById('GroupCo').value); palikaO = removeCommaFromString(document.getElementById('PalikaO').value); samriddhi = removeCommaFromString(document.getElementById('Samriddhi').value); //alert(samriddhi) if (optionIdVal == 3) { proposedGrant2 = removeCommaFromString(document.getElementById('ProposedGrant2').value); groupCo2 = removeCommaFromString(document.getElementById('GroupCo2').value); palikaO2 = removeCommaFromString(document.getElementById('PalikaO2').value); windowsInvestmentName = "Windows1Unlocking"; $("#IsWindowsLocking").val("Windows1Unlocking"); samriddhi2 = removeCommaFromString(document.getElementById('Samriddhi2').value); investmentOptionList.push({ ProposedGrant: proposedGrant2, GroupCo: groupCo2, PalikaO: palikaO2, CommodityId: commodityId, WindowsInvestmentName: windowsInvestmentName, Samriddhi: samriddhi2 }); } investmentOptionList.push({ ProposedGrant: proposedGrant, GroupCo: groupCo, PalikaO: palikaO, CommodityId: commodityId, Samriddhi: samriddhi }); return investmentOptionList; }*@ const model = getModel(); debugger; const ajax = request(model); debugger; ajax.done(function (response) { WorkForce.loader.hide(); showNotification("success"); window.location = "/groups"; }); ajax.fail(function (xhr) { WorkForce.loader.hide(); ShowMessage("error", xhr.responseText); }); }) function isNumberKey(element, evt) { var charCode = (evt.which) ? evt.which : event.keyCode if (charCode > 31 && (charCode < 48 || charCode > 57) && !(charCode == 46 || charCode == 8)) return false; else { var len = $(element).val().length; var index = $(element).val().indexOf('.'); if (index > 0 && charCode == 46) { return false; } if (index > 0) { var CharAfterdot = (len + 1) - index; if (CharAfterdot > 3) { return false; } } } return true; } function getNumberWithComma(value) { return Number(parseFloat(value).toFixed(2)).toLocaleString("en-IN", { minimumFractionDigits: 0 }) } function removeCommaFromString(value) { if (value == 0) { return 0; } value = (value == '') ? 0 : value; return parseFloat(value.replace(/,/g, '')); } </script>