|
3 | 3 |
|
4 | 4 | {% comment %} |
5 | 5 | <!-- |
6 | | - Copyright (C) 2011 University of Dundee & Open Microscopy Environment. |
| 6 | + Copyright (C) 2011-2021 University of Dundee & Open Microscopy Environment. |
7 | 7 | All rights reserved. |
8 | 8 | This program is free software: you can redistribute it and/or modify |
9 | 9 | it under the terms of the GNU Affero General Public License as |
|
25 | 25 | if (typeof OME === "undefined") { OME={}; } |
26 | 26 |
|
27 | 27 | OME.createShare = function() { |
28 | | - |
29 | | - var productListQuery = []; |
30 | | - |
31 | | - // we do inst.get_selected() here, since we then get objects |
32 | | - // instead of ids for some reason? |
33 | | - var inst = $.jstree.reference('#dataTree'); |
34 | | - data = inst.get_selected(true); |
35 | | - data.forEach(function(node){ |
36 | | - productListQuery.push(node.type + "=" + node.data.id); |
37 | | - }); |
38 | | - |
39 | | - var query = '{% url 'manage_action_containers' "add" "share" %}' + "?"+productListQuery.join("&"); |
40 | 28 | $("#create_share_form").dialog("open"); |
41 | | - $("#create_share_form").attr("action", query) |
42 | | - $("#create_share_form").load(query); |
43 | 29 | return false; |
44 | 30 | } |
45 | 31 |
|
46 | 32 | $(document).ready(function(){ |
47 | 33 |
|
48 | | - // AJAX handling of create-discussion form |
49 | | - $("#create_share_form").ajaxForm({ |
50 | | - success: function(html) { |
51 | | - if (html.indexOf("shareId") > -1) { |
52 | | - var shareId = html.replace("shareId:", ""); |
53 | | - $("#create_share_form").dialog( "close" ); |
54 | | - $("#shareCreatedId").text(shareId); |
55 | | - $("#share_dialog_form").dialog("open").show(); |
56 | | - } else { |
57 | | - $("#create_share_form").html(html); |
58 | | - } |
59 | | - }, |
60 | | - }); |
61 | | - |
62 | | - $("#share_dialog_form").dialog({ |
63 | | - autoOpen: false, |
64 | | - resizable: true, |
65 | | - height: 150, |
66 | | - width:300, |
67 | | - modal: true, |
68 | | - buttons: { |
69 | | - "OK": function() { |
70 | | - $( this ).dialog( "close" ); |
71 | | - } |
72 | | - } |
73 | | - }); |
74 | | - |
75 | 34 | $("#create_share_form").dialog({ |
| 35 | + title: "Shares not supported", |
76 | 36 | autoOpen: false, |
77 | 37 | resizable: true, |
78 | | - height: 600, |
| 38 | + height: 250, |
79 | 39 | width:450, |
80 | 40 | modal: true, |
81 | 41 | buttons: { |
82 | | - "Accept": function() { |
83 | | - // simply submit the form |
84 | | - $("#create_share_form").submit(); |
85 | | - }, |
86 | | - "Cancel": function() { |
| 42 | + "OK": function() { |
87 | 43 | $( this ).dialog( "close" ); |
88 | 44 | } |
89 | 45 | } |
90 | 46 | }); |
91 | | - |
92 | | - |
93 | 47 | }); |
94 | 48 | </script> |
95 | 49 |
|
96 | 50 |
|
97 | | - |
98 | | -<!-- hidden form for creating share - shown in dialog & loaded by AJAX --> |
99 | | -<form id="create_share_form" action="#" method="post" title="Create Share" class="standard_form">{% csrf_token %} |
100 | | -</form> |
101 | | - |
102 | | -<form id="share_dialog_form" action="#" title="Create Share" style="display:none"> |
103 | | - <p style="font-size: 120%; font-weight: bold"> |
104 | | - Share <span id="shareCreatedId"></span> was created successfully. |
| 51 | +<!-- hidden dialog --> |
| 52 | +<div id="create_share_form" style="display:none"> |
| 53 | + <p>Share functionality is no longer supported.</p> |
| 54 | + <p>Please see <a target="_blank" href="https://www.openmicroscopy.org/omero/features/share/">Sharing your data in OMERO</a> |
| 55 | + for alternative workflows. |
105 | 56 | </p> |
106 | | -</form> |
| 57 | +</div> |
0 commit comments