Ignore:
Timestamp:
Apr 6, 2011 5:24:54 PM (8 years ago)
Author:
Ted Faber <faber@…>
Branches:
compt_changes, info-ops, master
Children:
eb41909
Parents:
42dedbd
Message:

Need to keep track of service records to update.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fedd/federation/experiment_control.py

    r1ec5d4a rd0912be  
    12471247                        "More than one project export is not supported")
    12481248
    1249         def add_services(svcs, type, slist):
     1249        def add_services(svcs, type, slist, keys):
    12501250            """
    1251             Add the given services to slist.  type is import or export.
     1251            Add the given services to slist.  type is import or export.  Also
     1252            add a mapping entry from the assigned id to the original service
     1253            record.
    12521254            """
    12531255            for i, s in enumerate(svcs):
    12541256                idx = '%s%d' % (type, i)
     1257                keys[idx] = s
    12551258                sr = {'id': idx, 'name': s.name, 'visibility': type }
    12561259                if s.params:
     
    12941297        if import_svcs or export_svcs:
    12951298            slist = []
    1296             add_services(import_svcs, 'import', slist)
    1297             add_services(export_svcs, 'export', slist)
     1299            add_services(import_svcs, 'import', slist, e_keys)
     1300            add_services(export_svcs, 'export', slist, e_keys)
    12981301            req['service'] = slist
    12991302
Note: See TracChangeset for help on using the changeset viewer.