📄 fix_pay.ec
字号:
printf(" 本金:"); prtf_dnum(x,13); printf(" 利息:"); prtf_dnum(interes1+maint_v,13); printf("\n%c%c%c%c%c",12,27,'[','4','i'); move(20,20); addspace(50); move(20,20); mess((short)44); mess((short)4); getch(); strcpy(na,nam); s_n=s_num[0]; a_n=a_num; cu_t=cu_type[0]; te=ter[0]; b_n=b_num; prtf_inte(k,int_date,x,x+interes1+maint_v); interes1+=(x+maint_v); if(cred_type==11) { switch(toupper(cu_type[0])) { case 'C': case 'F': case 'M': case 'P': case 'U': interes1-=(long)interes1; break; case 'J': interes1-=(((long)(interes1/1000.0))*1000.0); break; case 'H': interes1-=(((long)(interes1/10.0))*10.0); } if(interes1>0.005) { i=toupper(cu_type[0])-64; z=get_rmb(i,interes1,&y); move(20,20); addspace(50); move(20,20); mess((short)58); mess((short)4); getch(); printf("%c%c%c%c\n\n\n\n\n",27,'[','5','i'); addspacef(20); printf("%-8s",nam); addspacef(40); printf("%4d年%2d月%2d日\n\n",year,month,day); addspacef(20); prtf_inum((long)s_num[0],2); putchar('-'); prtf_inum(a_num,9); printf("\n\n\n"); addspacef(10); switch(toupper(cu_type[0])) { case 'U': printf("US$"); break; case 'J': printf("Jap¥"); break; case 'H': printf("HK$"); break; case 'M': printf("DM"); break; case 'P': printf("£"); break; case 'F': printf("FF"); break; case 'C': printf("Can$"); } prtf_dnum(interes1,9); addspacef(18); printf("%10.4f",y*100); addspacef(16); prtf_dnum(z,9); printf("\n%c%c%c%c%c",12,27,'[','4','i'); c=cu_type[0]; cu_type[0]=toupper(c); move(20,20); addspace(50); move(20,20); for(i=0;i<5;i++) { $ insert into f_blot values (0,$ope_num,$s_num,$a_num,$nam,$s_type,$cu_type, $ter,$cr_num,"X",$interes1,$z,0.0); if(sqlca.sqlcode!=-271) break; printw("*"); refresh(); delay(5l); } cu_type[0]=c; if(sqlca.sqlcode==-271) { mess((short)73); flag=1; } else if(sqlca.sqlcode!=0) { addstr("写"); mess((short)16); printw("(%d), ",sqlca.sqlcode); flag=1; } } } } if(flag==0) { move(20,20); addspace(50); move(20,22); addstr("请输入新的凭证号"); amoun-=x; maint_v=0.0; move(7,48); prt_dnum(amoun,16); move(10,48); printw("%4d年%2d月%2d日",year,month,day); while(1) { move(9,20); c=readdv(&x,7); cr_num=x; move(9,20); addspace(10); move(9,20); prt_inum(cr_num,7); $ select cre_num from credential where op_num=$ope_num and cre_type=$cred_type and cre_num=$cr_num; move(20,22); addspace(40); if(sqlca.sqlcode!=0) { move(20,28); mess((short)11); mess((short)2); } else break; } cred_num=cr_num+100000000; $ update credential set cre_num=$cred_num where op_num=$ope_num and cre_type= $cred_type and cre_num=$cr_num; if(sqlca.sqlerrd[2]!=1) { move(20,20); addstr("写"); mess((short)10); printw("(%d), ",sqlca.sqlerrd[2]); flag=1; } } if(flag==0) { a_num=ac_num(cred_type); move(3,52); prt_inum(a_num,9); move(20,20); ope_date=las_date=year*10000+month*100+day; statu[0]='A'; if(cred_type==1) { $ insert into r_fix values ($s_num,$a_num,$nam,$pas,$cu_type,$ter,$amoun, $addres,$cr_num,$ope_date,$int_date,$statu, $las_date,$interes,$maint_v); } else { $ insert into f_fix values ($s_num,$a_num,$nam,$pas,$cu_type,$ter,$amoun, $addres,$cr_num,$ope_date,$int_date,$statu, $las_date,$interes,$maint_v); } if(sqlca.sqlcode!=0) { addstr("写"); mess((short)14); printw("(%d), ",sqlca.sqlcode); flag=1; } } if(flag==0) { c=cu_type[0]; cu_type[0]=toupper(c); for(i=0;i<5;i++) { if(cred_type==1) { $ insert into r_blot values (0,$ope_num,$s_num,$a_num,$nam,$s_type, $cu_type,$ter,$cr_num,"R",$amoun,$amoun,0); } else { $ insert into f_blot values (0,$ope_num,$s_num,$a_num,$nam,$s_type, $cu_type,$ter,$cr_num,"R",$amoun,$amoun,0); } if(sqlca.sqlcode!=-271) break; printw("*"); refresh(); delay(5l); } if(sqlca.sqlcode==-271) { mess((short)73); flag=1; } else if(sqlca.sqlcode!=0) { addstr("写"); mess((short)16); printw("(%d), ",sqlca.sqlcode); flag=1; } } if(flag==0) { if(cred_type==1) { $ open blot1; $ fetch last blot1 into $b_num; $ close blot1; } else { $ open blot2; $ fetch last blot2 into $b_num; $ close blot2; } cu_type[0]=c; $ insert into open_acc values ($s_num,$s_type,$cu_type,$ter,$a_num,$nam, $addres,$amoun,$ope_num); if(sqlca.sqlcode!=0) { addstr("写"); mess((short)17); printw("(%d), ",sqlca.sqlcode); flag=1; } } if(flag==0) { year1=int_date/10000; month1=(int_date%10000)/100; day1=int_date%100; mess((short)42); mess((short)4); getch(); printf("[5i%c%c%c%c%c",27,'%','9',1,20); printf("\n 凭证号: "); prtf_inum(cr_num,7); printf("\n"); addspacef(28); printf("%4d %2d %2d %2d时%2d分\n\n\n\n\n\n\n\n\n\n", year,month,day,ti/100,ti%100); addspacef(11); printf("%-8s ",nam); prtf_inum(s_num[0],2); printf("-"); prtf_inum(a_num,9); printf(" "); prtf_dnum(amoun,14); printf(" "); if(pas!=0)printf(" 密 "); else printf(" "); if(ter[0]<12) printf("%1d月",ter[0]); else printf("%1d年",ter[0]/12); printf(" %5.3f",interes*1.2); printf("\n\n"); addspacef(15); printf("%d-%2d-%2d ",year,month,day); printf(" %d-%2d-%2d ",year1,month1, day1); month2=month1+ter[0]; year2=year1+((month2-1)/12); month2=((month2-1)%12)+1; printf(" %4d-%2d-%2d ",year2, month2,day1); printf(" %d ",b_num); printf(" %-6s\f\n",st); printf("[4i"); move(20,20); mess((short)43); mess((short)4); getch(); if(toupper(cu_type[0])=='R') { printf("%c%c%c%c%c%c%c%c\n\n\n\n", 27,'[','5','i',28,'q',27,']'); addspacef(19); printf("%-8s",nam); addspacef(25); prtf_inum(s_num[0],2); printf("-"); prtf_inum(a_num,9); printf("\n"); printf("%c%c\n\n",28,'p'); addspacef(16); prtf_upper(amoun,toupper(cu_type[0])); printf("\n"); addspacef(16); printf("RMB¥"); prtf_dnum(amoun,13); printf("%c%c\n\n\n\n",28,'q'); printf(" %4d-%2d-%2d",year,month,day); prtf_dnum(amoun,14); if(ter[0]<12) printf(" %1d月",ter[0]); else printf(" %1d年",ter[0]/12); printf(" %5.3f",interes*1.2); printf(" %4d-%2d-%2d ",year1,month1,day1); printf("%4d-%2d-%2d",year2, month2,day1); prtf_dnum(amoun*interes*ter[0]*0.001, 13); printf(" %-6s\f\n",st); printf("%c%c%c%c", 27,'[','4','i'); } else { printf("%c%c%c%c%c%c%c%c\n", 27,'[','5','i',27,']',28,'p'); printf(" ┏━━━━┓\n"); printf(" ┃"); switch(toupper(cu_type[0])) { case 'U': printf("%-8s"," 美 元 "); break; case 'J': printf("%-8s"," 日 元 "); break; case 'H': printf("%-8s"," 港 元 "); break; case 'M': printf("%-8s","德国马克"); break; case 'P': printf("%-8s"," 英 镑 "); break; case 'F': printf("%-8s","法国法郎"); break; case 'C': printf("%-8s","加拿大元"); } printf("┃\n"); printf(" ┗━━━━┛\n"); printf("%c%c\n",28,'q'); printf(" 部份提支日期: %4d年%2d月%2d日" ,year,month,day); addspacef(49); printf("%4d-%2d-%2d\n",int_date/10000, (int_date%10000)/100,int_date%100); printf(" 原帐号: "); prtf_inum((long)s_num[0],2); putchar('-'); prtf_inum(a_num1,9); printf("\n\n\n"); printf("%c%c %-8s%c%c", 27,'[',nam,27,']'); addspacef(36); prtf_inum((long)s_num[0],2); putchar('-'); prtf_inum(a_num,9); addspacef(18); switch(toupper(cu_type[0])) {
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -