UNPKG

ns-export

Version:
551 lines (510 loc) 21.6 kB
<html> <head> <link href="../../jquery-ui.css" rel="stylesheet"> <link href="../../schema-browser.css" rel="stylesheet"> <script src="../../javascript/jquery-1.10.2.min.js"></script> <script src="../../javascript/jquery-ui.min.js"></script> <script src="../../menudefs.js"></script> <script src="../../javascript/menubuilder.js"></script> <script> (function( $ ){ //plugin buttonset vertical $.fn.buttonsetv = function() { $(':radio, :checkbox, :button', this).wrap('<div style="margin: 1px"/>'); $(this).buttonset(); $('label:first', this).removeClass('ui-corner-left').addClass('ui-corner-top'); $('label:last', this).removeClass('ui-corner-right').addClass('ui-corner-bottom'); mw = 0; // max witdh $('label', this).each(function(index){ w = $(this).width(); if (w > mw) mw = w; }) $('label', this).each(function(index){ $(this).width(mw); }) }; })( jQuery ); function getURLParameter(name) { return decodeURIComponent((new RegExp('[?|&]' + name + '=' + '([^&;]+?)(&|#|;|$)').exec(location.search)||[,""])[1].replace(/\+/g, '%20'))||null; } </script> <style> .custom-combobox { position: relative; display: inline-block; } .custom-combobox-toggle { position: absolute; top: 0; bottom: 0; margin-left: -1px; padding: 0; /* support: IE7 */ *height: 1.7em; *top: 0.1em; } .custom-combobox-input { margin: 0; padding: 0.3em; } </style> <script> (function( $ ) { $.widget( "custom.combobox_with_optgroup", { _create: function() { this.wrapper = $( "<span>" ) .addClass( "custom-combobox" ) .insertAfter( this.element ); this.element.hide(); this._createAutocomplete(); this._createShowAllButton(); }, _createAutocomplete: function() { var selected = this.element.find( ":selected" ), value = selected.val() ? selected.text() : ""; this.input = $( "<input>" ) .appendTo( this.wrapper ) .val( value ) .attr( "title", "" ) .addClass( "custom-combobox-input ui-widget ui-widget-content ui-state-default ui-corner-left" ) .autocomplete({ delay: 0, minLength: 0, source: $.proxy( this, "_source" ) }) .tooltip({ tooltipClass: "ui-state-highlight" }) ; this._on( this.input, { autocompleteselect: function( event, ui ) { ui.item.option.selected = true; window.location.href=ui.item.href; // this._trigger( "select", event, { // item: ui.item.option // }); }, autocompletechange: "_removeIfInvalid" }); this.input.data("uiAutocomplete")._renderMenu = function(ul, items) { var self = this, currentCategory = ""; var itemCounter=100; $.each(items, function(index, item) { itemCounter=itemCounter+1; if (item.category != currentCategory) { if (item.category) { ul.append("<li class='custom-autocomplete-category'>" + item.category + "</li>"); } currentCategory = item.category; } self._renderItem= function( ul, item ) { return $( "<li>").attr("class",item.class) .append( $( "<a>" ).attr("href",item.href).text( item.label ) ) .appendTo( ul ); }; self._renderItemData(ul, item); }); }; }, _createShowAllButton: function() { var input = this.input, wasOpen = false; $( "<a>" ) .attr( "tabIndex", -1 ) .attr( "title", "Show All" ) .tooltip() .appendTo( this.wrapper ) .button({ /* icons: { primary: "ui-icon-triangle-1-s" },*/ text: false }) .removeClass( "ui-corner-all" ) .addClass( "custom-combobox-toggle ui-corner-right" ) .mousedown(function() { wasOpen = input.autocomplete( "widget" ).is( ":visible" ); }) .click(function() { input.focus(); if ( wasOpen ) { return; } input.autocomplete( "search", "" ); }); }, _source: function( request, response ) { var matcher = new RegExp( $.ui.autocomplete.escapeRegex(request.term), "i" ); response( this.element.find( "option" ).map(function() { var text = $( this ).text(); if ( this.value && ( !request.term || matcher.test(text) ) ) return { label: text, value: text, option: this, class: $(this).attr("class"), href: $(this).attr("href"), category: $(this).closest("optgroup").attr("label") }; }) ); }, _removeIfInvalid: function( event, ui ) { if ( ui.item ) { return; } var value = this.input.val(), valueLowerCase = value.toLowerCase(), valid = false; this.element.find( "option" ).each(function() { if ( $( this ).text().toLowerCase() === valueLowerCase ) { this.selected = valid = true; return false; } }); if ( valid ) { return; } this.input .val( "" ) .attr( "title", value + " not found" ) .tooltip( "open" ); this.element.val( "" ); this._delay(function() { this.input.tooltip( "close" ).attr( "title", "" ); }, 2500 ); this.input.data( "ui-autocomplete" ).term = ""; }, _destroy: function() { this.wrapper.remove(); this.element.show(); }, getInput: function(){ return this.input; } }); })( jQuery ); </script> </head> <body> <div id='header'></div> <script> $(function() { $('#header').html(createHeader('script','record__payrollitem','../..')); }); </script> <div id='leftpanel'></div> <script> $(function() { $('#leftpanel').html(createLeftPanel('script','record__payrollitem','../..')); }); </script> <script type="text/javascript"> $().ready(function(){ $(".jtable th").each(function(){ $(this).addClass("ui-state-default"); }); $(".jtable td").each(function(){ $(this).addClass("ui-widget-content"); }); }); </script> <div id="contentPanel"> <H1>Payroll Item</H1> <H3>Internal ID: payrollitem</H3> <H2>Fields</H2> <table class="jtable"> <tr><th class="rt_fname">Internal ID</th><th class="rt_ftype">Type</th><th class="rt_fdle">nlapiSubmitField</th><th class="rt_flabel">Label</th><th class="rt_freq">Required</th><th class="rt_fhelp">Help</th></tr> <tr id="field_allowbulkentry"> <td class="rt_fname">allowbulkentry</td> <td class="rt_ftype">checkbox</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Allow entry from Create Payroll</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_applylimit"> <td class="rt_fname">applylimit</td> <td class="rt_ftype">checkbox</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Apply Limit to All Employees</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_applyrate"> <td class="rt_fname">applyrate</td> <td class="rt_ftype">checkbox</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Apply Rate to All Employees</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_basedonquantity"> <td class="rt_fname">basedonquantity</td> <td class="rt_ftype">checkbox</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Based on quantity</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_defaultrate"> <td class="rt_fname">defaultrate</td> <td class="rt_ftype">rate</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Default Rate</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_employeepaid"> <td class="rt_fname">employeepaid</td> <td class="rt_ftype">checkbox</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Employee Paid</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_expenseaccount"> <td class="rt_fname">expenseaccount</td> <td class="rt_ftype">select</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Expense Account</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_externalid"> <td class="rt_fname">externalid</td> <td class="rt_ftype">text</td> <td class="rt_fdle">false</td> <td class="rt_flabel">ExternalId</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_inactive"> <td class="rt_fname">inactive</td> <td class="rt_ftype">checkbox</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Inactive</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_itemtype"> <td class="rt_fname">itemtype</td> <td class="rt_ftype">select</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Item Type</td> <td class="rt_freq">true</td> <td class="rt_fhelp"></td> </tr> <tr id="field_liabilityaccount"> <td class="rt_fname">liabilityaccount</td> <td class="rt_ftype">select</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Liability Account</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_limit"> <td class="rt_fname">limit</td> <td class="rt_ftype">currency</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Limit</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_limitiswithholding"> <td class="rt_fname">limitiswithholding</td> <td class="rt_ftype">radio</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Wage</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_limittype"> <td class="rt_fname">limittype</td> <td class="rt_ftype">text</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Limit Type</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_masterpaycode"> <td class="rt_fname">masterpaycode</td> <td class="rt_ftype">select</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Pay Code</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_name"> <td class="rt_fname">name</td> <td class="rt_ftype">text</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Item Name</td> <td class="rt_freq">true</td> <td class="rt_fhelp"></td> </tr> <tr id="field_reportingsection"> <td class="rt_fname">reportingsection</td> <td class="rt_ftype">select</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Report Section</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_showinemployeecenter"> <td class="rt_fname">showinemployeecenter</td> <td class="rt_ftype">checkbox</td> <td class="rt_fdle">false</td> <td class="rt_flabel">View in Employee Center</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_subsidiary"> <td class="rt_fname">subsidiary</td> <td class="rt_ftype">select</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Subsidiary</td> <td class="rt_freq">true</td> <td class="rt_fhelp"></td> </tr> <tr id="field_usedefaults"> <td class="rt_fname">usedefaults</td> <td class="rt_ftype">checkbox</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Use System Defaults</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> <tr id="field_vendor"> <td class="rt_fname">vendor</td> <td class="rt_ftype">select</td> <td class="rt_fdle">false</td> <td class="rt_flabel">Agency</td> <td class="rt_freq">false</td> <td class="rt_fhelp"></td> </tr> </table> <H2>Sublists</H2> <H4><span id="field_employeepaycodelist_">employeepaycodelist - Employees</span></H4> <table class="jtable"> <tr><th class="rt_sname">Internal ID</th><th class="rt_stype">Type</th><th class="rt_slabel">Label</th><th class="rt_sreq">Required</th></tr> <tr id="field_employeepaycodelist_apply"> <td class="rt_sname">apply</td> <td class="rt_stype">checkbox</td> <td class="rt_slabel">Apply</td> <td class="rt_sreq">false</td> </tr> <tr id="field_employeepaycodelist_employeeid"> <td class="rt_sname">employeeid</td> <td class="rt_stype">integer</td> <td class="rt_slabel">Name</td> <td class="rt_sreq">false</td> </tr> <tr id="field_employeepaycodelist_empprevstate"> <td class="rt_sname">empprevstate</td> <td class="rt_stype">text</td> <td class="rt_slabel">State</td> <td class="rt_sreq">false</td> </tr> <tr id="field_employeepaycodelist_inactive"> <td class="rt_sname">inactive</td> <td class="rt_stype">checkbox</td> <td class="rt_slabel">Inactive</td> <td class="rt_sreq">false</td> </tr> </table> <H2>Tabs</H2> <table class="jtable"> <tr><th class="rt_tname">Name</th><th class="rt_tlabel">Label</th></tr> <tr> <td class="rt_tname">employee</td> <td class="rt_tlabel">Employee</td> </tr> </table> <H2>Search Filters</H2> <table class="jtable"> <tr><th class="rt_iname">Internal ID</th><th class="rt_itype">Type</th><th class="rt_ilabel">Label</th></tr> <tr> <td class="rt_iname">expenseaccount</td> <td class="rt_itype">select</td> <td class="rt_ilabel">Expense Account</td> </tr> <tr> <td class="rt_iname">itemtypenohierarchy</td> <td class="rt_itype">select</td> <td class="rt_ilabel">Item Type (no hierarchy)</td> </tr> <tr> <td class="rt_iname">liabilityaccount</td> <td class="rt_itype">select</td> <td class="rt_ilabel">Liability Account</td> </tr> <tr> <td class="rt_iname">masterpaycode</td> <td class="rt_itype">select</td> <td class="rt_ilabel">Master Pay Code</td> </tr> <tr> <td class="rt_iname">name</td> <td class="rt_itype">text</td> <td class="rt_ilabel">Name</td> </tr> <tr> <td class="rt_iname">subsidiary</td> <td class="rt_itype">select</td> <td class="rt_ilabel">Subsidiary</td> </tr> <tr> <td class="rt_iname">vendor</td> <td class="rt_itype">select</td> <td class="rt_ilabel">Vendor</td> </tr> </table> <H2>Search Columns</H2> <table class="jtable"> <tr><th class="rt_cname">Internal ID</th><th class="rt_ctype">Type</th><th class="rt_clabel">Label</th></tr> <tr> <td class="rt_cname">expenseaccount</td> <td class="rt_ctype">text</td> <td class="rt_clabel">Expense Account</td> </tr> <tr> <td class="rt_cname">isinactive</td> <td class="rt_ctype">checkbox</td> <td class="rt_clabel">Inactive</td> </tr> <tr> <td class="rt_cname">itemtypenohierarchy</td> <td class="rt_ctype">text</td> <td class="rt_clabel">Item Type (no hierarchy)</td> </tr> <tr> <td class="rt_cname">liabilityaccount</td> <td class="rt_ctype">text</td> <td class="rt_clabel">Liability Account</td> </tr> <tr> <td class="rt_cname">masterpaycode</td> <td class="rt_ctype">text</td> <td class="rt_clabel">Master Pay Code</td> </tr> <tr> <td class="rt_cname">name</td> <td class="rt_ctype">text</td> <td class="rt_clabel">Name</td> </tr> <tr> <td class="rt_cname">vendor</td> <td class="rt_ctype">text</td> <td class="rt_clabel">Vendor</td> </tr> </table> <p>&nbsp;</p> </div> <script> $(function() { wrapBodyDiv('script','contentPanel'); }); </script> </body> </html>