Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
M
my-yaf-project
Project
Project
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
chenchuanwen
my-yaf-project
Commits
7e17f2b8
Commit
7e17f2b8
authored
Dec 22, 2018
by
liuyuzhen
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
登录扫码问题
parent
9524f371
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
10 deletions
+5
-10
StoreService.php
application/models/Business/Store/StoreService.php
+3
-8
MemberService.php
application/models/Business/User/MemberService.php
+0
-2
FavoritesStore.php
application/models/DAO/FavoritesStore.php
+2
-0
No files found.
application/models/Business/Store/StoreService.php
View file @
7e17f2b8
...
...
@@ -213,14 +213,9 @@ class StoreServiceModel extends \Business\AbstractModel{
$storeMember
[
'fav_type'
]
=
\Our\ApiConst
::
one
;
$storeMembers
[]
=
$storeMember
;
$favoritesStoreDao
=
\DAO\FavoritesStoreModel
::
getInstance
();
$one
=
$favoritesStoreDao
->
getOne
(
'store_id'
,
array
(
'store_id'
=>
$storeId
,
'member_id'
=>
$memberId
,
'fav_type'
=>
\Our\ApiConst
::
one
,
'fav_from'
=>
\Our\ApiConst
::
scanFavor
),
''
);
if
(
!
$one
)
{
$result
=
$favoritesStoreDao
->
insertAll
(
$storeMembers
);
if
(
$result
)
{
$favoritesStoreDao
->
updateStoreCollecitonsCache
(
array
(
$storeId
),
$memberId
,
2
);
}
$favoritesDao
=
\DAO\FavoritesStoreModel
::
getInstance
();
\Our\RedisHelper
::
delCachedFunction
(
\Redis\Db6\FavoritesStoreRedisModel
::
getInstance
(),
array
(
&
$favoritesDao
,
'getOne'
),
array
(),
array
(
$memberId
));
$result
=
$favoritesStoreDao
->
insertAll
(
$storeMembers
);
if
(
$result
)
{
$favoritesStoreDao
->
updateStoreCollecitonsCache
(
array
(
$storeId
),
$memberId
,
2
);
}
}
else
{
...
...
application/models/Business/User/MemberService.php
View file @
7e17f2b8
...
...
@@ -376,8 +376,6 @@ class MemberServiceModel extends \Business\AbstractModel
return
false
;
}
$favoritesStoreDao
->
updateStoreCollecitonsCache
(
$storeIds
,
$memberId
,
2
);
$favoritesDao
=
\DAO\FavoritesStoreModel
::
getInstance
();
\Our\RedisHelper
::
delCachedFunction
(
\Redis\Db6\FavoritesStoreRedisModel
::
getInstance
(),
array
(
&
$favoritesDao
,
'getOne'
),
array
(),
array
(
$memberId
));
}
}
...
...
application/models/DAO/FavoritesStore.php
View file @
7e17f2b8
...
...
@@ -205,6 +205,8 @@ class FavoritesStoreModel extends \DAO\AbstractModel {
\Our\RedisHelper
::
delCachedFunction
(
\Redis\Db6\FavoritesStoreRedisModel
::
getInstance
(),
array
(
&
$this
,
'getOne'
),
array
(),
array
(
$memberId
));
}
\Our\RedisHelper
::
delCachedFunction
(
\Redis\Db6\FavoritesStoreRedisModel
::
getInstance
(),
array
(
&
$this
,
'getFavoritesStores'
),
array
(),
array
(
$memberId
));
\Our\RedisHelper
::
delCachedFunction
(
\Redis\Db6\FavoritesStoreRedisModel
::
getInstance
(),
array
(
&
$this
,
'selectList'
),
array
(),
array
(
$memberId
));
//更新个人中心首页数量
\DAO\MemberModel
::
getInstance
()
->
_changeNum
(
\Our\NameConst
::
storeCollection
,
$memberId
,
$type
==
1
?
-
(
count
(
$storeIds
))
:
count
(
$storeIds
));
return
true
;
...
...
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