Member LSTVLDL in WEBSECURE / QRPGLESRC

1.00
       *********************************************************************
2.00
       *  RPG ILE MODULE WEBSECURE/LSTVLDL
3.00
       *  List validation list entries
4.00
       *
5.00
       *  After compiling this RPG MODULE,
6.00
       *  create the related program with the following command:
7.00
       *
8.00
       *  CRTPGM WEBSECURE/WRKVLDL MODULE(WEBSECURE/WRKVLDL
9.00
       *         WEBSECURE/WRKVLDLE WEBSECURE/LSTVLDL WEBSECURE/GETVLDLE)
10.00
       *         ACTGRP(WRKVLDL) AUT(*USE)
11.00
       *
12.00
       *=====================================================
13.00
       *  The following parameters must be passed
14.00
       *  1-Validation list name               char 10
15.00
       *  2-Validation list library name       char 10
16.00
       *  3-Return code                        char  1
17.00
       *    blank=operation performed
18.00
       *    X    = some error
19.00
       *
20.00
       *********************************************************************
21.00
       *--------------------------------------------------------------------
22.00
       * Prototype definitions and standard system API error structure
23.00
       *--------------------------------------------------------------------
24.00
       /copy websecure/qrpglesrc,hspecs
25.00
       /copy websecure/qrpglesrc,hspecsbnd
26.00
       /copy WEBSECURE/qrpglesrc,prototypeb
27.00
       /copy WEBSECURE/qrpglesrc,usec
28.00
       /copy WEBSECURE/qrpglesrc,variables3
29.00
       *=====================================================================
30.00
       *
31.00
      D VldlNam         s             10a
32.00
      D VldlLib         s             10a
33.00
      D RetCode         s              1a
34.00
       *
35.00
      D VldlETy         s              1a
36.00
      D VldlE           s           1700a
37.00
      D PwdLen          s             10i 0
38.00
      D DtaLen          s             10i 0
39.00
       *
40.00
      D                 ds
41.00
      DVldlEData                1   1700
42.00
      D UsrNam                  1    100
43.00
      D UsrPwd                101    700
44.00
      D UsrData               701   1700
45.00
       *
46.00
      D seq             s             10i 0
47.00
      D DspPwd          s              1a
48.00
       *
49.00
       *=====================================================================
50.00
       * *entry parameter list
51.00
       *===========================================================================
52.00
      C     *entry        plist
53.00
      C                   parm                    VldlNam
54.00
      C                   parm                    VldlLib
55.00
      C                   parm                    RetCode
56.00
       *
57.00
      C                   eval      VldlNam = uppify(VldlNam)
58.00
      C                   eval      VldlLib = uppify(VldlLib)
59.00
       * List internet users
60.00
      C                   exsr      LstIntUsr
61.00
       * Back to caller
62.00
      C                   exsr      Exit
63.00
       *=====================================================================******
64.00
       * List internet users
65.00
       *=====================================================================******
66.00
      C     LstIntUsr     begsr
67.00
      C                   eval      RC = 0
68.00
      C                   eval      seq = 0
69.00
       *
70.00
       * Get the 1st entry
71.00
      C                   eval      VldlETy = '1'
72.00
      C                   exsr      GetVldlE
73.00
      C                   exsr      LstVldlE
74.00
       * Get the next entries
75.00
      C                   dow       RC = 0
76.00
      C                   eval      VldlETy = 'N'
77.00
      C                   exsr      GetVldlE
78.00
      C                   exsr      LstVldlE
79.00
      C                   enddo
80.00
       *
81.00
      C                   endsr
82.00
       *=====================================================================
83.00
       *  Get a Vldl Entry
84.00
       *=====================================================================
85.00
      C     GetVldlE      begsr
86.00
      C                   callb     'GETVLDLE'
87.00
      C                   parm                    VldlNam
88.00
      C                   parm                    VldlLib
89.00
      C                   parm                    VldlETy
90.00
      C                   parm                    VldlE
91.00
      C                   parm                    PwdLen
92.00
      C                   parm                    DtaLen
93.00
      C                   parm                    RC
94.00
      C                   eval      VldlEData = VldlE
95.00
      C                   endsr
96.00
       *=====================================================================
97.00
       *  List out a validation list entry
98.00
       *=====================================================================
99.00
      C     LstVldlE      begsr
100.00
       * If not end of validation list entries
101.00
      C                   IF        RC = 0
102.00
      C                   exsr      WrtRow
103.00
       * If end of validation list entries
104.00
      C                   ELSE
105.00
      C                   if        seq > 0
106.00
      C                   callp     wrtsection('tabend')
107.00
      C                   else
108.00
      C                   callp     wrtsection('none')
109.00
      C                   endif
110.00
      C                   exsr      Exit
111.00
      C                   ENDIF
112.00
      C                   endsr
113.00
       *=====================================================================
114.00
       * Set html variable data  (displaying validation list entries)
115.00
       * and list current validation list entry
116.00
       *=====================================================================
117.00
      C     WrtRow        begsr
118.00
       * Sequence
119.00
      C                   eval      seq = seq +1
120.00
      C                   if        seq = 1
121.00
      C                   callp     wrtsection('tabstr')
122.00
      C                   endif
123.00
      C                   callp     updhtmlvar('SEQ':
124.00
      C                             %trim(%editc(seq:'J')))
125.00
       * User name
126.00
      C                   callp     updHtmlVar('USRNAM':UsrNam)
127.00
       * User password
128.00
      C                   if        pwdlen > 0
129.00
      C                   callp     updHtmlVar('USRPWD':
130.00
      C                             %subst(usrpwd:1:pwdlen))
131.00
      C                   else
132.00
      C                   callp     updHtmlVar('USRPWD':' ')
133.00
      C                   endif
134.00
       * User description
135.00
      C                   if        dtalen > 0
136.00
      C                   callp     updHtmlVar('USRTXT':
137.00
      C                             %subst(UsrData:1:dtalen))
138.00
      C                   else
139.00
      C                   callp     updHtmlVar('USRTXT':' ')
140.00
      C                   endif
141.00
       * Write list row
142.00
      C                   callp     wrtsection('tabrow')
143.00
      C                   endsr
144.00
       *=====================================================================
145.00
       * Back to caller
146.00
       *=====================================================================
147.00
      C     Exit          begsr
148.00
      C                   return
149.00
      C                   endsr
0.030 sec.s