Difference between revisions of "Archiving Records"

From SmartWiki
Jump to: navigation, search
Line 1: Line 1:
 +
==Overview==
 +
This article outlines the procedures for archiving and unarchiving records within the SmartSimple Cloud system. It covers how to manage records' visibility by toggling their archived status, thereby improving system performance and ensuring data is easily retrievable when needed. Key features include filtering records based on their archival status, detailed steps for using the Batch Update feature for both archiving and unarchiving, and the use of the @archived@ system variable for conditional visibility and editing of records.
 +
Additionally, the article describes an alternative method for unarchiving records individually through custom JavaScript, offering a solution for a custom control.
  
 
==Archiving Records==
 
==Archiving Records==
Line 5: Line 8:
 
These records can also be removed from the archive as and when necessary.
 
These records can also be removed from the archive as and when necessary.
  
Both of these are possible using the [[Batch Update]] feature.  
+
Both of these are possible using the [[Batch Update]] feature.
:[[Image:ArchivingBatchUpdate.png]]
 
  
 +
: [[Image:ArchivingBatchUpdate.png]]
 
==Search Records==
 
==Search Records==
 
 
Searches can be filtered based on whether or not the object has been archived.
 
Searches can be filtered based on whether or not the object has been archived.
:[[Image:SearchArchived.png]]
 
:The above image of the Level 1 search shows how to filter for only records that have been Archived.
 
:To filter for records that are not archived simply search using normal criteria.
 
  
 +
: [[Image:SearchArchived.png]]
 +
: The above image of the Level 1 search shows how to filter for only records that have been Archived.
 +
: To filter for records that are not archived simply search using normal criteria.
 
==Archive Records==
 
==Archive Records==
 
1 Use the Search / Filter option to return the list of records that are to archived.
 
1 Use the Search / Filter option to return the list of records that are to archived.
Line 20: Line 22:
 
2 Once the search is complete select the records to be archived using the check boxes in the search screen.
 
2 Once the search is complete select the records to be archived using the check boxes in the search screen.
  
:[[Image:Archive.png]]
+
: [[Image:Archive.png]]
 
 
 
3 Click the Batch Update button.
 
3 Click the Batch Update button.
  
4 In the resulting screen select the Archived option from the '''Update Archive to''' drop-down list.  
+
4 In the resulting screen select the Archived option from the '''Update Archive to''' drop-down list.
 
 
:[[Image:ArchiveSelect.png]]
 
  
5 Then click the '''Batch Update''' button.  
+
: [[Image:ArchiveSelect.png]]
 +
5 Then click the '''Batch Update''' button.
  
 
6 Click OK on any windows related to the execution of workflows.
 
6 Click OK on any windows related to the execution of workflows.
  
:[[Image:ArchiveWorkflow.png]]
+
: [[Image:ArchiveWorkflow.png]]
 
 
 
7 User should get a confirmation screen to notify them that everything has been updated successfully.
 
7 User should get a confirmation screen to notify them that everything has been updated successfully.
  
:[[Image:ArchiveConfirmation.png]]
+
: [[Image:ArchiveConfirmation.png]]
 
+
8 The list view should also update to reflect that fact that the selected records have now been archived.
8 The list view should also update to reflect that fact that the selected records have now been archived.  
 
  
 
==Unarchive Records==
 
==Unarchive Records==
Line 45: Line 43:
 
2 Select the records to be unarchived using the check boxes in the search screen.
 
2 Select the records to be unarchived using the check boxes in the search screen.
  
3 In the resulting screen select the Not Archived option from the '''Update Archive to''' drop-down list.  
+
3 In the resulting screen select the Not Archived option from the '''Update Archive to''' drop-down list.
 
 
:[[Image:Unarchive.png]]
 
  
4 Then click the '''Batch Update''' button.  
+
: [[Image:Unarchive.png]]
 +
4 Then click the '''Batch Update''' button.
  
 
5 Click OK on any windows related to the execution of workflows.
 
5 Click OK on any windows related to the execution of workflows.
Line 55: Line 52:
 
6 User should get a confirmation screen to notify them that everything has been updated successfully.
 
6 User should get a confirmation screen to notify them that everything has been updated successfully.
  
:[[Image:ArchiveConfirmation.png]]
+
: [[Image:ArchiveConfirmation.png]]
 +
7 The list view should also update to reflect that fact that the selected records are no longer archived.
  
7 The list view should also update to reflect that fact that the selected records are no longer archived.
 
  
  
 
==Referencing the field==
 
==Referencing the field==
You can use the @archived@ variable to reference the archive status of a UTA L1 object, where 1 = Archived and 0 = Not-Archived.
+
You can use the @archived@ variable to reference the archive status of a UTA L1 object, where 1 = Archived and 0 = Not-Archived.
  
 
This can be used within conditional statements such as visibility and edit conditions to display/hide fields based on the object's archive status.
 
This can be used within conditional statements such as visibility and edit conditions to display/hide fields based on the object's archive status.
 +
  
  
 
==Unarchiving records without using Batch Update==
 
==Unarchiving records without using Batch Update==
An alternative method for unarchiving involves using [[Pandora]] in a custom javascript button. The sample code below is to be used within a [[Custom Field Type: Read Only – System Variables]] field.  
+
An alternative method for unarchiving involves using [[Pandora]] in a custom javascript button. The sample code below is to be used within a [[Custom Field Type: Read Only – System Variables]] field.
  
 
This method is best used in combination with a report built to list all archived records, with a hyperlink for each record.
 
This method is best used in combination with a report built to list all archived records, with a hyperlink for each record.
  
 
The process for the user will be:
 
The process for the user will be:
#The report is run where a record can be filtered according to search criteria.
+
 
#The user will click on a hyperlink into the record where the "Unarchive" button will be exposed.
+
# The report is run where a record can be filtered according to search criteria.
#Upon clicking the button, the record will be unarchived where it will now re-appear when searched within the UTA.
+
# The user will click on a hyperlink into the record where the "Unarchive" button will be exposed.
 +
# Upon clicking the button, the record will be unarchived where it will now re-appear when searched within the UTA.
  
  
<pre>
 
//Displays a button where when clicked will call the "unarchive()" function
 
  
<input type=Button class=Button value="Unarchive Record" onClick="unarchive();">
+
<pre>//Displays a button where when clicked will call the "unarchive()" function
  
<script type="text/javascript">
+
<input class="Button" type="Button" value="Unarchive Record" />
 +
<script type="text/javascript">// <![CDATA[
 
function unarchive(){
 
function unarchive(){
 
updatefields('archived',0);  //Sets Archived flag to 0
 
updatefields('archived',0);  //Sets Archived flag to 0
Line 99: Line 97:
 
var rs=levelone_update(false ,'',gbappid,rset);
 
var rs=levelone_update(false ,'',gbappid,rset);
 
}
 
}
</script>
+
// ]]></script>
 
</pre>
 
</pre>
 
==See Also==
 
==See Also==

Revision as of 06:15, 5 April 2024

Overview

This article outlines the procedures for archiving and unarchiving records within the SmartSimple Cloud system. It covers how to manage records' visibility by toggling their archived status, thereby improving system performance and ensuring data is easily retrievable when needed. Key features include filtering records based on their archival status, detailed steps for using the Batch Update feature for both archiving and unarchiving, and the use of the @archived@ system variable for conditional visibility and editing of records. Additionally, the article describes an alternative method for unarchiving records individually through custom JavaScript, offering a solution for a custom control.

Archiving Records

Level 1 records can be archived so they no longer appear in the Level 1 list view.

These records can also be removed from the archive as and when necessary.

Both of these are possible using the Batch Update feature.

ArchivingBatchUpdate.png

Search Records

Searches can be filtered based on whether or not the object has been archived.

SearchArchived.png
The above image of the Level 1 search shows how to filter for only records that have been Archived.
To filter for records that are not archived simply search using normal criteria.

Archive Records

1 Use the Search / Filter option to return the list of records that are to archived.

2 Once the search is complete select the records to be archived using the check boxes in the search screen.

Archive.png

3 Click the Batch Update button.

4 In the resulting screen select the Archived option from the Update Archive to drop-down list.

ArchiveSelect.png

5 Then click the Batch Update button.

6 Click OK on any windows related to the execution of workflows.

ArchiveWorkflow.png

7 User should get a confirmation screen to notify them that everything has been updated successfully.

ArchiveConfirmation.png

8 The list view should also update to reflect that fact that the selected records have now been archived.

Unarchive Records

1 Use the Search / Filter option to return the list of Archived records.

2 Select the records to be unarchived using the check boxes in the search screen.

3 In the resulting screen select the Not Archived option from the Update Archive to drop-down list.

Unarchive.png

4 Then click the Batch Update button.

5 Click OK on any windows related to the execution of workflows.

6 User should get a confirmation screen to notify them that everything has been updated successfully.

ArchiveConfirmation.png

7 The list view should also update to reflect that fact that the selected records are no longer archived.


Referencing the field

You can use the @archived@ variable to reference the archive status of a UTA L1 object, where 1 = Archived and 0 = Not-Archived.

This can be used within conditional statements such as visibility and edit conditions to display/hide fields based on the object's archive status.


Unarchiving records without using Batch Update

An alternative method for unarchiving involves using Pandora in a custom javascript button. The sample code below is to be used within a Custom Field Type: Read Only – System Variables field.

This method is best used in combination with a report built to list all archived records, with a hyperlink for each record.

The process for the user will be:

  1. The report is run where a record can be filtered according to search criteria.
  2. The user will click on a hyperlink into the record where the "Unarchive" button will be exposed.
  3. Upon clicking the button, the record will be unarchived where it will now re-appear when searched within the UTA.


//Displays a button where when clicked will call the "unarchive()" function

<input class="Button" type="Button" value="Unarchive Record" />
<script type="text/javascript">// <![CDATA[
function unarchive(){
	updatefields('archived',0);  //Sets Archived flag to 0
}

function updatefields(fieldname,fielddata){
	ss_developer_key="xxxxx";   //Enter Developer Key
	var gbappid=xxxxx;   //Enter application ID
	
	var addfields="opportunityid,"+fieldname;
	var rset=new ssRecordSet(null);
	rset.addfieldnames(addfields);
	var idx=rset.getnewrecnumber();
	rset.addfieldvaluebyname(idx,'opportunityid','@opportunityid@');
	rset.addfieldvaluebyname(idx,fieldname,fielddata);
	var rs=levelone_update(false ,'',gbappid,rset);
}
// ]]></script>

See Also