diff --git a/.gitpod.yml b/.gitpod.yml new file mode 100644 index 0000000000..33389c5960 --- /dev/null +++ b/.gitpod.yml @@ -0,0 +1,47 @@ +tasks: + - name: Setup django + before: | + export INVENTREE_DB_ENGINE='sqlite3' + export INVENTREE_DB_NAME='/workspace/InvenTree/dev/database.sqlite3' + export INVENTREE_MEDIA_ROOT='/workspace/InvenTree/inventree-data/media' + export INVENTREE_STATIC_ROOT='/workspace/InvenTree/dev/static' + export PIP_USER='no' + + python3 -m venv venv + source venv/bin/activate + pip install invoke + inv install + mkdir dev + inv update + gp sync-done setup_server + + - name: Start server + init: gp sync-await setup_server + command: | + gp sync-await setup_server + export INVENTREE_DB_ENGINE='sqlite3' + export INVENTREE_DB_NAME='/workspace/InvenTree/dev/database.sqlite3' + export INVENTREE_MEDIA_ROOT='/workspace/InvenTree/inventree-data/media' + export INVENTREE_STATIC_ROOT='/workspace/InvenTree/dev/static' + + source venv/bin/activate + rm /workspace/InvenTree/inventree-data -r + git clone https://github.com/inventree/demo-dataset /workspace/InvenTree/inventree-data + invoke delete-data -f + invoke import-records -f /workspace/InvenTree/inventree-data/inventree_data.json + + inv server + +# List the ports to expose. Learn more https://www.gitpod.io/docs/config-ports/ +ports: + - port: 8000 + onOpen: open-preview + +github: + prebuilds: + master: true + pullRequests: false + pullRequestsFromForks: true + addBadge: true + addLabel: gitpod-ready + addCheck: false diff --git a/InvenTree/InvenTree/settings.py b/InvenTree/InvenTree/settings.py index 208af3eb1a..e740107c0e 100644 --- a/InvenTree/InvenTree/settings.py +++ b/InvenTree/InvenTree/settings.py @@ -466,32 +466,101 @@ Ref: https://docs.djangoproject.com/en/3.2/ref/settings/#std:setting-OPTIONS """ # 'OPTIONS' or 'options' can be specified in config.yaml -db_options = db_config.get('OPTIONS', db_config.get('options', {})) +# Set useful sensible timeouts for a transactional webserver to communicate +# with its database server, that is, if the webserver is having issues +# connecting to the database server (such as a replica failover) don't sit and +# wait for possibly an hour or more, just tell the client something went wrong +# and let the client retry when they want to. +db_options = db_config.get("OPTIONS", db_config.get("options", {})) # Specific options for postgres backend -if 'postgres' in db_engine: - from psycopg2.extensions import ISOLATION_LEVEL_READ_COMMITTED, ISOLATION_LEVEL_SERIALIZABLE +if "postgres" in db_engine: + from psycopg2.extensions import ( + ISOLATION_LEVEL_READ_COMMITTED, + ISOLATION_LEVEL_SERIALIZABLE, + ) # Connection timeout - if 'connect_timeout' not in db_options: - db_options['connect_timeout'] = int(os.getenv('INVENTREE_DB_TIMEOUT', 2)) + if "connect_timeout" not in db_options: + # The DB server is in the same data center, it should not take very + # long to connect to the database server + # # seconds, 2 is minium allowed by libpq + db_options["connect_timeout"] = int( + os.getenv("INVENTREE_DB_TIMEOUT", 2) + ) + + # Setup TCP keepalive + # DB server is in the same DC, it should not become unresponsive for + # very long. With the defaults below we wait 5 seconds for the network + # issue to resolve itself. It it that doesn't happen whatever happened + # is probably fatal and no amount of waiting is going to fix it. + # # 0 - TCP Keepalives disabled; 1 - enabled + if "keepalives" not in db_options: + db_options["keepalives"] = int( + os.getenv("INVENTREE_DB_TCP_KEEPALIVES", "1") + ) + # # Seconds after connection is idle to send keep alive + if "keepalives_idle" not in db_options: + db_options["keepalives_idle"] = int( + os.getenv("INVENTREE_DB_TCP_KEEPALIVES_IDLE", "1") + ) + # # Seconds after missing ACK to send another keep alive + if "keepalives_interval" not in db_options: + db_options["keepalives_interval"] = int( + os.getenv("INVENTREE_DB_TCP_KEEPALIVES_INTERVAL", "1") + ) + # # Number of missing ACKs before we close the connection + if "keepalives_count" not in db_options: + db_options["keepalives_count"] = int( + os.getenv("INVENTREE_DB_TCP_KEEPALIVES_COUNT", "5") + ) + # # Milliseconds for how long pending data should remain unacked + # by the remote server + # TODO: Supported starting in PSQL 11 + # "tcp_user_timeout": int(os.getenv("PGTCP_USER_TIMEOUT", "1000"), # Postgres's default isolation level is Read Committed which is # normally fine, but most developers think the database server is # actually going to do Serializable type checks on the queries to # protect against simultaneous changes. - if 'isolation_level' not in db_options: - serializable = _is_true(os.getenv("PG_ISOLATION_SERIALIZABLE", "true")) - db_options['isolation_level'] = ISOLATION_LEVEL_SERIALIZABLE if serializable else ISOLATION_LEVEL_READ_COMMITTED + # https://www.postgresql.org/docs/devel/transaction-iso.html + # https://docs.djangoproject.com/en/3.2/ref/databases/#isolation-level + if "isolation_level" not in db_options: + serializable = _is_true( + os.getenv("INVENTREE_DB_ISOLATION_SERIALIZABLE", "true") + ) + db_options["isolation_level"] = ( + ISOLATION_LEVEL_SERIALIZABLE + if serializable + else ISOLATION_LEVEL_READ_COMMITTED + ) # Specific options for MySql / MariaDB backend -if 'mysql' in db_engine: - # TODO - pass +if "mysql" in db_engine: + # TODO TCP time outs and keepalives + + # MariaDB's default isolation level is Repeatable Read which is + # normally fine, but most developers think the database server is + # actually going to Serializable type checks on the queries to + # protect against siumltaneous changes. + # https://mariadb.com/kb/en/mariadb-transactions-and-isolation-levels-for-sql-server-users/#changing-the-isolation-level + # https://docs.djangoproject.com/en/3.2/ref/databases/#mysql-isolation-level + if "isolation_level" not in db_options: + serializable = _is_true( + os.getenv("INVENTREE_DB_ISOLATION_SERIALIZABLE", "true") + ) + db_options["isolation_level"] = ( + "serializable" if serializable else "read committed" + ) # Specific options for sqlite backend -if 'sqlite' in db_engine: - # TODO +if "sqlite" in db_engine: + # TODO: Verify timeouts are not an issue because no network is involved for SQLite + + # SQLite's default isolation level is Serializable due to SQLite's + # single writer implementation. Presumably as a result of this, it is + # not possible to implement any lower isolation levels in SQLite. + # https://www.sqlite.org/isolation.html pass # Provide OPTIONS dict back to the database configuration dict @@ -653,7 +722,7 @@ DATE_INPUT_FORMATS = [ ] # crispy forms use the bootstrap templates -CRISPY_TEMPLATE_PACK = 'bootstrap3' +CRISPY_TEMPLATE_PACK = 'bootstrap4' # Use database transactions when importing / exporting data IMPORT_EXPORT_USE_TRANSACTIONS = True diff --git a/InvenTree/InvenTree/static/bootstrap-table/bootstrap-table-en-US.min.js b/InvenTree/InvenTree/static/bootstrap-table/bootstrap-table-en-US.min.js deleted file mode 100644 index 87bef30086..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/bootstrap-table-en-US.min.js +++ /dev/null @@ -1,10 +0,0 @@ -/** - * bootstrap-table - An extended table to integration with some of the most widely used CSS frameworks. (Supports Bootstrap, Semantic UI, Bulma, Material Design, Foundation) - * - * @version v1.18.3 - * @homepage https://bootstrap-table.com - * @author wenzhixin (http://wenzhixin.net.cn/) - * @license MIT - */ - -!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n(require("jquery")):"function"==typeof define&&define.amd?define(["jquery"],n):n((t="undefined"!=typeof globalThis?globalThis:t||self).jQuery)}(this,(function(t){"use strict";function n(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var r=n(t),e="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function o(t,n){return t(n={exports:{}},n.exports),n.exports}var i=function(t){return t&&t.Math==Math&&t},u=i("object"==typeof globalThis&&globalThis)||i("object"==typeof window&&window)||i("object"==typeof self&&self)||i("object"==typeof e&&e)||function(){return this}()||Function("return this")(),f=function(t){try{return!!t()}catch(t){return!0}},c=!f((function(){return 7!=Object.defineProperty({},1,{get:function(){return 7}})[1]})),a={}.propertyIsEnumerable,l=Object.getOwnPropertyDescriptor,s={f:l&&!a.call({1:2},1)?function(t){var n=l(this,t);return!!n&&n.enumerable}:a},p=function(t,n){return{enumerable:!(1&t),configurable:!(2&t),writable:!(4&t),value:n}},g={}.toString,d=function(t){return g.call(t).slice(8,-1)},h="".split,y=f((function(){return!Object("z").propertyIsEnumerable(0)}))?function(t){return"String"==d(t)?h.call(t,""):Object(t)}:Object,m=function(t){if(null==t)throw TypeError("Can't call method on "+t);return t},v=function(t){return y(m(t))},w=function(t){return"object"==typeof t?null!==t:"function"==typeof t},b=function(t,n){if(!w(t))return t;var r,e;if(n&&"function"==typeof(r=t.toString)&&!w(e=r.call(t)))return e;if("function"==typeof(r=t.valueOf)&&!w(e=r.call(t)))return e;if(!n&&"function"==typeof(r=t.toString)&&!w(e=r.call(t)))return e;throw TypeError("Can't convert object to primitive value")},S={}.hasOwnProperty,T=function(t,n){return S.call(t,n)},O=u.document,P=w(O)&&w(O.createElement),j=!c&&!f((function(){return 7!=Object.defineProperty((t="div",P?O.createElement(t):{}),"a",{get:function(){return 7}}).a;var t})),x=Object.getOwnPropertyDescriptor,A={f:c?x:function(t,n){if(t=v(t),n=b(n,!0),j)try{return x(t,n)}catch(t){}if(T(t,n))return p(!s.f.call(t,n),t[n])}},C=function(t){if(!w(t))throw TypeError(String(t)+" is not an object");return t},E=Object.defineProperty,M={f:c?E:function(t,n,r){if(C(t),n=b(n,!0),C(r),j)try{return E(t,n,r)}catch(t){}if("get"in r||"set"in r)throw TypeError("Accessors not supported");return"value"in r&&(t[n]=r.value),t}},R=c?function(t,n,r){return M.f(t,n,p(1,r))}:function(t,n,r){return t[n]=r,t},F=function(t,n){try{R(u,t,n)}catch(r){u[t]=n}return n},N="__core-js_shared__",L=u[N]||F(N,{}),k=Function.toString;"function"!=typeof L.inspectSource&&(L.inspectSource=function(t){return k.call(t)});var H,I,_,D,q=L.inspectSource,z=u.WeakMap,G="function"==typeof z&&/native code/.test(q(z)),U=o((function(t){(t.exports=function(t,n){return L[t]||(L[t]=void 0!==n?n:{})})("versions",[]).push({version:"3.9.1",mode:"global",copyright:"© 2021 Denis Pushkarev (zloirock.ru)"})})),B=0,W=Math.random(),J=function(t){return"Symbol("+String(void 0===t?"":t)+")_"+(++B+W).toString(36)},K=U("keys"),Q={},V=u.WeakMap;if(G){var Y=L.state||(L.state=new V),X=Y.get,Z=Y.has,$=Y.set;H=function(t,n){return n.facade=t,$.call(Y,t,n),n},I=function(t){return X.call(Y,t)||{}},_=function(t){return Z.call(Y,t)}}else{var tt=K[D="state"]||(K[D]=J(D));Q[tt]=!0,H=function(t,n){return n.facade=t,R(t,tt,n),n},I=function(t){return T(t,tt)?t[tt]:{}},_=function(t){return T(t,tt)}}var nt,rt,et={set:H,get:I,has:_,enforce:function(t){return _(t)?I(t):H(t,{})},getterFor:function(t){return function(n){var r;if(!w(n)||(r=I(n)).type!==t)throw TypeError("Incompatible receiver, "+t+" required");return r}}},ot=o((function(t){var n=et.get,r=et.enforce,e=String(String).split("String");(t.exports=function(t,n,o,i){var f,c=!!i&&!!i.unsafe,a=!!i&&!!i.enumerable,l=!!i&&!!i.noTargetGet;"function"==typeof o&&("string"!=typeof n||T(o,"name")||R(o,"name",n),(f=r(o)).source||(f.source=e.join("string"==typeof n?n:""))),t!==u?(c?!l&&t[n]&&(a=!0):delete t[n],a?t[n]=o:R(t,n,o)):a?t[n]=o:F(n,o)})(Function.prototype,"toString",(function(){return"function"==typeof this&&n(this).source||q(this)}))})),it=u,ut=function(t){return"function"==typeof t?t:void 0},ft=function(t,n){return arguments.length<2?ut(it[t])||ut(u[t]):it[t]&&it[t][n]||u[t]&&u[t][n]},ct=Math.ceil,at=Math.floor,lt=function(t){return isNaN(t=+t)?0:(t>0?at:ct)(t)},st=Math.min,pt=function(t){return t>0?st(lt(t),9007199254740991):0},gt=Math.max,dt=Math.min,ht=function(t){return function(n,r,e){var o,i=v(n),u=pt(i.length),f=function(t,n){var r=lt(t);return r<0?gt(r+n,0):dt(r,n)}(e,u);if(t&&r!=r){for(;u>f;)if((o=i[f++])!=o)return!0}else for(;u>f;f++)if((t||f in i)&&i[f]===r)return t||f||0;return!t&&-1}},yt={includes:ht(!0),indexOf:ht(!1)}.indexOf,mt=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"].concat("length","prototype"),vt={f:Object.getOwnPropertyNames||function(t){return function(t,n){var r,e=v(t),o=0,i=[];for(r in e)!T(Q,r)&&T(e,r)&&i.push(r);for(;n.length>o;)T(e,r=n[o++])&&(~yt(i,r)||i.push(r));return i}(t,mt)}},wt={f:Object.getOwnPropertySymbols},bt=ft("Reflect","ownKeys")||function(t){var n=vt.f(C(t)),r=wt.f;return r?n.concat(r(t)):n},St=function(t,n){for(var r=bt(n),e=M.f,o=A.f,i=0;i=74)&&(nt=Lt.match(/Chrome\/(\d+)/))&&(rt=nt[1]);var _t,Dt=rt&&+rt,qt=!!Object.getOwnPropertySymbols&&!f((function(){return!Symbol.sham&&(Nt?38===Dt:Dt>37&&Dt<41)})),zt=qt&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,Gt=U("wks"),Ut=u.Symbol,Bt=zt?Ut:Ut&&Ut.withoutSetter||J,Wt=function(t){return T(Gt,t)&&(qt||"string"==typeof Gt[t])||(qt&&T(Ut,t)?Gt[t]=Ut[t]:Gt[t]=Bt("Symbol."+t)),Gt[t]},Jt=Wt("species"),Kt=function(t,n){var r;return Mt(t)&&("function"!=typeof(r=t.constructor)||r!==Array&&!Mt(r.prototype)?w(r)&&null===(r=r[Jt])&&(r=void 0):r=void 0),new(void 0===r?Array:r)(0===n?0:n)},Qt=Wt("species"),Vt=Wt("isConcatSpreadable"),Yt=9007199254740991,Xt="Maximum allowed index exceeded",Zt=Dt>=51||!f((function(){var t=[];return t[Vt]=!1,t.concat()[0]!==t})),$t=(_t="concat",Dt>=51||!f((function(){var t=[];return(t.constructor={})[Qt]=function(){return{foo:1}},1!==t[_t](Boolean).foo}))),tn=function(t){if(!w(t))return!1;var n=t[Vt];return void 0!==n?!!n:Mt(t)};!function(t,n){var r,e,o,i,f,c=t.target,a=t.global,l=t.stat;if(r=a?u:l?u[c]||F(c,{}):(u[c]||{}).prototype)for(e in n){if(i=n[e],o=t.noTargetGet?(f=Et(r,e))&&f.value:r[e],!Ct(a?e:c+(l?".":"#")+e,t.forced)&&void 0!==o){if(typeof i==typeof o)continue;St(i,o)}(t.sham||o&&o.sham)&&R(i,"sham",!0),ot(r,e,i,t)}}({target:"Array",proto:!0,forced:!Zt||!$t},{concat:function(t){var n,r,e,o,i,u=Rt(this),f=Kt(u,0),c=0;for(n=-1,e=arguments.length;nYt)throw TypeError(Xt);for(r=0;r=Yt)throw TypeError(Xt);Ft(f,c++,i)}return f.length=c,f}}),r.default.fn.bootstrapTable.locales["en-US"]=r.default.fn.bootstrapTable.locales.en={formatCopyRows:function(){return"Copy Rows"},formatPrint:function(){return"Print"},formatLoadingMessage:function(){return"Loading, please wait"},formatRecordsPerPage:function(t){return"".concat(t," rows per page")},formatShowingRows:function(t,n,r,e){return void 0!==e&&e>0&&e>r?"Showing ".concat(t," to ").concat(n," of ").concat(r," rows (filtered from ").concat(e," total rows)"):"Showing ".concat(t," to ").concat(n," of ").concat(r," rows")},formatSRPaginationPreText:function(){return"previous page"},formatSRPaginationPageText:function(t){return"to page ".concat(t)},formatSRPaginationNextText:function(){return"next page"},formatDetailPagination:function(t){return"Showing ".concat(t," rows")},formatClearSearch:function(){return"Clear Search"},formatSearch:function(){return"Search"},formatNoMatches:function(){return"No matching records found"},formatPaginationSwitch:function(){return"Hide/Show pagination"},formatPaginationSwitchDown:function(){return"Show pagination"},formatPaginationSwitchUp:function(){return"Hide pagination"},formatRefresh:function(){return"Refresh"},formatToggle:function(){return"Toggle"},formatToggleOn:function(){return"Show card view"},formatToggleOff:function(){return"Hide card view"},formatColumns:function(){return"Columns"},formatColumnsToggleAll:function(){return"Toggle all"},formatFullscreen:function(){return"Fullscreen"},formatAllRows:function(){return"All"},formatAutoRefresh:function(){return"Auto Refresh"},formatExport:function(){return"Export data"},formatJumpTo:function(){return"GO"},formatAdvancedSearch:function(){return"Advanced search"},formatAdvancedCloseButton:function(){return"Close"},formatFilterControlSwitch:function(){return"Hide/Show controls"},formatFilterControlSwitchHide:function(){return"Hide controls"},formatFilterControlSwitchShow:function(){return"Show controls"}},r.default.extend(r.default.fn.bootstrapTable.defaults,r.default.fn.bootstrapTable.locales["en-US"])})); diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/accent-neutralise/bootstrap-table-accent-neutralise.js b/InvenTree/InvenTree/static/bootstrap-table/extensions/accent-neutralise/bootstrap-table-accent-neutralise.js deleted file mode 100644 index 42c8d2896f..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/accent-neutralise/bootstrap-table-accent-neutralise.js +++ /dev/null @@ -1,170 +0,0 @@ -/** - * @author: Dennis Hernández - * @webSite: http://djhvscf.github.io/Blog - * @update: zhixin wen - */ - -!($ => { - const diacriticsMap = {} - const defaultAccentsDiacritics = [ - {base: 'A', letters: '\u0041\u24B6\uFF21\u00C0\u00C1\u00C2\u1EA6\u1EA4\u1EAA\u1EA8\u00C3\u0100\u0102\u1EB0\u1EAE\u1EB4\u1EB2\u0226\u01E0\u00C4\u01DE\u1EA2\u00C5\u01FA\u01CD\u0200\u0202\u1EA0\u1EAC\u1EB6\u1E00\u0104\u023A\u2C6F'}, - {base: 'AA',letters: '\uA732'}, - {base: 'AE',letters: '\u00C6\u01FC\u01E2'}, - {base: 'AO',letters: '\uA734'}, - {base: 'AU',letters: '\uA736'}, - {base: 'AV',letters: '\uA738\uA73A'}, - {base: 'AY',letters: '\uA73C'}, - {base: 'B', letters: '\u0042\u24B7\uFF22\u1E02\u1E04\u1E06\u0243\u0182\u0181'}, - {base: 'C', letters: '\u0043\u24B8\uFF23\u0106\u0108\u010A\u010C\u00C7\u1E08\u0187\u023B\uA73E'}, - {base: 'D', letters: '\u0044\u24B9\uFF24\u1E0A\u010E\u1E0C\u1E10\u1E12\u1E0E\u0110\u018B\u018A\u0189\uA779'}, - {base: 'DZ',letters: '\u01F1\u01C4'}, - {base: 'Dz',letters: '\u01F2\u01C5'}, - {base: 'E', letters: '\u0045\u24BA\uFF25\u00C8\u00C9\u00CA\u1EC0\u1EBE\u1EC4\u1EC2\u1EBC\u0112\u1E14\u1E16\u0114\u0116\u00CB\u1EBA\u011A\u0204\u0206\u1EB8\u1EC6\u0228\u1E1C\u0118\u1E18\u1E1A\u0190\u018E'}, - {base: 'F', letters: '\u0046\u24BB\uFF26\u1E1E\u0191\uA77B'}, - {base: 'G', letters: '\u0047\u24BC\uFF27\u01F4\u011C\u1E20\u011E\u0120\u01E6\u0122\u01E4\u0193\uA7A0\uA77D\uA77E'}, - {base: 'H', letters: '\u0048\u24BD\uFF28\u0124\u1E22\u1E26\u021E\u1E24\u1E28\u1E2A\u0126\u2C67\u2C75\uA78D'}, - {base: 'I', letters: '\u0049\u24BE\uFF29\u00CC\u00CD\u00CE\u0128\u012A\u012C\u0130\u00CF\u1E2E\u1EC8\u01CF\u0208\u020A\u1ECA\u012E\u1E2C\u0197'}, - {base: 'J', letters: '\u004A\u24BF\uFF2A\u0134\u0248'}, - {base: 'K', letters: '\u004B\u24C0\uFF2B\u1E30\u01E8\u1E32\u0136\u1E34\u0198\u2C69\uA740\uA742\uA744\uA7A2'}, - {base: 'L', letters: '\u004C\u24C1\uFF2C\u013F\u0139\u013D\u1E36\u1E38\u013B\u1E3C\u1E3A\u0141\u023D\u2C62\u2C60\uA748\uA746\uA780'}, - {base: 'LJ',letters: '\u01C7'}, - {base: 'Lj',letters: '\u01C8'}, - {base: 'M', letters: '\u004D\u24C2\uFF2D\u1E3E\u1E40\u1E42\u2C6E\u019C'}, - {base: 'N', letters: '\u004E\u24C3\uFF2E\u01F8\u0143\u00D1\u1E44\u0147\u1E46\u0145\u1E4A\u1E48\u0220\u019D\uA790\uA7A4'}, - {base: 'NJ',letters: '\u01CA'}, - {base: 'Nj',letters: '\u01CB'}, - {base: 'O', letters: '\u004F\u24C4\uFF2F\u00D2\u00D3\u00D4\u1ED2\u1ED0\u1ED6\u1ED4\u00D5\u1E4C\u022C\u1E4E\u014C\u1E50\u1E52\u014E\u022E\u0230\u00D6\u022A\u1ECE\u0150\u01D1\u020C\u020E\u01A0\u1EDC\u1EDA\u1EE0\u1EDE\u1EE2\u1ECC\u1ED8\u01EA\u01EC\u00D8\u01FE\u0186\u019F\uA74A\uA74C'}, - {base: 'OI',letters: '\u01A2'}, - {base: 'OO',letters: '\uA74E'}, - {base: 'OU',letters: '\u0222'}, - {base: 'OE',letters: '\u008C\u0152'}, - {base: 'oe',letters: '\u009C\u0153'}, - {base: 'P', letters: '\u0050\u24C5\uFF30\u1E54\u1E56\u01A4\u2C63\uA750\uA752\uA754'}, - {base: 'Q', letters: '\u0051\u24C6\uFF31\uA756\uA758\u024A'}, - {base: 'R', letters: '\u0052\u24C7\uFF32\u0154\u1E58\u0158\u0210\u0212\u1E5A\u1E5C\u0156\u1E5E\u024C\u2C64\uA75A\uA7A6\uA782'}, - {base: 'S', letters: '\u0053\u24C8\uFF33\u1E9E\u015A\u1E64\u015C\u1E60\u0160\u1E66\u1E62\u1E68\u0218\u015E\u2C7E\uA7A8\uA784'}, - {base: 'T', letters: '\u0054\u24C9\uFF34\u1E6A\u0164\u1E6C\u021A\u0162\u1E70\u1E6E\u0166\u01AC\u01AE\u023E\uA786'}, - {base: 'TZ',letters: '\uA728'}, - {base: 'U', letters: '\u0055\u24CA\uFF35\u00D9\u00DA\u00DB\u0168\u1E78\u016A\u1E7A\u016C\u00DC\u01DB\u01D7\u01D5\u01D9\u1EE6\u016E\u0170\u01D3\u0214\u0216\u01AF\u1EEA\u1EE8\u1EEE\u1EEC\u1EF0\u1EE4\u1E72\u0172\u1E76\u1E74\u0244'}, - {base: 'V', letters: '\u0056\u24CB\uFF36\u1E7C\u1E7E\u01B2\uA75E\u0245'}, - {base: 'VY',letters: '\uA760'}, - {base: 'W', letters: '\u0057\u24CC\uFF37\u1E80\u1E82\u0174\u1E86\u1E84\u1E88\u2C72'}, - {base: 'X', letters: '\u0058\u24CD\uFF38\u1E8A\u1E8C'}, - {base: 'Y', letters: '\u0059\u24CE\uFF39\u1EF2\u00DD\u0176\u1EF8\u0232\u1E8E\u0178\u1EF6\u1EF4\u01B3\u024E\u1EFE'}, - {base: 'Z', letters: '\u005A\u24CF\uFF3A\u0179\u1E90\u017B\u017D\u1E92\u1E94\u01B5\u0224\u2C7F\u2C6B\uA762'}, - {base: 'a', letters: '\u0061\u24D0\uFF41\u1E9A\u00E0\u00E1\u00E2\u1EA7\u1EA5\u1EAB\u1EA9\u00E3\u0101\u0103\u1EB1\u1EAF\u1EB5\u1EB3\u0227\u01E1\u00E4\u01DF\u1EA3\u00E5\u01FB\u01CE\u0201\u0203\u1EA1\u1EAD\u1EB7\u1E01\u0105\u2C65\u0250'}, - {base: 'aa',letters: '\uA733'}, - {base: 'ae',letters: '\u00E6\u01FD\u01E3'}, - {base: 'ao',letters: '\uA735'}, - {base: 'au',letters: '\uA737'}, - {base: 'av',letters: '\uA739\uA73B'}, - {base: 'ay',letters: '\uA73D'}, - {base: 'b', letters: '\u0062\u24D1\uFF42\u1E03\u1E05\u1E07\u0180\u0183\u0253'}, - {base: 'c', letters: '\u0063\u24D2\uFF43\u0107\u0109\u010B\u010D\u00E7\u1E09\u0188\u023C\uA73F\u2184'}, - {base: 'd', letters: '\u0064\u24D3\uFF44\u1E0B\u010F\u1E0D\u1E11\u1E13\u1E0F\u0111\u018C\u0256\u0257\uA77A'}, - {base: 'dz',letters: '\u01F3\u01C6'}, - {base: 'e', letters: '\u0065\u24D4\uFF45\u00E8\u00E9\u00EA\u1EC1\u1EBF\u1EC5\u1EC3\u1EBD\u0113\u1E15\u1E17\u0115\u0117\u00EB\u1EBB\u011B\u0205\u0207\u1EB9\u1EC7\u0229\u1E1D\u0119\u1E19\u1E1B\u0247\u025B\u01DD'}, - {base: 'f', letters: '\u0066\u24D5\uFF46\u1E1F\u0192\uA77C'}, - {base: 'g', letters: '\u0067\u24D6\uFF47\u01F5\u011D\u1E21\u011F\u0121\u01E7\u0123\u01E5\u0260\uA7A1\u1D79\uA77F'}, - {base: 'h', letters: '\u0068\u24D7\uFF48\u0125\u1E23\u1E27\u021F\u1E25\u1E29\u1E2B\u1E96\u0127\u2C68\u2C76\u0265'}, - {base: 'hv',letters: '\u0195'}, - {base: 'i', letters: '\u0069\u24D8\uFF49\u00EC\u00ED\u00EE\u0129\u012B\u012D\u00EF\u1E2F\u1EC9\u01D0\u0209\u020B\u1ECB\u012F\u1E2D\u0268\u0131'}, - {base: 'j', letters: '\u006A\u24D9\uFF4A\u0135\u01F0\u0249'}, - {base: 'k', letters: '\u006B\u24DA\uFF4B\u1E31\u01E9\u1E33\u0137\u1E35\u0199\u2C6A\uA741\uA743\uA745\uA7A3'}, - {base: 'l', letters: '\u006C\u24DB\uFF4C\u0140\u013A\u013E\u1E37\u1E39\u013C\u1E3D\u1E3B\u017F\u0142\u019A\u026B\u2C61\uA749\uA781\uA747'}, - {base: 'lj',letters: '\u01C9'}, - {base: 'm', letters: '\u006D\u24DC\uFF4D\u1E3F\u1E41\u1E43\u0271\u026F'}, - {base: 'n', letters: '\u006E\u24DD\uFF4E\u01F9\u0144\u00F1\u1E45\u0148\u1E47\u0146\u1E4B\u1E49\u019E\u0272\u0149\uA791\uA7A5'}, - {base: 'nj',letters: '\u01CC'}, - {base: 'o', letters: '\u006F\u24DE\uFF4F\u00F2\u00F3\u00F4\u1ED3\u1ED1\u1ED7\u1ED5\u00F5\u1E4D\u022D\u1E4F\u014D\u1E51\u1E53\u014F\u022F\u0231\u00F6\u022B\u1ECF\u0151\u01D2\u020D\u020F\u01A1\u1EDD\u1EDB\u1EE1\u1EDF\u1EE3\u1ECD\u1ED9\u01EB\u01ED\u00F8\u01FF\u0254\uA74B\uA74D\u0275'}, - {base: 'oi',letters: '\u01A3'}, - {base: 'ou',letters: '\u0223'}, - {base: 'oo',letters: '\uA74F'}, - {base: 'p',letters: '\u0070\u24DF\uFF50\u1E55\u1E57\u01A5\u1D7D\uA751\uA753\uA755'}, - {base: 'q',letters: '\u0071\u24E0\uFF51\u024B\uA757\uA759'}, - {base: 'r',letters: '\u0072\u24E1\uFF52\u0155\u1E59\u0159\u0211\u0213\u1E5B\u1E5D\u0157\u1E5F\u024D\u027D\uA75B\uA7A7\uA783'}, - {base: 's',letters: '\u0073\u24E2\uFF53\u00DF\u015B\u1E65\u015D\u1E61\u0161\u1E67\u1E63\u1E69\u0219\u015F\u023F\uA7A9\uA785\u1E9B'}, - {base: 't',letters: '\u0074\u24E3\uFF54\u1E6B\u1E97\u0165\u1E6D\u021B\u0163\u1E71\u1E6F\u0167\u01AD\u0288\u2C66\uA787'}, - {base: 'tz',letters: '\uA729'}, - {base: 'u',letters: '\u0075\u24E4\uFF55\u00F9\u00FA\u00FB\u0169\u1E79\u016B\u1E7B\u016D\u00FC\u01DC\u01D8\u01D6\u01DA\u1EE7\u016F\u0171\u01D4\u0215\u0217\u01B0\u1EEB\u1EE9\u1EEF\u1EED\u1EF1\u1EE5\u1E73\u0173\u1E77\u1E75\u0289'}, - {base: 'v',letters: '\u0076\u24E5\uFF56\u1E7D\u1E7F\u028B\uA75F\u028C'}, - {base: 'vy',letters: '\uA761'}, - {base: 'w',letters: '\u0077\u24E6\uFF57\u1E81\u1E83\u0175\u1E87\u1E85\u1E98\u1E89\u2C73'}, - {base: 'x',letters: '\u0078\u24E7\uFF58\u1E8B\u1E8D'}, - {base: 'y',letters: '\u0079\u24E8\uFF59\u1EF3\u00FD\u0177\u1EF9\u0233\u1E8F\u00FF\u1EF7\u1E99\u1EF5\u01B4\u024F\u1EFF'}, - {base: 'z',letters: '\u007A\u24E9\uFF5A\u017A\u1E91\u017C\u017E\u1E93\u1E95\u01B6\u0225\u0240\u2C6C\uA763'} - ] - - const initNeutraliser = () => { - for (const diacritic of defaultAccentsDiacritics) { - const letters = diacritic.letters - for (let i = 0; i < letters.length; i++) { - diacriticsMap[letters[i]] = diacritic.base - } - } - } - - /* eslint-disable no-control-regex */ - const removeDiacritics = str => str.replace(/[^\u0000-\u007E]/g, a => diacriticsMap[a] || a) - - $.extend($.fn.bootstrapTable.defaults, { - searchAccentNeutralise: false - }) - - $.BootstrapTable = class extends $.BootstrapTable { - init () { - if (this.options.searchAccentNeutralise) { - initNeutraliser() - } - super.init() - } - - initSearch () { - if (this.options.sidePagination !== 'server') { - let s = this.searchText && this.searchText.toLowerCase() - const f = $.isEmptyObject(this.filterColumns) ? null : this.filterColumns - - // Check filter - this.data = f ? this.options.data.filter((item, i) => { - for (const key in f) { - if (item[key] !== f[key]) { - return false - } - } - return true - }) : this.options.data - - this.data = s ? this.options.data.filter((item, i) => { - for (let [key, value] of Object.entries(item)) { - key = $.isNumeric(key) ? parseInt(key, 10) : key - const column = this.columns[this.fieldsColumnsIndex[key]] - const j = this.header.fields.indexOf(key) - - if (column && column.searchFormatter) { - value = $.fn.bootstrapTable.utils.calculateObjectValue(column, - this.header.formatters[j], [value, item, i], value) - } - - const index = this.header.fields.indexOf(key) - if (index !== -1 && this.header.searchables[index] && typeof value === 'string') { - if (this.options.searchAccentNeutralise) { - value = removeDiacritics(value) - s = removeDiacritics(s) - } - if (this.options.strictSearch) { - if ((`${value}`).toLowerCase() === s) { - return true - } - } else { - if ((`${value}`).toLowerCase().includes(s)) { - return true - } - } - } - } - return false - }) : this.data - } - } - } -})(jQuery) diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/accent-neutralise/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/accent-neutralise/extension.json deleted file mode 100644 index ce69cfdb5f..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/accent-neutralise/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Accent Neutralise", - "version": "1.0.0", - "description": "Plugin to neutralise the words.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/accent-neutralise", - "example": "#", - - "plugins": [{ - "name": "bootstrap-table-accent-neutralise", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/accent-neutralise" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/auto-refresh/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/auto-refresh/extension.json deleted file mode 100644 index 182561bc1e..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/auto-refresh/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Auto Refresh", - "version": "1.0.0", - "description": "Plugin to automatically refresh the table on an interval.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/auto-refresh", - "example": "#", - - "plugins": [{ - "name": "bootstrap-table-auto-refresh", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/auto-refresh" - }], - - "author": { - "name": "fenichaler", - "image": "https://avatars.githubusercontent.com/u/3437075" - } -} diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/cookie/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/cookie/extension.json deleted file mode 100644 index 6422de402a..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/cookie/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Cookie", - "version": "1.2.1", - "description": "Plugin to use the cookie of the browser.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/cookie", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/cookie.html", - - "plugins": [{ - "name": "bootstrap-table-cookie", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/cookie" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/copy-rows/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/copy-rows/extension.json deleted file mode 100644 index 4deb78b288..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/copy-rows/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Copy Rows", - "version": "1.0.0", - "description": "Allows pushing of selected column data to the clipboard.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/copy-rows", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/copy-rows.html", - - "plugins": [{ - "name": "copy-rows", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/copy-rows" - }], - - "author": { - "name": "Homer Glascock", - "image": "https://avatars1.githubusercontent.com/u/5546710" - } -} diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/defer-url/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/defer-url/extension.json deleted file mode 100644 index 4895fb21d0..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/defer-url/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "DeferURL", - "version": "1.0.0", - "description": "Plugin to defer server side processing.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/defer-url", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/defer-url.html", - - "plugins": [{ - "name": "bootstrap-table-defer-url", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/defer-url" - }], - - "author": { - "name": "rubensa", - "image": "https://avatars1.githubusercontent.com/u/1469340" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/editable/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/editable/extension.json deleted file mode 100644 index ea6106b693..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/editable/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Table Editable", - "version": "1.1.0", - "description": "Use the x-editable to in-place editing your table.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/editable", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/editable.html", - - "plugins": [{ - "name": "x-editable", - "url": "https://github.com/vitalets/x-editable" - }], - - "author": { - "name": "wenzhixin", - "image": "https://avatars1.githubusercontent.com/u/2117018" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/export/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/export/extension.json deleted file mode 100644 index 5714a5fa0a..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/export/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Table Export", - "version": "1.1.0", - "description": "Export your table data to JSON, XML, CSV, TXT, SQL, Word, Excel, PNG, PDF.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/export", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/export.html", - - "plugins": [{ - "name": "tableExport.jquery.plugin", - "url": "https://github.com/hhurz/tableExport.jquery.plugin" - }], - - "author": { - "name": "wenzhixin", - "image": "https://avatars1.githubusercontent.com/u/2117018" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/filter-control/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/filter-control/extension.json deleted file mode 100644 index b0e31694bb..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/filter-control/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Filter Control", - "version": "2.1.0", - "description": "Plugin to add input/select element on the top of the columns in order to filter the data.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/filter-control", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/filter-control.html", - - "plugins": [{ - "name": "bootstrap-table-filter-control", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/filter-control" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by-v2/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by-v2/extension.json deleted file mode 100644 index 2b948bbd30..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by-v2/extension.json +++ /dev/null @@ -1,12 +0,0 @@ -{ - "name": "Group By V2", - "version": "1.0.0", - "description": "Group the data by field", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/group-by-v2", - "example": "", - "plugins": [], - "author": { - "name": "Knoxvillekm", - "image": "https://avatars3.githubusercontent.com/u/11072464" - } -} diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by/bootstrap-table-group-by.css b/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by/bootstrap-table-group-by.css deleted file mode 100644 index fce5a9a7b1..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by/bootstrap-table-group-by.css +++ /dev/null @@ -1,53 +0,0 @@ -table.treetable tbody tr td { - cursor: default; -} - -table.treetable span { - background-position: center left; - background-repeat: no-repeat; - padding: .2em 0 .2em 1.5em; -} - -table.treetable tr.collapsed span.indenter a { - background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ONo62Dl8t6r8G/yJiYuP+5c+rcEAAAOF0ftH+LC+zGoA7BoBt/qIl7gRoXgugdfeLZrIPQLUAoOnaV/Nw+H48PEWhkLnZ2eXk5NhKxEJbYcpXff5nwl/AV/1s+X48/Pf14L7iJIEyXYFHBPjgwsz0TKUcz5IJhGLc5o9H/LcL//wd0yLESWK5WCoU41EScY5EmozzMqUiiUKSKcUl0v9k4t8s+wM+3zUAsGo+AXuRLahdYwP2SycQWHTA4vcAAPK7b8HUKAgDgGiD4c93/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O/PLi8ZafJzs07P1SkVPRU+lQ27tLdtWHX+G7R7ht7vPY07NXbW7z3/T7JvttVAVVN1WbVZftJ+7P3P66Jqun4lvttXa1ObXHtxwPSA/0HIw6217nU1R3SPVRSj9Yr60cOxx++/p3vdy0NNg1VjZzG4iNwRHnk6fcJ3/ceDTradox7rOEH0x92HWcdL2pCmvKaRptTmvtbYlu6T8w+0dbq3nr8R9sfD5w0PFl5SvNUyWna6YLTk2fyz4ydlZ19fi753GDborZ752PO32oPb++6EHTh0kX/i+c7vDvOXPK4dPKy2+UTV7hXmq86X23qdOo8/pPTT8e7nLuarrlca7nuer21e2b36RueN87d9L158Rb/1tWeOT3dvfN6b/fF9/XfFt1+cif9zsu72Xcn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAHlJREFUeNrcU1sNgDAQ6wgmcAM2MICGGlg1gJnNzWQcvwQGy1j4oUl/7tH0mpwzM7SgQyO+EZAUWh2MkkzSWhJwuRAlHYsJwEwyvs1gABDuzqoJcTw5qxaIJN0bgQRgIjnlmn1heSO5PE6Y2YXe+5Cr5+h++gs12AcAS6FS+7YOsj4AAAAASUVORK5CYII=); - padding-right: 12px; -} - -table.treetable tr.expanded span.indenter a { - background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcER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cn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAHFJREFUeNpi/P//PwMlgImBQsA44C6gvhfa29v3MzAwOODRc6CystIRbxi0t7fjDJjKykpGYrwwi1hxnLHQ3t7+jIGBQRJJ6HllZaUUKYEYRYBPOB0gBShKwKGA////48VtbW3/8clTnBIH3gCKkzJgAGvBX0dDm0sCAAAAAElFTkSuQmCC); - padding-right: 12px; -} - -table.treetable tr.branch { - background-color: #f9f9f9; -} - -table.treetable tr.selected { - background-color: #3875d7; - color: #fff; -} - -table.treetable tr span.indenter a { - outline: none; /* Expander shows outline after upgrading to 3.0 (#141) */ -} - -table.treetable tr.collapsed.selected span.indenter a { - background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgM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MlgHHADWD4//8/NtyAQxwD45KAAQdKDfj//////fgMIsYAZIMw1DKREFwODAwM/4kNRKq64AADA4MjFDOQ6gKyY4HodMA49PMCxQYABgAVYHsjyZ1x7QAAAABJRU5ErkJggg==); -} - -table.treetable tr.expanded.selected span.indenter a { - background-image: url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ONo62Dl8t6r8G/yJiYuP+5c+rcEAAAOF0ftH+LC+zGoA7BoBt/qIl7gRoXgugdfeLZrIPQLUAoOnaV/Nw+H48PEWhkLnZ2eXk5NhKxEJbYcpXff5nwl/AV/1s+X48/Pf14L7iJIEyXYFHBPjgwsz0TKUcz5IJhGLc5o9H/LcL//wd0yLESWK5WCoU41EScY5EmozzMqUiiUKSKcUl0v9k4t8s+wM+3zUAsGo+AXuRLahdYwP2SycQWHTA4vcAAPK7b8HUKAgDgGiD4c93/+8//UegJQCAZkmScQAAXkQkLlTKsz/HCAAARKCBKrBBG/TBGCzAB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bW7z3/T7JvttVAVVN1WbVZftJ+7P3P66Jqun4lvttXa1ObXHtxwPSA/0HIw6217nU1R3SPVRSj9Yr60cOxx++/p3vdy0NNg1VjZzG4iNwRHnk6fcJ3/ceDTradox7rOEH0x92HWcdL2pCmvKaRptTmvtbYlu6T8w+0dbq3nr8R9sfD5w0PFl5SvNUyWna6YLTk2fyz4ydlZ19fi753GDborZ752PO32oPb++6EHTh0kX/i+c7vDvOXPK4dPKy2+UTV7hXmq86X23qdOo8/pPTT8e7nLuarrlca7nuer21e2b36RueN87d9L158Rb/1tWeOT3dvfN6b/fF9/XfFt1+cif9zsu72Xcn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAFtJREFUeNpi/P//PwMlgImBQsA44C6giQENDAwM//HgBmLCAF/AMBLjBUeixf///48L7/+PCvZjU4fPAAc0AxywqcMXCwegGJ1NckL6jx5wpKYDxqGXEkkCgAEAmrqBIejdgngAAAAASUVORK5CYII=); -} - -table.treetable tr.accept { - background-color: #a3bce4; - color: #fff -} - -table.treetable tr.collapsed.accept td span.indenter a { - background-image: url(data:image/x-png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNY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njg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAFpJREFUeNpi/P//PwMlgHHADWD4//8/NtyAQxwD45KAAQdKDfj//////fgMIsYAZIMw1DKREFwODAwM/4kNRKq64AADA4MjFDOQ6gKyY4HodMA49PMCxQYABgAVYHsjyZ1x7QAAAABJRU5ErkJggg==); -} - -table.treetable tr.expanded.accept td span.indenter a { - background-image: url(data:image/x-png;base64,iVBORw0KGgoAAAANSUhEUgAAABAAAAAQCAYAAAAf8/9hAAAACXBIWXMAAAsTAAALEwEAmpwYAAAKT2lDQ1BQaG90b3Nob3AgSUNDIHByb2ZpbGUAAHjanVNnVFPpFj333vRCS4iAlEtvUhUIIFJCi4AUkSYqIQkQSoghodkVUcERRUUEG8igiAOOjoCMFVEsDIoK2AfkIaKOg6OIisr74Xuja9a89+bN/rXXPues852zzwfACAyWSDNRNYAMqUIeEeCDx8TG4eQuQIEKJHAAEAizZCFz/SMBAPh+PDwrIsAHvgABeNMLCADATZvAMByH/w/qQplcAYCEAcB0kThLCIAUAEB6jkKmAEBGAYCdmCZTAKAEAGDLY2LjAFAtAGAnf+bTAICd+Jl7AQBblCEVAaCRACATZYhEAGg7AKzPVopFAFgwABRmS8Q5ANgtADBJV2ZIALC3AMDOEAuyAAgMADBRiIUpAAR7AGDIIyN4AISZABRG8lc88SuuEOcqAAB4mbI8uSQ5RYFbCC1xB1dXLh4ozkkXKxQ2YQJhmkAuwnmZGTKBNA/g88wAAKCRFRHgg/P9eM4Ors7ONo62Dl8t6r8G/yJiYuP+5c+rcEAAAOF0ftH+LC+zGoA7BoBt/qIl7gRoXgugdfeLZrIPQLUAoOnaV/Nw+H48PEWhkLnZ2eXk5NhKx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Bqw8uIq2Km3VT6vtV5eufr0mek1rgV7ByoLBtQFr6wtVCuWFfevc1+1dT1gvWd+1YfqGnRs+FYmKrhTbF5cVf9go3HjlG4dvyr+Z3JS0qavEuWTPZtJm6ebeLZ5bDpaql+aXDm4N2dq0Dd9WtO319kXbL5fNKNu7g7ZDuaO/PLi8ZafJzs07P1SkVPRU+lQ27tLdtWHX+G7R7ht7vPY07NXbW7z3/T7JvttVAVVN1WbVZftJ+7P3P66Jqun4lvttXa1ObXHtxwPSA/0HIw6217nU1R3SPVRSj9Yr60cOxx++/p3vdy0NNg1VjZzG4iNwRHnk6fcJ3/ceDTradox7rOEH0x92HWcdL2pCmvKaRptTmvtbYlu6T8w+0dbq3nr8R9sfD5w0PFl5SvNUyWna6YLTk2fyz4ydlZ19fi753GDborZ752PO32oPb++6EHTh0kX/i+c7vDvOXPK4dPKy2+UTV7hXmq86X23qdOo8/pPTT8e7nLuarrlca7nuer21e2b36RueN87d9L158Rb/1tWeOT3dvfN6b/fF9/XfFt1+cif9zsu72Xcn7q28T7xf9EDtQdlD3YfVP1v+3Njv3H9qwHeg89HcR/cGhYPP/pH1jw9DBY+Zj8uGDYbrnjg+OTniP3L96fynQ89kzyaeF/6i/suuFxYvfvjV69fO0ZjRoZfyl5O/bXyl/erA6xmv28bCxh6+yXgzMV70VvvtwXfcdx3vo98PT+R8IH8o/2j5sfVT0Kf7kxmTk/8EA5jz/GMzLdsAAAAgY0hSTQAAeiUAAICDAAD5/wAAgOkAAHUwAADqYAAAOpgAABdvkl/FRgAAAFtJREFUeNpi/P//PwMlgImBQsA44C6giQENDAwM//HgBmLCAF/AMBLjBUeixf///48L7/+PCvZjU4fPAAc0AxywqcMXCwegGJ1NckL6jx5wpKYDxqGXEkkCgAEAmrqBIejdgngAAAAASUVORK5CYII=); -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by/bootstrap-table-group-by.js b/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by/bootstrap-table-group-by.js deleted file mode 100644 index 35c3b61a79..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by/bootstrap-table-group-by.js +++ /dev/null @@ -1,243 +0,0 @@ -/** - * @author: Dennis Hernández - * @webSite: http://djhvscf.github.io/Blog - * @version: v1.1.0 - */ - -!function ($) { - - 'use strict'; - - var originalRowAttr, - dataTTId = 'data-tt-id', - dataTTParentId = 'data-tt-parent-id', - obj = {}, - parentId = undefined; - - var getParentRowId = function (that, id) { - var parentRows = that.$body.find('tr').not('[' + 'data-tt-parent-id]'); - - for (var i = 0; i < parentRows.length; i++) { - if (i === id) { - return $(parentRows[i]).attr('data-tt-id'); - } - } - - return undefined; - }; - - var sumData = function (that, data) { - var sumRow = {}; - $.each(data, function (i, row) { - if (!row.IsParent) { - for (var prop in row) { - if (!isNaN(parseFloat(row[prop]))) { - if (that.columns[that.fieldsColumnsIndex[prop]].groupBySumGroup) { - if (sumRow[prop] === undefined) { - sumRow[prop] = 0; - } - sumRow[prop] += +row[prop]; - } - } - } - } - }); - return sumRow; - }; - - var rowAttr = function (row, index) { - //Call the User Defined Function - originalRowAttr.apply([row, index]); - - obj[dataTTId.toString()] = index; - - if (!row.IsParent) { - obj[dataTTParentId.toString()] = parentId === undefined ? index : parentId; - } else { - parentId = index; - delete obj[dataTTParentId.toString()]; - } - - return obj; - }; - - var setObjectKeys = function () { - // From https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/keys - Object.keys = function (o) { - if (o !== Object(o)) { - throw new TypeError('Object.keys called on a non-object'); - } - var k = [], - p; - for (p in o) { - if (Object.prototype.hasOwnProperty.call(o, p)) { - k.push(p); - } - } - return k; - } - }; - - var getDataArrayFromItem = function (that, item) { - var itemDataArray = []; - for (var i = 0; i < that.options.groupByField.length; i++) { - itemDataArray.push(item[that.options.groupByField[i]]); - } - - return itemDataArray; - }; - - var getNewRow = function (that, result, index) { - var newRow = {}; - for (var i = 0; i < that.options.groupByField.length; i++) { - newRow[that.options.groupByField[i].toString()] = result[index][0][that.options.groupByField[i]]; - } - - newRow.IsParent = true; - - return newRow; - }; - - var groupBy = function (array, f) { - var groups = {}; - $.each(array, function (i, o) { - var group = JSON.stringify(f(o)); - groups[group] = groups[group] || []; - groups[group].push(o); - }); - return Object.keys(groups).map(function (group) { - return groups[group]; - }); - }; - - var makeGrouped = function (that, data) { - var newData = [], - sumRow = {}; - - var result = groupBy(data, function (item) { - return getDataArrayFromItem(that, item); - }); - - for (var i = 0; i < result.length; i++) { - result[i].unshift(getNewRow(that, result, i)); - if (that.options.groupBySumGroup) { - sumRow = sumData(that, result[i]); - if (!$.isEmptyObject(sumRow)) { - result[i].push(sumRow); - } - } - } - - newData = newData.concat.apply(newData, result); - - if (!that.options.loaded && newData.length > 0) { - that.options.loaded = true; - that.options.originalData = that.options.data; - that.options.data = newData; - } - - return newData; - }; - - $.extend($.fn.bootstrapTable.defaults, { - groupBy: false, - groupByField: [], - groupBySumGroup: false, - groupByInitExpanded: undefined, //node, 'all' - //internal variables - loaded: false, - originalData: undefined - }); - - $.fn.bootstrapTable.methods.push('collapseAll', 'expandAll', 'refreshGroupByField'); - - $.extend($.fn.bootstrapTable.COLUMN_DEFAULTS, { - groupBySumGroup: false - }); - - var BootstrapTable = $.fn.bootstrapTable.Constructor, - _init = BootstrapTable.prototype.init, - _initData = BootstrapTable.prototype.initData; - - BootstrapTable.prototype.init = function () { - //Temporal validation - if (!this.options.sortName) { - if ((this.options.groupBy) && (this.options.groupByField.length > 0)) { - var that = this; - - // Compatibility: IE < 9 and old browsers - if (!Object.keys) { - $.fn.bootstrapTable.utils.objectKeys(); - } - - //Make sure that the internal variables are set correctly - this.options.loaded = false; - this.options.originalData = undefined; - - originalRowAttr = this.options.rowAttributes; - this.options.rowAttributes = rowAttr; - this.$el.off('post-body.bs.table').on('post-body.bs.table', function () { - that.$el.treetable({ - expandable: true, - onNodeExpand: function () { - if (that.options.height) { - that.resetHeader(); - } - }, - onNodeCollapse: function () { - if (that.options.height) { - that.resetHeader(); - } - } - }, true); - - if (that.options.groupByInitExpanded !== undefined) { - if (typeof that.options.groupByInitExpanded === 'number') { - that.expandNode(that.options.groupByInitExpanded); - } else if (that.options.groupByInitExpanded.toLowerCase() === 'all') { - that.expandAll(); - } - } - }); - } - } - _init.apply(this, Array.prototype.slice.apply(arguments)); - }; - - BootstrapTable.prototype.initData = function (data, type) { - //Temporal validation - if (!this.options.sortName) { - if ((this.options.groupBy) && (this.options.groupByField.length > 0)) { - - this.options.groupByField = typeof this.options.groupByField === 'string' ? - this.options.groupByField.replace('[', '').replace(']', '') - .replace(/ /g, '').toLowerCase().split(',') : this.options.groupByField; - - data = makeGrouped(this, data ? data : this.options.data); - } - } - _initData.apply(this, [data, type]); - }; - - BootstrapTable.prototype.expandAll = function () { - this.$el.treetable('expandAll'); - }; - - BootstrapTable.prototype.collapseAll = function () { - this.$el.treetable('collapseAll'); - }; - - BootstrapTable.prototype.expandNode = function (id) { - id = getParentRowId(this, id); - if (id !== undefined) { - this.$el.treetable('expandNode', id); - } - }; - - BootstrapTable.prototype.refreshGroupByField = function (groupByFields) { - if (!$.fn.bootstrapTable.utils.compareObjects(this.options.groupByField, groupByFields)) { - this.options.groupByField = groupByFields; - this.load(this.options.originalData); - } - }; -}(jQuery); diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by/extension.json deleted file mode 100644 index 1d6d838808..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/group-by/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Group By", - "version": "1.1.0", - "description": "Plugin to group the data by fields.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/group-by", - "example": "#", - - "plugins": [{ - "name": "bootstrap-table-group-by", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/group-by" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/i18n-enhance/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/i18n-enhance/extension.json deleted file mode 100644 index a2b018029c..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/i18n-enhance/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "i18n Enhance", - "version": "1.0.0", - "description": "Plugin to add i18n API in order to change column's title and table locale.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/i18n-enhance", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/i18n-enhance.html", - - "plugins": [{ - "name": "bootstrap-table-i18n-enhance", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/i18n-enhance" - }], - - "author": { - "name": "Jewway", - "image": "https://avatars0.githubusercontent.com/u/3501899" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/key-events/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/key-events/extension.json deleted file mode 100644 index 966f6f8f29..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/key-events/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Key Events", - "version": "1.0.0", - "description": "Plugin to support the key events in the bootstrap table.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/key-events", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/key-events.html", - - "plugins": [{ - "name": "bootstrap-table-key-events", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/key-events" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/mobile/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/mobile/extension.json deleted file mode 100644 index 433eb77fe9..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/mobile/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Mobile", - "version": "1.1.0", - "description": "Plugin to support the responsive feature.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/mobile", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/mobile.html", - - "plugins": [{ - "name": "bootstrap-table-mobile", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/mobile" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/multi-column-toggle/bootstrap-table-multi-toggle.js b/InvenTree/InvenTree/static/bootstrap-table/extensions/multi-column-toggle/bootstrap-table-multi-toggle.js deleted file mode 100644 index 4cb110bd89..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/multi-column-toggle/bootstrap-table-multi-toggle.js +++ /dev/null @@ -1,88 +0,0 @@ -/** - * @author Homer Glascock - * @version: v1.0.0 - */ - - !function ($) { - "use strict"; - - var sprintf = $.fn.bootstrapTable.utils.sprintf; - - var reInit = function (self) { - self.initHeader(); - self.initSearch(); - self.initPagination(); - self.initBody(); - }; - - $.extend($.fn.bootstrapTable.defaults, { - showToggleBtn: false, - multiToggleDefaults: [], //column names go here - }); - - $.fn.bootstrapTable.methods.push('hideAllColumns', 'showAllColumns'); - - var BootstrapTable = $.fn.bootstrapTable.Constructor, - _initToolbar = BootstrapTable.prototype.initToolbar; - - BootstrapTable.prototype.initToolbar = function () { - - _initToolbar.apply(this, Array.prototype.slice.apply(arguments)); - - var that = this, - $btnGroup = this.$toolbar.find('>.btn-group'); - - if (typeof this.options.multiToggleDefaults === 'string') { - this.options.multiToggleDefaults = JSON.parse(this.options.multiToggleDefaults); - } - - if (this.options.showToggleBtn && this.options.showColumns) { - var showbtn = "", - hidebtn = ""; - - $btnGroup.append(showbtn + hidebtn); - - $btnGroup.find('#showAllBtn').click(function () { that.showAllColumns(); - $btnGroup.find('#hideAllBtn').toggleClass('hidden'); - $btnGroup.find('#showAllBtn').toggleClass('hidden'); - }); - $btnGroup.find('#hideAllBtn').click(function () { that.hideAllColumns(); - $btnGroup.find('#hideAllBtn').toggleClass('hidden'); - $btnGroup.find('#showAllBtn').toggleClass('hidden'); - }); - } - }; - - BootstrapTable.prototype.hideAllColumns = function () { - var that = this, - defaults = that.options.multiToggleDefaults; - - $.each(this.columns, function (index, column) { - //if its one of the defaults dont touch it - if (defaults.indexOf(column.field) == -1 && column.switchable) { - column.visible = false; - var $items = that.$toolbar.find('.keep-open input').prop('disabled', false); - $items.filter(sprintf('[value="%s"]', index)).prop('checked', false); - } - }); - - reInit(that); - }; - - BootstrapTable.prototype.showAllColumns = function () { - var that = this; - $.each(this.columns, function (index, column) { - if (column.switchable) { - column.visible = true; - } - - var $items = that.$toolbar.find('.keep-open input').prop('disabled', false); - $items.filter(sprintf('[value="%s"]', index)).prop('checked', true); - }); - - reInit(that); - - that.toggleColumn(0, that.columns[0].visible, false); - }; - -}(jQuery); \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/multi-column-toggle/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/multi-column-toggle/extension.json deleted file mode 100644 index e27efdc881..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/multi-column-toggle/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Multi Column Toggle", - "version": "1.0.0", - "description": "Allows hiding and showing of multiple columns at once.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/multi-column-toggle", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/multi-column-toggle.html", - - "plugins": [{ - "name": "multi-column-toggle", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/multi-column-toggle" - }], - - "author": { - "name": "Homer Glascock", - "image": "https://avatars1.githubusercontent.com/u/5546710" - } -} diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-search/bootstrap-table-multiple-search.js b/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-search/bootstrap-table-multiple-search.js deleted file mode 100644 index a8e264e41f..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-search/bootstrap-table-multiple-search.js +++ /dev/null @@ -1,71 +0,0 @@ -/** - * @author: Dennis Hernández - * @webSite: http://djhvscf.github.io/Blog - * @version: v1.0.0 - */ - -!function ($) { - - 'use strict'; - - $.extend($.fn.bootstrapTable.defaults, { - multipleSearch: false, - delimeter: " " - }); - - var BootstrapTable = $.fn.bootstrapTable.Constructor, - _initSearch = BootstrapTable.prototype.initSearch; - - BootstrapTable.prototype.initSearch = function () { - if (this.options.multipleSearch) { - if (this.searchText === undefined) { - return; - } - var strArray = this.searchText.split(this.options.delimeter), - that = this, - f = $.isEmptyObject(this.filterColumns) ? null : this.filterColumns, - dataFiltered = []; - - if (strArray.length === 1) { - _initSearch.apply(this, Array.prototype.slice.apply(arguments)); - } else { - for (var i = 0; i < strArray.length; i++) { - var str = strArray[i].trim(); - dataFiltered = str ? $.grep(dataFiltered.length === 0 ? this.options.data : dataFiltered, function (item, i) { - for (var key in item) { - key = $.isNumeric(key) ? parseInt(key, 10) : key; - var value = item[key], - column = that.columns[that.fieldsColumnsIndex[key]], - j = $.inArray(key, that.header.fields); - - // Fix #142: search use formated data - if (column && column.searchFormatter) { - value = $.fn.bootstrapTable.utils.calculateObjectValue(column, - that.header.formatters[j], [value, item, i], value); - } - - var index = $.inArray(key, that.header.fields); - if (index !== -1 && that.header.searchables[index] && (typeof value === 'string' || typeof value === 'number')) { - if (that.options.strictSearch) { - if ((value + '').toLowerCase() === str) { - return true; - } - } else { - if ((value + '').toLowerCase().indexOf(str) !== -1) { - return true; - } - } - } - } - return false; - }) : this.data; - } - - this.data = dataFiltered; - } - } else { - _initSearch.apply(this, Array.prototype.slice.apply(arguments)); - } - }; - -}(jQuery); diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-search/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-search/extension.json deleted file mode 100644 index 5160d1a98b..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-search/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Multiple Search", - "version": "1.0.0", - "description": "Plugin to support the multiple search.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/multiple-search", - "example": "#", - - "plugins": [{ - "name": "bootstrap-table-multiple-search", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/multiple-search" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.css b/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.css deleted file mode 100644 index 81da76b5f3..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.css +++ /dev/null @@ -1,17 +0,0 @@ -.multiple-select-row-selected { - background: lightBlue -} - -.table tbody tr:hover td, -.table tbody tr:hover th { - background-color: transparent; -} - - -.table-striped tbody tr:nth-child(odd):hover td { - background-color: #F9F9F9; -} - -.fixed-table-container tbody .selected td { - background: lightBlue; -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.js b/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.js deleted file mode 100644 index 597b28b8f7..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-selection-row/bootstrap-table-multiple-selection-row.js +++ /dev/null @@ -1,127 +0,0 @@ -/** - * @author: Dennis Hernández - * @webSite: http://djhvscf.github.io/Blog - * @version: v1.0.0 - */ - -!function ($) { - - 'use strict'; - - document.onselectstart = function() { - return false; - }; - - var getTableObjectFromCurrentTarget = function (currentTarget) { - currentTarget = $(currentTarget); - return currentTarget.is("table") ? currentTarget : currentTarget.parents().find(".table"); - }; - - var getRow = function (target) { - target = $(target); - return target.parent().parent(); - }; - - var onRowClick = function (e) { - var that = getTableObjectFromCurrentTarget(e.currentTarget); - - if (window.event.ctrlKey) { - toggleRow(e.currentTarget, that, false, false); - } - - if (window.event.button === 0) { - if (!window.event.ctrlKey && !window.event.shiftKey) { - clearAll(that); - toggleRow(e.currentTarget, that, false, false); - } - - if (window.event.shiftKey) { - selectRowsBetweenIndexes([that.bootstrapTable("getOptions").multipleSelectRowLastSelectedRow.rowIndex, e.currentTarget.rowIndex], that) - } - } - }; - - var onCheckboxChange = function (e) { - var that = getTableObjectFromCurrentTarget(e.currentTarget); - clearAll(that); - toggleRow(getRow(e.currentTarget), that, false, false); - }; - - var toggleRow = function (row, that, clearAll, useShift) { - if (clearAll) { - row = $(row); - that.bootstrapTable("getOptions").multipleSelectRowLastSelectedRow = undefined; - row.removeClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass); - that.bootstrapTable("uncheck", row.data("index")); - } else { - that.bootstrapTable("getOptions").multipleSelectRowLastSelectedRow = row; - row = $(row); - if (useShift) { - row.addClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass); - that.bootstrapTable("check", row.data("index")); - } else { - if(row.hasClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass)) { - row.removeClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass) - that.bootstrapTable("uncheck", row.data("index")); - } else { - row.addClass(that.bootstrapTable("getOptions").multipleSelectRowCssClass); - that.bootstrapTable("check", row.data("index")); - } - } - } - }; - - var selectRowsBetweenIndexes = function (indexes, that) { - indexes.sort(function(a, b) { - return a - b; - }); - - for (var i = indexes[0]; i <= indexes[1]; i++) { - toggleRow(that.bootstrapTable("getOptions").multipleSelectRowRows[i-1], that, false, true); - } - }; - - var clearAll = function (that) { - for (var i = 0; i < that.bootstrapTable("getOptions").multipleSelectRowRows.length; i++) { - toggleRow(that.bootstrapTable("getOptions").multipleSelectRowRows[i], that, true, false); - } - }; - - $.extend($.fn.bootstrapTable.defaults, { - multipleSelectRow: false, - multipleSelectRowCssClass: 'multiple-select-row-selected', - //internal variables used by the extension - multipleSelectRowLastSelectedRow: undefined, - multipleSelectRowRows: [] - }); - - var BootstrapTable = $.fn.bootstrapTable.Constructor, - _init = BootstrapTable.prototype.init, - _initBody = BootstrapTable.prototype.initBody; - - BootstrapTable.prototype.init = function () { - if (this.options.multipleSelectRow) { - var that = this; - - //Make sure that the internal variables have the correct value - this.options.multipleSelectRowLastSelectedRow = undefined; - this.options.multipleSelectRowRows = []; - - this.$el.on("post-body.bs.table", function (e) { - setTimeout(function () { - that.options.multipleSelectRowRows = that.$body.children(); - that.options.multipleSelectRowRows.click(onRowClick); - that.options.multipleSelectRowRows.find("input[type=checkbox]").change(onCheckboxChange); - }, 1); - }); - } - - _init.apply(this, Array.prototype.slice.apply(arguments)); - }; - - BootstrapTable.prototype.clearAllMultipleSelectionRow = function () { - clearAll(this); - }; - - $.fn.bootstrapTable.methods.push('clearAllMultipleSelectionRow'); -}(jQuery); diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-selection-row/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-selection-row/extension.json deleted file mode 100644 index 69d4a9effa..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-selection-row/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Multiple Selection Row", - "version": "1.0.0", - "description": "Plugin to enable the multiple selection row. You can use the ctrl+click to select one row or use ctrl+shift+click to select a range of rows.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/multiple-selection-row", - "example": "", - - "plugins": [{ - "name": "bootstrap-table-multiple-selection-row", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/multiple-selection-row" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-sort/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-sort/extension.json deleted file mode 100644 index 580082a26b..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/multiple-sort/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Multiple Sort", - "version": "1.1.0", - "description": "Plugin to support the multiple sort.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/multiple-sort", - "example": "#", - - "plugins": [{ - "name": "bootstrap-table-multiple-sort", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/multiple-sort" - }], - - "author": { - "name": "dimbslmh", - "image": "https://avatars1.githubusercontent.com/u/745635" - } -} diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/natural-sorting/bootstrap-table-natural-sorting.js b/InvenTree/InvenTree/static/bootstrap-table/extensions/natural-sorting/bootstrap-table-natural-sorting.js deleted file mode 100644 index 30e6521760..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/natural-sorting/bootstrap-table-natural-sorting.js +++ /dev/null @@ -1,67 +0,0 @@ -/** - * @author: Brian Huisman - * @webSite: http://www.greywyvern.com - * @version: v1.0.0 - * JS functions to allow natural sorting on bootstrap-table columns - * add data-sorter="alphanum" or data-sorter="numericOnly" to any th - * - * @update Dennis Hernández - * @update Duane May - */ - -function alphanum(a, b) { - function chunkify(t) { - var tz = [], - x = 0, - y = -1, - n = 0, - i, - j; - - while (i = (j = t.charAt(x++)).charCodeAt(0)) { - var m = (i === 46 || (i >= 48 && i <= 57)); - if (m !== n) { - tz[++y] = ""; - n = m; - } - tz[y] += j; - } - return tz; - } - - function stringfy(v) { - if (typeof(v) === "number") { - v = "" + v; - } - if (!v) { - v = ""; - } - return v; - } - - var aa = chunkify(stringfy(a)); - var bb = chunkify(stringfy(b)); - - for (x = 0; aa[x] && bb[x]; x++) { - if (aa[x] !== bb[x]) { - var c = Number(aa[x]), - d = Number(bb[x]); - - if (c == aa[x] && d == bb[x]) { - return c - d; - } else { - return (aa[x] > bb[x]) ? 1 : -1; - } - } - } - return aa.length - bb.length; -} - -function numericOnly(a, b) { - function stripNonNumber(s) { - s = s.replace(new RegExp(/[^0-9]/g), ""); - return parseInt(s, 10); - } - - return stripNonNumber(a) - stripNonNumber(b); -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/natural-sorting/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/natural-sorting/extension.json deleted file mode 100644 index 06bf4e4ece..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/natural-sorting/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Natural Sorting", - "version": "1.0.0", - "description": "Plugin to support the natural sorting.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/natural-sorting", - "example": "#", - - "plugins": [{ - "name": "bootstrap-table-natural-sorting", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/natural-sorting" - }], - - "author": { - "name": "GreyWyvern", - "image": "https://avatars1.githubusercontent.com/u/137631" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/pipeline/LICENSE b/InvenTree/InvenTree/static/bootstrap-table/extensions/pipeline/LICENSE deleted file mode 100644 index 608dadfb85..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/pipeline/LICENSE +++ /dev/null @@ -1,21 +0,0 @@ -(The MIT License) - -Copyright (c) 2019 doug-the-guy - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in -all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN -THE SOFTWARE. diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/pipeline/README.md b/InvenTree/InvenTree/static/bootstrap-table/extensions/pipeline/README.md deleted file mode 100644 index c5019431f2..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/pipeline/README.md +++ /dev/null @@ -1,92 +0,0 @@ -# Bootstrap Table Pipelining - -Use Plugin: [bootstrap-table-pipeline] - -This plugin enables client side data caching for server side requests which will -eliminate the need to issue a new request every page change. This will allow -for a performance balance for a large data set between returning all data at once -(client side paging) and a new server side request (server side paging). - -There are two new options: -- usePipeline: enables this feature -- pipelineSize: the size of each cache window - -The size of the pipeline must be evenly divisible by the current page size. This is -assured by rounding up to the nearest evenly divisible value. For example, if -the pipeline size is 4990 and the current page size is 25, then pipeline size will -be dynamically set to 5000. - -The cache windows are computed based on the pipeline size and the total number of rows -returned by the server side query. For example, with pipeline size 500 and total rows -1300, the cache windows will be: - -[{'lower': 0, 'upper': 499}, {'lower': 500, 'upper': 999}, {'lower': 1000, 'upper': 1499}] - -Using the limit (i.e. the pipelineSize) and offset parameters, the server side request -**MUST** return only the data in the requested cache window **AND** the total number of rows. -To wit, the server side code must use the offset and limit parameters to prepare the response -data. - -On a page change, the new offset is checked if it is within the current cache window. If so, -the requested page data is returned from the cached data set. Otherwise, a new server side -request will be issued for the new cache window. - -The current cached data is only invalidated on these events: - - sorting - - searching - - page size change - - page change moves into a new cache window - -There are two new events: -- cached-data-hit.bs.table: issued when cached data is used on a page change -- cached-data-reset.bs.table: issued when the cached data is invalidated and new server side request is issued - -## Features - -* Created with Bootstrap 4 - -## Usage - -``` -# assumed import of bootstrap and bootstrap-table assets - -... - - - - - - -
TypeValueDate
-``` - -## Options - -### usePipeline - -* type: Boolean -* description: Set true to enable pipelining -* default: `false` - -## pipelineSize - -* type: Integer -* description: Size of each cache window. Must be greater than 0 -* default: `1000` - -## Events - -### onCachedDataHit(cached-data-hit.bs.table) - -* Fires when paging was able to use the locally cached data. - -### onCachedDataReset(cached-data-reset.bs.table) - -* Fires when the locally cached data needed to be reset (i.e. on sorting, searching, page size change or paged out of current cache window) diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/pipeline/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/pipeline/extension.json deleted file mode 100644 index de569c848c..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/pipeline/extension.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "name": "Pipeline", - "version": "1.0.0", - "description": "Plugin to support a hybrid approach to server/client side paging.", - "url": "", - "example": "#", - - "plugins": [{ - "name": "bootstrap-table-pipeline", - "url": "" - }], - - "author": { - "name": "doug-the-guy", - "image": "" - } -} - diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/reorder-columns/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/reorder-columns/extension.json deleted file mode 100644 index a3cc778318..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/reorder-columns/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Reorder Columns", - "version": "1.1.0", - "description": "Plugin to support the reordering columns feature.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/reorder-columns", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/reorder-columns.html", - - "plugins": [{ - "name": "bootstrap-table-reorder-columns", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/reorder-columns" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/reorder-rows/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/reorder-rows/extension.json deleted file mode 100644 index 69b978fb41..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/reorder-rows/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Reorder Rows", - "version": "1.0.0", - "description": "Plugin to support the reordering rows feature.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/reorder-rows", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/reorder-rows.html", - - "plugins": [{ - "name": "bootstrap-table-reorder-rows", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/reorder-rows" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/resizable/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/resizable/extension.json deleted file mode 100644 index f428c12beb..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/resizable/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Resizable", - "version": "1.1.0", - "description": "Plugin to support the resizable feature.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/resizable", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/resizable.html", - - "plugins": [{ - "name": "bootstrap-table-resizable", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/resizable" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/select2-filter/bootstrap-table-select2-filter.js b/InvenTree/InvenTree/static/bootstrap-table/extensions/select2-filter/bootstrap-table-select2-filter.js deleted file mode 100644 index 6bfa915c21..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/select2-filter/bootstrap-table-select2-filter.js +++ /dev/null @@ -1,332 +0,0 @@ -/** - * @author: Jewway - * @version: v1.1.1 - */ - -! function ($) { - 'use strict'; - - function getCurrentHeader(that) { - var header = that.$header; - if (that.options.height) { - header = that.$tableHeader; - } - - return header; - } - - function initFilterValues(that) { - if (!$.isEmptyObject(that.filterColumnsPartial)) { - var $header = getCurrentHeader(that); - - $.each(that.columns, function (idx, column) { - var value = that.filterColumnsPartial[column.field]; - - if (column.filter) { - if (column.filter.setFilterValue) { - var $filter = $header.find('[data-field=' + column.field + '] .filter'); - column.filter.setFilterValue($filter, column.field, value); - } else { - var $ele = $header.find('[data-filter-field=' + column.field + ']'); - switch (column.filter.type) { - case 'input': - $ele.val(value); - case 'select': - $ele.val(value).trigger('change'); - } - } - } - }); - } - } - - function createFilter(that, header) { - var enableFilter = false, - isVisible, - html, - timeoutId = 0; - - $.each(that.columns, function (i, column) { - isVisible = 'hidden'; - html = null; - - if (!column.visible) { - return; - } - - if (!column.filter) { - html = $('
'); - } else { - var filterClass = column.filter.class ? ' ' + column.filter.class : ''; - html = $('
'); - - if (column.searchable) { - enableFilter = true; - isVisible = 'visible' - } - - if (column.filter.template) { - html.append(column.filter.template(that, column, isVisible)); - } else { - var $filter = $(that.options.filterTemplate[column.filter.type.toLowerCase()](that, column, isVisible)); - - switch (column.filter.type) { - case 'input': - var cpLock = true; - $filter.off('compositionstart').on('compositionstart', function (event) { - cpLock = false; - }); - - $filter.off('compositionend').on('compositionend', function (event) { - cpLock = true; - var $input = $(this); - clearTimeout(timeoutId); - timeoutId = setTimeout(function () { - that.onColumnSearch(event, column.field, $input.val()); - }, that.options.searchTimeOut); - }); - - $filter.off('keyup').on('keyup', function (event) { - if (cpLock) { - var $input = $(this); - clearTimeout(timeoutId); - timeoutId = setTimeout(function () { - that.onColumnSearch(event, column.field, $input.val()); - }, that.options.searchTimeOut); - } - }); - - $filter.off('mouseup').on('mouseup', function (event) { - var $input = $(this), - oldValue = $input.val(); - - if (oldValue === "") { - return; - } - - setTimeout(function () { - var newValue = $input.val(); - - if (newValue === "") { - clearTimeout(timeoutId); - timeoutId = setTimeout(function () { - that.onColumnSearch(event, column.field, newValue); - }, that.options.searchTimeOut); - } - }, 1); - }); - break; - case 'select': - $filter.on('select2:select', function (event) { - that.onColumnSearch(event, column.field, $(this).val()); - }); - - $filter.on("select2:unselecting", function (event) { - var $select2 = $(this); - event.preventDefault(); - $select2.val(null).trigger('change'); - that.searchText = undefined; - that.onColumnSearch(event, column.field, $select2.val()); - }); - break; - } - - html.append($filter); - } - } - - $.each(header.children().children(), function (i, tr) { - tr = $(tr); - if (tr.data('field') === column.field) { - tr.find('.fht-cell').append(html); - return false; - } - }); - }); - - if (!enableFilter) { - header.find('.filter').hide(); - } - } - - function initSelect2(that) { - var $header = getCurrentHeader(that); - - $.each(that.columns, function (idx, column) { - if (column.filter && column.filter.type === 'select') { - var $selectEle = $header.find('select[data-filter-field="' + column.field + '"]'); - - if ($selectEle.length > 0 && !$selectEle.data().select2) { - var select2Opts = { - placeholder: "", - allowClear: true, - data: column.filter.data, - dropdownParent: that.$el.closest(".bootstrap-table") - }; - - $selectEle.select2(select2Opts); - } - } - }); - } - - $.extend($.fn.bootstrapTable.defaults, { - filter: false, - filterValues: {}, - filterTemplate: { - input: function (instance, column, isVisible) { - return ''; - }, - select: function (instance, column, isVisible) { - return ''; - } - }, - onColumnSearch: function (field, text) { - return false; - } - }); - - $.extend($.fn.bootstrapTable.COLUMN_DEFAULTS, { - filter: undefined - }); - - $.extend($.fn.bootstrapTable.Constructor.EVENTS, { - 'column-search.bs.table': 'onColumnSearch' - }); - - var BootstrapTable = $.fn.bootstrapTable.Constructor, - _init = BootstrapTable.prototype.init, - _initHeader = BootstrapTable.prototype.initHeader, - _initSearch = BootstrapTable.prototype.initSearch; - - BootstrapTable.prototype.init = function () { - //Make sure that the filtercontrol option is set - if (this.options.filter) { - var that = this; - - if (that.options.filterTemplate) { - that.options.filterTemplate = $.extend({}, $.fn.bootstrapTable.defaults.filterTemplate, that.options.filterTemplate); - } - - if (!$.isEmptyObject(that.options.filterValues)) { - that.filterColumnsPartial = that.options.filterValues; - that.options.filterValues = {}; - } - - this.$el.on('reset-view.bs.table', function () { - //Create controls on $tableHeader if the height is set - if (!that.options.height) { - return; - } - - //Avoid recreate the controls - if (that.$tableHeader.find('select').length > 0 || that.$tableHeader.find('input').length > 0) { - return; - } - - createFilter(that, that.$tableHeader); - }).on('post-header.bs.table', function () { - var timeoutId = 0; - - initSelect2(that); - clearTimeout(timeoutId); - timeoutId = setTimeout(function () { - initFilterValues(that); - }, that.options.searchTimeOut - 1000); - }).on('column-switch.bs.table', function (field, checked) { - initFilterValues(that); - }); - } - - _init.apply(this, Array.prototype.slice.apply(arguments)); - }; - - BootstrapTable.prototype.initHeader = function () { - _initHeader.apply(this, Array.prototype.slice.apply(arguments)); - if (this.options.filter) { - createFilter(this, this.$header); - } - }; - - BootstrapTable.prototype.initSearch = function () { - var that = this, - filterValues = that.filterColumnsPartial; - - // Filter for client - if (that.options.sidePagination === 'client') { - this.data = $.grep(this.data, function (row, idx) { - for (var field in filterValues) { - var column = that.columns[that.fieldsColumnsIndex[field]], - filterValue = filterValues[field].toLowerCase(), - rowValue = row[field]; - - rowValue = $.fn.bootstrapTable.utils.calculateObjectValue( - that.header, - that.header.formatters[$.inArray(field, that.header.fields)], [rowValue, row, idx], rowValue); - - if (column.filterStrictSearch) { - if (!($.inArray(field, that.header.fields) !== -1 && - (typeof rowValue === 'string' || typeof rowValue === 'number') && - rowValue.toString().toLowerCase() === filterValue.toString().toLowerCase())) { - return false; - } - } else { - if (!($.inArray(field, that.header.fields) !== -1 && - (typeof rowValue === 'string' || typeof rowValue === 'number') && - (rowValue + '').toLowerCase().indexOf(filterValue) !== -1)) { - return false; - } - } - } - - return true; - }); - } - - _initSearch.apply(this, Array.prototype.slice.apply(arguments)); - }; - - BootstrapTable.prototype.onColumnSearch = function (event, field, value) { - if ($.isEmptyObject(this.filterColumnsPartial)) { - this.filterColumnsPartial = {}; - } - - if (value) { - this.filterColumnsPartial[field] = value; - } else { - delete this.filterColumnsPartial[field]; - } - - this.options.pageNumber = 1; - this.onSearch(event); - this.trigger('column-search', field, value); - }; - - BootstrapTable.prototype.setSelect2Data = function (field, data) { - var that = this, - $header = getCurrentHeader(that), - $selectEle = $header.find('select[data-filter-field=\"' + field + '\"]'); - $selectEle.empty(); - $selectEle.select2({ - data: data, - placeholder: "", - allowClear: true, - dropdownParent: that.$el.closest(".bootstrap-table") - }); - - $.each(this.columns, function (idx, column) { - if (column.field === field) { - column.filter.data = data; - return false; - } - }); - }; - - BootstrapTable.prototype.setFilterValues = function (values) { - this.filterColumnsPartial = values; - }; - - $.fn.bootstrapTable.methods.push('setSelect2Data'); - $.fn.bootstrapTable.methods.push('setFilterValues'); - -}(jQuery); diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/select2-filter/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/select2-filter/extension.json deleted file mode 100644 index edbc589c0b..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/select2-filter/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Select2 Filter", - "version": "1.1.0", - "description": "Plugin to add select2 filter on the top of the columns in order to filter the data.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/select2-filter", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/select2-filter.html", - - "plugins": [{ - "name": "bootstrap-table-select2-filter", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/select2-filter" - }], - - "author": { - "name": "Jewway", - "image": "https://avatars0.githubusercontent.com/u/3501899" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/sticky-header/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/sticky-header/extension.json deleted file mode 100644 index 70ae30ff8b..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/sticky-header/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Sticky Header", - "version": "1.0.0", - "description": "An extension which provides a sticky header for table columns when scrolling on a long page and / or table. Works for tables with many columns and narrow width with horizontal scrollbars too.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/sticky-header", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/sticky-header.html", - - "plugins": [{ - "name": "bootstrap-table-sticky-header", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/sticky-header" - }], - - "author": { - "name": "vinzloh", - "image": "https://avatars0.githubusercontent.com/u/5501845" - } -} diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/toolbar/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/toolbar/extension.json deleted file mode 100644 index f33ae2c475..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/toolbar/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Toolbar", - "version": "2.0.0", - "description": "Plugin to support the advanced search.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/toolbar", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/toolbar.html", - - "plugins": [{ - "name": "bootstrap-table-toolbar", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/toolbar" - }], - - "author": { - "name": "djhvscf", - "image": "https://avatars1.githubusercontent.com/u/4496763" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.css b/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.css deleted file mode 100644 index 481ca89cd8..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.css +++ /dev/null @@ -1 +0,0 @@ -.table:not(.table-condensed)>tbody>tr>td.treenode{padding-top:0;padding-bottom:0;border-bottom:solid #fff 1px}.table:not(.table-condensed)>tbody>tr:last-child>td.treenode{border-bottom:none}.treenode .text{float:left;display:block;padding-top:6px;padding-bottom:6px}.treenode .vertical,.treenode .vertical.last{float:left;display:block;width:1px;border-left:dashed silver 1px;height:38px;margin-left:8px}.treenode .vertical.last{height:15px}.treenode .space,.treenode .node{float:left;display:block;width:15px;height:5px;margin-top:15px}.treenode .node{border-top:dashed silver 1px} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.js b/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.js deleted file mode 100644 index a8ff876d11..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.js +++ /dev/null @@ -1,130 +0,0 @@ -/** - * @author: KingYang - * @webSite: https://github.com/kingyang - * @version: v1.0.0 - */ - -! function ($) { - - 'use strict'; - - $.extend($.fn.bootstrapTable.defaults, { - treeShowField: null, - idField: 'id', - parentIdField: 'pid', - treeVerticalcls: 'vertical', - treeVerticalLastcls: 'vertical last', - treeSpacecls: 'space', - treeNodecls: 'node', - treeCellcls: 'treenode', - treeTextcls: 'text', - onTreeFormatter: function (row) { - var that = this, - options = that.options, - level = row._level || 0, - plevel = row._parent && row._parent._level || 0, - paddings = []; - for (var i = 0; i < plevel; i++) { - paddings.push(''); - paddings.push(''); - } - - for (var i = plevel; i < level; i++) { - if (row._last && i === (level - 1)) { - paddings.push(''); - } else { - paddings.push(''); - } - paddings.push(''); - } - return paddings.join(''); - }, onGetNodes: function (row, data) { - var that = this; - var nodes = []; - $.each(data, function (i, item) { - if (row[that.options.idField] === item[that.options.parentIdField]) { - nodes.push(item); - } - }); - return nodes; - }, - onCheckLeaf: function (row, data) { - if (row.isLeaf !== undefined) { - return row.isLeaf; - } - return !row._nodes || !row._nodes.length; - }, onCheckRoot: function (row, data) { - var that = this; - return !row[that.options.parentIdField]; - } - }); - - var BootstrapTable = $.fn.bootstrapTable.Constructor, - _initRow = BootstrapTable.prototype.initRow, - _initHeader = BootstrapTable.prototype.initHeader; - - BootstrapTable.prototype.initHeader = function () { - var that = this; - _initHeader.apply(that, Array.prototype.slice.apply(arguments)); - var treeShowField = that.options.treeShowField; - if (treeShowField) { - $.each(this.header.fields, function (i, field) { - if (treeShowField === field) { - that.treeEnable = true; - var _formatter = that.header.formatters[i]; - var _class = [that.options.treeCellcls]; - if (that.header.classes[i]) { - _class.push(that.header.classes[i].split('"')[1] || ''); - } - that.header.classes[i] = ' class="' + _class.join(' ') + '"'; - that.header.formatters[i] = function (value, row, index) { - var colTree = [that.options.onTreeFormatter.apply(that, [row])]; - colTree.push(''); - if (_formatter) { - colTree.push(_formatter.apply(this, Array.prototype.slice.apply(arguments))); - } else { - colTree.push(value); - } - colTree.push(''); - return colTree.join(''); - }; - return false; - } - }); - } - }; - - var initNode = function (item, idx, data, parentDom) { - var that = this; - var nodes = that.options.onGetNodes.apply(that, [item, data]); - item._nodes = nodes; - parentDom.append(_initRow.apply(that, [item, idx, data, parentDom])); - var len = nodes.length - 1; - for (var i = 0; i <= len; i++) { - var node = nodes[i]; - node._level = item._level + 1; - node._parent = item; - if (i === len) - node._last = 1; - initNode.apply(that, [node, $.inArray(node, data), data, parentDom]); - } - }; - - - BootstrapTable.prototype.initRow = function (item, idx, data, parentDom) { - var that = this; - if (that.treeEnable) { - if (that.options.onCheckRoot.apply(that, [item, data])) { - if (item._level === undefined) { - item._level = 0; - } - initNode.apply(that, [item, idx, data, parentDom]); - return true; - } - return false; - - } - return _initRow.apply(that, Array.prototype.slice.apply(arguments)); - }; - -} (jQuery); diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.less b/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.less deleted file mode 100644 index fc8ceda3b9..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/bootstrap-table-tree-column.less +++ /dev/null @@ -1,43 +0,0 @@ - .table:not(.table-condensed) > tbody > tr > td.treenode { - padding-top: 0; - padding-bottom: 0; - border-bottom: solid #fff 1px; - } - - .table:not(.table-condensed) > tbody > tr:last-child > td.treenode { - border-bottom: none; - } - - .treenode { - .text { - float: left; - display: block; - padding-top: 6px; - padding-bottom: 6px; - } - .vertical, - .vertical.last { - float: left; - display: block; - width: 1px; - border-left: dashed silver 1px; - height: 38px; - margin-left: 8px; - } - .vertical.last { - height: 15px; - } - - .space, - .node { - float: left; - display: block; - width: 15px; - height: 5px; - margin-top: 15px; - } - - .node { - border-top: dashed silver 1px; - } - } \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/extension.json deleted file mode 100644 index 72ddaa5a13..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "Tree column", - "version": "1.0.0", - "description": "Plugin to support display tree data column.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/tree-column", - "example": "http://issues.wenzhixin.net.cn/bootstrap-table/#extensions/tree-column.html", - - "plugins": [{ - "name": "bootstrap-table-reorder-rows", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/tree-column" - }], - - "author": { - "name": "KingYang", - "image": "https://avatars3.githubusercontent.com/u/1540211" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/icon.png b/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/icon.png deleted file mode 100644 index e7453922fe..0000000000 Binary files a/InvenTree/InvenTree/static/bootstrap-table/extensions/tree-column/icon.png and /dev/null differ diff --git a/InvenTree/InvenTree/static/bootstrap-table/extensions/treegrid/extension.json b/InvenTree/InvenTree/static/bootstrap-table/extensions/treegrid/extension.json deleted file mode 100644 index 2c07e1f487..0000000000 --- a/InvenTree/InvenTree/static/bootstrap-table/extensions/treegrid/extension.json +++ /dev/null @@ -1,17 +0,0 @@ -{ - "name": "treegrid", - "version": "1.0.0", - "description": "Plugin to support the jquery treegrid.", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/treegrid", - "example": "https://github.com/wenzhixin/bootstrap-table-examples/blob/master/extensions/treegrid.html", - - "plugins": [{ - "name": "bootstrap-table-treegrid", - "url": "https://github.com/wenzhixin/bootstrap-table/tree/master/src/extensions/treegrid" - }], - - "author": { - "name": "foreveryang321", - "image": "https://avatars0.githubusercontent.com/u/5868190" - } -} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.css b/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.css new file mode 100644 index 0000000000..86ec3f217d --- /dev/null +++ b/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.css @@ -0,0 +1,790 @@ +/** + * @author Dustin Utecht + * https://github.com/wenzhixin/bootstrap-table/ + */ +.bootstrap-table .fixed-table-toolbar::after { + content: ""; + display: block; + clear: both; +} + +.bootstrap-table .fixed-table-toolbar .bs-bars, +.bootstrap-table .fixed-table-toolbar .search, +.bootstrap-table .fixed-table-toolbar .columns { + position: relative; + margin-top: 10px; + margin-bottom: 10px; +} + +.bootstrap-table .fixed-table-toolbar .columns .btn-group > .btn-group { + display: inline-block; + margin-left: -1px !important; +} + +.bootstrap-table .fixed-table-toolbar .columns .btn-group > .btn-group > .btn { + border-radius: 0; +} + +.bootstrap-table .fixed-table-toolbar .columns .btn-group > .btn-group:first-child > .btn { + border-top-left-radius: 4px; + border-bottom-left-radius: 4px; +} + +.bootstrap-table .fixed-table-toolbar .columns .btn-group > .btn-group:last-child > .btn { + border-top-right-radius: 4px; + border-bottom-right-radius: 4px; +} + +.bootstrap-table .fixed-table-toolbar .columns .dropdown-menu { + text-align: left; + max-height: 300px; + overflow: auto; + -ms-overflow-style: scrollbar; + z-index: 1001; +} + +.bootstrap-table .fixed-table-toolbar .columns label { + display: block; + padding: 3px 20px; + clear: both; + font-weight: normal; + line-height: 1.428571429; +} + +.bootstrap-table .fixed-table-toolbar .columns-left { + margin-right: 5px; +} + +.bootstrap-table .fixed-table-toolbar .columns-right { + margin-left: 5px; +} + +.bootstrap-table .fixed-table-toolbar .pull-right .dropdown-menu { + right: 0; + left: auto; +} + +.bootstrap-table .fixed-table-container { + position: relative; + clear: both; +} + +.bootstrap-table .fixed-table-container .table { + width: 100%; + margin-bottom: 0 !important; +} + +.bootstrap-table .fixed-table-container .table th, +.bootstrap-table .fixed-table-container .table td { + vertical-align: middle; + box-sizing: border-box; +} + +.bootstrap-table .fixed-table-container .table thead th { + vertical-align: bottom; + padding: 0; + margin: 0; +} + +.bootstrap-table .fixed-table-container .table thead th:focus { + outline: 0 solid transparent; +} + +.bootstrap-table .fixed-table-container .table thead th.detail { + width: 30px; +} + +.bootstrap-table .fixed-table-container .table thead th .th-inner { + padding: 0.75rem; + vertical-align: bottom; + overflow: hidden; + text-overflow: ellipsis; + white-space: nowrap; +} + +.bootstrap-table .fixed-table-container .table thead th .sortable { + cursor: pointer; + background-position: right; + background-repeat: no-repeat; + padding-right: 30px !important; +} + +.bootstrap-table .fixed-table-container .table thead th .both { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAQAAADYWf5HAAAAkElEQVQoz7X QMQ5AQBCF4dWQSJxC5wwax1Cq1e7BAdxD5SL+Tq/QCM1oNiJidwox0355mXnG/DrEtIQ6azioNZQxI0ykPhTQIwhCR+BmBYtlK7kLJYwWCcJA9M4qdrZrd8pPjZWPtOqdRQy320YSV17OatFC4euts6z39GYMKRPCTKY9UnPQ6P+GtMRfGtPnBCiqhAeJPmkqAAAAAElFTkSuQmCC"); +} + +.bootstrap-table .fixed-table-container .table thead th .asc { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAYAAAByUDbMAAAAZ0lEQVQ4y2NgGLKgquEuFxBPAGI2ahhWCsS/gDibUoO0gPgxEP8H4ttArEyuQYxAPBdqEAxPBImTY5gjEL9DM+wTENuQahAvEO9DMwiGdwAxOymGJQLxTyD+jgWDxCMZRsEoGAVoAADeemwtPcZI2wAAAABJRU5ErkJggg=="); +} + +.bootstrap-table .fixed-table-container .table thead th .desc { + background-image: url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAYAAAByUDbMAAAAZUlEQVQ4y2NgGAWjYBSggaqGu5FA/BOIv2PBIPFEUgxjB+IdQPwfC94HxLykus4GiD+hGfQOiB3J8SojEE9EM2wuSJzcsFMG4ttQgx4DsRalkZENxL+AuJQaMcsGxBOAmGvopk8AVz1sLZgg0bsAAAAASUVORK5CYII= "); +} + +.bootstrap-table .fixed-table-container .table tbody tr.selected td { + background-color: #fafafa; +} + +.bootstrap-table .fixed-table-container .table tbody tr.no-records-found td { + text-align: center; +} + +.bootstrap-table .fixed-table-container .table tbody tr .card-view { + display: flex; +} + +.bootstrap-table .fixed-table-container .table tbody tr .card-view .card-view-title { + font-weight: bold; + display: inline-block; + min-width: 30%; + width: auto !important; + text-align: left !important; +} + +.bootstrap-table .fixed-table-container .table tbody tr .card-view .card-view-value { + width: 100% !important; +} + +.bootstrap-table .fixed-table-container .table .bs-checkbox { + text-align: center; +} + +.bootstrap-table .fixed-table-container .table .bs-checkbox label { + margin-bottom: 0; +} + +.bootstrap-table .fixed-table-container .table .bs-checkbox label input[type="radio"], +.bootstrap-table .fixed-table-container .table .bs-checkbox label input[type="checkbox"] { + margin: 0 auto !important; +} + +.bootstrap-table .fixed-table-container .table.table-sm .th-inner { + padding: 0.3rem; +} + +.bootstrap-table .fixed-table-container.fixed-height:not(.has-footer) { + border-bottom: 1px solid #dbdbdb; +} + +.bootstrap-table .fixed-table-container.fixed-height.has-card-view { + border-top: 1px solid #dbdbdb; + border-bottom: 1px solid #dbdbdb; +} + +.bootstrap-table .fixed-table-container.fixed-height .fixed-table-border { + border-left: 1px solid #dbdbdb; + border-right: 1px solid #dbdbdb; +} + +.bootstrap-table .fixed-table-container.fixed-height .table thead th { + border-bottom: 1px solid #dbdbdb; +} + +.bootstrap-table .fixed-table-container.fixed-height .table-dark thead th { + border-bottom: 1px solid #32383e; +} + +.bootstrap-table .fixed-table-container .fixed-table-header { + overflow: hidden; +} + +.bootstrap-table .fixed-table-container .fixed-table-body { + overflow-x: auto; + overflow-y: auto; + height: 100%; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading { + align-items: center; + background: #fff; + display: flex; + justify-content: center; + position: absolute; + bottom: 0; + width: 100%; + z-index: 1000; + transition: visibility 0s, opacity 0.15s ease-in-out; + opacity: 0; + visibility: hidden; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.open { + visibility: visible; + opacity: 1; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap { + align-items: baseline; + display: flex; + justify-content: center; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .loading-text { + margin-right: 6px; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-wrap { + align-items: center; + display: flex; + justify-content: center; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-dot, +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-wrap::after, +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-wrap::before { + content: ""; + animation-duration: 1.5s; + animation-iteration-count: infinite; + animation-name: LOADING; + background: #363636; + border-radius: 50%; + display: block; + height: 5px; + margin: 0 4px; + opacity: 0; + width: 5px; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-dot { + animation-delay: 0.3s; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-wrap::after { + animation-delay: 0.6s; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.table-dark { + background: #363636; +} + +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.table-dark .animation-dot, +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.table-dark .animation-wrap::after, +.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.table-dark .animation-wrap::before { + background: #fff; +} + +.bootstrap-table .fixed-table-container .fixed-table-footer { + overflow: hidden; +} + +.bootstrap-table .fixed-table-pagination::after { + content: ""; + display: block; + clear: both; +} + +.bootstrap-table .fixed-table-pagination > .pagination-detail, +.bootstrap-table .fixed-table-pagination > .pagination { + margin-top: 10px; + margin-bottom: 10px; +} + +.bootstrap-table .fixed-table-pagination > .pagination-detail .pagination-info { + line-height: 34px; + margin-right: 5px; +} + +.bootstrap-table .fixed-table-pagination > .pagination-detail .page-list { + display: inline-block; +} + +.bootstrap-table .fixed-table-pagination > .pagination-detail .page-list .btn-group { + position: relative; + display: inline-block; + vertical-align: middle; +} + +.bootstrap-table .fixed-table-pagination > .pagination-detail .page-list .btn-group .dropdown-menu { + margin-bottom: 0; +} + +.bootstrap-table .fixed-table-pagination > .pagination ul.pagination { + margin: 0; +} + +.bootstrap-table .fixed-table-pagination > .pagination ul.pagination li.page-intermediate a { + color: #c8c8c8; +} + +.bootstrap-table .fixed-table-pagination > .pagination ul.pagination li.page-intermediate a::before { + content: '\2B05'; +} + +.bootstrap-table .fixed-table-pagination > .pagination ul.pagination li.page-intermediate a::after { + content: '\27A1'; +} + +.bootstrap-table .fixed-table-pagination > .pagination ul.pagination li.disabled a { + pointer-events: none; + cursor: default; +} + +.bootstrap-table.fullscreen { + position: fixed; + top: 0; + left: 0; + z-index: 1050; + width: 100% !important; + background: #fff; + height: calc(100vh); + overflow-y: scroll; +} + +.bootstrap-table.bootstrap4 .pagination-lg .page-link, .bootstrap-table.bootstrap5 .pagination-lg .page-link { + padding: .5rem 1rem; +} + +.bootstrap-table.bootstrap5 .float-left { + float: left; +} + +.bootstrap-table.bootstrap5 .float-right { + float: right; +} + +/* calculate scrollbar width */ +div.fixed-table-scroll-inner { + width: 100%; + height: 200px; +} + +div.fixed-table-scroll-outer { + top: 0; + left: 0; + visibility: hidden; + width: 200px; + height: 150px; + overflow: hidden; +} + +@keyframes LOADING { + 0% { + opacity: 0; + } + 50% { + opacity: 1; + } + to { + opacity: 0; + } +} + +@font-face { + font-family: 'bootstrap-table'; + src: url("fonts/bootstrap-table.eot?gmdfsp"); + src: url("fonts/bootstrap-table.eot") format("embedded-opentype"), url("fonts/bootstrap-table.ttf") format("truetype"), url("fonts/bootstrap-table.woff") format("woff"), url("fonts/bootstrap-table.svg") format("svg"); + font-weight: normal; + font-style: normal; + font-display: block; +} + +[class^="icon-"], +[class*=" icon-"] { + /* use !important to prevent issues with browser extensions that change fonts */ + font-family: 'bootstrap-table', sans-serif !important; + speak: none; + font-style: normal; + font-weight: normal; + font-variant: normal; + text-transform: none; + line-height: 1; + /* Better Font Rendering =========== */ + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +.icon-arrow-down-circle:before { + content: "\e907"; +} + +.icon-arrow-up-circle:before { + content: "\e908"; +} + +.icon-chevron-left:before { + content: "\e900"; +} + +.icon-chevron-right:before { + content: "\e901"; +} + +.icon-clock:before { + content: "\e90c"; +} + +.icon-copy:before { + content: "\e909"; +} + +.icon-download:before { + content: "\e90d"; +} + +.icon-list:before { + content: "\e902"; +} + +.icon-maximize:before { + content: "\1f5ce"; +} + +.icon-minus:before { + content: "\e90f"; +} + +.icon-move:before { + content: "\e903"; +} + +.icon-plus:before { + content: "\e90e"; +} + +.icon-printer:before { + content: "\e90b"; +} + +.icon-refresh-cw:before { + content: "\e904"; +} + +.icon-search:before { + content: "\e90a"; +} + +.icon-toggle-right:before { + content: "\e905"; +} + +.icon-trash-2:before { + content: "\e906"; +} + +.icon-sort-amount-asc:before { + content: "\ea4c"; +} + +.bootstrap-table * { + box-sizing: border-box; +} + +.bootstrap-table input.form-control, +.bootstrap-table select.form-control, +.bootstrap-table .btn { + border-radius: 4px; + background-color: #fff; + border: 1px solid #ccc; + padding: 9px 12px; +} + +.bootstrap-table select.form-control { + height: 35px; +} + +.bootstrap-table .btn { + outline: none; + cursor: pointer; +} + +.bootstrap-table .btn.active { + background-color: #ebebeb; +} + +.bootstrap-table .btn:focus, .bootstrap-table .btn:hover { + background-color: whitesmoke; +} + +.bootstrap-table .caret { + display: inline-block; + width: 0; + height: 0; + margin-left: 2px; + vertical-align: middle; + border-top: 4px dashed; + border-top: 4px solid; + border-right: 4px solid transparent; + border-left: 4px solid transparent; +} + +.bootstrap-table .detail-icon { + text-decoration: none; + color: #3679e4; +} + +.bootstrap-table .detail-icon:hover { + color: #154a9f; +} + +.bootstrap-table .fixed-table-toolbar .columns, +.bootstrap-table .fixed-table-toolbar .columns .btn-group { + display: inline-block; +} + +.bootstrap-table .fixed-table-toolbar .columns > .btn:not(:first-child):not(:last-child), +.bootstrap-table .fixed-table-toolbar .columns > .btn:not(:first-child):not(:last-child) > .btn, +.bootstrap-table .fixed-table-toolbar .columns > .btn-group:not(:first-child):not(:last-child), +.bootstrap-table .fixed-table-toolbar .columns > .btn-group:not(:first-child):not(:last-child) > .btn { + border-radius: 0; +} + +.bootstrap-table .fixed-table-toolbar .columns > .btn:not(:last-child):not(.dropdown-toggle), +.bootstrap-table .fixed-table-toolbar .columns > .btn:not(:last-child) > .btn, +.bootstrap-table .fixed-table-toolbar .columns > .btn-group:not(:last-child):not(.dropdown-toggle), +.bootstrap-table .fixed-table-toolbar .columns > .btn-group:not(:last-child) > .btn { + border-top-right-radius: 0; + border-bottom-right-radius: 0; + border-right: none; +} + +.bootstrap-table .fixed-table-toolbar .columns > .btn:not(:first-child):not(.dropdown-toggle), +.bootstrap-table .fixed-table-toolbar .columns > .btn:not(:first-child) > .btn, +.bootstrap-table .fixed-table-toolbar .columns > .btn-group:not(:first-child):not(.dropdown-toggle), +.bootstrap-table .fixed-table-toolbar .columns > .btn-group:not(:first-child) > .btn { + border-top-left-radius: 0; + border-bottom-left-radius: 0; +} + +.bootstrap-table .fixed-table-toolbar .columns label { + padding: 5px 12px; +} + +.bootstrap-table .fixed-table-toolbar .columns input[type="checkbox"] { + vertical-align: middle; +} + +.bootstrap-table .fixed-table-toolbar .columns .dropdown-divider { + border-bottom: 1px solid #dbdbdb; +} + +.bootstrap-table .fixed-table-toolbar .search .input-group .search-input { + border-top-right-radius: 0; + border-bottom-right-radius: 0; + border-right: none; +} + +.bootstrap-table .fixed-table-toolbar .search .input-group button[name="search"], +.bootstrap-table .fixed-table-toolbar .search .input-group button[name="clearSearch"] { + border-top-left-radius: 0; + border-bottom-left-radius: 0; +} + +.bootstrap-table .fixed-table-toolbar .search .input-group button[name="search"]:not(:last-child), +.bootstrap-table .fixed-table-toolbar .search .input-group button[name="clearSearch"]:not(:last-child) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; + border-right: none; +} + +.bootstrap-table .open.dropdown-menu { + display: block; +} + +.bootstrap-table .dropdown-menu-up .dropdown-menu { + top: auto; + bottom: 100%; +} + +.bootstrap-table .dropdown-menu { + display: none; + background-color: #fff; + position: absolute; + right: 0; + min-width: 120px; + margin-top: 2px; + border: 1px solid #ccc; + border-radius: 4px; + -webkit-box-shadow: 0 3px 12px rgba(0, 0, 0, 0.175); + box-shadow: 0 3px 12px rgba(0, 0, 0, 0.175); +} + +.bootstrap-table .dropdown-menu .dropdown-item { + color: #363636; + text-decoration: none; + display: block; + padding: 5px 12px; + white-space: nowrap; +} + +.bootstrap-table .dropdown-menu .dropdown-item:hover { + background-color: whitesmoke; +} + +.bootstrap-table .dropdown-menu .dropdown-item.active { + background-color: #3679e4; + color: #fff; +} + +.bootstrap-table .dropdown-menu .dropdown-item.active:hover { + background-color: #1b5fcc; +} + +.bootstrap-table .columns-left .dropdown-menu { + left: 0; + right: auto; +} + +.bootstrap-table .pagination-detail { + float: left; +} + +.bootstrap-table .pagination-detail .dropdown-item { + min-width: 45px; + text-align: center; +} + +.bootstrap-table table { + border-collapse: collapse; +} + +.bootstrap-table table th { + text-align: inherit; +} + +.bootstrap-table table.table-bordered thead tr th, +.bootstrap-table table.table-bordered tbody tr td { + border: 1px solid #dbdbdb; +} + +.bootstrap-table table.table-bordered tbody tr td { + padding: 0.75rem; +} + +.bootstrap-table table.table-hover tbody tr:hover { + background: #fafafa; +} + +.bootstrap-table .float-left { + float: left; +} + +.bootstrap-table .float-right { + float: right; +} + +.bootstrap-table .pagination { + padding: 0; + align-items: center; + display: flex; + justify-content: center; + text-align: center; + list-style: none; +} + +.bootstrap-table .pagination .page-item { + border: 1px solid #dbdbdb; + background-color: #fff; + border-radius: 4px; + margin: 2px; + padding: 5px 2px 5px 2px; +} + +.bootstrap-table .pagination .page-item:hover { + background-color: whitesmoke; +} + +.bootstrap-table .pagination .page-item .page-link { + padding: 6px 12px; + line-height: 1.428571429; + color: #363636; + text-decoration: none; + outline: none; +} + +.bootstrap-table .pagination .page-item.active { + background-color: #3679e4; + border: 1px solid #206ae1; +} + +.bootstrap-table .pagination .page-item.active .page-link { + color: #fff; +} + +.bootstrap-table .pagination .page-item.active:hover { + background-color: #1b5fcc; +} + +.bootstrap-table .pagination .btn-group { + display: inline-block; +} + +.bootstrap-table .pagination .btn-group .btn:not(:first-child):not(:last-child), +.bootstrap-table .pagination .btn-group input:not(:first-child):not(:last-child) { + border-radius: 0; +} + +.bootstrap-table .pagination .btn-group .btn:first-child:not(:last-child):not(.dropdown-toggle), +.bootstrap-table .pagination .btn-group input:first-child:not(:last-child):not(.dropdown-toggle) { + border-top-right-radius: 0; + border-bottom-right-radius: 0; +} + +.bootstrap-table .pagination .btn-group .btn:last-child:not(:first-child), +.bootstrap-table .pagination .btn-group input:last-child:not(:first-child) { + border-top-left-radius: 0; + border-bottom-left-radius: 0; +} + +.bootstrap-table .pagination .btn-group > .btn-group:last-child:not(:first-child) > .btn:first-child { + border-top-left-radius: 0; + border-bottom-left-radius: 0; +} + +.bootstrap-table .filter-control { + display: flex; +} + +.bootstrap-table .page-jump-to input, +.bootstrap-table .page-jump-to .btn { + padding: 8px 12px; +} + +.modal { + position: fixed; + display: none; + top: 0; + left: 0; + bottom: 0; + right: 0; +} + +.modal.show { + display: flex; +} + +.modal .btn { + border-radius: 4px; + background-color: #fff; + border: 1px solid #ccc; + padding: 6px 12px; + outline: none; + cursor: pointer; +} + +.modal .btn.active { + border-color: black; +} + +.modal .modal-background { + position: fixed; + top: 0; + left: 0; + bottom: 0; + right: 0; + z-index: 998; + background-color: rgba(10, 10, 10, 0.86); +} + +.modal .modal-content { + position: relative; + width: 600px; + margin: 30px auto; + z-index: 999; +} + +.modal .modal-content .box { + background-color: #fff; + border-radius: 6px; + display: block; + padding: 1.25rem; +} diff --git a/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.js b/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.js new file mode 100644 index 0000000000..a8005559e7 --- /dev/null +++ b/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.js @@ -0,0 +1,1124 @@ +(function (global, factory) { + typeof exports === 'object' && typeof module !== 'undefined' ? factory(require('jquery')) : + typeof define === 'function' && define.amd ? define(['jquery'], factory) : + (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global.jQuery)); +}(this, (function ($) { 'use strict'; + + function _interopDefaultLegacy (e) { return e && typeof e === 'object' && 'default' in e ? e : { 'default': e }; } + + var $__default = /*#__PURE__*/_interopDefaultLegacy($); + + function _classCallCheck(instance, Constructor) { + if (!(instance instanceof Constructor)) { + throw new TypeError("Cannot call a class as a function"); + } + } + + function _defineProperties(target, props) { + for (var i = 0; i < props.length; i++) { + var descriptor = props[i]; + descriptor.enumerable = descriptor.enumerable || false; + descriptor.configurable = true; + if ("value" in descriptor) descriptor.writable = true; + Object.defineProperty(target, descriptor.key, descriptor); + } + } + + function _createClass(Constructor, protoProps, staticProps) { + if (protoProps) _defineProperties(Constructor.prototype, protoProps); + if (staticProps) _defineProperties(Constructor, staticProps); + return Constructor; + } + + function _inherits(subClass, superClass) { + if (typeof superClass !== "function" && superClass !== null) { + throw new TypeError("Super expression must either be null or a function"); + } + + subClass.prototype = Object.create(superClass && superClass.prototype, { + constructor: { + value: subClass, + writable: true, + configurable: true + } + }); + if (superClass) _setPrototypeOf(subClass, superClass); + } + + function _getPrototypeOf(o) { + _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { + return o.__proto__ || Object.getPrototypeOf(o); + }; + return _getPrototypeOf(o); + } + + function _setPrototypeOf(o, p) { + _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { + o.__proto__ = p; + return o; + }; + + return _setPrototypeOf(o, p); + } + + function _isNativeReflectConstruct() { + if (typeof Reflect === "undefined" || !Reflect.construct) return false; + if (Reflect.construct.sham) return false; + if (typeof Proxy === "function") return true; + + try { + Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); + return true; + } catch (e) { + return false; + } + } + + function _assertThisInitialized(self) { + if (self === void 0) { + throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); + } + + return self; + } + + function _possibleConstructorReturn(self, call) { + if (call && (typeof call === "object" || typeof call === "function")) { + return call; + } + + return _assertThisInitialized(self); + } + + function _createSuper(Derived) { + var hasNativeReflectConstruct = _isNativeReflectConstruct(); + + return function _createSuperInternal() { + var Super = _getPrototypeOf(Derived), + result; + + if (hasNativeReflectConstruct) { + var NewTarget = _getPrototypeOf(this).constructor; + + result = Reflect.construct(Super, arguments, NewTarget); + } else { + result = Super.apply(this, arguments); + } + + return _possibleConstructorReturn(this, result); + }; + } + + function _superPropBase(object, property) { + while (!Object.prototype.hasOwnProperty.call(object, property)) { + object = _getPrototypeOf(object); + if (object === null) break; + } + + return object; + } + + function _get(target, property, receiver) { + if (typeof Reflect !== "undefined" && Reflect.get) { + _get = Reflect.get; + } else { + _get = function _get(target, property, receiver) { + var base = _superPropBase(target, property); + + if (!base) return; + var desc = Object.getOwnPropertyDescriptor(base, property); + + if (desc.get) { + return desc.get.call(receiver); + } + + return desc.value; + }; + } + + return _get(target, property, receiver || target); + } + + var commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {}; + + function createCommonjsModule(fn, module) { + return module = { exports: {} }, fn(module, module.exports), module.exports; + } + + var check = function (it) { + return it && it.Math == Math && it; + }; + + // https://github.com/zloirock/core-js/issues/86#issuecomment-115759028 + var global_1 = + /* global globalThis -- safe */ + check(typeof globalThis == 'object' && globalThis) || + check(typeof window == 'object' && window) || + check(typeof self == 'object' && self) || + check(typeof commonjsGlobal == 'object' && commonjsGlobal) || + // eslint-disable-next-line no-new-func -- fallback + (function () { return this; })() || Function('return this')(); + + var fails = function (exec) { + try { + return !!exec(); + } catch (error) { + return true; + } + }; + + // Detect IE8's incomplete defineProperty implementation + var descriptors = !fails(function () { + return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7; + }); + + var nativePropertyIsEnumerable = {}.propertyIsEnumerable; + var getOwnPropertyDescriptor$1 = Object.getOwnPropertyDescriptor; + + // Nashorn ~ JDK8 bug + var NASHORN_BUG = getOwnPropertyDescriptor$1 && !nativePropertyIsEnumerable.call({ 1: 2 }, 1); + + // `Object.prototype.propertyIsEnumerable` method implementation + // https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable + var f$4 = NASHORN_BUG ? function propertyIsEnumerable(V) { + var descriptor = getOwnPropertyDescriptor$1(this, V); + return !!descriptor && descriptor.enumerable; + } : nativePropertyIsEnumerable; + + var objectPropertyIsEnumerable = { + f: f$4 + }; + + var createPropertyDescriptor = function (bitmap, value) { + return { + enumerable: !(bitmap & 1), + configurable: !(bitmap & 2), + writable: !(bitmap & 4), + value: value + }; + }; + + var toString = {}.toString; + + var classofRaw = function (it) { + return toString.call(it).slice(8, -1); + }; + + var split = ''.split; + + // fallback for non-array-like ES3 and non-enumerable old V8 strings + var indexedObject = fails(function () { + // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346 + // eslint-disable-next-line no-prototype-builtins -- safe + return !Object('z').propertyIsEnumerable(0); + }) ? function (it) { + return classofRaw(it) == 'String' ? split.call(it, '') : Object(it); + } : Object; + + // `RequireObjectCoercible` abstract operation + // https://tc39.es/ecma262/#sec-requireobjectcoercible + var requireObjectCoercible = function (it) { + if (it == undefined) throw TypeError("Can't call method on " + it); + return it; + }; + + // toObject with fallback for non-array-like ES3 strings + + + + var toIndexedObject = function (it) { + return indexedObject(requireObjectCoercible(it)); + }; + + var isObject = function (it) { + return typeof it === 'object' ? it !== null : typeof it === 'function'; + }; + + // `ToPrimitive` abstract operation + // https://tc39.es/ecma262/#sec-toprimitive + // instead of the ES6 spec version, we didn't implement @@toPrimitive case + // and the second argument - flag - preferred type is a string + var toPrimitive = function (input, PREFERRED_STRING) { + if (!isObject(input)) return input; + var fn, val; + if (PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val; + if (typeof (fn = input.valueOf) == 'function' && !isObject(val = fn.call(input))) return val; + if (!PREFERRED_STRING && typeof (fn = input.toString) == 'function' && !isObject(val = fn.call(input))) return val; + throw TypeError("Can't convert object to primitive value"); + }; + + var hasOwnProperty = {}.hasOwnProperty; + + var has$1 = function (it, key) { + return hasOwnProperty.call(it, key); + }; + + var document$1 = global_1.document; + // typeof document.createElement is 'object' in old IE + var EXISTS = isObject(document$1) && isObject(document$1.createElement); + + var documentCreateElement = function (it) { + return EXISTS ? document$1.createElement(it) : {}; + }; + + // Thank's IE8 for his funny defineProperty + var ie8DomDefine = !descriptors && !fails(function () { + return Object.defineProperty(documentCreateElement('div'), 'a', { + get: function () { return 7; } + }).a != 7; + }); + + var nativeGetOwnPropertyDescriptor = Object.getOwnPropertyDescriptor; + + // `Object.getOwnPropertyDescriptor` method + // https://tc39.es/ecma262/#sec-object.getownpropertydescriptor + var f$3 = descriptors ? nativeGetOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) { + O = toIndexedObject(O); + P = toPrimitive(P, true); + if (ie8DomDefine) try { + return nativeGetOwnPropertyDescriptor(O, P); + } catch (error) { /* empty */ } + if (has$1(O, P)) return createPropertyDescriptor(!objectPropertyIsEnumerable.f.call(O, P), O[P]); + }; + + var objectGetOwnPropertyDescriptor = { + f: f$3 + }; + + var anObject = function (it) { + if (!isObject(it)) { + throw TypeError(String(it) + ' is not an object'); + } return it; + }; + + var nativeDefineProperty = Object.defineProperty; + + // `Object.defineProperty` method + // https://tc39.es/ecma262/#sec-object.defineproperty + var f$2 = descriptors ? nativeDefineProperty : function defineProperty(O, P, Attributes) { + anObject(O); + P = toPrimitive(P, true); + anObject(Attributes); + if (ie8DomDefine) try { + return nativeDefineProperty(O, P, Attributes); + } catch (error) { /* empty */ } + if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported'); + if ('value' in Attributes) O[P] = Attributes.value; + return O; + }; + + var objectDefineProperty = { + f: f$2 + }; + + var createNonEnumerableProperty = descriptors ? function (object, key, value) { + return objectDefineProperty.f(object, key, createPropertyDescriptor(1, value)); + } : function (object, key, value) { + object[key] = value; + return object; + }; + + var setGlobal = function (key, value) { + try { + createNonEnumerableProperty(global_1, key, value); + } catch (error) { + global_1[key] = value; + } return value; + }; + + var SHARED = '__core-js_shared__'; + var store$1 = global_1[SHARED] || setGlobal(SHARED, {}); + + var sharedStore = store$1; + + var functionToString = Function.toString; + + // this helper broken in `3.4.1-3.4.4`, so we can't use `shared` helper + if (typeof sharedStore.inspectSource != 'function') { + sharedStore.inspectSource = function (it) { + return functionToString.call(it); + }; + } + + var inspectSource = sharedStore.inspectSource; + + var WeakMap$1 = global_1.WeakMap; + + var nativeWeakMap = typeof WeakMap$1 === 'function' && /native code/.test(inspectSource(WeakMap$1)); + + var shared = createCommonjsModule(function (module) { + (module.exports = function (key, value) { + return sharedStore[key] || (sharedStore[key] = value !== undefined ? value : {}); + })('versions', []).push({ + version: '3.9.1', + mode: 'global', + copyright: '© 2021 Denis Pushkarev (zloirock.ru)' + }); + }); + + var id = 0; + var postfix = Math.random(); + + var uid = function (key) { + return 'Symbol(' + String(key === undefined ? '' : key) + ')_' + (++id + postfix).toString(36); + }; + + var keys = shared('keys'); + + var sharedKey = function (key) { + return keys[key] || (keys[key] = uid(key)); + }; + + var hiddenKeys$1 = {}; + + var WeakMap = global_1.WeakMap; + var set, get, has; + + var enforce = function (it) { + return has(it) ? get(it) : set(it, {}); + }; + + var getterFor = function (TYPE) { + return function (it) { + var state; + if (!isObject(it) || (state = get(it)).type !== TYPE) { + throw TypeError('Incompatible receiver, ' + TYPE + ' required'); + } return state; + }; + }; + + if (nativeWeakMap) { + var store = sharedStore.state || (sharedStore.state = new WeakMap()); + var wmget = store.get; + var wmhas = store.has; + var wmset = store.set; + set = function (it, metadata) { + metadata.facade = it; + wmset.call(store, it, metadata); + return metadata; + }; + get = function (it) { + return wmget.call(store, it) || {}; + }; + has = function (it) { + return wmhas.call(store, it); + }; + } else { + var STATE = sharedKey('state'); + hiddenKeys$1[STATE] = true; + set = function (it, metadata) { + metadata.facade = it; + createNonEnumerableProperty(it, STATE, metadata); + return metadata; + }; + get = function (it) { + return has$1(it, STATE) ? it[STATE] : {}; + }; + has = function (it) { + return has$1(it, STATE); + }; + } + + var internalState = { + set: set, + get: get, + has: has, + enforce: enforce, + getterFor: getterFor + }; + + var redefine = createCommonjsModule(function (module) { + var getInternalState = internalState.get; + var enforceInternalState = internalState.enforce; + var TEMPLATE = String(String).split('String'); + + (module.exports = function (O, key, value, options) { + var unsafe = options ? !!options.unsafe : false; + var simple = options ? !!options.enumerable : false; + var noTargetGet = options ? !!options.noTargetGet : false; + var state; + if (typeof value == 'function') { + if (typeof key == 'string' && !has$1(value, 'name')) { + createNonEnumerableProperty(value, 'name', key); + } + state = enforceInternalState(value); + if (!state.source) { + state.source = TEMPLATE.join(typeof key == 'string' ? key : ''); + } + } + if (O === global_1) { + if (simple) O[key] = value; + else setGlobal(key, value); + return; + } else if (!unsafe) { + delete O[key]; + } else if (!noTargetGet && O[key]) { + simple = true; + } + if (simple) O[key] = value; + else createNonEnumerableProperty(O, key, value); + // add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative + })(Function.prototype, 'toString', function toString() { + return typeof this == 'function' && getInternalState(this).source || inspectSource(this); + }); + }); + + var path = global_1; + + var aFunction$1 = function (variable) { + return typeof variable == 'function' ? variable : undefined; + }; + + var getBuiltIn = function (namespace, method) { + return arguments.length < 2 ? aFunction$1(path[namespace]) || aFunction$1(global_1[namespace]) + : path[namespace] && path[namespace][method] || global_1[namespace] && global_1[namespace][method]; + }; + + var ceil = Math.ceil; + var floor = Math.floor; + + // `ToInteger` abstract operation + // https://tc39.es/ecma262/#sec-tointeger + var toInteger = function (argument) { + return isNaN(argument = +argument) ? 0 : (argument > 0 ? floor : ceil)(argument); + }; + + var min$1 = Math.min; + + // `ToLength` abstract operation + // https://tc39.es/ecma262/#sec-tolength + var toLength = function (argument) { + return argument > 0 ? min$1(toInteger(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991 + }; + + var max = Math.max; + var min = Math.min; + + // Helper for a popular repeating case of the spec: + // Let integer be ? ToInteger(index). + // If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length). + var toAbsoluteIndex = function (index, length) { + var integer = toInteger(index); + return integer < 0 ? max(integer + length, 0) : min(integer, length); + }; + + // `Array.prototype.{ indexOf, includes }` methods implementation + var createMethod$1 = function (IS_INCLUDES) { + return function ($this, el, fromIndex) { + var O = toIndexedObject($this); + var length = toLength(O.length); + var index = toAbsoluteIndex(fromIndex, length); + var value; + // Array#includes uses SameValueZero equality algorithm + // eslint-disable-next-line no-self-compare -- NaN check + if (IS_INCLUDES && el != el) while (length > index) { + value = O[index++]; + // eslint-disable-next-line no-self-compare -- NaN check + if (value != value) return true; + // Array#indexOf ignores holes, Array#includes - not + } else for (;length > index; index++) { + if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0; + } return !IS_INCLUDES && -1; + }; + }; + + var arrayIncludes = { + // `Array.prototype.includes` method + // https://tc39.es/ecma262/#sec-array.prototype.includes + includes: createMethod$1(true), + // `Array.prototype.indexOf` method + // https://tc39.es/ecma262/#sec-array.prototype.indexof + indexOf: createMethod$1(false) + }; + + var indexOf = arrayIncludes.indexOf; + + + var objectKeysInternal = function (object, names) { + var O = toIndexedObject(object); + var i = 0; + var result = []; + var key; + for (key in O) !has$1(hiddenKeys$1, key) && has$1(O, key) && result.push(key); + // Don't enum bug & hidden keys + while (names.length > i) if (has$1(O, key = names[i++])) { + ~indexOf(result, key) || result.push(key); + } + return result; + }; + + // IE8- don't enum bug keys + var enumBugKeys = [ + 'constructor', + 'hasOwnProperty', + 'isPrototypeOf', + 'propertyIsEnumerable', + 'toLocaleString', + 'toString', + 'valueOf' + ]; + + var hiddenKeys = enumBugKeys.concat('length', 'prototype'); + + // `Object.getOwnPropertyNames` method + // https://tc39.es/ecma262/#sec-object.getownpropertynames + var f$1 = Object.getOwnPropertyNames || function getOwnPropertyNames(O) { + return objectKeysInternal(O, hiddenKeys); + }; + + var objectGetOwnPropertyNames = { + f: f$1 + }; + + var f = Object.getOwnPropertySymbols; + + var objectGetOwnPropertySymbols = { + f: f + }; + + // all object keys, includes non-enumerable and symbols + var ownKeys = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) { + var keys = objectGetOwnPropertyNames.f(anObject(it)); + var getOwnPropertySymbols = objectGetOwnPropertySymbols.f; + return getOwnPropertySymbols ? keys.concat(getOwnPropertySymbols(it)) : keys; + }; + + var copyConstructorProperties = function (target, source) { + var keys = ownKeys(source); + var defineProperty = objectDefineProperty.f; + var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f; + for (var i = 0; i < keys.length; i++) { + var key = keys[i]; + if (!has$1(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key)); + } + }; + + var replacement = /#|\.prototype\./; + + var isForced = function (feature, detection) { + var value = data[normalize(feature)]; + return value == POLYFILL ? true + : value == NATIVE ? false + : typeof detection == 'function' ? fails(detection) + : !!detection; + }; + + var normalize = isForced.normalize = function (string) { + return String(string).replace(replacement, '.').toLowerCase(); + }; + + var data = isForced.data = {}; + var NATIVE = isForced.NATIVE = 'N'; + var POLYFILL = isForced.POLYFILL = 'P'; + + var isForced_1 = isForced; + + var getOwnPropertyDescriptor = objectGetOwnPropertyDescriptor.f; + + + + + + + /* + options.target - name of the target object + options.global - target is the global object + options.stat - export as static methods of target + options.proto - export as prototype methods of target + options.real - real prototype method for the `pure` version + options.forced - export even if the native feature is available + options.bind - bind methods to the target, required for the `pure` version + options.wrap - wrap constructors to preventing global pollution, required for the `pure` version + options.unsafe - use the simple assignment of property instead of delete + defineProperty + options.sham - add a flag to not completely full polyfills + options.enumerable - export as enumerable property + options.noTargetGet - prevent calling a getter on target + */ + var _export = function (options, source) { + var TARGET = options.target; + var GLOBAL = options.global; + var STATIC = options.stat; + var FORCED, target, key, targetProperty, sourceProperty, descriptor; + if (GLOBAL) { + target = global_1; + } else if (STATIC) { + target = global_1[TARGET] || setGlobal(TARGET, {}); + } else { + target = (global_1[TARGET] || {}).prototype; + } + if (target) for (key in source) { + sourceProperty = source[key]; + if (options.noTargetGet) { + descriptor = getOwnPropertyDescriptor(target, key); + targetProperty = descriptor && descriptor.value; + } else targetProperty = target[key]; + FORCED = isForced_1(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced); + // contained in target + if (!FORCED && targetProperty !== undefined) { + if (typeof sourceProperty === typeof targetProperty) continue; + copyConstructorProperties(sourceProperty, targetProperty); + } + // add a flag to not completely full polyfills + if (options.sham || (targetProperty && targetProperty.sham)) { + createNonEnumerableProperty(sourceProperty, 'sham', true); + } + // extend global + redefine(target, key, sourceProperty, options); + } + }; + + var aFunction = function (it) { + if (typeof it != 'function') { + throw TypeError(String(it) + ' is not a function'); + } return it; + }; + + // optional / simple context binding + var functionBindContext = function (fn, that, length) { + aFunction(fn); + if (that === undefined) return fn; + switch (length) { + case 0: return function () { + return fn.call(that); + }; + case 1: return function (a) { + return fn.call(that, a); + }; + case 2: return function (a, b) { + return fn.call(that, a, b); + }; + case 3: return function (a, b, c) { + return fn.call(that, a, b, c); + }; + } + return function (/* ...args */) { + return fn.apply(that, arguments); + }; + }; + + // `ToObject` abstract operation + // https://tc39.es/ecma262/#sec-toobject + var toObject = function (argument) { + return Object(requireObjectCoercible(argument)); + }; + + // `IsArray` abstract operation + // https://tc39.es/ecma262/#sec-isarray + var isArray = Array.isArray || function isArray(arg) { + return classofRaw(arg) == 'Array'; + }; + + var engineIsNode = classofRaw(global_1.process) == 'process'; + + var engineUserAgent = getBuiltIn('navigator', 'userAgent') || ''; + + var process = global_1.process; + var versions = process && process.versions; + var v8 = versions && versions.v8; + var match, version; + + if (v8) { + match = v8.split('.'); + version = match[0] + match[1]; + } else if (engineUserAgent) { + match = engineUserAgent.match(/Edge\/(\d+)/); + if (!match || match[1] >= 74) { + match = engineUserAgent.match(/Chrome\/(\d+)/); + if (match) version = match[1]; + } + } + + var engineV8Version = version && +version; + + var nativeSymbol = !!Object.getOwnPropertySymbols && !fails(function () { + /* global Symbol -- required for testing */ + return !Symbol.sham && + // Chrome 38 Symbol has incorrect toString conversion + // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances + (engineIsNode ? engineV8Version === 38 : engineV8Version > 37 && engineV8Version < 41); + }); + + var useSymbolAsUid = nativeSymbol + /* global Symbol -- safe */ + && !Symbol.sham + && typeof Symbol.iterator == 'symbol'; + + var WellKnownSymbolsStore = shared('wks'); + var Symbol$1 = global_1.Symbol; + var createWellKnownSymbol = useSymbolAsUid ? Symbol$1 : Symbol$1 && Symbol$1.withoutSetter || uid; + + var wellKnownSymbol = function (name) { + if (!has$1(WellKnownSymbolsStore, name) || !(nativeSymbol || typeof WellKnownSymbolsStore[name] == 'string')) { + if (nativeSymbol && has$1(Symbol$1, name)) { + WellKnownSymbolsStore[name] = Symbol$1[name]; + } else { + WellKnownSymbolsStore[name] = createWellKnownSymbol('Symbol.' + name); + } + } return WellKnownSymbolsStore[name]; + }; + + var SPECIES = wellKnownSymbol('species'); + + // `ArraySpeciesCreate` abstract operation + // https://tc39.es/ecma262/#sec-arrayspeciescreate + var arraySpeciesCreate = function (originalArray, length) { + var C; + if (isArray(originalArray)) { + C = originalArray.constructor; + // cross-realm fallback + if (typeof C == 'function' && (C === Array || isArray(C.prototype))) C = undefined; + else if (isObject(C)) { + C = C[SPECIES]; + if (C === null) C = undefined; + } + } return new (C === undefined ? Array : C)(length === 0 ? 0 : length); + }; + + var push = [].push; + + // `Array.prototype.{ forEach, map, filter, some, every, find, findIndex, filterOut }` methods implementation + var createMethod = function (TYPE) { + var IS_MAP = TYPE == 1; + var IS_FILTER = TYPE == 2; + var IS_SOME = TYPE == 3; + var IS_EVERY = TYPE == 4; + var IS_FIND_INDEX = TYPE == 6; + var IS_FILTER_OUT = TYPE == 7; + var NO_HOLES = TYPE == 5 || IS_FIND_INDEX; + return function ($this, callbackfn, that, specificCreate) { + var O = toObject($this); + var self = indexedObject(O); + var boundFunction = functionBindContext(callbackfn, that, 3); + var length = toLength(self.length); + var index = 0; + var create = specificCreate || arraySpeciesCreate; + var target = IS_MAP ? create($this, length) : IS_FILTER || IS_FILTER_OUT ? create($this, 0) : undefined; + var value, result; + for (;length > index; index++) if (NO_HOLES || index in self) { + value = self[index]; + result = boundFunction(value, index, O); + if (TYPE) { + if (IS_MAP) target[index] = result; // map + else if (result) switch (TYPE) { + case 3: return true; // some + case 5: return value; // find + case 6: return index; // findIndex + case 2: push.call(target, value); // filter + } else switch (TYPE) { + case 4: return false; // every + case 7: push.call(target, value); // filterOut + } + } + } + return IS_FIND_INDEX ? -1 : IS_SOME || IS_EVERY ? IS_EVERY : target; + }; + }; + + var arrayIteration = { + // `Array.prototype.forEach` method + // https://tc39.es/ecma262/#sec-array.prototype.foreach + forEach: createMethod(0), + // `Array.prototype.map` method + // https://tc39.es/ecma262/#sec-array.prototype.map + map: createMethod(1), + // `Array.prototype.filter` method + // https://tc39.es/ecma262/#sec-array.prototype.filter + filter: createMethod(2), + // `Array.prototype.some` method + // https://tc39.es/ecma262/#sec-array.prototype.some + some: createMethod(3), + // `Array.prototype.every` method + // https://tc39.es/ecma262/#sec-array.prototype.every + every: createMethod(4), + // `Array.prototype.find` method + // https://tc39.es/ecma262/#sec-array.prototype.find + find: createMethod(5), + // `Array.prototype.findIndex` method + // https://tc39.es/ecma262/#sec-array.prototype.findIndex + findIndex: createMethod(6), + // `Array.prototype.filterOut` method + // https://github.com/tc39/proposal-array-filtering + filterOut: createMethod(7) + }; + + // `Object.keys` method + // https://tc39.es/ecma262/#sec-object.keys + var objectKeys = Object.keys || function keys(O) { + return objectKeysInternal(O, enumBugKeys); + }; + + // `Object.defineProperties` method + // https://tc39.es/ecma262/#sec-object.defineproperties + var objectDefineProperties = descriptors ? Object.defineProperties : function defineProperties(O, Properties) { + anObject(O); + var keys = objectKeys(Properties); + var length = keys.length; + var index = 0; + var key; + while (length > index) objectDefineProperty.f(O, key = keys[index++], Properties[key]); + return O; + }; + + var html = getBuiltIn('document', 'documentElement'); + + var GT = '>'; + var LT = '<'; + var PROTOTYPE = 'prototype'; + var SCRIPT = 'script'; + var IE_PROTO = sharedKey('IE_PROTO'); + + var EmptyConstructor = function () { /* empty */ }; + + var scriptTag = function (content) { + return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT; + }; + + // Create object with fake `null` prototype: use ActiveX Object with cleared prototype + var NullProtoObjectViaActiveX = function (activeXDocument) { + activeXDocument.write(scriptTag('')); + activeXDocument.close(); + var temp = activeXDocument.parentWindow.Object; + activeXDocument = null; // avoid memory leak + return temp; + }; + + // Create object with fake `null` prototype: use iframe Object with cleared prototype + var NullProtoObjectViaIFrame = function () { + // Thrash, waste and sodomy: IE GC bug + var iframe = documentCreateElement('iframe'); + var JS = 'java' + SCRIPT + ':'; + var iframeDocument; + iframe.style.display = 'none'; + html.appendChild(iframe); + // https://github.com/zloirock/core-js/issues/475 + iframe.src = String(JS); + iframeDocument = iframe.contentWindow.document; + iframeDocument.open(); + iframeDocument.write(scriptTag('document.F=Object')); + iframeDocument.close(); + return iframeDocument.F; + }; + + // Check for document.domain and active x support + // No need to use active x approach when document.domain is not set + // see https://github.com/es-shims/es5-shim/issues/150 + // variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346 + // avoid IE GC bug + var activeXDocument; + var NullProtoObject = function () { + try { + /* global ActiveXObject -- old IE */ + activeXDocument = document.domain && new ActiveXObject('htmlfile'); + } catch (error) { /* ignore */ } + NullProtoObject = activeXDocument ? NullProtoObjectViaActiveX(activeXDocument) : NullProtoObjectViaIFrame(); + var length = enumBugKeys.length; + while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]]; + return NullProtoObject(); + }; + + hiddenKeys$1[IE_PROTO] = true; + + // `Object.create` method + // https://tc39.es/ecma262/#sec-object.create + var objectCreate = Object.create || function create(O, Properties) { + var result; + if (O !== null) { + EmptyConstructor[PROTOTYPE] = anObject(O); + result = new EmptyConstructor(); + EmptyConstructor[PROTOTYPE] = null; + // add "__proto__" for Object.getPrototypeOf polyfill + result[IE_PROTO] = O; + } else result = NullProtoObject(); + return Properties === undefined ? result : objectDefineProperties(result, Properties); + }; + + var UNSCOPABLES = wellKnownSymbol('unscopables'); + var ArrayPrototype = Array.prototype; + + // Array.prototype[@@unscopables] + // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables + if (ArrayPrototype[UNSCOPABLES] == undefined) { + objectDefineProperty.f(ArrayPrototype, UNSCOPABLES, { + configurable: true, + value: objectCreate(null) + }); + } + + // add a key to Array.prototype[@@unscopables] + var addToUnscopables = function (key) { + ArrayPrototype[UNSCOPABLES][key] = true; + }; + + var $find = arrayIteration.find; + + + var FIND = 'find'; + var SKIPS_HOLES = true; + + // Shouldn't skip holes + if (FIND in []) Array(1)[FIND](function () { SKIPS_HOLES = false; }); + + // `Array.prototype.find` method + // https://tc39.es/ecma262/#sec-array.prototype.find + _export({ target: 'Array', proto: true, forced: SKIPS_HOLES }, { + find: function find(callbackfn /* , that = undefined */) { + return $find(this, callbackfn, arguments.length > 1 ? arguments[1] : undefined); + } + }); + + // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables + addToUnscopables(FIND); + + var $includes = arrayIncludes.includes; + + + // `Array.prototype.includes` method + // https://tc39.es/ecma262/#sec-array.prototype.includes + _export({ target: 'Array', proto: true }, { + includes: function includes(el /* , fromIndex = 0 */) { + return $includes(this, el, arguments.length > 1 ? arguments[1] : undefined); + } + }); + + // https://tc39.es/ecma262/#sec-array.prototype-@@unscopables + addToUnscopables('includes'); + + var MATCH$1 = wellKnownSymbol('match'); + + // `IsRegExp` abstract operation + // https://tc39.es/ecma262/#sec-isregexp + var isRegexp = function (it) { + var isRegExp; + return isObject(it) && ((isRegExp = it[MATCH$1]) !== undefined ? !!isRegExp : classofRaw(it) == 'RegExp'); + }; + + var notARegexp = function (it) { + if (isRegexp(it)) { + throw TypeError("The method doesn't accept regular expressions"); + } return it; + }; + + var MATCH = wellKnownSymbol('match'); + + var correctIsRegexpLogic = function (METHOD_NAME) { + var regexp = /./; + try { + '/./'[METHOD_NAME](regexp); + } catch (error1) { + try { + regexp[MATCH] = false; + return '/./'[METHOD_NAME](regexp); + } catch (error2) { /* empty */ } + } return false; + }; + + // `String.prototype.includes` method + // https://tc39.es/ecma262/#sec-string.prototype.includes + _export({ target: 'String', proto: true, forced: !correctIsRegexpLogic('includes') }, { + includes: function includes(searchString /* , position = 0 */) { + return !!~String(requireObjectCoercible(this)) + .indexOf(notARegexp(searchString), arguments.length > 1 ? arguments[1] : undefined); + } + }); + + /** + * @author Dustin Utecht + * https://github.com/wenzhixin/bootstrap-table/ + */ + + $__default['default'].fn.bootstrapTable.theme = 'bootstrap-table'; + $__default['default'].extend($__default['default'].fn.bootstrapTable.defaults, { + iconsPrefix: 'icon', + icons: { + paginationSwitchDown: 'icon-arrow-up-circle', + paginationSwitchUp: 'icon-arrow-down-circle', + refresh: 'icon-refresh-cw', + toggleOff: 'icon-toggle-right', + toggleOn: 'icon-toggle-right', + columns: 'icon-list', + detailOpen: 'icon-plus', + detailClose: 'icon-minus', + fullscreen: 'icon-maximize', + search: 'icon-search', + clearSearch: 'icon-trash-2' + } + }); + + $__default['default'].BootstrapTable = /*#__PURE__*/function (_$$BootstrapTable) { + _inherits(_class, _$$BootstrapTable); + + var _super = _createSuper(_class); + + function _class() { + _classCallCheck(this, _class); + + return _super.apply(this, arguments); + } + + _createClass(_class, [{ + key: "init", + value: function init() { + _get(_getPrototypeOf(_class.prototype), "init", this).call(this); + + this.constants.classes.dropup = 'dropdown-menu-up'; + $__default['default']('.modal').on('click', '[data-close]', function (e) { + $__default['default'](e.delegateTarget).removeClass('show'); + }); + } + }, { + key: "initConstants", + value: function initConstants() { + _get(_getPrototypeOf(_class.prototype), "initConstants", this).call(this); + + this.constants.html.inputGroup = '
%s%s
'; + } + }, { + key: "initToolbar", + value: function initToolbar() { + _get(_getPrototypeOf(_class.prototype), "initToolbar", this).call(this); + + this.handleToolbar(); + } + }, { + key: "handleToolbar", + value: function handleToolbar() { + if (this.$toolbar.find('.dropdown-toggle').length) { + this._initDropdown(); + } + } + }, { + key: "initPagination", + value: function initPagination() { + _get(_getPrototypeOf(_class.prototype), "initPagination", this).call(this); + + if (this.options.pagination && this.paginationParts.includes('pageSize')) { + this._initDropdown(); + } + } + }, { + key: "_initDropdown", + value: function _initDropdown() { + var $dropdownToggles = $__default['default']('.dropdown-toggle'); + $dropdownToggles.off('click').on('click', function (e) { + var $target = $__default['default'](e.currentTarget); + + if ($target.parents('.dropdown-toggle').length > 0) { + $target = $target.parents('.dropdown-toggle'); + } + + $target.next('.dropdown-menu').toggleClass('open'); + }); + $__default['default'](window).off('click').on('click', function (e) { + var $dropdownToggles = $__default['default']('.dropdown-toggle'); + + if ($__default['default'](e.target).parents('.dropdown-toggle, .dropdown-menu').length === 0 && !$__default['default'](e.target).hasClass('dropdown-toggle')) { + $dropdownToggles.next('.dropdown-menu').removeClass('open'); + } + }); + } + }]); + + return _class; + }($__default['default'].BootstrapTable); + +}))); diff --git a/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.min.css b/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.min.css new file mode 100644 index 0000000000..57df50bae3 --- /dev/null +++ b/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.min.css @@ -0,0 +1,10 @@ +/** + * bootstrap-table - An extended table to integration with some of the most widely used CSS frameworks. (Supports Bootstrap, Semantic UI, Bulma, Material Design, Foundation) + * + * @version v1.18.3 + * @homepage https://bootstrap-table.com + * @author wenzhixin (http://wenzhixin.net.cn/) + * @license MIT + */ + +.bootstrap-table .fixed-table-toolbar::after{content:"";display:block;clear:both}.bootstrap-table .fixed-table-toolbar .bs-bars,.bootstrap-table .fixed-table-toolbar .columns,.bootstrap-table .fixed-table-toolbar .search{position:relative;margin-top:10px;margin-bottom:10px}.bootstrap-table .fixed-table-toolbar .columns .btn-group>.btn-group{display:inline-block;margin-left:-1px!important}.bootstrap-table .fixed-table-toolbar .columns .btn-group>.btn-group>.btn{border-radius:0}.bootstrap-table .fixed-table-toolbar .columns .btn-group>.btn-group:first-child>.btn{border-top-left-radius:4px;border-bottom-left-radius:4px}.bootstrap-table .fixed-table-toolbar .columns .btn-group>.btn-group:last-child>.btn{border-top-right-radius:4px;border-bottom-right-radius:4px}.bootstrap-table .fixed-table-toolbar .columns .dropdown-menu{text-align:left;max-height:300px;overflow:auto;-ms-overflow-style:scrollbar;z-index:1001}.bootstrap-table .fixed-table-toolbar .columns label{display:block;padding:3px 20px;clear:both;font-weight:400;line-height:1.428571429}.bootstrap-table .fixed-table-toolbar .columns-left{margin-right:5px}.bootstrap-table .fixed-table-toolbar .columns-right{margin-left:5px}.bootstrap-table .fixed-table-toolbar .pull-right .dropdown-menu{right:0;left:auto}.bootstrap-table .fixed-table-container{position:relative;clear:both}.bootstrap-table .fixed-table-container .table{width:100%;margin-bottom:0!important}.bootstrap-table .fixed-table-container .table td,.bootstrap-table .fixed-table-container .table th{vertical-align:middle;box-sizing:border-box}.bootstrap-table .fixed-table-container .table thead th{vertical-align:bottom;padding:0;margin:0}.bootstrap-table .fixed-table-container .table thead th:focus{outline:0 solid transparent}.bootstrap-table .fixed-table-container .table thead th.detail{width:30px}.bootstrap-table .fixed-table-container .table thead th .th-inner{padding:.75rem;vertical-align:bottom;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.bootstrap-table .fixed-table-container .table thead th .sortable{cursor:pointer;background-position:right;background-repeat:no-repeat;padding-right:30px!important}.bootstrap-table .fixed-table-container .table thead th .both{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAQAAADYWf5HAAAAkElEQVQoz7X QMQ5AQBCF4dWQSJxC5wwax1Cq1e7BAdxD5SL+Tq/QCM1oNiJidwox0355mXnG/DrEtIQ6azioNZQxI0ykPhTQIwhCR+BmBYtlK7kLJYwWCcJA9M4qdrZrd8pPjZWPtOqdRQy320YSV17OatFC4euts6z39GYMKRPCTKY9UnPQ6P+GtMRfGtPnBCiqhAeJPmkqAAAAAElFTkSuQmCC")}.bootstrap-table .fixed-table-container .table thead th .asc{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAYAAAByUDbMAAAAZ0lEQVQ4y2NgGLKgquEuFxBPAGI2ahhWCsS/gDibUoO0gPgxEP8H4ttArEyuQYxAPBdqEAxPBImTY5gjEL9DM+wTENuQahAvEO9DMwiGdwAxOymGJQLxTyD+jgWDxCMZRsEoGAVoAADeemwtPcZI2wAAAABJRU5ErkJggg==")}.bootstrap-table .fixed-table-container .table thead th .desc{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABMAAAATCAYAAAByUDbMAAAAZUlEQVQ4y2NgGAWjYBSggaqGu5FA/BOIv2PBIPFEUgxjB+IdQPwfC94HxLykus4GiD+hGfQOiB3J8SojEE9EM2wuSJzcsFMG4ttQgx4DsRalkZENxL+AuJQaMcsGxBOAmGvopk8AVz1sLZgg0bsAAAAASUVORK5CYII= ")}.bootstrap-table .fixed-table-container .table tbody tr.selected td{background-color:#fafafa}.bootstrap-table .fixed-table-container .table tbody tr.no-records-found td{text-align:center}.bootstrap-table .fixed-table-container .table tbody tr .card-view{display:flex}.bootstrap-table .fixed-table-container .table tbody tr .card-view .card-view-title{font-weight:700;display:inline-block;min-width:30%;width:auto!important;text-align:left!important}.bootstrap-table .fixed-table-container .table tbody tr .card-view .card-view-value{width:100%!important}.bootstrap-table .fixed-table-container .table .bs-checkbox{text-align:center}.bootstrap-table .fixed-table-container .table .bs-checkbox label{margin-bottom:0}.bootstrap-table .fixed-table-container .table .bs-checkbox label input[type=checkbox],.bootstrap-table .fixed-table-container .table .bs-checkbox label input[type=radio]{margin:0 auto!important}.bootstrap-table .fixed-table-container .table.table-sm .th-inner{padding:.3rem}.bootstrap-table .fixed-table-container.fixed-height:not(.has-footer){border-bottom:1px solid #dbdbdb}.bootstrap-table .fixed-table-container.fixed-height.has-card-view{border-top:1px solid #dbdbdb;border-bottom:1px solid #dbdbdb}.bootstrap-table .fixed-table-container.fixed-height .fixed-table-border{border-left:1px solid #dbdbdb;border-right:1px solid #dbdbdb}.bootstrap-table .fixed-table-container.fixed-height .table thead th{border-bottom:1px solid #dbdbdb}.bootstrap-table .fixed-table-container.fixed-height .table-dark thead th{border-bottom:1px solid #32383e}.bootstrap-table .fixed-table-container .fixed-table-header{overflow:hidden}.bootstrap-table .fixed-table-container .fixed-table-body{overflow-x:auto;overflow-y:auto;height:100%}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading{align-items:center;background:#fff;display:flex;justify-content:center;position:absolute;bottom:0;width:100%;z-index:1000;transition:visibility 0s,opacity .15s ease-in-out;opacity:0;visibility:hidden}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.open{visibility:visible;opacity:1}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap{align-items:baseline;display:flex;justify-content:center}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .loading-text{margin-right:6px}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-wrap{align-items:center;display:flex;justify-content:center}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-dot,.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-wrap::after,.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-wrap::before{content:"";animation-duration:1.5s;animation-iteration-count:infinite;animation-name:LOADING;background:#363636;border-radius:50%;display:block;height:5px;margin:0 4px;opacity:0;width:5px}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-dot{animation-delay:.3s}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading .loading-wrap .animation-wrap::after{animation-delay:.6s}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.table-dark{background:#363636}.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.table-dark .animation-dot,.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.table-dark .animation-wrap::after,.bootstrap-table .fixed-table-container .fixed-table-body .fixed-table-loading.table-dark .animation-wrap::before{background:#fff}.bootstrap-table .fixed-table-container .fixed-table-footer{overflow:hidden}.bootstrap-table .fixed-table-pagination::after{content:"";display:block;clear:both}.bootstrap-table .fixed-table-pagination>.pagination,.bootstrap-table .fixed-table-pagination>.pagination-detail{margin-top:10px;margin-bottom:10px}.bootstrap-table .fixed-table-pagination>.pagination-detail .pagination-info{line-height:34px;margin-right:5px}.bootstrap-table .fixed-table-pagination>.pagination-detail .page-list{display:inline-block}.bootstrap-table .fixed-table-pagination>.pagination-detail .page-list .btn-group{position:relative;display:inline-block;vertical-align:middle}.bootstrap-table .fixed-table-pagination>.pagination-detail .page-list .btn-group .dropdown-menu{margin-bottom:0}.bootstrap-table .fixed-table-pagination>.pagination ul.pagination{margin:0}.bootstrap-table .fixed-table-pagination>.pagination ul.pagination li.page-intermediate a{color:#c8c8c8}.bootstrap-table .fixed-table-pagination>.pagination ul.pagination li.page-intermediate a::before{content:'\2B05'}.bootstrap-table .fixed-table-pagination>.pagination ul.pagination li.page-intermediate a::after{content:'\27A1'}.bootstrap-table .fixed-table-pagination>.pagination ul.pagination li.disabled a{pointer-events:none;cursor:default}.bootstrap-table.fullscreen{position:fixed;top:0;left:0;z-index:1050;width:100%!important;background:#fff;height:calc(100vh);overflow-y:scroll}.bootstrap-table.bootstrap4 .pagination-lg .page-link,.bootstrap-table.bootstrap5 .pagination-lg .page-link{padding:.5rem 1rem}.bootstrap-table.bootstrap5 .float-left{float:left}.bootstrap-table.bootstrap5 .float-right{float:right}div.fixed-table-scroll-inner{width:100%;height:200px}div.fixed-table-scroll-outer{top:0;left:0;visibility:hidden;width:200px;height:150px;overflow:hidden}@keyframes LOADING{0%{opacity:0}50%{opacity:1}to{opacity:0}}@font-face{font-family:bootstrap-table;src:url("fonts/bootstrap-table.eot?gmdfsp");src:url("fonts/bootstrap-table.eot") format("embedded-opentype"),url("fonts/bootstrap-table.ttf") format("truetype"),url("fonts/bootstrap-table.woff") format("woff"),url("fonts/bootstrap-table.svg") format("svg");font-weight:400;font-style:normal;font-display:block}[class*=" icon-"],[class^=icon-]{font-family:bootstrap-table,sans-serif!important;speak:none;font-style:normal;font-weight:400;font-variant:normal;text-transform:none;line-height:1;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.icon-arrow-down-circle:before{content:"\e907"}.icon-arrow-up-circle:before{content:"\e908"}.icon-chevron-left:before{content:"\e900"}.icon-chevron-right:before{content:"\e901"}.icon-clock:before{content:"\e90c"}.icon-copy:before{content:"\e909"}.icon-download:before{content:"\e90d"}.icon-list:before{content:"\e902"}.icon-maximize:before{content:"\1f5ce"}.icon-minus:before{content:"\e90f"}.icon-move:before{content:"\e903"}.icon-plus:before{content:"\e90e"}.icon-printer:before{content:"\e90b"}.icon-refresh-cw:before{content:"\e904"}.icon-search:before{content:"\e90a"}.icon-toggle-right:before{content:"\e905"}.icon-trash-2:before{content:"\e906"}.icon-sort-amount-asc:before{content:"\ea4c"}.bootstrap-table *{box-sizing:border-box}.bootstrap-table .btn,.bootstrap-table input.form-control,.bootstrap-table select.form-control{border-radius:4px;background-color:#fff;border:1px solid #ccc;padding:9px 12px}.bootstrap-table select.form-control{height:35px}.bootstrap-table .btn{outline:0;cursor:pointer}.bootstrap-table .btn.active{background-color:#ebebeb}.bootstrap-table .btn:focus,.bootstrap-table .btn:hover{background-color:#f5f5f5}.bootstrap-table .caret{display:inline-block;width:0;height:0;margin-left:2px;vertical-align:middle;border-top:4px dashed;border-top:4px solid;border-right:4px solid transparent;border-left:4px solid transparent}.bootstrap-table .detail-icon{text-decoration:none;color:#3679e4}.bootstrap-table .detail-icon:hover{color:#154a9f}.bootstrap-table .fixed-table-toolbar .columns,.bootstrap-table .fixed-table-toolbar .columns .btn-group{display:inline-block}.bootstrap-table .fixed-table-toolbar .columns>.btn-group:not(:first-child):not(:last-child),.bootstrap-table .fixed-table-toolbar .columns>.btn-group:not(:first-child):not(:last-child)>.btn,.bootstrap-table .fixed-table-toolbar .columns>.btn:not(:first-child):not(:last-child),.bootstrap-table .fixed-table-toolbar .columns>.btn:not(:first-child):not(:last-child)>.btn{border-radius:0}.bootstrap-table .fixed-table-toolbar .columns>.btn-group:not(:last-child):not(.dropdown-toggle),.bootstrap-table .fixed-table-toolbar .columns>.btn-group:not(:last-child)>.btn,.bootstrap-table .fixed-table-toolbar .columns>.btn:not(:last-child):not(.dropdown-toggle),.bootstrap-table .fixed-table-toolbar .columns>.btn:not(:last-child)>.btn{border-top-right-radius:0;border-bottom-right-radius:0;border-right:none}.bootstrap-table .fixed-table-toolbar .columns>.btn-group:not(:first-child):not(.dropdown-toggle),.bootstrap-table .fixed-table-toolbar .columns>.btn-group:not(:first-child)>.btn,.bootstrap-table .fixed-table-toolbar .columns>.btn:not(:first-child):not(.dropdown-toggle),.bootstrap-table .fixed-table-toolbar .columns>.btn:not(:first-child)>.btn{border-top-left-radius:0;border-bottom-left-radius:0}.bootstrap-table .fixed-table-toolbar .columns label{padding:5px 12px}.bootstrap-table .fixed-table-toolbar .columns input[type=checkbox]{vertical-align:middle}.bootstrap-table .fixed-table-toolbar .columns .dropdown-divider{border-bottom:1px solid #dbdbdb}.bootstrap-table .fixed-table-toolbar .search .input-group .search-input{border-top-right-radius:0;border-bottom-right-radius:0;border-right:none}.bootstrap-table .fixed-table-toolbar .search .input-group button[name=clearSearch],.bootstrap-table .fixed-table-toolbar .search .input-group button[name=search]{border-top-left-radius:0;border-bottom-left-radius:0}.bootstrap-table .fixed-table-toolbar .search .input-group button[name=clearSearch]:not(:last-child),.bootstrap-table .fixed-table-toolbar .search .input-group button[name=search]:not(:last-child){border-top-right-radius:0;border-bottom-right-radius:0;border-right:none}.bootstrap-table .open.dropdown-menu{display:block}.bootstrap-table .dropdown-menu-up .dropdown-menu{top:auto;bottom:100%}.bootstrap-table .dropdown-menu{display:none;background-color:#fff;position:absolute;right:0;min-width:120px;margin-top:2px;border:1px solid #ccc;border-radius:4px;-webkit-box-shadow:0 3px 12px rgba(0,0,0,.175);box-shadow:0 3px 12px rgba(0,0,0,.175)}.bootstrap-table .dropdown-menu .dropdown-item{color:#363636;text-decoration:none;display:block;padding:5px 12px;white-space:nowrap}.bootstrap-table .dropdown-menu .dropdown-item:hover{background-color:#f5f5f5}.bootstrap-table .dropdown-menu .dropdown-item.active{background-color:#3679e4;color:#fff}.bootstrap-table .dropdown-menu .dropdown-item.active:hover{background-color:#1b5fcc}.bootstrap-table .columns-left .dropdown-menu{left:0;right:auto}.bootstrap-table .pagination-detail{float:left}.bootstrap-table .pagination-detail .dropdown-item{min-width:45px;text-align:center}.bootstrap-table table{border-collapse:collapse}.bootstrap-table table th{text-align:inherit}.bootstrap-table table.table-bordered tbody tr td,.bootstrap-table table.table-bordered thead tr th{border:1px solid #dbdbdb}.bootstrap-table table.table-bordered tbody tr td{padding:.75rem}.bootstrap-table table.table-hover tbody tr:hover{background:#fafafa}.bootstrap-table .float-left{float:left}.bootstrap-table .float-right{float:right}.bootstrap-table .pagination{padding:0;align-items:center;display:flex;justify-content:center;text-align:center;list-style:none}.bootstrap-table .pagination .page-item{border:1px solid #dbdbdb;background-color:#fff;border-radius:4px;margin:2px;padding:5px 2px 5px 2px}.bootstrap-table .pagination .page-item:hover{background-color:#f5f5f5}.bootstrap-table .pagination .page-item .page-link{padding:6px 12px;line-height:1.428571429;color:#363636;text-decoration:none;outline:0}.bootstrap-table .pagination .page-item.active{background-color:#3679e4;border:1px solid #206ae1}.bootstrap-table .pagination .page-item.active .page-link{color:#fff}.bootstrap-table .pagination .page-item.active:hover{background-color:#1b5fcc}.bootstrap-table .pagination .btn-group{display:inline-block}.bootstrap-table .pagination .btn-group .btn:not(:first-child):not(:last-child),.bootstrap-table .pagination .btn-group input:not(:first-child):not(:last-child){border-radius:0}.bootstrap-table .pagination .btn-group .btn:first-child:not(:last-child):not(.dropdown-toggle),.bootstrap-table .pagination .btn-group input:first-child:not(:last-child):not(.dropdown-toggle){border-top-right-radius:0;border-bottom-right-radius:0}.bootstrap-table .pagination .btn-group .btn:last-child:not(:first-child),.bootstrap-table .pagination .btn-group input:last-child:not(:first-child){border-top-left-radius:0;border-bottom-left-radius:0}.bootstrap-table .pagination .btn-group>.btn-group:last-child:not(:first-child)>.btn:first-child{border-top-left-radius:0;border-bottom-left-radius:0}.bootstrap-table .filter-control{display:flex}.bootstrap-table .page-jump-to .btn,.bootstrap-table .page-jump-to input{padding:8px 12px}.modal{position:fixed;display:none;top:0;left:0;bottom:0;right:0}.modal.show{display:flex}.modal .btn{border-radius:4px;background-color:#fff;border:1px solid #ccc;padding:6px 12px;outline:0;cursor:pointer}.modal .btn.active{border-color:#000}.modal .modal-background{position:fixed;top:0;left:0;bottom:0;right:0;z-index:998;background-color:rgba(10,10,10,.86)}.modal .modal-content{position:relative;width:600px;margin:30px auto;z-index:999}.modal .modal-content .box{background-color:#fff;border-radius:6px;display:block;padding:1.25rem} \ No newline at end of file diff --git a/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.min.js b/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.min.js new file mode 100644 index 0000000000..363d4ce3fd --- /dev/null +++ b/InvenTree/InvenTree/static/bootstrap-table/themes/bootstrap-table/bootstrap-table.min.js @@ -0,0 +1,10 @@ +/** + * bootstrap-table - An extended table to integration with some of the most widely used CSS frameworks. (Supports Bootstrap, Semantic UI, Bulma, Material Design, Foundation) + * + * @version v1.18.3 + * @homepage https://bootstrap-table.com + * @author wenzhixin (http://wenzhixin.net.cn/) + * @license MIT + */ + +!function(t,n){"object"==typeof exports&&"undefined"!=typeof module?n(require("jquery")):"function"==typeof define&&define.amd?define(["jquery"],n):n((t="undefined"!=typeof globalThis?globalThis:t||self).jQuery)}(this,(function(t){"use strict";function n(t){return t&&"object"==typeof t&&"default"in t?t:{default:t}}var e=n(t);function r(t,n){if(!(t instanceof n))throw new TypeError("Cannot call a class as a function")}function o(t,n){for(var e=0;e0?vt:gt)(t)},wt=Math.min,mt=function(t){return t>0?wt(bt(t),9007199254740991):0},Ot=Math.max,jt=Math.min,St=function(t){return function(n,e,r){var o,i=P(n),u=mt(i.length),c=function(t,n){var e=bt(t);return e<0?Ot(e+n,0):jt(e,n)}(r,u);if(t&&e!=e){for(;u>c;)if((o=i[c++])!=o)return!0}else for(;u>c;c++)if((t||c in i)&&i[c]===e)return t||c||0;return!t&&-1}},Tt={includes:St(!0),indexOf:St(!1)},Pt=Tt.indexOf,Et=function(t,n){var e,r=P(t),o=0,i=[];for(e in r)!_(et,e)&&_(r,e)&&i.push(e);for(;n.length>o;)_(r,e=n[o++])&&(~Pt(i,e)||i.push(e));return i},xt=["constructor","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","toLocaleString","toString","valueOf"],kt=xt.concat("length","prototype"),_t={f:Object.getOwnPropertyNames||function(t){return Et(t,kt)}},At={f:Object.getOwnPropertySymbols},Ct=ht("Reflect","ownKeys")||function(t){var n=_t.f(F(t)),e=At.f;return e?n.concat(e(t)):n},Rt=function(t,n){for(var e=Ct(n),r=L.f,o=I.f,i=0;i=74)&&(at=Qt.match(/Chrome\/(\d+)/))&&(lt=at[1]);var Yt,$t=lt&&+lt,Ht=!!Object.getOwnPropertySymbols&&!y((function(){return!Symbol.sham&&(Kt?38===$t:$t>37&&$t<41)})),Jt=Ht&&!Symbol.sham&&"symbol"==typeof Symbol.iterator,Zt=$("wks"),tn=d.Symbol,nn=Jt?tn:tn&&tn.withoutSetter||Z,en=function(t){return _(Zt,t)&&(Ht||"string"==typeof Zt[t])||(Ht&&_(tn,t)?Zt[t]=tn[t]:Zt[t]=nn("Symbol."+t)),Zt[t]},rn=en("species"),on=function(t,n){var e;return Gt(t)&&("function"!=typeof(e=t.constructor)||e!==Array&&!Gt(e.prototype)?E(e)&&null===(e=e[rn])&&(e=void 0):e=void 0),new(void 0===e?Array:e)(0===n?0:n)},un=[].push,cn=function(t){var n=1==t,e=2==t,r=3==t,o=4==t,i=6==t,u=7==t,c=5==t||i;return function(f,a,l,s){for(var p,d,y=Object(T(f)),h=S(y),g=Wt(a,l,3),v=mt(h.length),b=0,w=s||on,m=n?w(f,v):e||u?w(f,0):void 0;v>b;b++)if((c||b in h)&&(d=g(p=h[b],b,y),t))if(n)m[b]=d;else if(d)switch(t){case 3:return!0;case 5:return p;case 6:return b;case 2:un.call(m,p)}else switch(t){case 4:return!1;case 7:un.call(m,p)}return i?-1:r||o?o:m}},fn={forEach:cn(0),map:cn(1),filter:cn(2),some:cn(3),every:cn(4),find:cn(5),findIndex:cn(6),filterOut:cn(7)},an=Object.keys||function(t){return Et(t,xt)},ln=h?Object.defineProperties:function(t,n){F(t);for(var e,r=an(n),o=r.length,i=0;o>i;)L.f(t,e=r[i++],n[e]);return t},sn=ht("document","documentElement"),pn=nt("IE_PROTO"),dn=function(){},yn=function(t){return" - + - - diff --git a/InvenTree/templates/clip.html b/InvenTree/templates/clip.html index b0edff2fb3..6051e439b4 100644 --- a/InvenTree/templates/clip.html +++ b/InvenTree/templates/clip.html @@ -1,5 +1,5 @@ {% load i18n %} - + \ No newline at end of file diff --git a/InvenTree/templates/hover_image.html b/InvenTree/templates/hover_image.html index 556a8db140..e9f781655b 100644 --- a/InvenTree/templates/hover_image.html +++ b/InvenTree/templates/hover_image.html @@ -1,6 +1,6 @@ {% load static %} -
+
{% if hover %} {% endif %} diff --git a/InvenTree/templates/js/dynamic/inventree.js b/InvenTree/templates/js/dynamic/inventree.js index 4766565d3c..0172e47706 100644 --- a/InvenTree/templates/js/dynamic/inventree.js +++ b/InvenTree/templates/js/dynamic/inventree.js @@ -111,7 +111,7 @@ function inventreeDocReady() { modal.modal({ backdrop: 'static', - keyboard: 'false', + keyboard: true, }); modal.modal('show'); @@ -169,12 +169,7 @@ function inventreeDocReady() { html += ''; if (user_settings.SEARCH_SHOW_STOCK_LEVELS) { - html += partStockLabel( - item.data, - { - label_class: 'label-right', - } - ); + html += partStockLabel(item.data); } html += ''; @@ -195,6 +190,13 @@ function inventreeDocReady() { $('.brand-icon').each(function(i, obj) { loadBrandIcon($(this), $(this).attr('brand_name')); }); + + // Callback for "admin view" button + $('#admin-button').click(function() { + var url = $(this).attr('url'); + + location.href = url; + }); } function isFileTransfer(transfer) { diff --git a/InvenTree/templates/js/dynamic/nav.js b/InvenTree/templates/js/dynamic/nav.js index ddf3cb8c12..b99a3bb6bd 100644 --- a/InvenTree/templates/js/dynamic/nav.js +++ b/InvenTree/templates/js/dynamic/nav.js @@ -2,60 +2,26 @@ */ /* exported - attachNavCallbacks, - enableNavbar, - initNavTree, - loadTree, + activatePanel, + addSidebarHeader, + addSidebarItem, + addSidebarLink, + enableSidebar, onPanelLoad, */ /* -* Attach callbacks to navigation bar elements. -* -* Searches for elements with the class 'nav-toggle'. -* A callback is added to each element, -* to display the matching panel. -* -* The 'id' of the .nav-toggle element should be of the form "select-", -* and point to a matching "panel-" -*/ -function attachNavCallbacks(options={}) { - - $('.nav-toggle').click(function() { - var el = $(this); - - // Find the matching "panel" element - var panelName = el.attr('id').replace('select-', ''); - - activatePanel(panelName, options); - }); - - var panelClass = options.name || 'unknown'; - - /* Look for a default panel to initialize - * First preference = URL parameter e.g. ?display=part-stock - * Second preference = localStorage - * Third preference = default - */ - var defaultPanel = $.urlParam('display') || localStorage.getItem(`inventree-selected-panel-${panelClass}`) || options.default; - - if (defaultPanel) { - activatePanel(defaultPanel); - } -} - - -function activatePanel(panelName, options={}) { - - var panelClass = options.name || 'unknown'; + * Activate (display) the selected panel + */ +function activatePanel(label, panel_name, options={}) { // First, cause any other panels to "fade out" $('.panel-visible').hide(); $('.panel-visible').removeClass('panel-visible'); - + // Find the target panel - var panel = `#panel-${panelName}`; - var select = `#select-${panelName}`; + var panel = `#panel-${panel_name}`; + var select = `#select-${panel_name}`; // Check that the selected panel (and select) exist if ($(panel).length && $(select).length) { @@ -63,22 +29,22 @@ function activatePanel(panelName, options={}) { } else { // Either the select or the panel are not displayed! // Iterate through the available 'select' elements until one matches - panelName = null; + panel_name = null; - $('.nav-toggle').each(function() { - var panel_name = $(this).attr('id').replace('select-', ''); + $('.sidebar-selector').each(function() { + var name = $(this).attr('id').replace('select-', ''); - if ($(`#panel-${panel_name}`).length && (panelName == null)) { - panelName = panel_name; + if ($(`#panel-${name}`).length && (panel_name == null)) { + panel_name = name; } - panel = `#panel-${panelName}`; - select = `#select-${panelName}`; + panel = `#panel-${panel_name}`; + select = `#select-${panel_name}`; }); } // Save the selected panel - localStorage.setItem(`inventree-selected-panel-${panelClass}`, panelName); + localStorage.setItem(`inventree-selected-panel-${label}`, panel_name); // Display the panel $(panel).addClass('panel-visible'); @@ -93,9 +59,9 @@ function activatePanel(panelName, options={}) { $('.list-group-item').removeClass('active'); // Find the associated selector - var selectElement = `#select-${panelName}`; + var selector = `#select-${panel_name}`; - $(selectElement).parent('.list-group-item').addClass('active'); + $(selector).addClass('active'); } @@ -117,252 +83,129 @@ function onPanelLoad(panel, callback) { }); } -function loadTree(url, tree, options={}) { - /* Load the side-nav tree view - - Args: - url: URL to request tree data - tree: html ref to treeview - options: - data: data object to pass to the AJAX request - selected: ID of currently selected item - name: name of the tree - */ - - var data = {}; - - if (options.data) { - data = options.data; - } - - var key = 'inventree-sidenav-items-'; - - if (options.name) { - key += options.name; - } - - $.ajax({ - url: url, - type: 'get', - dataType: 'json', - data: data, - success: function(response) { - if (response.tree) { - $(tree).treeview({ - data: response.tree, - enableLinks: true, - showTags: true, - }); - - if (localStorage.getItem(key)) { - var saved_exp = localStorage.getItem(key).split(','); - - // Automatically expand the desired notes - for (var q = 0; q < saved_exp.length; q++) { - $(tree).treeview('expandNode', parseInt(saved_exp[q])); - } - } - - // Setup a callback whenever a node is toggled - $(tree).on('nodeExpanded nodeCollapsed', function(event, data) { - - // Record the entire list of expanded items - var expanded = $(tree).treeview('getExpanded'); - - var exp = []; - - for (var i = 0; i < expanded.length; i++) { - exp.push(expanded[i].nodeId); - } - - // Save the expanded nodes - localStorage.setItem(key, exp); - }); - } - }, - error: function(xhr, ajaxOptions, thrownError) { - // TODO - } - }); -} - /** - * Initialize navigation tree display + * Enable support for sidebar on this page */ -function initNavTree(options) { +function enableSidebar(label, options={}) { - var resize = true; + // Enable callbacks for sidebar buttons + $('.sidebar-selector').click(function() { + var el = $(this); - if ('resize' in options) { - resize = options.resize; - } + // Find the matching panel element to display + var panel_name = el.attr('id').replace('select-', ''); - var label = options.label || 'nav'; - - var stateLabel = `${label}-tree-state`; - var widthLabel = `${label}-tree-width`; - - var treeId = options.treeId || '#sidenav-left'; - var toggleId = options.toggleId; - - // Initially hide the tree - $(treeId).animate({ - width: '0px', - }, 0, function() { - - if (resize) { - $(treeId).resizable({ - minWidth: '0px', - maxWidth: '500px', - handles: 'e, se', - grid: [5, 5], - stop: function(event, ui) { - var width = Math.round(ui.element.width()); - - if (width < 75) { - $(treeId).animate({ - width: '0px' - }, 50); - - localStorage.setItem(stateLabel, 'closed'); - } else { - localStorage.setItem(stateLabel, 'open'); - localStorage.setItem(widthLabel, `${width}px`); - } - } - }); - } - - var state = localStorage.getItem(stateLabel); - var width = localStorage.getItem(widthLabel) || '300px'; - - if (state && state == 'open') { - - $(treeId).animate({ - width: width, - }, 50); - } + activatePanel(label, panel_name, options); }); - // Register callback for 'toggle' button - if (toggleId) { - - $(toggleId).click(function() { + /* Look for a "default" panel to initialize for this page + * + * - First preference = URL parameter e.g. ?display=part-stock + * - Second preference = local storage + * - Third preference = default + */ - var state = localStorage.getItem(stateLabel) || 'closed'; - var width = localStorage.getItem(widthLabel) || '300px'; + var selected_panel = $.urlParam('display') || localStorage.getItem(`inventree-selected-panel-${label}`) || options.default; - if (state == 'open') { - $(treeId).animate({ - width: '0px' - }, 50); + if (selected_panel) { + activatePanel(label, selected_panel); + } else { + // Find the "first" available panel (according to the sidebar) + var selector = $('.sidebar-selector').first(); - localStorage.setItem(stateLabel, 'closed'); - } else { - $(treeId).animate({ - width: width, - }, 50); + if (selector.exists()) { + var panel_name = selector.attr('id').replace('select-', ''); + activatePanel(label, panel_name); + } + } - localStorage.setItem(stateLabel, 'open'); - } + if (options.hide_toggle) { + // Hide the toggle button if specified + $('#sidebar-toggle').remove(); + } else { + $('#sidebar-toggle').click(function() { + // Add callback to "collapse" and "expand" the sidebar + + // By default, the menu is "expanded" + var state = localStorage.getItem(`inventree-menu-state-${label}`) || 'expanded'; + + // We wish to "toggle" the state! + setSidebarState(label, state == 'expanded' ? 'collapsed' : 'expanded'); }); } + + // Set the initial state (default = expanded) + var state = localStorage.getItem(`inventree-menu-state-${label}`) || 'expanded'; + + setSidebarState(label, state); + + // Finally, show the sidebar + $('#sidebar').show(); + } -/** - * Handle left-hand icon menubar display +/* + * Set the "toggle" state of the sidebar */ -function enableNavbar(options) { +function setSidebarState(label, state) { - var resize = true; - - if ('resize' in options) { - resize = options.resize; - } - - var label = options.label || 'nav'; - - label = `navbar-${label}`; - - var stateLabel = `${label}-state`; - var widthLabel = `${label}-width`; - - var navId = options.navId || '#sidenav-right'; - - var toggleId = options.toggleId; - - // Extract the saved width for this element - $(navId).animate({ - 'width': '45px', - 'min-width': '45px', - 'display': 'block', - }, 50, function() { - - // Make the navbar resizable - if (resize) { - $(navId).resizable({ - minWidth: options.minWidth || '100px', - maxWidth: options.maxWidth || '500px', - handles: 'e, se', - grid: [5, 5], - stop: function(event, ui) { - // Record the new width - var width = Math.round(ui.element.width()); - - // Reasonably narrow? Just close it! - if (width <= 75) { - $(navId).animate({ - width: '45px' - }, 50); - - localStorage.setItem(stateLabel, 'closed'); - } else { - localStorage.setItem(widthLabel, `${width}px`); - localStorage.setItem(stateLabel, 'open'); - } - } - }); - } - - var state = localStorage.getItem(stateLabel); - - var width = localStorage.getItem(widthLabel) || '250px'; - - if (state && state == 'open') { - - $(navId).animate({ - width: width - }, 100); - } - - }); - - // Register callback for 'toggle' button - if (toggleId) { - - $(toggleId).click(function() { - - var state = localStorage.getItem(stateLabel) || 'closed'; - var width = localStorage.getItem(widthLabel) || '250px'; - - if (state == 'open') { - $(navId).animate({ - width: '45px', - minWidth: '45px', - }, 50); - - localStorage.setItem(stateLabel, 'closed'); - - } else { - - $(navId).animate({ - 'width': width - }, 50); - - localStorage.setItem(stateLabel, 'open'); - } + if (state == 'collapsed') { + $('.sidebar-item-text').animate({ + 'opacity': 0.0, + 'font-size': '0%', + }, 100, function() { + $('.sidebar-item-text').hide(); + $('#sidebar-toggle-icon').removeClass('fa-chevron-left').addClass('fa-chevron-right'); }); + } else { + $('.sidebar-item-text').show(); + $('#sidebar-toggle-icon').removeClass('fa-chevron-right').addClass('fa-chevron-left'); + $('.sidebar-item-text').animate({ + 'opacity': 1.0, + 'font-size': '100%', + }, 100); } + + // Save the state of this sidebar + localStorage.setItem(`inventree-menu-state-${label}`, state); +} + + +/* + * Dynamically construct and insert a sidebar item into the sidebar at runtime. + * This mirrors the templated code in "sidebar_item.html" + */ +function addSidebarItem(options={}) { + + var html = ` + + + ${options.content_before || ''} + + + ${options.content_after || ''} + + `; + + $('#sidebar-list-group').append(html); +} + +/* + * Dynamicall construct and insert a sidebar header into the sidebar at runtime + * This mirrors the templated code in "sidebar_header.html" + */ +function addSidebarHeader(options={}) { + + var html = ` + +
+ + +
+
+ `; + + $('#sidebar-list-group').append(html); } diff --git a/InvenTree/templates/js/translated/attachment.js b/InvenTree/templates/js/translated/attachment.js index 88c73ed3e3..5ff5786588 100644 --- a/InvenTree/templates/js/translated/attachment.js +++ b/InvenTree/templates/js/translated/attachment.js @@ -27,7 +27,7 @@ function loadAttachmentTable(url, options) { return '{% trans "No attachments found" %}'; }, sortable: true, - search: false, + search: true, queryParams: options.filters || {}, onPostBody: function() { // Add callback for 'edit' button @@ -58,12 +58,16 @@ function loadAttachmentTable(url, options) { var fn = value.toLowerCase(); - if (fn.endsWith('.pdf')) { + if (fn.endsWith('.csv')) { + icon = 'fa-file-csv'; + } else if (fn.endsWith('.pdf')) { icon = 'fa-file-pdf'; } else if (fn.endsWith('.xls') || fn.endsWith('.xlsx')) { icon = 'fa-file-excel'; } else if (fn.endsWith('.doc') || fn.endsWith('.docx')) { icon = 'fa-file-word'; + } else if (fn.endsWith('.zip') || fn.endsWith('.7z')) { + icon = 'fa-file-archive'; } else { var images = ['.png', '.jpg', '.bmp', '.gif', '.svg', '.tif']; diff --git a/InvenTree/templates/js/translated/bom.js b/InvenTree/templates/js/translated/bom.js index 89ae428bcd..ee04cb8660 100644 --- a/InvenTree/templates/js/translated/bom.js +++ b/InvenTree/templates/js/translated/bom.js @@ -407,7 +407,7 @@ function loadBomTable(table, options) { // Display an extra icon if this part is an assembly if (sub_part.assembly) { - var text = ``; + var text = ``; html += renderLink(text, `/part/${row.sub_part}/bom/`); } @@ -470,7 +470,7 @@ function loadBomTable(table, options) { var text = value; if (value == null || value <= 0) { - text = `{% trans "No Stock" %}`; + text = `{% trans "No Stock" %}`; } return renderLink(text, url); @@ -612,7 +612,7 @@ function loadBomTable(table, options) { var bValidate = makeIconButton('fa-check-circle icon-green', 'bom-validate-button', row.pk, '{% trans "Validate BOM Item" %}'); - var bValid = ``; + var bValid = makeIconButton('fa-check-double icon-green', 'bom-valid-button', row.pk, '{% trans "This line has been validated" %}', {disabled: true}); var bSubs = makeIconButton('fa-exchange-alt icon-blue', 'bom-substitutes-button', row.pk, '{% trans "Edit substitute parts" %}'); diff --git a/InvenTree/templates/js/translated/build.js b/InvenTree/templates/js/translated/build.js index b6c98fc49e..dec9a4aaf7 100644 --- a/InvenTree/templates/js/translated/build.js +++ b/InvenTree/templates/js/translated/build.js @@ -34,8 +34,8 @@ function buildFormFields() { reference: { prefix: global_settings.BUILDORDER_REFERENCE_PREFIX, }, - title: {}, part: {}, + title: {}, quantity: {}, parent: { filters: { @@ -937,7 +937,10 @@ function loadBuildOutputAllocationTable(buildInfo, output, options={}) { var progress = makeProgressBar( allocatedLines, - totalLines + totalLines, + { + max_width: '150px', + } ); build_progress.html(progress); diff --git a/InvenTree/templates/js/translated/company.js b/InvenTree/templates/js/translated/company.js index 68b3079c3e..0e71ad99b1 100644 --- a/InvenTree/templates/js/translated/company.js +++ b/InvenTree/templates/js/translated/company.js @@ -325,15 +325,15 @@ function loadCompanyTable(table, url, options={}) { var html = imageHoverIcon(row.image) + renderLink(value, row.url); if (row.is_customer) { - html += ``; + html += ``; } if (row.is_manufacturer) { - html += ``; + html += ``; } if (row.is_supplier) { - html += ``; + html += ``; } return html; @@ -493,15 +493,15 @@ function loadManufacturerPartTable(table, url, options) { var html = imageHoverIcon(row.part_detail.thumbnail) + renderLink(value, url); if (row.part_detail.is_template) { - html += ``; + html += ``; } if (row.part_detail.assembly) { - html += ``; + html += ``; } if (!row.part_detail.active) { - html += `{% trans "Inactive" %}`; + html += `{% trans "Inactive" %}`; } return html; @@ -750,15 +750,15 @@ function loadSupplierPartTable(table, url, options) { var html = imageHoverIcon(row.part_detail.thumbnail) + renderLink(value, url); if (row.part_detail.is_template) { - html += ``; + html += ``; } if (row.part_detail.assembly) { - html += ``; + html += ``; } if (!row.part_detail.active) { - html += `{% trans "Inactive" %}`; + html += `{% trans "Inactive" %}`; } return html; diff --git a/InvenTree/templates/js/translated/filters.js b/InvenTree/templates/js/translated/filters.js index 6b109e2d18..a2ef36f1d3 100644 --- a/InvenTree/templates/js/translated/filters.js +++ b/InvenTree/templates/js/translated/filters.js @@ -281,7 +281,7 @@ function setupFilterList(tableKey, table, target) { // One blank slate, please element.empty(); - element.append(``); + element.append(``); // Callback for reloading the table element.find(`#reload-${tableKey}`).click(function() { @@ -294,10 +294,10 @@ function setupFilterList(tableKey, table, target) { } // If there are filters currently "in use", add them in! - element.append(``); + element.append(``); if (Object.keys(filters).length > 0) { - element.append(``); + element.append(``); } for (var key in filters) { @@ -320,7 +320,7 @@ function setupFilterList(tableKey, table, target) { html += generateAvailableFilterList(tableKey); html += generateFilterInput(tableKey); - html += ``; + html += ``; element.append(html); diff --git a/InvenTree/templates/js/translated/forms.js b/InvenTree/templates/js/translated/forms.js index a338310fd1..396226d52b 100644 --- a/InvenTree/templates/js/translated/forms.js +++ b/InvenTree/templates/js/translated/forms.js @@ -2,7 +2,6 @@ {% load inventree_extras %} /* globals - attachToggle, createNewModal, inventreeFormDataUpload, inventreeGet, @@ -49,6 +48,9 @@ * */ +// Set global default theme for select2 +$.fn.select2.defaults.set('theme', 'bootstrap-5'); + /* * Return true if the OPTIONS specify that the user * can perform a GET method at the endpoint. @@ -519,11 +521,6 @@ function constructFormBody(fields, options) { // Attach clear callbacks (if required) addClearCallbacks(fields, options); - attachToggle(modal); - - $(modal + ' .select2-container').addClass('select-full-width'); - $(modal + ' .select2-container').css('width', '100%'); - modalShowSubmitButton(modal, true); $(modal).on('click', '#modal-form-submit', function() { @@ -563,13 +560,14 @@ function insertConfirmButton(options) { var message = options.confirmMessage || '{% trans "Confirm" %}'; - var confirm = ` - - ${message} - - `; + var html = ` +
+ + +
+ `; - $(options.modal).find('#modal-footer-buttons').append(confirm); + $(options.modal).find('#modal-footer-buttons').append(html); // Disable the 'submit' button $(options.modal).find('#modal-form-submit').prop('disabled', true); @@ -930,7 +928,7 @@ function clearFormErrors(options) { $(options.modal).find('.form-error-message').remove(); // Remove the "has error" class - $(options.modal).find('.has-error').removeClass('has-error'); + $(options.modal).find('.form-field-error').removeClass('form-field-error'); // Hide the 'non field errors' $(options.modal).find('#non-field-errors').html(''); @@ -1103,8 +1101,8 @@ function handleFormErrors(errors, fields, options) { */ function addFieldErrorMessage(field_name, error_text, error_idx, options) { - // Add the 'has-error' class - $(options.modal).find(`#div_id_${field_name}`).addClass('has-error'); + // Add the 'form-field-error' class + $(options.modal).find(`#div_id_${field_name}`).addClass('form-field-error'); var field_dom = $(options.modal).find(`#errors-${field_name}`); @@ -1299,7 +1297,7 @@ function addSecondaryModal(field, fields, options) { var html = ` -
+
${secondary.label || secondary.title}
`; @@ -1585,7 +1583,6 @@ function initializeChoiceField(field, fields, options) { select.select2({ dropdownAutoWidth: false, dropdownParent: $(options.modal), - width: '100%', }); } @@ -1731,7 +1728,7 @@ function constructField(name, parameters, options) {
`; if (group_options.collapsible) { html += ` -
+
`; } else { @@ -1757,7 +1754,7 @@ function constructField(name, parameters, options) { var form_classes = 'form-group'; if (parameters.errors) { - form_classes += ' has-error'; + form_classes += ' form-field-error'; } // Optional content to render before the field @@ -1799,7 +1796,7 @@ function constructField(name, parameters, options) { html += `
`; if (parameters.prefix) { - html += `${parameters.prefix}`; + html += `${parameters.prefix}`; } } @@ -1809,7 +1806,7 @@ function constructField(name, parameters, options) { if (!parameters.required) { html += ` - + `; } @@ -1818,7 +1815,11 @@ function constructField(name, parameters, options) { } if (parameters.help_text && !options.hideLabels) { - html += constructHelpText(name, parameters, options); + + // Boolean values are handled differently! + if (parameters.type != 'boolean') { + html += constructHelpText(name, parameters, options); + } } // Div for error messages @@ -1993,7 +1994,6 @@ function constructInputOptions(name, classes, type, parameters) { switch (parameters.type) { case 'boolean': - opts.push(`style='display: inline-block; width: 20px; margin-right: 20px;'`); break; case 'integer': case 'float': @@ -2006,6 +2006,15 @@ function constructInputOptions(name, classes, type, parameters) { if (parameters.multiline) { return ``; + } else if (parameters.type == 'boolean') { + return ` +
+ + +
+ `; } else { return ``; } @@ -2029,7 +2038,7 @@ function constructCheckboxInput(name, parameters) { return constructInputOptions( name, - 'checkboxinput', + 'form-check-input', 'checkbox', parameters ); @@ -2114,7 +2123,7 @@ function constructChoiceInput(name, parameters) { */ function constructRelatedFieldInput(name) { - var html = ``; + var html = ``; // Don't load any options - they will be filled via an AJAX request @@ -2188,13 +2197,7 @@ function constructRawInput(name, parameters) { */ function constructHelpText(name, parameters) { - var style = ''; - - if (parameters.type == 'boolean') { - style = `style='display: inline-block; margin-left: 25px' `; - } - - var html = `
${parameters.help_text}
`; + var html = `
${parameters.help_text}
`; return html; } diff --git a/InvenTree/templates/js/translated/helpers.js b/InvenTree/templates/js/translated/helpers.js index 1bc15ea402..a1679a25b9 100644 --- a/InvenTree/templates/js/translated/helpers.js +++ b/InvenTree/templates/js/translated/helpers.js @@ -16,9 +16,9 @@ function yesNoLabel(value) { if (value) { - return `{% trans "YES" %}`; + return `{% trans "YES" %}`; } else { - return `{% trans "NO" %}`; + return `{% trans "NO" %}`; } } @@ -92,7 +92,7 @@ function select2Thumbnail(image) { */ function makeIconBadge(icon, title) { - var html = ``; + var html = ``; return html; } @@ -103,7 +103,7 @@ function makeIconBadge(icon, title) { */ function makeIconButton(icon, cls, pk, title, options={}) { - var classes = `btn btn-default btn-glyph ${cls}`; + var classes = `btn btn-outline-secondary ${cls}`; var id = `${cls}-${pk}`; @@ -182,8 +182,14 @@ function makeProgressBar(value, maximum, opts={}) { var id = options.id || 'progress-bar'; + var style = ''; + + if (opts.max_width) { + style += `max-width: ${options.max_width}; `; + } + return ` -
+
${text}
diff --git a/InvenTree/templates/js/translated/modals.js b/InvenTree/templates/js/translated/modals.js index f9658df559..32b5260e76 100644 --- a/InvenTree/templates/js/translated/modals.js +++ b/InvenTree/templates/js/translated/modals.js @@ -47,14 +47,12 @@ function createNewModal(options={}) {