Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
leaf-hlcm
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hlcm
leaf-hlcm
Commits
de8be8fd
Commit
de8be8fd
authored
Jul 22, 2022
by
gzj34291
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
建机茂甲合同签约完成后发送短信
parent
cfc8eb27
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
131 additions
and
0 deletions
+131
-0
reminder_sms_list.lwm
...n/webapp/WEB-INF/classes/sys/SYS420/reminder_sms_list.lwm
+17
-0
reminder_sms_loop.lwm
...n/webapp/WEB-INF/classes/sys/SYS420/reminder_sms_loop.lwm
+39
-0
sys_sms_server.lwm
...main/webapp/WEB-INF/classes/sys/SYS420/sys_sms_server.lwm
+28
-0
sms_batch_send.lsc
src/main/webapp/modules/sys/SYS420/sms_batch_send.lsc
+47
-0
No files found.
src/main/webapp/WEB-INF/classes/sys/SYS420/reminder_sms_list.lwm
0 → 100644
View file @
de8be8fd
<?xml version="1.0" encoding="UTF-8"?>
<bm:model
xmlns:bm=
"http://www.leaf-framework.org/schema/bm"
needAccessControl=
"false"
>
<bm:operations>
<bm:operation
name=
"update"
>
<bm:update-sql>
<![CDATA[
begin
contract_sign_message_pkg.send_mobile_remind_info(p_user_id =>
${/session/@user_id}, p_batch_id =>${@batch_id});
end;
]]>
</bm:update-sql>
<bm:parameters>
<bm:parameter
name=
"batch_id"
dataType=
"java.lang.Long"
input=
"true"
output=
"true"
outputPath=
"/parameter/@batch_id"
/>
</bm:parameters>
</bm:operation>
</bm:operations>
</bm:model>
src/main/webapp/WEB-INF/classes/sys/SYS420/reminder_sms_loop.lwm
0 → 100644
View file @
de8be8fd
<?xml version="1.0" encoding="UTF-8"?>
<bm:model
xmlns:bm=
"http://www.leaf-framework.org/schema/bm"
xmlns:f=
"leaf.database.features"
alias=
"t1"
baseTable=
"SYS_SMS_LIST"
needAccessControl=
"false"
>
<bm:fields>
<bm:field
name=
"sms_id"
databaseType=
"NUMBER"
datatype=
"java.lang.Long"
physicalName=
"SMS_ID"
prompt=
"SYS_SMS_LIST.SMS_ID"
/>
<bm:field
name=
"sms_date"
databaseType=
"DATE"
datatype=
"java.util.Date"
physicalName=
"SMS_DATE"
prompt=
"SYS_SMS_LIST.SMS_DATE"
/>
<bm:field
name=
"priority"
databaseType=
"NUMBER"
datatype=
"java.lang.Long"
physicalName=
"PRIORITY"
prompt=
"SYS_SMS_LIST.PRIORITY"
/>
<bm:field
name=
"phone_number"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"PHONE_NUMBER"
prompt=
"SYS_SMS_LIST.PHONE_NUMBER"
/>
<bm:field
name=
"text"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"TEXT"
prompt=
"SYS_SMS_LIST.TEXT"
/>
<bm:field
name=
"error_status"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"ERROR_STATUS"
prompt=
"SYS_SMS_LIST.ERROR_STATUS"
/>
<bm:field
name=
"error_msg"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"ERROR_MSG"
prompt=
"SYS_SMS_LIST.ERROR_MSG"
/>
<bm:field
name=
"status"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"STATUS"
prompt=
"SYS_SMS_LIST.STATUS"
/>
<bm:field
name=
"project_id"
databaseType=
"NUMBER"
datatype=
"java.lang.Long"
physicalName=
"PROJECT_ID"
prompt=
"SYS_SMS_LIST.PROJECT_ID"
/>
<bm:field
name=
"contract_number"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"CONTRACT_NUMBER"
prompt=
"SYS_SMS_LIST.CONTRACT_NUMBER"
/>
<bm:field
name=
"bp_name"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"BP_NAME"
prompt=
"SYS_SMS_LIST.BP_NAME"
/>
<bm:field
name=
"sms_type"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"SMS_TYPE"
prompt=
"SYS_SMS_LIST.SMS_TYPE"
/>
<bm:field
name=
"contract_id"
databaseType=
"NUMBER"
datatype=
"java.lang.Long"
physicalName=
"CONTRACT_ID"
prompt=
"SYS_SMS_LIST.CONTRACT_ID"
/>
<bm:field
name=
"batch_id"
databaseType=
"NUMBER"
datatype=
"java.lang.Long"
physicalName=
"BATCH_ID"
prompt=
"SYS_SMS_LIST.BATCH_ID"
/>
</bm:fields>
<bm:features>
<f:standard-who/>
</bm:features>
<bm:primary-key>
<bm:pk-field
name=
"sms_id"
/>
</bm:primary-key>
<bm:operations>
<bm:operation
name=
"update"
>
<bm:update-sql>
<![CDATA[
begin
hls_payment_msm_send_pkg.after_sys_sms_send_loop(p_sms_id =>
${@sms_id},
p_send_result =>${@result},
p_user_id =>${/session/@user_id});
end;
]]>
</bm:update-sql>
</bm:operation>
</bm:operations>
<bm:data-filters>
<bm:data-filter
name=
"query"
enforceOperations=
"query"
expression=
"t1.status = 'NEW' and t1.batch_id=${@batch_id}"
/>
</bm:data-filters>
</bm:model>
src/main/webapp/WEB-INF/classes/sys/SYS420/sys_sms_server.lwm
0 → 100644
View file @
de8be8fd
<?xml version="1.0" encoding="UTF-8"?>
<!--
$Author: DJ
$Date: 2013-12-26 下午3:25:40
$Revision: 1.0
$Purpose:
-->
<bm:model
xmlns:bm=
"http://www.leaf-framework.org/schema/bm"
xmlns:f=
"leaf.database.features"
alias=
"t1"
baseTable=
"SYS_SMS_SERVER"
needAccessControl=
"false"
>
<bm:fields>
<bm:field
name=
"server_id"
databaseType=
"NUMBER"
datatype=
"java.lang.Long"
physicalName=
"SERVER_ID"
prompt=
"SYS_SMS_SERVER.SERVER_ID"
/>
<bm:field
name=
"account_id"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"ACCOUNT_ID"
prompt=
"SYS_SMS_SERVER.ACCOUNT_ID"
/>
<bm:field
name=
"password"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"PASSWORD"
prompt=
"SYS_SMS_SERVER.PASSWORD"
/>
<bm:field
name=
"serviceid"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"SERVICEID"
prompt=
"SYS_SMS_SERVER.SERVICEID"
/>
<bm:field
name=
"server_code"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"SERVER_CODE"
prompt=
"SYS_SMS_SERVER.SERVER_CODE"
/>
<bm:field
name=
"server_url"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
physicalName=
"SERVER_URL"
prompt=
"SYS_SMS_SERVER.SERVER_URL"
/>
<bm:field
name=
"subcode"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
/>
<bm:field
name=
"sign"
databaseType=
"VARCHAR2"
datatype=
"java.lang.String"
/>
</bm:fields>
<bm:features>
<f:standard-who/>
</bm:features>
<bm:primary-key>
<bm:pk-field
name=
"server_id"
/>
</bm:primary-key>
<bm:data-filters>
<bm:data-filter
name=
"query"
expression=
"t1.server_code = 'HLCM_SMS'"
/>
</bm:data-filters>
</bm:model>
src/main/webapp/modules/sys/SYS420/sms_batch_send.lsc
0 → 100644
View file @
de8be8fd
<?xml version="1.0" encoding="UTF-8"?>
<a:service
xmlns:p=
"uncertain.proc"
xmlns:a=
"http://www.leaf-framework.org/application"
xmlns:s=
"leaf.plugin.script"
trace=
"true"
>
<a:init-procedure>
<s:server-script>
<![CDATA[
importPackage(Packages.java.util);
importPackage(Packages.com.hand.hls.hlcm.emay);
importPackage(Packages.com.hand.hap.system.dto);
//step2 发送短信
function sendsms() {
// 查询待发送短信表
var contract_collection = $bm('sys.SYS420.reminder_sms_list');
contract_collection.update();
var sms_list_bm = $bm('sys.SYS420.reminder_sms_loop');
println($ctx.parameter.batch_id);
var sms_list_result = sms_list_bm.queryAsMap({
"batch_id": $ctx.parameter.batch_id
});
var sms_list_records = sms_list_result.getChildren();
for (var i = 0; i < sms_list_records.length; i++) {
println(1);
var Phones = sms_list_records[i].phone_number;
var content = sms_list_records[i].text;
var sms_id = sms_list_records[i].sms_id;
try {
var example = new Example();
var result = example.setSingleSms(content, Phones);
var req_response = result.toString();
} catch (e) {
println("抛出异常:" + e);
}
//发送后请求更新
$bm('sys.SYS420.reminder_sms_loop').update({
sms_id: sms_id,
result: req_response
});
}
}
sendsms();
]]>
</s:server-script>
</a:init-procedure>
<a:service-output
output=
"/parameter"
/>
</a:service>
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment