git.shiar.nl
/
sheet.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
cae266f
)
word edit: group reference input with category
author
Mischa POSLAWSKY
<perl@shiar.org>
Fri, 29 May 2020 05:12:47 +0000
(07:12 +0200)
committer
Mischa POSLAWSKY
<perl@shiar.org>
Sat, 6 Jun 2020 01:49:20 +0000
(
03:49
+0200)
writer.plp
patch
|
blob
|
history
diff --git
a/writer.plp
b/writer.plp
index 206333f137e04c33e67b777b31e98ffdb37aa329..bae010cf19aa89e20ec950652848b3293ee987af 100644
(file)
--- a/
writer.plp
+++ b/
writer.plp
@@
-102,14
+102,14
@@
my $db = eval {
my @wordcols = (
lang => 'Language',
cat => 'Category',
my @wordcols = (
lang => 'Language',
cat => 'Category',
+ ref => undef, # included with cat
+ prio => 'Level',
+ cover => undef, # included with prio
form => 'Translation',
alt => 'Synonyms',
wptitle => 'Wikipedia',
source => 'Image',
thumb => 'Convert options',
form => 'Translation',
alt => 'Synonyms',
wptitle => 'Wikipedia',
source => 'Image',
thumb => 'Convert options',
- prio => 'Level',
- cover => undef, # included with prio
- ref => 'Reference',
);
my @prioenum = qw( essential basic common distinctive rare invisible );
my ($find) = map {{id => $_}} $fields{id} || $Request || ();
);
my @prioenum = qw( essential basic common distinctive rare invisible );
my ($find) = map {{id => $_}} $fields{id} || $Request || ();
@@
-230,6
+230,9
@@
for my $colinfo (pairs @wordcols) {
printf '<input id="%s" name="%1$s" value="%s" />', $col, Entity($val);
-e and printf '<img src="/%s" alt="%s" />', $_, $row->{form}
for $col eq 'thumb' ? "data/word/eng/$row->{form}.jpg" : ();
printf '<input id="%s" name="%1$s" value="%s" />', $col, Entity($val);
-e and printf '<img src="/%s" alt="%s" />', $_, $row->{form}
for $col eq 'thumb' ? "data/word/eng/$row->{form}.jpg" : ();
+ printf('<label for="%s">%s</label><input id="%1$s" name="%1$s" value="%s" />',
+ 'ref', 'Reference', Entity($row->{ref})
+ ) if $col eq 'cat';
}
print '</span>';
-e and printf('<img id="%spreview" src="/%s" alt="%s" hidden />',
}
print '</span>';
-e and printf('<img id="%spreview" src="/%s" alt="%s" hidden />',