#define MAXFIELDS 44
#define O_PARTNUM             0
#define N_PARTNUM             0
#define O_GROUP              21
#define N_GROUP               1
#define O_DESCR              32
#define N_DESCR               2
#define O_QUANTITY           73
#define N_QUANTITY            3
#define O_SOURCE             82
#define N_SOURCE              4
#define O_NAME               85
#define N_NAME                5
#define O_CARLINE           116
#define N_CARLINE             6
#define O_ORDERPNT          124
#define N_ORDERPNT            7
#define O_SEASONAL          126
#define N_SEASONAL            8
#define O_CRASH             128
#define N_CRASH               9
#define O_LOC               130
#define N_LOC                10
#define O_BINCAP            138
#define N_BINCAP             11
#define O_MINQTY            143
#define N_MINQTY             12
#define O_REFUSALS          148
#define N_REFUSALS           13
#define O_ALTBIN            150
#define N_ALTBIN             14
#define O_RTN               158
#define N_RTN                15
#define O_REPACK            160
#define N_REPACK             16
#define O_HAZARDOUS         162
#define N_HAZARDOUS          17
#define O_UPAC              164
#define N_UPAC               18
#define O_WAREHOUSE         169
#define N_WAREHOUSE          19
#define O_CLASS             173
#define N_CLASS              20
#define O_QUICK             175
#define N_QUICK              21
#define O_NEW_USED          196
#define N_NEW_USED           22
#define O_COST              198
#define N_COST               23
#define O_TRADE             206
#define N_TRADE              24
#define O_LIST              214
#define N_LIST               25
#define O_PERCENT           222
#define N_PERCENT            26
#define O_SPECIAL           228
#define N_SPECIAL            27
#define O_WCOMP             236
#define N_WCOMP              28
#define O_ADVERT            244
#define N_ADVERT             29
#define O_DISC1             252
#define N_DISC1              30
#define O_DISC2             260
#define N_DISC2              31
#define O_RESERVE           268
#define N_RESERVE            32
#define O_FIRSTYEAR         276
#define N_FIRSTYEAR          33
#define O_LASTYEAR          281
#define N_LASTYEAR           34
#define O_FMM               286
#define N_FMM                35
#define O_FDD               289
#define N_FDD                36
#define O_FYY               292
#define N_FYY                37
#define O_LMM               297
#define N_LMM                38
#define O_LDD               300
#define N_LDD                39
#define O_LYY               303
#define N_LYY                40
#define O_RECMM             308
#define N_RECMM              41
#define O_RECDD             311
#define N_RECDD              42
#define O_RECYY             314
#define N_RECYY              43
#include	<jcs/nfldstr.h>

int classp(int,FLD *,char *);
int ddp(int,FLD *,char *);
int lyyp(int,FLD *,char *);
int minqtyp(int,FLD *,char *);
int mmp(int,FLD *,char *);
int modyearp(int,FLD *,char *);
int new_usedp(int,FLD *,char *);
int noinit(FLD *,char *);
int noop(int,FLD *,char *);
int partnump(int,FLD *,char *);
int pricep(int,FLD *,char *);
int rsp(int,FLD *,char *);
int rtnp(int,FLD *,char *);
int sourcep(int,FLD *,char *);
int ssp(int,FLD *,char *);
int upacp(int,FLD *,char *);
int yesnop(int,FLD *,char *);
int yyp(int,FLD *,char *);
int	cks_newpart(int,FLD *,char *);
int	erx_newpart(void);
int	fky_newpart(int,FLD *,char *);
void	bg_newpart(int);
#define FBUFLENGTH 319
#ifdef	MAIN

void bg_newpart(line)
int line;
{
  switch  (line)  {
  case  0:
    pos(0,0);
    cls();
  case   1:
      pos(1,1);
      hon();
      pos(1,2);
      fputs("SYSTEM 1 BY JARVIS COMPUTER SOFTWARE.",stdout);
      pos(1,39);
      hoff();
  case   2:
  case   3:
      pos(3,1);
      hon();
      pos(3,2);
      fputs("PART NUMBER:",stdout);
      pos(3,14);
      hoff();
      pos(3,36);
      hon();
      pos(3,37);
      fputs("GROUP:",stdout);
      pos(3,43);
      hoff();
      pos(3,54);
      hon();
      pos(3,55);
      fputs("DESCRIPTION:",stdout);
      pos(3,67);
      hoff();
  case   4:
  case   5:
      pos(5,1);
      hon();
      pos(5,2);
      fputs("QUANTITY ON HAND:",stdout);
      pos(5,19);
      hoff();
      pos(5,34);
      hon();
      pos(5,35);
      fputs("SOURCE:",stdout);
      pos(5,42);
      hoff();
  case   6:
  case   7:
      pos(7,1);
      hon();
      pos(7,2);
      fputs("CAR LINES:",stdout);
      pos(7,12);
      hoff();
      pos(7,34);
      hon();
      pos(7,35);
      fputs("ORDER POINT CODE (N/V):",stdout);
      pos(7,58);
      hoff();
  case   8:
  case   9:
      pos(9,1);
      hon();
      pos(9,2);
      fputs("SEASONAL (Y/N):",stdout);
      pos(9,17);
      hoff();
      pos(9,34);
      hon();
      pos(9,35);
      fputs("PRO PART (CODE):",stdout);
      pos(9,51);
      hoff();
  case  10:
  case  11:
      pos(11,1);
      hon();
      pos(11,2);
      fputs("BIN LOCATION:",stdout);
      pos(11,15);
      hoff();
      pos(11,25);
      hon();
      pos(11,26);
      fputs("BIN CAP:",stdout);
      pos(11,34);
      hoff();
      pos(11,41);
      hon();
      pos(11,42);
      fputs("BIN MIN:",stdout);
      pos(11,50);
      hoff();
      pos(11,60);
      hon();
      pos(11,61);
      fputs("REFUSALS:",stdout);
      pos(11,70);
      hoff();
  case  12:
      pos(12,6);
      hon();
      pos(12,7);
      fputs("ALT BIN:",stdout);
      pos(12,15);
      hoff();
  case  13:
      pos(13,1);
      hon();
      pos(13,2);
      fputs("RETURNABLE (CODE):",stdout);
      pos(13,20);
      hoff();
      pos(13,34);
      hon();
      pos(13,35);
      fputs("REPACK (CODE):",stdout);
      pos(13,49);
      hoff();
      pos(13,53);
      hon();
      pos(13,54);
      fputs("HAZARDOUS:",stdout);
      pos(13,64);
      hoff();
  case  14:
  case  15:
      pos(15,9);
      hon();
      pos(15,10);
      fputs("UNIT PACK:",stdout);
      pos(15,20);
      hoff();
      pos(15,28);
      hon();
      pos(15,29);
      fputs("WAREHOUSE:",stdout);
      pos(15,39);
      hoff();
      pos(15,48);
      hon();
      pos(15,49);
      fputs("CLASS (P,G,O,A,T,S,U,M):",stdout);
      pos(15,73);
      hoff();
  case  16:
      pos(16,1);
      hon();
      pos(16,2);
      fputs("QUICK REFERENCE:",stdout);
      pos(16,18);
      hoff();
      pos(16,48);
      hon();
      pos(16,49);
      fputs("NEW/USED (N/U):",stdout);
      pos(16,64);
      hoff();
  case  17:
      pos(17,1);
      hon();
      pos(17,2);
      fputs("PRICING ",stdout);
      pos(17,10);
      hoff();
  case  18:
      pos(18,7);
      hon();
      pos(18,8);
      fputs("COST:",stdout);
      pos(18,13);
      hoff();
      pos(18,34);
      hon();
      pos(18,35);
      fputs("TRADE:",stdout);
      pos(18,41);
      hoff();
      pos(18,57);
      hon();
      pos(18,58);
      fputs("LIST:",stdout);
      pos(18,63);
      hoff();
      pos(18,77);
      fputs("%",stdout);
  case  19:
      pos(19,4);
      hon();
      pos(19,5);
      fputs("SPECIAL:",stdout);
      pos(19,13);
      hoff();
      pos(19,35);
      hon();
      pos(19,36);
      fputs("CORE:",stdout);
      pos(19,41);
      hoff();
      pos(19,55);
      hon();
      pos(19,56);
      fputs("ADVERT:",stdout);
      pos(19,63);
      hoff();
      pos(19,65);
      hoff();
  case  20:
      pos(20,1);
      hon();
      pos(20,2);
      fputs("DISC.COST1:",stdout);
      pos(20,13);
      hoff();
      pos(20,29);
      hon();
      pos(20,30);
      fputs("DISC.COST2:",stdout);
      pos(20,41);
      hoff();
      pos(20,54);
      hon();
      pos(20,55);
      fputs("RESERVE:",stdout);
      pos(20,63);
      hoff();
  case  21:
      pos(21,36);
      hon();
      pos(21,37);
      fputs("FIRST YEAR OF FIT:",stdout);
      pos(21,55);
      hoff();
      pos(21,61);
      hon();
      pos(21,62);
      fputs("LAST YEAR:",stdout);
      pos(21,72);
      hoff();
  case  22:
      pos(22,1);
      hon();
      pos(22,2);
      fputs("FIRST WEEK:",stdout);
      pos(22,13);
      hoff();
      pos(22,17);
      fputs("-  -",stdout);
      pos(22,27);
      hon();
      pos(22,28);
      fputs("LAST WEEK:",stdout);
      pos(22,38);
      hoff();
      pos(22,41);
      fputs("-  -",stdout);
      pos(22,50);
      hon();
      pos(22,51);
      fputs("RECEIVE DATE: ",stdout);
      pos(22,65);
      hoff();
      pos(22,67);
      fputs("-  -",stdout);
  case  23:
      pos(23,1);
      fputs("esc=SAVE DATA.  F5=RETURN TO MENU.  F1=CLEAR CURRENT FIELD.  F7=HELP.",stdout);
  case  24:
      pos(24,1);
      fputs("F2=NEXT RECORD. F3=OPTIONS.  F4=PREVIOUS RECORD. F6=DELETE RECORD.",stdout);
      break;
  }
}
FLD field_newpart[MAXFIELDS]  = {
 3,15,20,0+MAYENT+MUSTENT,RIGHT,' ',ANY,UPPER,   0,   0,partnump,noinit,0,/*PARTNUM*/
 3,44,10,0+MAYENT,RIGHT,' ',NUMERIC,UPPER,  21,   1,noop,noinit,0,/*GROUP*/
 3,68,12,0+MAYENT+MUSTENT,LEFT,' ',ANY,UPPER,  32,   2,noop,noinit,28,/*DESCR*/
 5,20, 8,0+MAYENT,RIGHT,' ',DIGIT,UPPER,  73,   3,noop,noinit,0,/*QUANTITY*/
 5,43, 2,0+MAYENT+MUSTENT,RIGHT,' ',DIGIT,UPPER,  82,   4,sourcep,noinit,0,/*SOURCE*/
 5,47,30,0,LEFT,' ',ANY,NOCASE,  85,   5,noop,noinit,0,/*NAME*/
 7,13, 7,0+MAYENT,LEFT,' ',ANY,UPPER, 116,   6,noop,noinit,0,/*CARLINE*/
 7,59, 1,0+MAYENT,LEFT,' ',ALPHA,UPPER, 124,   7,rsp,noinit,0,/*ORDERPNT*/
 9,18, 1,0+MAYENT+MUSTENT,LEFT,' ',ALPHA,UPPER, 126,   8,ssp,noinit,0,/*SEASONAL*/
 9,52, 1,0+MAYENT,LEFT,' ',ANY,NOCASE, 128,   9,noop,noinit,0,/*CRASH*/
11,16, 7,0+MAYENT,LEFT,' ',ANY,UPPER, 130,  10,noop,noinit,0,/*LOC*/
11,36, 4,0+MAYENT,RIGHT,' ',DIGIT,UPPER, 138,  11,noop,noinit,0,/*BINCAP*/
11,51, 4,0+MAYENT,RIGHT,' ',DIGIT,UPPER, 143,  12,minqtyp,noinit,0,/*MINQTY*/
11,71, 1,0+MAYENT,RIGHT,' ',DIGIT,UPPER, 148,  13,noop,noinit,0,/*REFUSALS*/
12,16, 7,0+MAYENT,LEFT,' ',ANY,UPPER, 150,  14,noop,noinit,0,/*ALTBIN*/
13,21, 1,0+MAYENT,LEFT,' ',ALPHA,UPPER, 158,  15,rtnp,noinit,0,/*RTN*/
13,50, 1,0+MAYENT,LEFT,' ',ANY,NOCASE, 160,  16,noop,noinit,0,/*REPACK*/
13,65, 1,0+MAYENT,NOJUST,' ',ANY,UPPER, 162,  17,yesnop,noinit,0,/*HAZARDOUS*/
15,21, 4,0+MAYENT,RIGHT,' ',DIGIT,UPPER, 164,  18,upacp,noinit,0,/*UPAC*/
15,41, 3,0+MAYENT,LEFT,' ',ANY,UPPER, 169,  19,noop,noinit,0,/*WAREHOUSE*/
15,74, 1,0+MAYENT,LEFT,' ',ALPHA,UPPER, 173,  20,classp,noinit,0,/*CLASS*/
16,19,20,0+MAYENT,LEFT,' ',ANY,UPPER, 175,  21,noop,noinit,0,/*QUICK*/
16,65, 1,0+MAYENT,LEFT,' ',ALPHA,UPPER, 196,  22,new_usedp,noinit,0,/*NEW_USED*/
18,14, 7,0+MAYENT,RIGHT,' ',NUMERIC,NOCASE, 198,  23,pricep,noinit,0,/*COST*/
18,42, 7,0+MAYENT,RIGHT,' ',NUMERIC,NOCASE, 206,  24,pricep,noinit,0,/*TRADE*/
18,64, 7,0+MAYENT,RIGHT,' ',NUMERIC,NOCASE, 214,  25,pricep,noinit,0,/*LIST*/
18,72, 5,0,RIGHT,' ',DIGIT,NOCASE, 222,  26,noop,noinit,0,/*PERCENT*/
19,14, 7,0+MAYENT,RIGHT,' ',NUMERIC,NOCASE, 228,  27,pricep,noinit,0,/*SPECIAL*/
19,42, 7,0+MAYENT,RIGHT,' ',NUMERIC,NOCASE, 236,  28,pricep,noinit,0,/*WCOMP*/
19,64, 7,0+MAYENT,RIGHT,' ',NUMERIC,NOCASE, 244,  29,pricep,noinit,0,/*ADVERT*/
20,14, 7,0+MAYENT,RIGHT,' ',NUMERIC,NOCASE, 252,  30,pricep,noinit,0,/*DISC1*/
20,42, 7,0+MAYENT,RIGHT,' ',NUMERIC,NOCASE, 260,  31,pricep,noinit,0,/*DISC2*/
20,64, 7,0+MAYENT,RIGHT,' ',NUMERIC,NOCASE, 268,  32,pricep,noinit,0,/*RESERVE*/
21,56, 4,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 276,  33,modyearp,noinit,0,/*FIRSTYEAR*/
21,73, 4,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 281,  34,modyearp,noinit,0,/*LASTYEAR*/
22,15, 2,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 286,  35,mmp,noinit,0,/*FMM*/
22,18, 2,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 289,  36,ddp,noinit,0,/*FDD*/
22,21, 4,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 292,  37,yyp,noinit,0,/*FYY*/
22,39, 2,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 297,  38,mmp,noinit,0,/*LMM*/
22,42, 2,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 300,  39,ddp,noinit,0,/*LDD*/
22,45, 4,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 303,  40,lyyp,noinit,0,/*LYY*/
22,65, 2,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 308,  41,mmp,noinit,0,/*RECMM*/
22,68, 2,0+MAYENT,RIGHT,'0',DIGIT,UPPER, 311,  42,ddp,noinit,0,/*RECDD*/
22,71, 4,0+MAYENT,RIGHT,' ',DIGIT,UPPER, 314,  43,yyp,noinit,0,/*RECYY*/
};

char	fbuf_newpart[319];
SCR	screen_newpart    = {
field_newpart,
fbuf_newpart,
fky_newpart,
cks_newpart,
erx_newpart,
bg_newpart,
MAXFIELDS,
0,
1,
1,
24,
80
};
#else
extern	char	fbuf_newpart[319];
extern SCR screen_newpart;
extern FLD field_newpart[MAXFIELDS];
#endif
