Community
    • Categories
    • Recent
    • Popular
    • Users
    • Search
    • Register
    • Login

    Exchange of user-created object types

    Scheduled Pinned Locked Moved General
    2 Posts 2 Posters 359 Views 1 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.
    • N Offline
      NdsMetall
      last edited by NdsMetall

      Hello,
      I'm in the process of creating custom object types for certain device types, mostly derived from the generic "Device" type. The question arose as to whether there were already provided object types somewhere in the forum, on Github or elsewhere, or how one could make the community happy with such object types.

      Is there already a practice for this? or deployment modalities?

      I would like to give something back to the community of i-doit users.

      Best regards
      Ralf Kühnbaum-Grashorn

      1 Reply Last reply Reply Quote 1
      • R Offline
        raftaar45ds
        last edited by

        You should consider changing your class to "User" instead of "Users". The list_of_users will then be a list of user objects, instead of a list of names. To implement a changeUser function you probably want to create some kind of variable state which indicates whether a user is currently logged in, and which user it is. It is a better design to split the login handling into a separate class, you could for example call it "LoginHandler".

        1 Reply Last reply Reply Quote 0
        • First post
          Last post