|
|
@@ -151,6 +151,9 @@
|
|
|
</div>
|
|
|
<script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>
|
|
|
<script>
|
|
|
+// var a = document.getElementById("form_area_id");
|
|
|
+// a.options[0].selected = true;
|
|
|
+
|
|
|
$(function () {
|
|
|
$('body').on('click', 'a[eventtype="event-delete"]', function () {
|
|
|
var span = $(this).prev();
|
|
|
@@ -224,6 +227,8 @@
|
|
|
//重置表单
|
|
|
$('.reset').on('click',function(){
|
|
|
$('input').val('');
|
|
|
+ $('#form_area_id').val('');
|
|
|
+ $('#form_status').val('');
|
|
|
$('#infoname').val('');
|
|
|
// var type = $(this).data('type');
|
|
|
// active[type] ? active[type].call(this) : '';
|
|
|
@@ -259,6 +264,27 @@
|
|
|
</script>
|
|
|
@include('vip.datatable')
|
|
|
<script src="https://cdn.bootcss.com/jquery/3.2.1/jquery.min.js"></script>
|
|
|
+ <script>
|
|
|
+ var id = $('#form_area_id').val();
|
|
|
+ if(id != ''){
|
|
|
+ $.ajax({
|
|
|
+ type:'get',
|
|
|
+ url:'/admin/TennisLeague/getcountry',
|
|
|
+ data:{id:id},
|
|
|
+ dataType:'json',
|
|
|
+ success:function(data){ //请求成功回调函数
|
|
|
+ var option = '';
|
|
|
+ option += '<option value></option>';
|
|
|
+ for(var i=0;i<data.length;i++){ //循环获取返回值,并组装成html代码
|
|
|
+ option += "<option value="+data[i]["id"]+">"+data[i]["name"]+"</option>";
|
|
|
+ }
|
|
|
+ $("#country_id").html(option);
|
|
|
+ //重新渲染select
|
|
|
+ form.render('select');
|
|
|
+ },
|
|
|
+ });
|
|
|
+ }
|
|
|
+ </script>
|
|
|
<script>
|
|
|
var id;
|
|
|
var aa;
|
|
|
@@ -266,14 +292,12 @@
|
|
|
var form = layui.form;
|
|
|
form.on('select(sect)',function(data){
|
|
|
id = data.value;
|
|
|
- console.log(id);
|
|
|
$.ajax({
|
|
|
type:'get',
|
|
|
url:'/admin/TennisLeague/getcountry',
|
|
|
data:{id:id},
|
|
|
dataType:'json',
|
|
|
success:function(data){ //请求成功回调函数
|
|
|
- console.log(data);
|
|
|
var option = '';
|
|
|
var dd = '';
|
|
|
option += '<option value></option>';
|
|
|
@@ -292,5 +316,6 @@
|
|
|
return true;
|
|
|
});
|
|
|
});
|
|
|
+
|
|
|
</script>
|
|
|
@endsection
|