123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272 |
- $PBExportHeader$w_hsaccount_ch.srw
- forward
- global type w_hsaccount_ch from w_publ_edit_choice
- end type
- end forward
- global type w_hsaccount_ch from w_publ_edit_choice
- integer width = 3214
- integer height = 2200
- string title = "项目设定"
- long backcolor = 82700779
- event refresh_face ( )
- end type
- global w_hsaccount_ch w_hsaccount_ch
- type variables
- s_accounts s_account
- end variables
- on w_hsaccount_ch.create
- call super::create
- end on
- on w_hsaccount_ch.destroy
- call super::destroy
- end on
- event retrieve_uc;dw_UC.retrieve()
- end event
- event close;CloseWithReturn(THIS,s_account)
- end event
- event ue_before_open;call super::ue_before_open;if_ue_filter = TRUE
- end event
- type cb_func from w_publ_edit_choice`cb_func within w_hsaccount_ch
- boolean visible = false
- integer y = 804
- boolean enabled = false
- end type
- type cb_exit from w_publ_edit_choice`cb_exit within w_hsaccount_ch
- integer x = 165
- end type
- event cb_exit::clicked;s_account.accountsid = 0
- Close (PARENT)
- end event
- type cb_add from w_publ_edit_choice`cb_add within w_hsaccount_ch
- boolean visible = false
- integer y = 804
- boolean enabled = false
- end type
- event cb_add::clicked;//Long ll_newid,i
- //String errmsg
- //IF dw_edit_mode THEN
- // dw_uc.AcceptText()
- // IF dw_uc.GetNextModified(0, Primary!) = 0 THEN
- // MessageBox('提示','没有任何修改,不可以保存!')
- // RETURN
- // END IF
- // dw_uc.Object.hsitemname[dw_uc.GetRow()] = Trim(dw_uc.Object.hsitemname[dw_uc.GetRow()])
- // dw_uc.Object.hsitemcode[dw_uc.GetRow()] = Trim(dw_uc.Object.hsitemcode[dw_uc.GetRow()])
- //
- // IF dw_uc.Object.hsitemcode[dw_uc.GetRow()] = '' THEN
- // MessageBox('提示','请输入编号!')
- // dw_uc.SetFocus()
- // dw_uc.SetColumn('hsitemcode')
- // RETURN
- // END IF
- //
- // IF dw_uc.Object.hsitemname[dw_uc.GetRow()] = '' THEN
- // MessageBox('提示','请输入项目资料名称!')
- // dw_uc.SetFocus()
- // dw_uc.SetColumn('hsitemname')
- // RETURN
- // END IF
- // dw_uc.Object.accsetid[dw_uc.GetRow()] = sys_accsetid
- //
- // IF dw_uc.Object.hsitemid[dw_uc.GetRow()] = 0 THEN
- // ll_newid = f_sys_scidentity(sys_accsetid,"cw_hsitem","hsitemid",errmsg,TRUE,id_sqlca)
- // IF ll_newid <= 0 THEN
- // MessageBox('提示',errmsg)
- // RETURN
- // ELSE
- // dw_uc.Object.hsitemid[dw_uc.GetRow()] = ll_newid
- // END IF
- // END IF
- //END IF
- //
- //IF dw_edit_mode THEN
- // String ls_errmsg
- // IF dw_uc.UPDATE() = -1 THEN
- // IF Pos(ins_sqlerrtext,"Cannot insert duplicate key row") > 0 THEN
- // ls_errmsg = "关键内容重复"
- // ELSE
- // ls_errmsg = "因为网络或其他原因>"+ins_sqlerrtext
- // END IF
- // ROLLBACK;
- // MessageBox ('提示',ls_errmsg+",保存操作失败!",Exclamation!,OK!)
- // LS_UPDATE_FLAG = FALSE
- // RETURN
- // ELSE
- // COMMIT;
- // FOR i = 1 TO 5
- // dw_uc.SetTabOrder ( i, 0 )
- // NEXT
- // LS_UPDATE_FLAG = TRUE
- // END IF
- // ins_sqlerrtext = ""
- //ELSE
- // Long li_row, li_cur_row
- // li_cur_row = dw_uc.GetRow()
- // li_row = dw_uc.InsertRow (0)
- // FOR i = 1 TO 5
- // dw_uc.SetTabOrder ( i, i*10 )
- // NEXT
- // dw_uc.SelectRow(0,FALSE)
- // dw_uc.ScrollToRow (li_row)
- // dw_uc.SelectRow(li_row,TRUE)
- // dw_uc.SetFocus()
- // modifyrow_no = li_row
- //END IF
- //
- //dw_edit_mode = NOT dw_edit_mode
- //WF_FACE_CHANGE()
- //PARENT.TriggerEvent('refresh_face')
- //
- //
- //
- end event
- type cb_edit from w_publ_edit_choice`cb_edit within w_hsaccount_ch
- boolean visible = false
- integer y = 804
- boolean enabled = false
- end type
- event cb_edit::clicked;//Long i
- //IF dw_edit_mode THEN
- // IF dw_uc.GetItemStatus(dw_uc.GetRow(), 0, Primary!) = NewModified! OR dw_uc.GetItemStatus(dw_uc.GetRow(), 0, Primary!) = New! THEN
- // dw_uc.DeleteRow(dw_uc.GetRow())
- // ELSE
- // dw_uc.ReselectRow(dw_uc.GetRow())
- // END IF
- // FOR i = 1 TO 5
- // dw_uc.SetTabOrder ( i, 0 )
- // NEXT
- // modifyrow_no = 0
- //ELSE
- // modifyrow_no = dw_uc.GetRow()
- // FOR i = 1 TO 5
- // dw_uc.SetTabOrder ( i, i*10 )
- // NEXT
- // dw_uc.SetFocus()
- //
- // dw_uc.SelectRow(0,FALSE)
- // dw_uc.ScrollToRow (modifyrow_no)
- // dw_uc.SelectRow(modifyrow_no,TRUE)
- //
- //END IF
- //
- //dw_edit_mode = NOT dw_edit_mode
- //WF_FACE_CHANGE()
- //PARENT.TriggerEvent('refresh_face')
- //
- end event
- type cb_delet from w_publ_edit_choice`cb_delet within w_hsaccount_ch
- boolean visible = false
- integer y = 804
- boolean enabled = false
- end type
- event cb_delet::clicked;//IF MessageBox (publ_operator,"是否确定要删除当前记录?(选择确定后记录将不可恢复)",Question!,YesNo! ) = 2 THEN
- //RETURN
- //END IF
- //
- //long LS_id
- //LONG LS_LONG=0
- //string ls_code,arg_msg
- //IF DW_UC.GETROW()<=0 THEN
- // MESSAGEBOX(publ_operator,'没有操作目标记录!')
- // RETURN
- //END IF
- //LS_id=DW_UC.OBJECT.hsitemid[DW_UC.GETROW()]
- //select COUNT(*) into :LS_LONG from cw_credencemx
- // where cw_credencemx.itemid=:LS_id
- // and cw_credencemx.accsetid=:sys_accsetid;
- //if SQLCA.SQLCode<>0 then
- // MessageBox (publ_operator,"数据查询操作失败!(请重试!)",Exclamation!,OK!)
- // return
- //end if
- //IF LS_LONG>0 THEN
- // MessageBox (publ_operator,"该资料已经使用于凭证,不可以删除!",Exclamation!,OK!)
- // RETURN
- //END IF
- //
- //LS_LONG=0
- //select COUNT(*) into :LS_LONG from cw_inititembala
- // where cw_inititembala.itemid=:LS_id
- // and cw_inititembala.accsetid=:sys_accsetid;
- //if SQLCA.SQLCode<>0 then
- // MessageBox (publ_operator,"数据查询操作失败!(请重试!)",Exclamation!,OK!)
- // return
- //end if
- //IF LS_LONG>0 THEN
- // MessageBox (publ_operator,"该资料已经使用于项目初始化数据,不可以删除!",Exclamation!,OK!)
- // RETURN
- //END IF
- //
- //dw_uc.SetRedraw (false)
- //dw_UC.DeleteRow (0)
- //dw_UC.TriggerEvent (rowfocuschanged!)
- //
- //if dw_UC.Update() = -1 then
- // rollback;
- // MessageBox (publ_operator,"删除记录操作失败!",Exclamation!,OK!)
- //else
- // commit;
- //end if
- //dw_uc.SetRedraw (true)
- end event
- type cb_choice from w_publ_edit_choice`cb_choice within w_hsaccount_ch
- integer x = 0
- end type
- event cb_choice::clicked;call super::clicked;Long ll_row
- dw_uc.AcceptText()
- ll_row = dw_uc.GetRow()
- IF ll_row <= 0 THEN
- MessageBox('提示','请选择项目')
- RETURN
- END IF
- s_account.accountsid = dw_uc.Object.accountsid[ll_row]
- s_account.accountsname = dw_uc.Object.accountsname[ll_row]
- Close (PARENT)
- end event
- type dw_uc from w_publ_edit_choice`dw_uc within w_hsaccount_ch
- integer y = 184
- integer width = 3182
- integer height = 1924
- string dataobject = "dw_hsaccount_index"
- end type
- type cb_help from w_publ_edit_choice`cb_help within w_hsaccount_ch
- boolean visible = false
- integer x = 1243
- integer y = 520
- boolean enabled = false
- end type
- type ln_bar from w_publ_edit_choice`ln_bar within w_hsaccount_ch
- end type
- type ln_bar2 from w_publ_edit_choice`ln_bar2 within w_hsaccount_ch
- end type
- type r_bar from w_publ_edit_choice`r_bar within w_hsaccount_ch
- end type
|