Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
usedCarAuction
/
aus
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit e8253136
authored
Jan 09, 2026
by
gonglei
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
加入框架代码
1 parent
77e2a820
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
26 additions
and
46 deletions
aus-api/src/main/java/com/glsx/usedcar/web/api/LoginController.java
aus-core/src/main/java/com/glsx/usedcar/module/account/service/AccountService.java
aus-core/src/main/java/com/glsx/usedcar/module/security/domain/MaLoginRequest.java
aus-front/app/src/module/account/PersonCertificationPage.vue
aus-front/app/src/module/auction/AuctionVehiclePage.vue
aus-front/app/src/pages/LoginPage.vue
aus-api/src/main/java/com/glsx/usedcar/web/api/LoginController.java
View file @
e825313
...
...
@@ -140,7 +140,7 @@ public class LoginController extends LoginCommonController {
account
.
setEnabled
(
true
);
account
.
setCertifiedState
(
Account
.
CertifiedState
.
UNCERTIFIED
);
account
.
setAccountType
(
Account
.
AccountType
.
COMMON
);
account
=
accountService
.
addAccount
(
account
);
account
=
accountService
.
addAccount
(
account
,
maLoginRequest
.
getRecommendCode
()
);
}
else
{
if
(!
account
.
isEnabled
())
{
accountInfo
.
setStatus
(
403
);
...
...
aus-core/src/main/java/com/glsx/usedcar/module/account/service/AccountService.java
View file @
e825313
...
...
@@ -94,9 +94,16 @@ public class AccountService extends AbstractAuctionService {
* @return 个人账户实例对象
*/
@Transactional
(
propagation
=
Propagation
.
REQUIRED
,
rollbackFor
=
Exception
.
class
)
public
Account
addAccount
(
Account
account
)
{
public
Account
addAccount
(
Account
account
,
String
recommendCode
)
{
account
.
setLastLoginTime
(
LocalDateTime
.
now
());
return
accountDao
.
save
(
account
);
Account
save
=
accountDao
.
save
(
account
);
if
(
StringUtils
.
hasText
(
recommendCode
))
{
accountTagDao
.
findTopByRecommendCode
(
recommendCode
).
ifPresent
(
accountTag
->
{
save
.
getAccountTags
().
add
(
accountTag
);
});
}
return
save
;
}
@Transactional
(
propagation
=
Propagation
.
REQUIRED
,
rollbackFor
=
Exception
.
class
)
...
...
aus-core/src/main/java/com/glsx/usedcar/module/security/domain/MaLoginRequest.java
View file @
e825313
...
...
@@ -32,6 +32,11 @@ public class MaLoginRequest {
private
String
openId
;
/**
* 推荐码
*/
private
String
recommendCode
;
// /**
// * 历史缓存自动token登录
// */
...
...
aus-front/app/src/module/account/PersonCertificationPage.vue
View file @
e825313
...
...
@@ -51,14 +51,14 @@
</view>
</view>
</view>
<
view
class=
"form-section"
>
<uni-forms-item
label=
""
name=
"recommendCode"
>
<view
class=
"form-item"
>
<text
class=
"label-text"
>
推荐码
</text
>
<uni-easyinput
v-model=
"formData.recommendCode"
placeholder=
"请输入推荐码"
:inputBorder=
"false"
/
>
</view
>
</uni-forms-item
>
<
/view
>
<
!--
<view
class=
"form-section"
>
--
>
<!--
<uni-forms-item
label=
""
name=
"recommendCode"
>
--
>
<!--
<view
class=
"form-item"
>
--
>
<!--
<text
class=
"label-text"
>
推荐码
</text>
--
>
<!--
<uni-easyinput
v-model=
"formData.recommendCode"
placeholder=
"请输入推荐码"
:inputBorder=
"false"
/>
--
>
<!--
</view>
--
>
<!--
</uni-forms-item>
--
>
<
!--
</view>
--
>
<!-- 提交按钮 -->
<view
class=
"submit-button-container"
>
<van-button
type=
"primary"
:disabled=
"!isFormValid"
round
@
click=
"submitForm"
block
>
提交
</van-button>
...
...
@@ -96,7 +96,6 @@ export default class PersonCertificationPage extends Vue {
accountName
:
{
rules
:
[{
required
:
true
,
errorMessage
:
'请输入真实姓名'
}]
},
idCard
:
{
rules
:
[
{
required
:
true
,
errorMessage
:
'请输入身份证号码'
},
...
...
aus-front/app/src/module/auction/AuctionVehiclePage.vue
View file @
e825313
...
...
@@ -729,38 +729,6 @@ export default class AuctionVehiclePage extends Vue {
this
.
isAgreed
=
!
this
.
isAgreed
;
}
/**
* 支付保证金
*/
confirmRecharge
():
void
{
const
recharge
=
new
Recharge
();
uni
.
showLoading
({
title
:
'正在支付保证金...'
,
mask
:
true
});
const
that
=
this
;
DepositController
.
addDeposit
(
this
.
axios
,
this
.
aucvehId
).
then
(
res
=>
{
const
result
=
res
.
data
;
uni
.
requestPayment
({
provider
:
'wxpay'
,
timeStamp
:
result
.
timeStamp
,
nonceStr
:
result
.
nonceStr
,
orderInfo
:
undefined
,
package
:
result
.
packageValue
,
signType
:
result
.
signType
,
paySign
:
result
.
paySign
,
complete
(
result
:
any
):
void
{
},
fail
(
error
:
any
):
void
{
//支付失败时出发,比如取消支付、余额不足等
setTimeout
(()
=>
{
uni
.
showToast
({
title
:
error
,
icon
:
'none'
});
},
300
);
},
success
(
result
:
any
):
void
{
// //触发该success时已经是输入密码支付成功后触发,可做一些页面跳转和成功提示
setTimeout
(()
=>
{
that
.
commitBid
();
},
800
);
},
});
}).
finally
(()
=>
uni
.
hideLoading
());
}
// 提交出价
submitBid
()
{
...
...
@@ -810,8 +778,7 @@ export default class AuctionVehiclePage extends Vue {
confirmText
:
'立即缴纳'
,
success
:
(
res
)
=>
{
if
(
res
.
confirm
)
{
this
.
confirmRecharge
();
// uni.navigateTo({url: '/module/deposit/RechargePage'});
uni
.
navigateTo
({
url
:
'/module/deposit/RechargePage'
});
}
}
});
...
...
aus-front/app/src/pages/LoginPage.vue
View file @
e825313
...
...
@@ -90,12 +90,14 @@ export default class LoginPage extends Vue {
}
loginByPhone
(
appId
:
string
,
code
:
string
,
e
:
any
)
{
const
recommendCode
=
uni
.
getStorageSync
(
'recommendCode'
);
const
url
=
'ma/'
+
appId
+
'/phoneLogin'
;
uni
.
showLoading
({
title
:
'正在登录中...'
,
mask
:
true
});
this
.
axios
.
post
(
url
,
{
encryptedData
:
e
.
detail
.
encryptedData
,
iv
:
e
.
detail
.
iv
,
code
:
code
,
recommendCode
:
recommendCode
}).
then
((
response
:
any
)
=>
{
console
.
log
(
response
);
const
accountInfo
:
AccountInfo
=
response
.
data
;
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment