作者 lihan
1 个管道 的构建 通过 耗费 0 秒

项目细节完善

... ... @@ -475,7 +475,9 @@ class CenterController extends HomeBaseController
if($request->isAjax()) {
}else {
return $this->fetch(':comment');
return $this->fetch(':comment', [
'oid' => request()->param('oid')
]);
}
}
... ...
... ... @@ -57,27 +57,46 @@
<script type="text/javascript" src="__TMPL__/static/assets/js/jquery-2.1.0.js"></script>
<script type="text/javascript" src="__TMPL__/static/assets/js/jquery.raty.js"></script>
<script type="text/javascript">
var startnum = 0;
var rank_synthetical = 0;
$('#start').raty({
click: function(s) {
console.log(s)
startnum = s;
rank_synthetical = s;
}
})
var startnum_min1 = 0;
var rank_service = 0;
$('#icon').raty({
click: function(s) {
console.log(s)
startnum = s;
rank_service = s;
}
})
var startnum_min2 = 0;
var rank_journey = 0;
$('#wuxing').raty({
click: function(s) {
console.log(s)
startnum = s;
rank_journey = s;
}
})
$(".ok").click(function () {
alert(rank_synthetical);
$.ajax({
url:"{:url('user/Center/comment')}",
data:{
oid:'{$oid}',
rank_synthetical:rank_synthetical,
rank_service:rank_service,
rank_journey:rank_journey
},
type:"POST",
dataType:"JSON",
success: function (data) {
}
})
})
</script>
</html>
\ No newline at end of file
... ...