MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    Setting 2 default calendar modules; but weird represent

    Scheduled Pinned Locked Moved Solved Troubleshooting
    11 Posts 2 Posters 2.9k Views 2 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • 1 Offline
      1a2a3a @sdetweil
      last edited by sdetweil

      @sdetweil we are talking about default cal ya? lets ignore cx here.
      i have 1 hidden with 2 url. <- this is fine to be hidden because i need the url to be passed on to the cx.

      have another 1 not hidden with 1 url. <- i cant change the date format for this with the code given unless i merge both cal (hidden and not hidden) url into 1 module. i only want this calendar to only show holiday and not the rest of the url.

      im going to paste my code here

      {
        module: "MMM-CalendarExt3Agenda",
        position: "top_left",
        title: "Today",
          config: {
      	  locale: 'en-GB',
      	  instanceId: "basicCalendar",
      	  startDayIndex: 0,
      	  endDayIndex: 7,
      	  showMiniMonthCalendar: false,
      
        }
      },
      
      
      {
      			module: "calendar",
      			broadcastPastEvents: true,
      			config: {
      			timeFormat: "absolute",
      			dateFormat: "Do MMM",
      			calendars: [
      					{
      					 url: "personal.ics",
      					name: "123",
      					},
      					{
      					url: "personal2.ics",
      					},
      					{
      					url: "soccer.ics",
      					},
      
      ]
      }
      },
      
      
      {
      			 module: "MMM-CalendarExt3",
      			 position: "bottom_bar",
      			 title: "",
      			 config: {
      			  mode: "weekly",
      			  instanceId: "basicCalendar",
      			  locale: 'en-GB',
      			  weekIndex: 0,  
      			  weeksInView: 4,
      			  maxEventLines: 6,
      			  fontSize: '18px',
      			  eventHeight: '13px',
      			  firstDayOfWeek: 0,
                    		  useMarquee: true,
      			  calendarSet: [],
         }
      		},
      
      
      		{
      			module: "calendar",
      			broadcastPastEvents: true,
      			header: "Singapore Holiday",
      			position: "top_right",
      			config: {
      			timeFormat: "absolute",
      			dateFormat: "Do MMM",
      			fulldayEventDateFormat: "Do. MMM",
      			maximumEntries: 10,
      				calendars: [
      					{
      					url: "https://www.officeholidays.com/ics-clean/singapore",
      					name: "Singapore Holiday",
      					},
      
      

      …

      and this is my result. as you can see, managed to flip all the dates to d MM except the one on the right showing the holiday despite the code added in…

      mm.jpg

      S 2 Replies Last reply Reply Quote 0
      • S Do not disturb
        sdetweil @1a2a3a
        last edited by

        @1a2a3a I think you have the wrong format requested

        Do MMM

        from the moment format specs page
        https://momentjscom.readthedocs.io/en/latest/moment/04-displaying/01-format/

        Day of Month	D	1 2 ... 30 31
        Do	1st 2nd ... 30th 31st
        DD	01 02 ... 30 31
        

        Do has th, nd,st…

        D has just the number

        DD has 2 digit number 0 prefixed

        Sam

        How to add modules

        learning how to use browser developers window for css changes

        1 1 Reply Last reply Reply Quote 0
        • S Do not disturb
          sdetweil @1a2a3a
          last edited by

          @1a2a3a one other minor forum thing…
          alwasy warp config stuff in code block

          paste text in editor
          spare line above/below
          select all the text you pasted
          hit the </> button to wrap in code block… I added that for you this time

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          1 Reply Last reply Reply Quote 0
          • 1 Offline
            1a2a3a @sdetweil
            last edited by

            @sdetweil nothing works actually. so you see my code.
            the last paragraph on the default cal module where holiday ics is … no matter what format i choose for the date format, it will be stuck at Dec 25th. all i wanted is 25th Dec or 25 Dec.

            S 1 Reply Last reply Reply Quote 0
            • S Do not disturb
              sdetweil @1a2a3a
              last edited by

              @1a2a3a ok, got it…

              the code is using this attribute

               'fullDayEventDateFormat'
                fulldayEventDateFormat: "Do. MMM",
              

              you are suppling the second one

              case matters, every character

              so your config entry is ignored as it didn’t match, so it used the default

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              1 1 Reply Last reply Reply Quote 0
              • 1 Offline
                1a2a3a @sdetweil
                last edited by

                @sdetweil yes yes yes! thank you so much! spent my entire day on this :(

                S 1 Reply Last reply Reply Quote 0
                • S Do not disturb
                  sdetweil @1a2a3a
                  last edited by

                  @1a2a3a one of my modules ‘may’ help… doesn’t work for every module

                  see https://github.com/sdetweil/MMM-Config

                  it provides a form for you to fill out… no more config editing…

                  some modules do tricky things… EXT3/Agenda

                  but they can be augmented with a proper config definition and work perfectly.
                  I ship the schemas for modules that won’t be updated as a way to help older modules…

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  1 1 Reply Last reply Reply Quote 0
                  • 1 Offline
                    1a2a3a @sdetweil
                    last edited by

                    @sdetweil I actually installed this but couldn’t get it to work. When I tried launching, the page looks gibberish to me and it doesn’t generate a new config file. Not sure if I’m doing something wrong.

                    S 1 Reply Last reply Reply Quote 0
                    • S Do not disturb
                      sdetweil @1a2a3a
                      last edited by sdetweil

                      @1a2a3a can u send me some screen shots? either direct or to my mail , same userid at gmail…

                      and the schema3.json file from the module folder

                      Sam

                      How to add modules

                      learning how to use browser developers window for css changes

                      1 Reply Last reply Reply Quote 0
                      • 1
                      • 2
                      • 1 / 2
                      • First post
                        Last post
                      Enjoying MagicMirror? Please consider a donation!
                      MagicMirror created by Michael Teeuw.
                      Forum managed by Sam, technical setup by Karsten.
                      This forum is using NodeBB as its core | Contributors
                      Contact | Privacy Policy