Skip to content

Submission bitstream access condition edit form doesn't work without maxStartDate or MaxEndDate #1696

@atarix83

Description

@atarix83

Describe the bug
During submission when a bitstream access condition has a start date or an end date (lease/embrago) without setting the maxStartDate/MaxEndDate the edit form breaks down when selection that specific access condition

To Reproduce
Steps to reproduce the behavior:

  1. on rest side configure the access condition (config/spring/access-conditions.xml) lease or embargo in order to not have endDateLimit or startDateLimit
    <bean id="lease" class="org.dspace.submit.model.AccessConditionOption">
        <property name="groupName" value="Anonymous"/>
        <property name="name" value="lease"/>
        <property name="hasStartDate" value="false"/>
        <property name="hasEndDate" value="true"/>
    </bean> 
    <bean id="embargoed" class="org.dspace.submit.model.AccessConditionOption">
        <property name="groupName" value="Anonymous"/>
        <property name="name" value="embargo"/>
        <property name="hasStartDate" value="true"/>
        <property name="hasEndDate" value="false"/>
        
    </bean>
  1. create a new submission and upload a bitstream
  2. edit the access condition for the bitstream
  3. select one of the access condition changed lease/embrago
  4. select a date
  5. the form breaks down and it doesn't allow to save

Expected behavior
The form should allow to select a start date or an end date even without setting the maxStartDate/MaxEndDate

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions