return $matches[1];
}
else {
-print_r('cacou');
return $td;
}
}
";
}
+function input_check_details($row, $dummy) {
+ $row_id = $row['id'];
+ return "
+ <input type='checkbox' class='check_detail' name='detail[$row_id][check]'>";
+}
+
function get_order_details_extra($customer_id, $location, $item_like) {
$sql = "SELECT sod.id
, so.order_no
<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
<script src="js/jquery.tablednd.0.8.min.js"></script>
<script text="text/javascript">
- console.log('hello')
/** add table DnD as behavior **/
function onDragStart (table, row) {
console.log(table)
,_("Hold Until") => array('fun' => 'input_hold_until_date_details', 'ord' => '')
,_("Require By") => array('fun' => 'input_required_date_details', 'ord' => '')
,_("Expiry Date") => array('fun' => 'input_expiry_date_details', 'ord' => '')
- ,_("Comment") => array('fun' => 'input_comment_details', 'ord' => '')
+ ,_("Comment") => array('fun' => 'input_comment_details', 'ord' => '')
+ ,'<input id="checkAll" type="checkbox">' => array('fun' => 'input_check_details')
);
}
else {
}
</style>
+<script src="http://code.jquery.com/jquery-1.9.1.js"></script>
+<script text="text/javascript">
+
+var inserts = {
+ '#checkAll': function (e) {
+ e.onchange = function() {
+ $('.check_detail').prop('checked', e.checked)
+ }
+ }
+ }
+Behaviour.register(inserts);
+</script>