cancel
Showing results for 
Search instead for 
Did you mean: 

Help: customizing explorer

sbudrez
Champ in-the-making
Champ in-the-making
Hi to all!

I have downloaded and istalled alfresco community edition 3.2
I've read the "tutorial" (the .pdf file named "Getting_Started_with_Explorer_DM_for_Alfresco_Community_Edition_3_2") and learned the basic customizations (like creating spaces or content rules). I was wondering if there's a way to do this operation outside alfresco itself, for example editing text in some kind of configuration file. Is this possible?

Thanks for any help  :roll:
24 REPLIES 24

norgan
Champ in-the-making
Champ in-the-making
That would be called a developement environment Smiley Happy Best start with Jeff Potts excellent blog http://www.ecmarchitect.com and work through the tutorials there Smiley Happy

Regards, Norgan

sbudrez
Champ in-the-making
Champ in-the-making
Woa thanks a lot!
The guides on the blog you've linked are really useful  Smiley Happy
I'll take some time on it…

But i have a serious problem: my alfresco server startup time is way too long =(
I've already posted it here:
http://forums.alfresco.com/en/viewtopic.php?f=8&t=21806

Maybe you can give me some help?

sbudrez
Champ in-the-making
Champ in-the-making
It seems i have solved the "slow startup" problem  Smiley Happy

I've started reading the first guide: "Working with custom content types", but I have some problems.
I've created the files "someco-model-context.xml" and "scModel.xml" and placed into my "extension" folder. Then as the guide says I restart the alfresco server, but it get's a problem. The problem is in the form of "Could not import bootstrap model" as mentioned in the guide, but it doesn't suggest a solution to avoid it =(

I've also read these guides were developed for an older version of alfresco, maybe they are out-of-date? Can i find some updates somewhere?

I've even tried to find on the blog an email address to contact Jeff Potts, but i wasn't able to find it   Smiley Indifferent

norgan
Champ in-the-making
Champ in-the-making
Hi,
when alfresco refueses to load a custom model, unfortunately, the error messages are hard to find, if there at all. first of all - some errormessages hide somewhere close to the end of the stack trace, roughly 20 - 40 lines fom the bottom, not as usual right on the top.

Then, it might happen, that you have problems switching between character encodings (UTF8, Ansi, Codepages …)
last is typos - the examples themselves are fine and work - I just tried them myself. Settings up eclipse to use UTF-8 only helps a lot !

sbudrez
Champ in-the-making
Champ in-the-making
Well i must admit i am completely a novice  Smiley Indifferent
Firts of all thanks for the patience you have with me  :roll:

Eclipse? I didn't know this software. I see it offers a lot of functions… but i don't exactly understand how can it be helpful.
I suppose just for editing XML files, am i wrong? (I must admit creating XML files with notepad maybe wasn't the best choice…)
I see there are a lot of version of eclipse. I've downloaded the "Eclipse IDE for Java Developers", because the description mentioned an XML Editor. But it seems i can't understand how it works. It's the correct version for my purpose??

What do you mean with "typos"?

I've located the error. It says:

10:06:42,093  ERROR [web.context.ContextLoader] Context initialization failed
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'extension.dictionaryBootstrap' defined in file
[C:\Programmi\Alfresco\tomcat\webapps\alfresco\WEB-INF\classes\alfresco\extension\someco-model-context.xml]: Invocation of init method failed;
nested exception is org.alfresco.service.cmr.dictionary.DictionaryException: 08220001 Could not import bootstrap model alfresco/extension/scModel.xml

Caused by: org.alfresco.service.cmr.dictionary.DictionaryException: 08220001 Could not import bootstrap model alfresco/extension/scModel.xml

Caused by: org.jibx.runtime.JiBXException: Expected "{http://www.alfresco.org/model/dictionary/1.0}type" end tag, found "{http://www.alfresco.org/model/dictionary/1.0}mandatoryaspects" start tag (line 42, col 31)

22-set-2009 10.06.43 org.apache.catalina.core.StandardContext start
GRAVE: Error listenerStart
22-set-2009 10.06.43 org.apache.catalina.core.StandardContext start
GRAVE: Context [/alfresco] startup failed due to previous errors
log4j:ERROR LogMananger.repositorySelector was null likely due to error in class
reloading, using NOPLoggerRepository.

INFO: Server startup in 73293 ms

jayjayecl
Confirmed Champ
Confirmed Champ
could you provide us with your model file?

sbudrez
Champ in-the-making
Champ in-the-making
I have copied the model file as it was from the guide (http://ecmarchitect.com/images/articles/alfresco-content/content-article.pdf)
I've done a copy/paste (altough it doesn't work well, because some charcater like "-" aren't copied and i had to insert them manually)

Anyway here's the file:

<?xml version="1.0" encoding="UTF-8"?>
<!– Definition of new Model –>
<model name="sc:somecomodel" xmlns="http://www.alfresco.org/model/dictionary/1.0">

    <!– Optional meta-data about the model –>
    <description>Someco Model</description>
    <author>Optaros</author>
    <version>1.0</version>

    <!– Imports are required to allow references to definitions in other models –>
    <imports>
        <!–Import Alfresco Dictionary Definitions –>
        <import uri="http://www.alfresco.org/model/dictionary/1.0" prefix="d" />
        <!–Import Alfresco Content Domain Model Definitions –>
        <import uri="http://www.alfresco.org/model/content/1.0" prefix="cm" />
    </imports>

    <!– Introduction of new namespaces defined by this model –>
    <namespaces>
        <namespace uri="http://www.someco.com/model/content/1.0" prefix="sc" />
    </namespaces>

    <types>
        <!– Enterprise-wide generic document type –>
        <type name="sc:doc">
            <title>Someco Document</title>
            <parent>cm:content</parent>
            <associations>
                <association name="sc:relatedDocuments">
                    <title>Related Documents</title>
                    <source>
                        <mandatory>false</mandatory>
                        <many>true</many>
                    </source>
                    <target>
                        <class>sc:doc</class>
                        <mandatory>false</mandatory>
                        <many>true</many>
                    </target>
                </association>
            </associations>
            <mandatoryaspects>
                <aspect>cm:generalclassifiable</aspect>
            </mandatoryaspects>
        </type>

        <type name="sc:whitepaper">
            <title>Someco Whitepaper</title>
            <parent>sc:doc</parent>
        </type>
    </types>

    <aspects>
        <aspect name="sc:webable">
            <title>Someco Webable</title>
            <properties>
                <property name="sc:published">
                    <type>d:date</type>
                </property>
                <property name="sc:isActive">
                    <type>d:boolean</type>
                    <default>false</default>
                </property>
            </properties>
        </aspect>
            <aspect name="sc:productRelated">
            <title>Someco Product Metadata</title>
            <properties>
                <property name="sc:product">
                    <type>d:text</type>
                    <mandatory>true</mandatory>
                </property>
                <property name="sc:version">
                    <type>d:text</type>
                    <mandatory>true</mandatory>
                </property>
            </properties>
        </aspect>
    </aspects>
</model>

jayjayecl
Confirmed Champ
Confirmed Champ
replace "mandatoryaspects" with "mandatory-aspects"

sbudrez
Champ in-the-making
Champ in-the-making
:shock:
I can't believe it. I've checked the text so many times and i've never noticed THAT!
I feel so stupid  :lol:
Thanks a lot

PS: Is there a way to copy and paste from a .pdf file without losing part of the text?