w_planprice_saletask_add.srw 5.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239
  1. $PBExportHeader$w_planprice_saletask_add.srw
  2. forward
  3. global type w_planprice_saletask_add from w_publ_base
  4. end type
  5. type em_1 from editmask within w_planprice_saletask_add
  6. end type
  7. type em_2 from editmask within w_planprice_saletask_add
  8. end type
  9. type st_1 from statictext within w_planprice_saletask_add
  10. end type
  11. type st_2 from statictext within w_planprice_saletask_add
  12. end type
  13. type st_3 from statictext within w_planprice_saletask_add
  14. end type
  15. type cb_ok from uo_imflatbutton within w_planprice_saletask_add
  16. end type
  17. end forward
  18. global type w_planprice_saletask_add from w_publ_base
  19. integer width = 1591
  20. integer height = 724
  21. string title = "增加销售订单产品"
  22. boolean minbox = false
  23. windowtype windowtype = response!
  24. em_1 em_1
  25. em_2 em_2
  26. st_1 st_1
  27. st_2 st_2
  28. st_3 st_3
  29. cb_ok cb_ok
  30. end type
  31. global w_planprice_saletask_add w_planprice_saletask_add
  32. type variables
  33. s_edit_index_tran ins_s_return
  34. end variables
  35. on w_planprice_saletask_add.create
  36. int iCurrent
  37. call super::create
  38. this.em_1=create em_1
  39. this.em_2=create em_2
  40. this.st_1=create st_1
  41. this.st_2=create st_2
  42. this.st_3=create st_3
  43. this.cb_ok=create cb_ok
  44. iCurrent=UpperBound(this.Control)
  45. this.Control[iCurrent+1]=this.em_1
  46. this.Control[iCurrent+2]=this.em_2
  47. this.Control[iCurrent+3]=this.st_1
  48. this.Control[iCurrent+4]=this.st_2
  49. this.Control[iCurrent+5]=this.st_3
  50. this.Control[iCurrent+6]=this.cb_ok
  51. end on
  52. on w_planprice_saletask_add.destroy
  53. call super::destroy
  54. destroy(this.em_1)
  55. destroy(this.em_2)
  56. destroy(this.st_1)
  57. destroy(this.st_2)
  58. destroy(this.st_3)
  59. destroy(this.cb_ok)
  60. end on
  61. event close;call super::close;closewithreturn(this,ins_s_return)
  62. end event
  63. event open;call super::open;
  64. s_edit_index_tran INS_RT_STRU
  65. INS_RT_STRU = Message.PowerObjectParm
  66. IF IsValid(INS_RT_STRU) THEN
  67. IF INS_RT_STRU.b_long = 1 THEN
  68. This.Title = '增加销售订单产品'
  69. st_3.Text = '请设置增加到价格表的日期范围'
  70. ELSEIF INS_RT_STRU.b_long = 2 THEN
  71. This.Title = '增加生产进仓单产品'
  72. st_3.Text = '请设置增加到价格表的日期范围'
  73. END IF
  74. END IF
  75. end event
  76. type cb_func from w_publ_base`cb_func within w_planprice_saletask_add
  77. boolean visible = false
  78. end type
  79. type cb_exit from w_publ_base`cb_exit within w_planprice_saletask_add
  80. integer x = 859
  81. integer y = 448
  82. integer width = 302
  83. integer height = 100
  84. integer picsize = 16
  85. end type
  86. event cb_exit::clicked;ins_s_return.b_long = 0
  87. Close(Parent)
  88. end event
  89. type em_1 from editmask within w_planprice_saletask_add
  90. integer x = 370
  91. integer y = 208
  92. integer width = 416
  93. integer height = 84
  94. integer taborder = 30
  95. boolean bringtotop = true
  96. integer textsize = -9
  97. integer weight = 400
  98. fontcharset fontcharset = gb2312charset!
  99. fontpitch fontpitch = variable!
  100. string facename = "宋体"
  101. long textcolor = 33554432
  102. string text = "none"
  103. alignment alignment = center!
  104. borderstyle borderstyle = stylelowered!
  105. maskdatatype maskdatatype = datemask!
  106. string mask = "yyyy-mm-dd"
  107. boolean dropdowncalendar = true
  108. end type
  109. event constructor;This.Text = String(Today(),'yyyy-mm-')+'01'
  110. end event
  111. type em_2 from editmask within w_planprice_saletask_add
  112. integer x = 923
  113. integer y = 208
  114. integer width = 416
  115. integer height = 84
  116. integer taborder = 40
  117. boolean bringtotop = true
  118. integer textsize = -9
  119. integer weight = 400
  120. fontcharset fontcharset = gb2312charset!
  121. fontpitch fontpitch = variable!
  122. string facename = "宋体"
  123. long textcolor = 33554432
  124. string text = "none"
  125. alignment alignment = center!
  126. borderstyle borderstyle = stylelowered!
  127. maskdatatype maskdatatype = datemask!
  128. string mask = "yyyy-mm-dd"
  129. boolean dropdowncalendar = true
  130. end type
  131. event constructor;This.Text = String(Today(),'yyyy-mm-dd')
  132. end event
  133. type st_1 from statictext within w_planprice_saletask_add
  134. integer x = 55
  135. integer y = 224
  136. integer width = 288
  137. integer height = 48
  138. boolean bringtotop = true
  139. integer textsize = -9
  140. integer weight = 400
  141. fontcharset fontcharset = gb2312charset!
  142. fontpitch fontpitch = variable!
  143. string facename = "宋体"
  144. long textcolor = 33554432
  145. long backcolor = 134217739
  146. string text = "单据日期从"
  147. alignment alignment = right!
  148. boolean focusrectangle = false
  149. end type
  150. type st_2 from statictext within w_planprice_saletask_add
  151. integer x = 800
  152. integer y = 224
  153. integer width = 105
  154. integer height = 48
  155. boolean bringtotop = true
  156. integer textsize = -9
  157. integer weight = 400
  158. fontcharset fontcharset = gb2312charset!
  159. fontpitch fontpitch = variable!
  160. string facename = "宋体"
  161. long textcolor = 33554432
  162. long backcolor = 134217739
  163. string text = "到"
  164. alignment alignment = center!
  165. boolean focusrectangle = false
  166. end type
  167. type st_3 from statictext within w_planprice_saletask_add
  168. integer x = 215
  169. integer y = 72
  170. integer width = 1111
  171. integer height = 48
  172. boolean bringtotop = true
  173. integer textsize = -9
  174. integer weight = 400
  175. fontcharset fontcharset = gb2312charset!
  176. fontpitch fontpitch = variable!
  177. string facename = "宋体"
  178. long textcolor = 255
  179. long backcolor = 134217739
  180. string text = "请设置增加到计划成本价的日期范围"
  181. alignment alignment = center!
  182. boolean focusrectangle = false
  183. end type
  184. type cb_ok from uo_imflatbutton within w_planprice_saletask_add
  185. integer x = 398
  186. integer y = 448
  187. integer taborder = 20
  188. boolean bringtotop = true
  189. string normalpicname = "ok.bmp"
  190. integer picsize = 16
  191. end type
  192. event clicked;call super::clicked;DateTime ldt_sdate,ldt_edate
  193. ldt_sdate = DateTime(Date(em_1.Text),Time(0))
  194. ldt_edate = DateTime(Date(em_2.Text),Time('23:59:59'))
  195. If ldt_sdate > ldt_edate Then
  196. MessageBox('系统提示','请设置正确的日期范围')
  197. Return
  198. End If
  199. ins_s_return.first_date = ldt_sdate
  200. ins_s_return.end_date = ldt_edate
  201. ins_s_return.b_long = 1
  202. Close(Parent)
  203. end event