Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
M
manager
Project
Overview
Details
Activity
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
reyun
manager
Commits
67282a11
Commit
67282a11
authored
Aug 13, 2020
by
kangxiaoshan
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
校验客户主账号
parent
f18451ec
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
91 additions
and
5 deletions
+91
-5
workspace.xml
.idea/workspace.xml
+0
-0
QcloudAccount.java
src/main/java/common/model/QcloudAccount.java
+59
-0
QcloudAccountRepository.java
src/main/java/common/repository/QcloudAccountRepository.java
+9
-0
ContractServiceImpl.java
src/main/java/common/service/impl/ContractServiceImpl.java
+21
-3
applicationContext.xml
src/main/resources/spring/applicationContext.xml
+2
-2
No files found.
.idea/workspace.xml
View file @
67282a11
This diff is collapsed.
Click to expand it.
src/main/java/common/model/QcloudAccount.java
0 → 100644
View file @
67282a11
package
common
.
model
;
import
javax.persistence.Entity
;
import
javax.persistence.GeneratedValue
;
import
javax.persistence.GenerationType
;
import
javax.persistence.Id
;
import
java.util.Date
;
@Entity
public
class
QcloudAccount
{
private
Long
id
;
private
String
email
;
private
String
company
;
private
Long
accountId
;
// 账号id
private
Date
updateTime
;
@Id
@GeneratedValue
(
strategy
=
GenerationType
.
IDENTITY
)
public
Long
getId
()
{
return
id
;
}
public
void
setId
(
Long
id
)
{
this
.
id
=
id
;
}
public
String
getEmail
()
{
return
email
;
}
public
void
setEmail
(
String
email
)
{
this
.
email
=
email
;
}
public
Long
getAccountId
()
{
return
accountId
;
}
public
void
setAccountId
(
Long
accountId
)
{
this
.
accountId
=
accountId
;
}
public
Date
getUpdateTime
()
{
return
updateTime
;
}
public
void
setUpdateTime
(
Date
updateTime
)
{
this
.
updateTime
=
updateTime
;
}
public
String
getCompany
()
{
return
company
;
}
public
void
setCompany
(
String
company
)
{
this
.
company
=
company
;
}
}
src/main/java/common/repository/QcloudAccountRepository.java
0 → 100644
View file @
67282a11
package
common
.
repository
;
import
common.model.QcloudAccount
;
import
org.springframework.data.jpa.repository.JpaRepository
;
public
interface
QcloudAccountRepository
extends
JpaRepository
<
QcloudAccount
,
Long
>
{
QcloudAccount
findByEmail
(
String
email
);
}
src/main/java/common/service/impl/ContractServiceImpl.java
View file @
67282a11
...
@@ -200,9 +200,6 @@ public class ContractServiceImpl implements ContractService {
...
@@ -200,9 +200,6 @@ public class ContractServiceImpl implements ContractService {
@Autowired
@Autowired
JdbcTemplate
jdbcTemplate
;
JdbcTemplate
jdbcTemplate
;
@Autowired
@Qualifier
(
"jdbcTemplateQcloud"
)
JdbcTemplate
jdbcTemplateqCloud
;
@Autowired
@Autowired
TransactionUtils
transactionUtils
;
TransactionUtils
transactionUtils
;
...
@@ -210,6 +207,9 @@ public class ContractServiceImpl implements ContractService {
...
@@ -210,6 +207,9 @@ public class ContractServiceImpl implements ContractService {
@Autowired
@Autowired
ShareIncomeService
shareIncomeService
;
ShareIncomeService
shareIncomeService
;
@Autowired
QcloudAccountRepository
qcloudAccountRepository
;
@Override
@Override
public
Map
<
String
,
Object
>
checkAccount
(
String
email
,
String
platfrom
)
{
public
Map
<
String
,
Object
>
checkAccount
(
String
email
,
String
platfrom
)
{
...
@@ -223,6 +223,18 @@ public class ContractServiceImpl implements ContractService {
...
@@ -223,6 +223,18 @@ public class ContractServiceImpl implements ContractService {
if
(
"tkio"
.
equals
(
platfrom
))
{
if
(
"tkio"
.
equals
(
platfrom
))
{
//account4Web = account4WebRepository.findByEmail(email);
//account4Web = account4WebRepository.findByEmail(email);
account
=
accountRepository
.
findByEmail
(
email
);
account
=
accountRepository
.
findByEmail
(
email
);
if
(
account
==
null
)
{
QcloudAccount
qcloudAccount
=
qcloudAccountRepository
.
findByEmail
(
email
);
if
(
qcloudAccount
!=
null
)
{
account
=
new
Account
();
account
.
setId
(
qcloudAccount
.
getId
());
account
.
setCompany
(
qcloudAccount
.
getCompany
());
account
.
setEmail
(
qcloudAccount
.
getEmail
());
}
}
}
else
if
(
"io"
.
equals
(
platfrom
))
{
}
else
if
(
"io"
.
equals
(
platfrom
))
{
ioAccount4Web
=
ioAccount4WebRepository
.
findByEmail
(
email
);
ioAccount4Web
=
ioAccount4WebRepository
.
findByEmail
(
email
);
}
else
if
(
"adi"
.
equals
(
platfrom
))
{
}
else
if
(
"adi"
.
equals
(
platfrom
))
{
...
@@ -2389,6 +2401,12 @@ public class ContractServiceImpl implements ContractService {
...
@@ -2389,6 +2401,12 @@ public class ContractServiceImpl implements ContractService {
}
}
});*/
});*/
List
<
QcloudAccount
>
qcloudAccounts
=
qcloudAccountRepository
.
findAll
();
qcloudAccounts
.
stream
().
map
(
v
->
{
emailDic
.
put
(
v
.
getEmail
(),
""
);
return
null
;
});
for
(
int
i
=
0
;
i
<
accountsEmail
.
size
();
i
++)
{
for
(
int
i
=
0
;
i
<
accountsEmail
.
size
();
i
++)
{
String
e
=
accountsEmail
.
get
(
i
);
String
e
=
accountsEmail
.
get
(
i
);
if
(!
emailDic
.
containsKey
(
e
))
{
if
(!
emailDic
.
containsKey
(
e
))
{
...
...
src/main/resources/spring/applicationContext.xml
View file @
67282a11
...
@@ -344,12 +344,12 @@
...
@@ -344,12 +344,12 @@
<property
name=
"dataSource"
ref=
"dataSource"
/>
<property
name=
"dataSource"
ref=
"dataSource"
/>
</bean>
</bean>
<bean
id=
"qClouDataSource"
parent=
"parentDataSource"
>
<
!--<
bean id="qClouDataSource" parent="parentDataSource">
<property name="url" value="${qcloudatasource.url}"/>
<property name="url" value="${qcloudatasource.url}"/>
<property name="username" value="${qcloudatasource.username}"/>
<property name="username" value="${qcloudatasource.username}"/>
<property name="password" value="${qcloudatasource.password}"/>
<property name="password" value="${qcloudatasource.password}"/>
</bean>
</bean>
<bean id="jdbcTemplateQcloud" class="org.springframework.jdbc.core.JdbcTemplate">
<bean id="jdbcTemplateQcloud" class="org.springframework.jdbc.core.JdbcTemplate">
<property name="dataSource" ref="qClouDataSource"></property>
<property name="dataSource" ref="qClouDataSource"></property>
</bean>
</bean>
-->
</beans>
</beans>
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