Commit 1d1719db by 冷斌

add

parent 66dd301c
......@@ -10,7 +10,7 @@
<form class="well form-search" method="post" action="{:U('Welfare/savePrice')}">
价格:
<input type="text" name="price" style="width: 200px;" value="" placeholder="">
<input type="submit" class="btn btn-primary js-ajax-dialog-btn" data-msg="您确定要删除吗?" value="保存">
<input type="submit" class="btn btn-primary js-ajax-dialog-btn" data-msg="您确定要修改价格吗?" value="保存">
</form>
<form method="post" class="js-ajax-form">
<table class="table table-hover table-bordered">
......
......@@ -28,7 +28,6 @@ class WelfareController extends AdminbaseController
function savePrice()
{
if(IS_POST){
$price=I('price');
if ($price > 0) {
$jackpot=M("welfare_rate");
......@@ -45,8 +44,7 @@ class WelfareController extends AdminbaseController
M("welfare_rate")->where('id=1')->save(['rate' => $price]);
}
}
}
return $this->index();
$this->success('修改成功');
}
function index(){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment