talk@lists.collectionspace.org

WE HAVE SUNSET THIS LISTSERV - Join us at collectionspace@lyrasislists.org

View all threads

Local Schema Extension: adding a new field in a <repeat>element

SB
Sébastien Brossard
Mon, Aug 6, 2012 2:43 PM

Hi again,

As said in my previous message, a new problem arose with our new structuredDate:

We want to add our new structuredDateSMK element in

<section id="textualInscriptionInformation"><repeat id="textualInscriptionGroupList/textualInscriptionGroup" >

I created a new textualInscriptionSMKGroup in Service (with all the core fields + <xs:element name="inscriptionContentSMKDateGroup" type="structuredDateSMKGroup"/> )

Then in Application:

<section id="textualInscriptionInformation"> <repeat id="textualInscriptionSMKGroupList/textualInscriptionSMKGroup" section="smk">...

(... re-declare all the core fields +

<group id="inscriptionContentSMKDateGroup" ui-type="groupfield/structureddateSMK" primarykey="dateSMKDisplayText" ui-func="cspace.structuredDateSMK" section="smk">
<selector>object-description-inscription-content-date-smk</selector>
</group>

)

The result is:

·        Services works (tested through REST API)

·        JASON packets are correct

·        But when sniffing the xml packet, the <inscriptionContentSMKDateGroup>  is always empty - it seems that the application can't make the link with structureddateSMK.

Chris told me that there should be a simpler way to add a simple field in a <repeat> element than re-creating the whole thing each time, maybe have you got an idea?

Thank you by advance for your help.

Best regards,

Sébastien

Sébastien Brossard
IT-Udvikler
sebastien.brossard@smk.dkmailto:3sebastien.brossard@smk.dkT
Tmailto:3sebastien.brossard@smk.dkT +45 3374 8483

Statens Museum for Kunst
Sølvgade 48-50
DK-1307 København K

T +45 3374 8494
F +45 3374 8404
smk.dkhttp://smk.dk/

[Beskrivelse: Logo_mail]

Hi again, As said in my previous message, a new problem arose with our new structuredDate: We want to add our new structuredDateSMK element in <section id="textualInscriptionInformation"><repeat id="textualInscriptionGroupList/textualInscriptionGroup" > I created a new textualInscriptionSMKGroup in Service (with all the core fields + <xs:element name="inscriptionContentSMKDateGroup" type="structuredDateSMKGroup"/> ) Then in Application: <section id="textualInscriptionInformation"> <repeat id="textualInscriptionSMKGroupList/textualInscriptionSMKGroup" section="smk">... (... re-declare all the core fields + <group id="inscriptionContentSMKDateGroup" ui-type="groupfield/structureddateSMK" primarykey="dateSMKDisplayText" ui-func="cspace.structuredDateSMK" section="smk"> <selector>object-description-inscription-content-date-smk</selector> </group> ) The result is: · Services works (tested through REST API) · JASON packets are correct · But when sniffing the xml packet, the <inscriptionContentSMKDateGroup> is always empty - it seems that the application can't make the link with structureddateSMK. Chris told me that there should be a simpler way to add a simple field in a <repeat> element than re-creating the whole thing each time, maybe have you got an idea? Thank you by advance for your help. Best regards, Sébastien Sébastien Brossard IT-Udvikler sebastien.brossard@smk.dk<mailto:3sebastien.brossard@smk.dkT> T<mailto:3sebastien.brossard@smk.dkT> +45 3374 8483 Statens Museum for Kunst Sølvgade 48-50 DK-1307 København K T +45 3374 8494 F +45 3374 8404 smk.dk<http://smk.dk/> [Beskrivelse: Logo_mail]
RL
Ray Lee
Mon, Aug 6, 2012 5:51 PM

Hi Sébastien,
I ran into this problem in 2.4, and it's detailed in CSPACE-5085. The problem is that even though you've defined inscriptionContentSMKDateGroup as being in the smk schema ("section"), the app layer doesn't understand that all of the fields in the structured date are also in the smk schema. The workaround is to explicitly define all of the fields in the structured date to have section="smk". There's an example of this in the first comment on that jira. Again, this was for 2.4, so there's a chance things are different in 2.3.

Ray

On Aug 6, 2012, at 7:43 AM, Sébastien Brossard wrote:

Hi again,

As said in my previous message, a new problem arose with our new structuredDate:

We want to add our new structuredDateSMK element in

<section id="textualInscriptionInformation"><repeat id="textualInscriptionGroupList/textualInscriptionGroup" >

I created a new textualInscriptionSMKGroup in Service (with all the core fields + <xs:element name="inscriptionContentSMKDateGroup" type="structuredDateSMKGroup"/> )

Then in Application:

<section id="textualInscriptionInformation"> <repeat id="textualInscriptionSMKGroupList/textualInscriptionSMKGroup" section="smk">…

(… re-declare all the core fields +

<group id="inscriptionContentSMKDateGroup" ui-type="groupfield/structureddateSMK" primarykey="dateSMKDisplayText" ui-func="cspace.structuredDateSMK" section="smk">
<selector>object-description-inscription-content-date-smk</selector>
</group>

)

The result is:
·        Services works (tested through REST API)
·        JASON packets are correct
·        But when sniffing the xml packet, the <inscriptionContentSMKDateGroup>  is always empty – it seems that the application can’t make the link with structureddateSMK.

Chris told me that there should be a simpler way to add a simple field in a <repeat> element than re-creating the whole thing each time, maybe have you got an idea?

Thank you by advance for your help.

Best regards,

Sébastien

Sébastien Brossard
IT-Udvikler
sebastien.brossard@smk.dk
T +45 3374 8483

Statens Museum for Kunst
Sølvgade 48-50
DK—1307 København K
T +45 3374 8494
F +45 3374 8404
smk.dk

<image003.jpg>


Talk mailing list
Talk@lists.collectionspace.org
http://lists.collectionspace.org/mailman/listinfo/talk_lists.collectionspace.org

Hi Sébastien, I ran into this problem in 2.4, and it's detailed in CSPACE-5085. The problem is that even though you've defined inscriptionContentSMKDateGroup as being in the smk schema ("section"), the app layer doesn't understand that all of the fields in the structured date are also in the smk schema. The workaround is to explicitly define all of the fields in the structured date to have section="smk". There's an example of this in the first comment on that jira. Again, this was for 2.4, so there's a chance things are different in 2.3. Ray On Aug 6, 2012, at 7:43 AM, Sébastien Brossard wrote: > Hi again, > > As said in my previous message, a new problem arose with our new structuredDate: > > We want to add our new structuredDateSMK element in > > <section id="textualInscriptionInformation"><repeat id="textualInscriptionGroupList/textualInscriptionGroup" > > > I created a new textualInscriptionSMKGroup in Service (with all the core fields + <xs:element name="inscriptionContentSMKDateGroup" type="structuredDateSMKGroup"/> ) > > Then in Application: > > <section id="textualInscriptionInformation"> > <repeat id="textualInscriptionSMKGroupList/textualInscriptionSMKGroup" section="smk">… > > (… re-declare all the core fields + > > <group id="inscriptionContentSMKDateGroup" ui-type="groupfield/structureddateSMK" > primarykey="dateSMKDisplayText" ui-func="cspace.structuredDateSMK" section="smk"> > <selector>object-description-inscription-content-date-smk</selector> > </group> > > ) > > The result is: > · Services works (tested through REST API) > · JASON packets are correct > · But when sniffing the xml packet, the <inscriptionContentSMKDateGroup> is always empty – it seems that the application can’t make the link with structureddateSMK. > > Chris told me that there should be a simpler way to add a simple field in a <repeat> element than re-creating the whole thing each time, maybe have you got an idea? > > Thank you by advance for your help. > > Best regards, > > Sébastien > > > Sébastien Brossard > IT-Udvikler > sebastien.brossard@smk.dk > T +45 3374 8483 > > Statens Museum for Kunst > Sølvgade 48-50 > DK—1307 København K > T +45 3374 8494 > F +45 3374 8404 > smk.dk > > <image003.jpg> > > > _______________________________________________ > Talk mailing list > Talk@lists.collectionspace.org > http://lists.collectionspace.org/mailman/listinfo/talk_lists.collectionspace.org
RL
Ray Lee
Mon, Aug 6, 2012 5:56 PM

Actually, the jira says it affects 2.3, so maybe I saw it there first. In that case, the workaround should work for you!

Thanks,
Ray

On Aug 6, 2012, at 10:51 AM, Ray Lee wrote:

Hi Sébastien,
I ran into this problem in 2.4, and it's detailed in CSPACE-5085. The problem is that even though you've defined inscriptionContentSMKDateGroup as being in the smk schema ("section"), the app layer doesn't understand that all of the fields in the structured date are also in the smk schema. The workaround is to explicitly define all of the fields in the structured date to have section="smk". There's an example of this in the first comment on that jira. Again, this was for 2.4, so there's a chance things are different in 2.3.

Ray

On Aug 6, 2012, at 7:43 AM, Sébastien Brossard wrote:

Hi again,

As said in my previous message, a new problem arose with our new structuredDate:

We want to add our new structuredDateSMK element in

<section id="textualInscriptionInformation"><repeat id="textualInscriptionGroupList/textualInscriptionGroup" >

I created a new textualInscriptionSMKGroup in Service (with all the core fields + <xs:element name="inscriptionContentSMKDateGroup" type="structuredDateSMKGroup"/> )

Then in Application:

<section id="textualInscriptionInformation"> <repeat id="textualInscriptionSMKGroupList/textualInscriptionSMKGroup" section="smk">…

(… re-declare all the core fields +

<group id="inscriptionContentSMKDateGroup" ui-type="groupfield/structureddateSMK" primarykey="dateSMKDisplayText" ui-func="cspace.structuredDateSMK" section="smk">
<selector>object-description-inscription-content-date-smk</selector>
</group>

)

The result is:
·        Services works (tested through REST API)
·        JASON packets are correct
·        But when sniffing the xml packet, the <inscriptionContentSMKDateGroup>  is always empty – it seems that the application can’t make the link with structureddateSMK.

Chris told me that there should be a simpler way to add a simple field in a <repeat> element than re-creating the whole thing each time, maybe have you got an idea?

Thank you by advance for your help.

Best regards,

Sébastien

Sébastien Brossard
IT-Udvikler
sebastien.brossard@smk.dk
T +45 3374 8483

Statens Museum for Kunst
Sølvgade 48-50
DK—1307 København K
T +45 3374 8494
F +45 3374 8404
smk.dk

<image003.jpg>


Talk mailing list
Talk@lists.collectionspace.org
http://lists.collectionspace.org/mailman/listinfo/talk_lists.collectionspace.org

Actually, the jira says it affects 2.3, so maybe I saw it there first. In that case, the workaround should work for you! Thanks, Ray On Aug 6, 2012, at 10:51 AM, Ray Lee wrote: > Hi Sébastien, > I ran into this problem in 2.4, and it's detailed in CSPACE-5085. The problem is that even though you've defined inscriptionContentSMKDateGroup as being in the smk schema ("section"), the app layer doesn't understand that all of the fields in the structured date are also in the smk schema. The workaround is to explicitly define all of the fields in the structured date to have section="smk". There's an example of this in the first comment on that jira. Again, this was for 2.4, so there's a chance things are different in 2.3. > > Ray > > > > On Aug 6, 2012, at 7:43 AM, Sébastien Brossard wrote: > >> Hi again, >> >> As said in my previous message, a new problem arose with our new structuredDate: >> >> We want to add our new structuredDateSMK element in >> >> <section id="textualInscriptionInformation"><repeat id="textualInscriptionGroupList/textualInscriptionGroup" > >> >> I created a new textualInscriptionSMKGroup in Service (with all the core fields + <xs:element name="inscriptionContentSMKDateGroup" type="structuredDateSMKGroup"/> ) >> >> Then in Application: >> >> <section id="textualInscriptionInformation"> >> <repeat id="textualInscriptionSMKGroupList/textualInscriptionSMKGroup" section="smk">… >> >> (… re-declare all the core fields + >> >> <group id="inscriptionContentSMKDateGroup" ui-type="groupfield/structureddateSMK" >> primarykey="dateSMKDisplayText" ui-func="cspace.structuredDateSMK" section="smk"> >> <selector>object-description-inscription-content-date-smk</selector> >> </group> >> >> ) >> >> The result is: >> · Services works (tested through REST API) >> · JASON packets are correct >> · But when sniffing the xml packet, the <inscriptionContentSMKDateGroup> is always empty – it seems that the application can’t make the link with structureddateSMK. >> >> Chris told me that there should be a simpler way to add a simple field in a <repeat> element than re-creating the whole thing each time, maybe have you got an idea? >> >> Thank you by advance for your help. >> >> Best regards, >> >> Sébastien >> >> >> Sébastien Brossard >> IT-Udvikler >> sebastien.brossard@smk.dk >> T +45 3374 8483 >> >> Statens Museum for Kunst >> Sølvgade 48-50 >> DK—1307 København K >> T +45 3374 8494 >> F +45 3374 8404 >> smk.dk >> >> <image003.jpg> >> >> >> _______________________________________________ >> Talk mailing list >> Talk@lists.collectionspace.org >> http://lists.collectionspace.org/mailman/listinfo/talk_lists.collectionspace.org > > _______________________________________________ > Talk mailing list > Talk@lists.collectionspace.org > http://lists.collectionspace.org/mailman/listinfo/talk_lists.collectionspace.org
SB
Sébastien Brossard
Thu, Aug 9, 2012 1:26 PM

Hi Ray,

You were right, it solved my problem.
Many thanks for help.

Br,
Sébastien

Fra: Ray Lee [mailto:rhlee@berkeley.edu]
Sendt: 6. august 2012 19:51
Til: Sébastien Brossard
Cc: 'talk@lists.collectionspace.org'
Emne: Re: [Talk] Local Schema Extension: adding a new field in a <repeat>element

Hi Sébastien,
I ran into this problem in 2.4, and it's detailed in CSPACE-5085http://issues.collectionspace.org/browse/CSPACE-5085. The problem is that even though you've defined inscriptionContentSMKDateGroup as being in the smk schema ("section"), the app layer doesn't understand that all of the fields in the structured date are also in the smk schema. The workaround is to explicitly define all of the fields in the structured date to have section="smk". There's an example of this in the first comment on that jira. Again, this was for 2.4, so there's a chance things are different in 2.3.

Ray

On Aug 6, 2012, at 7:43 AM, Sébastien Brossard wrote:

Hi again,

As said in my previous message, a new problem arose with our new structuredDate:

We want to add our new structuredDateSMK element in

<section id="textualInscriptionInformation"><repeat id="textualInscriptionGroupList/textualInscriptionGroup" >

I created a new textualInscriptionSMKGroup in Service (with all the core fields + <xs:element name="inscriptionContentSMKDateGroup" type="structuredDateSMKGroup"/> )

Then in Application:

<section id="textualInscriptionInformation"> <repeat id="textualInscriptionSMKGroupList/textualInscriptionSMKGroup" section="smk">...

(... re-declare all the core fields +

<group id="inscriptionContentSMKDateGroup" ui-type="groupfield/structureddateSMK" primarykey="dateSMKDisplayText" ui-func="cspace.structuredDateSMK" section="smk">
<selector>object-description-inscription-content-date-smk</selector>
</group>

)

The result is:

  •     Services works (tested through REST API)
    
  •     JASON packets are correct
    
  •     But when sniffing the xml packet, the <inscriptionContentSMKDateGroup>  is always empty - it seems that the application can't make the link with structureddateSMK.
    

Chris told me that there should be a simpler way to add a simple field in a <repeat> element than re-creating the whole thing each time, maybe have you got an idea?

Thank you by advance for your help.

Best regards,

Sébastien

Sébastien Brossard
IT-Udvikler
sebastien.brossard@smk.dkmailto:3sebastien.brossard@smk.dkT
Tmailto:3sebastien.brossard@smk.dkT +45 3374 8483

Statens Museum for Kunst
Sølvgade 48-50
DK-1307 København K

T +45 3374 8494
F +45 3374 8404
smk.dkhttp://smk.dk/

<image003.jpg>


Talk mailing list
Talk@lists.collectionspace.orgmailto:Talk@lists.collectionspace.org
http://lists.collectionspace.org/mailman/listinfo/talk_lists.collectionspace.org

Hi Ray, You were right, it solved my problem. Many thanks for help. Br, Sébastien Fra: Ray Lee [mailto:rhlee@berkeley.edu] Sendt: 6. august 2012 19:51 Til: Sébastien Brossard Cc: 'talk@lists.collectionspace.org' Emne: Re: [Talk] Local Schema Extension: adding a new field in a <repeat>element Hi Sébastien, I ran into this problem in 2.4, and it's detailed in CSPACE-5085<http://issues.collectionspace.org/browse/CSPACE-5085>. The problem is that even though you've defined inscriptionContentSMKDateGroup as being in the smk schema ("section"), the app layer doesn't understand that all of the fields in the structured date are also in the smk schema. The workaround is to explicitly define all of the fields in the structured date to have section="smk". There's an example of this in the first comment on that jira. Again, this was for 2.4, so there's a chance things are different in 2.3. Ray On Aug 6, 2012, at 7:43 AM, Sébastien Brossard wrote: Hi again, As said in my previous message, a new problem arose with our new structuredDate: We want to add our new structuredDateSMK element in <section id="textualInscriptionInformation"><repeat id="textualInscriptionGroupList/textualInscriptionGroup" > I created a new textualInscriptionSMKGroup in Service (with all the core fields + <xs:element name="inscriptionContentSMKDateGroup" type="structuredDateSMKGroup"/> ) Then in Application: <section id="textualInscriptionInformation"> <repeat id="textualInscriptionSMKGroupList/textualInscriptionSMKGroup" section="smk">... (... re-declare all the core fields + <group id="inscriptionContentSMKDateGroup" ui-type="groupfield/structureddateSMK" primarykey="dateSMKDisplayText" ui-func="cspace.structuredDateSMK" section="smk"> <selector>object-description-inscription-content-date-smk</selector> </group> ) The result is: * Services works (tested through REST API) * JASON packets are correct * But when sniffing the xml packet, the <inscriptionContentSMKDateGroup> is always empty - it seems that the application can't make the link with structureddateSMK. Chris told me that there should be a simpler way to add a simple field in a <repeat> element than re-creating the whole thing each time, maybe have you got an idea? Thank you by advance for your help. Best regards, Sébastien Sébastien Brossard IT-Udvikler sebastien.brossard@smk.dk<mailto:3sebastien.brossard@smk.dkT> T<mailto:3sebastien.brossard@smk.dkT> +45 3374 8483 Statens Museum for Kunst Sølvgade 48-50 DK-1307 København K T +45 3374 8494 F +45 3374 8404 smk.dk<http://smk.dk/> <image003.jpg> _______________________________________________ Talk mailing list Talk@lists.collectionspace.org<mailto:Talk@lists.collectionspace.org> http://lists.collectionspace.org/mailman/listinfo/talk_lists.collectionspace.org