diff options
Diffstat (limited to 'bugzillaBugTriage.js')
-rw-r--r-- | bugzillaBugTriage.js | 69 |
1 files changed, 31 insertions, 38 deletions
diff --git a/bugzillaBugTriage.js b/bugzillaBugTriage.js index a62c630..7f93ca8 100644 --- a/bugzillaBugTriage.js +++ b/bugzillaBugTriage.js @@ -480,12 +480,6 @@ Color.prototype.lightColor = function() { //==================================================================================== // BzPage's methods -BzPage.prototype.getLogTime = function() { - // FIXME to be implemented - var today = new Date(); - return today.toDateString(); -} - /** * Check for the presence of a keyword * @@ -863,34 +857,6 @@ BzPage.prototype.setBranding = function () { }; /** - */ -BzPage.prototype.groupIDs = function (manStr,cardStrID) { - var outStr = filterByRegexp(chipIDsGroupings,manStr+","+cardStrID); - if (outStr.length === 0) { - outStr = "UNGROUPED_" + manStr+"/"+cardStrID; - } - return outStr; -}; - -/** - * Given PCI IDs for manufacturer and card ID return chipset string - * - * @param manufacturerNo string with manufacturer PCI ID - * @param cardNo string with card PCI ID - * - * @return array with chip string and optinoal variants - */ -BzPage.prototype.checkChipStringFromID = function (manufacturerNo,cardNo) { - var soughtID = (manufacturerNo+","+cardNo).toUpperCase(); - var outList = PCI_ID_Array[soughtID]; - if (outList) { - return outList; - } else { - return ""; - } -}; - -/** * Given line to be parsed, find out which chipset it is and fill in the whiteboard * * @param iLine string with the whole unparsed "interesting line" @@ -898,6 +864,32 @@ BzPage.prototype.checkChipStringFromID = function (manufacturerNo,cardNo) { * @return None */ BzPage.prototype.fillInWhiteBoard = function (iLine, driverStr) { + function groupIDs (manStr,cardStrID) { + var outStr = filterByRegexp(chipIDsGroupings,manStr+","+cardStrID); + if (outStr.length === 0) { + outStr = "UNGROUPED_" + manStr+"/"+cardStrID; + } + return outStr; + }; + + /** + * Given PCI IDs for manufacturer and card ID return chipset string + * + * @param manufacturerNo string with manufacturer PCI ID + * @param cardNo string with card PCI ID + * + * @return array with chip string and optinoal variants + */ + function checkChipStringFromID (manufacturerNo,cardNo) { + var soughtID = (manufacturerNo+","+cardNo).toUpperCase(); + var outList = PCI_ID_Array[soughtID]; + if (outList) { + return outList; + } else { + return ""; + } + }; + var outStr = ""; var cardIDStr = ""; var cardIDArr = []; @@ -905,14 +897,14 @@ BzPage.prototype.fillInWhiteBoard = function (iLine, driverStr) { chipSwitchboard: if (driverStr === "RADEON") { var cardID = iLine.replace(ATIgetIDRE,"$1"); - cardIDArr = this.checkChipStringFromID("1002",cardID); + cardIDArr = checkChipStringFromID("1002",cardID); if (cardIDArr.length > 0) { cardIDStr = cardIDArr[0]; if (cardIDArr[1]) { optionStr = cardIDArr[1]; - outStr = this.groupIDs(driverStr,cardIDStr)+"/" + optionStr; + outStr = groupIDs(driverStr,cardIDStr)+"/" + optionStr; } else { - outStr = this.groupIDs(driverStr,cardIDStr); + outStr = groupIDs(driverStr,cardIDStr); optionStr = ""; } } else { @@ -933,7 +925,7 @@ BzPage.prototype.fillInWhiteBoard = function (iLine, driverStr) { iLine = iLine.replace(new RegExp(cardIDArr[0],"i")).trim(); // nVidia developers opted-out from grouping if (driverStr === "INTEL") { - outStr = this.groupIDs(cardIDArr[1],iLine); + outStr = groupIDs(cardIDArr[1],iLine); } else { outStr = iLine; } @@ -1907,6 +1899,7 @@ function BzPage(doc) { false); // logging all submits for timesheet + console.log("logSubmits = " + logSubmits); if (logSubmits) { this.dok.forms.namedItem("changeform").addEventListener("submit", function () {that.addLogRecord();} |