aggiunta costruzione della configurazione per splitter
This commit is contained in:
@@ -416,6 +416,27 @@ class bananaSelezOut(PyQt5.QtWidgets.QWidget):
|
||||
|
||||
def splitta(self):
|
||||
# costruisco il dizionario di configurazione
|
||||
splconf = copy.deepcopy(self.conf.dump())
|
||||
lang = copy.deepcopy(self.conf.use('languageconf.json').getParam(splconf['docStruct']['language']))
|
||||
splconf['language'] = self.conf.use('languageconf.json').getParam(lang)
|
||||
|
||||
#formato nome in uscita
|
||||
nametemp=[]
|
||||
for i in range(3):
|
||||
if i == splconf['docStruct']['numberPos'] and splconf['docStruct']['outNumber']:
|
||||
nametemp.append("docnum")
|
||||
if i == splconf['docStruct']['datePos'] and splconf['docStruct']['outDate']:
|
||||
nametemp.append(splconf['docStruct']['dateFormats'][splconf['docStruct']['outDateType']])
|
||||
if i == splconf['docStruct']['titlePos'] and splconf['docStruct']['outTitle']:
|
||||
nametemp.append("title")
|
||||
pass
|
||||
if splconf['docStruct']['outPrefix'] != '':
|
||||
nametemp.insert(0, splconf['docStruct']['outPrefix']) #inserisco prefisso e suffisso
|
||||
if splconf['docStruct']['outSuffix'] != '':
|
||||
nametemp.append(splconf['docStruct']['outSuffix'])
|
||||
#unisco i pezzi
|
||||
splconf['docStruct']['outNameFormat'] = splconf['docStruct']['outNameSep'].join(nametemp)+splconf['docStruct']['outExt']
|
||||
|
||||
pass
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user