relationship stuff basically working
This commit is contained in:
		
							parent
							
								
									e676e10e33
								
							
						
					
					
						commit
						13706c3d84
					
				
					 2 changed files with 7 additions and 4 deletions
				
			
		|  | @ -34,10 +34,10 @@ class Concepts(Container): | |||
|     indexes = None | ||||
| 
 | ||||
|     def queryRels(self, **crit): | ||||
|         pred = crit.get(predicate) | ||||
|         if pred is not None and isinstance(pred, ('string', 'bytes')): | ||||
|             crit['predicate'] = self.storage.getContainer(Predicate).queryLast(name=pred) | ||||
|         for k, v in crit.items: | ||||
|         #pred = crit.get(predicate) | ||||
|         #if pred is not None and isinstance(pred, ('string', 'bytes')): | ||||
|         #    crit['predicate'] = self.storage.getContainer(Predicate).queryLast(name=pred) | ||||
|         for k, v in crit.items(): | ||||
|             if isinstance(v, Track): | ||||
|                 crit[k] = v.uid | ||||
|         rels = self.storage.getContainer(Triple) | ||||
|  |  | |||
|  | @ -114,5 +114,8 @@ def test_topic(self, config): | |||
|     topics.save(tp_proglang) | ||||
|     tp_itc.addChild(tp_proglang) | ||||
| 
 | ||||
|     c = list(tp_itc.children()) | ||||
|     self.assertEqual(c[0].getSecond().name, 'prog_lang') | ||||
| 
 | ||||
|     storage.commit() | ||||
|      | ||||
|  |  | |||
		Loading…
	
	Add table
		
		Reference in a new issue