Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 32e816b5

Von Bernd Bleßmann vor mehr als 9 Jahren hinzugefügt

  • ID 32e816b5faa06c33f4927271b04d29a92bb943d3
  • Vorgänger d93709bd
  • Nachfolger e30fbb34

Preisgruppe bei Stammdaten->Berichte->Kunden anzeigen lassen können.

Conflicts:

SL/CT.pm
bin/mozilla/ct.pl

Unterschiede anzeigen:

SL/CT.pm
78 78
      "discount"           => "ct.discount",
79 79
      "insertdate"         => "ct.itime",
80 80
      "salesman"           => "e.name",
81
      "payment"            => "pt.description"
81
      "payment"            => "pt.description",
82
      "pricegroup"         => "pg.pricegroup",
82 83
    );
83 84

  
84 85
  $form->{sort} ||= "name";
......
213 214
    push @values, $form->{addr_zipcode} . '%';
214 215
  }
215 216

  
217
  my $pg_select = $form->{l_pricegroup} ? qq|, pg.pricegroup as pricegroup | : '';
218
  my $pg_join   = $form->{l_pricegroup} ? qq|LEFT JOIN pricegroup pg ON (ct.klass = pg.id) | : '';
216 219
  my $query =
217 220
    qq|SELECT ct.*, ct.itime::DATE AS insertdate, b.description AS business, e.name as salesman, | .
218 221
    qq|  pt.description as payment | .
222
    $pg_select .
219 223
    (qq|, NULL AS invnumber, NULL AS ordnumber, NULL AS quonumber, NULL AS invid, NULL AS module, NULL AS formtype, NULL AS closed | x!! $join_records) .
220 224
    qq|FROM $cv ct | .
221 225
    qq|LEFT JOIN business b ON (ct.business_id = b.id) | .
222 226
    qq|LEFT JOIN employee e ON (ct.salesman_id = e.id) | .
223 227
    qq|LEFT JOIN payment_terms pt ON (ct.payment_id = pt.id) | .
228
    $pg_join .
224 229
    qq|WHERE $where|;
225 230

  
226 231
  my @saved_values = @values;
bin/mozilla/ct.pl
170 170
    'id',        'name',    "$form->{db}number",   'contact',   'phone',    'discount',
171 171
    'fax',       'email',   'taxnumber',           'street',    'zipcode' , 'city',
172 172
    'business',  'payment', 'invnumber', 'ordnumber',           'quonumber', 'salesman',
173
    'country',   'insertdate'
173
    'country',   'insertdate',           'pricegroup'
174 174
  );
175 175

  
176 176
  my @includeable_custom_variables = grep { $_->{includeable} } @{ $cvar_configs };
......
201 201
    'discount'          => { 'text' => $locale->text('Discount'), },
202 202
    'payment'           => { 'text' => $locale->text('Payment Terms'), },
203 203
    'insertdate'        => { 'text' => $locale->text('Insert Date'), },
204
    'pricegroup'        => { 'text' => $locale->text('Pricegroup'), },
204 205
    %column_defs_cvars,
205 206
  );
206 207

  
templates/webpages/ct/search.html
192 192
       <input name="l_salesman" id="l_salesman" type="checkbox" class="checkbox" value="Y">
193 193
       <label for="l_salesman">[% 'Salesman' | $T8 %]</label>
194 194
      </td>
195
      </tr>
196
      <tr>
197
      <td>
198
       <input name="l_pricegroup" id="l_pricegroup" type="checkbox" class="checkbox" value="Y">
199
       <label for="l_pricegroup">[% 'Pricegroup' | $T8 %]</label>
200
      </td>
195 201
      [% END %]
196 202
      </tr>
197 203

  

Auch abrufbar als: Unified diff