GoogleDrive में किसी दस्तावेज़ को संपादित करने के बाद, ऐसा लगता है कि LastModified मान कभी-कभी नहीं बदलता है। ऐसा लगता है कि मूल्य कुछ मिनटों में अपडेट किया जाएगा।फ़ाइल संपादन के बाद Etag और LastModifiedDate donot परिवर्तन
मैंने ड्राइवएसडीके द्वारा दस्तावेज़ के एटाग को लाने की कोशिश की, यह इटाग मूल्य भी होता है।
यह अजीब व्यवहार मुझे वास्तविक समय पर दस्तावेज़ स्थिति (संशोधित या नहीं) प्राप्त करने से रोकता है। किसी भी सुझाव की अत्यधिक सराहना की जाएगी।
[नमूना अनुरोध और प्रतिक्रिया] अनुरोध है सिर्फ GoogleDrive ListFiles: https://www.googleapis.com/drive/v2/files
यहाँ प्रतिक्रिया JSON का हिस्सा है, और आप देख सकते हैं कि ModifiedDate ModifiedByMeDate से पहले है।
{
"kind": "drive#fileList",
"etag": "\"3NNCnvnQuji-pODa6SMQ6atlc3M/oKnf21kAcJKTCIycS597xCSR2bk\"",
"selfLink": "https://www.googleapis.com/drive/v2/files",
"items": [
{
"kind": "drive#file",
"id": "1lZjcJIf3Chuu5upFqtiqfTRnRw7*****rFL_tlO8A",
"etag": "\"3NNCnvnQuji-pODa6SMQ6atlc3M/MTM1NDY5MzMyMzQ1Mg\"",
"selfLink": "https://www.googleapis.com/drive/v2/files/1lZjcJIf3Chuu5upFqtiqfTRnRw7wSUjbRurFL_tlO8A",
"alternateLink": "https://docs.google.com/a/*****.com/document/d/1lZjcJIf3Chuu5upFqtiqfTRnRw7wSUjbRurFL_tlO8A/edit",
"embedLink": "https://docs.google.com/a/*****.com/document/d/1lZjcJIf3Chuu5upFqtiqfTRnRw7wSUjbRurFL_tlO8A/preview",
"iconLink": "https://ssl.gstatic.com/docs/doclist/images/icon_11_document_list.png",
"thumbnailLink": "https://docs.google.com/feeds/vt?gd=true&id=1lZjcJIf3Chuu5upFqtiq*****7wSUjbRurFL_tlO8A&v=22&s=AMedNnoAAAAAU*****UK74n3UiIg0L4TY-NwP3EaAU&sz=s220",
"title": "TestFile",
"mimeType": "application/vnd.google-apps.document",
"labels": {
"starred": false,
"hidden": false,
"trashed": false,
"restricted": false,
"viewed": true
},
"createdDate": "2012-07-24T08:14:13.918Z",
"modifiedDate": "2012-12-06T01:49:57.982Z",
"modifiedByMeDate": "2012-12-06T01:49:57.982Z",
"lastViewedByMeDate": "2012-12-06T01:50:06.974Z",
"parents": [
{
"kind": "drive#parentReference",
"id": "0AJ-aGTt-gWksUk9PVA",
"selfLink": "https://www.googleapis.com/drive/v2/files/1lZjcJIf3Chuu5upFqtiqfTRnRw7wSUjbRurFL_tlO8A/parents/0AJ-aGTt-gWksUk9PVA",
"parentLink": "https://www.googleapis.com/drive/v2/files/0AJ-aGTt-gWksUk9PVA",
"isRoot": true
}
],
"exportLinks": {
"application/vnd.openxmlformats-officedocument.wordprocessingml.document": "https://docs.google.com/feeds/download/documents/export/Export?id=1l*****huu5upFqtiqfTRnRw7wSUjbRurFL_tlO8A&exportFormat=docx",
"application/vnd.oasis.opendocument.text": "https://docs.google.com/feeds/download/documents/export/Export?id=1lZjcJIf3Chuu5upF*****SUjbRurFL_tlO8A&exportFormat=odt",
"text/html": "https://docs.google.com/feeds/download/documents/export/Export?id=1lZjcJIf3Chuu5upFqtiqfTRnRw7wSUj*****L_tlO8A&exportFormat=html",
"application/rtf": "https://docs.google.com/feeds/download/documents/export/Export?id=1lZjcJIf3Chuu5upFqtiq*****SUjbRurFL_tlO8A&exportFormat=rtf",
"text/plain": "https://docs.google.com/feeds/download/documents/export/Export?id=1lZjcJIf3Chuu5upFqtiqf*****SUjbRurFL_tlO8A&exportFormat=txt",
"application/pdf": "https://docs.google.com/feeds/download/documents/export/Export?id=1lZjcJIf3C*****fTRnRw7wSUjbRurFL_tlO8A&exportFormat=pdf"
},
"userPermission": {
"kind": "drive#permission",
"etag": "\"3NNCnvnQuji-pODa6SMQ6atlc3M/6LfqbkrWujmUe1WSDkyhTxdIUCc\"",
"id": "me",
"selfLink": "https://www.googleapis.com/drive/v2/files/1lZjcJIf3Chuu5upFqtiqfTRnRw7wSUjbRurFL_tlO8A/permissions/me",
"role": "owner",
"type": "user"
},
"quotaBytesUsed": "0",
"ownerNames": [
"***** *****"
],
"lastModifyingUserName": "***** *****",
"editable": true,
"writersCanShare": true,
"appDataContents": false
},
कृपया संबंधित JSON प्रतिक्रिया के साथ एक नमूना अनुरोध जोड़ें जो दिखाता है कि अंतिम संशोधित मान परिवर्तित नहीं हुआ है। –
हाय क्लाउडियो, मैंने अभी नमूना प्रतिक्रिया JSON संलग्न किया है। – asir6
यदि आप अद्यतन अनुरोध भेजते समय संशोधितडेट फ़ील्ड सेट करना चाहते हैं, तो आपको अपने अनुरोध पैरामीटर में setModifiedDate = true भी सेट करना होगा: https://developers.google.com/drive/v2/reference/files/update –