Improving oracles' import/export.
This commit is contained in:
parent
9f8556bfa3
commit
f5edec4708
@ -3,5 +3,5 @@ asTiddler
|
||||
^ Tiddler new
|
||||
title: self name;
|
||||
tags: 'Starforged';
|
||||
text: self intro, String lf, String lf, self optionsWikiTextTable;
|
||||
text: self introText, String cr, String cr, self optionsWikiTextTable;
|
||||
created: DateAndTime now asString.
|
@ -1,7 +1,7 @@
|
||||
accessing
|
||||
fromDictionary: aDictionary
|
||||
| optionsTable |
|
||||
name := aDictionary at: 'Name'.
|
||||
name := aDictionary at: 'Name' ifAbsent: [ name := aDictionary at: 'Display name' ].
|
||||
optionsTable := aDictionary at: 'Table'.
|
||||
optionsTable doWithIndex: [:opt :i | | key value prevKey |
|
||||
(i = 1)
|
||||
|
3
RoloLudo.package/SfOracle.class/instance/introText.st
Normal file
3
RoloLudo.package/SfOracle.class/instance/introText.st
Normal file
@ -0,0 +1,3 @@
|
||||
accessing
|
||||
introText
|
||||
^ self intro ifNil: [ ^ '' ]
|
@ -2,9 +2,10 @@ accessing
|
||||
optionsWikiTextTable
|
||||
| output |
|
||||
output := '' writeStream.
|
||||
self options keysAndValuesDo: [:k :v |
|
||||
self options keysAndValuesDo: [:k :v | | keyString |
|
||||
keyString := ((k size = 1) ifTrue: [ k first asString ] ifFalse: [ k first asString, ' - ', k last asString ]).
|
||||
output
|
||||
nextPutAll: '| ', k first asString, ' - ', k last asString, ' |';
|
||||
nextPutAll: '| ',keyString , ' |';
|
||||
nextPutAll: v, ' |'; cr
|
||||
].
|
||||
^ output contents
|
Loading…
Reference in New Issue
Block a user