Projekt

Allgemein

Profil

« Zurück | Weiter » 

Revision c3db1b36

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

  • ID c3db1b36f46f3bb8fe278ad3320bc7b139278dc3
  • Vorgänger f825d995
  • Nachfolger 9aa58dc1

Auftrags-Controller: weitere Links hierhin bei experimentellen Features

Unterschiede anzeigen:

SL/Controller/DeliveryPlan.pm
369 369
    my $vc     = $object->is_sales ? 'customer' : 'vendor';
370 370
    my $id     = $object->id;
371 371

  
372
    return "oe.pl?action=$action&type=$type&vc=$vc&id=$id";
372
    if ($::instance_conf->get_feature_experimental) {
373
      return "controller.pl?action=Order/$action&type=$type&id=$id";
374
    } else {
375
      return "oe.pl?action=$action&type=$type&vc=$vc&id=$id";
376
    }
373 377
  }
374 378
  if ($object->isa('SL::DB::Part')) {
375 379
    my $id     = $object->id;
SL/Controller/DeliveryValueReport.pm
231 231
    my $vc     = $object->is_sales ? 'customer' : 'vendor';
232 232
    my $id     = $object->id;
233 233

  
234
    return "oe.pl?action=$action&type=$type&vc=$vc&id=$id";
234
    if ($::instance_conf->get_feature_experimental) {
235
      return "controller.pl?action=Order/$action&type=$type&id=$id";
236
    } else {
237
      return "oe.pl?action=$action&type=$type&vc=$vc&id=$id";
238
    }
235 239
  }
236 240
  if ($object->isa('SL::DB::Part')) {
237 241
    my $id     = $object->id;
SL/Controller/FinancialControllingReport.pm
278 278
    my $type = $object->type;
279 279
    my $id   = $object->id;
280 280

  
281
    return "oe.pl?action=$action&type=$type&vc=customer&id=$id";
281
    if ($::instance_conf->get_feature_experimental) {
282
      return "controller.pl?action=Order/$action&type=$type&id=$id";
283
    } else {
284
      return "oe.pl?action=$action&type=$type&vc=customer&id=$id";
285
    }
282 286
  }
283 287
  if ($object->isa('SL::DB::Customer')) {
284 288
    my $id     = $object->id;
SL/Controller/SellPriceInformation.pm
140 140
    my $vc     = $object->is_sales ? 'customer' : 'vendor';
141 141
    my $id     = $object->id;
142 142

  
143
    return "oe.pl?action=$action&type=$type&vc=$vc&id=$id";
143
    if ($::instance_conf->get_feature_experimental) {
144
      return "controller.pl?action=Order/$action&type=$type&id=$id";
145
    } else {
146
      return "oe.pl?action=$action&type=$type&vc=$vc&id=$id";
147
    }
144 148
  }
145 149
  if ($object->isa('SL::DB::Customer')) {
146 150
    my $id     = $object->id;
SL/Controller/ShopOrder.pm
156 156
      $self->shop_order->save;
157 157
      $self->shop_order->link_to_record($order);
158 158
    }) || die $order->db->error;
159
    $self->redirect_to(controller => "oe.pl", action => 'edit', type => 'sales_order', vc => 'customer', id => $order->id);
159
    my $order_controller = $::instance_conf->get_feature_experimental ? 'Order' :'oe.pl';
160
    $self->redirect_to(controller => $order_controller, action => 'edit', type => 'sales_order', vc => 'customer', id => $order->id);
160 161
  }
161 162
}
162 163

  
SL/Controller/TopQuickSearch/OERecord.pm
64 64
}
65 65

  
66 66
sub redirect_to_object {
67
  SL::Controller::Base->new->url_for(
68
    controller => 'oe.pl',
69
    action     => 'edit',
70
    type       => $_[0]->type,
71
    vc         => $_[0]->vc,
72
    id         => $_[1],
73
  );
67
  if ($::instance_conf->get_feature_experimental) {
68
    SL::Controller::Base->new->url_for(
69
      controller => 'Order',
70
      action     => 'edit',
71
      type       => $_[0]->type,
72
      id         => $_[1],
73
    );
74
  } else {
75
    SL::Controller::Base->new->url_for(
76
      controller => 'oe.pl',
77
      action     => 'edit',
78
      type       => $_[0]->type,
79
      vc         => $_[0]->vc,
80
      id         => $_[1],
81
    );
82
  }
74 83
}
75 84

  
76 85
sub type {
SL/FU.pm
336 336
    };
337 337

  
338 338
  } elsif ($params{trans_type} eq 'sales_quotation') {
339
    my $script = 'oe.pl';
340
    my $action = 'edit';
341
    if ($::instance_conf->get_feature_experimental) {
342
      $script = 'controller.pl';
343
      $action = 'Order/edit';
344
    }
339 345
    $link = {
340
      'url'   => 'oe.pl?action=edit&type=sales_quotation&id=' . $params{trans_id},
346
      'url'   => $script . '?action=' . $action . '&type=sales_quotation&id=' . $params{trans_id},
341 347
      'title' => $locale->text('Sales quotation') . " $params{trans_info}",
342 348
    };
343 349

  
......
356 362
    };
357 363

  
358 364
  } elsif ($params{trans_type} eq 'sales_order') {
365
    my $script = 'oe.pl';
366
    my $action = 'edit';
367
    if ($::instance_conf->get_feature_experimental) {
368
      $script = 'controller.pl';
369
      $action = 'Order/edit';
370
    }
359 371
    $link = {
360
      'url'   => 'oe.pl?action=edit&type=sales_order&id=' . $params{trans_id},
372
      'url'   => $script . '?action=' . $action . '&type=sales_order&id=' . $params{trans_id},
361 373
      'title' => $locale->text('Sales Order') . " $params{trans_info}",
362 374
    };
363 375

  
......
386 398
    };
387 399

  
388 400
  } elsif ($params{trans_type} eq 'request_quotation') {
401
    my $script = 'oe.pl';
402
    my $action = 'edit';
403
    if ($::instance_conf->get_feature_experimental) {
404
      $script = 'controller.pl';
405
      $action = 'Order/edit';
406
    }
389 407
    $link = {
390
      'url'   => 'oe.pl?action=edit&type=request_quotation&id=' . $params{trans_id},
408
      'url'   => $script . '?action=' . $action . '&type=request_quotation&id=' . $params{trans_id},
391 409
      'title' => $locale->text('Request quotation') . " $params{trans_info}",
392 410
    };
393 411

  
394 412
  } elsif ($params{trans_type} eq 'purchase_order') {
413
    my $script = 'oe.pl';
414
    my $action = 'edit';
415
    if ($::instance_conf->get_feature_experimental) {
416
      $script = 'controller.pl';
417
      $action = 'Order/edit';
418
    }
395 419
    $link = {
396
      'url'   => 'oe.pl?action=edit&type=purchase_order&id=' . $params{trans_id},
420
      'url'   => $script . '?action=' . $action . '&type=purchase_order&id=' . $params{trans_id},
397 421
      'title' => $locale->text('Purchase Order') . " $params{trans_info}",
398 422
    };
399 423

  
bin/mozilla/ct.pl
286 286
    }
287 287

  
288 288
    my $base_url              = build_std_url("script=$ref->{module}.pl", 'action=edit', 'id=' . E($ref->{invid}), 'callback', @hidden_nondefault);
289
    if ($::instance_conf->get_feature_experimental) {
290
      if ('oe' eq $ref->{module}) {
291
        $base_url             = build_std_url("script=controller.pl", 'action=Order/edit', 'id=' . E($ref->{invid}), 'callback', @hidden_nondefault);
292
      }
293
    }
294

  
289 295
    $row->{invnumber}->{link} = $base_url;
290 296
    $row->{ordnumber}->{link} = $base_url . "&type=${ordertype}";
291 297
    $row->{quonumber}->{link} = $base_url . "&type=${quotationtype}";
bin/mozilla/ic.pl
541 541
      # | ist bestellt  | Von Kunden bestellt |  -> edit_oe_ord_link
542 542
      # | Anfrage       | Angebot             |  -> edit_oe_quo_link
543 543

  
544
      my $edit_oe_ord_link = build_std_url("script=oe.pl", 'action=edit', 'type=' . E($ref->{cv} eq 'vendor' ? 'purchase_order' : 'sales_order'), 'id=' . E($ref->{trans_id}), 'callback');
545
      my $edit_oe_quo_link = build_std_url("script=oe.pl", 'action=edit', 'type=' . E($ref->{cv} eq 'vendor' ? 'request_quotation' : 'sales_quotation'), 'id=' . E($ref->{trans_id}), 'callback');
544
      my $edit_oe_ord_link = ($::instance_conf->get_feature_experimental)
545
                           ? build_std_url("script=controller.pl", 'action=Order/edit',
546
                                           'type=' . E($ref->{cv} eq 'vendor' ? 'purchase_order' : 'sales_order'),        'id=' . E($ref->{trans_id}), 'callback')
547
                           : build_std_url("script=oe.pl",         'action=edit',
548
                                           'type=' . E($ref->{cv} eq 'vendor' ? 'purchase_order' : 'sales_order'),        'id=' . E($ref->{trans_id}), 'callback');
549

  
550
      my $edit_oe_quo_link = ($::instance_conf->get_feature_experimental)
551
                           ? build_std_url("script=controller.pl", 'action=Order/edit',
552
                                           'type=' . E($ref->{cv} eq 'vendor' ? 'request_quotation' : 'sales_quotation'), 'id=' . E($ref->{trans_id}), 'callback')
553
                           : build_std_url("script=oe.pl",         'action=edit',
554
                                           'type=' . E($ref->{cv} eq 'vendor' ? 'request_quotation' : 'sales_quotation'), 'id=' . E($ref->{trans_id}), 'callback');
546 555

  
547 556
      $row->{ordnumber}{link} = $edit_oe_ord_link;
548 557
      $row->{quonumber}{link} = $edit_oe_quo_link if (!$ref->{ordnumber});
templates/webpages/customer_vendor/get_delivery.html
27 27
            <tr class="listrow[% loop.count % 2 %]">
28 28
              <td>[% HTML.escape(row.shiptoname) UNLESS loop.prev.shiptoname == row.shiptoname %]&nbsp;</td>
29 29
              <td>[% IF row.id %]<a href='[% row.script %].pl?action=edit&id=[% HTML.escape(row.id) %]'>[% END %][% HTML.escape(row.invnumber)   || '&nbsp;' %][% IF row.id %]</a>[% END %]</td>
30
              <td>[% IF row.oe_id %]<a href='oe.pl?action=edit&type=[% IF SELF.is_customer %]sales_order[% ELSE %]purchase_order[% END %]&vc=customer&id=[% HTML.escape(row.oe_id) %]'>[% END %][% HTML.escape(row.ordnumber)   || '&nbsp;' %][% IF row.oe_id %]</a>[% END %]</td>
30
              [%- IF INSTANCE_CONF.get_feature_experimental -%]
31
                <td>[% IF row.oe_id %]<a href='controller.pl?action=Order/edit&type=[% IF SELF.is_customer %]sales_order[% ELSE %]purchase_order[% END %]&id=[% HTML.escape(row.oe_id) %]'>[% END %][% HTML.escape(row.ordnumber)   || '&nbsp;' %][% IF row.oe_id %]</a>[% END %]</td>
32
              [%- ELSE -%]
33
                <td>[% IF row.oe_id %]<a href='oe.pl?action=edit&type=[% IF SELF.is_customer %]sales_order[% ELSE %]purchase_order[% END %]&vc=customer&id=[% HTML.escape(row.oe_id) %]'>[% END %][% HTML.escape(row.ordnumber)   || '&nbsp;' %][% IF row.oe_id %]</a>[% END %]</td>
34
              [%- END -%]
31 35
              <td>[% HTML.escape(row.transdate)   || '&nbsp;' %]</td>
32 36
              <td>[% HTML.escape(row.description) || '&nbsp;' %]</td>
33 37
              <td>[% HTML.escape(row.qty)         || '&nbsp;' %]</td>
templates/webpages/mass_invoice_create_print_from_do/list_sales_delivery_orders.html
36 36
      <td>[% L.checkbox_tag('id[]', value=sales_delivery_order.id, "data-checkall"=1) %]</td>
37 37
      <td>[% HTML.escape(sales_delivery_order.transdate_as_date) %]</td>
38 38
      <td>[% L.link(SELF.url_for(controller="do.pl", action="edit", type="sales_delivery_order", id=sales_delivery_order.id), sales_delivery_order.donumber) %]</td>
39
      <td>[% L.link(SELF.url_for(controller="oe.pl", action="edit", type="sales_order", id=sales_delivery_order.sales_order.id), sales_delivery_order.ordnumber) %]</td>
39
      [%- IF INSTANCE_CONF.get_feature_experimental -%]
40
        <td>[% L.link(SELF.url_for(controller="controller.pl", action="Order/edit", type="sales_order", id=sales_delivery_order.sales_order.id), sales_delivery_order.ordnumber) %]</td>
41
      [%- ELSE -%]
42
        <td>[% L.link(SELF.url_for(controller="oe.pl", action="edit", type="sales_order", id=sales_delivery_order.sales_order.id), sales_delivery_order.ordnumber) %]</td>
43
      [%- END -%]
40 44
      <td>[% HTML.escape(sales_delivery_order.customer.name) %]</td>
41 45
     </tr>
42 46
     [%- END %]
templates/webpages/requirement_spec_order/list.html
79 79
      [% END %]
80 80
     </td>
81 81
     <td>
82
      <a href="oe.pl?action=edit&id=[% HTML.url(rs_order.order_id) %]&type=[% HTML.url(rs_order.order.type) %]">
82
      [%- IF INSTANCE_CONF.get_feature_experimental -%]
83
        <a href="controller.pl?action=Order/edit&id=[% HTML.url(rs_order.order_id) %]&type=[% HTML.url(rs_order.order.type) %]">
84
      [%- ELSE -%]
85
        <a href="oe.pl?action=edit&id=[% HTML.url(rs_order.order_id) %]&type=[% HTML.url(rs_order.order.type) %]">
86
      [%- END -%]
83 87
       [% HTML.escape(rs_order.order.quotation ? rs_order.order.quonumber : rs_order.order.ordnumber) %]
84 88
      </a>
85 89
     </td>

Auch abrufbar als: Unified diff