Unable to modify asset state or unable to edit assets

Unable to modify asset state or unable to edit assets

Issue:

While trying to change asset state from list view, we get "Sorry an error has occurred". If we try to Edit that asset, we get a blank page.

Error traces from logs:

|[com.adventnet.servicedesk.asset.action.AssetDefAction]|[SEVERE]|[102]: Exception while trying to retrieve data for Asset : 744955| 
java.lang.NullPointerException
at com.adventnet.servicedesk.utils.Select2Util.constructJSONData(Select2Util.java:78)
at com.adventnet.servicedesk.asset.action.MSPAssetDefAction.fillDetails(MSPAssetDefAction.java:75)
at com.adventnet.servicedesk.asset.action.AssetDefAction.execute(AssetDefAction.java:796)
at com.adventnet.servicedesk.asset.action.MSPAssetDefAction.execute(MSPAssetDefAction.java:39)

Cause:

Issue is because those assets which has this issue does not have department assigned to it properly. 

Fix:

Navigate to Assets list view->Select all the assets that has this issue->Actions-> Modify State->Assign to Department->Select the Account and Department and save.

If there are more number of assets in trouble, you can use this below query to find out the same,

select r.resourcename,r.ciid,ro.deptid,dd.deptname,dd.siteid from resources r inner join resourceowner ro on r.resourceid=ro.resourceid inner join departmentdefinition dd on ro.deptid=dd.deptid where dd.siteid is null

                  New to ADManager Plus?

                    New to ADSelfService Plus?

                      • Related Articles

                      • Query to show Asset state history ( MSSQL)

                        Tested in MSSQL build (14306) SELECT res.resourcename 'Asset Name', res.assettag 'Asset Tag',res.serialno 'Asset Serial No.', rs2.statedesc 'Previous State',rs1.statedesc 'Current State',DATEADD(s,DATEDIFF(s,GETUTCDATE() ,getdate()) + ...
                      • Script for Mandating Asset field in Request Creation/Edit page

                        Please Use the below script in FAFR to mandate Asset field in the Request Creation/Edit page if(jQuery("#selectedCIs").val() == ""){ alert("Asset(s) field cannot be empty."); $CS.stopFormSubmission(); }
                      • Blank screen while opening timesheet

                        Issue : While opening a timesheet, the page appears blank like the below screenshot Cause : The issue occurs if the date format is set to dd.mm.yyyy Solution : Please login as the user, click on the user badge on the top right corner, click on ...
                      • Hide Asset

                        Use case If Technicians want to hide Asset field during template loading, then the same can be achieved using Execute Script option in Field and Form Rules. Solution Edit the incident/service template from which the asset needs to be hidden, choose ...
                      • Unable to add or edit account and bill rule in 10.6 builds

                        Error Trace [09:46:20:508]|[04-28-2022]|[SYSERR]|[INFO]|[47]: Caused by: org.json.JSONException: JSONObject["udf_fields"] not found.| Fix * Stop Servicedeskplus-msp service. * Navigate to \ManageEngine\ServiceDeskPlus-MSP\conf\entity_conf and take a ...