作者 王晓刚
1 个管道 的构建 通过 耗费 0 秒

提现失败问题

... ... @@ -58,8 +58,14 @@ class SchoolController extends AdminBaseController{
$this -> assign('data',$data);
$this -> assign('grade_class_str',$grade_class_str);
$this -> assign('grade_id_str',$grade_id_str);
$province = Db::name('area')->where(['pid'=>0])->select();
$province = Db::name('area')->where(['level'=>1])->select();
$data_city = Db::name('area')->where(['level'=>2,'name'=>$data['work_city']])->find();
$city = Db::name('area')->where(['pid'=>$data_city['pid'],'level'=>2])->select();
$data_county = Db::name('area')->where(['level'=>3,'name'=>$data['work_county']])->find();
$county = Db::name('area')->where(['level'=>3,'pid'=>$data_county['pid']])->select();
$this->assign('province',$province);
$this->assign('city',$city);
$this->assign('county',$county);
return $this -> fetch();
}
... ...
... ... @@ -8,18 +8,25 @@
</ul>
<form class="js-ajax-form" method="post" action="{:url('School/school_edit_post')}" role="form" style="margin-top: 20px;">
<div class="input-group">
<php>$area = explode(' ',$data['region']);</php>
<span class="input-group-addon">学校地区:</span>
<select class="form-control" name="province" id="province" required>
<option>请选择</option>
<foreach name="$province" item="p">
<option value="{$p.name}">{$p.name}</option>
<option value="{$p.name}" <eq name="$area[0]" value="$p.name}">selected</eq> >{$p.name}</option>
</foreach>
</select>
<select class="form-control" name="city" id="city" required>
<option>请选择</option>
<foreach name="$city" item="c">
<option value="{$c.name}" <eq name="$area[1]" value="$c.name}">selected</eq> >{$c.name}</option>
</foreach>
</select>
<select class="form-control" name="county" id="county" required>
<option>请选择</option>
<foreach name="$county" item="co">
<option value="{$co.name}" <eq name="$area[2]" value="$co.name}">selected</eq> >{$co.name}</option>
</foreach>
</select>
<input type="text" class="form-control" name="region" value="{$data.region}" >
</div>
... ...