Esempio n. 1
0
def move_object(s):
    obj = input("Enter Object Handle: ")
    source = input("Enter Collection Handle to Move From: ")
    dest = input("Enter Collection Handle to Move To: ")

    DCC.dcc_move(s, obj, source, dest)
    return
Esempio n. 2
0
def move_object(s):
    obj = input("Enter Object Handle: ")
    source = input("Enter Collection Handle to Move From: ")
    dest = input("Enter Collection Handle to Move To: ")

    DCC.dcc_move(s, obj, source, dest)
    return    
Esempio n. 3
0
                {'chandle':'Collection-1004', 'cname':'5.0 Change Control Requests - CR Archive','keyword':'CR - Archived'},      
                ]
        
        idx = 0   
        for l in list:
            print('[',idx,'] : ', l['cname'])
            idx = idx + 1
   
        ans = input('\n>>>> Choose a new location for the Collection [1-6] or Q:')
        if 'Q' in ans.upper():
            print('\n\n....Not making any changes')  
        else:
            # Remove collection from all change control collections
            ansnum = int(ans)
            dest = list[ansnum]['chandle']
            for l in list:
                for p in fd['parents']:
                    if p[0] == l['chandle']:
                        if dest != l['chandle']: # don't move if it's already in the desired collection
                            DCC.dcc_move(s, cr_coll, l['chandle'], dest)
            # Set keywords
            DCC.set_metadata(s, cr_coll, Keywords = crnum + ': ' + list[ansnum]['keyword'])        
            DCC.set_metadata(s, cr_coll, Summary = crnum + ': ' + list[ansnum]['keyword'])   
        
        print('\n')
        fd = DCC.prop_get(s, cr_coll, InfoSet = 'CollData')
        fd['parents'] = DCC.prop_get(s, cr_coll, InfoSet = 'Parents')
        DCC.print_coll_data(fd)
        DCC.print_parents(fd['parents'])