Exemplo n.º 1
0
	def viewHouseholdData(self):
		if self.countRowsSelected(self.tableView) != 0:
			# get the hhid of the selected household
			selectedRow = self.getCurrentRow(self.tableView)
			hhid = self.tableView.model().item(selectedRow,0).text()
		
			# show household data form
			form = FrmHouseholdData(self.parent,hhid)
			subWin = self.parent.mdi.addSubWindow(form)
			self.parent.centerSubWindow(subWin)
			form.show()
		else:
			msg = "Please select the row containing a household whose data you want to view or edit."
			QMessageBox.information(self,"View|Edit Household Data",msg)