개정판 fd369507
issue #000: 0618
Change-Id: Ib7dcf97f83d731dfb02d923730ba0284756a5e97
DTI_PID/DTI_PID/Shapes/EngineeringAbstractItem.py | ||
---|---|---|
159 | 159 |
self.attrs.clear() |
160 | 160 |
self._associations.clear() |
161 | 161 |
else: |
162 |
freeze = False |
|
162 | 163 |
for key in self.attrs.keys(): |
163 | 164 |
if key.Freeze: |
164 |
return |
|
165 |
freeze = True |
|
166 |
break |
|
167 |
if freeze: |
|
168 |
for assoc in self.associations(): |
|
169 |
assoc.owner = self |
|
165 | 170 |
|
166 |
|
|
167 |
self.attrs.clear() |
|
168 |
self._associations.clear() |
|
171 |
else: |
|
172 |
self.attrs.clear()
|
|
173 |
self._associations.clear()
|
|
169 | 174 |
|
170 | 175 |
def add_assoc_item(self, item, at=None): |
171 | 176 |
""" add given item to association """ |
DTI_PID/DTI_PID/Shapes/EngineeringEquipmentItem.py | ||
---|---|---|
142 | 142 |
@author humkyung |
143 | 143 |
@date 2018.06.14 |
144 | 144 |
''' |
145 |
''' |
|
145 | 146 |
def getAttributes(self): |
146 | 147 |
_attrs = {} |
147 | 148 |
try: |
... | ... | |
185 | 186 |
App.mainWnd().addMessage.emit(MessageType.Error, message) |
186 | 187 |
|
187 | 188 |
return _attrs |
189 |
''' |
|
188 | 190 |
|
189 | 191 |
def highlight(self, flag): |
190 | 192 |
""" highlight/unhighlight the equpment """ |
DTI_PID/DTI_PID/Shapes/EngineeringReducerItem.py | ||
---|---|---|
114 | 114 |
message = 'error occured({}) in {}:{}'.format(ex, sys.exc_info()[-1].tb_frame.f_code.co_filename, sys.exc_info()[-1].tb_lineno) |
115 | 115 |
App.mainWnd().addMessage.emit(MessageType.Error, message) |
116 | 116 |
|
117 |
''' |
|
117 | 118 |
def getAttributes(self): |
118 | 119 |
""" get attributes of reducer """ |
119 | 120 |
|
... | ... | |
126 | 127 |
# 해당 Type의 attribute setting |
127 | 128 |
docData = AppDocData.instance() |
128 | 129 |
symbolAttrs = docData.getSymbolAttribute(self.type) |
130 |
|
|
129 | 131 |
_texts = self.texts() |
130 | 132 |
_symbols = self.symbols() |
131 | 133 |
for attr in symbolAttrs: |
... | ... | |
151 | 153 |
App.mainWnd().addMessage.emit(MessageType.Error, message) |
152 | 154 |
|
153 | 155 |
return _attrs |
156 |
''' |
|
154 | 157 |
|
155 | 158 |
def toSql(self): |
156 | 159 |
""" convert valve data to sql query """ |
DTI_PID/DTI_PID/Shapes/SymbolSvgItem.py | ||
---|---|---|
664 | 664 |
super().mouseReleaseEvent(event) |
665 | 665 |
|
666 | 666 |
def removeSelfAttr(self, attributeName): |
667 |
target = None |
|
667 | 668 |
for attr in self.attrs: |
668 | 669 |
if attr.Attribute == attributeName: |
669 |
del self.attrs[attr] |
|
670 |
target = attr |
|
671 |
break |
|
672 |
|
|
673 |
if target: |
|
674 |
del self.attrs[attr] |
|
670 | 675 |
|
671 | 676 |
''' |
672 | 677 |
@brief Find TextItem contain Point |
내보내기 Unified diff