|
|
@@ -434,8 +434,9 @@ class OrderController extends BaseController
|
|
|
$post = Yii::$app->request->post();
|
|
|
$id = $post['id'];
|
|
|
$order = OrderService::getById($id);
|
|
|
- if ($this->userId != $order['userId']) {
|
|
|
- util::fail('您没有权限操作');
|
|
|
+ OrderService::valid($order, $this->merchantId);
|
|
|
+ if ($order['grade'] > 0) {
|
|
|
+ util::fail('您已经评过了');
|
|
|
}
|
|
|
OrderService::comment($post);
|
|
|
util::complete('提交成功');
|