ikinci temizlik tamamlandı
This commit is contained in:
@@ -0,0 +1,45 @@
|
||||
<?php
|
||||
$column = [];
|
||||
$column['name'] = post("name");
|
||||
$column['type'] = post("type");
|
||||
$column['relation'] = []; //json_decode(post("relation"));
|
||||
$relationDatas = [];
|
||||
$relationDatas[$column['name']] = [];//$column['relation'];
|
||||
$rowName = "click-edit";
|
||||
$tableName = post("table_name");
|
||||
|
||||
$unique = post("id") . post("name");
|
||||
|
||||
$listData = db($tableName)->where("id", post("id"))->first();
|
||||
|
||||
?>
|
||||
<div class="editable-zone" id="{{$unique}}">
|
||||
@include("components.columns.{$column['type']}")
|
||||
</div>
|
||||
<script>
|
||||
$("#{{$unique}} input").on("blur", function() {
|
||||
var that = $(this);
|
||||
var value = that.val();
|
||||
|
||||
$.post("{{ url('admin-ajax/input-edit') }}",{
|
||||
table : that.attr("table"),
|
||||
key : that.attr("key"),
|
||||
value : that.val(),
|
||||
_token : "{{ csrf_token() }}",
|
||||
id : that.attr("data-id"),
|
||||
name : that.attr("name")
|
||||
|
||||
},function(){
|
||||
that.prop("disabled",false);
|
||||
that.parent().parent().html(value).removeClass("edited");
|
||||
that.prop("disabled",true);
|
||||
|
||||
});
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
});
|
||||
</script>
|
||||
Reference in New Issue
Block a user