def loadCmbsUnderKec(self, kecamatan): #rint'loadCmbsUnderKec' sql = "SELECT kelurahan FROM postcodes \ WHERE kecamatan = '%s' \ GROUP BY (kelurahan) \ ORDER BY (kelurahan)" % kecamatan self.combo_box_kel.Clear() loadCmb.setItems(self.combo_box_kel, sql) sql = "SELECT kabupaten FROM postcodes \ WHERE kecamatan = '%s'" % kecamatan kabupaten = fetch.getStr(sql) loadCmb.restore_str(self.combo_box_kab, kabupaten)
def loadCmbsUnderKab(self, kabupaten): #rint'loadCmbsUnderKab' sql = "SELECT kecamatan FROM postcodes \ WHERE kabupaten = '%s' \ GROUP BY (kecamatan) \ ORDER BY (kecamatan)" % kabupaten loadCmb.setItems(self.combo_box_kec, sql) sql = "SELECT kelurahan FROM postcodes \ WHERE kabupaten = '%s' \ GROUP BY (kelurahan) \ ORDER BY (kelurahan)" % kabupaten loadCmb.setItems(self.combo_box_kel, sql)