Revision 1973 tmp/org.txm.analec.rcp/src/org/txm/macro/urs/edit/CheckDuplicatesInSchemasMacro.groovy

CheckDuplicatesInSchemasMacro.groovy (revision 1973)
16 16
import org.txm.rcp.Application
17 17
import org.txm.rcp.IImageKeys
18 18
import org.txm.rcp.swt.widget.parameters.*
19
import org.txm.searchengine.cqp.CQPSearchEngine
19 20
import org.txm.searchengine.cqp.corpus.*
20 21
import org.txm.searchengine.cqp.corpus.query.CQLQuery
21 22

  
......
41 42
def CQI = CQPSearchEngine.getCqiClient()
42 43

  
43 44
def corpus = corpusViewSelection
44
mainCorpus = corpus.getMainCorpus()
45 45

  
46
def word = mainCorpus.getWordProperty()
47
def analecCorpus = URSCorpora.getCorpus(mainCorpus.getName())
46
def word = corpus.getWordProperty()
47
def analecCorpus = URSCorpora.getCorpus(corpus)
48 48

  
49 49
if (schema_property_display.length() > 0) {
50 50
	def errors = AnalecUtils.isPropertyDefined(Schema.class, analecCorpus, schema_ursql, schema_property_display).size()
......
56 56

  
57 57
def allUnits = [:]
58 58

  
59
def allSchemas = AnalecUtils.selectSchemasInCorpus(debug, analecCorpus, , schema_ursql, -1, Integer.MAX_VALUE)
59
def allSchemas = AnalecUtils.selectSchemasInCorpus(debug, analecCorpus, corpus , schema_ursql, -1, Integer.MAX_VALUE)
60 60

  
61 61
if (allSchemas.size() == 0) {
62 62
	println "No schema match for '$schema_ursql' selection. Aborting"

Also available in: Unified diff