{"version":3,"file":"main.bundle.js","sources":["../../js/app/extension.js","../../js/app/header-spa.js","../../js/app/header.js","../../js/app/payment.js","../../js/app/registration.js"],"sourcesContent":["$().ready(function () {\r\n\t$(function () {\r\n\t\tif ($(\"#ProjectExpired\").length && $(\"#ProjectExpired\").val()?.toLowerCase() === \"true\") {\r\n\t\t\t$(\"#maincontainer\").find(\"input, button, submit, textarea, select\").attr(\"disabled\", \"disabled\");\r\n\t\t}\r\n\t})\r\n\r\n\t$(\"#ddlExtnProjects\").change(function () {\r\n\t\t$(\"#btnExtnSubmit\").prop('disabled', true);\r\n\t\tvar proj = $(this).val();\r\n\t\tif (proj != \"\") {\r\n\t\t\t$.ajax({\r\n\t\t\t\turl: \"/extension/getdetail\",\r\n\t\t\t\ttype: 'POST',\r\n\t\t\t\tdata: {\r\n\t\t\t\t\tprojectID: $(this).val(),\r\n\t\t\t\t},\r\n\t\t\t\tsuccess: function (result) {\r\n\t\t\t\t\tif (result.EligibleForExtension) {\r\n\t\t\t\t\t\t//alert(result.RFQnumber);\r\n\t\t\t\t\t\t$(\"#RFQNum\").val(result.RFQnumber);\r\n\t\t\t\t\t\t$(\"#btnExtnSubmit\").removeAttr(\"disabled\");\r\n\t\t\t\t\t} else {\r\n\t\t\t\t\t\talert(\"'\" + result.ProjectName + \"' is not eligible for extension. Projects can only be extended within 10 days of expiry date.\");\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\t})\r\n\r\n\t$(\"#btnExtnSubmit\").click(function () {\r\n\t\t$(\"#RFQNum\").removeAttr(\"disabled\");\r\n\t})\r\n})","jQuery.noConflict();\r\n(function ($) {\r\n\t$(function () {\r\n\t\t// bind search\r\n\t\t\r\n\t\tvar bottomMenu = $(\".menuBottomRow\");\r\n\t\tvar origOffsetY = bottomMenu ? bottomMenu.offset().top : 0;\r\n\r\n\t\tfunction scroll() {\r\n\t\t\tvar sticky = true;\r\n\t\t\tif (typeof usePartialStickyMenu != \"undefined\") {\r\n\t\t\t\tsticky = usePartialStickyMenu;\r\n\t\t\t}\r\n\t\t\tif (sticky) {\r\n\t\t\t\tif ($(window).scrollTop() >= origOffsetY) {\r\n\t\t\t\t\t$(\".menuBottomRow\").addClass(\"sticky\");\r\n\t\t\t\t\t$(\".content\").addClass(\"menu-padding\");\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$(\".menuBottomRow\").removeClass(\"sticky\");\r\n\t\t\t\t\t$(\".content\").removeClass(\"menu-padding\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\tdocument.onscroll = scroll;\r\n\r\n\t\t//Navigation Menu Slider\r\n\t\t$(\"#nav-expander\").on(\"click\", function (e) {\r\n\t\t\te.preventDefault();\r\n\t\t\t$(\"body\").toggleClass(\"nav-expanded\");\r\n\t\t});\r\n\t\t$(\"#nav-close\").on(\"click\", function (e) {\r\n\t\t\te.preventDefault();\r\n\t\t\t$(\"body\").removeClass(\"nav-expanded\");\r\n\t\t});\r\n\t});\r\n})(jQuery);","$(function () {\r\n\t// bind search\r\n\t\r\n\tvar bottomMenu = $(\".menuBottomRow\");\r\n\tvar origOffsetY = bottomMenu ? bottomMenu.offset().top : 0;\r\n\r\n\tfunction scroll() {\r\n\t\tvar sticky = true;\r\n\t\tif (typeof usePartialStickyMenu != \"undefined\") {\r\n\t\t\tsticky = usePartialStickyMenu;\r\n\t\t}\r\n\t\tif (sticky) {\r\n\t\t\tif ($(window).scrollTop() >= origOffsetY) {\r\n\t\t\t\t$(\".menuBottomRow\").addClass(\"sticky\");\r\n\t\t\t\t$(\".content\").addClass(\"menu-padding\");\r\n\t\t\t} else {\r\n\t\t\t\t$(\".menuBottomRow\").removeClass(\"sticky\");\r\n\t\t\t\t$(\".content\").removeClass(\"menu-padding\");\r\n\t\t\t}\r\n\t\t}\r\n\t}\r\n\r\n\tdocument.onscroll = scroll;\r\n\r\n\t//Navigation Menu Slider\r\n\t$(\"#nav-expander\").on(\"click\", function (e) {\r\n\t\te.preventDefault();\r\n\t\t$(\"body\").toggleClass(\"nav-expanded\");\r\n\t});\r\n\t$(\"#nav-close\").on(\"click\", function (e) {\r\n\t\te.preventDefault();\r\n\t\t$(\"body\").removeClass(\"nav-expanded\");\r\n\t});\r\n});\r\n\r\n","$().ready(function () {\r\n\t$(\".dp\").datepicker({ dateFormat: 'mm/dd/yy' }).keydown(false);\r\n\r\n\tif ($(\"#PaymentID\").val() > 0) {\r\n\t\t$(\"#ddlPymtProjects\").prop('disabled', true);\r\n\r\n\t\tGetProjectInformation($(\"#ddlPymtProjects\").val());\r\n\t\t$(\"#Amount\").removeAttr(\"disabled\");\r\n\r\n\t\t$(\"#PODate\").datepicker({ dateFormat: 'mm/dd/yy' }).keydown(false);\r\n\t} else {\r\n\t\t$(\"#PODate\").datepicker({ dateFormat: 'mm/dd/yy' }).keydown(false);\r\n\t\t$(\"#PODate\").datepicker('setDate', new Date());\r\n\t\t$(\".dp\").datepicker('setDate', new Date());\r\n\t}\r\n\t$('#calPODt').click(function () {\r\n\t\t$(\"#PODate\").focus();\r\n\t});\r\n\r\n\tManageAddInvoiceButton();\r\n\r\n\t$(\"#btnPymtSubmit\").on(\"click\", function () {\r\n\t\tvar errors = \"\";\r\n\t\tif ($(\"#ddlPymtProjects\").val() == \"\") {\r\n\t\t\t$(\"#ddlPymtProjects\").addClass(\"input-validation-error\");\r\n\t\t\terrors += \"Project\\n\";\r\n\t\t}\r\n\t\tif ($(\"#Amount\").val() == \"\") {\r\n\t\t\t$(\"#Amount\").addClass(\"input-validation-error\");\r\n\t\t\terrors += \"Total Revenue\\n\";\r\n\t\t}\r\n\t\telse if ($(\"#Amount\").val() == 0) {\r\n\t\t\t$(\"#Amount\").addClass(\"input-validation-error\");\r\n\t\t\terrors += \"Total Revenue > 0\\n\";\r\n\t\t}\r\n\r\n\t\tvar pofile = document.getElementById(\"POFile\");\r\n\t\tif (pofile != null && pofile.files.length > 0) {\r\n\t\t\tvar POInfo = $('[id^=PO]');\r\n\t\t\tvar POError = \"\";\r\n\t\t\tPOInfo.each(function () {\r\n\t\t\t\tif ($(this).attr(\"id\") != \"PO\" && $(this).val() == \"\") {\r\n\t\t\t\t\t$(this).addClass(\"input-validation-error\");\r\n\t\t\t\t\tPOError = \"PO information \\n\";\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t\terrors += POError;\r\n\t\t}\r\n\r\n\t\tvar InvInfo = $('[name^=Invoices]');\r\n\t\tvar InvError = \"\";\r\n\t\tInvInfo.each(function () {\r\n\t\t\tif ($(\"#PaymentID\").val() > 0 && $(this).hasClass(\"file\")) { //don't validate file on update\r\n\r\n\t\t\t} else if ($(this).val() == \"\" && !$(this).attr(\"id\").endsWith(\"invoice\")) {\r\n\t\t\t\t$(this).addClass(\"input-validation-error\");\r\n\t\t\t\tInvError = \"Invoice information\\n\";\r\n\t\t\t}\r\n\t\t});\r\n\t\terrors += InvError;\r\n\r\n\t\tif (errors != \"\") {\r\n\t\t\talert(\"Please correct the following error(s) and submit again!\\n\\n\" + errors);\r\n\t\t\treturn false;\r\n\t\t} else {\r\n\t\t\tvar validRows = $(\".payment-invoice-row\");\r\n\t\t\t$(\".dp\").removeAttr(\"readonly\");\r\n\r\n\t\t\t$(\"#ReImbursementAmount\").removeAttr(\"disabled\");\r\n\t\t\t$(\"#Amount\").removeAttr(\"disabled\");\r\n\t\t\t$(\"#ddlPymtProjects\").removeAttr(\"disabled\");\r\n\r\n\t\t\talert(\"Please note, in order to be paid out on \" + $(\"#ProgramName\").val() + \", revenue level minimums must be met.\");\r\n\t\t\treturn true;\r\n\t\t}\r\n\t});\r\n\r\n\t$('#Amount').on(\"paste\", function (e) {\r\n\t\te.preventDefault();\r\n\t});\r\n\r\n\tif ($(\"#Amount\").val() == \"0\") $(\"#Amount\").val(\"\");\r\n\tif ($(\"#ReImbursementAmount\").val() == \"0\") $(\"#ReImbursementAmount\").val(\"\");\r\n\r\n\t//var AlreadyClaimed = 0;\r\n\t$(\"#Amount\").on(\"input\", function () {\r\n\t\tCalculateAmount();\r\n\t});\r\n\r\n\t$(\"#ddlPymtProjects\").change(function () {\r\n\t\tvar proj = $(this).val();\r\n\t\t$(\"#btnPymtSubmit\").prop('disabled', false);\r\n\t\tGetProjectInformation(proj);\r\n\t});\r\n\r\n\tfunction ManageAddInvoiceButton() {\r\n\t\tvar rc = $(\"#pymtNumRows\").val() * 1;\r\n\t\tif (rc <= 2) {\r\n\t\t\t$(\".add-paymentinvoice-row\").removeAttr(\"disabled\");\r\n\t\t} else {\r\n\t\t\t$(\".add-paymentinvoice-row\").prop('disabled', true);\r\n\t\t}\r\n\t}\r\n\r\n\t$(\"body\").on(\"click\", \".delete-paymentinvoice-row\", function () {\r\n\t\tSetNumRowsForInvoice(-1);\r\n\t\t$(this).closest('tr').remove();\r\n\t\tManageAddInvoiceButton();\r\n\t});\r\n\r\n\t$(\".add-paymentinvoice-row\").click(function () {\r\n\t\tAddPaymentInvoiceRow();\r\n\t\tManageAddInvoiceButton();\r\n\t});\r\n\r\n\tfunction CheckPaymentInvoiceEntries() {\r\n\t\tvar validRows = $(\".payment-invoice-row\");\r\n\t\t$(\"#pymtNumRows\").val(validRows.length);\r\n\t\tvar IsEmpty = false;\r\n\t\tif (validRows.length > 0) {\r\n\t\t\tvalidRows.each(function () {\r\n\t\t\t\tvar input = $(this).find('input[type=\"text\"]');\r\n\t\t\t\tinput.each(function () {\r\n\t\t\t\t\tif (!$(this).val() && !$(this).hasClass(\"tt-hint\")) {\r\n\t\t\t\t\t\t$(this).addClass(\"input-validation-error\");\r\n\t\t\t\t\t\tIsEmpty = true;\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\r\n\t\t\t\tvar files = $(this).find('input[type=\"file\"]');\r\n\t\t\t\tfiles.each(function () {\r\n\t\t\t\t\tif ($(\"#PaymentID\").val() == 0 && $(this).val() == \"\") {\r\n\t\t\t\t\t\t$(this).addClass(\"input-validation-error\");\r\n\t\t\t\t\t\tIsEmpty = true;\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\r\n\t\t\t\t$(this).parents(\"tr\").find(\".input-validation-error\").first().focus();\r\n\t\t\t});\r\n\t\t}\r\n\t\treturn IsEmpty;\r\n\t}\r\n\r\n\tfunction SetNumRowsForInvoice(num) {\r\n\t\tvar rc = $(\"#pymtNumRows\").val() * 1 + num;\r\n\t\t$(\"#pymtNumRows\").val(rc);\r\n\t}\r\n\r\n\tfunction AddPaymentInvoiceRow() {\r\n\t\tvar empty = CheckPaymentInvoiceEntries();\r\n\t\t//console.log(\"empty\", empty);\r\n\t\tif (!empty) {\r\n\t\t\t//var nextIndex = $(\"table#tblInvs tbody tr\").length;\r\n\t\t\tvar nextIndex = $(\"#invRunningCount\").val() * 1 + 1;\r\n\t\t\t$(\"#invRunningCount\").val(nextIndex);\r\n\r\n\t\t\t$.ajax({\r\n\t\t\t\turl: \"/payment/addpaymentinvoicerow\",\r\n\t\t\t\ttype: 'POST',\r\n\t\t\t\tdata: { index: nextIndex },\r\n\t\t\t\tsuccess: function (results) {\r\n\t\t\t\t\t$(\"table#tblInvs tbody\").append(results);\r\n\t\t\t\t\t$(\"#Invoices_\" + nextIndex + \"__invoice\").val(\"\");\r\n\t\t\t\t\t//$(\"#Invoices_\" + nextIndex + \"__invoiceDate\").datetimepicker({ format: \"L\" }).keydown(false);\r\n\t\t\t\t\t$(\"#Invoices_\" + nextIndex + \"__invoiceDate\").datepicker({ dateFormat: 'mm/dd/yy' }).keydown(false);\r\n\t\t\t\t\t$(\"#Invoices_\" + nextIndex + \"__invoiceDate\").datepicker('setDate', new Date());\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t\tSetNumRowsForInvoice(1);\r\n\t\t}\r\n\t}\r\n})\r\n\r\nfunction CalculateAmount() {\r\n\tvar amt = $(\"#Amount\").val() * 1;\r\n\tvar maxclaim = $(\"#MaxClaim\").val() * 1;\r\n\tvar alreadyclaimed = $(\"#AlreadyClaimed\").val() * 1;\r\n\tvar allowedAmt = maxclaim - alreadyclaimed;\r\n\r\n\tvar revenuePercent = $(\"#revenuePercentage\").val()*1;\r\n\tvar call = $(\"#CallAmount\").val() * 1;\r\n\tvar meeting = $(\"#MeetingAmount\").val() * 1;\r\n\r\n\tvar reimb = \"\";\r\n\tif (amt > allowedAmt) {\r\n\t\t$(\"#Amount\").val(\"\");\r\n\t\tif (alreadyclaimed > 0) {\r\n\t\t\talert(\"Please note you must extend your current project or register a new project if the revenue amount has increased.\\n\\nYou have already claimed $\" + alreadyclaimed + \" of $\" + maxclaim + \" for this project. Remaining amount that can be claimed is $\" + (allowedAmt));\r\n\t\t} else {\r\n\t\t\talert(\"You are allowed to claim up to $\" + allowedAmt + \" only.\");\r\n\t\t}\r\n\t} else {\r\n\t\tvar reimb = (amt * (revenuePercent / 100)).toFixed(2);\r\n\t\treimb = (reimb * 1).toFixed(2);\r\n\t}\r\n\tif (reimb == 0) reimb = \"\";\r\n\t$(\"#ReImbursementAmount\").val(reimb);\r\n}\r\n\r\nfunction GetProjectInformation(proj) {\r\n\tvar amt = $(\"#Amount\").val() * 1;\r\n\tdocument.getElementById(\"divClaimBalance\").innerHTML = \"\";\r\n\tif (amt == 0) $(\"#Amount\").val(\"\");\r\n\tif ($(\"#ReImbursementAmount\").val() == 0) $(\"#ReImbursementAmount\").val(\"\");\r\n\r\n\tif (proj != \"\") {\r\n\t\tvar pymtID = $(\"#PaymentID\").val();\r\n\t\tif (pymtID == 0) CalculateAmount();\r\n\t\t\r\n\t\t$.ajax({\r\n\t\t\turl: \"/payment/getmessage\",\r\n\t\t\ttype: 'POST',\r\n\t\t\tdata: {\r\n\t\t\t\tprojectID: proj\r\n\t\t\t},\r\n\t\t\tsuccess: function (result) {\r\n\t\t\t\tif (pymtID == 0)\r\n\t\t\t\t\tAlreadyClaimed = result.AlreadyClaimed * 1;\r\n\t\t\t\telse\r\n\t\t\t\t\tAlreadyClaimed = result.AlreadyClaimed * 1 - amt * 1;\r\n\r\n\t\t\t\tMaxClaimAmt = result.MaxClaimAmt * 1;\r\n\t\t\t\t$(\"#AlreadyClaimed\").val(AlreadyClaimed);\r\n\t\t\t\t$(\"#MaxClaim\").val(MaxClaimAmt);\r\n\r\n\t\t\t\tdocument.getElementById(\"divClaimBalance\").innerHTML = result.Message;\r\n\t\t\t\tif (AlreadyClaimed > 0) { //If this is not the first payment, don't let them choose Call/Meeting\r\n\t\t\t\t\t$('input.rdo').prop('checked', false);\r\n\t\t\t\t\t$(\"input.rdo\").attr(\"disabled\", true);\r\n\t\t\t\t\t//$(\"#divclaimed\").html(\"You already Claimed $\" + AlreadyClaimed + \" for this Project\");\r\n\t\t\t\t} else {\r\n\t\t\t\t\t$(\"input.rdo\").attr(\"disabled\", false);\r\n\t\t\t\t\t//$(\"#divclaimed\").html(\"\");\r\n\t\t\t\t}\r\n\t\t\t\t//alert(AlreadyClaimed + \" :: \" + MaxClaimAmt);\r\n\t\t\t\tif (AlreadyClaimed >= MaxClaimAmt) {\r\n\r\n\t\t\t\t\t$(\"#Amount\").prop('disabled', true);\r\n\t\t\t\t\t$(\"#btnPymtSubmit\").prop('disabled', true);\r\n\t\t\t\t\talert(\"Please note you must extend your current project or register a new project if the revenue amount has increased.\");\r\n\t\t\t\t} else {\r\n\t\t\t\t\tif ($(\"#Amount\").prop('disabled'))\r\n\t\t\t\t\t\t$(\"#Amount\").removeAttr(\"disabled\");\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t});\r\n\t} else {\r\n\t\t$(\"#Amount\").prop('disabled', true);\r\n\t}\r\n\r\n\tvar paid = $(\"input:radio[name=Paid]:checked\").val();\r\n\r\n\tif (paid == \"Yes\") {\r\n\t\t$(\"#btnPymtSubmit\").attr(\"disabled\", \"disabled\");\r\n\t}\r\n}","whenAvailable(\"Bloodhound\", function () {\r\n whenAvailable(\"$\", function () {\r\n $().ready(function () {\r\n\r\n $(function () {\r\n if ($(\"#ProjectExpired\").val()?.toLowerCase() == \"true\") {\r\n $(\"#maincontainer\").find(\"input, button, submit, textarea, select\").attr(\"disabled\", \"disabled\");\r\n }\r\n\r\n var country = $(\"#Country\");\r\n // set the initial values\r\n //UpdateStates(country.val());\r\n\r\n country.change(function () {\r\n UpdateStates($(this).val(), \"\");\r\n })\r\n\r\n if ($(\"#expirydate\").val() == \"\") {\r\n $(\"#expirydate\").datepicker({ dateFormat: 'mm/dd/yy', minDate: 0 }).keydown(false);\r\n $(\"#purchasedate\").datepicker({ dateFormat: 'mm/dd/yy', minDate: 0 }).keydown(false);\r\n $(\"#installationdate\").datepicker({ dateFormat: 'mm/dd/yy', minDate: 0 }).keydown(false);\r\n $(\"#purchasedate\").datepicker('setDate', new Date());\r\n $(\"#installationdate\").datepicker('setDate', new Date());\r\n } else {\r\n $(\"#expirydate\").datepicker({ dateFormat: 'mm/dd/yy' }).keydown(false);\r\n $(\"#purchasedate\").datepicker({ dateFormat: 'mm/dd/yy' }).keydown(false);\r\n $(\"#installationdate\").datepicker({ dateFormat: 'mm/dd/yy' }).keydown(false);\r\n }\r\n\r\n $('#calPDt').click(function () {\r\n $(\"#purchasedate\").focus();\r\n });\r\n $('#calInstDt').click(function () {\r\n $(\"#installationdate\").focus();\r\n });\r\n /*$('#calExpDt').click(function () {\r\n $(\"#expirydate\").focus();\r\n });*/\r\n });\r\n\r\n $('#btnProjSubmit').click(function () {\r\n var ErrorMsg = \"\";\r\n $('#purchasedate').prop(\"disabled\", false);\r\n $('#installationdate').prop(\"disabled\", false);\r\n $(\"#purchasedate\").removeAttr(\"readonly\");\r\n $(\"#installationdate\").removeAttr(\"readonly\");\r\n $('#Status').prop(\"disabled\", false);\r\n $('#RFQNum').prop(\"disabled\", false);\r\n $('#expirydate').prop(\"disabled\", false);\r\n\r\n var Err = false;\r\n if ($(\"#ddlOppType\").val() == \"\") {\r\n Err = true;\r\n $(\"#ddlOppType\").addClass(\"input-validation-error error\");\r\n }\r\n\r\n if ($('input[name=SalesCall]:checked').length > 0) {\r\n if ($('#RepName').val() == \"\") {\r\n Err = true;\r\n $(\"#RepName\").addClass(\"input-validation-error error\");\r\n }\r\n\r\n /*var posfile = document.getElementById(\"ProofOfSaleFile\");\r\n if ((posfile == null || posfile.files.length == 0)) {\r\n Err = true;\r\n $(\"#ProofOfSaleFile\").addClass(\"input-validation-error error\");\r\n }*/\r\n }\r\n\r\n if ($(\"#Contactname\").val() == \"\" && $(\"#Contactemail\").val() == \"\") {\r\n Err = true;\r\n $(\"#Contactemail\").addClass(\"input-validation-error error\");\r\n }\r\n\r\n var ProdInfo = $('[name^=ProjectProducts]');\r\n ProdInfo.each(function () {\r\n if ($(this).val() == \"\") {\r\n $(this).addClass(\"input-validation-error\");\r\n Err = true;\r\n }\r\n else if ($(this).val() == \"0\" && $(this).attr(\"id\").endsWith(\"Quantity\")) {\r\n $(this).addClass(\"input-validation-error error\");\r\n IsEmpty = true;\r\n }\r\n });\r\n\r\n /*if (Err)\r\n return false;\r\n else*/\r\n return true;\r\n });\r\n });\r\n\r\n function UpdateStates(selectedCountry, selstate) {\r\n var state = $(\"#State\");\r\n state.children().remove();\r\n $.ajax({\r\n url: \"/getstates\",\r\n type: 'POST',\r\n data: { country: selectedCountry },\r\n success: function (results) {\r\n for (i = 0; i < results.length; i++) {\r\n var st = results[i].key;\r\n //state.append(``);\r\n if (selstate == st) {\r\n state.append(``);\r\n } else {\r\n state.append(``);\r\n }\r\n };\r\n }\r\n });\r\n }\r\n\r\n ManageDeleteButton();\r\n\r\n function SetNumRows(num) {\r\n var rc = $(\"#numRows\").val() * 1 + num;\r\n $(\"#numRows\").val(rc);\r\n }\r\n\r\n function ManageDeleteButton() {\r\n var rc = $(\"#numRows\").val() * 1;\r\n\r\n if (rc == 1) {\r\n $(\".delete-cell\").attr(\"style\", \"display:none\");\r\n } else {\r\n var validRows = $(\".delete-cell\");\r\n validRows.each(function () {\r\n $(this).attr(\"style\", \"display:''\")\r\n })\r\n }\r\n\r\n }\r\n\r\n\r\n $(\"body\").on(\"click\", \".delete-projectproduct-row\", function () {\r\n $(this).closest('tr').remove();\r\n SetNumRows(-1);\r\n ManageDeleteButton();\r\n });\r\n\r\n $(\".add-projectproduct-row\").click(function () {\r\n AddProjectProductRow();\r\n });\r\n\r\n function CheckProjectProductEntries() {\r\n var validRows = $(\".prod-reg-row\");\r\n var IsEmpty = false;\r\n if (validRows.length > 0) {\r\n validRows.each(function () {\r\n var input = $(this).find('input[type=\"text\"]');\r\n input.each(function () {\r\n\r\n if (!$(this).val() && !$(this).hasClass(\"tt-hint\")) {\r\n $(this).addClass(\"input-validation-error error\");\r\n IsEmpty = true;\r\n } else {\r\n $(this).removeClass(\"input-validation-error error\");\r\n }\r\n });\r\n $(this).parents(\"tr\").find(\".error\").first().focus();\r\n });\r\n }\r\n return IsEmpty;\r\n }\r\n\r\n function AddProjectProductRow() {\r\n var empty = CheckProjectProductEntries();\r\n //console.log(\"empty\", empty);\r\n if (!empty) {\r\n //var nextIndex = $(\"table#tblProds tbody tr\").length;\r\n var nextIndex = $(\"#runningCount\").val() * 1 + 1;\r\n $(\"#runningCount\").val(nextIndex);\r\n\r\n $.ajax({\r\n url: \"/registration/addprojectproductrow\",\r\n type: 'POST',\r\n data: { index: nextIndex },\r\n success: function (results) {\r\n $(\"table#tblProds tbody\").append(results);\r\n\r\n //$(\"#ProjectProducts_\" + nextIndex + \"__Quantity\").val(\"1\");\r\n $(\"#ProjectProducts_\" + nextIndex + \"__ModelNumber\").typeahead({\r\n highlight: true,\r\n minLength: 2\r\n }, typeaheadbountyOpts);\r\n }\r\n });\r\n SetNumRows(1);\r\n ManageDeleteButton();\r\n }\r\n }\r\n\r\n var models = new Bloodhound({\r\n datumTokenizer: Bloodhound.tokenizers.obj.whitespace('value'),\r\n queryTokenizer: Bloodhound.tokenizers.whitespace,\r\n remote: {\r\n url: '/api/verticalmarket/getproducts/%QUERY',\r\n wildcard: '%QUERY'\r\n }\r\n });\r\n models.initialize();\r\n var typeaheadbountyOpts = {\r\n name: 'models',\r\n source: models.ttAdapter(),\r\n templates: {\r\n pending: 'LOADING...',\r\n //notFound: 'NOT FOUND',\r\n },\r\n highlighter: function (item) {\r\n var regex = new RegExp('(' + this.query + ')', 'gi');\r\n return item.replace(regex, \"$1\");\r\n }\r\n };\r\n\r\n $(\".typeaheadbounty\").typeahead({\r\n highlight: true,\r\n minLength: 2\r\n }, typeaheadbountyOpts);\r\n /*.on('typeahead:selected', function (e, datum) {\r\n //console.log(\"SELECTED\", datum);\r\n })\r\n .on('change blur', function () {\r\n // Force select an item\r\n match = false;\r\n \r\n $.each(models.index.datums, function (i, item) {\r\n if ($(this).val() == item) {\r\n match = true;\r\n }\r\n });\r\n \r\n if (!match) {\r\n $(this).val('');\r\n }\r\n });*/\r\n });\r\n});"],"names":["$","proj","result","jQuery","bottomMenu","origOffsetY","scroll","sticky","e","GetProjectInformation","ManageAddInvoiceButton","errors","pofile","POInfo","POError","InvInfo","InvError","CalculateAmount","rc","SetNumRowsForInvoice","AddPaymentInvoiceRow","CheckPaymentInvoiceEntries","validRows","IsEmpty","input","files","num","empty","nextIndex","results","amt","maxclaim","alreadyclaimed","allowedAmt","revenuePercent","reimb","pymtID","paid","country","UpdateStates","ProdInfo","selectedCountry","selstate","state","st","ManageDeleteButton","SetNumRows","AddProjectProductRow","CheckProjectProductEntries","typeaheadbountyOpts","models","item","regex"],"mappings":"mHAAAA,EAAG,EAAC,MAAM,UAAY,CACrBA,EAAE,UAAY,OACTA,EAAE,iBAAiB,EAAE,UAAUA,EAAAA,EAAE,iBAAiB,EAAE,IAAK,IAA1BA,YAAAA,EAA4B,iBAAkB,QAChFA,EAAE,gBAAgB,EAAE,KAAK,yCAAyC,EAAE,KAAK,WAAY,UAAU,CAElG,CAAE,EAEDA,EAAE,kBAAkB,EAAE,OAAO,UAAY,CACxCA,EAAE,gBAAgB,EAAE,KAAK,WAAY,EAAI,EACzC,IAAIC,EAAOD,EAAE,IAAI,EAAE,IAAG,EAClBC,GAAQ,IACXD,EAAE,KAAK,CACN,IAAK,uBACL,KAAM,OACN,KAAM,CACL,UAAWA,EAAE,IAAI,EAAE,IAA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