MCPcopy Create free account
hub / github.com/altairwei/WizNotePlus / modifyObjectModifiedTime

Method modifyObjectModifiedTime

src/database/WizIndex.cpp:2209–2236  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2207}
2208
2209bool WizIndex::modifyObjectModifiedTime(const CString& strGUID, const CString& strType, const WizOleDateTime& t)
2210{
2211 CString strTableName;
2212 CString strKeyFieldName;
2213
2214 if (!getObjectTableInfo(strType, strTableName, strKeyFieldName))
2215 return false;
2216
2217 CString strTimeFieldName;
2218 if (0 == strType.compareNoCase("document")
2219 || 0 == strType.compareNoCase("attachment"))
2220 {
2221 strTimeFieldName = "DT_INFO_MODIFIED";
2222 }
2223 else
2224 {
2225 strTimeFieldName = "DT_MODIFIED";
2226 }
2227
2228 CString strSQL = WizFormatString5("update %1 set %2=%3 where %4=%5",
2229 strTableName,
2230 strTimeFieldName,
2231 TIME2SQL(t),
2232 strKeyFieldName,
2233 STR2SQL(strGUID));
2234
2235 return execSQL(strSQL);
2236}
2237
2238bool WizIndex::getObjectModifiedTime(const CString& strGUID, const CString& strType, WizOleDateTime& t)
2239{

Callers

nothing calls this directly

Calls 2

WizFormatString5Function · 0.85
compareNoCaseMethod · 0.80

Tested by

no test coverage detected