function print_settle_group_list_form($settle_array, $groupid) { foreach ($settle_array as $key => $value) { $pay_array[$value['pay_uid']][] = array("pay_name" => $value['pay_name'], "get_uid" => $value['get_uid'], "get_name" => $value['get_name'], "sum" => $value['sum']); } $row = 1; $listhtml = ""; $formarray['action'] = $_SERVER['PHP_SELF']; foreach ($pay_array as $pay_uid => $get_array) { $formarray['rows'][$row]['type'] = "textrow"; $formarray['rows'][$row]['label'] = $get_array[0]['pay_name'] . " paid:"; $row++; // $listhtml .= n(6) . "<ul class=\"pageitem\">\n"; // $listhtml .= n(8) . "<li class=\"textbox\"><span class=\"header\">". $get_array[0]['pay_name'] ." pays:</span></li>\n"; $get_array = array_sort($get_array, 'sum', SORT_DESC); foreach ($get_array as $key => $value) { $formarray['rows'][$row]['type'] = "checkbox"; $formarray['rows'][$row]['label'] = $value['get_name'] . ' € ' . number_format($value['sum'], DECIMALS, DSEP, TSEP); $formarray['rows'][$row]['name'] = "paylist[]"; $formarray['rows'][$row]['checked'] = 1; $formarray['rows'][$row]['value'] = $pay_uid . '-' . $value['get_uid']; $row++; /* $listhtml .= n(8) . "<li class=\"menu\">\n"; $listhtml .= n(10). "<span class=\"name\">" . $value['get_name'] . "</span>\n"; $listhtml .= n(10). "<span class=\"balance\">\n"; $listhtml .= n(12). "<span class=\"price_neg\">" . number_format($value['sum'], DECIMALS , DSEP,TSEP) . "</span>\n"; $listhtml .= n(12). "<span class=\"euro_neg\">€</span>\n"; $listhtml .= n(10). "</span>\n"; $listhtml .= n(8). "</li>\n"; */ } //$listhtml .= n(6) . "</ul>"; } $checkarr = get_group_checkarr($groupid); $formarray['rows'][$row]['items'] = "|groupid|hidden|" . $groupid; $formarray['rows'][$row + 1]['items'] = "|hash|hidden|" . $checkarr['hash']; $formarray['rows'][$row + 2]['items'] = "|mode|hidden|process"; $formarray['rows'][$row + 3]['items'] = "||submit|Submit payments"; echo create_form_html($formarray); }
$amount = $user->data['email_notify']; } //$formarray['rows'][$i]['items'] = "label|name|type|value"; $formarray['action'] = $_SERVER['PHP_SELF']; //$formarray['rows'][0]['items'] = "Username:|username|text|" . $_POST['username']; $formarray['rows'][0]['items'] = "Name:|realname|text|" . $realname; $formarray['rows'][1]['items'] = "New password:|passwordx|password"; $formarray['rows'][2]['items'] = "Re-enter:|password2|password"; $formarray['rows'][3]['items'] = "Email:|email|text|" . $email; $formarray['rows'][4]['label'] = "Name format:"; $formarray['rows'][4]['type'] = "select"; $formarray['rows'][4]['name'] = "name_format"; $formarray['rows'][4]['value'] = get_name_format(1, true); $formarray['rows'][4]['selected'] = $nformat; $formarray['rows'][5]['type'] = "checkbox"; $formarray['rows'][5]['label'] = "Notify by email:"; $formarray['rows'][5]['name'] = "email_notify"; $formarray['rows'][5]['checked'] = $checked; $formarray['rows'][5]['value'] = 1; $formarray['rows'][6]['items'] = "Notify amount:|amount|text|" . $amount; $formarray['rows'][7]['items'] = "Current pass:|curpassword|password"; $formarray['rows'][8]['items'] = "|mode|hidden|validate"; $formarray['rows'][9]['items'] = "||submit|Change!"; echo create_form_html($formarray); unset($formarray); } print_footer($user, 6); ?>
$html .= '</label>'; $html .= '</div>'; $html .= '</div>';*/ //#### end ############ $html .= '</div>'; $html .= '</div>'; $html .= '</div>'; $html .= '</div>'; $html .= '</div>'; } $html .= '<div class="text-center">'; $html .= '</div>'; $html .= '</form>'; return $html; } $order_id = $_GET['order']; $view_data['order_id'] = $order_id; $order = new Order(); $order->set_order($order_id); $order_data = $order->get_order_data(); $attendees = $order->get_attendees(); $attendees_data = array(); foreach ($attendees as $a) { $attendees_data[] = $a->get_attendee_data(); } $edit = $_GET['do'] == 'edit' ? true : false; $html = create_form_html($texts, $order_data, $attendees_data, $edit); $ret = array(); $ret['r'] = 'ok'; $ret['msg'] = $html; die(json_encode($ret));