function GetPage($res = '', $number) { $num = 0; if ($res[phone] == "") { $num = $number; } else { $num = $res[phone]; } if ($res[id] != '') { $dis = 'disabled="disabled"'; } else { $dis = ''; } $increm = mysql_query("\tSELECT `name`,\r\n\t\t\t\t\t\t\t\t\t`rand_name`\r\n\t\t\t\t\t\t\tFROM \t`file`\r\n\t\t\t\t\t\t\tWHERE `incomming_call_id` = {$res['id']}\r\n\t\t\t"); $data .= ' <!-- jQuery Dialog --> <div id="add-edit-goods-form" title="საქონელი"> <!-- aJax --> </div> <div id="dialog-form"> <div style="float: left; width: 673px;"> <fieldset > <legend>ძირითადი ინფორმაცია</legend> <tr> <label for="req_num">დამფორმირებელი</label> <label for="req_num">:</label> <label for="req_num">' . $res['operator'] . '</label> </tr> <table width="100%" class="dialog-form-table"> <tr> <td style="width: 180px;"><label for="req_num">მომართვა №</label></td> <td style="width: 180px !important;"><label for="req_data">თარიღი</label></td> <td style="width: 180px;"><label for="req_phone">ტელეფონი</label></td> </tr> <tr> <td style="width: 180px;"> <input type="text" id="id" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField user_id\'" value="' . $res['id'] . '" disabled="disabled" /> </td> <td style="width: 180px;"> <input type="text" id="c_date" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField date\'" value="' . $res['call_date'] . '" disabled="disabled" /> </td> <td style="width: 180px;"> <input type="text" id="phone" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $num . '" disabled="disabled"/> </td> <td style="width: 69px;"> </td> </tr> <tr> <td style="width: 180px;"><label for="d_number">ზარის ტიპი</label></td> <td style="width: 180px;"><label for="d_number">კატეგორია</label></td> <td style="width: 180px;"><label for="d_number">ქვე-კატეგოტია</label></td> <td ></td> </tr> <tr> <td style="width: 180px;"><select id="call_type_id" class="idls object"disabled="disabled">' . Getcall_type($res['call_type_id']) . '</select></td> <td style="width: 180px;"><select id="category_parent_id" class="idls object"disabled="disabled">' . Getcategory($res['category_parent_id']) . '</select></td> <td style="width: 180px;"><select id="category_id" class="idls object"disabled="disabled">' . Getcategory1_edit($res['category_id']) . '</select></td> <td ></td> </tr> </table>'; $data .= '<table id="additional" class="hidden dialog-form-table" width="100%"> <tr id="aaaa"> <td style="width: 180px;"><label pey_label1 for="d_number">ტრანზაქციის ფორმა</label></td> <td style="width: 180px;"><label id="bank_label" for="d_number">მომსახურე ბანკი</label></td> <td style="width: 180px;"><label id="pey_label" for="d_number">აპარატის ტიპი</label></td> <td style="width: 106px;"></td> </tr> <tr id="c"> <td style="width: 180px;"><select id="pay_type_id" class="idls object"disabled="disabled">' . Getpay_type($res['pay_type_id']) . '</select></td> <td style="width: 180px;"><select id="bank_id" class="idls object"disabled="disabled">' . Get_bank($res['bank_id']) . '</select></td> <td style="width: 180px;"><select id="pay_aparat_id" class="idls object"disabled="disabled">' . Getpay_aparat($res['pay_aparat_id']) . '</select></td> <td style="width: 106px;"></td> </tr> <tr id="bbbb"> <td style="width: 180px;"><label id="card_label" for="d_number">ბარათის ტიპი</label></td> <td style="width: 180px;"></td> <td style="width: 180px;"></td> <td style="width: 106px;"></td> </tr> <tr id="d" > <td style="width: 180px;"><select id="card_type_id" class="idls object"disabled="disabled">' . Getcard_type($res['card_type_id']) . '</select></td> <td style="width: 180px;"></td> <td style="width: 180px;"></td> <td style="width: 106px;"></td> </tr> </table>'; $data .= '<table width="100%" class="dialog-form-table"> <tr> <td style="width: 180px;"><label for="req_num">პრობლემის თარიღი</label></td> <td style="width: 180px;"><label for="d_number">სტატუსი</label></td> <td style="width: 180px;"><label for="d_number">ობიექტი</label></td> <td ></td> </tr> <tr> <td style="width: 180px;"> <input type="text" id="problem_date" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['problem_date'] . '"disabled="disabled" /></td> <td style="width: 180px;"><select id="call_status_id" class="idls object"disabled="disabled"disabled="disabled">' . Getcall_status($res['status']) . '</select></td> <td style="width: 180px;"><select id="object_id" class="idls object"disabled="disabled">' . Getobject($res['object_id']) . '</select></td> <td ></td> </tr> <tr> <td style="width: 180px;"><label for="req_num">ინფორმაციის წყარო</label></td> <td style="width: 180px;"></td> <td style="width: 180px;"></td> <td ></td> </tr> <tr> <td style="width: 180px;"><select id="source_id" class="idls object"disabled="disabled">' . Getsource($res['source_id']) . '</select></td> <td style="width: 180px;"></td> <td style="width: 180px;"></td> <td ></td> </tr> <tr> <td style="width: 180px;"><label for="content">საუბრის შინაარსი</label></td> </tr> <tr> <td colspan="6"> <textarea style="width: 641px; resize: none;" id="call_content" class="idle" name="call_content" cols="300" rows="4"disabled="disabled">' . $res['call_content'] . '</textarea> </td> </tr> </table> </fieldset > <fieldset style="margin-top: 5px;"> <legend>დავალების ფორმირება</legend> <table class="dialog-form-table"> <tr> <td style="width: 180px;"><label for="d_number">დავალების ტიპი</label></td> <td style="width: 180px;"><label for="d_number">განყოფილება</label></td> <td style="width: 180px;"><label for="d_number">პასუხისმგებელი პირი</label></td> </tr> <tr> <td style="width: 180px;" id="task_type_change"><select id="task_type_id" class="idls object"disabled="disabled">' . Gettask_type($res['task_type_id']) . '</select></td> <td style="width: 180px;"><select id="task_department_id" class="idls object"disabled="disabled">' . Getdepartment($res['task_department_id']) . '</select></td> <td style="width: 180px;"><select id="persons_id" class="idls object"disabled="disabled">' . Getpersons($res['persons_id']) . '</select></td> </tr> <tr> <td style="width: 180px;"><label for="d_number">პრიორიტეტები</label></td> <td style="width: 180px;"><label for="d_number">მაკონტროლებელი</label></td> <td style="width: 180px;"><label for="d_number">სხვა ნომერი</label></td> </tr> <tr> <td style="width: 180px;"><select id="priority_id" class="idls object">' . Getpriority($res['priority_id']) . '</select></td> <td style="width: 180px;"><select id="controler_id" class="idls object">' . Get_control($res['control_user_id']) . '</select></td> <td style="width: 180px;"> <input type="text" id="task_phone" class="idle" onblur="this.className=\'idle\'" value="' . $res['task_phone'] . '" /> </td> </tr> <tr> <td style="width: 180px;"><label for="content">პრობლემის გადაწყვეტა</label></td> </tr> <tr> <td colspan="6"> <textarea style="width: 641px; resize: none;" id="problem_coment" class="idle" name="call_content" cols="300" rows="4"disabled="disabled">' . $res['problem_comment'] . '</textarea> </td> </tr> </table> </fieldset> </div> <div> </fieldset> </div> <div style="float: right; width: 355px;"> <fieldset> <legend>მომართვის ავტორი</legend> <table style="height: 119px;"> <tr> <td style="width: 180px;">PIN კოდი</td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;"><input type="text" id="personal_pin" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['personal_pin'] . '"' . $dis . ' disabled="disabled"/></td> <td style="width: 180px;" class="hidden friend"> </td> </tr> <tr> <td style="width: 180px;">პირადი ნომერი</td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;"> <input type="text" id="personal_id" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['personal_id'] . '" ' . $dis . 'disabled="disabled"/> </td> <td style="width: 180px;"></td> </tr> </table> </fieldset> <div id="additional_info">'; $data .= '</div>'; $data .= GetRecordingsSection1($res); $data .= GetRecordingsSection($res); $data .= ' <fieldset> <legend>დამატებითი ინფორმაცია</legend> <table style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;"> <tr> <td> <div class="file-uploader"> <input id="choose_file" type="file" name="choose_file" class="input" style="display: none;"> <button id="choose_button" class="center">აირჩიეთ ფაილი</button> <input id="hidden_inc" type="text" value="' . increment('incomming_call') . '" style="display: none;"> </div> </td> </tr> </table> <table style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;"> <tr style="border-bottom: 1px solid #85b1de;"> <td colspan="3">მიმაგრებული ფაილი</td> </tr> </table> <table id="file_div" style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;">'; while ($increm_row = mysql_fetch_assoc($increm)) { $data .= ' <tr style="border-bottom: 1px solid #85b1de;"> <td style="width:110px; display:block;word-wrap:break-word;">' . $increm_row[name] . '</td> <td ><button type="button" value="media/uploads/file/' . $increm_row[rand_name] . '" style="cursor:pointer; border:none; margin-top:25%; display:block; height:16px; width:16px; background:none;background-image:url(\'media/images/get.png\');" id="download" ></button><input type="text" style="display:none;" id="download_name" value="' . $increm_row[rand_name] . '"> </td> <td ><button type="button" value="' . $increm_row[id] . '" style="cursor:pointer; border:none; margin-top:25%; display:block; height:16px; width:16px; background:none; background-image:url(\'media/images/x.png\');" id="delete"></button></td> </tr>'; } $data .= ' </table> </fieldset> </div> <input id="hidden_user" type="text" value="' . $res['user_id'] . '" style="display: none;"> </div>'; return $data; }
function GetPage($res = '', $number) { $num = 0; if ($res[phone] == "") { $num = $number; } else { $num = $res[phone]; } $increm = mysql_query("\tSELECT `name`,\r\n\t\t\t`rand_name`\r\n\t\t\tFROM \t`file`\r\n\t\t\tWHERE `task_id` = {$res['id']}\r\n\t\t\t"); if ($res[call_id] == '') { $data .= '<div id="dialog-form"> <div style="float: left; width: 500px;"> <fieldset > <legend>ძირითადი ინფორმაცია</legend> <table width="100%" class="dialog-form-table"> <tr> <td style="width: 180px;"><label for="req_num">დავალების №</label></td> <td style="width: 180px !important;"><label for="req_data">ფორმირების თარიღი</label></td> <td style="width: 180px;"><label for="req_phone">ტელეფონი</label></td> </tr> <tr> <td style="width: 180px;"> <input type="text" id="id" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField user_id\'" value="' . $res['id'] . '" disabled="disabled" /> </td> <td style="width: 180px;"> <input type="text" id="c_date" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField date\'" value="' . $res['call_date'] . '" disabled="disabled" /> </td> <td style="width: 180px;"> <input type="text" id="phone" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['phone'] . '" disabled="disabled" /> </td> <td style="width: 69px;"> <button class="calls">ნომრები</button> </td> </tr> <tr> <td style="width: 180px;"><label for="req_num">შესრულების გეგმ. დრო</label></td> <td style="width: 180px !important;"><label for="req_data">შესრულების ფაქტ. დრო</label></td> <td style="width: 180px;"><label for="req_phone">შესრულების დრო</label></td> </tr> <tr> <td style="width: 180px;"> <input type="text" id="planned_end_date" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['planned_end_date'] . '" disabled="disabled" /> </td> <td style="width: 180px;"> <input type="text" id="fact_end_date" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['fact_end_date'] . '" disabled="disabled" /> </td> <td style="width: 180px;"> <input type="text" id="call_duration" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['call_duration'] . '" disabled="disabled" /> </td> <td style="width: 69px;"> </td> </tr>'; $data .= '<table class="dialog-form-table"> <tr> <td style="width: 180px;"><label for="d_number">დავალების ტიპი</label></td> <td style="width: 180px;"><label for="d_number">განყოფილება</label></td> <td style="width: 180px;"><label for="d_number">პასუხისმგებელი პირი</label></td> </tr> <tr> <td style="width: 180px;"><select id="task_type_id" class="idls object"disabled="disabled" disabled="disabled">' . Gettask_type($res['task_type_id']) . '</select></td> <td style="width: 180px;"><select id="task_department_id" class="idls object"disabled="disabled">' . Getdepartment($res['task_department_id']) . '</select></td> <td style="width: 180px;"><select id="persons_id" class="idls object" disabled="disabled">' . Getpersonss($res['persons_id']) . '</select></td> </tr> <tr> <td style="width: 180px;"><label for="d_number">პრიორიტეტები</label></td> <td style="width: 180px;"><label for="d_number">თემა</label></td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;"><select id="priority_id" class="idls object" disabled="disabled">' . Getpriority($res['priority_id']) . '</select></td> <td style="width: 180px;"><select id="template_id" class="idls object" disabled="disabled">' . Gettemplate($res['template_id']) . '</select></td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 150px;"><label for="content">კომენტარი</label></td> <td style="width: 150px;"><label for="content"></label></td> <td style="width: 150px;"><label for="content"></label></td> </tr> <tr> <td colspan="6"> <textarea style="width: 641px; resize: none;" id="comment" class="idle" name="call_content" cols="300" rows="2" disabled="disabled">' . $res['comment'] . '</textarea> </td> </tr> <tr> <td style="width: 180px;"><label for="content">საუბრის შინაარსი</label></td> </tr> <tr> <td colspan="6"> <textarea style="width: 641px; resize: none;" id="problem_comment" class="idle" name="call_content" cols="300" rows="2" >' . $res['problem_comment'] . '</textarea> </td> </tr> </table> </fieldset> </div> <div> </fieldset> </div> <div style="float: right; width: 355px;"> <fieldset> <legend>მომართვის ავტორი</legend> <table style="height: 243px;"> <tr> <td style="width: 180px;">PIN კოდი</td> <td style="width: 180px;">ეგობრის PIN ცოდი</td> </tr> <tr> <td style="width: 180px;"><input type="text" id="personal_pin" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['personal_pin'] . '" /></td> <td style="width: 180px;"><input type="text" id="personal_pin" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['friend_pin'] . '" /></td> </tr> <tr> <td style="width: 180px;">პირადი ნომერი</td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;"> <input type="text" id="personal_id" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['personal_id'] . '" /> </td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;">სახელი და გვარი</td> </td> </tr> <tr > <td style="width: 180px;">' . $res['name1'] . '</td> </td> </tr> <tr > <td style="width: 180px;">ტელეფონი</td> </td> </tr> <tr> <td style="width: 180px;">' . $res['personal_phone'] . '</td> </td> </tr> <tr> <td style="width: 180px;">ელ-ფოსტა</td> </td> </tr> <tr> <td style="width: 180px;">' . $res['mail'] . '</td> <td ></td> </tr> <tr> <td td style="width: 180px;">user-ი</td> <td td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;">' . $res['user'] . '</td> <td td style="width: 180px;"></td> </tr> </table> </fieldset> <fieldset> <legend>მომართვის ავტორი</legend> <table> <tr> <td>სულ</td> <td></td> <td></td> <td style="width: 150px;"></td> <td>1</td> </tr> <tr> <td></td> <td>მოგვარებულები</td> <td></td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td>პრეტენზია</td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td>ინფორმაცია</td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td>მიმდინარე</td> <td></td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td></td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td>პრეტენზია</td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td>ინფორმაცია</td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td></td> <td style="width: 150px;"></td> <td style="width: 300px;"> <input type="button" value="ვრცლად"/> </td> </tr> </tr> </table> </fieldset> <fieldset> <legend>დამატებითი ინფორმაცია</legend> <table style="float: left; border: 1px solid #85b1de; width: 180px; text-align: center;"> <tr style="border-bottom: 1px solid #85b1de;"> <td colspan="2">საუბრის ჩანაწერი</td> </tr> <tr style="border-bottom: 1px solid #85b1de; "> <td>დრო</td> <td style="border-left:1px solid #85b1de; width: 50px;">ჩანაწერი</td> </tr> <tr > <td></td> <td><input type="button" value="მოსმენა"/></td> </tr> <table/> <table style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;"> <tr> <td> <div class="file-uploader"> <input id="choose_file" type="file" name="choose_file" class="input" style="display: none;"> <button id="choose_button" class="center">აირჩიეთ ფაილი</button> <input id="hidden_inc" type="text" value="' . increment('task') . '" style="display: none;"> </div> </td> </tr> </table> <table style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;"> <tr style="border-bottom: 1px solid #85b1de;"> <td colspan="3">მიმაგრებული ფაილი</td> </tr> </table> <table id="file_div" style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;">'; while ($increm_row = mysql_fetch_assoc($increm)) { $data .= ' <tr style="border-bottom: 1px solid #85b1de;"> <td style="width:110px; display:block;word-wrap:break-word;">' . $increm_row[name] . '</td> <td ><button type="button" value="media/uploads/file/' . $increm_row[rand_name] . '" style="cursor:pointer; border:none; margin-top:25%; display:block; height:16px; width:16px; background:none;background-image:url(\'media/images/get.png\');" id="download" ></button><input type="text" style="display:none;" id="download_name" value="' . $increm_row[rand_name] . '"> </td> <td ><button type="button" value="' . $increm_row[id] . '" style="cursor:pointer; border:none; margin-top:25%; display:block; height:16px; width:16px; background:none; background-image:url(\'media/images/x.png\');" id="delete"></button></td> </tr>'; } $data .= ' </table> </fieldset> </div> </div>'; } else { $data .= '<div id="dialog-form"> <div style="float: left; width: 500px;"> <fieldset > <legend>ძირითადი ინფორმაცია</legend> <table width="100%" class="dialog-form-table"> <tr> <td style="width: 180px;"><label for="req_num">მომართვა №</label></td> <td style="width: 180px !important;"><label for="req_data">თარიღი</label></td> <td style="width: 180px;"><label for="req_phone">ტელეფონი</label></td> </tr> <tr> <td style="width: 180px;"> <input type="text" id="id" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField user_id\'" value="' . $res['id'] . '" disabled="disabled" /> </td> <td style="width: 180px;"> <input type="text" id="c_date" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField date\'" value="' . $res['call_date'] . '" disabled="disabled" /> </td> <td style="width: 180px;"> <input type="text" id="phone" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $num . '" /> </td> <td style="width: 69px;"> <button class="calls">ნომრები</button> </td> </tr> <tr> <td style="width: 180px;"><label for="d_number">ზარის ტიპი</label></td> <td style="width: 180px;"><label for="d_number">კატეგორია</label></td> <td style="width: 180px;"><label for="d_number">ქვე-კატეგოტია</label></td> <td ></td> </tr> <tr> <td style="width: 180px;"><select id="call_type_id" class="idls object" disabled="disabled">' . Getcall_type($res['call_type_id']) . '</select></td> <td style="width: 180px;"><select id="category_parent_id" class="idls object" disabled="disabled">' . Getcategory($res['category_parent_id']) . '</select></td> <td style="width: 180px;"><select id="category_id" class="idls object" disabled="disabled">' . Getcategory1_edit($res['category_id']) . '</select></td> <td ></td> </tr> </table>'; if (Getcategory($res['category_parent_id']) == 407) { $data .= '<table id="additional" class="hidden dialog-form-table" width="100%"> <tr > <td style="width: 180px;"><label for="d_number">შეტანის ფორმა</label></td> <td style="width: 180px;"><label for="d_number">მომსახურე ბანკი</label></td> <td style="width: 180px;"><label for="d_number">ფილიალი</label></td> <td style="width: 106px;"></td> </tr> <tr > <td style="width: 180px;"><select id="pay_type_id" class="idls object" disabled="disabled">' . Getpay_type($res['pay_type_id']) . '</select></td> <td style="width: 180px;"><select id="bank_id" class="idls object" disabled="disabled">' . Get_bank($res['bank_id']) . '</select></td> <td style="width: 180px;"><select id="bank_object_id" class="idls object" disabled="disabled">' . Getbank_object_edit($res['bank_object_id']) . '</select></td> <td style="width: 106px;"></td> </tr> <tr > <td style="width: 180px;"><label for="d_number">ბარათის ტიპი</label></td> <td style="width: 180px;"><label for="d_number">ანგარიშსწორება</label></td> <td style="width: 180px;"><label for="d_number">აპარატის ტიპი</label></td> <td style="width: 106px;"></td> </tr> <tr > <td style="width: 180px;"><select id="card_type_id" class="idls object" disabled="disabled">' . Getcard_type($res['card_type_id']) . '</select></td> <td style="width: 180px;"><select id="card_type1_id" class="idls object" disabled="disabled">' . Getcard_type1($res['card_type1_id']) . '</select></td> <td style="width: 180px;"><select id="pay_aparat_id" class="idls object" disabled="disabled">' . Getpay_aparat($res['pay_aparat_id']) . '</select></td> <td style="width: 106px;"></td> </tr> </table>'; } $data .= '<table width="100%" class="dialog-form-table"> <tr> <td style="width: 180px;"><label for="req_num">პრობლემის თარიღი</label></td> <td style="width: 180px;"><label for="d_number">ობიექტი</label></td> <td style="width: 180px;"><label for="d_number">ზარის სტატუსი</label></td> <td ></td> </tr> <tr> <td style="width: 180px;"> <input type="text" id="problem_date" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res[problem_date] . '"disabled="disabled" /></td> <td style="width: 180px;"><select id="object_id" class="idls object" disabled="disabled">' . Getobject($res['object_id']) . '</select></td> <td style="width: 180px;"><select id="call_status_id" class="idls object"disabled="disabled">' . Getcall_status($res['status']) . '</select></td> <td ></td> </tr> <tr> <td style="width: 180px;"><label for="content">საუბრის შინაარსი</label></td> </tr> <tr> <td colspan="6"> <textarea disabled="disabled" style="width: 641px; resize: none;" id="call_content" class="idle" name="call_content" cols="300" rows="2" >' . $res['call_content'] . '</textarea> </td> </tr> <tr> <td style="width: 180px;"><label for="content">პრობლემის გადაწყვეტა</label></td> </tr> <tr> <td colspan="6"> <textarea style="width: 641px; resize: none;" id="problem_comment" class="idle" name="call_content" cols="300" rows="2">' . $res['problem_comment'] . '</textarea> </td> </tr> </table> </fieldset > <fieldset style="margin-top: 5px;"> <legend>დავალების ფორმირება</legend> <table class="dialog-form-table"> <tr> <td style="width: 180px;"><label for="d_number">დავალების ტიპი</label></td> <td style="width: 180px;"><label for="d_number">განყოფილება</label></td> <td style="width: 180px;"><label for="d_number">პასუხისმგებელი პირი</label></td> </tr> <tr> <td style="width: 180px;"><select id="task_type_id" class="idls object"disabled="disabled">' . Gettask_type($res['task_type_id']) . '</select></td> <td style="width: 180px;"><select id="task_department_id" class="idls object"disabled="disabled">' . Getdepartment($res['task_department_id']) . '</select></td> <td style="width: 180px;"><select id="persons_id" class="idls object"disabled="disabled">' . Getpersonss($res['persons_id']) . '</select></td> </tr> <tr> <td style="width: 180px;"><label for="d_number">პრიორიტეტები</label></td> <td style="width: 180px;"></td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;"><select id="priority_id" class="idls object">' . Getpriority($res['priority_id']) . '</select></td> <td style="width: 180px;"></td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 150px;"><label for="content">კომენტარი</label></td> <td style="width: 150px;"><label for="content"></label></td> <td style="width: 150px;"><label for="content"></label></td> </tr> <tr> <td colspan="6"> <textarea style="width: 641px; resize: none;" id="comment" class="idle" name="content" cols="300" rows="2">' . $res['comment'] . '</textarea> </td> </tr> </tr> </table> </fieldset> </div> <div> </fieldset> </div> <div style="float: right; width: 355px;"> <fieldset> <legend>მომართვის ავტორი</legend> <table style="height: 243px;"> <tr> <td style="width: 180px;">PIN კოდი</td> <td style="width: 180px;">ეგობრის PIN ცოდი</td> </tr> <tr> <td style="width: 180px;"><input type="text" id="personal_pin" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['personal_pin'] . '" /></td> <td style="width: 180px;"><input type="text" id="personal_pin" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['friend_pin'] . '" /></td> </tr> <tr> <td style="width: 180px;">პირადი ნომერი</td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;"> <input type="text" id="personal_id" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['personal_id'] . '" /> </td> <td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;">სახელი და გვარი</td> </td> </tr> <tr > <td style="width: 180px;">' . $res['name1'] . '</td> </td> </tr> <tr > <td style="width: 180px;">ტელეფონი</td> </td> </tr> <tr> <td style="width: 180px;">' . $res['personal_phone'] . '</td> </td> </tr> <tr> <td style="width: 180px;">ელ-ფოსტა</td> </td> </tr> <tr> <td style="width: 180px;">' . $res['mail'] . '</td> <td ></td> </tr> <tr> <td td style="width: 180px;">user-ი</td> <td td style="width: 180px;"></td> </tr> <tr> <td style="width: 180px;">' . $res['user'] . '</td> <td td style="width: 180px;"></td> </tr> </table> </fieldset> <fieldset> <legend>მომართვის ავტორი</legend> <table> <tr> <td>სულ</td> <td></td> <td></td> <td style="width: 150px;"></td> <td>1</td> </tr> <tr> <td></td> <td>მოგვარებულები</td> <td></td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td>პრეტენზია</td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td>ინფორმაცია</td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td>მიმდინარე</td> <td></td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td></td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td>პრეტენზია</td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td>ინფორმაცია</td> <td style="width: 150px;"></td> <td>2</td> </tr> <tr> <td></td> <td></td> <td></td> <td style="width: 150px;"></td> <td style="width: 300px;"> <input type="button" value="ვრცლად"/> </td> </tr> </tr> </table> </fieldset> <fieldset> <legend>დამატებითი ინფორმაცია</legend> <table style="float: left; border: 1px solid #85b1de; width: 180px; text-align: center;"> <tr style="border-bottom: 1px solid #85b1de;"> <td colspan="2">საუბრის ჩანაწერი</td> </tr> <tr style="border-bottom: 1px solid #85b1de; "> <td>დრო</td> <td style="border-left:1px solid #85b1de; width: 50px;">ჩანაწერი</td> </tr> <tr > <td></td> <td><input type="button" value="მოსმენა"/></td> </tr> <table/> <table style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;"> <tr> <td> <div class="file-uploader"> <input id="choose_file" type="file" name="choose_file" class="input" style="display: none;"> <button id="choose_button" class="center">აირჩიეთ ფაილი</button> <input id="hidden_inc" type="text" value="' . increment('task') . '" style="display: none;"> </div> </td> </tr> </table> <table style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;"> <tr style="border-bottom: 1px solid #85b1de;"> <td colspan="3">მიმაგრებული ფაილი</td> </tr> </table> <table id="file_div" style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;">'; while ($increm_row = mysql_fetch_assoc($increm)) { $data .= ' <tr style="border-bottom: 1px solid #85b1de;"> <td style="width:110px; display:block;word-wrap:break-word;">' . $increm_row[name] . '</td> <td ><button type="button" value="media/uploads/file/' . $increm_row[rand_name] . '" style="cursor:pointer; border:none; margin-top:25%; display:block; height:16px; width:16px; background:none;background-image:url(\'media/images/get.png\');" id="download" ></button><input type="text" style="display:none;" id="download_name" value="' . $increm_row[rand_name] . '"> </td> <td ><button type="button" value="' . $increm_row[id] . '" style="cursor:pointer; border:none; margin-top:25%; display:block; height:16px; width:16px; background:none; background-image:url(\'media/images/x.png\');" id="delete"></button></td> </tr>'; } $data .= ' </table> </fieldset> </div> </div>'; } $data .= '<input type="hidden" id="outgoing_call_id" value="' . $res['id'] . '" />'; return $data; }
function GetPage($res = '', $number, $incom_id) { $num = 0; if ($res[phone] == "") { $num = $number; } else { $num = $res[phone]; } $tanxa = 'class="hidden dialog-form-table"'; $disabled = ''; $hidden_class = ''; if ($_REQUEST['id'] == '') { $hidden_class = 'class="hidden"'; } else { //echo $_REQUEST['id']; if ($res[category_id] == 407) { //echo $res[category_id]; $tanxa = 'class="dialog-form-table"'; } else { $tanxa = 'class="hidden dialog-form-table"'; } $disabled = 'disabled="disabled"'; } $increm = mysql_query("\tSELECT `name`,\n\t \t\t\t\t\t\t\t\t`rand_name`,\n\t\t\t\t\t\t\t\t\t`id`\n\t\t\t\t\t\t\tFROM \t`file`\n\t\t\t\t\t\t\tWHERE `task_id` = {$res['id']}\n\t\t\t\t\t\t\t "); $data .= ' <!-- jQuery Dialog --> <div id="add-edit-goods-form" title="საქონელი"> <!-- aJax --> </div> <div id="dialog-form"> <div style="float: left; width: 500px;"> <fieldset > <legend>ძირითადი ინფორმაცია</legend> <table width="100%" class="dialog-form-table"> <tr> <td style="width: 215px;"><label for="req_num">დავალების №</label></td> <td style="width: 215px !important;"><label for="req_data">თარიღი</label></td> <td style="width: 215px;"><label for="req_data">ტელეფონი</label></td> </tr> <tr> <td style="width: 215px;"> <input style="width: 180px; type="text" id="id" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField user_id\'" value="' . $res['id'] . '" disabled="disabled" /> </td> <td style="width: 215px;"> <input style="width: 180px; type="text" id="c_date" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField date\'" value="' . $res['call_date'] . '" disabled="disabled" /> </td> <td style="width: 215px;"> <input style="width: 180px; type="text" id="phone" class="idle" onblur="this.className=\'idle\'" value="' . $res['phone'] . '" /> </td> </tr> </table>'; $data .= '<table id="additiona" class="dialog-form-table" width="100%"> <tr> <td style="width: 215px;"><label for="d_number">ზარის ტიპი</label></td> <td style="width: 215px;"><label for="d_number">კატეგორია</label></td> <td style="width: 215px;"><label for="d_number">ქვე-კატეგოტია</label></td> </tr> <tr> <td style="width: 215px;"><select style="width: 186px;" id="call_type_id" class="idls object"" >' . Getcall_type($res['call_type_id']) . '</select></td> <td style="width: 215px;"><select style="width: 186px;" id="category_parent_id" class="idls object"" >' . Getcategory1($res['call_type_id'], $res['category_id']) . '</select></td> <td style="width: 215px;"><select style="width: 186px;" id="category_id" class="idls object"" >' . Getcategory2($res['category_id'], $res['category_parent_id']) . '</select></td> </tr> </table> <table id="additiona3" ' . $tanxa . ' width="100%"> <tr id="aaaa"> <td style="width: 215px;"><label id="pey_label1" for="d_number">ტრანზაქციის ფორმა</label></td> <td style="width: 215px;"><label for="d_number" id="bank_label">მომსახურე ბანკი</label></td> <td style="width: 215px;"><label id="pey_label" for="d_number" >აპარატის ტიპი</label></td> </tr> <tr id="c"> <td style="width: 215px;"><select style="width: 186px;" id="pay_type_id" class="idls object">' . Getpay_type($res['pay_type_id']) . '</select></td> <td style="width: 215px;"><select style="width: 186px;" id="bank_id" class="idls object">' . Get_bank($res['bank_id']) . '</select></td> <td style="width: 215px;"><select style="width: 186px;" id="pay_aparat_id" class="idls object">' . Getpay_aparat($res['pay_aparat_id']) . '</select></td> </tr> <tr id="bbbb"> <td style="width: 215px;"><label for="d_number" id="card_label">ბარათის ტიპი</label></td> <td style="width: 215px;"></td> <td style="width: 215px;"></td> </tr> <tr id="d"> <td style="width: 215px;"><select style="width: 186px;" id="card_type_id" class="idls object">' . Getcard_type($res['card_type_id']) . '</select></td> <td style="width: 215px;"></td> <td style="width: 215px;"></td> </tr> </table> <table id="additiona2" class="dialog-form-table" width="100%"> <tr> <td style="width: 215px;"><label for="req_num">პრობლემის თარიღი</label></td> <td style="width: 215px;"><label for="d_number">სტატუსი</label></td> <td style="width: 215px;"><label for="d_number">ობიექტი</label></td> </tr> <tr> <td style="width: 215px;"> <input style="width: 180px;" type="text" id="problem_date" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res[problem_date] . '"" /> </td> <td style="width: 215px;"><select style="width: 186px;" id="call_status_id" class="idls object">' . Getcall_status($res['call_status_id']) . '</select></td> <td style="width: 215px;"><select style="width: 186px;" id="object_id" class="idls object">' . Getobject($res['object_id']) . '</select></td> </tr> <tr> <td style="width: 215px;"><label for="task_type_id">დავალების ტიპი</label></td> <td style="width: 215px;"><label for="task_department_id">განყოფილება</label></td> <td style="width: 215px;"><label for="persons_id">პასუხისმგებელი პირი</label></td> </tr> <tr> <td style="width: 215px;"><select style="width: 186px;" id="task_type_id" class="idls object">' . Gettask_type($res['task_type_id']) . '</select></td> <td style="width: 215px;"><select style="width: 186px;" id="task_department_id" class="idls object">' . Getdepartment($res['task_department_id']) . '</select></td> <td style="width: 215px;"><select style="width: 186px;" id="persons_id" class="idls object">' . Getpersons($res['persons_id']) . '</select></td> </tr> <tr> <td style="width: 215px;"><label for="task_type_id">ინფორმაციის წყარო</label></td> <td style="width: 215px;"><label id="pr" class="hidden" for="d_number">პრიორიტეტები</label></td> <td style="width: 215px;"></td> </tr> <tr> <td style="width: 215px;"><select style="width: 186px;" id="source" class="idls object">' . Getsource($res['source']) . '</select></td> <td style="width: 215px;"><label class="hidden" id="priority"><select id="priority_id" class="idls" >' . Getpriority($res['priority_id']) . '</label></select></td> <td style="width: 215px;"></td> </tr> </table> <table id="additiona1" class="hidden dialog-form-table" width="100%"> <tr> <td style="width: 215px;"><label for="req_num">შესრ.პერ.დასაწყისი</label></td> <td style="width: 215px !important;"><label for="req_data">შესრ.პერ.დასასრული</label></td> <td style="width: 215px;"><label for="req_phone">შესრულების დრო</label></td> </tr> <tr> <td style="width: 215px;"> <input type="text" id="planned_date" style="width: 180px;" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['planned_end_date'] . '" /> </td> <td style="width: 215px;"> <input type="text" id="fact_end_date" style="width: 180px;" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['call_date'] . '"/> </td> <td style="width: 215px;"> <input type="text" id="call_duration" style="width: 180px;" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $num . '" /> </td> </tr> </table> <br> <table> <tr> <td style="width: 150px;"><label for="content">საუბრის შინაარსი</label></td> <td style="width: 150px;"><label for="content"></label></td> <td style="width: 150px;"><label for="content"></label></td> </tr> <tr> <td colspan="6"> <textarea ' . $disabled . ' style="width: 641px; resize: vertical;" id="comment" class="idle" name="content" cols="300" rows="4">' . $res['comment'] . '</textarea> </td> </tr> <tr> <td ' . $hidden_class . ' style="width: 215px;"><label for="content">პრობლემის გადაწყვეტა</label></td> </tr> <tr> <td colspan="5"> <textarea ' . $hidden_class . ' style="width: 641px; resize: vertical;" id="problem_comment" class="idle" name="call_content" cols="300" rows="4">' . $res['problem_comment'] . '</textarea> </td> </tr> </table>'; $data .= ' </fieldset > </div> <div> </fieldset> </div> <div style="float: right; width: 355px;"> <!---------------------------------------------------------------კლიენტი----------------------------------------------------------------------------> <fieldset onload="legal()"> <legend>მომართვის ავტორი</legend> <table style="height: 172px;"> <tr style="height:20px;"> <td style="padding: 0px 0px 10px 45px;"><input type="radio" style="float:left;" class="legal" onclick="legal()" value="fhisical" name="legal" ' . ($res['abonent_status'] == "fhisical" ? "checked" : "checked") . '><span style="display: inline-block; margin: 8px;" >ფიზიკური </span></td> <td style="width: 180px; height:20px;"><input type="radio" style="float:left;" class="legal" onclick="legal()" value="Jural" name="legal" ' . ($res['abonent_status'] == "Jural" ? "checked" : "") . '><span style="display: inline-block; margin: 8px;">იურიდიული </td> </tr> <tr style="height:20px;"> <td style="width: 180px; height:20px;">ტელეფონი</td> <td style="width: 180px; height:20px;"><div class="fhisical">პირადი ნომერი</div><div class="Jural">საიდენთიპიკაციო კოდი</div></td> </tr> <tr style="height:40px;"> <td style="width: 180px; height:20px;"><input type="text" id="abonent_phone" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['abonent_phone'] . '" /></td> <td style="width: 180px; height:20px;"><input type="text" id="abonent_pin" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['abonent_pin'] . '" /></td> </tr> <tr style="height:20px;"> <td colspan="2" style="height:20px;"><div class="fhisical">აბონენტის სახელი გვარი</div><div class="Jural">ორგანიზაცია</div></td> </tr> <tr style="height:40px;"> <td colspan="2" style="height:20px;"> <input type="text" id="abonent_name" style="width: 328px;" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['abonent_name'] . '" /> </td> </tr> <tr style="height:20px;" class="Jural"> <td colspan="2" style="height:20px;">პასუხისმგებელი პირი</td> </tr> <tr style="height:40px;" class="Jural"> <td colspan="2" style="height:20px;"> <input type="text" id="abonent_responsibl_person" style="width: 328px;" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['abonent_responsibl_person'] . '" /> </td> </tr> <tr style="height:20px;"> <td colspan="2" style="height:20px;">მისამართი</td> </tr> <tr style="height:20px;"> <td colspan="2" style="height:40px;"> <textarea type="text" id="abonent_address" style="width: 328px; resize: vertical;" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" >' . $res['abonent_address'] . '</textarea> </td> </tr> <tr style="height:20px;"> <td style="width: 180px;"></td> <td style="width: 180px;">აბონენტის ნომერი</td> </tr> <tr style="height:40px;"> <td style="width: 180px;">შენიშვნა</td> <td style="width: 180px;"><input type="text" id="abonent_number" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" value="' . $res['abonent_number'] . '" /></td> </tr> <tr style="height:40px;"> <td colspan="2"> <textarea type="text" id="abonent_coment" style="width: 328px; resize: vertical;" class="idle" onblur="this.className=\'idle\'" onfocus="this.className=\'activeField\'" >' . $res['abonent_coment'] . '</textarea> </td> </tr> </table> </fieldset> <div id="additional_info">'; if (!empty($res['personal_pin'])) { $data .= get_addition_all_info($res['personal_pin']); } $data .= '</div>'; $data .= GetRecordingsSection($res); $data .= ' <fieldset> <legend>დამატებითი ინფორმაცია</legend> <table id="additiona1" class="hidden dialog-form-table" style="float: left; border: 1px solid #85b1de; width: 180px; text-align: center;"> <table style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;"> <tr> <td> <div class="file-uploader"> <input id="choose_file" type="file" name="choose_file" class="input" style="display: none;"> <button id="choose_button" class="download">აირჩიეთ ფაილი</button> <input id="hidden_inc" type="text" value="' . increment('task') . '" style="display: none;"> </div> </td> </tr> </table> <table style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;"> <tr style="border-bottom: 1px solid #85b1de;"> <td colspan="3">მიმაგრებული ფაილი</td> </tr> </table> <table id="file_div" style="float: right; border: 1px solid #85b1de; width: 150px; text-align: center;">'; while ($increm_row = mysql_fetch_assoc($increm)) { $data .= ' <tr style="border-bottom: 1px solid #85b1de;"> <td style="width:110px; display:block;word-wrap:break-word;">' . $increm_row[name] . '</td> <td ><button type="button" value="media/uploads/file/' . $increm_row[rand_name] . '" style="cursor:pointer; border:none; margin-top:25%; display:block; height:16px; width:16px; background:none;background-image:url(\'media/images/get.png\');" id="download" ></button><input type="text" style="display:none;" id="download_name" value="' . $increm_row[rand_name] . '"> </td> <td ><button type="button" value="' . $increm_row[id] . '" style="cursor:pointer; border:none; margin-top:25%; display:block; height:16px; width:16px; background:none; background-image:url(\'media/images/x.png\');" id="delete"></button></td> </tr>'; } $data .= ' </table> </fieldset> </div> <!-- ID --> <input type="hidden" id="req_id" value="' . $res['id'] . '" /> </div>'; return $data; }