View | Details | Raw Unified | Return to bug 35451
Collapse All | Expand All

(-)a/Koha/Schema/Result/Accountline.pm (-3 / +1 lines)
Lines 447-455 __PACKAGE__->has_many( Link Here
447
447
448
    return {
448
    return {
449
        "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.accountlines_id" },
449
        "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.accountlines_id" },
450
450
        "$args->{foreign_alias}.record_table" => __PACKAGE__->table,
451
        "$args->{foreign_alias}.field_id" =>
452
            { -in => \'(SELECT id FROM additional_fields WHERE tablename LIKE "accountlines:%")' },
453
    };
451
    };
454
  },
452
  },
455
  { cascade_copy => 0, cascade_delete => 0 },
453
  { cascade_copy => 0, cascade_delete => 0 },
(-)a/Koha/Schema/Result/Aqbasket.pm (-3 / +1 lines)
Lines 352-360 __PACKAGE__->has_many( Link Here
352
352
353
    return {
353
    return {
354
        "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.basketno" },
354
        "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.basketno" },
355
355
        "$args->{foreign_alias}.record_table" => __PACKAGE__->table,
356
        "$args->{foreign_alias}.field_id" =>
357
            { -in => \'(SELECT id FROM additional_fields WHERE tablename = "aqbasket")' },
358
    };
356
    };
359
  },
357
  },
360
  { cascade_copy => 0, cascade_delete => 0 },
358
  { cascade_copy => 0, cascade_delete => 0 },
(-)a/Koha/Schema/Result/Aqinvoice.pm (-3 / +1 lines)
Lines 228-236 __PACKAGE__->has_many( Link Here
228
228
229
        return {
229
        return {
230
            "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.invoiceid" },
230
            "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.invoiceid" },
231
231
            "$args->{foreign_alias}.record_table" => __PACKAGE__->table,
232
            "$args->{foreign_alias}.field_id" =>
233
              { -in => \'(SELECT id FROM additional_fields WHERE tablename="aqinvoices")' },
234
        };
232
        };
235
    },
233
    },
236
    { cascade_copy => 0, cascade_delete => 0 },
234
    { cascade_copy => 0, cascade_delete => 0 },
(-)a/Koha/Schema/Result/Aqorder.pm (-4 / +1 lines)
Lines 900-909 __PACKAGE__->has_many( Link Here
900
900
901
    return {
901
    return {
902
        "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.ordernumber" },
902
        "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.ordernumber" },
903
903
        "$args->{foreign_alias}.record_table" => __PACKAGE__->table,
904
        # TODO Add column additional_field_values.tablename to avoid subquery ?
905
        "$args->{foreign_alias}.field_id" =>
906
            { -in => \'(SELECT id FROM additional_fields WHERE tablename = "aqorders")' },
907
    };
904
    };
908
  },
905
  },
909
  { cascade_copy => 0, cascade_delete => 0 },
906
  { cascade_copy => 0, cascade_delete => 0 },
(-)a/Koha/Schema/Result/Subscription.pm (-4 / +1 lines)
Lines 577-585 __PACKAGE__->has_many( Link Here
577
577
578
    return {
578
    return {
579
        "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.subscriptionid" },
579
        "$args->{foreign_alias}.record_id" => { -ident => "$args->{self_alias}.subscriptionid" },
580
580
        "$args->{foreign_alias}.record_table" => __PACKAGE__->table,
581
        "$args->{foreign_alias}.field_id" =>
582
            { -in => \'(SELECT id FROM additional_fields WHERE tablename = "subscription")' },
583
    };
581
    };
584
  },
582
  },
585
  { cascade_copy => 0, cascade_delete => 0 },
583
  { cascade_copy => 0, cascade_delete => 0 },
586
- 

Return to bug 35451