w_rp_owwfjg_in.srw 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593
  1. $PBExportHeader$w_rp_owwfjg_in.srw
  2. forward
  3. global type w_rp_owwfjg_in from w_publ_easyq
  4. end type
  5. type ddlb_2 from dropdownlistbox within w_rp_owwfjg_in
  6. end type
  7. type ddlb_3 from uo_ddlb_storageid within w_rp_owwfjg_in
  8. end type
  9. type tv_1 from uo_tv_mtrltype within w_rp_owwfjg_in
  10. end type
  11. type ddlb_status from dropdownlistbox within w_rp_owwfjg_in
  12. end type
  13. type ddlb_1 from dropdownlistbox within w_rp_owwfjg_in
  14. end type
  15. type ddlb_scid from uo_ddlb_scid within w_rp_owwfjg_in
  16. end type
  17. type st_5 from statictext within w_rp_owwfjg_in
  18. end type
  19. type cb_other from uo_imflatbutton within w_rp_owwfjg_in
  20. end type
  21. end forward
  22. global type w_rp_owwfjg_in from w_publ_easyq
  23. integer width = 3662
  24. integer height = 2044
  25. string title = "外协进仓统计表"
  26. event ue_retrieve_info ( )
  27. ddlb_2 ddlb_2
  28. ddlb_3 ddlb_3
  29. tv_1 tv_1
  30. ddlb_status ddlb_status
  31. ddlb_1 ddlb_1
  32. ddlb_scid ddlb_scid
  33. st_5 st_5
  34. cb_other cb_other
  35. end type
  36. global w_rp_owwfjg_in w_rp_owwfjg_in
  37. type variables
  38. Long cur_storageid_arr[]
  39. Int cur_mtrlorigin = -1
  40. String ls_handtype = ''
  41. Long cur_flag = -1
  42. Long cur_secflag = -1
  43. Long cur_thflag = -1
  44. long cur_scid_arr[]
  45. long cur_billtype = 4
  46. end variables
  47. forward prototypes
  48. public function integer wf_hide_col ()
  49. public subroutine wf_hidecol ()
  50. end prototypes
  51. event ue_retrieve_info();Long ll_row
  52. Long ll_mtrlid
  53. ll_row = dw_1.GetRow()
  54. IF ll_row <= 0 THEN
  55. ll_mtrlid = 0
  56. ELSE
  57. ll_mtrlid = dw_1.Object.mtrlid[ll_row]
  58. END IF
  59. IF IsValid(w_mtrl_info) THEN
  60. w_mtrl_info.WindowState = Normal!
  61. w_mtrl_info.ins_mtrlid = ll_mtrlid
  62. w_mtrl_info.wf_retrieve(ll_mtrlid)
  63. END IF
  64. end event
  65. public function integer wf_hide_col ();//s_hide_col s_col
  66. //
  67. //IF dw_1.DataObject = 'dw_rp_owwfjg_in' THEN
  68. // s_col.col_1 = 'ow_wfjgmx_in_aft_jgprice'
  69. // s_col.col_2 = 'ow_wfjgmx_in_aft_rebate'
  70. // s_col.col_3 = 'priceamt'
  71. // s_col.col_4 = 'ow_wfjgmx_in_aft_cost'
  72. // s_col.col_5 = 'costamt'
  73. //ELSEIF dw_1.DataObject = 'dw_rp_owwfjg_in_ws' THEN
  74. // s_col.col_1 = 'ow_wfjgmx_in_aft_jgprice'
  75. // s_col.col_2 = 'ow_wfjgmx_in_aft_rebate'
  76. // s_col.col_3 = 'priceamt'
  77. // s_col.col_4 = 'ow_wfjgmx_in_aft_cost'
  78. // s_col.col_5 = 'costamt'
  79. //ELSEIF dw_1.DataObject = 'dw_rp_owwfjg_out_hz_ws' THEN
  80. // s_col.col_1 = 'amt'
  81. // s_col.col_2 = 'price'
  82. // s_col.col_3 = 'planamt'
  83. // s_col.col_4 = 'u_mtrldef_planprice'
  84. //ELSE
  85. // s_col.col_1 = 'amt'
  86. // s_col.col_2 = 'price'
  87. // s_col.col_3 = 'costamt'
  88. //
  89. //END IF
  90. //
  91. ////f_hide_col(121,dw_1,s_col)
  92. //f_hide_col(1448,dw_1,s_col)
  93. //
  94. //s_hide_col s_col_mtrlsectype
  95. //s_col_mtrlsectype.col_1 = 'u_mtrldef_mtrlsectype'
  96. //f_hide_col(1308,dw_1,s_col_mtrlsectype)
  97. //
  98. //s_hide_col s_col_zxmtrlmode
  99. //s_col_zxmtrlmode.col_1 = 'u_mtrldef_zxmtrlmode'
  100. //f_hide_col(1309,dw_1,s_col_zxmtrlmode)
  101. RETURN 1
  102. end function
  103. public subroutine wf_hidecol ();s_hide_col s_col
  104. IF dw_1.DataObject = 'dw_rp_owwfjg_in' THEN
  105. s_col.col_1 = 'ow_wfjgmx_in_aft_jgprice'
  106. s_col.col_2 = 'ow_wfjgmx_in_aft_rebate'
  107. s_col.col_3 = 'priceamt'
  108. s_col.col_4 = 'ow_wfjgmx_in_aft_cost'
  109. s_col.col_5 = 'costamt'
  110. s_col.col_6 = 'ow_wfjgmx_in_aft_fprice'
  111. s_col.col_7 = 'ow_wfjgmx_in_aft_price'
  112. s_col.col_8 = 'famt'
  113. s_col.col_9 = 'amt'
  114. ELSEIF dw_1.DataObject = 'dw_rp_owwfjg_in_ws' THEN
  115. s_col.col_1 = 'ow_wfjgmx_in_aft_jgprice'
  116. s_col.col_2 = 'ow_wfjgmx_in_aft_rebate'
  117. s_col.col_3 = 'priceamt'
  118. s_col.col_4 = 'ow_wfjgmx_in_aft_cost'
  119. s_col.col_5 = 'costamt'
  120. ELSEIF dw_1.DataObject = 'dw_rp_owwfjg_out_hz_ws' THEN
  121. s_col.col_1 = 'amt'
  122. s_col.col_2 = 'price'
  123. s_col.col_3 = 'planamt'
  124. s_col.col_4 = 'u_mtrldef_planprice'
  125. ELSE
  126. s_col.col_1 = 'amt'
  127. s_col.col_2 = 'price'
  128. s_col.col_3 = 'costamt'
  129. END IF
  130. f_hide_col(1448,dw_1,s_col) //隐藏加工价
  131. s_hide_col s_col_mtrlsectype
  132. s_col_mtrlsectype.col_1 = 'u_mtrldef_mtrlsectype'
  133. f_hide_col(1308,dw_1,s_col_mtrlsectype)
  134. s_hide_col s_col_zxmtrlmode
  135. s_col_zxmtrlmode.col_1 = 'u_mtrldef_zxmtrlmode'
  136. f_hide_col(1309,dw_1,s_col_zxmtrlmode)
  137. //RETURN 1
  138. end subroutine
  139. on w_rp_owwfjg_in.create
  140. int iCurrent
  141. call super::create
  142. this.ddlb_2=create ddlb_2
  143. this.ddlb_3=create ddlb_3
  144. this.tv_1=create tv_1
  145. this.ddlb_status=create ddlb_status
  146. this.ddlb_1=create ddlb_1
  147. this.ddlb_scid=create ddlb_scid
  148. this.st_5=create st_5
  149. this.cb_other=create cb_other
  150. iCurrent=UpperBound(this.Control)
  151. this.Control[iCurrent+1]=this.ddlb_2
  152. this.Control[iCurrent+2]=this.ddlb_3
  153. this.Control[iCurrent+3]=this.tv_1
  154. this.Control[iCurrent+4]=this.ddlb_status
  155. this.Control[iCurrent+5]=this.ddlb_1
  156. this.Control[iCurrent+6]=this.ddlb_scid
  157. this.Control[iCurrent+7]=this.st_5
  158. this.Control[iCurrent+8]=this.cb_other
  159. end on
  160. on w_rp_owwfjg_in.destroy
  161. call super::destroy
  162. destroy(this.ddlb_2)
  163. destroy(this.ddlb_3)
  164. destroy(this.tv_1)
  165. destroy(this.ddlb_status)
  166. destroy(this.ddlb_1)
  167. destroy(this.ddlb_scid)
  168. destroy(this.st_5)
  169. destroy(this.cb_other)
  170. end on
  171. event resize;call super::resize;tv_1.height=this.height - dw_1.y - 150
  172. end event
  173. type cb_func from w_publ_easyq`cb_func within w_rp_owwfjg_in
  174. end type
  175. type cb_exit from w_publ_easyq`cb_exit within w_rp_owwfjg_in
  176. integer x = 1477
  177. end type
  178. type cb_2 from w_publ_easyq`cb_2 within w_rp_owwfjg_in
  179. integer x = 1175
  180. integer taborder = 110
  181. boolean bringtotop = true
  182. end type
  183. type cb_psetup from w_publ_easyq`cb_psetup within w_rp_owwfjg_in
  184. integer x = 919
  185. integer taborder = 90
  186. boolean bringtotop = true
  187. end type
  188. type cb_1 from w_publ_easyq`cb_1 within w_rp_owwfjg_in
  189. boolean bringtotop = true
  190. end type
  191. event cb_1::clicked;datetime first_date,end_date
  192. first_date=datetime(date(em_1.text),time(0))
  193. end_date=datetime(date(em_2.text),time('23:59:59'))
  194. //dw_1.uf_read_profile_layout()
  195. //wf_hide_col()
  196. //f_title_change(dw_1)
  197. dw_1.retrieve(cur_scid_arr,cur_storageid_arr,cur_billtype,first_date,end_date,cur_flag,cur_secflag,ls_handtype,cur_thflag,sys_user_spttype)
  198. end event
  199. type st_3 from w_publ_easyq`st_3 within w_rp_owwfjg_in
  200. integer x = 1655
  201. integer y = 216
  202. end type
  203. type st_4 from w_publ_easyq`st_4 within w_rp_owwfjg_in
  204. integer x = 2341
  205. integer y = 216
  206. end type
  207. type em_1 from w_publ_easyq`em_1 within w_rp_owwfjg_in
  208. integer x = 1865
  209. integer y = 196
  210. integer width = 389
  211. integer taborder = 120
  212. end type
  213. type em_2 from w_publ_easyq`em_2 within w_rp_owwfjg_in
  214. integer x = 2446
  215. integer width = 389
  216. integer taborder = 130
  217. end type
  218. type ddlb_yl from w_publ_easyq`ddlb_yl within w_rp_owwfjg_in
  219. integer x = 1897
  220. integer y = 4
  221. end type
  222. type cbx_yl from w_publ_easyq`cbx_yl within w_rp_owwfjg_in
  223. integer x = 1678
  224. integer y = 4
  225. end type
  226. type dw_1 from w_publ_easyq`dw_1 within w_rp_owwfjg_in
  227. integer x = 805
  228. integer y = 308
  229. integer width = 2400
  230. integer height = 1540
  231. string dataobject = "dw_rp_owwfjg_in"
  232. end type
  233. event dw_1::doubleclicked;call super::doubleclicked;String ls_code
  234. Long ll_scid
  235. Int li_thflag
  236. IF dw_1.DataObject = 'dw_rp_owwfjg_in' THEN
  237. IF row > 0 THEN
  238. ll_scid = THIS.Object.ow_wfjg_in_scid[row]
  239. ls_code = THIS.Object.ow_wfjg_in_inwarecode[row]
  240. // li_thflag = THIS.Object.ow_wfjg_in_thflag[row]
  241. f_open_win(ll_scid,ls_code)
  242. END IF
  243. END IF
  244. end event
  245. event dw_1::rowfocuschanged;call super::rowfocuschanged;IF currentrow <=0 THEN RETURN
  246. this.selectrow(0,false)
  247. this.selectrow(currentrow,true)
  248. PARENT.TriggerEvent('ue_retrieve_info')
  249. end event
  250. type sle_mtrl from w_publ_easyq`sle_mtrl within w_rp_owwfjg_in
  251. end type
  252. type sle_cust from w_publ_easyq`sle_cust within w_rp_owwfjg_in
  253. end type
  254. type st_mtrl from w_publ_easyq`st_mtrl within w_rp_owwfjg_in
  255. end type
  256. type st_cust from w_publ_easyq`st_cust within w_rp_owwfjg_in
  257. end type
  258. type cbx_loginretr from w_publ_easyq`cbx_loginretr within w_rp_owwfjg_in
  259. boolean visible = true
  260. integer x = 1678
  261. end type
  262. type pb_em1 from w_publ_easyq`pb_em1 within w_rp_owwfjg_in
  263. integer x = 2258
  264. end type
  265. type pb_em2 from w_publ_easyq`pb_em2 within w_rp_owwfjg_in
  266. integer x = 2839
  267. integer y = 188
  268. end type
  269. type pb_2 from w_publ_easyq`pb_2 within w_rp_owwfjg_in
  270. integer x = 2944
  271. integer y = 188
  272. end type
  273. type cb_help from w_publ_easyq`cb_help within w_rp_owwfjg_in
  274. integer x = 1326
  275. end type
  276. type cb_copyself from w_publ_easyq`cb_copyself within w_rp_owwfjg_in
  277. end type
  278. type gb_1 from w_publ_easyq`gb_1 within w_rp_owwfjg_in
  279. end type
  280. type ln_bar from w_publ_easyq`ln_bar within w_rp_owwfjg_in
  281. end type
  282. type ln_bar2 from w_publ_easyq`ln_bar2 within w_rp_owwfjg_in
  283. end type
  284. type r_bar from w_publ_easyq`r_bar within w_rp_owwfjg_in
  285. integer x = 1865
  286. end type
  287. type ln_1 from w_publ_easyq`ln_1 within w_rp_owwfjg_in
  288. end type
  289. type ln_2 from w_publ_easyq`ln_2 within w_rp_owwfjg_in
  290. end type
  291. type ln_3 from w_publ_easyq`ln_3 within w_rp_owwfjg_in
  292. end type
  293. type ln_4 from w_publ_easyq`ln_4 within w_rp_owwfjg_in
  294. end type
  295. type ddlb_2 from dropdownlistbox within w_rp_owwfjg_in
  296. integer x = 2254
  297. integer y = 36
  298. integer width = 599
  299. integer height = 448
  300. integer taborder = 80
  301. boolean bringtotop = true
  302. integer textsize = -9
  303. integer weight = 400
  304. fontcharset fontcharset = gb2312charset!
  305. fontpitch fontpitch = variable!
  306. string facename = "宋体"
  307. long textcolor = 33554432
  308. string text = "仓库外协收货明细表"
  309. boolean sorted = false
  310. boolean vscrollbar = true
  311. string item[] = {"仓库外协收货明细表","仓库外协收货汇总表","车间外协收货明细表","车间外协收货汇总表"}
  312. borderstyle borderstyle = stylelowered!
  313. end type
  314. event selectionchanged;dw_1.uf_save_profile_layout()
  315. IF ddlb_2.Text = '仓库外协收货明细表' THEN
  316. dw_1.DataObject = 'dw_rp_owwfjg_in'
  317. cur_billtype = 4
  318. ELSEIF ddlb_2.Text = '仓库外协收货汇总表' THEN
  319. dw_1.DataObject = 'dw_rp_owwfjg_in_hz'
  320. cur_billtype = 4
  321. ELSEIF ddlb_2.Text = '车间外协收货明细表' THEN
  322. dw_1.DataObject = 'dw_rp_owwfjg_in'
  323. cur_billtype = 5
  324. ELSEIF ddlb_2.Text = '车间外协收货汇总表' THEN
  325. dw_1.DataObject = 'dw_rp_owwfjg_in_hz'
  326. cur_billtype = 5
  327. END IF
  328. //dw_1.SetTransObject(sqlca)
  329. //
  330. //dw_1.ins_INIfile_name = sys_inifilename
  331. //dw_1.ins_opemp = publ_operator
  332. //dw_1.cardw_empid = sys_empid
  333. //dw_1.cur_DataObject = dw_1.DataObject
  334. wf_replacedw()
  335. //wf_hide_col()
  336. cb_1.TriggerEvent(Clicked!)
  337. end event
  338. type ddlb_3 from uo_ddlb_storageid within w_rp_owwfjg_in
  339. integer x = 823
  340. integer y = 196
  341. integer width = 498
  342. integer height = 1108
  343. integer taborder = 130
  344. boolean bringtotop = true
  345. end type
  346. event constructor;call super::constructor;cur_storageid_arr = this.uo_storageid_arr
  347. end event
  348. event selectionchanged;call super::selectionchanged;cur_storageid_arr = this.uo_storageid_arr
  349. cb_1.triggerevent(clicked!)
  350. end event
  351. type tv_1 from uo_tv_mtrltype within w_rp_owwfjg_in
  352. integer y = 308
  353. integer width = 805
  354. integer height = 1540
  355. integer taborder = 60
  356. boolean bringtotop = true
  357. integer textsize = -9
  358. fontcharset fontcharset = gb2312charset!
  359. fontfamily fontfamily = anyfont!
  360. string facename = "宋体"
  361. end type
  362. event selectionchanged;call super::selectionchanged;ls_handtype = THIS.uo_cur_info.handtype
  363. ls_handtype = ls_handtype + '%'
  364. cb_1.TriggerEvent(clicked!)
  365. end event
  366. type ddlb_status from dropdownlistbox within w_rp_owwfjg_in
  367. integer x = 1339
  368. integer y = 196
  369. integer width = 311
  370. integer height = 296
  371. integer taborder = 70
  372. boolean bringtotop = true
  373. integer textsize = -9
  374. integer weight = 400
  375. fontcharset fontcharset = gb2312charset!
  376. fontpitch fontpitch = variable!
  377. string facename = "宋体"
  378. long textcolor = 33554432
  379. string text = "[全部]"
  380. boolean sorted = false
  381. string item[] = {"[全部]","待收货审","待财务审","审核完毕"}
  382. borderstyle borderstyle = stylelowered!
  383. end type
  384. event selectionchanged;IF Index = 1 THEN
  385. cur_flag = -1
  386. cur_secflag = -1
  387. ELSEIF Index = 2 THEN
  388. cur_flag = 0
  389. cur_secflag = -1
  390. ELSEIF Index = 3 THEN
  391. cur_flag = 1
  392. cur_secflag = 0
  393. ELSEIF Index = 4 THEN
  394. cur_flag = 1
  395. cur_secflag = 1
  396. END IF
  397. cb_1.TriggerEvent(clicked!)
  398. end event
  399. type ddlb_1 from dropdownlistbox within w_rp_owwfjg_in
  400. integer x = 553
  401. integer y = 196
  402. integer width = 265
  403. integer height = 296
  404. integer taborder = 80
  405. boolean bringtotop = true
  406. integer textsize = -9
  407. integer weight = 400
  408. fontcharset fontcharset = gb2312charset!
  409. fontpitch fontpitch = variable!
  410. string facename = "宋体"
  411. long textcolor = 33554432
  412. string text = "[全部]"
  413. boolean sorted = false
  414. string item[] = {"[全部]","收货","返工"}
  415. borderstyle borderstyle = stylelowered!
  416. end type
  417. event selectionchanged;IF Index = 1 THEN
  418. cur_thflag = -1
  419. ELSEIF Index = 2 THEN
  420. cur_thflag = 0
  421. ELSEIF Index = 3 THEN
  422. cur_thflag = 1
  423. END IF
  424. cb_1.TriggerEvent(clicked!)
  425. end event
  426. type ddlb_scid from uo_ddlb_scid within w_rp_owwfjg_in
  427. integer x = 137
  428. integer y = 196
  429. integer width = 407
  430. integer height = 620
  431. integer taborder = 60
  432. boolean bringtotop = true
  433. end type
  434. event constructor;call super::constructor;cur_scid_arr = THIS.uo_scid_arr
  435. end event
  436. event selectionchanged;call super::selectionchanged;
  437. cur_scid_arr = THIS.uo_scid_arr
  438. cb_1.triggerevent(clicked!)
  439. end event
  440. type st_5 from statictext within w_rp_owwfjg_in
  441. integer y = 216
  442. integer width = 128
  443. integer height = 48
  444. boolean bringtotop = true
  445. integer textsize = -9
  446. integer weight = 400
  447. fontcharset fontcharset = gb2312charset!
  448. fontpitch fontpitch = variable!
  449. string facename = "宋体"
  450. long textcolor = 33554432
  451. long backcolor = 134217739
  452. string text = "分部"
  453. alignment alignment = right!
  454. boolean focusrectangle = false
  455. end type
  456. type cb_other from uo_imflatbutton within w_rp_owwfjg_in
  457. integer x = 558
  458. integer width = 361
  459. integer height = 164
  460. integer taborder = 40
  461. boolean bringtotop = true
  462. string text = "物料相关查询"
  463. string normalpicname = "imexport.BMP"
  464. integer picsize = 16
  465. toolbaralignment pic_align = alignattop!
  466. boolean border = false
  467. end type
  468. event clicked;call super::clicked;Long ll_row
  469. ll_row = dw_1.GetRow()
  470. IF ll_row <= 0 THEN
  471. MessageBox('提示','请选择物料',information!,OK!)
  472. RETURN
  473. END IF
  474. Long ll_mtrlid
  475. ll_mtrlid = dw_1.Object.mtrlid[ll_row]
  476. IF IsValid(w_mtrl_info) THEN
  477. w_mtrl_info.WindowState = Normal!
  478. w_mtrl_info.ins_mtrlid = ll_mtrlid
  479. w_mtrl_info.wf_retrieve(ll_mtrlid)
  480. ELSE
  481. OpenWithParm(w_mtrl_info,ll_mtrlid)
  482. END IF
  483. end event