* Use itemFormat/focusItemFormat for set newscan message/file conf/areas
* Docs for set_newscan_date module
This commit is contained in:
parent
b34294fbef
commit
370f8039db
Binary file not shown.
|
@ -254,6 +254,16 @@
|
|||
}
|
||||
}
|
||||
|
||||
messageAreaSetNewScanDate: {
|
||||
mci: {
|
||||
SM2: {
|
||||
width: 54
|
||||
itemFormat: "|00|07{conf.name} |08- |07{area.name}"
|
||||
focusItemFormat: "|00|15{conf.name} |07- |15{area.name}"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
mailMenuCreateMessage: {
|
||||
0: {
|
||||
mci: {
|
||||
|
|
|
@ -153,11 +153,13 @@ exports.getModule = class SetNewScanDate extends MenuModule {
|
|||
selections.push({
|
||||
conf : {
|
||||
confTag : conf.confTag,
|
||||
text : conf.conf.name, // standard
|
||||
name : conf.conf.name,
|
||||
desc : conf.conf.desc,
|
||||
},
|
||||
area : {
|
||||
areaTag : area.areaTag,
|
||||
text : area.area.name, // standard
|
||||
name : area.area.name,
|
||||
desc : area.area.desc,
|
||||
}
|
||||
|
@ -168,11 +170,13 @@ exports.getModule = class SetNewScanDate extends MenuModule {
|
|||
selections.unshift({
|
||||
conf : {
|
||||
confTag : '',
|
||||
text : 'All conferences',
|
||||
name : 'All conferences',
|
||||
desc : 'All conferences',
|
||||
},
|
||||
area : {
|
||||
areaTag : '',
|
||||
text : 'All areas',
|
||||
name : 'All areas',
|
||||
desc : 'All areas',
|
||||
}
|
||||
|
@ -236,14 +240,9 @@ exports.getModule = class SetNewScanDate extends MenuModule {
|
|||
scanDateView.setText(today.format(scanDateFormat));
|
||||
|
||||
if('message' === self.target) {
|
||||
const messageSelectionsFormat = self.menuConfig.config.messageSelectionsFormat || '{conf.name} - {area.name}';
|
||||
const messageSelectionFocusFormat = self.menuConfig.config.messageSelectionFocusFormat || messageSelectionsFormat;
|
||||
|
||||
const targetSelectionView = vc.getView(MciViewIds.main.targetSelection);
|
||||
|
||||
targetSelectionView.setItems(self.targetSelections.map(targetSelection => stringFormat(messageSelectionFocusFormat, targetSelection)));
|
||||
targetSelectionView.setFocusItems(self.targetSelections.map(targetSelection => stringFormat(messageSelectionFocusFormat, targetSelection)));
|
||||
|
||||
targetSelectionView.setItems(self.targetSelections);
|
||||
targetSelectionView.setFocusItemIndex(0);
|
||||
}
|
||||
|
||||
|
|
|
@ -76,6 +76,7 @@
|
|||
- [Show Art]({{ site.baseurl }}{% link modding/show-art.md %})
|
||||
- [Download Manager]({{ site.baseurl }}{% link modding/file-base-download-manager.md %})
|
||||
- [Web Download Manager]({{ site.baseurl }}{% link modding/file-base-web-download-manager.md %})
|
||||
- [Set Newscan Date]({{ site.baseurl }}{% link modding/set-newscan-date.md %})
|
||||
|
||||
- Administration
|
||||
- [oputil]({{ site.baseurl }}{% link admin/oputil.md %})
|
||||
|
|
|
@ -19,5 +19,5 @@ The following `itemFormat` object is provided to MCI 1 (ie: `%VM1`) and MCI 10+
|
|||
* `fileName`: Entry filename.
|
||||
* `path`: Full file path.
|
||||
* `byteSize`: Size in bytes of file.
|
||||
* `webDlLink`: Web download link including VTX style ANSI ESC sequences.
|
||||
* `webDlLink`: Web download link including [VTX style ANSI ESC sequences](https://raw.githubusercontent.com/codewar65/VTX_ClientServer/master/vtx.txt).
|
||||
* `webDlExpire`: Expiration date/time for this link. Formatted using `webDlExpireTimeFormat`.
|
|
@ -21,6 +21,6 @@ The following `itemFormat` object is provided to MCI 1 (ie: `%VM1`) and custom r
|
|||
* `path`: Full file path.
|
||||
* `byteSize`: Size in bytes of file.
|
||||
* `webDlLinkRaw`: Web download link.
|
||||
* `webDlLink`: Web download link including VTX style ANSI ESC sequences.
|
||||
* `webDlLink`: Web download link including [VTX style ANSI ESC sequences](https://raw.githubusercontent.com/codewar65/VTX_ClientServer/master/vtx.txt).
|
||||
* `webDlExpire`: Expiration date/time for this link. Formatted using `webDlExpireTimeFormat`.
|
||||
|
||||
|
|
|
@ -0,0 +1,29 @@
|
|||
---
|
||||
layout: page
|
||||
title: Set Newscan Date Module
|
||||
---
|
||||
## Set Newscan Date Module
|
||||
The `set_newscan_date` module allows setting newscan dates (aka pointers) for message conferences and areas as well as within the file base. Users can select specific conferences/areas or all (where applicable).
|
||||
|
||||
## Configuration
|
||||
### Configuration Block
|
||||
Available `config` block entries are as follows:
|
||||
* `target`: Choose from `message` for message conferences & areas, or `file` for file base areas.
|
||||
* `scanDateFormat`: Format for scan date. This format must align with the **output** of the MaskEditView (`%ME1`) MCI utilized for input. Defaults to `YYYYMMDD` (which matches mask of `####/##/##`).
|
||||
|
||||
### Theming
|
||||
#### Message Conference & Areas
|
||||
When `target` is `message`, the following `itemFormat` object is provided to MCI 2 (ie: `%SM2`):
|
||||
* `conf`: An object containing:
|
||||
* `confTag`: Conference tag.
|
||||
* `name`: Conference name. Also available in `{text}`.
|
||||
* `desc`: Conference description.
|
||||
* `area`: An object containing:
|
||||
* `areaTag`: Area tag.
|
||||
* `name`: Area name. Also available in `{text}`.
|
||||
* `desc`: Area description.
|
||||
|
||||
When dealing with the file base, ENiGMA½ does not currently have the ability to set newscan dates for specific areas. No `%SM2` is used in this case.
|
||||
|
||||
### Submit Actions
|
||||
Submit action should map to `@method:scanDateSubmit` and provide `scanDate` in form data. For message conf/areas (`target` of `message`), `targetSelection` should be also be provided in form data: An index to the selected conf/area.
|
|
@ -1921,7 +1921,6 @@
|
|||
SM2: {
|
||||
argName: targetSelection
|
||||
submit: false
|
||||
justify: right
|
||||
}
|
||||
}
|
||||
submit: {
|
||||
|
|
Loading…
Reference in New Issue