SEBA-457 Core xproto cleanup
Change-Id: Ib99680dd81016694094a5c230afdf9dcf2cb307e
diff --git a/lib/xos-genx/xosgenx/targets/mock_classes.xtarget b/lib/xos-genx/xosgenx/targets/mock_classes.xtarget
index 61c2f1f..bc56747 100644
--- a/lib/xos-genx/xosgenx/targets/mock_classes.xtarget
+++ b/lib/xos-genx/xosgenx/targets/mock_classes.xtarget
@@ -225,6 +225,9 @@
model_accessor = ModelAccessor()
+def get_first_site():
+ return model_accessor.Site.objects.first().id
+
class ObjectSet(object):
def __init__(self, objects):
self.objects = objects
diff --git a/lib/xos-genx/xosgenx/targets/service.xtarget b/lib/xos-genx/xosgenx/targets/service.xtarget
index 1027680..4c47fab 100644
--- a/lib/xos-genx/xosgenx/targets/service.xtarget
+++ b/lib/xos-genx/xosgenx/targets/service.xtarget
@@ -2,14 +2,14 @@
{% set legacy_tag = '_decl' %}
{% set legacy = True %}
from core.models.xosbase import *
-from core.models import ServiceInstance, TenantWithContainer
+from core.models import ServiceInstance
{% else %}
{% set legacy = False %}
{% set legacy_tag = '' %}
{% if file_exists('../header.py') or file_exists('header.py')-%}from header import *
{% else %}
from core.models.xosbase import *
-from core.models import ServiceInstance, TenantWithContainer
+from core.models import ServiceInstance
{% endif %}
{% endif %}