summaryrefslogtreecommitdiff
path: root/ishtar_common
diff options
context:
space:
mode:
authorÉtienne Loks <etienne.loks@iggdrasil.net>2020-04-07 12:36:55 +0200
committerÉtienne Loks <etienne.loks@iggdrasil.net>2021-02-28 12:15:20 +0100
commitffedddae0c27f165e9d839edc5421e415b491330 (patch)
treecc2d30385aebb2a7b6d3aebf8dbaa26134617bf0 /ishtar_common
parent0f96790ca2866d205b262c96ddb1b155abb80ef6 (diff)
downloadIshtar-ffedddae0c27f165e9d839edc5421e415b491330.tar.bz2
Ishtar-ffedddae0c27f165e9d839edc5421e415b491330.zip
New container management: change ext id
Diffstat (limited to 'ishtar_common')
-rw-r--r--ishtar_common/migrations/0203_auto_20200407_1142.py20
-rw-r--r--ishtar_common/models.py3
2 files changed, 22 insertions, 1 deletions
diff --git a/ishtar_common/migrations/0203_auto_20200407_1142.py b/ishtar_common/migrations/0203_auto_20200407_1142.py
new file mode 100644
index 000000000..db6cbc50c
--- /dev/null
+++ b/ishtar_common/migrations/0203_auto_20200407_1142.py
@@ -0,0 +1,20 @@
+# -*- coding: utf-8 -*-
+# Generated by Django 1.11.27 on 2020-04-07 11:42
+from __future__ import unicode_literals
+
+from django.db import migrations, models
+
+
+class Migration(migrations.Migration):
+
+ dependencies = [
+ ('ishtar_common', '0202_auto_20200129_1941'),
+ ]
+
+ operations = [
+ migrations.AlterField(
+ model_name='ishtarsiteprofile',
+ name='container_external_id',
+ field=models.TextField(default='{location__external_id}-{container_type__txt_idx}-{parent_id}-{reference}', help_text='Formula to manage container external ID. Change this with care. With incorrect formula, the application might be unusable and import of external data can be destructive.', verbose_name='Container external id'),
+ ),
+ ]
diff --git a/ishtar_common/models.py b/ishtar_common/models.py
index 4b4753fe3..38e5b2fb4 100644
--- a/ishtar_common/models.py
+++ b/ishtar_common/models.py
@@ -2972,7 +2972,8 @@ class IshtarSiteProfile(models.Model, Cached):
"data can be destructive."))
container_external_id = models.TextField(
_("Container external id"),
- default="{responsible__external_id}-{index}",
+ default="{parent_external_id}-{container_type__txt_idx}-"
+ "{reference}",
help_text=_("Formula to manage container external ID. "
"Change this with care. With incorrect formula, the "
"application might be unusable and import of external "