Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
C
cash-loan-flow-boss
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
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
QG
cash-loan-flow-boss
Commits
d0c5016a
Commit
d0c5016a
authored
Feb 25, 2020
by
王向伟
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加进件配置项
parent
e76a136c
Changes
9
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
188 additions
and
456 deletions
+188
-456
mvnw
mvnw
+0
-286
mvnw.cmd
mvnw.cmd
+0
-161
ChannelConfBaseModel.java
...hloanflowboss/api/channel/model/ChannelConfBaseModel.java
+3
-0
ChannelConfServiceImpl.java
...nflowboss/api/channel/service/ChannelConfServiceImpl.java
+27
-8
ChannelApplyInfoStrategy.java
...loanflowboss/spi/clf/entity/ChannelApplyInfoStrategy.java
+62
-0
ChannelApplyInfoStrategyRepository.java
...pi/clf/repository/ChannelApplyInfoStrategyRepository.java
+17
-0
CLFCenterService.java
...up/cashloanflowboss/spi/clf/service/CLFCenterService.java
+5
-0
CLFCenterServiceImpl.java
...ashloanflowboss/spi/clf/service/CLFCenterServiceImpl.java
+13
-1
ChannelApplyInfoStrategyTest.java
...owboss/service/contract/ChannelApplyInfoStrategyTest.java
+61
-0
No files found.
mvnw
deleted
100644 → 0
View file @
e76a136c
#!/bin/sh
# ----------------------------------------------------------------------------
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# https://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
# ----------------------------------------------------------------------------
# ----------------------------------------------------------------------------
# Maven2 Start Up Batch script
#
# Required ENV vars:
# ------------------
# JAVA_HOME - location of a JDK home dir
#
# Optional ENV vars
# -----------------
# M2_HOME - location of maven2's installed home dir
# MAVEN_OPTS - parameters passed to the Java VM when running Maven
# e.g. to debug Maven itself, use
# set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
# MAVEN_SKIP_RC - flag to disable loading of mavenrc files
# ----------------------------------------------------------------------------
if
[
-z
"
$MAVEN_SKIP_RC
"
]
;
then
if
[
-f
/etc/mavenrc
]
;
then
.
/etc/mavenrc
fi
if
[
-f
"
$HOME
/.mavenrc"
]
;
then
.
"
$HOME
/.mavenrc"
fi
fi
# OS specific support. $var _must_ be set to either true or false.
cygwin
=
false
;
darwin
=
false
;
mingw
=
false
case
"
`
uname
`
"
in
CYGWIN
*
)
cygwin
=
true
;;
MINGW
*
)
mingw
=
true
;;
Darwin
*
)
darwin
=
true
# Use /usr/libexec/java_home if available, otherwise fall back to /Library/Java/Home
# See https://developer.apple.com/library/mac/qa/qa1170/_index.html
if
[
-z
"
$JAVA_HOME
"
]
;
then
if
[
-x
"/usr/libexec/java_home"
]
;
then
export
JAVA_HOME
=
"
`
/usr/libexec/java_home
`
"
else
export
JAVA_HOME
=
"/Library/Java/Home"
fi
fi
;;
esac
if
[
-z
"
$JAVA_HOME
"
]
;
then
if
[
-r
/etc/gentoo-release
]
;
then
JAVA_HOME
=
`
java-config
--jre-home
`
fi
fi
if
[
-z
"
$M2_HOME
"
]
;
then
## resolve links - $0 may be a link to maven's home
PRG
=
"
$0
"
# need this for relative symlinks
while
[
-h
"
$PRG
"
]
;
do
ls
=
`
ls
-ld
"
$PRG
"
`
link
=
`
expr
"
$ls
"
:
'.*-> \(.*\)$'
`
if
expr
"
$link
"
:
'/.*'
>
/dev/null
;
then
PRG
=
"
$link
"
else
PRG
=
"
`
dirname
"
$PRG
"
`
/
$link
"
fi
done
saveddir
=
`
pwd
`
M2_HOME
=
`
dirname
"
$PRG
"
`
/..
# make it fully qualified
M2_HOME
=
`
cd
"
$M2_HOME
"
&&
pwd
`
cd
"
$saveddir
"
# echo Using m2 at $M2_HOME
fi
# For Cygwin, ensure paths are in UNIX format before anything is touched
if
$cygwin
;
then
[
-n
"
$M2_HOME
"
]
&&
M2_HOME
=
`
cygpath
--unix
"
$M2_HOME
"
`
[
-n
"
$JAVA_HOME
"
]
&&
JAVA_HOME
=
`
cygpath
--unix
"
$JAVA_HOME
"
`
[
-n
"
$CLASSPATH
"
]
&&
CLASSPATH
=
`
cygpath
--path
--unix
"
$CLASSPATH
"
`
fi
# For Mingw, ensure paths are in UNIX format before anything is touched
if
$mingw
;
then
[
-n
"
$M2_HOME
"
]
&&
M2_HOME
=
"
`
(
cd
"
$M2_HOME
"
;
pwd
)
`
"
[
-n
"
$JAVA_HOME
"
]
&&
JAVA_HOME
=
"
`
(
cd
"
$JAVA_HOME
"
;
pwd
)
`
"
# TODO classpath?
fi
if
[
-z
"
$JAVA_HOME
"
]
;
then
javaExecutable
=
"
`
which javac
`
"
if
[
-n
"
$javaExecutable
"
]
&&
!
[
"
`
expr
\"
$javaExecutable
\"
:
'\([^ ]*\)'
`
"
=
"no"
]
;
then
# readlink(1) is not available as standard on Solaris 10.
readLink
=
`
which
readlink
`
if
[
!
`
expr
"
$readLink
"
:
'\([^ ]*\)'
`
=
"no"
]
;
then
if
$darwin
;
then
javaHome
=
"
`
dirname
\"
$javaExecutable
\"
`
"
javaExecutable
=
"
`
cd
\"
$javaHome
\"
&&
pwd
-P
`
/javac"
else
javaExecutable
=
"
`
readlink
-f
\"
$javaExecutable
\"
`
"
fi
javaHome
=
"
`
dirname
\"
$javaExecutable
\"
`
"
javaHome
=
`
expr
"
$javaHome
"
:
'\(.*\)/bin'
`
JAVA_HOME
=
"
$javaHome
"
export
JAVA_HOME
fi
fi
fi
if
[
-z
"
$JAVACMD
"
]
;
then
if
[
-n
"
$JAVA_HOME
"
]
;
then
if
[
-x
"
$JAVA_HOME
/jre/sh/java"
]
;
then
# IBM's JDK on AIX uses strange locations for the executables
JAVACMD
=
"
$JAVA_HOME
/jre/sh/java"
else
JAVACMD
=
"
$JAVA_HOME
/bin/java"
fi
else
JAVACMD
=
"
`
which java
`
"
fi
fi
if
[
!
-x
"
$JAVACMD
"
]
;
then
echo
"Error: JAVA_HOME is not defined correctly."
>
&2
echo
" We cannot execute
$JAVACMD
"
>
&2
exit
1
fi
if
[
-z
"
$JAVA_HOME
"
]
;
then
echo
"Warning: JAVA_HOME environment variable is not set."
fi
CLASSWORLDS_LAUNCHER
=
org.codehaus.plexus.classworlds.launcher.Launcher
# traverses directory structure from process work directory to filesystem root
# first directory with .mvn subdirectory is considered project base directory
find_maven_basedir
()
{
if
[
-z
"
$1
"
]
then
echo
"Path not specified to find_maven_basedir"
return
1
fi
basedir
=
"
$1
"
wdir
=
"
$1
"
while
[
"
$wdir
"
!=
'/'
]
;
do
if
[
-d
"
$wdir
"
/.mvn
]
;
then
basedir
=
$wdir
break
fi
# workaround for JBEAP-8937 (on Solaris 10/Sparc)
if
[
-d
"
${
wdir
}
"
]
;
then
wdir
=
`
cd
"
$wdir
/.."
;
pwd
`
fi
# end of workaround
done
echo
"
${
basedir
}
"
}
# concatenates all lines of a file
concat_lines
()
{
if
[
-f
"
$1
"
]
;
then
echo
"
$(
tr
-s
'\n'
' '
<
"
$1
"
)
"
fi
}
BASE_DIR
=
`
find_maven_basedir
"
$(
pwd
)
"
`
if
[
-z
"
$BASE_DIR
"
]
;
then
exit
1
;
fi
##########################################################################################
# Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
# This allows using the maven wrapper in projects that prohibit checking in binary data.
##########################################################################################
if
[
-r
"
$BASE_DIR
/.mvn/wrapper/maven-wrapper.jar"
]
;
then
if
[
"
$MVNW_VERBOSE
"
=
true
]
;
then
echo
"Found .mvn/wrapper/maven-wrapper.jar"
fi
else
if
[
"
$MVNW_VERBOSE
"
=
true
]
;
then
echo
"Couldn't find .mvn/wrapper/maven-wrapper.jar, downloading it ..."
fi
jarUrl
=
"https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.4.2/maven-wrapper-0.4.2.jar"
while
IFS
=
"="
read
key value
;
do
case
"
$key
"
in
(
wrapperUrl
)
jarUrl
=
"
$value
"
;
break
;;
esac
done
<
"
$BASE_DIR
/.mvn/wrapper/maven-wrapper.properties"
if
[
"
$MVNW_VERBOSE
"
=
true
]
;
then
echo
"Downloading from:
$jarUrl
"
fi
wrapperJarPath
=
"
$BASE_DIR
/.mvn/wrapper/maven-wrapper.jar"
if
command
-v
wget
>
/dev/null
;
then
if
[
"
$MVNW_VERBOSE
"
=
true
]
;
then
echo
"Found wget ... using wget"
fi
wget
"
$jarUrl
"
-O
"
$wrapperJarPath
"
elif
command
-v
curl
>
/dev/null
;
then
if
[
"
$MVNW_VERBOSE
"
=
true
]
;
then
echo
"Found curl ... using curl"
fi
curl
-o
"
$wrapperJarPath
"
"
$jarUrl
"
else
if
[
"
$MVNW_VERBOSE
"
=
true
]
;
then
echo
"Falling back to using Java to download"
fi
javaClass
=
"
$BASE_DIR
/.mvn/wrapper/MavenWrapperDownloader.java"
if
[
-e
"
$javaClass
"
]
;
then
if
[
!
-e
"
$BASE_DIR
/.mvn/wrapper/MavenWrapperDownloader.class"
]
;
then
if
[
"
$MVNW_VERBOSE
"
=
true
]
;
then
echo
" - Compiling MavenWrapperDownloader.java ..."
fi
# Compiling the Java class
(
"
$JAVA_HOME
/bin/javac"
"
$javaClass
"
)
fi
if
[
-e
"
$BASE_DIR
/.mvn/wrapper/MavenWrapperDownloader.class"
]
;
then
# Running the downloader
if
[
"
$MVNW_VERBOSE
"
=
true
]
;
then
echo
" - Running MavenWrapperDownloader.java ..."
fi
(
"
$JAVA_HOME
/bin/java"
-cp
.mvn/wrapper MavenWrapperDownloader
"
$MAVEN_PROJECTBASEDIR
"
)
fi
fi
fi
fi
##########################################################################################
# End of extension
##########################################################################################
export
MAVEN_PROJECTBASEDIR
=
${
MAVEN_BASEDIR
:-
"
$BASE_DIR
"
}
if
[
"
$MVNW_VERBOSE
"
=
true
]
;
then
echo
$MAVEN_PROJECTBASEDIR
fi
MAVEN_OPTS
=
"
$(
concat_lines
"
$MAVEN_PROJECTBASEDIR
/.mvn/jvm.config"
)
$MAVEN_OPTS
"
# For Cygwin, switch paths to Windows format before running java
if
$cygwin
;
then
[
-n
"
$M2_HOME
"
]
&&
M2_HOME
=
`
cygpath
--path
--windows
"
$M2_HOME
"
`
[
-n
"
$JAVA_HOME
"
]
&&
JAVA_HOME
=
`
cygpath
--path
--windows
"
$JAVA_HOME
"
`
[
-n
"
$CLASSPATH
"
]
&&
CLASSPATH
=
`
cygpath
--path
--windows
"
$CLASSPATH
"
`
[
-n
"
$MAVEN_PROJECTBASEDIR
"
]
&&
MAVEN_PROJECTBASEDIR
=
`
cygpath
--path
--windows
"
$MAVEN_PROJECTBASEDIR
"
`
fi
WRAPPER_LAUNCHER
=
org.apache.maven.wrapper.MavenWrapperMain
exec
"
$JAVACMD
"
\
$MAVEN_OPTS
\
-classpath
"
$MAVEN_PROJECTBASEDIR
/.mvn/wrapper/maven-wrapper.jar"
\
"-Dmaven.home=
${
M2_HOME
}
"
"-Dmaven.multiModuleProjectDirectory=
${
MAVEN_PROJECTBASEDIR
}
"
\
${
WRAPPER_LAUNCHER
}
$MAVEN_CONFIG
"
$@
"
mvnw.cmd
deleted
100644 → 0
View file @
e76a136c
@REM ----------------------------------------------------------------------------
@REM Licensed to the Apache Software Foundation (ASF) under one
@REM or more contributor license agreements. See the NOTICE file
@REM distributed with this work for additional information
@REM regarding copyright ownership. The ASF licenses this file
@REM to you under the Apache License, Version 2.0 (the
@REM "License"); you may not use this file except in compliance
@REM with the License. You may obtain a copy of the License at
@REM
@REM https://www.apache.org/licenses/LICENSE-2.0
@REM
@REM Unless required by applicable law or agreed to in writing,
@REM software distributed under the License is distributed on an
@REM "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@REM KIND, either express or implied. See the License for the
@REM specific language governing permissions and limitations
@REM under the License.
@REM ----------------------------------------------------------------------------
@REM ----------------------------------------------------------------------------
@REM Maven2 Start Up Batch script
@REM
@REM Required ENV vars:
@REM JAVA_HOME - location of a JDK home dir
@REM
@REM Optional ENV vars
@REM M2_HOME - location of maven2's installed home dir
@REM MAVEN_BATCH_ECHO - set to 'on' to enable the echoing of the batch commands
@REM MAVEN_BATCH_PAUSE - set to 'on' to wait for a key stroke before ending
@REM MAVEN_OPTS - parameters passed to the Java VM when running Maven
@REM e.g. to debug Maven itself, use
@REM set MAVEN_OPTS=-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=8000
@REM MAVEN_SKIP_RC - flag to disable loading of mavenrc files
@REM ----------------------------------------------------------------------------
@REM Begin all REM lines with '@' in case MAVEN_BATCH_ECHO is 'on'
@echo off
@REM set title of command window
title %0
@REM enable echoing my setting MAVEN_BATCH_ECHO to 'on'
@if "%MAVEN_BATCH_ECHO%" == "on" echo %MAVEN_BATCH_ECHO%
@REM set %HOME% to equivalent of $HOME
if "%HOME%" == "" (set "HOME=%HOMEDRIVE%%HOMEPATH%")
@REM Execute a user defined script before this one
if not "%MAVEN_SKIP_RC%" == "" goto skipRcPre
@REM check for pre script, once with legacy .bat ending and once with .cmd ending
if exist "%HOME%\mavenrc_pre.bat" call "%HOME%\mavenrc_pre.bat"
if exist "%HOME%\mavenrc_pre.cmd" call "%HOME%\mavenrc_pre.cmd"
:skipRcPre
@setlocal
set ERROR_CODE=0
@REM To isolate internal variables from possible post scripts, we use another setlocal
@setlocal
@REM ==== START VALIDATION ====
if not "%JAVA_HOME%" == "" goto OkJHome
echo.
echo Error: JAVA_HOME not found in your environment. >&2
echo Please set the JAVA_HOME variable in your environment to match the >&2
echo location of your Java installation. >&2
echo.
goto error
:OkJHome
if exist "%JAVA_HOME%\bin\java.exe" goto init
echo.
echo Error: JAVA_HOME is set to an invalid directory. >&2
echo JAVA_HOME = "%JAVA_HOME%" >&2
echo Please set the JAVA_HOME variable in your environment to match the >&2
echo location of your Java installation. >&2
echo.
goto error
@REM ==== END VALIDATION ====
:init
@REM Find the project base dir, i.e. the directory that contains the folder ".mvn".
@REM Fallback to current working directory if not found.
set MAVEN_PROJECTBASEDIR=%MAVEN_BASEDIR%
IF NOT "%MAVEN_PROJECTBASEDIR%"=="" goto endDetectBaseDir
set EXEC_DIR=%CD%
set WDIR=%EXEC_DIR%
:findBaseDir
IF EXIST "%WDIR%"\.mvn goto baseDirFound
cd ..
IF "%WDIR%"=="%CD%" goto baseDirNotFound
set WDIR=%CD%
goto findBaseDir
:baseDirFound
set MAVEN_PROJECTBASEDIR=%WDIR%
cd "%EXEC_DIR%"
goto endDetectBaseDir
:baseDirNotFound
set MAVEN_PROJECTBASEDIR=%EXEC_DIR%
cd "%EXEC_DIR%"
:endDetectBaseDir
IF NOT EXIST "%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config" goto endReadAdditionalConfig
@setlocal EnableExtensions EnableDelayedExpansion
for /F "usebackq delims=" %%a in ("%MAVEN_PROJECTBASEDIR%\.mvn\jvm.config") do set JVM_CONFIG_MAVEN_PROPS=!JVM_CONFIG_MAVEN_PROPS! %%a
@endlocal & set JVM_CONFIG_MAVEN_PROPS=%JVM_CONFIG_MAVEN_PROPS%
:endReadAdditionalConfig
SET MAVEN_JAVA_EXE="%JAVA_HOME%\bin\java.exe"
set WRAPPER_JAR="%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.jar"
set WRAPPER_LAUNCHER=org.apache.maven.wrapper.MavenWrapperMain
set DOWNLOAD_URL="https://repo.maven.apache.org/maven2/io/takari/maven-wrapper/0.4.2/maven-wrapper-0.4.2.jar"
FOR /F "tokens=1,2 delims==" %%A IN (%MAVEN_PROJECTBASEDIR%\.mvn\wrapper\maven-wrapper.properties) DO (
IF "%%A"=="wrapperUrl" SET DOWNLOAD_URL=%%B
)
@REM Extension to allow automatically downloading the maven-wrapper.jar from Maven-central
@REM This allows using the maven wrapper in projects that prohibit checking in binary data.
if exist %WRAPPER_JAR% (
echo Found %WRAPPER_JAR%
) else (
echo Couldn't find %WRAPPER_JAR%, downloading it ...
echo Downloading from: %DOWNLOAD_URL%
powershell -Command "(New-Object Net.WebClient).DownloadFile('%DOWNLOAD_URL%', '%WRAPPER_JAR%')"
echo Finished downloading %WRAPPER_JAR%
)
@REM End of extension
%MAVEN_JAVA_EXE% %JVM_CONFIG_MAVEN_PROPS% %MAVEN_OPTS% %MAVEN_DEBUG_OPTS% -classpath %WRAPPER_JAR% "-Dmaven.multiModuleProjectDirectory=%MAVEN_PROJECTBASEDIR%" %WRAPPER_LAUNCHER% %MAVEN_CONFIG% %*
if ERRORLEVEL 1 goto error
goto end
:error
set ERROR_CODE=1
:end
@endlocal & set ERROR_CODE=%ERROR_CODE%
if not "%MAVEN_SKIP_RC%" == "" goto skipRcPost
@REM check for post script, once with legacy .bat ending and once with .cmd ending
if exist "%HOME%\mavenrc_post.bat" call "%HOME%\mavenrc_post.bat"
if exist "%HOME%\mavenrc_post.cmd" call "%HOME%\mavenrc_post.cmd"
:skipRcPost
@REM pause the script if MAVEN_BATCH_PAUSE is set to 'on'
if "%MAVEN_BATCH_PAUSE%" == "on" pause
if "%MAVEN_TERMINATE_CMD%" == "on" exit %ERROR_CODE%
exit /B %ERROR_CODE%
src/main/java/cn/quantgroup/cashloanflowboss/api/channel/model/ChannelConfBaseModel.java
View file @
d0c5016a
package
cn
.
quantgroup
.
cashloanflowboss
.
api
.
channel
.
model
;
package
cn
.
quantgroup
.
cashloanflowboss
.
api
.
channel
.
model
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ChannelApplyInfoStrategy
;
import
lombok.Data
;
import
lombok.Data
;
import
javax.validation.constraints.NotNull
;
import
javax.validation.constraints.NotNull
;
...
@@ -18,6 +19,8 @@ public class ChannelConfBaseModel {
...
@@ -18,6 +19,8 @@ public class ChannelConfBaseModel {
private
String
env
;
private
String
env
;
private
Integer
fundId
;
private
Integer
fundId
;
private
Integer
p2pFundId
;
private
Integer
p2pFundId
;
private
ChannelApplyInfoStrategy
channelApplyInfoStrategy
;
/**
/**
* 对应productId
* 对应productId
*/
*/
...
...
src/main/java/cn/quantgroup/cashloanflowboss/api/channel/service/ChannelConfServiceImpl.java
View file @
d0c5016a
package
cn
.
quantgroup
.
cashloanflowboss
.
api
.
channel
.
service
;
package
cn
.
quantgroup
.
cashloanflowboss
.
api
.
channel
.
service
;
import
java.sql.Timestamp
;
import
java.util.*
;
import
cn.quantgroup.cashloanflowboss.api.channel.entity.ChannelConf
;
import
cn.quantgroup.cashloanflowboss.api.channel.entity.ChannelConf
;
import
cn.quantgroup.cashloanflowboss.api.channel.model.ChannelConfAddModel
;
import
cn.quantgroup.cashloanflowboss.api.channel.model.ChannelConfAddModel
;
import
cn.quantgroup.cashloanflowboss.api.channel.model.ChannelConfBaseModel
;
import
cn.quantgroup.cashloanflowboss.api.channel.model.ChannelConfBaseModel
;
import
cn.quantgroup.cashloanflowboss.api.channel.model.ChannelConfVo
;
import
cn.quantgroup.cashloanflowboss.api.channel.model.ChannelConfVo
;
import
cn.quantgroup.cashloanflowboss.api.channel.model.ChannelListModel
;
import
cn.quantgroup.cashloanflowboss.api.channel.model.ChannelListModel
;
import
cn.quantgroup.cashloanflowboss.api.channel.repository.ChannelConfRepository
;
import
cn.quantgroup.cashloanflowboss.api.channel.util.ChannelConfUtil
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ChannelApplyInfoStrategy
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ClfCallbackConfiguration
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ClfCallbackConfiguration
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ClfChannelConfiguration
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ClfChannelConfiguration
;
import
cn.quantgroup.cashloanflowboss.api.channel.repository.ChannelConfRepository
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ClfOrderCallBack
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ClfOrderCallBack
;
import
cn.quantgroup.cashloanflowboss.spi.clf.model.KANoticeType
;
import
cn.quantgroup.cashloanflowboss.spi.clf.model.KANoticeType
;
import
cn.quantgroup.cashloanflowboss.api.channel.util.ChannelConfUtil
;
import
cn.quantgroup.cashloanflowboss.spi.clf.service.CLFCenterService
;
import
cn.quantgroup.cashloanflowboss.spi.clf.service.CLFCenterService
;
import
cn.quantgroup.cashloanflowboss.utils.IgnorePropertiesUtil
;
import
cn.quantgroup.cashloanflowboss.utils.IgnorePropertiesUtil
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.BeanUtils
;
...
@@ -20,6 +19,10 @@ import org.springframework.beans.factory.annotation.Autowired;
...
@@ -20,6 +19,10 @@ import org.springframework.beans.factory.annotation.Autowired;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Page
;
import
org.springframework.stereotype.Service
;
import
org.springframework.stereotype.Service
;
import
java.sql.Timestamp
;
import
java.util.Date
;
import
java.util.List
;
/**
/**
* function:
* function:
* date: 2019/8/2
* date: 2019/8/2
...
@@ -28,7 +31,7 @@ import org.springframework.stereotype.Service;
...
@@ -28,7 +31,7 @@ import org.springframework.stereotype.Service;
*/
*/
@Service
@Service
public
class
ChannelConfServiceImpl
implements
ChannelConfService
{
public
class
ChannelConfServiceImpl
implements
ChannelConfService
{
@Autowired
@Autowired
private
CLFCenterService
clfCenterService
;
private
CLFCenterService
clfCenterService
;
...
@@ -37,7 +40,6 @@ public class ChannelConfServiceImpl implements ChannelConfService{
...
@@ -37,7 +40,6 @@ public class ChannelConfServiceImpl implements ChannelConfService{
private
ChannelConfRepository
channelConfRepository
;
private
ChannelConfRepository
channelConfRepository
;
@Override
@Override
public
Page
<
ChannelListModel
>
getChannelInfo
(
Integer
pageNumber
,
Integer
pageSize
,
Long
channelId
,
String
channelName
)
{
public
Page
<
ChannelListModel
>
getChannelInfo
(
Integer
pageNumber
,
Integer
pageSize
,
Long
channelId
,
String
channelName
)
{
...
@@ -60,8 +62,9 @@ public class ChannelConfServiceImpl implements ChannelConfService{
...
@@ -60,8 +62,9 @@ public class ChannelConfServiceImpl implements ChannelConfService{
public
ChannelConfVo
getChannelConf
(
Long
channelId
)
{
public
ChannelConfVo
getChannelConf
(
Long
channelId
)
{
ChannelConf
channelConf
=
channelConfRepository
.
getByChannelId
(
channelId
);
ChannelConf
channelConf
=
channelConfRepository
.
getByChannelId
(
channelId
);
ChannelConfVo
channelConfVo
;
if
(
channelConf
!=
null
)
{
if
(
channelConf
!=
null
)
{
return
ChannelConfUtil
.
channelConfConvertVOModel
(
channelConf
);
channelConfVo
=
ChannelConfUtil
.
channelConfConvertVOModel
(
channelConf
);
}
else
{
}
else
{
// boss channel_conf 为空,从clf 查询数据
// boss channel_conf 为空,从clf 查询数据
ClfChannelConfiguration
channelConfiguration
=
clfCenterService
.
findChannelConfigurationByChannelId
(
channelId
);
ClfChannelConfiguration
channelConfiguration
=
clfCenterService
.
findChannelConfigurationByChannelId
(
channelId
);
...
@@ -70,8 +73,12 @@ public class ChannelConfServiceImpl implements ChannelConfService{
...
@@ -70,8 +73,12 @@ public class ChannelConfServiceImpl implements ChannelConfService{
ClfOrderCallBack
orderStatus
=
clfCenterService
.
findOrderCallBackByByCallbackStatusAndChannelId
(
KANoticeType
.
FUND_SUCC
.
name
(),
channelId
);
ClfOrderCallBack
orderStatus
=
clfCenterService
.
findOrderCallBackByByCallbackStatusAndChannelId
(
KANoticeType
.
FUND_SUCC
.
name
(),
channelId
);
ClfOrderCallBack
repaymentPlan
=
clfCenterService
.
findOrderCallBackByByCallbackStatusAndChannelId
(
KANoticeType
.
REPAYMENT
.
name
(),
channelId
);
ClfOrderCallBack
repaymentPlan
=
clfCenterService
.
findOrderCallBackByByCallbackStatusAndChannelId
(
KANoticeType
.
REPAYMENT
.
name
(),
channelId
);
return
ChannelConfUtil
.
getChannelConfVoByClf
(
channelConfiguration
,
approve
,
orderStatus
,
repaymentPlan
);
channelConfVo
=
ChannelConfUtil
.
getChannelConfVoByClf
(
channelConfiguration
,
approve
,
orderStatus
,
repaymentPlan
);
}
}
ChannelApplyInfoStrategy
channelApplyInfoStrategyByChannelId
=
clfCenterService
.
findChannelApplyInfoStrategyByChannelId
(
channelId
);
channelConfVo
.
getBasicInfo
().
setChannelApplyInfoStrategy
(
channelApplyInfoStrategyByChannelId
);
return
channelConfVo
;
}
}
@Override
@Override
...
@@ -122,6 +129,18 @@ public class ChannelConfServiceImpl implements ChannelConfService{
...
@@ -122,6 +129,18 @@ public class ChannelConfServiceImpl implements ChannelConfService{
}
}
clfCenterService
.
saveOrderCall
(
clfOrderCallBackList
);
clfCenterService
.
saveOrderCall
(
clfOrderCallBackList
);
}
}
//保存进件配置项
Long
channelId
=
basicInfo
.
getChannelId
();
ChannelApplyInfoStrategy
channelApplyInfoStrategy
=
basicInfo
.
getChannelApplyInfoStrategy
();
if
(
channelApplyInfoStrategy
!=
null
)
{
ChannelApplyInfoStrategy
strategy
=
clfCenterService
.
findChannelApplyInfoStrategyByChannelId
(
channelId
);
if
(
strategy
!=
null
)
{
channelApplyInfoStrategy
.
setId
(
strategy
.
getId
());
}
clfCenterService
.
saveChannelApplyInfoStrategy
(
channelApplyInfoStrategy
);
}
return
true
;
return
true
;
}
}
}
}
src/main/java/cn/quantgroup/cashloanflowboss/spi/clf/entity/ChannelApplyInfoStrategy.java
0 → 100644
View file @
d0c5016a
package
cn
.
quantgroup
.
cashloanflowboss
.
spi
.
clf
.
entity
;
import
lombok.Data
;
import
javax.persistence.*
;
import
java.io.Serializable
;
/**
* @author Wang Xiangwei
* @version 2020/2/25
*/
@Data
@Entity
@Table
(
name
=
"channel_apply_info_strategy"
,
catalog
=
"cash_loan_flow"
)
public
class
ChannelApplyInfoStrategy
implements
Serializable
{
@Id
@Column
(
name
=
"id"
)
@GeneratedValue
(
strategy
=
GenerationType
.
IDENTITY
)
private
Long
id
;
@Column
(
name
=
"channel_id"
)
private
Long
channelId
;
@Column
(
name
=
"channel_name"
)
private
String
channelName
;
@Column
(
name
=
"channel_user_id"
)
private
Boolean
channelUserId
;
@Column
(
name
=
"address"
)
private
Boolean
address
;
@Column
(
name
=
"contact"
)
private
Boolean
contact
;
@Column
(
name
=
"education"
)
private
Boolean
education
;
@Column
(
name
=
"income"
)
private
Boolean
income
;
@Column
(
name
=
"email"
)
private
Boolean
email
;
@Column
(
name
=
"occupation"
)
private
Boolean
occupation
;
@Column
(
name
=
"ocr"
)
private
Boolean
ocr
;
@Column
(
name
=
"mobile"
)
private
Boolean
mobile
;
@Column
(
name
=
"device"
)
private
Boolean
device
;
@Column
(
name
=
"contacts_book"
)
private
Boolean
contactsBook
;
}
src/main/java/cn/quantgroup/cashloanflowboss/spi/clf/repository/ChannelApplyInfoStrategyRepository.java
0 → 100644
View file @
d0c5016a
package
cn
.
quantgroup
.
cashloanflowboss
.
spi
.
clf
.
repository
;
import
cn.quantgroup.cashloanflowboss.core.persistence.CashLoanFlowDataSource
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ChannelApplyInfoStrategy
;
import
org.springframework.data.jpa.repository.JpaRepository
;
import
org.springframework.stereotype.Repository
;
/**
* @author Wang Xiangwei
* @version 2020/2/25
*/
@CashLoanFlowDataSource
@Repository
public
interface
ChannelApplyInfoStrategyRepository
extends
JpaRepository
<
ChannelApplyInfoStrategy
,
Long
>
{
ChannelApplyInfoStrategy
findByChannelId
(
Long
channelId
);
}
src/main/java/cn/quantgroup/cashloanflowboss/spi/clf/service/CLFCenterService.java
View file @
d0c5016a
...
@@ -3,6 +3,7 @@ package cn.quantgroup.cashloanflowboss.spi.clf.service;
...
@@ -3,6 +3,7 @@ package cn.quantgroup.cashloanflowboss.spi.clf.service;
import
cn.quantgroup.cashloanflowboss.api.order.model.OrderBaseModel
;
import
cn.quantgroup.cashloanflowboss.api.order.model.OrderBaseModel
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.*
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.*
;
import
org.springframework.data.domain.Page
;
import
org.springframework.data.domain.Page
;
import
java.util.List
;
import
java.util.List
;
/**
/**
...
@@ -36,4 +37,8 @@ public interface CLFCenterService {
...
@@ -36,4 +37,8 @@ public interface CLFCenterService {
ClfOrderCallBack
findOrderCallBackByByCallbackStatusAndChannelId
(
String
name
,
Long
channelId
);
ClfOrderCallBack
findOrderCallBackByByCallbackStatusAndChannelId
(
String
name
,
Long
channelId
);
void
reloadKAConfiguration
();
void
reloadKAConfiguration
();
ChannelApplyInfoStrategy
findChannelApplyInfoStrategyByChannelId
(
Long
channelId
);
void
saveChannelApplyInfoStrategy
(
ChannelApplyInfoStrategy
channelApplyInfoStrategy
);
}
}
src/main/java/cn/quantgroup/cashloanflowboss/spi/clf/service/CLFCenterServiceImpl.java
View file @
d0c5016a
...
@@ -21,7 +21,7 @@ import java.util.Objects;
...
@@ -21,7 +21,7 @@ import java.util.Objects;
* @author: suntao
* @author: suntao
*/
*/
@Service
@Service
public
class
CLFCenterServiceImpl
implements
CLFCenterService
{
public
class
CLFCenterServiceImpl
implements
CLFCenterService
{
@Autowired
@Autowired
...
@@ -44,6 +44,8 @@ public class CLFCenterServiceImpl implements CLFCenterService{
...
@@ -44,6 +44,8 @@ public class CLFCenterServiceImpl implements CLFCenterService{
@Autowired
@Autowired
private
ClfOrderCallbackRepository
clfOrderCallbackRepository
;
private
ClfOrderCallbackRepository
clfOrderCallbackRepository
;
@Autowired
private
ChannelApplyInfoStrategyRepository
channelApplyInfoStrategyRepository
;
@Override
@Override
...
@@ -143,4 +145,14 @@ public class CLFCenterServiceImpl implements CLFCenterService{
...
@@ -143,4 +145,14 @@ public class CLFCenterServiceImpl implements CLFCenterService{
public
void
reloadKAConfiguration
()
{
public
void
reloadKAConfiguration
()
{
clfCenter
.
reloadKASetting
(
""
);
clfCenter
.
reloadKASetting
(
""
);
}
}
@Override
public
ChannelApplyInfoStrategy
findChannelApplyInfoStrategyByChannelId
(
Long
channelId
)
{
return
channelApplyInfoStrategyRepository
.
findByChannelId
(
channelId
);
}
@Override
public
void
saveChannelApplyInfoStrategy
(
ChannelApplyInfoStrategy
channelApplyInfoStrategy
)
{
channelApplyInfoStrategyRepository
.
saveAndFlush
(
channelApplyInfoStrategy
);
}
}
}
src/test/java/cn/quantgroup/cashloanflowboss/service/contract/ChannelApplyInfoStrategyTest.java
0 → 100644
View file @
d0c5016a
package
cn
.
quantgroup
.
cashloanflowboss
.
service
.
contract
;
import
cn.quantgroup.cashloanflowboss.CashLoanFlowBossApplicationTests
;
import
cn.quantgroup.cashloanflowboss.api.channel.model.ChannelConfVo
;
import
cn.quantgroup.cashloanflowboss.api.channel.service.ChannelConfService
;
import
cn.quantgroup.cashloanflowboss.spi.clf.entity.ChannelApplyInfoStrategy
;
import
cn.quantgroup.cashloanflowboss.spi.clf.service.CLFCenterService
;
import
cn.quantgroup.cashloanflowboss.spi.xyqb.service.XYQBCenterService
;
import
org.junit.Test
;
import
org.springframework.beans.factory.annotation.Autowired
;
/**
* function:
* date: 2019/12/6
*
* @author: suntao
*/
public
class
ChannelApplyInfoStrategyTest
extends
CashLoanFlowBossApplicationTests
{
@Autowired
private
CLFCenterService
clfCenterService
;
@Autowired
private
ChannelConfService
channelConfService
;
@Test
public
void
test
()
{
ChannelApplyInfoStrategy
strategy
=
new
ChannelApplyInfoStrategy
();
strategy
.
setAddress
(
true
);
strategy
.
setChannelId
(
12L
);
strategy
.
setChannelName
(
"测试"
);
strategy
.
setContact
(
false
);
strategy
.
setChannelUserId
(
false
);
strategy
.
setContactsBook
(
true
);
strategy
.
setDevice
(
true
);
strategy
.
setEducation
(
true
);
strategy
.
setEmail
(
false
);
strategy
.
setIncome
(
true
);
strategy
.
setMobile
(
true
);
clfCenterService
.
saveChannelApplyInfoStrategy
(
strategy
);
ChannelApplyInfoStrategy
strategy1
=
clfCenterService
.
findChannelApplyInfoStrategyByChannelId
(
12L
);
strategy
.
setId
(
strategy1
.
getId
());
strategy
.
setChannelName
(
"测试更新"
);
clfCenterService
.
saveChannelApplyInfoStrategy
(
strategy
);
}
@Test
public
void
testGetChannelInfo
(){
ChannelConfVo
channelConf
=
channelConfService
.
getChannelConf
(
159881L
);
ChannelApplyInfoStrategy
channelApplyInfoStrategy
=
channelConf
.
getBasicInfo
().
getChannelApplyInfoStrategy
();
channelApplyInfoStrategy
.
setChannelUserId
(
true
);
channelConfService
.
editChannelConfInfo
(
channelConf
);
}
}
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