Skip to content

Customize New Field#

Add new props to the property to use them inside of the specific input type

File: piveau-hub-ui-modules\src\modules\data-provider-interface\config\dcatap-input-definition.js

    IDENTIFIER: {
      identifier: 'datasetID',
      type: 'autocomplete-input',
      name: 'semanticNameOfProperty',
      class: 'property',
      NEW_PROPERTY: true, <- added a new boolean to the property
      '@change': true,
    },
If you want to use NEW_PROPERTY you need to initialize it inside of the main.ts.

File: piveau-hub-ui-modules\src\main.ts

Vue.use(VueFormulate, {
  ...
  library: {
    ...
    'autocomplete-input': {
      classification: 'text',
      component: 'AutocompleteInput',
      slotProps: {
        component: ['voc', 'multiple','annifTheme','dcatDE', NEW_PROPERTY],
      },
      ...
    },
    ...
    }
...    
}    
If you want to use the NEW_PROPERTY inside of the component you need to define it as a prop.

File: piveau-hub-ui-modules\src\modules\data-provider-interface\config\page-content-config.js

export default {
    props: {
        NEW_PROPERTY: {
        type: Boolean,
        required: true,
        },
    ...
    }
...
}    
If you need further informations on all the other porperties and how to change them, look here