Changeset 8408 for mauRepo


Ignore:
Timestamp:
26/06/12 14:21:46 (7 years ago)
Author:
mnagni
Message:

# 22505: Use the CedaMoles? python package
removed the ceda_moles folders and verified the imports

Location:
mauRepo/MolesManager/trunk
Files:
1 added
4 deleted
8 edited

Legend:

Unmodified
Added
Removed
  • mauRepo/MolesManager/trunk/resources/requirements.txt

    r8329 r8408  
    77#This package should be available in the machine where CedaManager will be deployed 
    88#psycopg2==2.4.2 
     9 
     10# CEDA PACKAGES please add something like 
     11# --extra-index-url http://ciprod1.cems.rl.ac.uk/pip 
     12# to your pip install  
     13ceda-moles-model==0.1.0 
  • mauRepo/MolesManager/trunk/src/MolesManager/moles3epb.py

    r8392 r8408  
    3434from ea_model.ceda_metadatamodel.ceda_observationcollection.ceda_observationcollection import CEDA_ObservationCollection 
    3535from ea_model.ceda_metadatamodel.ceda_observation.ceda_observation import CEDA_Observation 
    36 from ea_model.iso_19115_2006_metadata_corrigendum.reference_system_information.md_identifier import MD_Identifier 
    37 from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_citation import CI_Citation 
    3836from ea_model.moles3_4.observationcollection.mo_observationcollection import MO_ObservationCollection 
    3937from ea_model.moles3_4.observation.mo_observation import MO_Observation 
     
    4240from sqlalchemy.orm import mapper 
    4341from MolesManager.ceda_guid import CedaGUID 
    44 from ea_model.moles3_4.utilities.mo_responsiblepartyinfo import MO_ResponsiblePartyInfo 
    45 from ea_model.moles3_4.utilities.mo_rolevalue import MO_RoleValue 
    4642from sqlalchemy.orm.collections import InstrumentedList 
     43from ea_model.iso_19115_2006_metadata_corrigendum.reference_system_information.md_identifier import MD_Identifier 
     44from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_citation import CI_Citation 
    4745from ea_model.iso_19115_2006_metadata_corrigendum.extent_information.ex_geographicboundingbox import EX_GeographicBoundingBox 
    4846from libs.postgisutil import unifyGeometries, create_st_setSRID 
    49  
    5047 
    5148class Moles3EPBFactory(EPB): 
     
    204201            @return: True if the collection contains the given observation, False otherwise   
    205202        """ 
     203         
     204        # TO FIX!!! 
     205         
     206        ''' 
    206207        ret = self._session.query(MO_ResponsiblePartyInfo).join(MO_Observation). \ 
    207             filter(MO_ResponsiblePartyInfo.role == MO_RoleValue.cl_author). \ 
     208            filter(MO_ResponsiblePartyInfo.role == CEDA_RoleValue.cl_author). \ 
    208209            filter(MO_Observation.id == obs_id)        
    209210        return ret 
     211        ''' 
     212         
    210213 
    211214    def extractObservationByTitleKeywords(self, keywords): 
  • mauRepo/MolesManager/trunk/src/MolesManager/settings.py

    r8250 r8408  
    209209#MOLES3_DB_CONNECTION = 'postgresql://user:pws@host:port/dbName' 
    210210MOLES3_DB_CONNECTION = 'PG_MOLES3_DB_CONNECTION' 
    211 from sqlTables import doTables as doMoles, attachEvents 
     211from ea_model.sqlTables import doTables as doMoles, attachEvents 
    212212MOLES3_DB_SCRIPT = doMoles 
    213213EVENTS_DB = attachEvents 
  • mauRepo/MolesManager/trunk/src/MolesManager/views/cedaObservationView.py

    r8335 r8408  
    77from django.core.context_processors import csrf 
    88from ea_model.ceda_metadatamodel.ceda_observation.ceda_observation import CEDA_Observation 
    9 from MolesManager.moles3epb import Moles3EPB 
    109from MolesManager.djencoder import DJEncoder 
    1110from django.utils.safestring import mark_safe 
  • mauRepo/MolesManager/trunk/src/libs/migration/processor/commons.py

    r8358 r8408  
    3232''' 
    3333from ea_model.moles3_4.utilities.mo_responsiblepartyinfo import MO_ResponsiblePartyInfo 
    34 from ea_model.iso_19115_2006_metadata_corrigendum.reference_system_information.md_identifier import MD_Identifier 
    3534from httplib import HTTPConnection 
    3635from xml.etree.ElementTree import XML, tostring 
    3736import time, datetime 
    38 from ea_model.upcomingiso.ci_organisation import CI_Organisation 
    39 from ea_model.upcomingiso.ci_party import CI_Party 
    40 from ea_model.upcomingiso.ci_individual import CI_Individual 
    4137from libs.migration.exception.exceptions import NoDataLineage 
    42 from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_citation import CI_Citation 
    43 from ea_model.iso_19115_2006_metadata_corrigendum.data_quality_information.dq_element import DQ_Element 
    44 from ea_model.iso_19115_2006_metadata_corrigendum.data_quality_information.dq_conformanceresult import DQ_ConformanceResult 
    4538from hashlib import md5 
    4639from xml.sax.saxutils import unescape, escape 
     
    4942from ea_model.ceda_metadatamodel.ceda_result.ceda_result import CEDA_Result 
    5043from ea_model.moles3_4.result.mo_onlineresource import MO_OnlineResource 
    51 from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.url import URL 
    52 from ea_model.iso_19115_2006_metadata_corrigendum.extent_information.ex_geographicboundingbox import EX_GeographicBoundingBox 
    5344from ea_model.ceda_metadatamodel.ceda_computation.ceda_processing import CEDA_Processing 
    5445from ea_model.ceda_metadatamodel.ceda_acquisition.ceda_instrument import CEDA_Instrument 
    5546from ea_model.ceda_metadatamodel.ceda_observationprocess.ceda_compositeprocess import CEDA_CompositeProcess 
    5647from ea_model.ceda_metadatamodel.ceda_acquisition.ceda_acquisition import CEDA_Acquisition 
    57 from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_date import CI_Date 
     48from ea_model.ceda_metadatamodel.ceda_project.ceda_project import CEDA_Project 
     49from ea_model.ceda_metadatamodel.ceda_utilities.ceda_review import CEDA_Review 
     50from ea_model.iso_19115_2006_metadata_corrigendum.reference_system_information.md_identifier import MD_Identifier 
     51from ea_model.iso_19115_2006_metadata_corrigendum.identification_information.md_keywords import MD_Keywords 
    5852from ea_model.iso_19103_2005_schema_language.basic_types.primitive.date_and_time.datetime import DateTime 
    5953from ea_model.iso_19103_2005_schema_language.basic_types.primitive.date_and_time.date import Date 
    6054from ea_model.iso_19108_2006_temporal_schema.temporal_reference_system.tm_position import TM_Position 
    6155from ea_model.iso_19108_2006_temporal_schema.temporal_objects.tm_instant import TM_Instant 
    62 from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_contact import CI_Contact 
     56from ea_model.iso_19108_2006_temporal_schema.temporal_objects.tm_period import TM_Period 
    6357from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_address import CI_Address 
    6458from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_onlineresource import CI_OnlineResource 
    6559from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_telephone import CI_Telephone 
    66 from ea_model.iso_19108_2006_temporal_schema.temporal_objects.tm_period import TM_Period 
     60from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_contact import CI_Contact 
     61from ea_model.moles3_4.utilities.mo_individual import MO_Individual 
     62from ea_model.moles3_4.utilities.mo_organisation import MO_Organisation 
     63from ea_model.moles3_4.utilities import mo_organisation 
     64from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_date import CI_Date 
     65from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_citation import CI_Citation 
    6766from ea_model.iso_19115_2006_metadata_corrigendum.constraint_information.md_constraints import MD_Constraints 
    6867from ea_model.iso_19115_2006_metadata_corrigendum.constraint_information.md_legalconstraints import MD_LegalConstraints 
    69 from ea_model.ceda_metadatamodel.ceda_project.ceda_project import CEDA_Project 
     68from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_responsibleparty import CI_ResponsibleParty 
    7069from ea_model.iso_19115_2006_metadata_corrigendum.metadata_entity_set_information.md_metadata import MD_Metadata 
    71 from ea_model.ceda_metadatamodel.ceda_utilities.ceda_review import CEDA_Review 
    72 from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_responsibleparty import CI_ResponsibleParty 
    73 from ea_model.iso_19115_2006_metadata_corrigendum.maintenance_information.md_maintenancefrequencycode import MD_MaintenanceFrequencyCode 
    74 from ea_model.iso_19115_2006_metadata_corrigendum.identification_information.md_keywords import MD_Keywords 
     70from ea_model.iso_19115_2006_metadata_corrigendum.data_quality_information.dq_conformanceresult import DQ_ConformanceResult 
     71from ea_model.iso_19115_2006_metadata_corrigendum.extent_information.ex_geographicboundingbox import EX_GeographicBoundingBox 
     72from ea_model.iso_19115_2006_metadata_corrigendum.data_quality_information.dq_element import DQ_Element 
    7573 
    7674base = '/exist/rest/atoms' 
     
    696694    return ci_contact 
    697695 
    698 def createCI_Individual(name = None, contactInfo = None): 
    699     ''' 
    700         Creates a new CI_Individual instance 
     696def createMO_Individual(name = None, contactInfo = None): 
     697    ''' 
     698        Creates a new MO_Individual instance 
    701699        @param name: a String 
    702700        @param contactInfo: an array of CI_Contact         
    703701    '''     
    704     ci_party = CI_Individual() 
     702    ci_party = MO_Individual() 
    705703    if name: 
    706704        ci_party.name = name 
     
    709707    return ci_party 
    710708 
    711 def createCI_Organization(name = None, contactInfo = None): 
    712     ''' 
    713         Creates a new CI_Individual instance 
    714         @param name: a String 
    715         @param contactInfo: an array of CI_Contact         
    716     '''     
    717     ci_party = CI_Organisation() 
    718     if name: 
    719         ci_party.name = name 
    720     if contactInfo: 
    721         ci_party.contactInfo = contactInfo         
    722     return ci_party 
    723  
    724709def createMO_Organization(name = None, contactInfo = None): 
    725710    ''' 
    726711        Creates a new MO_Organization instance. 
    727         TEMPORARILY RETURNS A CI_ORGANIZATION BECAUSE A DB SCHEMA PROBLEM!!!! 
    728712        @param name: a String 
    729713        @param contactInfo: an array of CI_Contact         
    730714    '''        
    731     ci_party = CI_Organisation() 
     715    ci_party = MO_Organisation() 
    732716    if name: 
    733717        ci_party.name = name 
  • mauRepo/MolesManager/trunk/src/libs/migration/processor/dataEntity.py

    r8392 r8408  
    4242    hasMOBeenProcessed, getAtomDocumentHashByMO, extractTitle 
    4343from libs.migration.processor.deployment import DeploymentProcessor 
    44 from ea_model.moles3_4.utilities.mo_publicationstatevalue import MO_PublicationStateValue 
    4544from logging import StreamHandler 
    4645import logging 
    4746from ea_model.iso_19115_2006_metadata_corrigendum.citation_and_responsible_party_information.ci_datetypecode import CI_DateTypeCode 
    4847from MolesManager.ceda_guid import CedaGUID 
     48from ea_model.moles3_4.observation.mo_observationpublicationstatevalue import MO_ObservationPublicationStateValue 
     49from MolesManager.codelist import MM_ObservationPublicationStateValue,\ 
     50    getCLValue 
    4951 
    5052CEDA_TITLE = 'ceda_title' 
     
    124126        if not hasMOBeenProcessed(self._dataEntityMigration): 
    125127            docHash = getAtomDocumentHashByMO(self._dataEntityMigration) 
    126             ceda_observationCollection.publicationState = MO_PublicationStateValue.cl_working 
     128            ceda_observationCollection.publicationState = getCLValue(MM_ObservationPublicationStateValue.cl_working) 
    127129            self.epbRepo.moles3EPB.persistInstance(ceda_observationCollection) 
    128130            self.epbRepo.migrationEPB.updateMigrationObject(self._dataEntityMigration, \ 
     
    179181        try : 
    180182            if self._dataEntityMigration.ceda_observation_coll_id: 
    181                 obsColl = self.epbRepo.moles3EPB.search(CEDA_ObservationCollection, self._dataEntityMigration.ceda_observation_coll_id)  
     183                #obsColl = self.epbRepo.moles3EPB.search(CEDA_ObservationCollection, self._dataEntityMigration.ceda_observation_coll_id)  
     184                obsColl = self.epbRepo.moles3EPB.searchSelectiveLoad(CEDA_ObservationCollection, self._dataEntityMigration.ceda_observation_coll_id, \ 
     185                                                           ['identifier']) 
    182186            else: 
    183187                obsColl = CEDA_ObservationCollection() 
  • mauRepo/MolesManager/trunk/src/libs/migration/processor/deployment.py

    r8362 r8408  
    4444    createCI_Contact, createCI_Address, createCI_OnlineResource,\ 
    4545    createCI_Telephone, extractMolesTemporalRange, isoDateStringToTimeDate,\ 
    46     createTM_Period, createCI_Individual, findAccessLinksInMigrationDocument,\ 
     46    createTM_Period, findAccessLinksInMigrationDocument,\ 
    4747    findLinksInDeployment, createMD_LegalConstraints,\ 
    4848    createDQ_Element, createDQ_ConformanceResult, findUpdatedDate,\ 
     
    5050    createCI_ResponsibleParty, extractUpdateFrequency,\ 
    5151    findLinksInMigrationDocument, findSubTypeInDPT, extractMolesPublishedDate,\ 
    52     createMD_Keywords, hasMOBeenProcessed 
    53 from ea_model.moles3_4.utilities.mo_rolevalue import MO_RoleValue 
     52    createMD_Keywords, hasMOBeenProcessed, createMO_Individual 
    5453from ea_model.ceda_metadatamodel.ceda_observation.ceda_observation import CEDA_Observation 
    5554from libs.epb import EPB 
    5655from libs.migration.processor.deployment_data import DeploymentDataProcessor 
    57 from ea_model.moles3_4.utilities.mo_publicationstatevalue import MO_PublicationStateValue 
    5856from libs.migration.exception.exceptions import NoDataLineage,\ 
    5957    NoAssociatedAuthor 
     
    7472from ea_model.iso_19115_2006_metadata_corrigendum.maintenance_information.md_maintenancefrequencycode import MD_MaintenanceFrequencyCode 
    7573from ea_model.ceda_metadatamodel.ceda_result.ceda_curationvalue import CEDA_CurationValue 
     74from ea_model.moles3_4.utilities.ceda_rolevalue import CEDA_RoleValue 
     75from ea_model.moles3_4.observation.mo_observationpublicationstatevalue import MO_ObservationPublicationStateValue 
     76from MolesManager.codelist import MM_RoleValue,\ 
     77    MM_ObservationPublicationStateValue, getCLValue 
    7678 
    7779MET_GEO_FEATURE = 'Meteorological geographical features' 
     
    103105    def _existsCEDAasPublisher(self): 
    104106        for rp in self._ceda_observation.relatedParty: 
    105             if rp.role == MO_RoleValue.cl_publisher: 
     107            if rp.role == getCLValue(MM_RoleValue.cl_publisher): 
    106108                for party in rp.parties: 
    107109                    if party.name == DeploymentProcessor.publisherName: 
     
    199201             
    200202            py_date = None 
    201             cited_responsible = createCI_ResponsibleParty(role=CI_RoleCode.cl_publisher, \ 
     203            cited_responsible = createCI_ResponsibleParty(role=getCLValue(CI_RoleCode.cl_publisher), \ 
    202204                                                              organizationName='NERC - British Atmospheric Data Centre') 
    203205            if doi.upper() == '10.5285/E8F43A51-0198-4323-A926-FE69225D57DD': 
     
    212214            if py_date:    
    213215                dt = createDate(py_date) 
    214                 ci_date = createCI_Date(CI_DateTypeCode.cl_publication, date = dt) 
     216                ci_date = createCI_Date(getCLValue(CI_DateTypeCode.cl_publication), date = dt) 
    215217                i_authority = createCI_Citation("DOI", date = ci_date) 
    216218                identifier = createMD_Identifier(code = doi, authority=i_authority) 
     
    267269                int_description = "download directly from archive"     
    268270            i_sources.append(createMO_OnlineResource(linkage = dwn['href'], name = dwn['title'], \ 
    269                                                    function = CI_OnLineFunctionCode.cl_download, \ 
     271                                                   function = getCLValue(CI_OnLineFunctionCode.cl_download), \ 
    270272                                                   description = int_description, applicationProfile = int_applicationProfile)) 
    271273             
     
    280282            i_logical_path = infodb_de['logical_path'] 
    281283                 
    282         i_category = ceda_curationvalue.CEDA_CurationValue.cl_a                                     
     284        i_category = getCLValue(CEDA_CurationValue.cl_a)                                   
    283285        if infodb_de and infodb_de.has_key('category') and infodb_de['category']: 
    284286            i_category = CEDA_CurationValue.from_string(infodb_de['category'].lower())         
     
    328330         
    329331        if party and not self._deploymentHasBeenProcessed: 
    330             observation.relatedParty.append(createMO_ResponsiblePartyInfo(MO_RoleValue.cl_publisher, [party])) 
    331             observation.relatedParty.append(createMO_ResponsiblePartyInfo(MO_RoleValue.cl_custodian, deepcopy([party]))) 
    332             observation.relatedParty.append(createMO_ResponsiblePartyInfo(MO_RoleValue.cl_distributor, deepcopy([party]))) 
    333             observation.relatedParty.append(createMO_ResponsiblePartyInfo(MO_RoleValue.cl_pointofcontact, deepcopy([party]))) 
    334             observation.relatedParty.append(createMO_ResponsiblePartyInfo(MO_RoleValue.cl_metadataowner, deepcopy([party]))) 
    335             observation.relatedParty.append(createMO_ResponsiblePartyInfo(MO_RoleValue.cl_curator, deepcopy([party]))) 
     332            observation.relatedParty.append(createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_publisher), [party])) 
     333            observation.relatedParty.append(createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_custodian), deepcopy([party]))) 
     334            observation.relatedParty.append(createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_distributor), deepcopy([party]))) 
     335            observation.relatedParty.append(createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_pointofcontact), deepcopy([party]))) 
     336            observation.relatedParty.append(createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_metadataowner), deepcopy([party]))) 
     337            observation.relatedParty.append(createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_curator), deepcopy([party]))) 
    336338            return         
    337339        #Still have to update observation.result.source 
     
    346348        if doc_date: 
    347349            i_date = createDate(isoDateTimeStringToTimeDate(doc_date))                 
    348             ci_dates.append(createCI_Date(CI_DateTypeCode.cl_revision, date = i_date))             
     350            ci_dates.append(createCI_Date(getCLValue(CI_DateTypeCode.cl_revision), date = i_date))             
    349351        else: 
    350352            i_date = createDate(isoDateTimeStringToTimeDate(datetime.datetime.now())) 
    351             ci_dates.append(createCI_Date(CI_DateTypeCode.cl_creation, date = i_date)) 
     353            ci_dates.append(createCI_Date(getCLValue(CI_DateTypeCode.cl_creation), date = i_date)) 
    352354 
    353355        i_specification = createCI_Citation(title = "CEDA Data Quality Statement", date=ci_dates) 
     
    504506            if access_link and len(access_link) == 1: 
    505507                i_use_limitation.append("Access to these data is restricted. To obtain access please apply for access at: %s" % (access_link[0]['href'])) 
    506                 i_accessConstraints.append(MD_RestrictionCode.cl_restricted) 
     508                i_accessConstraints.append(getCLValue(MD_RestrictionCode.cl_restricted)) 
    507509                observation.permission = createMD_LegalConstraints(useLimitation = i_use_limitation, accessConstrains = i_accessConstraints) 
    508510                 
     
    534536            return 
    535537                
    536         i_party = createCI_Individual(name = 'Graham Parton') 
    537         i_reviewer = createMO_ResponsiblePartyInfo(MO_RoleValue.cl_processor, [i_party]) 
    538         ceda_observation.internalReview.append( \ 
    539             createCEDA_Review(reviewer=i_reviewer, reviewFrequency=CEDA_ReviewFrequencyValue.cl_yearly, \ 
    540                               reviewStatus=CEDA_ReviewStatusValue.cl_required))   
     538        i_party = createMO_Individual(name = 'Graham Parton') 
     539        i_reviewer = createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_processor), [i_party]) 
     540        ceda_observation.metadataManagement.append( \ 
     541            createCEDA_Review(reviewer=i_reviewer, reviewFrequency=getCLValue(CEDA_ReviewFrequencyValue.cl_yearly), \ 
     542                              reviewStatus=getCLValue(CEDA_ReviewStatusValue.cl_required)))   
    541543 
    542544    def _assignLanguage(self, ceda_observation): 
     
    546548        i_date_stamp = createDate(datetime.datetime.now()) 
    547549        #i_contact = createCI_Citation("", date = i_date_stamp) 
    548         i_contact = createCI_ResponsibleParty(CI_RoleCode.cl_user) 
     550        i_contact = createCI_ResponsibleParty(getCLValue(CI_RoleCode.cl_user)) 
    549551        ceda_observation.metadata = createMD_Metadata(date_stamp=i_date_stamp, contact = [i_contact], language = "English") 
    550552                         
     
    582584 
    583585            if len(ret['ind']) > 0: 
    584                 i_party = createCI_Individual(name = ret['ind'][0]) 
    585                 observation.relatedParty.append(createMO_ResponsiblePartyInfo(MO_RoleValue.cl_author, [i_party]))                  
     586                i_party = createMO_Individual(name = ret['ind'][0]) 
     587                observation.relatedParty.append(createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_author), [i_party]))                  
    586588            if len(ret['org']) > 0: 
    587589                i_party = createMO_Organization(name = ret['org'][0]) 
    588                 observation.relatedParty.append(createMO_ResponsiblePartyInfo(MO_RoleValue.cl_author, [i_party])) 
     590                observation.relatedParty.append(createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_author), [i_party])) 
    589591             
    590592            if len(ret['ind']) > 1: 
     
    610612        i_party = [] 
    611613        for nm in ind_names: 
    612             i_party.append(createCI_Individual(name = nm)) 
     614            i_party.append(createMO_Individual(name = nm)) 
    613615                 
    614616        for nm in org_names: 
     
    617619        if i_party: 
    618620            if not self._deploymentHasBeenProcessed: 
    619                 observation.relatedParty.append(createMO_ResponsiblePartyInfo(MO_RoleValue.cl_coinvestigator, i_party)) 
     621                observation.relatedParty.append(createMO_ResponsiblePartyInfo(getCLValue(MM_RoleValue.cl_coinvestigator), i_party)) 
    620622                return 
    621623        #Still have to update observation.permission 
     
    642644        #Is a first time process? 
    643645        if not hasMOBeenProcessed(self._deploymentMigration): 
    644             ceda_observation.publicationState = MO_PublicationStateValue.cl_working             
     646            ceda_observation.publicationState = getCLValue(MM_ObservationPublicationStateValue.cl_working)           
    645647            docHash = getAtomDocumentHashByMO(self._dataEntityMigration) 
    646648            self.epbRepo.moles3EPB.persistInstance(ceda_observation)         
  • mauRepo/MolesManager/trunk/src/libs/migration/processor/deployment_data.py

    r8358 r8408  
    3535    findSummary, findDocumentationInMigrationDocument, createCI_Citation,\ 
    3636    createMO_OnlineResource, findLinksInDeployment 
    37 from ea_model.moles3_4.utilities.mo_publicationstatevalue import MO_PublicationStateValue 
     37from ea_model.moles3_4.utilities.ceda_publicationstatevalue import CEDA_PublicationStateValue 
    3838 
    3939class DeploymentDataProcessor(object): 
     
    6464                    i_documentation = createCI_Citation("Documentation resource") 
    6565                    i_resource = createMO_OnlineResource(doc_link[0]['href']) 
    66                 project = createCEDA_Project(abstract=i_abstract, publication_state=MO_PublicationStateValue.cl_working, \ 
     66                project = createCEDA_Project(abstract=i_abstract, publication_state=CEDA_PublicationStateValue.cl_working, \ 
    6767                                             documentation=i_documentation, project_resource=i_resource) 
    6868                self._commitDeploymentMigration(project, activity, 'ceda_project_id') 
Note: See TracChangeset for help on using the changeset viewer.