100 likes | 335 Views
Tech Talk: How to Extend Checklist Functionality. Tim Climis Rebecca Swords. Outline. Checklist Structure Basics Task extensions Live Example: Immigration Document Creation. Checklist Terminology. Family, Genus, Species, Subspecies Family = campus + e-form group + checklist type
E N D
Tech Talk: How to Extend Checklist Functionality Tim Climis Rebecca Swords
Outline • Checklist Structure Basics • Task extensions • Live Example: Immigration Document Creation
Checklist Terminology • Family, Genus, Species, Subspecies • Family = campus + e-form group + checklist type • Genus = Admit Type / Domestic,International • Species = Term / Student type • Subspecies = Application / Transcript / Course • SpeciesKey = Family|Genus|Species (F2|FYL|4128 – Bloomington Graduate Admission First-Year Law for Fall 2012)
Checklist Table Structure • jbChecklist: associates student, subspecies, and (jb)E-Form Group; produces “checklistID” • jbChecklistSpeciesKey: associates SpeciesKey to a checklistID • jbChecklistStage: records Stage History for checklistID • jbChecklistOfficeTask: records completed Office Tasks for a checklistID
What’s a Task Extension? • Task Extensions allow a task to be automatically set to a particular status under certain conditions. • For example, automatically mark English Proficiency as Approved if TOEFL scores are high enough. • Valid statuses: any code in codeEForm
Task Type Creation Basics • Create a Task Type in codeChecklistOfficeTaskType • Set the type for the Office Task when configuring it on a Checklist • Create a stored procedure in the database called checklistTaskExtension<taskTypeCode>(ex. checklistTaskExtensionC001) • Add that stored procedure to dataFeedChecklistTaskExtensions
Creating the Stored Procedure CREATEPROCEDURE[dbo].[checklistTaskExtensionC011]AS BEGIN SETNOCOUNTON; INSERTINTOjbChecklistOfficeTaskExtQueue(idnumber,checklistID,officeTaskID,status) SELECT viewChecklistTaskExtHelper.idnumber, viewChecklistTaskExtHelper.checklistID, viewChecklistTaskExtHelper.officeTaskID, CASE WHENjbChecklistSpeciesKey.speciesKeyLIKE'%4132' THEN'Approved' ELSE'NA' ENDASstatus FROMviewChecklistTaskExtHelper INNERJOINjbChecklistSpeciesKey ONviewChecklistTaskExtHelper.idnumber=jbChecklistSpeciesKey.idnumber ANDviewChecklistTaskExtHelper.checklistID=jbChecklistSpeciesKey.checklistID WHEREviewChecklistTaskExtHelper.taskType=‘C011' END
Write a SELECT Query • Select the students you want to be checked, the task to set, and the status to set to. • Use viewChecklistTaskExtHelper like a function • TaskID = viewChecklistTaskExtHelper(student, checklist, taskType)
Let’s Write a Task Extension • Sunapsis comes with an extension for marking immigration documents as created but it doesn’t handle change of level well • Let’s make our own
Take-aways • Understand the basics of Checklists’ underlying structure • Know what a task extension is, and how to write one