archesproject / arches

Arches is a web platform for creating, managing, & visualizing geospatial data. Arches was inspired by the needs of the Cultural Heritage community, particularly the widespread need of organizations to build & manage cultural heritage inventories
GNU Affero General Public License v3.0
218 stars 143 forks source link

[date widget] Entering date default and Discard Card Edits raises TypeErrors #10412

Open jacobtylerwalls opened 11 months ago

jacobtylerwalls commented 11 months ago

Date Node > Widget Manager

  1. Enter a date default
  2. Discard Card Edits

Screenshot 2023-12-13 at 10 17 44 AM

knockout-latest.js:20 Uncaught TypeError: Unable to process binding "if: function(){return configForm }"
Message: Unable to process binding "datepicker: function(){return {format:'YYYY-MM-DD',viewMode:viewMode,minDate:false,maxDate:false} }"
Message: viewMode() expects a string parameter
    at L.viewMode (bootstrap-datetimepicker.min.js:4:27162)
    at Function.eval (bootstrap-datetimepicker.min.js:4:21499)
    at Function.each (jquery.min.js:2:3161)
    at L.options (bootstrap-datetimepicker.min.js:4:21402)
    at i (bootstrap-datetimepicker.min.js:4:33433)
    at HTMLInputElement.eval (bootstrap-datetimepicker.min.js:4:34043)
    at Function.each (jquery.min.js:2:3111)
    at ce.fn.init.each (jquery.min.js:2:1576)
    at $.fn.datetimepicker (bootstrap-datetimepicker.min.js:4:33911)
    at init (datepicker.js:59:18)
knockout-latest.js:20 Uncaught TypeError: date() parameter must be one of [null, string, moment or Date]
    at L.date (bootstrap-datetimepicker.min.js:4:21650)
    at a.gc.eval [as kc] (datepicker.js:64:18)
    at Function.notifySubscribers (knockout-latest.js:42:453)
    at Function.wa (knockout-latest.js:47:255)
    at DatePickerWidget.c [as value] (knockout-latest.js:46:494)
    at DatePickerWidget.WidgetViewModel (widget.js:86:14)
    at new DatePickerWidget (datepicker.js:18:21)
    at Object.eval [as createViewModel] (knockout-latest.js:92:380)
    at c (knockout-latest.js:98:333)
    at eval (knockout-latest.js:99:294)
jacobtylerwalls commented 11 months ago

Second TypeError mentioned in #9646, but the result is a little worse here (widget doesn't render).