Browse Source

语音播报金额当为整数时 去除0.00

master
Lemon 6 years ago
parent
commit
a2fd7669c1
  1. 2
      app/Service/DeviceServiceImp.php

2
app/Service/DeviceServiceImp.php

@ -112,7 +112,7 @@ class DeviceServiceImp implements DeviceServiceInterface
->where(['store_id' => $order['store_id'], 'is_bind' => SpeakerDevic::IS_BIND_YES])
->get()
->toArray();
$msg = $order['type']==1 ? "{\"msg\":\"您有新的懒族外卖订单\"}" : "{\"msg\":\"微信到账".$order['money']."\"}";
$msg = $order['type']==1 ? "{\"msg\":\"您有新的懒族外卖订单\"}" : "{\"msg\":\"微信到账".floatval($order['money'])."\"}";
foreach ($device_names as $key => $dev_name) {
$this->IOTService->pub($dev_name['device_name'], $msg);
}

Loading…
Cancel
Save