Navigation

    Kopano
    • Register
    • Login
    • Search
    • Categories
    • Get Official Kopano Support
    • Recent
    Statement regarding the closure of the Kopano community forum and the end of the community edition

    Missing Calendar items after PST import

    Kopano Groupware Core
    1
    2
    128
    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.
    • rgsell
      rgsell last edited by rgsell

      Hi,

      I have a problem with missing calendar items after importing mailboxes from PSTs.

      They are visible in the list view of the webapp and when I click on them and save, they become visible in the calendar view as well.

      Any advise how to make them all visible via script?

      our versions:

      kopano-server 8.7.7.0-0+8.2
      kopano-webapp 3.5.13.2530+109.1

      TIA,
      Roland.

      EDIT:
      I digged a little bit into it and checked what properties are changing, when I save it:
      The PR_MESSAGE_SIZE and the PR_LAST_MODIFICATION_TIME changes obviously.
      Then the PR_LAST_MODIFIER_NAME_W changes from SYSTEM to tw (the user name)

      Then this 5 properties are added:
      Property(appointment:33299) Duration (minutes) 33299 0x80130003 510
      Property(common:34051) Reminder 34051 0x81a3000b False
      Property(common:34068) 34068 0x81b4000b True
      Property(common:34070) 34070 0x81b60040 2019-12-19 08:00:00
      Property(common:34071) 34071 0x81b70040 2019-12-19 16:30:00

      I don’t think that this information helps, but what do I know? ;-)

      1 Reply Last reply Reply Quote 0
      • rgsell
        rgsell last edited by rgsell

        I managed to fix it by myself.

        Just did a
        item.create_prop(0x81b60040, value=item.start)
        item.create_prop(0x81b70040, value=item.end)

        over all calendar items. This makes them visible again.
        I can post the whole script later, if someone needs it.

        you should run this is a tmux or screen session!

        #!/usr/bin/python3
        
        # This script sets all the special start and stop kopano properties for all calendar entries
        # To fix the following problem:
        # User PST files are imported in Kopano, but calendar items doesn't appear in calendar view
        # (only in list view)
        # If an entry in list view is clicked and saved, it becomes visible in calendar view as well
        # To make them all visible at once for all users run this script
        
        import kopano
        
        
        calendar_name = 'Kalender'
        
        server = kopano.Server()
        for user in server.users():
            print('-------------')
            print(user.name)
            print('-------------')
            cal = None
            for folder in user.store.folders():
                if folder.name == calendar_name:
                    cal = folder
                    print('Kalender gefunden')
        
            if not cal:
                print('kein Kalender da?')
                continue
            for item in cal.items():
                print(item.subject)
                item.create_prop(0x81b60040, value=item.start)
                item.create_prop(0x81b70040, value=item.end)
            print(' ')
            print(' ')
        
        1 Reply Last reply Reply Quote 0
        • First post
          Last post