Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qa-deploy-utils
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
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
QA
qa-deploy-utils
Commits
7f17fcdf
Commit
7f17fcdf
authored
Feb 06, 2018
by
qa_quantgroup
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改closeloan脚本
parent
4140a2c4
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
1 addition
and
87 deletions
+1
-87
closeloan.sh
qa_shell_script/script_by_Contorller/closeloan.sh
+1
-1
pushloanprogress_dock.sh
...hell_script/script_by_Contorller/pushloanprogress_dock.sh
+0
-86
No files found.
qa_shell_script/script_by_Contorller/closeloan.sh
View file @
7f17fcdf
...
...
@@ -24,7 +24,7 @@ function closeloan()
echo
"user_id=
$user_id
"
#更新loan_application_history表中的is_active=0
update_sql
=
"update
${
TABLENAME
}
set is_active=0 where user_id=
${
user_id
}
and is_active=1 and business_type=0"
update_sql
=
"update
${
TABLENAME
}
set is_active=0
,set progress=16
where user_id=
${
user_id
}
and is_active=1 and business_type=0"
mysql
$mysqld
${
DBNAME
}
-e
"
${
update_sql
}
"
echo
"done!!!
$date
"
break
...
...
qa_shell_script/script_by_Contorller/pushloanprogress_dock.sh
deleted
100755 → 0
View file @
4140a2c4
#!/bin/bash
ip
=
$1
phone_no
=
$2
PORT
=
$3
USERNAME
=
"qa"
PASSWORD
=
"qatest"
DBNAME
=
"xyqb"
TABLENAME
=
"loan_application_history"
DBNAME1
=
"xyqb_user"
TABLENAME1
=
"user"
mysqld
=
"-h
${
ip
}
-P
${
PORT
}
-u
${
USERNAME
}
-p
${
PASSWORD
}
"
date
=
`
date
"+%Y-%m-%d %H:%M:%S"
`
function
pushloanprogress
(){
len
=
`
echo
$phone_no
|awk
'{print length($0)}'
`
if
[
$len
-ne
11
]
then
echo
"请输入11位手机号!"
else
#echo "开始修改"
#查询userID
select_sql
=
"select id from
${
TABLENAME1
}
where phone_no=
${
phone_no
}
"
user_id
=
`
mysql
-N
$mysqld
${
DBNAME1
}
-e
"
${
select_sql
}
"
`
#cho "user_id=$user_id"
#查找loanid
loanid
=
"select id from
${
TABLENAME
}
where user_id=
${
user_id
}
and is_active = 1"
loan_id
=
`
mysql
-N
$mysqld
${
DBNAME
}
-e
"
${
loanid
}
"
`
#cho "loan_id=$loan_id"
#查询订单状态
progressid
=
"select progress from
${
TABLENAME
}
where user_id=
${
user_id
}
and is_active = 1"
progress_id
=
`
mysql
-N
$mysqld
${
DBNAME
}
-e
"
${
progressid
}
"
`
echo
"progress=
$progress_id
"
#push订单状态
#终审中
if
[
$progress_id
-eq
7
]
;
then
curl
-d
"loanId=
${
loan_id
}
&loanProgress=FINAL_SCREENING"
"http://qapi-zhangbo.q-gp.com/test/loanMq/one"
echo
"推送成功
$date
"
#终审拒绝
elif
[
$progress_id
-eq
8
]
;
then
curl
-d
"loanId=
${
loan_id
}
&loanProgress=FINAL_SCREENING_REJECT"
"http://qapi-zhangbo.q-gp.com/test/loanMq/one"
echo
"推送成功
$date
"
#未通过初筛
elif
[
$progress_id
-eq
19
]
;
then
curl
-d
"loanId=
${
loan_id
}
&loanProgress=FILTERING_DECLINED"
"http://qapi-zhangbo.q-gp.com/test/loanMq/one"
echo
"推送成功
$date
"
#借款清单生成完成
elif
[
$progress_id
-eq
9
]
;
then
curl
-d
"loanId=
${
loan_id
}
&loanProgress=LOAN_APPLICATION_MANIFEST_COMPLETE"
"http://qapi-zhangbo.q-gp.com/test/loanMq/one"
echo
"推送成功
$date
"
#等待资金方放款
elif
[
$progress_id
-eq
20
]
;
then
curl
-d
"loanId=
${
loan_id
}
&loanProgress=WAITING_FUND"
"http://qapi-zhangbo.q-gp.com/test/loanMq/one"
echo
"推送成功
$date
"
#查看还款计划
elif
[
$progress_id
-eq
15
]
;
then
curl
-d
"loanId=
${
loan_id
}
&loanProgress=CHECK_REPAYMENT_PLAN"
"http://qapi-zhangbo.q-gp.com/test/loanMq/one"
echo
"推送成功
$date
"
#马上金融放款失败
elif
[
$progress_id
-eq
23
]
;
then
curl
-d
"loanId=
${
loan_id
}
&loanProgress=FINAL_FUNDED_APPROVAL_FAIL"
"http://qapi-zhangbo.q-gp.com/test/loanMq/one"
echo
"推送成功
$date
"
#借款完成
elif
[
$progress_id
-eq
16
]
;
then
curl
-d
"loanId=
${
loan_id
}
&loanProgress=LOAN_COMPLETE"
"http://qapi-zhangbo.q-gp.com/test/loanMq/one"
else
echo
"progress=
$progress_id
,订单状态不对"
fi
break
fi
}
pushloanprogress
$ip
$phone_no
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