Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision 0a7acc87

Von Niclas Zimmermann vor mehr als 11 Jahren hinzugefügt

  • ID 0a7acc87a3c4c016b324795c4c777643ee1517fc
  • Vorgänger e04c32d3
  • Nachfolger 253a9323

Trailing Whitespaces entfernen

Dieser Commit entfernt lediglich Leerzeichen am Ende der Zeilen.

Unterschiede anzeigen:

SL/AP.pm
241 241
    $query =
242 242
      qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, taxkey, tax_id, chart_link) | .
243 243
      qq|VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, | .
244
      qq|        (SELECT taxkey_id FROM chart WHERE accno = ?),| . 
245
      qq|        (SELECT tax_id| . 
246
      qq|         FROM taxkeys| . 
247
      qq|         WHERE chart_id= (SELECT id | . 
248
      qq|                          FROM chart| . 
249
      qq|                          WHERE accno = ?)| . 
250
      qq|         AND startdate <= ?| . 
244
      qq|        (SELECT taxkey_id FROM chart WHERE accno = ?),| .
245
      qq|        (SELECT tax_id| .
246
      qq|         FROM taxkeys| .
247
      qq|         WHERE chart_id= (SELECT id | .
248
      qq|                          FROM chart| .
249
      qq|                          WHERE accno = ?)| .
250
      qq|         AND startdate <= ?| .
251 251
      qq|         ORDER BY startdate DESC LIMIT 1),| .
252 252
      qq|        (SELECT c.link FROM chart c WHERE c.accno = ?))|;
253 253
    @values = ($form->{id}, $form->{AP_amounts}{payables}, $form->{payables},
......
299 299
          qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, project_id, taxkey, tax_id, chart_link) | .
300 300
          qq|VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, ?, | .
301 301
          qq|        (SELECT taxkey_id FROM chart WHERE accno = ?),| .
302
          qq|        (SELECT tax_id| . 
303
          qq|         FROM taxkeys| . 
304
          qq|         WHERE chart_id= (SELECT id | . 
305
          qq|                          FROM chart| . 
306
          qq|                          WHERE accno = ?)| . 
307
          qq|         AND startdate <= ?| . 
302
          qq|        (SELECT tax_id| .
303
          qq|         FROM taxkeys| .
304
          qq|         WHERE chart_id= (SELECT id | .
305
          qq|                          FROM chart| .
306
          qq|                          WHERE accno = ?)| .
307
          qq|         AND startdate <= ?| .
308 308
          qq|         ORDER BY startdate DESC LIMIT 1),| .
309 309
          qq|        (SELECT c.link FROM chart c WHERE c.accno = ?))|;
310 310
        @values = ($form->{id}, $form->{AP_payables}, $amount,
......
320 320
      $query =
321 321
        qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, gldate, source, memo, project_id, taxkey, tax_id, chart_link) | .
322 322
        qq|VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, ?, ?, ?, ?, | .
323
        qq|        (SELECT taxkey_id FROM chart WHERE accno = ?), | . 
323
        qq|        (SELECT taxkey_id FROM chart WHERE accno = ?), | .
324 324
        qq|        (SELECT tax_id| .
325
        qq|         FROM taxkeys| . 
326
        qq|         WHERE chart_id= (SELECT id | . 
327
        qq|                          FROM chart| . 
328
        qq|                          WHERE accno = ?)| . 
329
        qq|         AND startdate <= ?| . 
325
        qq|         FROM taxkeys| .
326
        qq|         WHERE chart_id= (SELECT id | .
327
        qq|                          FROM chart| .
328
        qq|                          WHERE accno = ?)| .
329
        qq|         AND startdate <= ?| .
330 330
        qq|         ORDER BY startdate DESC LIMIT 1),| .
331 331
        qq|        (SELECT c.link FROM chart c WHERE c.accno = ?))|;
332 332
      @values = ($form->{id}, $form->{"AP_paid_account_$i"}, $form->{"paid_$i"},
......
345 345
          qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, fx_transaction, cleared, project_id, taxkey, tax_id, chart_link) | .
346 346
          qq|VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, 't', 'f', ?, | .
347 347
          qq|        (SELECT taxkey_id FROM chart WHERE accno = ?), | .
348
          qq|        (SELECT tax_id| . 
349
          qq|         FROM taxkeys| . 
350
          qq|         WHERE chart_id= (SELECT id | . 
351
          qq|                          FROM chart| . 
352
          qq|                          WHERE accno = ?)| . 
353
          qq|         AND startdate <= ?| . 
348
          qq|        (SELECT tax_id| .
349
          qq|         FROM taxkeys| .
350
          qq|         WHERE chart_id= (SELECT id | .
351
          qq|                          FROM chart| .
352
          qq|                          WHERE accno = ?)| .
353
          qq|         AND startdate <= ?| .
354 354
          qq|         ORDER BY startdate DESC LIMIT 1),| .
355 355
          qq|        (SELECT c.link FROM chart c WHERE c.accno = ?))|;
356 356
        @values = ($form->{id}, $form->{"AP_paid_account_$i"}, $amount,
......
372 372
          qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, fx_transaction, cleared, project_id, taxkey, tax_id, chart_link) | .
373 373
          qq|VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, 't', 'f', ?, | .
374 374
          qq|        (SELECT taxkey_id FROM chart WHERE accno = ?)| .
375
          qq|        (SELECT tax_id| . 
376
          qq|         FROM taxkeys| . 
377
          qq|         WHERE chart_id= (SELECT id | . 
378
          qq|                          FROM chart| . 
379
          qq|                          WHERE accno = ?)| . 
380
          qq|         AND startdate <= ?| . 
375
          qq|        (SELECT tax_id| .
376
          qq|         FROM taxkeys| .
377
          qq|         WHERE chart_id= (SELECT id | .
378
          qq|                          FROM chart| .
379
          qq|                          WHERE accno = ?)| .
380
          qq|         AND startdate <= ?| .
381 381
          qq|         ORDER BY startdate DESC LIMIT 1),| .
382 382
          qq|        (SELECT c.link FROM chart c WHERE c.accno = ?))|;
383
        @values = ($form->{id}, 
383
        @values = ($form->{id},
384 384
                   ($amount > 0) ? $form->{fxgain_accno} : $form->{fxloss_accno},
385 385
                   $amount, conv_date($form->{"datepaid_$i"}), $project_id,
386 386
                   ($amount > 0) ? $form->{fxgain_accno} : $form->{fxloss_accno},
SL/AR.pm
192 192
    # add recievables
193 193
    $query = qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, taxkey, tax_id, chart_link)
194 194
                 VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, (SELECT taxkey_id FROM chart WHERE accno = ?),
195
                 (SELECT tax_id 
196
                  FROM taxkeys 
197
                  WHERE chart_id= (SELECT id  
198
                                   FROM chart 
199
                                   WHERE accno = ?) 
200
                  AND startdate <= ? 
195
                 (SELECT tax_id
196
                  FROM taxkeys
197
                  WHERE chart_id= (SELECT id
198
                                   FROM chart
199
                                   WHERE accno = ?)
200
                  AND startdate <= ?
201 201
                  ORDER BY startdate DESC LIMIT 1),
202 202
                 (SELECT c.link FROM chart c WHERE c.accno = ?))|;
203 203
    @values = (conv_i($form->{id}), $form->{AR_amounts}{receivables}, conv_i($form->{receivables}), conv_date($form->{transdate}),
......
240 240
        # add receivable
241 241
        $query = qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, project_id, taxkey, tax_id, chart_link)
242 242
                     VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, ?, (SELECT taxkey_id FROM chart WHERE accno = ?),
243
                     (SELECT tax_id 
244
                      FROM taxkeys 
245
                      WHERE chart_id= (SELECT id 
246
                                       FROM chart 
247
                                       WHERE accno = ?) 
248
                      AND startdate <= ? 
243
                     (SELECT tax_id
244
                      FROM taxkeys
245
                      WHERE chart_id= (SELECT id
246
                                       FROM chart
247
                                       WHERE accno = ?)
248
                      AND startdate <= ?
249 249
                      ORDER BY startdate DESC LIMIT 1),
250 250
                     (SELECT c.link FROM chart c WHERE c.accno = ?))|;
251 251
        @values = (conv_i($form->{id}), $form->{AR}{receivables}, $amount, conv_date($form->{"datepaid_$i"}), $project_id, $form->{AR}{receivables}, $form->{AR}{receivables}, conv_date($form->{"datepaid_$i"}),
......
261 261
        $amount = $form->{"paid_$i"} * -1;
262 262
        $query  = qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, gldate, source, memo, project_id, taxkey, tax_id, chart_link)
263 263
                     VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, ?, ?, ?, ?, (SELECT taxkey_id FROM chart WHERE accno = ?),
264
                     (SELECT tax_id 
265
                      FROM taxkeys 
266
                      WHERE chart_id= (SELECT id 
267
                                       FROM chart 
268
                                       WHERE accno = ?) 
269
                      AND startdate <= ? 
264
                     (SELECT tax_id
265
                      FROM taxkeys
266
                      WHERE chart_id= (SELECT id
267
                                       FROM chart
268
                                       WHERE accno = ?)
269
                      AND startdate <= ?
270 270
                      ORDER BY startdate DESC LIMIT 1),
271 271
                     (SELECT c.link FROM chart c WHERE c.accno = ?))|;
272 272
        @values = (conv_i($form->{id}), $form->{AR}{"paid_$i"}, $amount, conv_date($form->{"datepaid_$i"}), $gldate, $form->{"source_$i"}, $form->{"memo_$i"}, $project_id, $form->{AR}{"paid_$i"},
......
279 279
        if ($amount != 0) {
280 280
          $query = qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, fx_transaction, cleared, project_id, taxkey, tax_id, chart_link)
281 281
                       VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, 't', 'f', ?, (SELECT taxkey_id FROM chart WHERE accno = ?),
282
                       (SELECT tax_id 
283
                        FROM taxkeys 
284
                        WHERE chart_id= (SELECT id  
285
                                         FROM chart 
286
                                         WHERE accno = ?) 
287
                        AND startdate <= ? 
282
                       (SELECT tax_id
283
                        FROM taxkeys
284
                        WHERE chart_id= (SELECT id
285
                                         FROM chart
286
                                         WHERE accno = ?)
287
                        AND startdate <= ?
288 288
                        ORDER BY startdate DESC LIMIT 1),
289 289
                       (SELECT c.link FROM chart c WHERE c.accno = ?))|;
290 290
          @values = (conv_i($form->{id}), $form->{AR}{"paid_$i"}, $amount, conv_date($form->{"datepaid_$i"}), $project_id, $form->{AR}{"paid_$i"},
......
299 299
          my $accno = ($amount > 0) ? $form->{fxgain_accno} : $form->{fxloss_accno};
300 300
          $query = qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate, fx_transaction, cleared, project_id, taxkey, tax_id, chart_link)
301 301
                       VALUES (?, (SELECT id FROM chart WHERE accno = ?), ?, ?, 't', 'f', ?, (SELECT taxkey_id FROM chart WHERE accno = ?),
302
                       (SELECT tax_id 
303
                        FROM taxkeys 
304
                        WHERE chart_id= (SELECT id  
305
                                         FROM chart 
306
                                         WHERE accno = ?) 
307
                        AND startdate <= ? 
302
                       (SELECT tax_id
303
                        FROM taxkeys
304
                        WHERE chart_id= (SELECT id
305
                                         FROM chart
306
                                         WHERE accno = ?)
307
                        AND startdate <= ?
308 308
                        ORDER BY startdate DESC LIMIT 1),
309 309
                       (SELECT c.link FROM chart c WHERE c.accno = ?))|;
310 310
          @values = (conv_i($form->{id}), $accno, $amount, conv_date($form->{"datepaid_$i"}), $project_id, $accno, $accno, conv_date($form->{"datepaid_$i"}), $accno);
SL/GL.pm
171 171
        qq|INSERT INTO acc_trans (trans_id, chart_id, amount, transdate,
172 172
                                  source, memo, project_id, taxkey, tax_id, chart_link)
173 173
           VALUES (?, (SELECT chart_id FROM tax WHERE id = ?),
174
                   ?, ?, ?, ?, ?, ?, ?, (SELECT link 
175
                                         FROM chart 
176
                                         WHERE id = (SELECT chart_id 
177
                                                     FROM tax 
174
                   ?, ?, ?, ?, ?, ?, ?, (SELECT link
175
                                         FROM chart
176
                                         WHERE id = (SELECT chart_id
177
                                                     FROM tax
178 178
                                                     WHERE id = ?)))|;
179 179
      @values = (conv_i($form->{id}), conv_i($form->{"tax_id_$i"}),
180 180
                 $tax, conv_date($form->{transdate}), $form->{"source_$i"},
SL/IR.pm
1221 1221

  
1222 1222
  my $transdate = "";
1223 1223
  if ($form->{type} eq "invoice") {
1224
    $transdate = $form->{deliverydate} ? $dbh->quote($form->{deliverydate}) 
1225
               : $form->{invdate} ? $dbh->quote($form->{invdate}) 
1224
    $transdate = $form->{deliverydate} ? $dbh->quote($form->{deliverydate})
1225
               : $form->{invdate} ? $dbh->quote($form->{invdate})
1226 1226
               : "current_date";
1227 1227
  } else {
1228 1228
    $transdate = $form->{transdate} ? $dbh->quote($form->{transdate}) : "current_date";

Auch abrufbar als: Unified diff