Community Live Stream - Code Decoded - Service Portal Live Widgets

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
[Music] good morning good afternoon good evening wherever you are whenever you are hey just checking to see if the live stream is working it says it's waiting where are we going okay i have got an error here that i'm going to try and fix says the resolution is wrong let's try fixing that uh where do we fix that okay since it's not streaming i'm going to stop then open widget stream health i need to change your video versus current resolution which is not supported by this configuration error messages analytics system settings auto start captions latency settings [Music] good morning good afternoon good evening wherever you are and whenever you are welcome to the community live stream my name is chuck tomasi from servicenow and looks like we're good to go thank you for joining me here today you can catch us on youtube mondays and thursdays at 2 p.m utc i look forward to seeing you there set your calendar do whatever else you need to do i uh well you know what to do on youtube click the like click the subscribe notifications i think i have a notification around here somewhere that says hey guess what we are broadcasting and wake up phone if you do that you'll get something that looks a lot like that i also have one from twitch that says guess what twitch is also broadcasting oh i've got a little bit of color issue going on on the left hand side of the screen see if i can clean that up for you real fast i apologize i thought i had all that squared away right at the beginning of the show uh it looks like a key threshold thing to me yes we'll just boost that up must be the lighting change today all right we are good to go let's continue on now that we've got audio and video issues out of the way this is september 14th 2020 and our topic today is live service portal widgets we are going to create something that reacts dynamically to changing data and i'll give you some caveats under the hood and some bonus content of how you can make your widgets work across multiple instances you can make them reusable using some options so look forward to that everybody doing all right we're okay we're strapped in okay let's get on with the rest of the intro you can also find us over on twitch let's get that going twitch.tv now community where you can find those videos a lot of people play them there appreciate that very much i'm not able to monitor the live chat through twitch at the same time i'm doing youtube so i am watching youtube if you've got questions about service portal widgets being live okay there's a lot to know about service portal widgets yeah i understand that i appreciate that this topic is on live service portal widgets particularly the record watch method and we will get into that in just a bit if you've got other questions please post them over at the community at community.servicenow.com our chat room is very gracious and says you know that's a little off topic we're not talking about atf today we're not talking about upgrades we did that yesterday on tech wait tuesday on tech now i have to remember what day it is this is thursday right still thursday it's been going on for quite some time let me get going with that so please post in the community if you haven't already done so go over to developer.servicenow.com where you can get yourself a free personal developer instance all those apis blog entries videos live coding happy hour on fridays lots of great stuff over at the developer community at the developer portal developer.servicenow.com one of the things of course you can find over there is meetups i was uh privileged to present at the amsterdam meetup yesterday or last night for some of you that was a wonderful experience we shared a lot of great developer resources if you want i believe that's going to the video is going to be posted publicly so you could virtually attend the amsterdam meetup out of time out of sync but there are many many others around the world that are happening virtually as well i believe there's a vancouver one coming up next week that i plan to attend they're just they keep popping up and i'm going to whack those moles as many as i can and attend and present phoenix is coming up on october 1st so look forward to that as well that'll be pretty early morning for some of you in ist time zone so maybe you can make it hopefully you can look forward to seeing you there whether it's phoenix or london or if it's close enough that i can get in the time zone and i don't have something else scheduled i'll let you know about that one thing i do want to let you know about is i saw this on our internal feed this morning creator con 2020 is coming up october 27th registration opens october 8th giving you some dates here mark your calendars october 8th registration opens up and the on-demand content will be starting up october 20th one week ahead so you can do those virtual labs before you even get to creatorcon then on the 27th we'll have our keynote we'll have our live sessions we'll have all that stuff it's not going to be a two-day event it's going to be more like a four-hour event so keynote hands-on workshops and follow along and live coding happy hour lots of great stuff look for the published agenda and the newsletter coming out in a couple of weeks so october 8th is when registration opens up those of you who attended the creator con 2020 in may there is something different for you and if i understood right you will automatically be registered for that so you just sign up it could be easier than that we've we've just sort of pulled you along or you can opt out if you list wish but i don't know why anybody would anyone would want to do that craziness but watch for this this is coming up very very soon mark your calendars so that nobody takes your time and you can enjoy the full experience before and during and after creatorcon 2020. so look forward to that also we did release a new episode of breakpoint the servicenow developer podcast released that yesterday on the 16th i just don't know what day it is today uh talking with g von kaur about upgrade center in paris this is a follow-up to our tuesday sorry a warning just came up yeah yeah yeah looks like we're so good okay tuesday's tech now this is a conversation we had that follows along with that so look forward to that we also have one coming up more about creatorcon 2020 with jason mckee next wednesday bonus episode because normally breakpoint is every other wednesday but again there's so much stuff i want to share we're going to put that in and get that to you so if you're not already subscribed if you're not already listening breakpoint you can find it on apple podcast google spotify and as of yesterday amazon amazon music has released podcasts and breakpoint is in there as well just discovered that yesterday we do have our next tech now coming up on october 20th this is part one of two around process automation designer and playbook so this is big stuff in paris and we brought in the expert yaranguez to tell you tell you all about it you can find that go register over at bitly slash tn 80 reg and get signed up 8 a.m pacific time 8 30 p.m ist that'll be october 20th looking forward to seeing you all there and i am looking forward to learning more about that we do have some code snippets that we'll be discussing today this is service portal widgets there's going to be custom code i have all of that code available in a folder with today's date over at the github repo you see right there bitly sn-cls go find that and if you're not familiar with javascript and you want to get more comfortable with it or there's just something you need to go back and check check out the javascript series with the bitly link sn learn js a lot of great people have been commenting on that a lot of people have been leaving great comments they are great people for watching the video don't get me mistaken so we've got that all covered let's continue on with today's topic which is not looking at the meetup map it is going into service portal and i am going to get my notes down here make sure i've got everything all set up the way it should be so the basic idea behind today's topic is there are times when you want a dashboard a widget a page something to update live in real time or as near real time as you can get without having to put in a refresh sure you can put in an http meta tag at the top of your page and say refresh every 30 seconds and it's going to refresh all of the page but that's not optimal we want the data on the server side to say hey look at me i changed it's time to update this widget we can do that right in a service portal widget this is one of the coolest things that i found i use it for a lot of different use cases if i could if i have time i'll show you some of those but i will show you some examples of how you can use it to be better we're going to turn a static widget into a fully fledged reactive widget and it'll do the same thing for a list because you may want to see where things are in a in a priority queue i'm also going to give you some caveats there are some warnings as i built some of these out i went ooh bad idea let's not do that again because it sent the whole thing into a crazy tail spin so yes drew we are going to be doing record watch so i'm going to build this up a little by little if you haven't already seen the service portal widget episode i did on august 13th watch for the orange tie the orange background the the service portal widgets part one was august 13th in this in in this channel so servicenow community on youtube go to the community live stream playlist and you'll find it there okay i will try to put a link in there so we can link these two together you go whoa whoa whoa what's he talking about just so you don't think i'm glossing over some of the concept a little too quickly so i am going to start by opening up the service portal widget editor which i already did here you can find that under service portal there is this guy right here service portal configuration click that it will bring up another tab with the widget editor actually brings up the configuration page i do this let's go back to this widget editor and i'm going to create a new widget all this widget is going to do is count the number of active p1 incidents and as that number changes it will update live see if i can do this in two windows so let's create this one called cls live count i'm going to create a test page because i often like to see these on a separate page sometimes the preview window just doesn't give you everything you need did i click submit i click submit we've got our three basic parts of our widget the server script on the right the client script in the middle the html on the left so shouldn't come as any surprise to save you to save me a bunch of embarrassment and you a bunch of boring time i've already written out these scripts they're not terribly complex let's start with the server script put that in there you know what i should be able to look at this on this screen sure this is fine again all of this is going to be in the github repo that you see right over here sn-cls look for the folder 2020-09-14 excuse me 1-7 and you will find that there okay so the server script starts whenever the widget starts whenever appears on a page or it's told to refresh we'll get to that in a second okay the client script can tell it to refresh the an event could tell we're going to just keep an eye on that but let's say for now we're just going to run this server script at the beginning when this starts i am going to pass it a table and a filter and a label okay because i want a little widget that says active p1 incidents in english and then i'm going to pass it a filter an encoded query so that the glide record operation knows what to watch for active equals true priority equals one pretty easy and also the table incident so three pieces of information now i could hard code those right into here to say here is glide aggregate go get the incident name go go get the incident table here is my filter active equals one that makes the widget good for one and only one thing counting active p1 incidents but what if i want to see how many overdue loaner requests i've got or how many employees are pending an offer or just some single score record that i want to put on a widget this enables me to do this with options so option says go get the options i'll show you how to make the option schema in in a second but i can pass in options to each instance of a widget remember widget's just going to be this basic framework and until you put it on a page which it just did from that test page until you put it on a page it really doesn't do anything it's a blueprint this this is a blueprint it doesn't run until it's on a page and this line five here says go and check if they passed me an option table name if they didn't then i'm going to use incident this is a shorthand notation of an if else it's actually an if not l it's a it's saying if you didn't pass me this i'm going to use a default value if there's no filter i will not use a filter so instead of getting a null or an undefined going no i don't know how to do a query on undefined this will actually pass it a blank string and the label hey if you didn't give me a label well you don't get a label that's fine too then i use those options in the data model as data.table name data.filter glide aggregate should not come as any surprise i'll cover that in more detail at a later date if all i'm doing is counting records i want to use glide aggregate do not use glide record and get row count too slow okay you could have tens of thousands of records and it will take a long time for your widget to draw glad aggregate very fast we'll talk about glide query in a little bit i know somebody out there is going what about cloud query do we have anything about broadcasting between widgets in our agenda today no that's going to be events and that is coming up so you can send a signal using events between widgets very cool i've done that for even just one widget telling another hey it's time to present your little loading widget circle the icon goes around and then it says okay now it's time to stop that's pretty fun i do my query i get my count and i store that in data count pretty simple server script so let's do that let's go get the html as well so the html is super simple i did very little if no styling on this except a br i input the code from my data object as c.data.label c dot label.count and i should theoretically be able to run this so it runs okay well it's saved we could turn on the preview and say enable preview go and i didn't give it any options and it's counting all records in the incident table by default so to set up demo data i can first have to edit the options schema and say i need a table i need a filter and i need a label and i better pay attention to what i call those in the server script it was table name with a capital n filter and label okay easy enough let's add a label to this is table name the name is table name the type is string that's fine default value i could put a default value in here that would be fine and form section don't need it let's add another one for my filter filter filter string good default value all records because i can't guarantee every record every table i'm going to query has an active field that wouldn't make any sense so let's not do that and finally i need a third element to my options and that's going to be the label label string fine here we can even put in a thing no label all right now if i save that and run it it says no label still getting all records from the incident table it's got double defaults now one from that uh and in here if i look at my i'm trying to remember where it was there was the demo data i thought i could put in some demo data here but i could be wrong might have to do that through open in platform okay let's go look at this widget because there's a field on the widget where i can put in some demo data and the demo data is a json structure that looks like this i don't know why it does this crazy indent thing on me but it has and in here i don't have to pass in if i'm just testing this thing i don't have to put it on a page and instantiate a widget etc etc so i've got this list of my different things and for my demo i'm going to pass in my priority one active equals true active p1 incidents update that now just remember i updated this in two different places which means i should really reload this so that it gets its demo data i've run into that before and now it says there are come on 17 active 1p yes active p1 incident is that true let's go find out incident and sedent let's try typing that again incident open is active equals true and priority is one can we find a one ah you're no fun let's group by priority i can't find one on the screen immediately there we are 17 of them how about that so our widget is working in terms of just raw functionality it's not live yet we're still building up to that we're also using some um back here we're also using some options so that we can make it a little more flexible and i can see that from let's let's do this server surface portal pages and i should have my test page out here cls live count and i can look at that let's uh open it in the designer it's going to go from the widget editor to the page editor and here is my wonderful test widget notice that it's a little big i got to go over here the pencil icon will bring up my options so i can say look rather than using the default incident yeah i'm really going to say use the incident field but this time your filter is active equals true and oh can't remember what that crazy query was so let's go back to my incident list and get my priority ones there's one no matching no matching and of course i can always copy the query from here paste it into the filter here that's what it's looking for so that's what i'll give it and this is active p1 incidents there's one instantiation let's make the layout a little better i don't really care for this super wide thing let's go to the three column mode i'm going to put that right there drag this widget down there get rid of this container i think i can get rid of that container somehow right maybe just hit delete do you want to permanently delete the selection yes okay rid of that so i've got one widget there let's put another widget there cls i have count we'll put another one there this one is going to count something different we'll count something off of the employee table that i have on a completely different application let's set up a filter um let's do active employees how's that can't remember the name of the table here let's cheat we'll do show xml and in here we have our table name hooray there's many places you can get a table name that just happened to be my closest one table name filter active equals true label active employees same widget two different counts two different labels two different instances of that widget you've probably seen this a lot on service portal when you put a badge or something for the knowledge base or catalog or something of that nature same concept if i go to preview it is not one of my most stylized pages but it works if i want i can there's a preview out there that same page i don't remember nope let's do this let's go back to the service portal page cls live count and i can test it i love this try it let's try it in the standard service portal just click that link and up it comes now i've got a nice test page that i can refer to if i like i can even use my browser's developer console to see any messages over here notice that it says hey it's too narrow for 3333 i'm going to auto scale so it is a responsive interface and it will stack them instead of putting them side by side let's go back to the widget editor we're not done yet go back to widget editor okay that was stuck in preview mode we are going to go to the widget editor service portal configuration widget editor okay we've got our basic widget counting but it's not live this is where the secret sauce comes in this you also need to be very careful we'll put the preview window away we don't need to do that right now we've got this widget pretty solid from a basic html standpoint the secret is in the client script i don't know it says mjs it's not an m.js it's just a js i thought i renamed that something didn't sync and if i look at this script look at it completely there is a key component in here called record watch and if i go to the docs site maybe docs it might be developer i gotta look it's under sp util client there it is and it says i have a few methods for you add error message add info message that's how you can put those nice ones up there one of my favorites add trivial message it's like an info message get a nice little green banner but it goes away after a few seconds so it's just there to say yeah record updated goodbye you don't have to go exit out we should go through a lot of these later but the one i'm looking for is record watch ta-da and it has several parameters it is part of scope so first of all do not forget to include scope and sputil i'm going to be using those things i usually start writing the code and then the client script comes up and goes hey what's a dollar scope i forgot to include that okay that is going to be important i pass it the table to watch a filter of records to watch and then an optional callback function now i like the callback function because it says if this stuff switches it changes go do this other thing i'm not sure what the purpose of record watch would be without a callback function haven't run into a use case like that so if you look at how we're using it i have sputil it's going to pass dollar scope here is my table name now rather than type in incident i'm going to use the one that's in the data model as c.data.table name that was also part of the options so i know i've got that i know i've got my filter what am i watching for i'm watching for all active p1 incidents that was part of the count you don't have to make this filter match the other filter but in this case it makes sense why would i want to watch for all incidents changing when really my filter only updates for the active p1 which is preferable demo data or option schema demo data is going to be if you're working in the widget editor itself okay the option schema is necessary if you want to make your actually you can't have demo data without an option schema it wouldn't make sense because it's like where where's the options coming from think of demo data as filling in the blanks for whatever you're working on on the widget editor okay that's going to be because i can't really mod i can't put in data until it's on a page i can't put in those options until it's on the page well it's not on a page if i'm just sitting there working on the test bench in the widget editor so that's kind of what it's doing hope that explained it they work hand in hand short answer then i've got my callback function which has a response action and i'm just simply going to log out what the response data is now i often do this with things like hey a record is changed now go update it c dot server dot update says go rerun the server side script okay so it will refresh that count that's all this does you can make this do some crazy stuff if you are changing i want to point out that that response dot data piece because it will um it will actually return some interesting information let's put this into our client script which is over here done done done and you can have more than one record watch this is the crazy part more than one record watch in a widget i've got one that's got three or four it's watching the customer information for that i mean it's a very specialized widget it's watching the cis user table for that it's watching the a queue for this other thing and based on what changes happen it will affect the behavior of the widget oh it's time to go update this list oh i'm going to refresh the entire page oh it's time okay so you get the idea you can have more than one of these but be extremely careful especially when i get to the next example about the list be extremely careful because every update whether it's human made or server made will trigger record watch why do i say that because i ran into a situation where i had a list of records and i was reordering them and i said okay move this third one to the second position and then renumber them all so instead of one three one three two four it would go one two three four i just did two record updates it's going to call record watch two more times now imagine that in a long list where you're moving something from a position a record of a list of 80 records and you move something from 80 to one it has to renumber every record it's doing 80 triggers of record watch because you simply went nope put it up there and renumber them from 1 to 80 again okay so think about that if you have a business rule or a script include or something that is going and doing an update based on a change you made or change this the system made says let's renumber all the records so they come out 1 to 80 again if you do that glide record update operation it's going to trigger record watch and what happens is it's as if you just hit that refresh button 80 times it's going to take a long time and you will see the magic dancing dots you've probably seen these on a lot of other portals when you refresh and you see the the dots over here just to the left of your menu it's going to go i said wow this is crazy because i was i was saying i'm done with this and then a business rule would go renumber that list and it would take two minutes to say i'm done updating your list like why did that take so long oh it's refreshing all those records which is triggering a record watch and it's like oh it had to do 80 refreshes for that that was painful okay now that we've got this in here let's do this put that there i am going to tear this off close that for a second close that we're not ready to look at that yet move this over here i could probably blow that up can i blow that up just a little bit more no darn and let's keep an eye on those widgets we're going to go to the employee table which was over here and it says active employees 43 i don't remember 43 records in that employee table that doesn't seem quite right am i looking at the right table let's change one let's go true i didn't refresh the page did i it doesn't have the latest client code whenever you make a change to a widget you gotta update that let's go back to incidents just for fun here's activep1 critical if i go and open up a new p1 and say this is high this is high priority is critical we'll say this is for fred and it is active we need a short description hello widget and i saved that fingers crossed waiting take a drink that looks good of course not sure why the instance is really really slow hopefully i didn't send it into an infinite loop and lock something up there we are okay that is now correct but why didn't this trigger we still have 17 active p1 incidents i don't believe that for a minute do you oops i didn't want priority one i want priority one here how many do we have we still have 17 interesting i wonder where that issue went let's sort by uh date updated did i miss something somebody catch something p3 instead of p1 really updated a i thought i made it a p1 network file issues where'd my thing just go email server is down let's try that again these are all p1s let's go get one that's not a p1 it's always the data isn't it need to fix incident impact okay hello widget it did i did set it to one i said priority is anyway let's try that again work notes work notes all right everybody's favorite work notes save for it watch for it we're all eagerly hey that was pretty cool did you miss it it was right over here it was 18. i'll adjust that back save it more work notes i've spelt work notes properly have to do that save it it should go back to 17. so that widget is reacting to live data now pretty neat we've got it working so that it's it's more of a dashboard kind of thing that's record watch in a nutshell you've got dollar scope your table your filter away we go let's next make this work on a list all right so i don't remember where the list was so i'm going to bring it up this way uh pages i think service portal ah pages and i have one called cls live list i don't remember what widget's on it so we're going to try it on the main portal again nothing special here tear that off and these are my active employees but again it is not live i'm going to go to the widget editor and show you because in the widget editor go to widgets and pick open cls live list widget which is on the cls live list page i don't have any record watch in here i also noted in paris that it now starts with api.controller in the client script don't know what that was for or why but if you're making new widgets watch for that employees increased by one awesome we have a list of two again i have filter i have demo data i've got um this widget is able to show not only a list this one's kind of fun because it goes and gets the fields from a list that the the html notice that it doesn't spell out the labels name date of higher state i am passing that as some of the widget options so if i look at the schema i have a table name again i have a filter again i have a label for the table and then i have what fields do you want and i said i just want the name and the active field i could have date of hire this is my default date data but it's a list of comma separated fields and then as extra bonus content i say let's go get the labels for those fields and i can do that with a gr.getelement getlabel there's some other glide record operations hanging out here again i'll have these in the of these in the github repo then i put all of that into the data object you've seen me do this on the august 13 episode where i was building a service portal widget it builds out that table of here's a label here's a value and then the html becomes very very simple go print out the row that has the labels on it and go print out each rows values so pretty slick and easy to do this particular instance if i do a control shift i can look at my instance options for this particular widget i think i clicked that yes instance options there they are i say go get from the employee table where active is true there's your label and i want name date of hire and state on that widget name data fire and state pretty neat pretty flexible little simple table widget this one has a little bit of styling on it so not too proud of it but enough there's my label and let's watch it work live because right now it's not if i go and change jeremy in the employee table i was just there a little while ago so it should be in my history here's jeremy let's make jeremy false nothing happens i have to refresh the page and jeremy goes away so let's go make that live of course we're going to use record watch again and i believe i have the code for that i do not we're going to have to write this one it's going to look an awful lot like this one oop i didn't copy and paste properly copy paste paste am i in the wrong scope or something no because i wouldn't have been able to edit that very interesting there it wasn't blue you know you're having a bad day when you can't do a basic copy and paste uh class table striped is working it's it's striped you couldn't see it it's probably pretty light there let me zoom in on the table we're going to refresh that in a minute anyway is this record watch any different than the previous one well probably not if you know how i write my code so i am watching the table in the c dot table name no this is c dot data dot table table dot name because i put everything into a table object the name is in name the filter is in filter table.filter and we are going to just spit out the console data on the login just a moment and then it will refresh this into our field labels our field list all of that's going to be rerun in the code save that say a quick prayer refresh it no jeremy there back that up a little bit so we can see don't need the server script at the moment i love how service portal is written in service portal change that to true pretty cool huh make it better than that let's put craig in the list true there's craig i don't know what order it's sorting these in it's probably by date of higher or something so i've got my apparently i've got my uh state is off it's got a date value in there not sure what i did for that but uh i did name date of higher and state and state is uh should be the value retired terminated whatever it was so i'm gonna have to look at that uh what is the significance of filter the third argument in the record watch function that tells the record watch do you want to watch for all records that may change or do you want to do you want me to trigger on just the ones you specify it's exactly the same as the filter up here if i were to say active equals true if i put a filter on a list i am only looking at those records these aren't live of course but it's a way of filtering down how much information the record watch has to keep an eye on it's going hey you've got 10 000 ci's but i specify a filter and says i'm only going to watch for changes on these 15. okay that's what you told me to watch for that's what that does again watch out for what seems like a simple little oh i'm going to reorder so instead of 1 2 3 this is going to be 3 2 1 and go save i've just done three glide record queries and that triggers record watch three more times you will see those dancing dots a lot so don't do that it's painful i've got a live list i've got a live widget let me check my notes make sure i didn't miss anything we talked about options how to make your widget multi-purpose reusable the counter the live list widget got that got the options and record watch talked about records records that update frequently it could be a problem depending on what the frequency is if you're talking once a minute hey no problem but if it's something that's happening you know 10 times a second and there are systems out there that update records very very frequently you may be doing this in a business rule and you just want to check okay that's going to affect record watch remember record watch is sitting out there listening it's going hello what's happening i just want to show you something let's uh not do a software update right now i also want to show you something in the console log i believe is that keystroke and when something changes refresh that you'll start getting these amv the asynchronous message bus that's how it communicates between the server and the client and the client says hey i got something to update so if you start seeing amb messages in your console log it means record watch is listening record watch is working and when i change something in here bing that console message just dumped out the data this could be useful for you if you're watching for one particular change in a record because all record watch is going to say is a record matching this table and filter changed you may want to know what did it change from and what did it change too that is available in here what changed active active was it's element zero i thought there was a deeper display in here that's the prototype change but you could tell what fields change so i could put an if statement inside of that callback function to say if active was one of the changes because it could have been several changes you might have changed active you might have changed state date of higher all that other stuff somebody somewhere either interactively or via the system business rules whatever change the active field that's going to be important we also have the record information which should look familiar here's active the display value is false the value is false notice these are strings be aware of that this is where this log really comes in helpful there's the table that was changed i've got my sys created on it's only reporting back to me what changed so be aware of what's available in here but it's handy to know what's in that response so i printed out the response.data remember that console.log statement that was in my widget that's what that's coming from right there i usually do something very similar to this just to make sure record watch is working dump me the data and update the list or update the widget just rerun that server code so that i can see what's happening did it work sometimes it's just a console log that says record watch fired okay there are other times when i want to say did this field change and is the field value now empty because if it's empty well that changes the behavior of the widget entirely so i have to refresh the page something of that nature very very useful stuff a lot of power in record watch but again be careful about multiple updates the other one i found was watching the sys properties table don't know why but whoever is using the widget needs to have a read role on that you can read the value of a property through server script to display it now granted properties shouldn't be changing all that often anyway if you're changing it more than once a week you're probably not using properties correctly because properties affect the way the application or the system behaves and you don't want to change that every day if you're changing it once every six months maybe but again if you if if you're using record watch on sys properties you may have it on a dashboard somewhere that says you know our total limit is 10 and if somebody changes it to 15 you could have that on your dashboard somewhere saying hey the limit's not 15. also remember sys properties every time you change a property it's going to flush the cash so if you're changing them frequently again you're probably using properties wrong and you're going to have a system impact as everybody refreshes their cache of forms and lists and preferences and properties and okay they're in the cache for the reason to minimize performance to minimize performance issues but if you're flushing the cache you're defeating it i actually ran into a system where somebody said why is my system running so slow they had a background script that was running a changing a system property like every three seconds it was like really frustrating went okay just turn that off so generally you wouldn't use this for sys properties but if you do recognize that record watch is go whoever's running the widget needs to have a read role and there's a roles field for reading and writing on that property don't know why it's kind of funky because nowhere else do you need that but just one of the special cases that i ran up against you want to pass that on okay that is all i've got for today i hope you can join me on monday the 21st when we talk about ui actions part one thank you for joining me hope you had a wonderful time you learned something about record watch and making your lists and account widgets live and we will see you right back here at 2 p.m utc on monday till then take care have fun bye [Music] you
Info
Channel: ServiceNow - Now Community
Views: 3,875
Rating: 4.9587631 out of 5
Keywords:
Id: Eg7l15v-nd0
Channel Id: undefined
Length: 50min 27sec (3027 seconds)
Published: Thu Sep 17 2020
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.