Revision bbe298f0
Von Moritz Bunkus vor fast 8 Jahren hinzugefügt
SL/Controller/Draft.pm | ||
---|---|---|
131 | 131 |
sub draft_list { |
132 | 132 |
my ($self) = @_; |
133 | 133 |
|
134 |
my $result = selectall_hashref_query($::form, $::form->get_standard_dbh, <<SQL, $self->module, $self->submodule); |
|
135 |
SELECT d.*, date(d.itime) AS date, e.name AS employee_name
|
|
134 |
my $result = selectall_hashref_query($::form, $::form->get_standard_dbh, <<SQL, $self->module, $self->submodule, SL::DB::Manager::Employee->current->id);
|
|
135 |
SELECT d.*, date(d.itime) AS date |
|
136 | 136 |
FROM drafts d |
137 |
LEFT JOIN employee e ON d.employee_id = e.id |
|
138 |
WHERE (d.module = ?) AND (d.submodule = ?) |
|
137 |
WHERE (d.module = ?) |
|
138 |
AND (d.submodule = ?) |
|
139 |
AND (d.employee_id = ?) |
|
139 | 140 |
ORDER BY d.itime |
140 | 141 |
SQL |
141 | 142 |
} |
templates/webpages/drafts/form.html | ||
---|---|---|
24 | 24 |
<tr class="listheading"> |
25 | 25 |
<th>[% 'Date' | $T8 %]</th> |
26 | 26 |
<th>[% 'Description' | $T8 %]</th> |
27 |
<th>[% 'Employee' | $T8 %]</th> |
|
28 | 27 |
</tr> |
29 | 28 |
|
30 | 29 |
[% FOREACH row = drafts_list %] |
... | ... | |
37 | 36 |
[% L.link(SELF.url_for(action='load',id=row.id), row.description) %] |
38 | 37 |
[%- END %] |
39 | 38 |
</td> |
40 |
<td>[% row.employee_name | html %]</td> |
|
41 | 39 |
<td>[% L.html_tag('span', LxERP.t8('Delete'), class='cursor-pointer interact', onclick="kivi.Draft.delete('" _ row.id _ "')") %]</a></td> |
42 | 40 |
</tr> |
43 | 41 |
[% END %] |
44 | 42 |
</table> |
45 | 43 |
[%- END %] |
46 |
|
Auch abrufbar als: Unified diff
Entwürfe: nur die eigenen Entwürfe anzeigen