mirror of
https://github.com/nottinghamtec/PyRIGS.git
synced 2026-01-17 05:22:16 +00:00
Added ability to delete all venues before improt
This commit is contained in:
@@ -90,7 +90,9 @@ def import_vat_rates():
|
||||
print("Found: " + object.__str__())
|
||||
|
||||
|
||||
def import_venues():
|
||||
def import_venues(delete=False):
|
||||
if delete:
|
||||
models.Venue.objects.all().delete()
|
||||
cursor = setup_cursor()
|
||||
if cursor is None:
|
||||
return
|
||||
@@ -116,8 +118,7 @@ def main():
|
||||
# import_people()
|
||||
# import_organisations()
|
||||
# import_vat_rates()
|
||||
import_venues()
|
||||
|
||||
import_venues(True)
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
||||
|
||||
Reference in New Issue
Block a user