@@ 285-292 (lines=8) @@ | ||
282 | * @param Node $node |
|
283 | * @return Wopi |
|
284 | */ |
|
285 | public function getRemoteToken(Node $node) { |
|
286 | list($urlSrc, $token, $wopi) = $this->getToken($node->getId(), null, null, false, true); |
|
287 | $wopi->setIsRemoteToken(true); |
|
288 | $wopi->setRemoteServer($node->getStorage()->getRemote()); |
|
289 | ||
290 | $this->wopiMapper->update($wopi); |
|
291 | return $wopi; |
|
292 | } |
|
293 | ||
294 | /** |
|
295 | * @param Node $node |
|
@@ 298-305 (lines=8) @@ | ||
295 | * @param Node $node |
|
296 | * @return Wopi |
|
297 | */ |
|
298 | public function getRemoteTokenFromDirect(Node $node, $editorUid) { |
|
299 | list($urlSrc, $token, $wopi) = $this->getToken($node->getId(), null, $editorUid, true, true); |
|
300 | $wopi->setIsRemoteToken(true); |
|
301 | $wopi->setRemoteServer($node->getStorage()->getRemote()); |
|
302 | ||
303 | $this->wopiMapper->update($wopi); |
|
304 | return $wopi; |
|
305 | } |
|
306 | ||
307 | ||
308 | } |