AnsweredAssumed Answered

Classification creation fails with: Missing classification

Question asked by sufo on Feb 4, 2011
Latest reply on Feb 7, 2011 by sufo
I'm trying to create my own classification via the WebScript but it fails with the error message: Missing classification: {travel.agency.model}taclassifiable
I have defined my own model (<namespace uri="travel.agency.model" prefix="ta"/>) in which there is this aspect defined:
      <aspect name="ta:taclassifiable">
         <title>Travel Agency Classifiable</title>
         <parent>cm:classifiable</parent>
         <properties>
            <property name="ta:categories">
               <title>Categories</title>
               <type>d:category</type>
               <mandatory>false</mandatory>
               <multiple>true</multiple>
               <index enabled="true">
                  <atomic>true</atomic>
                  <stored>true</stored>
                  <tokenised>false</tokenised>
               </index>
            </property>        
         </properties>
      </aspect>
When I try to execute this code, it generates above mentioned error:
var categoryRoot = roothome.childByNamePath("categories");
var props = [];
props["view:childName"] = "{travel.agency.model}taclassifiable";
var classification = categoryRoot.createNode("taclassifiable", "cm:category", props, "cm:categories");
Am I missing something?

Outcomes