% % post-reserved interaction % % intercept change, post-pickup ack, new pickup code % *skedresp { *skedcurs "Current status for " &_Sked.Name &" of " &_Sked.Company catcr _Sked.Slot any? "skedstatslot" log)( { % % there is a Pickup active, either coming up, happedning now, or already past % *skedspan _Sked.InWindow { % % the driver should be picking up now % &"You are within the Pickup time slot of " } { % % this Pickup slot has past, or in the future % _Sked.InPast { % % past time for pickup slot % &"It is past the Pickup time slot of " } { % % the pickup is in the future % &"Your next Pickup time slot is coming up at " } ifelse &"(" &_Sked.Stime &") on " _Sked.Date " " left$ & catcr } ifelse } { % % there is no currently scheduled slot % &"No scheduled Pickup." } ifelse _Sked.IsDocket { % % they just sent a Pickup number % &"You sent us a Pickup number." _docket *skedhasd { &"That Pickup number " &_docket &" has already been scheduled on " &_Sked.Already &"." } { _docket !Sked.Docket "ReqDate" *skednumb catcr &"Let's schedule the new Pickup." catcr &"Please text a date for scheduled visit, a six digit date (example 011423)." catcr &"Text the letter x to end the scheduling process for the Pickup number." } ifelse } { trim catcr &"Text a Pickup number (xxxxxxx-x.x), to schedule." catcr } ifelse _Sked.IsDate { } { } ifelse } { % % not valid message % "No Status" } ifelse *skedxmit /* _Sked.IsDocket { % % they just sent a Pickup number % &"You sent us a Pickup number," _Sked.IsSame { % % the same Pickup number was sent % &" the same as the current one." catcr } { % % a different Pickup number was sent % &" different than the current one." catcr % % determine the context of the pickup number sent % _Sked.InFuture { % % a pickup is scheduled already, this must be a correction % &"This Pickup number will replace any already scheduled." catcr } { % % the previous pickup number is currently happening or in the past % _Sked.InPast { % % this must be a new Pickup, see if the prior one has been satisfied % &"This is a new Pickup number," _Sked.PriorDocket any)? { % % the previous pickup has not been acknowledged % "ReqDone" *skednumb catcr &"Did you pick up the previous shipment? Please text y or n." } { % % there was no unacked pickup, schedule the new pickup % &" Let's schedule the new Pickup." catcr "ReqToday" *skednumb &"Will you be picking up today? Please text y or n." } ifelse } { % % driver should be picking up now, check for being within the time slot now % _Sked.InWindow { % % pickup should be happening now, check for arrived % this must be a correction % &"This Pickup number will replace any already scheduled." catcr } { % % there is not a scheduled pickup, wasn't future, within, or past % there was no unacked pickup, schedule the new pickup % "ReqDate" *skednumb &" Let's schedule the new Pickup." catcr &"Please text a date for scheduled visit, a six digit date (example 011423)." */ /* &" Let's schedule the new Pickup." catcr "ReqToday" *skednumb &"Will you be picking up today? Please text y or n." */ /* } ifelse } ifelse } ifelse } ifelse } { % % no docket number was sent % } ifelse */ /* % % gather status % "Status Pickup(Past " _Sked.InPast 1 right & &", Within " _Sked.InWindow 1 right & &", Future " _Sked.InFuture 1 right & &", IsDate " _Sked.IsDate 1 right & &", SameDate " _Sked.SameDate 1 right & &")" catcr "Status Message(Change " _Sked.IsChange 1 right & &", Pickup# " _Sked.IsDocket 1 right & &", Same# " _Sked.IsSame 1 right & &", Message " _Sked.IsMessage 1 right & &", Admin " _Sked.IsAdmin 1 right & _Sked.IsAdmin { &", Command " _Sked.Command & } if &")" catcr & */ /* % % show the current pickup number that is active % the driver may have sent a pickup number just now % the prior pickup number shows if it was different than the one possibly sent % _Sked.PriorDocket any)? { % % a different pickup number was just sent % &"The current Pickup number is: " &_Sked.PriorDocket catcr } { % % the same pickup number possibly just sent % _Sked.Docket any)? { % % has a current pickup number already or the same one was just sent % &"The current Pickup number is: " &_Sked.Docket catcr } { % % the last pickup was accomplished % &"There is no current Pickup number." catcr % % this should not occur since there is a slot assigned % request the docket number % "ReqDock" *skednumb &"Please text the Pickup number (xxxxxxx-x.x)." } ifelse } ifelse */