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
07404f86
Commit
07404f86
authored
Sep 21, 2018
by
liuyuzhen
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master_dev' of git.shenbd.com:qm-develop/shenbd into lyz
parents
0b439d60
0c2b576a
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
17 additions
and
10 deletions
+17
-10
MessageService.php
application/models/Business/Message/MessageService.php
+3
-1
OrderService.php
application/models/Business/Order/OrderService.php
+5
-4
RefundService.php
application/models/Business/Order/RefundService.php
+7
-4
OrderGoods.php
application/models/DAO/Order/OrderGoods.php
+1
-1
Store.php
application/models/DAO/Store.php
+1
-0
No files found.
application/models/Business/Message/MessageService.php
View file @
07404f86
...
...
@@ -134,7 +134,9 @@ class MessageServiceModel extends \Business\AbstractModel
if
(
$type
==
4
)
{
$store
=
\DAO\StoreModel
::
getInstance
();
$store
->
setDb
(
$db
);
$avatar
=
$store
->
getInfoById
(
$userid
,
'store_label'
,
'store_label'
);
$storeData
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\OrderRedisModel
::
getInstance
(),
array
(
&
$store
,
'getInfoById'
),
array
(
$this
->
order
[
'storeId'
],
$this
->
storeField
),
\Our\ApiConst
::
oneDaySecond
);
$avatar
=
$storeData
[
'storeLabel'
];
// $avatar = $store->getInfoById($userid, 'store_label', 'store_label');
$avatar
=
Common
::
getStaticFile
(
$avatar
,
ImageConst
::
storeLabel
,
ImageConst
::
imageDomain
);
}
...
...
application/models/Business/Order/OrderService.php
View file @
07404f86
...
...
@@ -254,9 +254,9 @@ class OrderServiceModel extends \Business\AbstractModel
$this
->
orderGoodsList
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\OrderRedisModel
::
getInstance
(),
array
(
&
$orderGoodsDao
,
'getOrderGoodsByOrderIds'
),
array
(
$orderId
,
$this
->
getGoodsDetailField
()),
\Our\ApiConst
::
oneDaySecond
,
array
(
$orderId
));
//商店相关信息
$this
->
store
=
$storeDao
->
get
(
$this
->
order
[
'storeId'
]);
$this
->
store
=
Common
::
convertUnderline
(
$this
->
store
[
0
]);
// $this->store = \Our\RedisHelper::cachedFunction(\Redis\Db5\OrderRedisModel::getInstance(), array(&$storeDao, 'getInfoById'), array($this->order['storeId'], $this->storeField), \Our\ApiConst::one
DaySecond,array($this->order['storeId']));
//
$this->store=$storeDao->get($this->order['storeId']);
//
$this->store=Common::convertUnderline($this->store[0]);
$this
->
store
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\OrderRedisModel
::
getInstance
(),
array
(
&
$storeDao
,
'getInfoById'
),
array
(
$this
->
order
[
'storeId'
],
$storeDao
->
detailField
),
\Our\ApiConst
::
seven
DaySecond
,
array
(
$this
->
order
[
'storeId'
]));
$returnData
=
$this
->
order
;
//配送员信息
$this
->
diliveryman
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\OrderRedisModel
::
getInstance
(),
array
(
&
$diliverymanDao
,
'findById'
),
array
(
$returnData
[
'diliverymanId'
]),
\Our\ApiConst
::
oneDaySecond
);
...
...
@@ -832,8 +832,9 @@ class OrderServiceModel extends \Business\AbstractModel
if
(
empty
(
$this
->
orderGoodsList
))
{
ErrorModel
::
throwException
(
CodeConfigModel
::
notExistOrderGoods
);
}
//商店相关信息
$this
->
store
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\OrderRedisModel
::
getInstance
(),
array
(
&
$storeDao
,
'getInfoById'
),
array
(
$this
->
order
[
'storeId'
],
$this
->
store
Field
),
\Our\ApiConst
::
oneDaySecond
);
$this
->
store
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\OrderRedisModel
::
getInstance
(),
array
(
&
$storeDao
,
'getInfoById'
),
array
(
$this
->
order
[
'storeId'
],
$storeDao
->
detail
Field
),
\Our\ApiConst
::
oneDaySecond
);
$orderGoods
=
$goodsDao
->
convert
(
$this
->
orderGoodsList
);
if
(
empty
(
$orderGoods
))
{
...
...
application/models/Business/Order/RefundService.php
View file @
07404f86
...
...
@@ -235,8 +235,9 @@ class RefundServiceModel extends \Business\AbstractModel
$orderGoodses
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\RefundReasonRedisModel
::
getInstance
(),
array
(
&
$orderGoodsDao
,
'getOrderGoodsByOrderIds'
),
array
(
$orderInfo
[
'orderId'
],
$this
->
orderGoodsField
),
\Our\ApiConst
::
oneDaySecond
);
$orderGoodses
=
$orderGoodsDao
->
convertOrderGoods
(
$orderGoodses
,
'goodsId'
);
$goodsIds
=
$orderGoodsDao
->
getRefundOrderGoodsIds
(
$orderGoodses
);
$this
->
store
=
$storeDao
->
get
(
$this
->
order
[
'storeId'
]);
$this
->
store
=
Common
::
convertUnderline
(
$this
->
store
[
0
]);
// $this->store=$storeDao->get($this->order['storeId']);
// $this->store=Common::convertUnderline($this->store[0]);
$this
->
store
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\OrderRedisModel
::
getInstance
(),
array
(
&
$storeDao
,
'getInfoById'
),
array
(
$orderInfo
[
'storeId'
],
$storeDao
->
detailField
),
\Our\ApiConst
::
sevenDaySecond
,
array
(
$orderInfo
[
'storeId'
]));
if
(
!
empty
(
$orderGoodses
[
$goodsId
])){
$orderGoods
=
$orderGoodses
[
$goodsId
];
}
...
...
@@ -443,8 +444,10 @@ class RefundServiceModel extends \Business\AbstractModel
ErrorModel
::
throwException
(
CodeConfigModel
::
notExistRefund
);
}
$orderGoods
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\RefundReasonRedisModel
::
getInstance
(),
array
(
&
$orderGoodsDao
,
'findByRecId'
),
array
(
$refundReturn
[
'orderGoodsId'
],
$this
->
getGoodsDetailField
()),
\Our\ApiConst
::
oneDaySecond
);
$this
->
store
=
$storeDao
->
get
(
$refundReturn
[
'storeId'
]);
$this
->
store
=
Common
::
convertUnderline
(
$this
->
store
[
0
]);
// $this->store=$storeDao->get($refundReturn['storeId']);
// $this->store=Common::convertUnderline($this->store[0]);
$this
->
store
=
\Our\RedisHelper
::
cachedFunction
(
\Redis\Db5\OrderRedisModel
::
getInstance
(),
array
(
&
$storeDao
,
'getInfoById'
),
array
(
$refundReturn
[
'storeId'
],
$storeDao
->
detailField
),
\Our\ApiConst
::
sevenDaySecond
,
array
(
$refundReturn
[
'storeId'
]));
$refundReturn
[
'goodsGroup'
]
=
$goodsDao
->
getGoodsGroup
(
$orderGoods
[
'goodsGroup'
]);
$refundReturn
[
'goodsAttr'
]
=
$goodsDao
->
getFormatGoodsAttr
(
$orderGoods
[
'goodsSpec'
]);
$refundReturn
[
'sellerStateName'
]
=
ArrayConst
::
sellerState
[
$refundReturn
[
'sellerState'
]];
...
...
application/models/DAO/Order/OrderGoods.php
View file @
07404f86
...
...
@@ -238,7 +238,7 @@ class OrderGoodsModel extends \DAO\AbstractModel {
public
function
getMemberStoreStaticsByCreateTime
(
$gmtCreate
,
$pageIndex
,
$pageSize
){
$this
->
setDb
(
$this
->
dbName
);
$where
=
\Our\Common
::
format
(
' gmt_update>={0} and gmt_update<{1} '
,
$gmtCreate
,
TIMESTAMP
);
$res
=
$this
->
lists
(
$where
,
array
(
'gmt_
cre
ate'
=>
'asc'
),
$this
->
sumField
,
$pageIndex
,
$pageSize
);
$res
=
$this
->
lists
(
$where
,
array
(
'gmt_
upd
ate'
=>
'asc'
),
$this
->
sumField
,
$pageIndex
,
$pageSize
);
return
$res
[
'list'
]
?
$res
:
false
;
}
public
function
getMemberStoreOrderGoodsCount
(
$storeIds
,
$memberIds
){
...
...
application/models/DAO/Store.php
100755 → 100644
View file @
07404f86
...
...
@@ -13,6 +13,7 @@ use Our\ImageConst;
class
StoreModel
extends
\DAO\AbstractModel
{
public
$detailField
=
" member_id as memberId,store_id as storeId,offline_payway as offlinePayway,store_label as storeLabel"
;
protected
function
init
()
{
...
...
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