1 2 Previous Next 18 Replies Latest reply on Aug 31, 2016 9:37 PM by Jamie Cannon

    Simple action to set boolean to '0'

    Apprentice

      Why I find actions in Landesk so difficult I don't know but I do - all I want to do is:

       

      When a user clicks 'unresolve' on the incident window, I want a boolean field called 'FTF' to be set to '0' (this field is in the 'Resolution' BO table). This field is set originally when the anaylst ticks (or not) a box on the 'resolve' window.

       

      Sounds simple but just can;t get my head round actions and what the heck you are meant to do with them, even reading the manual.

       

      Many thanks.

        • 1. Re: Simple action to set boolean to '0'
          DGieraltowski Rookie

          Hi JamieK,

           

          Create new manualy action called "Unresolve", next new automatic action in your incident process, allow an assiciation with window. Link to it from status and back to this status (status>manual action>automatic action>status). Click twice on action and on the window set FTF value as "0" (but you have to have it on the incident window).

          • 2. Re: Simple action to set boolean to '0'
            andreas.lindner Expert

            Hi JaimeK,

             

            you are right, it is not as simple as it loos like, because it is in the object Resolution and not in Incident. If it were in Incident I'd agree with DGieraltowski.

             

            The easiest way for me in this case would be to use a SQL Trigger on the Unresolve Table that sets the FTF flag in the latest Resolution to 0. You can select the Incident Guid on Insert because every Unresolve and Resolution are linked through that GUID to the main Incident. And using the CreationDate or LastUpdateDate you can find the latest Resolution and set the FTF to 0.

             

            Just ask your DB Admin, he might know what to do. And a word of advice: Do a backup before adding the trigger and test it on a non productive copy!

             

            Cheers!

            Andreas

            • 3. Re: Simple action to set boolean to '0'
              Apprentice

              Many thanks both but still totally confused! Don't suppose someone could walk me through it as we have no dedicated DB admin, I'm basically it. I didn;t quite follow the English (no offence) on the first post, how do I "Link to it from status and back to this status"? Where is this found? Pretend your talking to a child and I'll understand..

               

              Thanks again.

              • 4. Re: Simple action to set boolean to '0'
                Jamie Cannon ITSMMVPGroup

                If you are wanting to automatically set this flag on the Resolve window it can get a little tricky.  The tricky part being that if you want to set a field on anything OTHER than your main Incident form, you have to run that action again (like Resolve).  The Resolve form is actually tied to the "Resolve" action which is a based on the Resolutions Business Object.  So normally, you'd need the "Resolve" action to fire again before you can set that flag automatically with process, but that's not optimal in this case.  It is however possible to try this as a copy rule and I'll walk you through that.

                 

                1.  On your INCIDENT business object, create a new boolean called "FTF Flag".  Set Default Value to False, Mandatory to True and Backfill to False.

                2.  Add this new Boolean Attribute to your Incident window.

                    -- On your Resolution window, please be sure to include the INCIDENT attribute and set it to read only in the properties.  This will just show the Incident number which is needed to get back to the Incident
                        form for the next part.

                3.  On your PROCESS, create a new action called "Set FTF Flag" and set the association to window equal to true.

                4.  Add your new "Set FTF Flag" to your process AFTER your unresolve action.

                5.  Open your "Set FTF Flag" action and check then uncheck your boolean.  This will ensure the system see's it as False or 0 in the database.  Save your process.

                    --  Once you have saved your process, go back to the attribute on your Incident window in designer and set it to read only so ONLY the process can manipulate that now.

                    --  This will now set a flag on your primary Incident window for FTF.  Now we need to try to get that onto Resolution form with a copy rule.

                6. Go to Window Designer and expand Incident Management and highlight resolution

                7. In your actions panel, select the "Business Object Copy Rules" action

                8. This part may be best to follow the details here: How to set up Copy Rules  (make sure you use Initialise and Value Changed)

                9. Save that and give it a shot.

                 

                Hopefully that will help you out.  If it doesn't, please let us know.  It could be possible to do it with a calculation, but we'll make that a last resort.    Good luck!

                 

                Jamie

                2 of 2 people found this helpful
                • 5. Re: Simple action to set boolean to '0'
                  Apprentice

                  Many thanks for your comprehensive reply! Just had one question before I start trying this - I already have an attribute 'FirstTimeFix' in my 'Resolution' Business Object because the tick box to set this boolean needs to be on the resolution window. Am I duplicating these attributes by adding 'FTF Flag' or are you saying I need to use two attributes in order to do this?

                   

                  Thought it better to ask before I go through all the steps. Many thanks again.

                  • 6. Re: Simple action to set boolean to '0'
                    Jamie Cannon ITSMMVPGroup

                    Keep the one you already have on resolution because you are going to copy to that one from the NEW one you create on the Incident object.

                    • 7. Re: Simple action to set boolean to '0'
                      Apprentice

                      Many thanks for this - will try and get back. Apologies for delay in replying, this site has been acting up. Thanks again.

                      • 8. Re: Simple action to set boolean to '0'
                        Apprentice

                        Sorry Jamie - hopefully last question. I am at the stage of applying the "Business Object Copy Rules" - will these rules only fire when the Window is run? I take it when running the Un-resolve action this window will run in the background and the value copied to the resolution boolean attribute? i.e. the attribute will be updated immediately and not only when the incident window is opened?

                         

                        Thanks.

                        • 9. Re: Simple action to set boolean to '0'
                          Apprentice

                          Me again. I have setup the copy rule as below, does this look right?

                           

                          The only thing I can't figure out is where you set the 'Copy Related' property to True??

                           

                          Thanks.

                           

                          • 10. Re: Simple action to set boolean to '0'
                            Jamie Cannon ITSMMVPGroup

                            Set the Event to Initials and value changed.  Also, the copy related is a property on the resolution form.  This may work, give it a shot.  If it doesn't, there may be a way to set it with a calculation.

                            • 11. Re: Simple action to set boolean to '0'
                              Apprentice

                              Thanks, will try.

                              • 12. Re: Simple action to set boolean to '0'
                                Apprentice

                                Big sigh - ok I can;t find the 'copy related' property - can someone please point me to it? Grrr.

                                • 13. Re: Simple action to set boolean to '0'
                                  Apprentice

                                  I now see where the 'copy related' can be found in window designer - unfrotunately when I click on the 'Fisrt Time Fix' boolean tick box on the resolution window it doesn;t have that option in the properties?

                                  • 14. Re: Simple action to set boolean to '0'
                                    Jamie Cannon ITSMMVPGroup

                                    It's possible you won't need it.  I think that copy related really pertains to stuff like text fields.

                                    1 2 Previous Next