@avrham
זה בקוד html
<!DOCTYPE html>
<html>
<head>
<title>התחברות</title>
<style>
#login-form, #register-form {
margin: 20px;
padding: 20px;
border: 1px solid #ccc;
border-radius: 5px;
width: 300px;
}
#login-form input, #register-form input {
margin-bottom: 10px;
padding: 8px;
width: 100%;
border: 1px solid #ccc;
border-radius: 3px; /* תעגול פינות שדות */
}
/* סגנון משותף לכל הכפתורים */
button {
padding: 10px 20px;
background-color: #4CAF50;
color: white;
border: none;
border-radius: 3px;
cursor: pointer;
}
#result {
margin-top: 20px;
font-weight: bold;
}
</style>
</head>
<body>
<center>
<div id="login-form">
<h2>התחבר</h2>
<input type="text" id="did" placeholder="מספר מערכת">
<input type="password" id="token" placeholder="סיסמה">
<button onclick="login()">התחבר</button>
</div>
<div id="register-form" style="display: none;">
</div>
<div id="result"></div>
</center>
<div id="myContent" style="display: none;"> <!-- מוסתר כברירת מחדל -->
<div id="content" style="display: none;">
<h2>פעולות זמינות:</h2>
<!-- קמפיינים -->
<h3>קמפיינים</h3>
<button onclick="getActiveCampaigns()">קבל קמפיינים פעילים</button>
<div>
<label for="scheduleCampaignTemplateId">מספר מזהה של הקמפיין:</label>
<input type="text" id="scheduleCampaignTemplateId" placeholder="123">
</div>
<div>
<label for="scheduleCampaignTime">זמן הפעלה (yyyy-MM-dd-HH:mm:ss):</label>
<input type="text" id="scheduleCampaignTime" placeholder="2024-01-01-10:00:00">
</div>
<button onclick="scheduleCampaign()">צור קמפיין מתוזמן</button>
<div>
<label for="scheduledCampaignsType">סוג הקמפיינים:</label>
<select id="scheduledCampaignsType">
<option value="PENDING">PENDING</option>
<option value="SUCCESSFUL">SUCCESSFUL</option>
<option value="FAILED">FAILED</option>
</select>
</div>
<div>
<label for="scheduledCampaignsOrder">סדר מיון:</label>
<select id="scheduledCampaignsOrder">
<option value="asc">asc</option>
<option value="desc">desc</option>
</select>
</div>
<button onclick="getScheduledCampaigns()">קבל קמפיינים מתוזמנים</button>
<div>
<label for="deleteScheduledCampaignId">מזהה קמפיין למחיקה:</label>
<input type="text" id="deleteScheduledCampaignId" placeholder="מזהה">
</div>
<button onclick="deleteScheduledCampaign()">מחק קמפיין מתוזמן</button>
<!-- ניהול קבצים -->
<h3>ניהול קבצים</h3>
<div>
<label for="getIVR2DirPath">נתיב תיקייה:</label>
<input type="text" id="getIVR2DirPath" placeholder="/1/2">
</div>
<div>
<label for="getIVR2DirFilesFrom">הצג קבצים מ:</label>
<input type="text" id="getIVR2DirFilesFrom" placeholder="0">
</div>
<div>
<label for="getIVR2DirFilesLimit">הצג קבצים עד:</label>
<input type="text" id="getIVR2DirFilesLimit" placeholder="5">
</div>
<div>
<label for="getIVR2DirOrderBy">מיין קבצים לפי:</label>
<select id="getIVR2DirOrderBy">
<option value="name">name</option>
<option value="date">date</option>
<option value="mtime">mtime</option>
<option value="customerdid">customerdid</option>
<option value="uploader">uploader</option>
<option value="size">size</option>
<option value="source">source</option>
</select>
</div>
<div>
<label for="getIVR2DirOrderDir">סדר קבצים:</label>
<select id="getIVR2DirOrderDir">
<option value="asc">asc</option>
<option value="desc">desc</option>
</select>
</div>
<button onclick="getIVR2Dir()">הצגת תוכן שלוחה</button>
<button onclick="getIvrTree()">קבל רשימת קבצים</button>
<div>
<label for="fileActionAction">פעולה:</label>
<select id="fileActionAction">
<option value="copy">copy</option>
<option value="move">move</option>
<option value="delete">delete</option>
</select>
</div>
<div>
<label for="fileActionWhat">נתיב מקור:</label>
<input type="text" id="fileActionWhat" placeholder="/1/2">
</div>
<div>
<label for="fileActionTarget">נתיב יעד:</label>
<input type="text" id="fileActionTarget" placeholder="/1/3">
</div>
<button onclick="fileAction()">ניהול תיקיות וקבצים</button>
<div>
<label for="getTextFileWhat">נתיב קובץ:</label>
<input type="text" id="getTextFileWhat" placeholder="/1/2/ext.ini">
</div>
<button onclick="getTextFile()">קבל תוכן קובץ טקסט</button>
<div>
<label for="uploadTextFileWhat">נתיב קובץ:</label>
<input type="text" id="uploadTextFileWhat" placeholder="/1/2/ext.ini">
</div>
<div>
<label for="uploadTextFileContents">תוכן הקובץ:</label>
<textarea id="uploadTextFileContents" placeholder="תוכן חדש"></textarea>
</div>
<button onclick="uploadTextFile()">העלאת טקסט לקובץ</button>
<div>
<label for="updateExtensionPath">נתיב שלוחה:</label>
<input type="text" id="updateExtensionPath" placeholder="/1">
</div>
<div>
<label for="updateExtensionType">סוג שלוחה:</label>
<input type="text" id="updateExtensionType" placeholder="menu">
</div>
<div>
<label for="updateExtensionTitle">כותרת שלוחה:</label>
<input type="text" id="updateExtensionTitle" placeholder="בדיקה">
</div>
<button onclick="updateExtension()">עדכון הגדרות שלוחה</button>
<!-- שיחות -->
<h3>שיחות</h3>
<div>
<label for="callActionIds">מזהה השיחה:</label>
<input type="text" id="callActionIds" placeholder="f6657b78a2f35d6d04dd203400828362">
</div>
<div>
<label for="callActionAction">פעולה:</label>
<input type="text" id="callActionAction" placeholder="set:GOasap=hangup">
</div>
<button onclick="callAction()">הכוונת שיחה</button>
<div>
<label for="getIncomingSumFrom">מאיזה תאריך:</label>
<input type="text" id="getIncomingSumFrom" placeholder="2023-12-01">
</div>
<div>
<label for="getIncomingSumTo">עד איזה תאריך:</label>
<input type="text" id="getIncomingSumTo" placeholder="2023-12-31">
</div>
<button onclick="getIncomingSum()">קבלת סיכום דקות נכנסות</button>
<div>
<label for="getSmsOutLogLimit">הגבלת תוצאות:</label>
<input type="text" id="getSmsOutLogLimit" placeholder="10">
</div>
<button onclick="getSmsOutLog()">קבלת לוג סמסים יוצאים</button>
<!-- אימות -->
<h3>אימות</h3>
<button onclick="validationToken()">קבלת מידע על טוקן</button>
<div>
<label for="doubleAuthAction">פעולה:</label>
<select id="doubleAuthAction">
<option value="SendCode">SendCode</option>
<option value="VerifyCode">VerifyCode</option>
</select>
</div>
<div>
<label for="doubleAuthCode">קוד האימות:</label>
<input type="text" id="doubleAuthCode" placeholder="קוד">
</div>
<button onclick="doubleAuth()">ביצוע אימות דו שלבי בטוקן</button>
<div>
<label for="getLoginLogLimit">הגבלת תוצאות:</label>
<input type="text" id="getLoginLogLimit" placeholder="10">
</div>
<div>
<label for="getLoginLogUsername">שם משתמש:</label>
<input type="text" id="getLoginLogUsername" placeholder="שם משתמש">
</div>
<button onclick="getLoginLog()">קבל לוג התחברויות</button>
<div>
<label for="getAllSessionsLimit">הגבלת תוצאות:</label>
<input type="text" id="getAllSessionsLimit" placeholder="10">
</div>
<button onclick="getAllSessions()">קבל סשנים פעילים</button>
<div>
<label for="killSessionSessionId">מזהה סשן:</label>
<input type="text" id="killSessionSessionId" placeholder="מזהה">
</div>
<button onclick="killSession()">סגירת סשן ספציפי</button>
<button onclick="killAllSessions()">סגירת כל הסשנים הפעילים</button>
<!-- צינתוק -->
<h3>צינתוק</h3>
<div>
<label for="runTzintukCallerId">זיהוי יוצא:</label>
<input type="text" id="runTzintukCallerId" placeholder="זיהוי">
</div>
<div>
<label for="runTzintukTzintukTimeOut">זמן צינתוק:</label>
<input type="text" id="runTzintukTzintukTimeOut" placeholder="9">
</div>
<div>
<label for="runTzintukPhones">מספרים לחיוג:</label>
<input type="text" id="runTzintukPhones" placeholder="0510000:0510001">
</div>
<button onclick="runTzintuk()">הפעלת צינתוק</button>
<div>
<label for="tzintukimListManagementAction">פעולה:</label>
<select id="tzintukimListManagementAction">
<option value="getlists">getlists</option>
<option value="getlistEnteres">getlistEnteres</option>
<option value="getLogList">getLogList</option>
<option value="resetList">resetList</option>
</select>
</div>
<div>
<label for="tzintukimListManagementTzintukimList">מספר הרשימה:</label>
<input type="text" id="tzintukimListManagementTzintukimList" placeholder="מספר">
</div>
<button onclick="tzintukimListManagement()">ניהול רשימות צינתוקים</button>
<!-- פקס -->
<h3>פקס</h3>
<div>
<label for="sendFaxPdfFile">קובץ לשליחה:</label>
<input type="text" id="sendFaxPdfFile" placeholder="ivr2://FaxTest.pdf">
</div>
<div>
<label for="sendFaxPhone">לאן לשלוח:</label>
<input type="text" id="sendFaxPhone" placeholder="0510000">
</div>
<div>
<label for="sendFaxCallerId">זיהוי יוצא:</label>
<input type="text" id="sendFaxCallerId" placeholder="זיהוי">
</div>
<div>
<label for="sendFaxDeliveryUrl">כתובת לקבלת דוח מסירה:</label>
<input type="text" id="sendFaxDeliveryUrl" placeholder="http://127.0.0.6:18358/FaxDel">
</div>
<button onclick="sendFax()">שליחת פקס</button>
<!-- בדיקות -->
<h3>בדיקות</h3>
<div>
<label for="checkIfFileExistsPath">נתיב קובץ:</label>
<input type="text" id="checkIfFileExistsPath" placeholder="ivr2:/4/ext.ini">
</div>
<button onclick="checkIfFileExists()">בדיקה האם קובץ קיים</button>
<div>
<label for="sendSmsFrom">זיהוי שולח:</label>
<input type="text" id="sendSmsFrom" placeholder="זיהוי">
</div>
<div>
<label for="sendSmsMessage">תוכן ההודעה:</label>
<textarea id="sendSmsMessage" placeholder="תוכן"></textarea>
</div>
<div>
<input type="checkbox" id="sendSmsSendFlashMessage">
<label for="sendSmsSendFlashMessage">הודעת פלאש</label>
</div>
<div>
<label for="sendSmsPhones">נמענים:</label>
<input type="text" id="sendSmsPhones" placeholder="0510000:0510001">
</div>
<button onclick="sendSms()">שליחת סמסים</button>
<div>
<label for="createBridgeCallCallerId">זיהוי שיחה יוצאת:</label>
<input type="text" id="createBridgeCallCallerId" placeholder="זיהוי">
</div>
<div>
<label for="createBridgeCallPhones">מספר טלפון לחיוג:</label>
<input type="text" id="createBridgeCallPhones" placeholder="0510000">
</div>
<div>
<label for="createBridgeCallBridgePhones">מספר טלפון לניתוב:</label>
<input type="text" id="createBridgeCallBridgePhones" placeholder="0510001">
</div>
<div>
<input type="checkbox" id="createBridgeCallDialSip">
<label for="createBridgeCallDialSip">הפעלת חיוג ל SIP</label>
</div>
<div>
<input type="checkbox" id="createBridgeCallDialSipExtension">
<label for="createBridgeCallDialSipExtension">הפעלת חיוג לשלוחת SIP</label>
</div>
<div>
<label for="createBridgeCallAccountNumber">מספר חשבון SIP:</label>
<input type="text" id="createBridgeCallAccountNumber" placeholder="מספר">
</div>
<div>
<label for="createBridgeCallSipExtension">שלוחה SIP:</label>
<input type="text" id="createBridgeCallSipExtension" placeholder="שלוחה">
</div>
<div>
<input type="checkbox" id="createBridgeCallRecordCall">
<label for="createBridgeCallRecordCall">הקלטת שיחה</label>
</div>
<div>
<input type="checkbox" id="createBridgeCallSendMailInCall">
<label for="createBridgeCallSendMailInCall">שליחת הקלטה למייל</label>
</div>
<div>
<label for="createBridgeCallSendMailInCallTo">מייל:</label>
<input type="text" id="createBridgeCallSendMailInCallTo" placeholder="מייל">
</div>
<button onclick="createBridgeCall()">הקמת שיחת גישור</button>
<div>
<label for="getQueueRealTimeQueuePath">נתיב שלוחת התור:</label>
<input type="text" id="getQueueRealTimeQueuePath" placeholder="/1/2">
</div>
<button onclick="getQueueRealTime()">קבלת מידע בזמן אמת על שלוחת תור</button>
<button onclick="getCustomerData()">קבלת מידע על המערכת</button>
<div>
<label for="viewCampaignReportsCampaignId">מזהה קמפיין:</label>
<input type="text" id="viewCampaignReportsCampaignId" placeholder="מזהה">
</div>
<div>
<input type="checkbox" id="viewCampaignReportsJson">
<label for="viewCampaignReportsJson">JSON</label>
</div>
<button onclick="viewCampaignReports()">קבלת דוח קמפיין</button>
<!-- זיהוי ספיישל -->
<h3>זיהוי ספיישל</h3>
<div>
<label for="validationCallerIdAction">פעולה:</label>
<select id="validationCallerIdAction">
<option value="send">send</option>
<option value="valid">valid</option>
</select>
</div>
<div>
<label for="validationCallerIdCallerId">מספר:</label>
<input type="text" id="validationCallerIdCallerId" placeholder="מספר">
</div>
<div>
<label for="validationCallerIdValidType">סוג אימות:</label>
<select id="validationCallerIdValidType">
<option value="SMS">SMS</option>
<option value="CALL">CALL</option>
</select>
</div>
<div>
<label for="validationCallerIdReId">מזהה בקשה:</label>
<input type="text" id="validationCallerIdReId" placeholder="מזהה">
</div>
<div>
<label for="validationCallerIdCode">קוד אימות:</label>
<input type="text" id="validationCallerIdCode" placeholder="קוד">
</div>
<button onclick="validationCallerId()">הוספה ואימות של זיהוי ספיישל</button>
<!-- תזמון משימות -->
<h3>תזמון משימות</h3>
<button onclick="getTasks()">קבלת רשימת המשימות במערכת</button>
<div>
<label for="getTasksLimit">הגבלת תוצאות:</label>
<input type="text" id="getTasksLimit" placeholder="100">
</div>
<div>
<label for="getTasksDataTaskId">מזהה משימה:</label>
<input type="text" id="getTasksDataTaskId" placeholder="מזהה">
</div>
<button onclick="getTasksData()">קבלת מידע מפורט על משימה מסויימת</button>
<div>
<label for="getTasksLogsTaskId">מזהה משימה:</label>
<input type="text" id="getTasksLogsTaskId" placeholder="מזהה">
</div>
<button onclick="getTasksLogs()">קבלת לוג הפעלות על משימה מסויימת</button>
<div>
<label for="createTaskDescription">תיאור משימה:</label>
<textarea id="createTaskDescription" placeholder="תיאור"></textarea>
</div>
<div>
<label for="createTaskMinute">דקה:</label>
<input type="number" id="createTaskMinute" min="0" max="59">
</div>
<div>
<label for="createTaskHour">שעה:</label>
<input type="number" id="createTaskHour" min="0" max="23">
</div>
<div>
<label for="createTaskYear">שנה:</label>
<input type="number" id="createTaskYear" min="2023">
</div>
<div>
<label for="createTaskDay">יום בחודש:</label>
<input type="number" id="createTaskDay" min="1" max="31">
</div>
<div>
<label for="createTaskMonth">חודש:</label>
<input type="number" id="createTaskMonth" min="1" max="12">
</div>
<div>
<input type="checkbox" id="createTaskActive">
<label for="createTaskActive">פעילה</label>
</div>
<div>
<input type="checkbox" id="createTaskCheckIsKodesh">
<label for="createTaskCheckIsKodesh">מנוע שבת וחגים</label>
</div>
<div>
<input type="checkbox" id="createTaskMailInEnd">
<label for="createTaskMailInEnd">מייל בסיום מוצלח</label>
</div>
<div>
<input type="checkbox" id="createTaskMailInError">
<label for="createTaskMailInError">מייל בסיום בכישלון</label>
</div>
<div>
<input type="checkbox" id="createTaskIfAnyDay">
<label for="createTaskIfAnyDay">כל יום בשבוע</label>
</div>
<div>
<label for="createTaskDays">ימי הפעילות (JSON):</label>
<textarea id="createTaskDays" placeholder='{"0":1,"1":0,"2":1,"3":1,"4":0,"5":0,"6":0}'></textarea>
</div>
<div>
<label for="createTaskTaskList">סוג משימה:</label>
<select id="createTaskTaskList">
<option value="SendSMS">SendSMS</option>
<option value="RunTzintuk">RunTzintuk</option>
<option value="MoveOnFile">MoveOnFile</option>
</select>
</div>
<div>
<label for="createTaskCallerId">זיהוי יוצא:</label>
<input type="text" id="createTaskCallerId" placeholder="זיהוי">
</div>
<div>
<label for="createTaskList">רשימה:</label>
<input type="text" id="createTaskList" placeholder="מזהה/שם רשימה">
</div>
<div>
<label for="createTaskSmsList">רשימת תפוצה:</label>
<input type="text" id="createTaskSmsList" placeholder="מזהה">
</div>
<div>
<label for="createTaskTypeList">סוג רשימה:</label>
<select id="createTaskTypeList">
<option value="tpl">tpl</option>
<option value="tzl">tzl</option>
</select>
</div>
<div>
<label for="createTaskSmsMessage">הודעת סמס:</label>
<textarea id="createTaskSmsMessage" placeholder="הודעה"></textarea>
</div>
<div>
<label for="createTaskFolder">תיקיית מקור:</label>
<input type="text" id="createTaskFolder" placeholder="תיקייה">
</div>
<div>
<label for="createTaskTarget">תיקיית יעד:</label>
<input type="text" id="createTaskTarget" placeholder="תיקייה">
</div>
<div>
<label for="createTaskMoveFileType">סוג קובץ:</label>
<select id="createTaskMoveFileType">
<option value="maxFile">maxFile</option>
<option value="minFile">minFile</option>
</select>
</div>
<div>
<label for="createTaskBlockMoveIfNewFileInMinutes">חסימת העברת קובץ:</label>
<input type="number" id="createTaskBlockMoveIfNewFileInMinutes" placeholder="דקות">
</div>
<button onclick="createTask()">יצירת משימה חדשה</button>
<div>
<label for="updateTaskTaskId">מזהה משימה לעריכה:</label>
<input type="text" id="updateTaskTaskId" placeholder="מזהה">
</div>
<div>
<label for="updateTaskDescription">תיאור משימה:</label>
<textarea id="updateTaskDescription" placeholder="תיאור"></textarea>
</div>
<div>
<label for="updateTaskMinute">דקה:</label>
<input type="number" id="updateTaskMinute" min="0" max="59">
</div>
<div>
<label for="updateTaskHour">שעה:</label>
<input type="number" id="updateTaskHour" min="0" max="23">
</div>
<div>
<label for="updateTaskYear">שנה:</label>
<input type="number" id="updateTaskYear" min="2023">
</div>
<div>
<label for="updateTaskDay">יום בחודש:</label>
<input type="number" id="updateTaskDay" min="1" max="31">
</div>
<div>
<label for="updateTaskMonth">חודש:</label>
<input type="number" id="updateTaskMonth" min="1" max="12">
</div>
<div>
<input type="checkbox" id="updateTaskActive">
<label for="updateTaskActive">פעילה</label>
</div>
<div>
<input type="checkbox" id="updateTaskMailInEnd">
<label for="updateTaskMailInEnd">מייל בסיום מוצלח</label>
</div>
<div>
<input type="checkbox" id="updateTaskMailInError">
<label for="updateTaskMailInError">מייל בסיום בכישלון</label>
</div>
<div>
<input type="checkbox" id="updateTaskIfAnyDay">
<label for="updateTaskIfAnyDay">כל יום בשבוע</label>
</div>
<div>
<label for="updateTaskDays">ימי הפעילות (JSON):</label>
<textarea id="updateTaskDays" placeholder='{"0":1,"1":0,"2":1,"3":1,"4":0,"5":0,"6":0}'></textarea>
</div>
<button onclick="updateTask()">עידכון זמני ריצה של משימה קיימת</button>
<div>
<label for="deleteTaskTaskId">מזהה משימה למחיקה:</label>
<input type="text" id="deleteTaskTaskId" placeholder="מזהה">
</div>
<button onclick="deleteTask()">מחיקת משימה</button>
<!-- TTS -->
<h3>TTS</h3>
<div>
<label for="sendTtsCallerId">זיהוי שולח:</label>
<input type="text" id="sendTtsCallerId" placeholder="זיהוי">
</div>
<div>
<label for="sendTtsTtsMessage">טקסט:</label>
<textarea id="sendTtsTtsMessage" placeholder="טקסט"></textarea>
</div>
<div>
<label for="sendTtsCallbackUrl">קישור לקבלת Hooks:</label>
<input type="text" id="sendTtsCallbackUrl" placeholder="קישור">
</div>
<div>
<label for="sendTtsRepeatFile">כמה פעמים לחזור:</label>
<input type="number" id="sendTtsRepeatFile" min="1">
</div>
<div>
<label for="sendTtsTtsRate">מהירות השמעה:</label>
<input type="number" id="sendTtsTtsRate" min="-10" max="10">
</div>
<div>
<label for="sendTtsTtsVoice">קול:</label>
<input type="text" id="sendTtsTtsVoice" placeholder="קול">
</div>
<div>
<input type="checkbox" id="sendTtsSendMail">
<label for="sendTtsSendMail">קבל דוח קמפיין</label>
</div>
<div>
<label for="sendTtsPhones">נמענים:</label>
<input type="text" id="sendTtsPhones" placeholder="0510000:0510001">
</div>
<button onclick="sendTts()">שליחת קמפיין הודעת TTS</button>
<!-- YMGR -->
<h3>YMGR</h3>
<div>
<label for="renderYMGRFileWath">מיקום הקובץ:</label>
<input type="text" id="renderYMGRFileWath" placeholder="ivr2:/ymgtTest.ymgr">
</div>
<div>
<label for="renderYMGRFileConvertType">סוג הקובץ:</label>
<select id="renderYMGRFileConvertType">
<option value="html">html</option>
<option value="csv">csv</option>
<option value="json">json</option>
</select>
</div>
<div>
<input type="checkbox" id="renderYMGRFileNotLoadLang">
<label for="renderYMGRFileNotLoadLang">לא להשתמש בתרגום</label>
</div>
<div>
<label for="renderYMGRFileRenderLanguage">שפת חיפוש תרגומים:</label>
<input type="text" id="renderYMGRFileRenderLanguage" placeholder="HE">
</div>
<button onclick="renderYMGRFile()">הפקת דוח מקובץ ymgr</button>
<!-- תנועות יחידות -->
<h3>תנועות יחידות</h3>
<button onclick="getCustomerSmsTransactions()">קבלת תנועות יחידות סמסים</button>
<!-- בדיקת תיקיה -->
<h3>בדיקת תיקיה</h3>
<div>
<label for="checkIfFolderExistsPath">נתיב תיקיה:</label>
<input type="text" id="checkIfFolderExistsPath" placeholder="ivr/10">
</div>
<button onclick="checkIfFolderExists()">בדיקה האם תיקייה קיימת</button>
<!-- SIP -->
<h3>SIP</h3>
<div>
<label for="createSipAccountExtNumber">מספר שלוחה (אופציונלי):</label>
<input type="number" id="createSipAccountExtNumber" min="200" max="10000">
</div>
<button onclick="createSipAccount()">יצירת חשבון</button>
<button onclick="getSipAccountsInCustomer()">קבלת רשימת החשבונות</button>
<div>
<label for="sipToWssAccountNumber">מספר חשבון (אופציונלי):</label>
<input type="number" id="sipToWssAccountNumber">
</div>
<button onclick="sipToWss()">SipToWss</button>
<button onclick="sipToUdp()">SipToUdp</button>
<div>
<label for="editCallerIdInSipAccountAccountNumber">מספר חשבון:</label>
<input type="number" id="editCallerIdInSipAccountAccountNumber">
</div>
<div>
<label for="editCallerIdInSipAccountCallerId">זיהוי יוצא:</label>
<input type="text" id="editCallerIdInSipAccountCallerId" placeholder="זיהוי">
</div>
<button onclick="editCallerIdInSipAccount()">הגדרת זיהוי יוצא קבוע</button>
<div>
<label for="deleteSipAccountAccountNumber">מספר חשבון (או מערך):</label>
<input type="text" id="deleteSipAccountAccountNumber" placeholder="מספר/מערך">
</div>
<button onclick="deleteSipAccount()">מחיקת חשבון</button>
</div>
<script>
function login() {
const did = document.getElementById("did").value;
const token = document.getElementById("token").value;
const apiUrl = `https://www.call2all.co.il/ym/api/Login?username=${did}&password=${token}`;
fetch(apiUrl)
.then(response => response.json())
.then(data => {
if (data.responseStatus === 'OK') {
document.getElementById("myContent").style.display = "block";
} else {
// אם ההתחברות נכשלה, הצג הודעת שגיאה
document.getElementById("result").innerHTML = "<h1>ERROR שגיאה</h1>";
}
})
.catch(error => {
// טיפול בשגיאות רשת
console.error("Error:", error);
document.getElementById("result").innerHTML = "<h1>ERROR שגיאה ברשת</h1>";
});
}
</script>
</body>
</html>