summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Container.py6
-rw-r--r--DockWidgets/DockWidget.py7
-rw-r--r--DockWidgets/__pycache__/DockWidget.cpython-37.pycbin6107 -> 6155 bytes
-rw-r--r--Graphics.py6
-rw-r--r--Undo.datbin63193 -> 4777 bytes
-rw-r--r--UnitOperations.py3
6 files changed, 14 insertions, 8 deletions
diff --git a/Container.py b/Container.py
index 5469de2..ec46706 100644
--- a/Container.py
+++ b/Container.py
@@ -186,11 +186,9 @@ class Container():
self.msg_browser()
self.result=self.flowsheet.result_data
print("under Eqn mode simulation")
+ print("710 ", self.result)
- try:
- DockWidget.show_result(NodeItem.get_dock_widget())
- except AttributeError:
- pass
+ DockWidget.show_result(NodeItem.get_dock_widget())
def flat_list(lst):
flat_lst=[]
diff --git a/DockWidgets/DockWidget.py b/DockWidgets/DockWidget.py
index 6fc7731..2b1cdb9 100644
--- a/DockWidgets/DockWidget.py
+++ b/DockWidgets/DockWidget.py
@@ -187,10 +187,11 @@ class DockWidget(QDockWidget,ui_dialog):
@staticmethod
def show_result(lst):
- #DockWidget1.flag = True
for i in lst:
- i.results_category(i.name)
- #i.show()
+ try:
+ i.results_category(i.name)
+ except AttributeError:
+ pass
# result data tab
def results_category(self,name):
diff --git a/DockWidgets/__pycache__/DockWidget.cpython-37.pyc b/DockWidgets/__pycache__/DockWidget.cpython-37.pyc
index f1fa8b5..b042722 100644
--- a/DockWidgets/__pycache__/DockWidget.cpython-37.pyc
+++ b/DockWidgets/__pycache__/DockWidget.cpython-37.pyc
Binary files differ
diff --git a/Graphics.py b/Graphics.py
index fd02d39..47aa4ea 100644
--- a/Graphics.py
+++ b/Graphics.py
@@ -473,6 +473,12 @@ class NodeItem(QtWidgets.QGraphicsItem):
self.nop = int(text)
self.obj.no_of_outputs = self.nop
self.obj.variables['No']['value'] = self.nop
+ elif self.obj.type == 'DistillationColumn':
+ text, ok = QInputDialog.getText(self.container.graphicsView, 'DistillationColumn', 'Enter number of input:')
+ if ok and text:
+ self.nin = int(text)
+ self.obj.no_of_inputs = self.nin
+ self.obj.variables['NI']['value'] = self.nin
self.dock_widget = None
lst.append(self)
diff --git a/Undo.dat b/Undo.dat
index 436d91a..b3b7c48 100644
--- a/Undo.dat
+++ b/Undo.dat
Binary files differ
diff --git a/UnitOperations.py b/UnitOperations.py
index 90111d1..7105606 100644
--- a/UnitOperations.py
+++ b/UnitOperations.py
@@ -214,7 +214,7 @@ class DistillationColumn(UnitOperation):
def __init__(self,name='DistillationColumn'):
self.name = name + str(DistillationColumn.counter)
self.type = 'DistillationColumn'
- self.no_of_inputs = 2
+ self.no_of_inputs = 1
self.no_of_outputs = 2
self.compounds = compound_selected
@@ -232,6 +232,7 @@ class DistillationColumn(UnitOperation):
type(self).counter += 1
self.variables = {
+ 'NI' : {'name':'Number of Input', 'value':2, 'unit':''},
'RR' : {'name':'Reflux Ratio', 'value':None, 'unit':''},
'T' : {'name':'Temperature', 'value':300, 'unit':'K'},
'Nout' : {'name':'No of Sidedraws', 'value':None, 'unit':''},