{
    "description": "GPSR",
    "domaine": "",
    "email": "",
    "groups": [
        {
            "description": "GPSR Daten",
            "entries": [
                {
                    "description": "GPSR001 - Prüfe Modulangabe",
                    "errorMessage": "",
                    "expresion": "var artikelStatus = Article.getData(\"STATUS\");\nvar UmverpackungsEAN = Article.getData(\"UMVERPACKUNGEAN\");\nerror = true;\nerrorHealtyRelatedStatement = false;\nerrorHazardStatement = false;\nerrorPrecautionaryStatement = false;\nerrorGhsStatement = false;\n\nif (UmverpackungsEAN || artikelStatus == '91E'){\n\treturn true\n};\n\nvar productModulesList = Article.getList(\"ProductModulesList\");\n\nif (productModulesList.count() == 0){\n\t\n\tArticle.addError(\"Der Artikel besitzt keine Angaben zu den GPSR relevanten Hinweisen Warn- Gefahren, Sicherheitshinweise bzw. GHS Piktogramme\", -1);\n\treturn false\n};\n\nfor (var i = 0; i < productModulesList.count(); i++){\n\n\tvar productModulesList_i = productModulesList.at(i);\n\tvar productModulesListAttID = productModulesList_i.getData(\"AttID\");\n\tvar productModulesListValue = productModulesList_i.getData(\"Value\");\n\t\n\tif (productModulesListAttID == 'healtyRelatedStatement'){\n\t\n\t\terrorHealtyRelatedStatement = true\n\t};\n\t\n\tif (productModulesListAttID == 'hazardStatement'){\n\t\n\t\terrorHazardStatement = true\n\t};\n\t\n\tif (productModulesListAttID == 'precautionaryStatement'){\n\t\n\t\terrorPrecautionaryStatement = true;\n\t};\n\t\n\tif (productModulesListAttID == 'ghsStatement'){\n\t\n\t\terrorGhsStatement = true\n\t};\n\t\n\tif (!productModulesListAttID){\n\t\n\t\terror = false;\n\t\tArticle.addError(\"Unvollständige Angabe bei den Hinweisen - Keine Angabe 'AttID' beim Eintrag '\" + productModulesListValue +\"' vorhanden\", -1)\n\t};\n\t\n\tif (!productModulesListValue){\n\t\n\t\terror = false;\n\t\tArticle.addError(\"Unvollständige Angabe bei den Hinweisen - Keine Angabe 'Value' beim Typ '\" + productModulesListAttID +\"' vorhanden\", -1)\n\t};\n};\n\n\nif (errorHealtyRelatedStatement == false){\n\n\terror = false;\n\tArticle.addError(\"Fehlende Angabe - Keine Angabe 'healtyRelatedStatement - gesundheitsbezogene Angaben' vorhanden\", -1)\n};\n\nif (errorHazardStatement == false){\n\n\terror = false;\n\tArticle.addError(\"Fehlende Angabe - Keine Angabe 'hazardStatement - Gefahrenhinweise' vorhanden\", -1)\n};\n\nif (errorPrecautionaryStatement == false){\n\n\terror = false;\n\tArticle.addError(\"Fehlende Angabe - Keine Angabe 'precautionaryStatement - Sicherheitshinweise' vorhanden\", -1)\n};\n\nif (errorGhsStatement == false){\n\n\terror = false;\n\tArticle.addError(\"Fehlende Angabe - Keine Angabe 'ghsStatement - ghs Angaben' vorhanden\", -1)\n};\n\nreturn error;",
                    "finalScript": "(function(){ var artikelStatus = Article.getData(\"STATUS\");\nvar UmverpackungsEAN = Article.getData(\"UMVERPACKUNGEAN\");\nerror = true;\nerrorHealtyRelatedStatement = false;\nerrorHazardStatement = false;\nerrorPrecautionaryStatement = false;\nerrorGhsStatement = false;\n\nif (UmverpackungsEAN || artikelStatus == '91E'){\n\treturn true\n};\n\nvar productModulesList = Article.getList(\"ProductModulesList\");\n\nif (productModulesList.count() == 0){\n\t\n\tArticle.addError(\"Der Artikel besitzt keine Angaben zu den GPSR relevanten Hinweisen Warn- Gefahren, Sicherheitshinweise bzw. GHS Piktogramme\", -1);\n\treturn false\n};\n\nfor (var i = 0; i < productModulesList.count(); i++){\n\n\tvar productModulesList_i = productModulesList.at(i);\n\tvar productModulesListAttID = productModulesList_i.getData(\"AttID\");\n\tvar productModulesListValue = productModulesList_i.getData(\"Value\");\n\t\n\tif (productModulesListAttID == 'healtyRelatedStatement'){\n\t\n\t\terrorHealtyRelatedStatement = true\n\t};\n\t\n\tif (productModulesListAttID == 'hazardStatement'){\n\t\n\t\terrorHazardStatement = true\n\t};\n\t\n\tif (productModulesListAttID == 'precautionaryStatement'){\n\t\n\t\terrorPrecautionaryStatement = true;\n\t};\n\t\n\tif (productModulesListAttID == 'ghsStatement'){\n\t\n\t\terrorGhsStatement = true\n\t};\n\t\n\tif (!productModulesListAttID){\n\t\n\t\terror = false;\n\t\tArticle.addError(\"Unvollständige Angabe bei den Hinweisen - Keine Angabe 'AttID' beim Eintrag '\" + productModulesListValue +\"' vorhanden\", -1)\n\t};\n\t\n\tif (!productModulesListValue){\n\t\n\t\terror = false;\n\t\tArticle.addError(\"Unvollständige Angabe bei den Hinweisen - Keine Angabe 'Value' beim Typ '\" + productModulesListAttID +\"' vorhanden\", -1)\n\t};\n};\n\n\nif (errorHealtyRelatedStatement == false){\n\n\terror = false;\n\tArticle.addError(\"Fehlende Angabe - Keine Angabe 'healtyRelatedStatement - gesundheitsbezogene Angaben' vorhanden\", -1)\n};\n\nif (errorHazardStatement == false){\n\n\terror = false;\n\tArticle.addError(\"Fehlende Angabe - Keine Angabe 'hazardStatement - Gefahrenhinweise' vorhanden\", -1)\n};\n\nif (errorPrecautionaryStatement == false){\n\n\terror = false;\n\tArticle.addError(\"Fehlende Angabe - Keine Angabe 'precautionaryStatement - Sicherheitshinweise' vorhanden\", -1)\n};\n\nif (errorGhsStatement == false){\n\n\terror = false;\n\tArticle.addError(\"Fehlende Angabe - Keine Angabe 'ghsStatement - ghs Angaben' vorhanden\", -1)\n};\n\nreturn error;})",
                    "groupId": "42a12b50-adb1-11ef-98b9-612c5e80c86b",
                    "id": "70f9a400-adb1-11ef-ae0e-01df2ac2d8f8",
                    "name": "GPSR001 - Prüfe Modulangabe",
                    "variables": [
                    ],
                    "version": 1
                },
                {
                    "description": "GPSR004 - Prüfe Land bei GPSR",
                    "errorMessage": "",
                    "expresion": "error = true;\n\nvar regulationList = Article.getList(\"RegulationList\");\n\nif (regulationList.count() == 0) {\n\treturn true\n}\n\nfor (var i = 0; i < regulationList.count(); i++){\n\t\n\tvar regulationList_i = regulationList.at(i);\n\tvar regulationListCountry = regulationList_i.getData(\"CountryId\");\n\t\n\tif (!regulationListCountry){\n\t\terror = false;\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag bei den Hinweisen, aber ohne eine (gültige) Angabe Land.\", -1)\n\t}\n}\n\nreturn error;\n",
                    "finalScript": "(function(){ error = true;\n\nvar regulationList = Article.getList(\"RegulationList\");\n\nif (regulationList.count() == 0) {\n\treturn true\n}\n\nfor (var i = 0; i < regulationList.count(); i++){\n\t\n\tvar regulationList_i = regulationList.at(i);\n\tvar regulationListCountry = regulationList_i.getData(\"CountryId\");\n\t\n\tif (!regulationListCountry){\n\t\terror = false;\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag bei den Hinweisen, aber ohne eine (gültige) Angabe Land.\", -1)\n\t}\n}\n\nreturn error;\n})",
                    "groupId": "42a12b50-adb1-11ef-98b9-612c5e80c86b",
                    "id": "8a73e210-d27d-11ef-ad32-d90890a60b64",
                    "name": "GPSR004 - Prüfe Land bei den Hinweisen",
                    "variables": [
                    ],
                    "version": 1
                },
                {
                    "description": "GPSR003 - Prüfe Hinweise auf Vollständigkeit",
                    "errorMessage": "",
                    "expresion": "error = true;\n\nvar regulationList = Article.getList(\"RegulationList\");\n\n\nfor (var i = 0; i < regulationList.count(); i++){\n\n\tvar regulationList_i = regulationList.at(i);\n\t\n\tvar regulationListCountry = regulationList_i.getData(\"CountryId\");\n\tvar healtyRelatedStatementList = regulationList_i.getList(\"CompulsoryAdditiveLabelInformationList\");\n\tvar hazardStatementList = regulationList_i.getList(\"HazardStatementList\");\n\tvar precautionaryStatementList = regulationList_i.getList(\"PrecautionaryStatementList\");\n\tvar ghsSymbolDescriptionList = regulationList_i.getList(\"GhsSymbolDescriptionList\");\n\t\n\tfor (var j = 0; j < healtyRelatedStatementList.count(); j++){\n\t\t\n\t\tvar healtyRelatedStatementList_j = healtyRelatedStatementList.at(j);\n\t\tvar healtyRelatedStatementListSprache = healtyRelatedStatementList_j.getData(\"LocaleId\");\n\t\tvar healtyRelatedStatementListValue = healtyRelatedStatementList_j.getData(\"Value\");\n\t\t\n\t\tif (!healtyRelatedStatementListSprache || healtyRelatedStatementListSprache == 1){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Warnhinweis, aber ohne eine (gültige) Sprachangabe. Land: '\" + regulationListCountry + \"' | Wert: '\" + healtyRelatedStatementListValue + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (!healtyRelatedStatementListValue){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Warnhinweis, aber ohne einen Wert. Land: '\" + regulationListCountry + \"' | Sprache: '\" + healtyRelatedStatementListSprache + \"'\", -1);\n\t\t\terror = false\n\t\t}\n\t};\n\t\n\tfor (var k = 0; k < hazardStatementList.count(); k++){\n\t\t\n\t\tvar hazardStatementList_k = hazardStatementList.at(k);\n\t\tvar hazardStatementListSprache = hazardStatementList_k.getData(\"LocaleId\");\n\t\tvar hazardStatementListValue = hazardStatementList_k.getData(\"Value\");\n\t\tvar hazardStatementListCode = hazardStatementList_k.getData(\"code\");\n\t\t\n\t\tif (hazardStatementListValue && (!hazardStatementListSprache || hazardStatementListSprache == 1)){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Gefahrenhinweis, aber ohne eine (gültige) Sprachangabe. Land: '\" + regulationListCountry + \"' | Wert: '\" + hazardStatementListValue + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (hazardStatementListSprache && !hazardStatementListValue){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Gefahrenhinweis, aber ohne einen Wert. Land: '\" + regulationListCountry + \"' | Sprache: '\" + hazardStatementListSprache + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (!hazardStatementListCode){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Gefahrenhinweis, aber ohne eine Angabe Code. Land: '\" + regulationListCountry + \"'\", -1);\n\t\t\terror = false\n\t\t}\n\t};\n\t\n\tfor (var l = 0; l < precautionaryStatementList.count(); l++){\n\t\t\n\t\tvar precautionaryStatementList_l = precautionaryStatementList.at(l);\n\t\tvar precautionaryStatementListSprache = precautionaryStatementList_l.getData(\"LocaleId\");\n\t\tvar precautionaryStatementListValue = precautionaryStatementList_l.getData(\"Value\");\n\t\tvar precautionaryStatementListCode = precautionaryStatementList_l.getData(\"code\");\n\t\t\n\t\tif (precautionaryStatementListValue && (!precautionaryStatementListSprache || precautionaryStatementListSprache == 1)){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Sicherheitshinweis, aber ohne eine (gültige) Sprachangabe. Land: '\" + regulationListCountry + \"' | Wert: '\" + precautionaryStatementListValue + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (precautionaryStatementListSprache && !precautionaryStatementListValue){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Sicherheitshinweis, aber ohne einen Wert. Land: '\" + regulationListCountry + \"' | Sprache: '\" + precautionaryStatementListSprache + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (!precautionaryStatementListCode){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Sicherheitshinweis, aber ohne eine Angabe Code. Land: '\" + regulationListCountry + \"'\", -1);\n\t\t\terror = false\n\t\t}\n\t};\n\t\n\tfor (var m = 0; m < ghsSymbolDescriptionList.count(); m++){\n\t\t\n\t\tvar ghsSymbolDescriptionList_m = ghsSymbolDescriptionList.at(m);\n\t\tvar ghsSymbolDescriptionListSprache = ghsSymbolDescriptionList_m.getData(\"LocaleId\");\n\t\tvar ghsSymbolDescriptionListValue = ghsSymbolDescriptionList_m.getData(\"Value\");\n\t\tvar ghsSymbolDescriptionListCode = ghsSymbolDescriptionList_m.getData(\"code\");\n\t\t\n\t\tif (ghsSymbolDescriptionListValue && (!ghsSymbolDescriptionListSprache || ghsSymbolDescriptionListSprache == 1)){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag GHS Piktogramm, aber ohne eine (gültige) Sprachangabe. Land: '\" + regulationListCountry + \"' | Wert: '\" + ghsSymbolDescriptionListValue + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (ghsSymbolDescriptionListSprache && !ghsSymbolDescriptionListValue){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag GHS Piktogramm, aber ohne einen Wert. Land: '\" + regulationListCountry + \"' | Sprache: '\" + ghsSymbolDescriptionListSprache + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (!ghsSymbolDescriptionListCode){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag GHS Piktogramm, aber ohne eine Angabe Code. Land: '\" + regulationListCountry + \"'\", -1);\n\t\t\terror = false\n\t\t}\n\t};\n}\n\n\nreturn error;",
                    "finalScript": "(function(){ error = true;\n\nvar regulationList = Article.getList(\"RegulationList\");\n\n\nfor (var i = 0; i < regulationList.count(); i++){\n\n\tvar regulationList_i = regulationList.at(i);\n\t\n\tvar regulationListCountry = regulationList_i.getData(\"CountryId\");\n\tvar healtyRelatedStatementList = regulationList_i.getList(\"CompulsoryAdditiveLabelInformationList\");\n\tvar hazardStatementList = regulationList_i.getList(\"HazardStatementList\");\n\tvar precautionaryStatementList = regulationList_i.getList(\"PrecautionaryStatementList\");\n\tvar ghsSymbolDescriptionList = regulationList_i.getList(\"GhsSymbolDescriptionList\");\n\t\n\tfor (var j = 0; j < healtyRelatedStatementList.count(); j++){\n\t\t\n\t\tvar healtyRelatedStatementList_j = healtyRelatedStatementList.at(j);\n\t\tvar healtyRelatedStatementListSprache = healtyRelatedStatementList_j.getData(\"LocaleId\");\n\t\tvar healtyRelatedStatementListValue = healtyRelatedStatementList_j.getData(\"Value\");\n\t\t\n\t\tif (!healtyRelatedStatementListSprache || healtyRelatedStatementListSprache == 1){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Warnhinweis, aber ohne eine (gültige) Sprachangabe. Land: '\" + regulationListCountry + \"' | Wert: '\" + healtyRelatedStatementListValue + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (!healtyRelatedStatementListValue){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Warnhinweis, aber ohne einen Wert. Land: '\" + regulationListCountry + \"' | Sprache: '\" + healtyRelatedStatementListSprache + \"'\", -1);\n\t\t\terror = false\n\t\t}\n\t};\n\t\n\tfor (var k = 0; k < hazardStatementList.count(); k++){\n\t\t\n\t\tvar hazardStatementList_k = hazardStatementList.at(k);\n\t\tvar hazardStatementListSprache = hazardStatementList_k.getData(\"LocaleId\");\n\t\tvar hazardStatementListValue = hazardStatementList_k.getData(\"Value\");\n\t\tvar hazardStatementListCode = hazardStatementList_k.getData(\"code\");\n\t\t\n\t\tif (hazardStatementListValue && (!hazardStatementListSprache || hazardStatementListSprache == 1)){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Gefahrenhinweis, aber ohne eine (gültige) Sprachangabe. Land: '\" + regulationListCountry + \"' | Wert: '\" + hazardStatementListValue + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (hazardStatementListSprache && !hazardStatementListValue){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Gefahrenhinweis, aber ohne einen Wert. Land: '\" + regulationListCountry + \"' | Sprache: '\" + hazardStatementListSprache + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (!hazardStatementListCode){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Gefahrenhinweis, aber ohne eine Angabe Code. Land: '\" + regulationListCountry + \"'\", -1);\n\t\t\terror = false\n\t\t}\n\t};\n\t\n\tfor (var l = 0; l < precautionaryStatementList.count(); l++){\n\t\t\n\t\tvar precautionaryStatementList_l = precautionaryStatementList.at(l);\n\t\tvar precautionaryStatementListSprache = precautionaryStatementList_l.getData(\"LocaleId\");\n\t\tvar precautionaryStatementListValue = precautionaryStatementList_l.getData(\"Value\");\n\t\tvar precautionaryStatementListCode = precautionaryStatementList_l.getData(\"code\");\n\t\t\n\t\tif (precautionaryStatementListValue && (!precautionaryStatementListSprache || precautionaryStatementListSprache == 1)){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Sicherheitshinweis, aber ohne eine (gültige) Sprachangabe. Land: '\" + regulationListCountry + \"' | Wert: '\" + precautionaryStatementListValue + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (precautionaryStatementListSprache && !precautionaryStatementListValue){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Sicherheitshinweis, aber ohne einen Wert. Land: '\" + regulationListCountry + \"' | Sprache: '\" + precautionaryStatementListSprache + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (!precautionaryStatementListCode){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag Sicherheitshinweis, aber ohne eine Angabe Code. Land: '\" + regulationListCountry + \"'\", -1);\n\t\t\terror = false\n\t\t}\n\t};\n\t\n\tfor (var m = 0; m < ghsSymbolDescriptionList.count(); m++){\n\t\t\n\t\tvar ghsSymbolDescriptionList_m = ghsSymbolDescriptionList.at(m);\n\t\tvar ghsSymbolDescriptionListSprache = ghsSymbolDescriptionList_m.getData(\"LocaleId\");\n\t\tvar ghsSymbolDescriptionListValue = ghsSymbolDescriptionList_m.getData(\"Value\");\n\t\tvar ghsSymbolDescriptionListCode = ghsSymbolDescriptionList_m.getData(\"code\");\n\t\t\n\t\tif (ghsSymbolDescriptionListValue && (!ghsSymbolDescriptionListSprache || ghsSymbolDescriptionListSprache == 1)){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag GHS Piktogramm, aber ohne eine (gültige) Sprachangabe. Land: '\" + regulationListCountry + \"' | Wert: '\" + ghsSymbolDescriptionListValue + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (ghsSymbolDescriptionListSprache && !ghsSymbolDescriptionListValue){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag GHS Piktogramm, aber ohne einen Wert. Land: '\" + regulationListCountry + \"' | Sprache: '\" + ghsSymbolDescriptionListSprache + \"'\", -1);\n\t\t\terror = false\n\t\t};\n\t\t\n\t\tif (!ghsSymbolDescriptionListCode){\n\n\t\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag GHS Piktogramm, aber ohne eine Angabe Code. Land: '\" + regulationListCountry + \"'\", -1);\n\t\t\terror = false\n\t\t}\n\t};\n}\n\n\nreturn error;})",
                    "groupId": "42a12b50-adb1-11ef-98b9-612c5e80c86b",
                    "id": "a1915e10-ae50-11ef-941e-09e4000dd310",
                    "name": "GPSR003 - Prüfe Hinweise auf Vollständigkeit",
                    "variables": [
                    ],
                    "version": 1
                },
                {
                    "description": "GPSR002 - Prüfe Hinweise vorhanden",
                    "errorMessage": "",
                    "expresion": "var artikelStatus = Article.getData(\"STATUS\");\nvar UmverpackungsEAN = Article.getData(\"UMVERPACKUNGEAN\");\nerror = true;\nhealtyRelatedStatement = 0;\nhazardStatement = 0;\nprecautionaryStatement = 0;\nghsStatement = 0;\nstatement = 0;\n\nif (UmverpackungsEAN || artikelStatus == '91E'){\n\treturn true\n};\n\nvar productModulesList = Article.getList(\"ProductModulesList\");\n\nfor (var i = 0; i < productModulesList.count(); i++){\n\n\tvar productModulesList_i = productModulesList.at(i);\n\tvar productModulesListAttID = productModulesList_i.getData(\"AttID\");\n\tvar productModulesListValue = productModulesList_i.getData(\"Value\");\n\t\n\tif (productModulesListAttID == 'healtyRelatedStatement' && productModulesListValue == 'TRUE'){\n\t\n\t\thealtyRelatedStatement = 1;\n\t\tstatement = 1\n\t};\n\t\n\tif (productModulesListAttID == 'hazardStatement' && productModulesListValue == 'TRUE'){\n\t\n\t\thazardStatement = 1;\n\t\tstatement = 1\n\t};\n\t\n\tif (productModulesListAttID == 'precautionaryStatement' && productModulesListValue == 'TRUE'){\n\t\n\t\tprecautionaryStatement = 1;\n\t\tstatement = 1\n\t};\n\t\n\tif (productModulesListAttID == 'ghsStatement' && productModulesListValue == 'TRUE'){\n\t\n\t\tghsStatement = 1;\n\t\tstatement = 1\n\t};\n};\n\n\nvar regulationList = Article.getList(\"RegulationList\");\n\nif (statement == '1' && regulationList.count() == 0){\n\t\n\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag in der Liste mit Warn- Gefahren, Sicherheitshinweise bzw. GHS Piktogramme 'TRUE', aber keinen Eintrag bei den Hinweislisten\", -1);\n\treturn false\n};\n\n\n\nfor (var k = 0; k < regulationList.count(); k++){\n\n\tvar regulationList_k = regulationList.at(k);\n\t\n\tvar regulationListCountry = regulationList_k.getData(\"CountryId\");\n\tvar healtyRelatedStatementList = regulationList_k.getList(\"CompulsoryAdditiveLabelInformationList\");\n\tvar hazardStatementList = regulationList_k.getList(\"HazardStatementList\");\n\tvar recautionaryStatementList = regulationList_k.getList(\"PrecautionaryStatementList\");\n\tvar ghsSymbolDescriptionList = regulationList_k.getList(\"GhsSymbolDescriptionList\");\n\n\tif (healtyRelatedStatement == 1 && healtyRelatedStatementList.count() == 0){\n\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag mit Warnhinweis 'TRUE', aber keinen Warnhinweis beim Land '\" + regulationListCountry + \"' \", -1);\n\t\terror = false\n\t};\n\t\n\tif (hazardStatement == 1 && hazardStatementList.count() == 0){\n\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag mit Gefahrenhinweis 'TRUE', aber keinen Gefahrenhinweis beim Land '\" + regulationListCountry + \"' \", -1);\n\t\terror = false\n\t};\n\t\n\tif (precautionaryStatement == 1 && recautionaryStatementList.count() == 0){\n\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag mit Sicherheitshinweis 'TRUE', aber keinen Sicherheitshinweis beim Land '\" + regulationListCountry + \"' \", -1);\n\t\terror = false\n\t};\n\t\n\tif (ghsStatement == 1 && ghsSymbolDescriptionList.count() == 0){\n\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag mit GHS Angabe 'TRUE', aber keine GHS Angabe beim Land '\" + regulationListCountry + \"' \", -1);\n\t\terror = false\n\t};\n}\n\n\nreturn error;",
                    "finalScript": "(function(){ var artikelStatus = Article.getData(\"STATUS\");\nvar UmverpackungsEAN = Article.getData(\"UMVERPACKUNGEAN\");\nerror = true;\nhealtyRelatedStatement = 0;\nhazardStatement = 0;\nprecautionaryStatement = 0;\nghsStatement = 0;\nstatement = 0;\n\nif (UmverpackungsEAN || artikelStatus == '91E'){\n\treturn true\n};\n\nvar productModulesList = Article.getList(\"ProductModulesList\");\n\nfor (var i = 0; i < productModulesList.count(); i++){\n\n\tvar productModulesList_i = productModulesList.at(i);\n\tvar productModulesListAttID = productModulesList_i.getData(\"AttID\");\n\tvar productModulesListValue = productModulesList_i.getData(\"Value\");\n\t\n\tif (productModulesListAttID == 'healtyRelatedStatement' && productModulesListValue == 'TRUE'){\n\t\n\t\thealtyRelatedStatement = 1;\n\t\tstatement = 1\n\t};\n\t\n\tif (productModulesListAttID == 'hazardStatement' && productModulesListValue == 'TRUE'){\n\t\n\t\thazardStatement = 1;\n\t\tstatement = 1\n\t};\n\t\n\tif (productModulesListAttID == 'precautionaryStatement' && productModulesListValue == 'TRUE'){\n\t\n\t\tprecautionaryStatement = 1;\n\t\tstatement = 1\n\t};\n\t\n\tif (productModulesListAttID == 'ghsStatement' && productModulesListValue == 'TRUE'){\n\t\n\t\tghsStatement = 1;\n\t\tstatement = 1\n\t};\n};\n\n\nvar regulationList = Article.getList(\"RegulationList\");\n\nif (statement == '1' && regulationList.count() == 0){\n\t\n\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag in der Liste mit Warn- Gefahren, Sicherheitshinweise bzw. GHS Piktogramme 'TRUE', aber keinen Eintrag bei den Hinweislisten\", -1);\n\treturn false\n};\n\n\n\nfor (var k = 0; k < regulationList.count(); k++){\n\n\tvar regulationList_k = regulationList.at(k);\n\t\n\tvar regulationListCountry = regulationList_k.getData(\"CountryId\");\n\tvar healtyRelatedStatementList = regulationList_k.getList(\"CompulsoryAdditiveLabelInformationList\");\n\tvar hazardStatementList = regulationList_k.getList(\"HazardStatementList\");\n\tvar recautionaryStatementList = regulationList_k.getList(\"PrecautionaryStatementList\");\n\tvar ghsSymbolDescriptionList = regulationList_k.getList(\"GhsSymbolDescriptionList\");\n\n\tif (healtyRelatedStatement == 1 && healtyRelatedStatementList.count() == 0){\n\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag mit Warnhinweis 'TRUE', aber keinen Warnhinweis beim Land '\" + regulationListCountry + \"' \", -1);\n\t\terror = false\n\t};\n\t\n\tif (hazardStatement == 1 && hazardStatementList.count() == 0){\n\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag mit Gefahrenhinweis 'TRUE', aber keinen Gefahrenhinweis beim Land '\" + regulationListCountry + \"' \", -1);\n\t\terror = false\n\t};\n\t\n\tif (precautionaryStatement == 1 && recautionaryStatementList.count() == 0){\n\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag mit Sicherheitshinweis 'TRUE', aber keinen Sicherheitshinweis beim Land '\" + regulationListCountry + \"' \", -1);\n\t\terror = false\n\t};\n\t\n\tif (ghsStatement == 1 && ghsSymbolDescriptionList.count() == 0){\n\n\t\tArticle.addError(\"Der Artikel besitzt mindestens einen Eintrag mit GHS Angabe 'TRUE', aber keine GHS Angabe beim Land '\" + regulationListCountry + \"' \", -1);\n\t\terror = false\n\t};\n}\n\n\nreturn error;})",
                    "groupId": "42a12b50-adb1-11ef-98b9-612c5e80c86b",
                    "id": "df1e85a0-adb5-11ef-a52b-67f01d8f037a",
                    "name": "GPSR002 - Prüfe Hinweise vorhanden",
                    "variables": [
                    ],
                    "version": 1
                }
            ],
            "id": "42a12b50-adb1-11ef-98b9-612c5e80c86b",
            "name": "GPSR Daten"
        }
    ],
    "id": "f5938c40-d27c-11ef-ad82-d7b8c1daad10",
    "logfilePath": "",
    "mergePoolAndAssortmentData": true,
    "name": "GPSR",
    "withoutdeletedarticles": true
}
