xuzhiheng 4 سال پیش
والد
کامیت
89c36e2a6c
1فایلهای تغییر یافته به همراه5 افزوده شده و 1 حذف شده
  1. 5 1
      services/stdlib/docGet.go

+ 5 - 1
services/stdlib/docGet.go

@@ -24,6 +24,10 @@ func DocGetCheck(docId, userId, appId string) stdlib.DocGetCheckResp {
 		// docPrice = docData["price"].(int)
 		docStatistics := model.DocStatistics{}
 		jyDocsRpcUtil.GetJyDocsDB().First(&docStatistics, &model.DocStatistics{AppId: appId, DocId: docId})
+		ossPdfId := ""
+		if isbuy {
+			ossPdfId = doc.OssPdfId
+		}
 		docCheck := stdlib.DocGetCheckResp{
 			Code:  1,
 			Msg:   "ok",
@@ -41,7 +45,7 @@ func DocGetCheck(docId, userId, appId string) stdlib.DocGetCheckResp {
 				DocSummary:   doc.DocSummary,
 				DocFileType:  int64(doc.DocFileType),
 				PreviewImgId: doc.PreviewImgId,
-				OssPdfId:     doc.OssPdfId,
+				OssPdfId:     ossPdfId,
 			},
 		}
 		return docCheck