// ==UserScript== // @name Best Teacher(JQuery) // @version 2023.301.5132113 // @author jimbo // @description 谁是最好的老师?-排序显示,经验值计算|自定义经验值公式|好评率|显示年龄|列表显示所有教师 // @homepage https://gitee.com/tsharp/userscripts#readme // @supportURL https://gitee.com/tsharp/userscripts/findteacherson51talk // @namespace https://github.com/niubilityfrontend // @license OSL-3.0 // @include *51talk.com/ReserveNew/index* // @include *51talk.com/TeacherNew/* // @include *51talk.com/user/* // @include *51talk.cn/ReserveNew/index* // @include *51talk.cn/TeacherNew/* // @include *51talk.cn/user/* // @include *51suyang.cn/ReserveNew/index* // @include *51suyang.cn/TeacherNew/* // @include *51suyang.cn/user/* // @grant GM_xmlhttpRequest // @grant GM_getValue // @grant GM_setValue // @grant GM_listValues // @grant GM_deleteValue // @grant GM_registerMenuCommand // @downloadURL https://update.greasyfork.icu/scripts/388276/Best%20Teacher%28JQuery%29.user.js // @updateURL https://update.greasyfork.icu/scripts/388276/Best%20Teacher%28JQuery%29.meta.js // ==/UserScript== /*! For license information please see findingteacher.user.js.LICENSE.txt */ (()=>{var __webpack_modules__={818:function(module,exports,__webpack_require__){var __WEBPACK_AMD_DEFINE_ARRAY__,__WEBPACK_AMD_DEFINE_RESULT__;!function(t,e){"use strict";__WEBPACK_AMD_DEFINE_ARRAY__=[__webpack_require__(336)],void 0===(__WEBPACK_AMD_DEFINE_RESULT__=function(i){return e(i,t.document)}.apply(exports,__WEBPACK_AMD_DEFINE_ARRAY__))||(module.exports=__WEBPACK_AMD_DEFINE_RESULT__)}("undefined"!=typeof window?window:this,(function($,document){"use strict";var englishLanguageDefaults={name:"English (United States)",nameEnglish:"English (United States)",isRTL:!1,defaults:{recordtext:"View {0} - {1} of {2}",emptyrecords:"No records to view",loadtext:"Loading...",pgtext:"Page {0} of {1}",pgfirst:"First Page",pglast:"Last Page",pgnext:"Next Page",pgprev:"Previous Page",pgrecs:"Records per Page",showhide:"Toggle Expand Collapse Grid",savetext:"Saving..."},search:{caption:"Search...",Find:"Find",Reset:"Reset",odata:[{oper:"eq",text:"equal"},{oper:"ne",text:"not equal"},{oper:"lt",text:"less"},{oper:"le",text:"less or equal"},{oper:"gt",text:"greater"},{oper:"ge",text:"greater or equal"},{oper:"bw",text:"begins with"},{oper:"bn",text:"does not begin with"},{oper:"in",text:"is in"},{oper:"ni",text:"is not in"},{oper:"ew",text:"ends with"},{oper:"en",text:"does not end with"},{oper:"cn",text:"contains"},{oper:"nc",text:"does not contain"},{oper:"nu",text:"is null"},{oper:"nn",text:"is not null"}],groupOps:[{op:"AND",text:"all"},{op:"OR",text:"any"}],addGroupTitle:"Add subgroup",deleteGroupTitle:"Delete group",addRuleTitle:"Add rule",deleteRuleTitle:"Delete rule",operandTitle:"Click to select search operation.",resetTitle:"Reset Search Value"},edit:{addCaption:"Add Record",editCaption:"Edit Record",bSubmit:"Submit",bCancel:"Cancel",bClose:"Close",saveData:"Data has been changed! Save changes?",bYes:"Yes",bNo:"No",bExit:"Cancel",msg:{required:"Field is required",number:"Please, enter valid number",minValue:"value must be greater than or equal to ",maxValue:"value must be less than or equal to",email:"is not a valid e-mail",integer:"Please, enter valid integer value",date:"Please, enter valid date value",url:"is not a valid URL. Prefix required ('http://' or 'https://')",nodefined:" is not defined!",novalue:" return value is required!",customarray:"Custom function should return array!",customfcheck:"Custom function should be present in case of custom checking!"}},view:{caption:"View Record",bClose:"Close"},del:{caption:"Delete",msg:"Delete selected record(s)?",bSubmit:"Delete",bCancel:"Cancel"},nav:{edittext:"",edittitle:"Edit selected row",addtext:"",addtitle:"Add new row",deltext:"",deltitle:"Delete selected row",searchtext:"",searchtitle:"Find records",refreshtext:"",refreshtitle:"Reload Grid",alertcap:"Warning",alerttext:"Please, select row",viewtext:"",viewtitle:"View selected row",savetext:"",savetitle:"Save row",canceltext:"",canceltitle:"Cancel row editing"},col:{caption:"Select columns",bSubmit:"Ok",bCancel:"Cancel"},errors:{errcap:"Error",nourl:"No url is set",norecords:"No records to process",model:"Length of colNames <> colModel!"},formatter:{integer:{thousandsSeparator:",",defaultValue:"0"},number:{decimalSeparator:".",thousandsSeparator:",",decimalPlaces:2,defaultValue:"0.00"},currency:{decimalSeparator:".",thousandsSeparator:",",decimalPlaces:2,prefix:"",suffix:"",defaultValue:"0.00"},date:{dayNames:["Sun","Mon","Tue","Wed","Thr","Fri","Sat","Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],monthNames:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec","January","February","March","April","May","June","July","August","September","October","November","December"],AmPm:["am","pm","AM","PM"],S:function(t){return t<11||13").replace(/</g,"<").replace(/'/g,"'").replace(///g,"/").replace(/'/g,"'").replace(///g,"/").replace(/"/g,'"').replace(/&/g,"&"):t},htmlEncode:function(t){return t?String(t).replace(/&/g,"&").replace(/"/g,""").replace(/'/g,"'").replace(/\//g,"/").replace(//g,">"):t},oldEncodePostedData:function(t){return t?String(t).replace(/&/g,"&").replace(/"/g,""").replace(//g,">"):t},oldDecodePostedData:function(t){return t&&(" "===t||" "===t||1===t.length&&160===t.charCodeAt(0))?"":t?String(t).replace(/>/g,">").replace(/</g,"<").replace(/"/g,'"').replace(/&/g,"&"):t},clearArray:function(t){for(;0])*>/gi,""))&&" "!==t&&" "!==t?t.replace(/"/g,"'"):"":t},stripPref:function(t,e){var i=$.type(t);return"string"!==i&&"number"!==i||(e=""!==(t=String(t))?String(e).replace(String(t),""):e),e},getRes:function(t,e){var i,r=e.split("."),n=r.length;if(null!=t){for(i=0;i?@\[\\\]\^`{|}~]/g,"\\$&")},getGridComponentId:function(t){if(null==this.p||!this.p.id)return"";var e=this.p.id;switch(t){case COMPONENT_NAMES.GRID:return e;case COMPONENT_NAMES.GRID_BOX_DIV:return"gbox_"+e;case COMPONENT_NAMES.GRID_VIEW_DIV:return"gview_"+e;case COMPONENT_NAMES.DIALOG_ALERT_DIV:return"alertmod_"+e;case COMPONENT_NAMES.COLUMN_RESIZER_DIV:return"rs_m"+e;case COMPONENT_NAMES.HEADER_SELECT_ALL_ROWS_CHECKBOX:return"cb_"+e;case COMPONENT_NAMES.SEARCH_OPERATION_MENU_UL:return"sopt_menu";default:return""}},getGridComponentIdSelector:function(t){var e=jgrid.getGridComponentId.call(this,t);return e?"#"+jgrid.jqID(e):""},isHTMLElement:function(t){return"object"==typeof HTMLElement||"function"==typeof HTMLElement?t instanceof HTMLElement:null!=t&&"object"==typeof t&&1===t.nodeType&&"string"==typeof t.nodeName},getGridComponent:function(t,e){var i;if(e instanceof $||0
"),e=t.appendTo("body").find("td").width();return t.remove(),.1
"),i=e.appendTo("body").find("td").is(":hidden");return e.remove(),i},cell_width:!0,ajaxOptions:{},from:function(source){var context=this,QueryObject=function(d,q){var self=this,_data=d,_usecase=!0,_trim=!1,_query=q,_stripNum=/[\$,%]/g,_lastCommand=null,_lastField=null,_orDepth=0,_negate=!1,_queuedOperator="",_sorting=[],toString=Object.prototype.toString;if("object"!=typeof d||!d.push)throw"data provides is not an array";if(0",i)},this.less=function(t,e,i){return self._compareValues(self.less,t,e,"<",i)},this.greaterOrEquals=function(t,e,i){return self._compareValues(self.greaterOrEquals,t,e,">=",i)},this.lessOrEquals=function(t,e,i){return self._compareValues(self.lessOrEquals,t,e,"<=",i)},this.startsWith=function(t,e){var i=null==e?t:e,r=_trim?$.trim(i.toString()).length:i.toString().length;return self._append(self._getStr(t)+".substr(0,"+r+") == "+self._getStr('"'+self._toStr(e)+'"')),self._setCommand(self.startsWith,t),self._resetNegate(),self},this.endsWith=function(t,e){var i=null==e?t:e,r=_trim?$.trim(i.toString()).length:i.toString().length;return self._append(self._getStr(t)+".substr("+self._getStr(t)+".length-"+r+","+r+') == "'+self._toStr(e)+'"'),self._setCommand(self.endsWith,t),self._resetNegate(),self},this.contains=function(t,e){return self._append(self._getStr(t)+'.indexOf("'+self._toStr(e)+'",0) > -1'),self._setCommand(self.contains,t),self._resetNegate(),self},this.groupBy=function(t,e,i,r){return self._hasData()?self._getGroup(_data,t,e,i,r):null},this.orderBy=function(t,e,i,r,n){return null==i&&(i="text"),null==r&&(r="Y-m-d"),null==n&&(n=!1),"desc"!==(e=null==e?"a":$.trim(e.toString().toLowerCase()))&&"descending"!==e||(e="d"),"asc"!==e&&"ascending"!==e||(e="a"),_sorting.push({by:t,dir:e,type:i,datefmt:r,sfunc:n}),self},this.inSet=function(t,e,i){var r=void 0===e?null:e,n=void 0===i.stype?"text":i.stype;return r=self._getStr('"'+self._toStr(r)+'"'),"text"!==n?self._compareValues(self.equals,t,e,"==",i):(self._append("jQuery.inArray("+self._getStr(t)+","+r+".split('"+(context.p.inFilterSeparator||",")+"')) >= 0"),self._setCommand(self.inSet,t),self._resetNegate(),self)},this.custom=function(t,e,i){return self._append("self.p.customSortOperations."+t+'.filter.call(self,{item:this,cmName:"'+e+'",iCol:self.p.iColByName["'+e+'"]>=0 ? self.p.iColByName["'+e+'"] : self.p.iPropByName["'+e+'"],isAddProp:self.p.iColByName["'+e+'"]<0,searchValue:"'+i+'"})'),self._setCommand(self.custom,e),self._resetNegate(),self},self};return new QueryObject(source,null)},serializeFeedback:function(t,e,i){var r,n=this;return n instanceof $&&0