123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151 |
- $PBExportHeader$w_aifmb_user_choice.srw
- forward
- global type w_aifmb_user_choice from w_publ_choice
- end type
- end forward
- global type w_aifmb_user_choice from w_publ_choice
- integer width = 2002
- integer height = 1440
- string title = "员工选择"
- end type
- global w_aifmb_user_choice w_aifmb_user_choice
- type variables
- s_aifmb_user_choice s_select
- string obj_empcode
- //int ii_status = 1
- end variables
- on w_aifmb_user_choice.create
- call super::create
- end on
- on w_aifmb_user_choice.destroy
- call super::destroy
- end on
- event close;call super::close;CLOSEWITHRETURN(THIS,s_select)
- end event
- event dw_filter;//string filterstr
- //filterstr=""+trim(sle_ch.text)
- //
- String obj_expr = ''
- IF Trim(sle_ch.Text) <> '' THEN
- IF Pos(Trim(sle_ch.Text),'%') = 0 THEN
- obj_expr = obj_expr+'( userid LIKE "%'+Trim(sle_ch.Text)+'%" )'
- ELSE
- obj_expr = obj_expr+'( Lower(userid) LIKE "'+Trim(sle_ch.Text)+'" )'
- END IF
- END IF
- long a
- a=1
- IF Trim(sle_ch.Text) <> '' THEN
- IF obj_expr <> '' THEN obj_expr = obj_expr+ ' or '
- IF Pos(Trim(sle_ch.Text),'%') = 0 THEN
- obj_expr = obj_expr+' ( username LIKE "%'+Trim(sle_ch.Text)+'%" )'
- ELSE
- obj_expr = obj_expr+' ( username LIKE "'+Trim(sle_ch.Text)+'" )'
- END IF
- END IF
- dw_ch.SetFilter(obj_expr)
- dw_ch.SetRedraw(FALSE)
- dw_ch.Filter()
- IF dw_ch.RowCount() >= 1 THEN
- dw_ch.SelectRow(0,FALSE)
- dw_ch.SelectRow(1,TRUE)
- END IF
- dw_ch.SetRedraw(TRUE)
- end event
- event open;call super::open;obj_empcode = Message.StringParm
- IF obj_empcode <> '' THEN
- sle_ch.Text = obj_empcode
- THIS.TriggerEvent("dw_filter")
- END IF
- end event
- type cb_func from w_publ_choice`cb_func within w_aifmb_user_choice
- end type
- type cb_exit from w_publ_choice`cb_exit within w_aifmb_user_choice
- integer taborder = 50
- end type
- type sle_ch from w_publ_choice`sle_ch within w_aifmb_user_choice
- integer x = 379
- integer y = 184
- integer width = 389
- end type
- type dw_ch from w_publ_choice`dw_ch within w_aifmb_user_choice
- integer width = 1966
- integer height = 1036
- string dataobject = "dw_aifmb_user_choice"
- boolean hsplitscroll = false
- end type
- type st_1 from w_publ_choice`st_1 within w_aifmb_user_choice
- integer x = 18
- integer y = 204
- integer width = 343
- string text = "工号/姓名含:"
- alignment alignment = right!
- boolean righttoleft = false
- end type
- type cb_retrieve from w_publ_choice`cb_retrieve within w_aifmb_user_choice
- integer taborder = 60
- end type
- event cb_retrieve::clicked;
- //if upperbound(sys_user_dept)=0 then
- // long a[]
- // a[1]=0
- // setnull(a[1])
- // dw_ch.retrieve()
- //else
- dw_ch.retrieve()
- //end if
- THIS.TriggerEvent("dw_filter")
- end event
- type cb_choice from w_publ_choice`cb_choice within w_aifmb_user_choice
- end type
- event cb_choice::clicked;Long LS_ROW
- LS_ROW = dw_CH.GetRow()
- IF LS_ROW <= 0 THEN
- MessageBox('系统提示','请先选择目标行!',StopSign!)
- RETURN
- END IF
- s_select.empid = dw_CH.Object.empid[dw_CH.GetRow()]
- s_select.userid = dw_CH.Object.userid[dw_CH.GetRow()]
- s_select.username = dw_CH.Object.username[dw_CH.GetRow()]
- Close(PARENT)
- end event
- type ln_bar from w_publ_choice`ln_bar within w_aifmb_user_choice
- end type
- type ln_bar2 from w_publ_choice`ln_bar2 within w_aifmb_user_choice
- end type
- type r_bar from w_publ_choice`r_bar within w_aifmb_user_choice
- end type
- type ln_1 from w_publ_choice`ln_1 within w_aifmb_user_choice
- end type
- type ln_2 from w_publ_choice`ln_2 within w_aifmb_user_choice
- end type
|