w_outware_pos_rebate.srw 4.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207
  1. $PBExportHeader$w_outware_pos_rebate.srw
  2. forward
  3. global type w_outware_pos_rebate from w_publ_base
  4. end type
  5. type cb_1 from uo_imflatbutton within w_outware_pos_rebate
  6. end type
  7. type st_1 from statictext within w_outware_pos_rebate
  8. end type
  9. type st_mtrlname from statictext within w_outware_pos_rebate
  10. end type
  11. type em_1 from editmask within w_outware_pos_rebate
  12. end type
  13. type st_2 from statictext within w_outware_pos_rebate
  14. end type
  15. type st_3 from statictext within w_outware_pos_rebate
  16. end type
  17. end forward
  18. global type w_outware_pos_rebate from w_publ_base
  19. integer width = 1481
  20. integer height = 704
  21. boolean titlebar = false
  22. string title = ""
  23. boolean controlmenu = false
  24. boolean minbox = false
  25. windowtype windowtype = response!
  26. cb_1 cb_1
  27. st_1 st_1
  28. st_mtrlname st_mtrlname
  29. em_1 em_1
  30. st_2 st_2
  31. st_3 st_3
  32. end type
  33. global w_outware_pos_rebate w_outware_pos_rebate
  34. type variables
  35. s_pos_rebate_tran s_rt_stru
  36. end variables
  37. event open;call super::open;s_rt_stru = message.powerobjectparm
  38. em_1.text = string(s_rt_stru.prerebate * 100)
  39. st_mtrlname.text = string(s_rt_stru.mtrlname)
  40. em_1.setfocus()
  41. s_rt_stru.if_ok = 0
  42. end event
  43. on w_outware_pos_rebate.create
  44. int iCurrent
  45. call super::create
  46. this.cb_1=create cb_1
  47. this.st_1=create st_1
  48. this.st_mtrlname=create st_mtrlname
  49. this.em_1=create em_1
  50. this.st_2=create st_2
  51. this.st_3=create st_3
  52. iCurrent=UpperBound(this.Control)
  53. this.Control[iCurrent+1]=this.cb_1
  54. this.Control[iCurrent+2]=this.st_1
  55. this.Control[iCurrent+3]=this.st_mtrlname
  56. this.Control[iCurrent+4]=this.em_1
  57. this.Control[iCurrent+5]=this.st_2
  58. this.Control[iCurrent+6]=this.st_3
  59. end on
  60. on w_outware_pos_rebate.destroy
  61. call super::destroy
  62. destroy(this.cb_1)
  63. destroy(this.st_1)
  64. destroy(this.st_mtrlname)
  65. destroy(this.em_1)
  66. destroy(this.st_2)
  67. destroy(this.st_3)
  68. end on
  69. event close;call super::close;closewithreturn(this,s_rt_stru)
  70. end event
  71. type cb_func from w_publ_base`cb_func within w_outware_pos_rebate
  72. boolean visible = false
  73. integer y = 804
  74. end type
  75. type cb_exit from w_publ_base`cb_exit within w_outware_pos_rebate
  76. integer x = 882
  77. integer y = 508
  78. string text = "退出[ESC]"
  79. string normalpicname = ""
  80. end type
  81. event cb_exit::clicked;s_rt_stru.if_ok = 0
  82. close(parent)
  83. end event
  84. type cb_1 from uo_imflatbutton within w_outware_pos_rebate
  85. integer x = 320
  86. integer y = 508
  87. integer width = 311
  88. integer height = 96
  89. integer taborder = 30
  90. boolean bringtotop = true
  91. string text = "确定[ENT]"
  92. boolean default = true
  93. end type
  94. event clicked;call super::clicked;if dec(em_1.text)<0 or dec(em_1.text)>100 then
  95. openwithparm(w_pos_msg,'请输入合理的折扣数值!')
  96. em_1.setfocus()
  97. em_1.selecttext( 1, len(em_1.text))
  98. return
  99. end if
  100. s_rt_stru.if_ok = 1
  101. s_rt_stru.newrebate = dec(em_1.text) / 100
  102. close(parent)
  103. end event
  104. type st_1 from statictext within w_outware_pos_rebate
  105. integer x = 137
  106. integer y = 132
  107. integer width = 558
  108. integer height = 48
  109. boolean bringtotop = true
  110. integer textsize = -9
  111. integer weight = 400
  112. fontcharset fontcharset = gb2312charset!
  113. fontpitch fontpitch = variable!
  114. string facename = "宋体"
  115. long textcolor = 16711680
  116. long backcolor = 134217739
  117. string text = "商品名称:"
  118. boolean focusrectangle = false
  119. end type
  120. type st_mtrlname from statictext within w_outware_pos_rebate
  121. integer x = 137
  122. integer y = 196
  123. integer width = 1216
  124. integer height = 48
  125. boolean bringtotop = true
  126. integer textsize = -9
  127. integer weight = 700
  128. fontcharset fontcharset = gb2312charset!
  129. fontpitch fontpitch = variable!
  130. string facename = "宋体"
  131. long textcolor = 33554432
  132. long backcolor = 67108864
  133. alignment alignment = center!
  134. boolean focusrectangle = false
  135. end type
  136. type em_1 from editmask within w_outware_pos_rebate
  137. integer x = 370
  138. integer y = 324
  139. integer width = 384
  140. integer height = 84
  141. integer taborder = 30
  142. boolean bringtotop = true
  143. integer textsize = -9
  144. integer weight = 700
  145. fontcharset fontcharset = gb2312charset!
  146. fontpitch fontpitch = variable!
  147. string facename = "宋体"
  148. long textcolor = 33554432
  149. string text = "00"
  150. borderstyle borderstyle = stylelowered!
  151. string mask = "###,###"
  152. end type
  153. event getfocus;this.selecttext( 1, len(this.text))
  154. end event
  155. type st_2 from statictext within w_outware_pos_rebate
  156. integer x = 137
  157. integer y = 340
  158. integer width = 192
  159. integer height = 48
  160. boolean bringtotop = true
  161. integer textsize = -9
  162. integer weight = 400
  163. fontcharset fontcharset = gb2312charset!
  164. fontpitch fontpitch = variable!
  165. string facename = "宋体"
  166. long textcolor = 16711680
  167. long backcolor = 134217739
  168. string text = "折扣:"
  169. boolean focusrectangle = false
  170. end type
  171. type st_3 from statictext within w_outware_pos_rebate
  172. integer x = 782
  173. integer y = 340
  174. integer width = 453
  175. integer height = 48
  176. boolean bringtotop = true
  177. integer textsize = -9
  178. integer weight = 700
  179. fontcharset fontcharset = gb2312charset!
  180. fontpitch fontpitch = variable!
  181. string facename = "宋体"
  182. long textcolor = 255
  183. long backcolor = 134217739
  184. string text = "例如:8折用80"
  185. boolean focusrectangle = false
  186. end type