FHW2 (32)    ORDER DIALOG (101.41)

Name Value
NAME FHW2
ITEMS
  • SEQUENCE:   1
    HELP MESSAGE:   Enter the date to begin delivery of this tray, up to 30 days ahead.
    ENTRY ACTION:   S $P(ORDIALOG(PROMPT,0),":",2)="T+30" D:ORCAT="O" ENDT^ORCDFHO
    ITEM:   OR GTX START DATE
    EXIT ACTION:   N X,Y,%DT S X=$G(ORDIALOG(PROMPT,INST)),%DT="X" I $L(X) D ^%DT S:Y>0 ORDATE=$P(Y,".") D:ORCAT="O" EXDT^ORCDFHO(X)
    REQUIRED:   YES
    ASK ON ACTION:   W
  • SEQUENCE:   2
    HELP MESSAGE:   Enter the date to end delivery of this tray, up to 30 days ahead.
    ASK ON CONDITION:   I ORCAT'="O"
    POST-SELECTION ACTION:   I $$FTDCOMP^ORCD("START DATE","END DATE",">") K DONE W $C(7),!,"Cannot end before start date!",!
    DEFAULT:   S Y=$$VAL^ORCD("START DATE")
    ENTRY ACTION:   S $P(ORDIALOG(PROMPT,0),":",2)="T+30"
    ITEM:   OR GTX STOP DATE
    DISPLAY TEXT:   End Date:
    REQUIRED:   YES
    ASK ON ACTION:   W
  • SEQUENCE:   4
    HELP MESSAGE:   Enter the meal for delivery of this tray.
    ASK ON CONDITION:   I ORCAT'="O"
    POST-SELECTION ACTION:   I $G(ORESET),ORESET'=ORDIALOG(PROMPT,ORI) K ORDIALOG($$PTR^ORCD("OR GTX ORDERABLE ITEM"),1),ORDIALOG($$PTR^ORCD("OR GTX MEAL TIME"),1)
    XECUTABLE HELP:   D SETLIST^ORCD
    ITEM:   OR GTX MEAL
    EXIT ACTION:   S ORMEAL=$G(ORDIALOG(PROMPT,INST))
    ORDER TEXT SEQUENCE:   2
    LEADING TEXT:   for
    TRAILING TEXT:   meal
    REQUIRED:   YES
  • SEQUENCE:   5
    INDEX:   S.E/L T
    HELP MESSAGE:   Select the type of tray to be delivered, either EARLY or LATE.
    SCREEN:   I $$ACTIVE^ORDD43(Y)
    POST-SELECTION ACTION:   Q:$$NOTIMES^ORCDFH(ORMEAL,+Y) I $G(ORESET),ORESET'=ORDIALOG(PROMPT,ORI) K ORDIALOG($$PTR^ORCD("OR GTX MEAL TIME"),1)
    XECUTABLE HELP:   N IDX,SCR S IDX=$G(ORDIALOG(PROMPT,"D")),SCR=$G(ORDIALOG(PROMPT,"S")) D XHELP^ORDD43(IDX,SCR)
    ITEM:   OR GTX ORDERABLE ITEM
    EXIT ACTION:   S ORTRAY=+$G(ORDIALOG(PROMPT,INST))
    DISPLAY TEXT:   Early or Late:
    REQUIRED:   YES
  • SEQUENCE:   6
    HELP MESSAGE:   Enter the desired delivery time for this tray.
    ASK ON CONDITION:   I $G(ORDIALOG(PROMPT,"LIST"))>1
    POST-SELECTION ACTION:   D CKTIME^ORCDFH I '$G(DONE) W !,ORDIALOG(PROMPT,"?") D LIST^ORCD
    XECUTABLE HELP:   D LIST^ORCD
    DEFAULT:   D MEALS^ORCDFH N TOT S TOT=+$G(ORDIALOG(PROMPT,"LIST")) S:TOT=1 Y=$P(ORDIALOG(PROMPT,"LIST",$O(ORDIALOG(PROMPT,"LIST",""))),U,2) D:TOT>1 LIST^ORCD
    ITEM:   OR GTX MEAL TIME
    REQUIRED:   YES
  • SEQUENCE:   3
    INPUT TRANSFORM:   S X=$$UP^XLFSTR(X)
    HELP MESSAGE:   Enter the days of the week to deliver this tray, e.g. MWF; choose from (M)onday, (T)uesday, (W)ednesday, Thu(R)sday, (F)riday, (S)aturday, and Sunday(X).
    ASK ON CONDITION:   I ORCAT'="O",$$FTDCOMP^ORCD("END DATE","START DATE",">")
    POST-SELECTION ACTION:   I '$$SCHEDOK^ORCDFH(ORDIALOG(PROMPT,ORI)) K DONE W $C(7),!,ORDIALOG(PROMPT,"?"),!
    ITEM:   OR GTX SCHEDULE
    ORDER TEXT SEQUENCE:   4
    LEADING TEXT:   every
    DISPLAY TEXT:   Days of Week:
    REQUIRED:   YES
  • SEQUENCE:   7
    HELP MESSAGE:   Enter YES if this meal is to be bagged.
    ASK ON CONDITION:   I $P($G(ORPARAM(2)),U,10)="Y"
    ITEM:   OR GTX YES/NO
    DISPLAY TEXT:   Bagged Meal:
DISPLAY TEXT Early/Late Tray
ENTRY ACTION D EN^ORCDFH,EN2^ORCDFH
QUICK SETUP S ORCAT=""
TYPE dialog
EXIT ACTION D EX^ORCDFH K ORMEAL,ORTRAY,ORDATE
DISPLAY GROUP EARLY/LATE TRAYS
WINDOW FORM ID 117
SIGNATURE REQUIRED NONE
PACKAGE DIETETICS
VERIFY ORDER YES
TIMESTAMP 2024-09-03 10:47:29