 
					
				
		
07-15-2020 03:06 AM
Hello,
I'm having trouble setting one of my custom properties to read-only in the content app.
Based on this: https://www.alfresco.com/abn/adf/docs/content-services/components/content-metadata-card.component/#m...
I added the property to the config file:
"content-metadata": {
    "presets": {
      "custom": [
        {
          "includeAll": true,
          "readOnlyProperties": ["uiVMb:orgaUnit"],
          "exclude": [
            "rn:renditioned",
            "cm:versionable",
            "cm:auditable",
            "cm:thumbnailModification",
            "cm:content",
            "cm:author",
            "cm:titled",
            "cm:generalclassifiable",
            "cm:taggable",
            "dp:restrictable",
            "fm:commentsRollup",
            "qshare:shared",
            "exif:exif",
            "cm:effectivity",
            "cm:emailed",
            "cm:likesRatingSchemeRollups",
            "cm:lockable",
            "cm:ownable"
          ]
        },
        {
          "title": "APP.CONTENT_METADATA.EXIF_GROUP_TITLE",
          "items": [
            {
              "aspect": "exif:exif",
              "properties": [
                "exif:pixelXDimension",
                "exif:pixelYDimension",
                "exif:dateTimeOriginal",I didn’t change anything in the metadata-tab component:
template: `
    <adf-content-metadata-card
      [readOnly]="!canUpdateNode"
      [preset]="'custom'"
      [node]="node"
      [displayAspect]="displayAspect$ | async"
    >
    </adf-content-metadata-card>And yet, this property can be edited. What am I doing wrong?
Kind regards,
Jannik
07-15-2020 03:12 AM
Please note that the content app stores the metadata settings in the "content-metadata-presets" section of the "app.extensions.json", not "app.config.json" file.
 
					
				
		
07-15-2020 07:35 AM
Hi dvuika,
Thanks for your quick reply. I tried the app.extensions.json file
"content-metadata-presets": [
      {
        "id": "app.content.metadata.custom",
        "custom": [
          {
            "id": "app.content.metadata.customSetting",
            "includeAll": true,
            "readOnlyProperties": ["uiVMb:orgaUnit"],
            "exclude": [
              "rn:renditioned",
              "cm:versionable",
              "cm:auditable",
              "cm:thumbnailModification",
              "cm:content",
              "cm:author",
              "cm:titled",
              "cm:generalclassifiable",
              "cm:taggable",and it didn’t work as well. I’m using ADF 3.9.0, ACS 6.1.0.5. Any further suggestions?
Cheers
08-11-2022 10:41 AM
I have the same problem with ACA latest version.
Please help with an advice.
Serge
 
					
				
				
			
		
Explore our Alfresco products with the links below. Use labels to filter content by product module.