|
|
|
@ -1,4 +1,117 @@
|
|
|
|
|
[
|
|
|
|
|
{
|
|
|
|
|
"label": "django.db.models.deletion",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"importPath": "django.db.models.deletion",
|
|
|
|
|
"description": "django.db.models.deletion",
|
|
|
|
|
"detail": "django.db.models.deletion",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "migrations",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "migrations",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "migrations",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "migrations",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "migrations",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "admin",
|
|
|
|
|
"importPath": "django.contrib",
|
|
|
|
@ -55,38 +168,6 @@
|
|
|
|
|
"detail": "django.apps",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "models",
|
|
|
|
|
"importPath": "django.db",
|
|
|
|
|
"description": "django.db",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "django.db",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "json",
|
|
|
|
|
"kind": 6,
|
|
|
|
@ -152,6 +233,22 @@
|
|
|
|
|
"detail": "rest_framework",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "serializers",
|
|
|
|
|
"importPath": "rest_framework",
|
|
|
|
|
"description": "rest_framework",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "rest_framework",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "viewsets",
|
|
|
|
|
"importPath": "rest_framework",
|
|
|
|
|
"description": "rest_framework",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "rest_framework",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "logging",
|
|
|
|
|
"kind": 6,
|
|
|
|
@ -382,6 +479,14 @@
|
|
|
|
|
"detail": "frontImages",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "views",
|
|
|
|
|
"importPath": "object",
|
|
|
|
|
"description": "object",
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"detail": "object",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "get_wsgi_application",
|
|
|
|
|
"importPath": "django.core.wsgi",
|
|
|
|
@ -390,6 +495,24 @@
|
|
|
|
|
"detail": "django.core.wsgi",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "frontImages.models",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"importPath": "frontImages.models",
|
|
|
|
|
"description": "frontImages.models",
|
|
|
|
|
"detail": "frontImages.models",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "object.models",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"isExtraImport": true,
|
|
|
|
|
"importPath": "object.models",
|
|
|
|
|
"description": "object.models",
|
|
|
|
|
"detail": "object.models",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "sys",
|
|
|
|
|
"kind": 6,
|
|
|
|
@ -399,6 +522,15 @@
|
|
|
|
|
"detail": "sys",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "Migration",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.api.migrations.0001_initial",
|
|
|
|
|
"description": "back.api.migrations.0001_initial",
|
|
|
|
|
"peekOfCode": "class Migration(migrations.Migration):\n initial = True\n dependencies = [\n ]\n operations = [\n migrations.CreateModel(\n name='Floorplan',\n fields=[\n ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),\n ('title', models.CharField(max_length=200)),",
|
|
|
|
|
"detail": "back.api.migrations.0001_initial",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "ApiConfig",
|
|
|
|
|
"kind": 6,
|
|
|
|
@ -755,7 +887,7 @@
|
|
|
|
|
"kind": 5,
|
|
|
|
|
"importPath": "back.back.urls",
|
|
|
|
|
"description": "back.back.urls",
|
|
|
|
|
"peekOfCode": "router = routers.DefaultRouter()\nrouter.register(r'api/front_img', frontimg_views.ImageViewSet)\nurlpatterns = [\n path('', include(router.urls)),\n path(\"admin/\", admin.site.urls),\n path(\"api/products\", csrf_exempt(views.Products.as_view())),\n path(\"api/floorplan/\", csrf_exempt(views.FloorplanView.as_view())),\n path(\"api/floorplan/<str:id>\", csrf_exempt(views.FloorplanView.as_view())),\n path(\"api/floorplan/<str:id>/points\", csrf_exempt(views.FloorplanPointsView.as_view())),\n] + static('/files', document_root='files')",
|
|
|
|
|
"peekOfCode": "router = routers.DefaultRouter()\nrouter.register(r'api/front_img', frontimg_views.ImageViewSet)\nrouter.register(r'api/obj/element', object_views.Element3DViewSet)\nrouter.register(r'api/obj/clickable', object_views.ClickableAreaViewSet)\nurlpatterns = [\n path('', include(router.urls)),\n path(\"admin/\", admin.site.urls),\n path(\"api/products\", csrf_exempt(views.Products.as_view())),\n path(\"api/floorplan/\", csrf_exempt(views.FloorplanView.as_view())),\n path(\"api/floorplan/<str:id>\", csrf_exempt(views.FloorplanView.as_view())),",
|
|
|
|
|
"detail": "back.back.urls",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
@ -777,6 +909,15 @@
|
|
|
|
|
"detail": "back.back.wsgi",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "Migration",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.frontImages.migrations.0001_initial",
|
|
|
|
|
"description": "back.frontImages.migrations.0001_initial",
|
|
|
|
|
"peekOfCode": "class Migration(migrations.Migration):\n initial = True\n dependencies = [\n ]\n operations = [\n migrations.CreateModel(\n name='Image',\n fields=[\n ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),\n ('file', models.ImageField(upload_to=frontImages.models.group_based_upload_to)),",
|
|
|
|
|
"detail": "back.frontImages.migrations.0001_initial",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "FrontimagesConfig",
|
|
|
|
|
"kind": 6,
|
|
|
|
@ -831,6 +972,33 @@
|
|
|
|
|
"detail": "back.frontImages.views",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "Migration",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.object.migrations.0001_initial",
|
|
|
|
|
"description": "back.object.migrations.0001_initial",
|
|
|
|
|
"peekOfCode": "class Migration(migrations.Migration):\n initial = True\n dependencies = [\n ]\n operations = [\n migrations.CreateModel(\n name='Element3D',\n fields=[\n ('id', models.BigAutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),\n ('model_file', models.FileField(upload_to=object.models.group_based_upload_to)),",
|
|
|
|
|
"detail": "back.object.migrations.0001_initial",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "Migration",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.object.migrations.0002_remove_element3d_parent",
|
|
|
|
|
"description": "back.object.migrations.0002_remove_element3d_parent",
|
|
|
|
|
"peekOfCode": "class Migration(migrations.Migration):\n dependencies = [\n ('object', '0001_initial'),\n ]\n operations = [\n migrations.RemoveField(\n model_name='element3d',\n name='parent',\n ),\n ]",
|
|
|
|
|
"detail": "back.object.migrations.0002_remove_element3d_parent",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "Migration",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.object.migrations.0003_element3d_parent",
|
|
|
|
|
"description": "back.object.migrations.0003_element3d_parent",
|
|
|
|
|
"peekOfCode": "class Migration(migrations.Migration):\n dependencies = [\n ('object', '0002_remove_element3d_parent'),\n ]\n operations = [\n migrations.AddField(\n model_name='element3d',\n name='parent',\n field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.PROTECT, to='object.element3d'),\n ),",
|
|
|
|
|
"detail": "back.object.migrations.0003_element3d_parent",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "ObjectConfig",
|
|
|
|
|
"kind": 6,
|
|
|
|
@ -845,7 +1013,7 @@
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.object.models",
|
|
|
|
|
"description": "back.object.models",
|
|
|
|
|
"peekOfCode": "class Element3D(models.Model):\n model_file = models.FileField(upload_to=group_based_upload_to)\n name = models.CharField(max_length=255)\n description = models.TextField()\n def __str__(self):\n return self.name\nclass ClickableArea(models.Model):\n name = models.CharField(max_length=255)\n description = models.TextField()\n object_name = models.CharField(max_length=255)",
|
|
|
|
|
"peekOfCode": "class Element3D(models.Model):\n parent = models.ForeignKey(\"self\", on_delete=models.PROTECT, null=True)\n model_file = models.FileField(upload_to=group_based_upload_to)\n name = models.CharField(max_length=255)\n description = models.TextField()\n def __str__(self):\n return self.name\nclass ClickableArea(models.Model):\n name = models.CharField(max_length=255)\n description = models.TextField()",
|
|
|
|
|
"detail": "back.object.models",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
@ -854,7 +1022,7 @@
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.object.models",
|
|
|
|
|
"description": "back.object.models",
|
|
|
|
|
"peekOfCode": "class ClickableArea(models.Model):\n name = models.CharField(max_length=255)\n description = models.TextField()\n object_name = models.CharField(max_length=255)\n target = models.ForeignKey(Element3D, on_delete=models.CASCADE, related_name='clickable_areas')\n def __str__(self):\n return self.name",
|
|
|
|
|
"peekOfCode": "class ClickableArea(models.Model):\n name = models.CharField(max_length=255)\n description = models.TextField()\n object_name = models.CharField(max_length=255)\n target = models.ForeignKey(\n Element3D, on_delete=models.CASCADE, related_name=\"clickable_areas\"\n )\n def __str__(self):\n return self.name",
|
|
|
|
|
"detail": "back.object.models",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
@ -863,7 +1031,7 @@
|
|
|
|
|
"kind": 2,
|
|
|
|
|
"importPath": "back.object.models",
|
|
|
|
|
"description": "back.object.models",
|
|
|
|
|
"peekOfCode": "def group_based_upload_to(instance, filename):\n logger.info(instance)\n return \"files/image/{}/{}/{}\".format(\n type(instance).__name__.lower(), instance.id, filename\n )\nclass Element3D(models.Model):\n model_file = models.FileField(upload_to=group_based_upload_to)\n name = models.CharField(max_length=255)\n description = models.TextField()\n def __str__(self):",
|
|
|
|
|
"peekOfCode": "def group_based_upload_to(instance, filename):\n logger.info(instance)\n return \"files/image/{}/{}/{}\".format(\n type(instance).__name__.lower(), instance.id, filename\n )\nclass Element3D(models.Model):\n parent = models.ForeignKey(\"self\", on_delete=models.PROTECT, null=True)\n model_file = models.FileField(upload_to=group_based_upload_to)\n name = models.CharField(max_length=255)\n description = models.TextField()",
|
|
|
|
|
"detail": "back.object.models",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
@ -872,10 +1040,46 @@
|
|
|
|
|
"kind": 5,
|
|
|
|
|
"importPath": "back.object.models",
|
|
|
|
|
"description": "back.object.models",
|
|
|
|
|
"peekOfCode": "logger = logging.getLogger(\"root\")\ndef group_based_upload_to(instance, filename):\n logger.info(instance)\n return \"files/image/{}/{}/{}\".format(\n type(instance).__name__.lower(), instance.id, filename\n )\nclass Element3D(models.Model):\n model_file = models.FileField(upload_to=group_based_upload_to)\n name = models.CharField(max_length=255)\n description = models.TextField()",
|
|
|
|
|
"peekOfCode": "logger = logging.getLogger(\"root\")\ndef group_based_upload_to(instance, filename):\n logger.info(instance)\n return \"files/image/{}/{}/{}\".format(\n type(instance).__name__.lower(), instance.id, filename\n )\nclass Element3D(models.Model):\n parent = models.ForeignKey(\"self\", on_delete=models.PROTECT, null=True)\n model_file = models.FileField(upload_to=group_based_upload_to)\n name = models.CharField(max_length=255)",
|
|
|
|
|
"detail": "back.object.models",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "Element3DSerializer",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.object.serializers",
|
|
|
|
|
"description": "back.object.serializers",
|
|
|
|
|
"peekOfCode": "class Element3DSerializer(serializers.ModelSerializer):\n model_file = serializers.ImageField(use_url=False)\n class Meta:\n model = Element3D\n fields = \"__all__\"\nclass ClickableAreaSerializer(serializers.ModelSerializer):\n class Meta:\n model = ClickableArea\n fields = \"__all__\"",
|
|
|
|
|
"detail": "back.object.serializers",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "ClickableAreaSerializer",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.object.serializers",
|
|
|
|
|
"description": "back.object.serializers",
|
|
|
|
|
"peekOfCode": "class ClickableAreaSerializer(serializers.ModelSerializer):\n class Meta:\n model = ClickableArea\n fields = \"__all__\"",
|
|
|
|
|
"detail": "back.object.serializers",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "ClickableAreaViewSet",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.object.views",
|
|
|
|
|
"description": "back.object.views",
|
|
|
|
|
"peekOfCode": "class ClickableAreaViewSet(viewsets.ModelViewSet):\n queryset = ClickableArea.objects.all()\n serializer_class = ClickableAreaSerializer\nclass Element3DViewSet(viewsets.ModelViewSet):\n queryset = Element3D.objects.all()\n serializer_class = Element3DSerializer",
|
|
|
|
|
"detail": "back.object.views",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "Element3DViewSet",
|
|
|
|
|
"kind": 6,
|
|
|
|
|
"importPath": "back.object.views",
|
|
|
|
|
"description": "back.object.views",
|
|
|
|
|
"peekOfCode": "class Element3DViewSet(viewsets.ModelViewSet):\n queryset = Element3D.objects.all()\n serializer_class = Element3DSerializer",
|
|
|
|
|
"detail": "back.object.views",
|
|
|
|
|
"documentation": {}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
"label": "main",
|
|
|
|
|
"kind": 2,
|
|
|
|
|