本文整理汇总了C++中Ticket::addLogEntry方法的典型用法代码示例。如果您正苦于以下问题:C++ Ticket::addLogEntry方法的具体用法?C++ Ticket::addLogEntry怎么用?C++ Ticket::addLogEntry使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Ticket
的用法示例。
在下文中一共展示了Ticket::addLogEntry方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: scanOrphans
//.........这里部分代码省略.........
strcpy(tmpPhone, "");
workStr = connDB.curRow["DSLNumber"];
strcat(tmpPhone, workStr.substr(0, 3).c_str());
strcat(tmpPhone, "%%");
strcat(tmpPhone, workStr.substr(3, 3).c_str());
strcat(tmpPhone, "%%");
strcat(tmpPhone, workStr.substr(6, 4).c_str());
strcat(tmpPhone, "%%");
//printf("select * from PhoneNumbers where PhoneNumber LIKE '%s'\n", tmpPhone);
phoneDB.query("select * from PhoneNumbers where PhoneNumber LIKE '%s'", tmpPhone);
if (phoneDB.rowCount) {
// Found a matching phone number
phoneDB.getrow();
custID = atol(phoneDB.curRow["RefID"]);
workDB.dbcmd("update QwestDSLNotices set CustomerID = %ld where NoticeID = %ld", custID, atol(connDB.curRow["NoticeID"]));
// Now, add the notice into the customer notes.
ADBTable notesDB("Notes");
notesDB.setValue("AutoNote", 1);
notesDB.setValue("AddedBy", "Auto");
notesDB.setValue("NoteDate", connDB.curRow["NoticeDate"]);
notesDB.setValue("CustomerID", custID);
notesDB.setValue("NoteType", "Qwest DSL");
notesDB.setValue("Category", connDB.curRow["Action"]);
notesDB.setValue("SubCategory", "Connect Notice");
notesDB.setValue("Subject", connDB.curRow["Action"]);
strcpy(noteText, "");
strcat(noteText, "Action ");
strcat(noteText, connDB.curRow["Action"]);
strcat(noteText, "\n");
strcat(noteText, "Name ");
strcat(noteText, connDB.curRow["Name"]);
strcat(noteText, "\n");
strcat(noteText, "Addr1 ");
strcat(noteText, connDB.curRow["Addr1"]);
strcat(noteText, "\n");
strcat(noteText, "Addr2 ");
strcat(noteText, connDB.curRow["Addr2"]);
strcat(noteText, "\n");
strcat(noteText, "Addr3 ");
strcat(noteText, connDB.curRow["Addr3"]);
strcat(noteText, "\n");
strcat(noteText, "Select ");
strcat(noteText, connDB.curRow["Select256"]);
strcat(noteText, "\n");
strcat(noteText, "CBR Number ");
strcat(noteText, connDB.curRow["CBR"]);
strcat(noteText, "\n");
strcat(noteText, "DSL Phone ");
strcat(noteText, connDB.curRow["DSLNumber"]);
strcat(noteText, "\n");
strcat(noteText, "Blarg Circuit ");
strcat(noteText, connDB.curRow["BlargCircuit"]);
strcat(noteText, "\n");
strcat(noteText, "Due Date ");
strcat(noteText, connDB.curRow["DueDate"]);
strcat(noteText, "\n");
strcat(noteText, "Speed ");
strcat(noteText, connDB.curRow["LineSpeed"]);
strcat(noteText, "\n");
strcat(noteText, "VPI ");
strcat(noteText, connDB.curRow["VPI"]);
strcat(noteText, "\n");
strcat(noteText, "VCI ");
strcat(noteText, connDB.curRow["VCI"]);
strcat(noteText, "\n");
notesDB.setValue("NoteText", noteText);
notesDB.ins();
// Now that the note has been inserted, check for any
// tickets that may be opened on this line still.
if (atol(connDB.curRow["TicketNo"])) {
// We have a ticket. Load it up.
Ticket tmpTick;
tmpTick.setTicketNo(atol(connDB.curRow["TicketNo"]));
if (tmpTick.status() != Ticket::Closed) {
// The ticket is open. Set the customer ID and
// close it.
tmpTick.setCustomerID(custID);
tmpTick.setStatus(Ticket::Closed);
tmpTick.addLogEntry(Ticket::Normal, "DSL Number %s found for Customer ID %ld. Auto-closing ticket.", connDB.curRow["DSLNumber"], custID);
}
}
}
}
}
示例2: createSalesTicket
int createSalesTicket(ConnectNotice &cn)
{
char noteText[4096];
char summary[4096];
Ticket newTick;
sprintf(summary, "Qwest DSL - %s %s", cn.connType, cn.custCirc);
newTick.setName(cn.custName);
newTick.setSummary(summary);
newTick.setOpened();
newTick.setModified();
newTick.setStatus(Ticket::Unexamined);
newTick.setType(Ticket::Sales);
newTick.create();
strcpy(noteText, "The following Qwest connect notice has been recieved and no matching phone numbers could be found for it.<P>\n");
strcat(noteText, "Action ");
strcat(noteText, cn.connType);
strcat(noteText, "<BR>\n");
strcat(noteText, "Notice Date ");
strcat(noteText, cn.noticeDate);
strcat(noteText, "<BR>\n");
strcat(noteText, "Name ");
strcat(noteText, cn.custName);
strcat(noteText, "<BR>\n");
strcat(noteText, "Addr1 ");
strcat(noteText, cn.addr1);
strcat(noteText, "<BR>\n");
strcat(noteText, "Addr2 ");
strcat(noteText, cn.addr2);
strcat(noteText, "<BR>\n");
strcat(noteText, "Addr3 ");
strcat(noteText, cn.addr3);
strcat(noteText, "<BR>\n");
strcat(noteText, "Select ");
strcat(noteText, cn.isSelect);
strcat(noteText, "<BR>\n");
strcat(noteText, "CBR Number ");
strcat(noteText, cn.cbr);
strcat(noteText, "<BR>\n");
strcat(noteText, "DSL Phone ");
strcat(noteText, cn.custCirc);
strcat(noteText, "<BR>\n");
strcat(noteText, "Blarg Circuit ");
strcat(noteText, cn.hostCirc);
strcat(noteText, "<BR>\n");
strcat(noteText, "Due Date ");
strcat(noteText, cn.dueDate);
strcat(noteText, "<BR>\n");
strcat(noteText, "Speed ");
strcat(noteText, cn.speed);
strcat(noteText, "<BR>\n");
strcat(noteText, "VPI ");
strcat(noteText, cn.vpi);
strcat(noteText, "<BR>\n");
strcat(noteText, "VCI ");
strcat(noteText, cn.vci);
strcat(noteText, "<BR>\n");
newTick.addLogEntry(Ticket::Normal, "%s", noteText);
ADB tmpDB;
cn.ticketNo = newTick.ticketNo();
tmpDB.dbcmd("update QwestDSLNotices set TicketNo = %ld where NoticeID = %ld", cn.ticketNo, cn.noticeID);
return 1;
}