12345678910111213141516171819202122232425262728293031323334353637383940 |
- $PBExportHeader$ef_sms_send.srf
- global type ef_sms_send from function_object
- end type
- forward prototypes
- global function string ef_sms_send (string arg_content, string arg_phone)
- end prototypes
- global function string ef_sms_send (string arg_content, string arg_phone);String rslt = ''
- uo_spring_send uo_send
- uo_send = Create uo_spring_send
- uo_send.commit_transaction = sqlca
- IF arg_phone = '' THEN
- rslt = '接收号码不能为空'
- GOTO ext
- END IF
- Long ll_sendwayid
- SELECT TOP 1 sendwayid
- INTO :ll_sendwayid
- From u_spring_sendway;
- IF sqlca.SQLCode <> 0 THEN
- rslt = '查询短信通道失败,' + sqlca.SQLErrText
- GOTO ext
- END IF
- IF uo_send.uf_sendnow(ll_sendwayid, 0, 0, '', '', arg_phone, arg_content, rslt) <> 1 THEN
- GOTO ext
- END IF
- ext:
- Destroy uo_send
- RETURN rslt
- end function
|