Use standard itemFormat for BBS list. Add docs

This commit is contained in:
Bryan Ashby 2018-11-05 21:08:56 -07:00
parent 8942eff203
commit a98940e967
3 changed files with 5 additions and 10 deletions

View file

@ -218,12 +218,7 @@ exports.getModule = class BBSListModule extends MenuModule {
}
setEntries(entriesView) {
const config = this.menuConfig.config;
const listFormat = config.listFormat || '{bbsName}';
const focusListFormat = config.focusListFormat || '{bbsName}';
entriesView.setItems(this.entries.map( e => stringFormat(listFormat, e) ) );
entriesView.setFocusItems(this.entries.map( e => stringFormat(focusListFormat, e) ) );
return entriesView.setItems(this.entries);
}
displayBBSList(clearScreen, cb) {
@ -277,6 +272,7 @@ exports.getModule = class BBSListModule extends MenuModule {
(err, row) => {
if (!err) {
self.entries.push({
text : row.bbs_name, // standard field
id : row.id,
bbsName : row.bbs_name,
sysOp : row.sysop,