This repository has been archived by the owner on Nov 25, 2020. It is now read-only.
/
manifest.xml
556 lines (556 loc) · 48.3 KB
/
manifest.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
<?xml version="1.0" encoding="UTF-8"?>
<ajxp_plugin name="share" label="CONF_MESSAGE[Sharing Features]" description="CONF_MESSAGE[Share Center actions and hooks]" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="file:../core.ajaxplorer/ajxp_registry.xsd">
<server_settings>
<global_param name="FORK_EVENT_FORWARDING" type="boolean" label="Fork Events Forwarding" description="If you detect performances issues while modifiyng files under deep trees, try activating that one. Please be sure of what you do, this may trigger a whole lot of php processes on the server." default="false"/>
<global_param name="ENABLE_FILE_PUBLIC_LINK" group="CONF_MESSAGE[Link Generation]" description="CONF_MESSAGE[Enable public link generation for files]" label="CONF_MESSAGE[Enable public links for files]" type="boolean" default="true" expose="true"/>
<global_param name="USE_REWRITE_RULE" group="CONF_MESSAGE[Link Generation]" description="CONF_MESSAGE[Use web server RewriteEngine mechanism to generate prettier URLs]" label="CONF_MESSAGE[Use Rewrite Rule]" type="boolean" default="false"/>
<global_param name="HASH_MIN_LENGTH" group="CONF_MESSAGE[Link Generation]" description="CONF_MESSAGE[Minimum length of the generated hash]" label="CONF_MESSAGE[Hash minimum length]" type="integer" default="6"/>
<global_param name="HASH_USER_EDITABLE" group="CONF_MESSAGE[Link Generation]" description="CONF_MESSAGE[Allow users to manually choose a hash for the generated links]" label="CONF_MESSAGE[Hash user-editable]" type="boolean" default="false" expose="true"/>
<global_param name="FILE_MAX_EXPIRATION" group="CONF_MESSAGE[Link Generation]" description="CONF_MESSAGE[Maximum share expiration limit for file, 0 = unlimited]" label="CONF_MESSAGE[Maximum file expiration limit]" type="integer" default="0" expose="true"/>
<global_param name="FILE_MAX_DOWNLOAD" group="CONF_MESSAGE[Link Generation]" description="CONF_MESSAGE[Maximum download limit for file, 0 = unlimited]" label="CONF_MESSAGE[Maximum file download limit]" type="integer" default="0" expose="true"/>
<global_param name="EMAIL_INVITE_EXTERNAL" group="CONF_MESSAGE[Link Generation]" description="CONF_MESSAGE[Use external mailer for invitations]" label="CONF_MESSAGE[Force External Mailer]" type="boolean" default="false" expose="true"/>
<global_param name="CREATE_QRCODE" group="CONF_MESSAGE[Link Generation]" description="CONF_MESSAGE[Create and display QRCode for shared link]" label="CONF_MESSAGE[Create QRCode]" type="boolean" default="false" expose="true"/>
<global_param name="ENABLE_FOLDER_SHARING" group="CONF_MESSAGE[Folder Sharing]" description="CONF_MESSAGE[Enable folder sharing (workspace and minisite)]" label="CONF_MESSAGE[Enable folder sharing]" type="select" choices="both|Minisites and Workspaces,minisite|Minisites only,workspace|Workspaces only,disable|Disable Folder Sharing" mandatory="true" default="both" expose="true"/>
<global_param name="AVOID_SHARED_FOLDER_SAME_LABEL" group="CONF_MESSAGE[Folder Sharing]" description="CONF_MESSAGE[Disallow users to create shared folders if a workspace already exists with the same label]" label="CONF_MESSAGE[Avoid labels duplication]" type="boolean" default="false"/>
<global_param name="SHARED_USERS_TMP_PREFIX" group="CONF_MESSAGE[Shared users configurations]" description="CONF_MESSAGE[Mandatory prefix for users created temporary users login]" label="CONF_MESSAGE[Tmp users prefix]" type="string" expose="true"/>
<global_param name="CUSTOM_SHAREPAGE_TITLE" group="CONF_MESSAGE[Weblink Page]" type="string" label="CONF_MESSAGE[Page Title]" description="CONF_MESSAGE[Share page title. Use AJXP_FILENAME keyword to display the file name.]" mandatory="false" default=""/>
<global_param name="CUSTOM_SHAREPAGE_LEGEND" group="CONF_MESSAGE[Weblink Page]" type="string" label="CONF_MESSAGE[Download text]" description="CONF_MESSAGE[Text displayed below the download button. Use AJXP_FILENAME keyword to display the file name, and PYDIO_APP_TITLE for the application title.]" mandatory="false" default=""/>
<global_param name="CUSTOM_SHAREPAGE_LEGEND_PASS" group="CONF_MESSAGE[Weblink Page]" type="string" label="CONF_MESSAGE[Download text w/ Pass]" description="CONF_MESSAGE[Text displayed below the download button when a password is mandatory. Use AJXP_FILENAME keyword to display the file name, and PYDIO_APP_TITLE for the application title.]" mandatory="false" default=""/>
<global_param name="CUSTOM_SHAREPAGE_BUTTON" group="CONF_MESSAGE[Weblink Page]" type="image" label="CONF_MESSAGE[Download Button]" description="CONF_MESSAGE[Image used as a button for downloading the file]" mandatory="false"
editable="true"
uploadAction="store_binary_temp"
loadAction="get_global_binary_param"
defaultImage="plugins/action.share/res/dl.png"
expose="true"
/>
<global_param name="CUSTOM_SHAREPAGE_BACKGROUND_COLOR" group="CONF_MESSAGE[Weblink Page]" type="string" label="CONF_MESSAGE[Background Color]" description="CONF_MESSAGE[Share page background color.]" mandatory="false" default="#FFFFFF"/>
<global_param name="CUSTOM_SHAREPAGE_TEXT_COLOR" group="CONF_MESSAGE[Weblink Page]" type="string" label="CONF_MESSAGE[Text Color]" description="CONF_MESSAGE[Share page text color.]" mandatory="false" default="#399c9b"/>
<global_param name="CUSTOM_SHAREPAGE_TEXTSHADOW_COLOR" group="CONF_MESSAGE[Weblink Page]" type="string" label="CONF_MESSAGE[Text Shadow]" description="CONF_MESSAGE[Share page text shadow color.]" mandatory="false" default="#FFFFFF"/>
<global_param name="CUSTOM_SHAREPAGE_BACKGROUND_1" group="CONF_MESSAGE[Page Background Images]" type="image" label="CONF_MESSAGE[Custom Background (1)]" description="CONF_MESSAGE[Image used as a background]" mandatory="false"
editable="true"
uploadAction="store_binary_temp"
loadAction="get_global_binary_param"
defaultImage="plugins/action.share/res/hi-res/PARIS.jpg"
expose="true"
/>
<global_param name="CUSTOM_SHAREPAGE_BACKGROUND_ATTRIBUTES_1" group="CONF_MESSAGE[Page Background Images]" type="select"
choices="background-repeat:no-repeat;background-position:50% 50%;|Center in Page (no-repeat),background-repeat:repeat;background-size:100%;background-position:50% 50%;|Fetch Window (repeat vertically),background-repeat:no-repeat;background-size:100%; background-position:center center;|Fetch Window (no repeat),background-repeat:repeat;|Tile (repeat both directions)"
label="CONF_MESSAGE[Background Attributes(1)]" description="CONF_MESSAGE[Image used as a background]"
mandatory="false" expose="true" default="background-repeat:repeat;background-size:100%;background-position:50% 50%;"/>
<global_param name="CUSTOM_SHAREPAGE_BACKGROUND_2" group="CONF_MESSAGE[Page Background Images]" type="image" label="CONF_MESSAGE[Custom Background (2)]" description="CONF_MESSAGE[Image used as a background]" mandatory="false"
editable="true"
uploadAction="store_binary_temp"
loadAction="get_global_binary_param"
defaultImage="plugins/action.share/res/hi-res/NORMANDY.jpg"
expose="true"
/>
<global_param name="CUSTOM_SHAREPAGE_BACKGROUND_ATTRIBUTES_2" group="CONF_MESSAGE[Page Background Images]" type="select"
choices="background-repeat:no-repeat;background-position:50% 50%;|Center in Page (no-repeat),background-repeat:repeat;background-size:100%;background-position:50% 50%;|Fetch Window (repeat vertically),background-repeat:no-repeat;background-size:100%; background-position:center center;|Fetch Window (no repeat),background-repeat:repeat;|Tile (repeat both directions)"
label="CONF_MESSAGE[Background Attributes(2)]" description="CONF_MESSAGE[Image used as a background]" mandatory="false" expose="true" default="background-repeat:repeat;background-size:100%;background-position:50% 50%;"/>
<global_param name="CUSTOM_SHAREPAGE_BACKGROUND_3" group="CONF_MESSAGE[Page Background Images]" type="image" label="CONF_MESSAGE[Custom Background (3)]" description="CONF_MESSAGE[Image used as a background]" mandatory="false"
editable="true"
uploadAction="store_binary_temp"
loadAction="get_global_binary_param"
defaultImage="plugins/action.share/res/hi-res/CRETE.jpg"
expose="true"
/>
<global_param name="CUSTOM_SHAREPAGE_BACKGROUND_ATTRIBUTES_3" group="CONF_MESSAGE[Page Background Images]" type="select"
choices="background-repeat:no-repeat;background-position:50% 50%;|Center in Page (no-repeat),background-repeat:repeat;background-size:100%;background-position:50% 50%;|Fetch Window (repeat vertically),background-repeat:no-repeat;background-size:100%; background-position:center center;|Fetch Window (no repeat),background-repeat:repeat;|Tile (repeat both directions)"
label="CONF_MESSAGE[Background Attributes(3)]" description="CONF_MESSAGE[Image used as a background]" mandatory="false" expose="true" default="background-repeat:repeat;background-size:100%;background-position:50% 50%;"/>
<global_param name="CUSTOM_MINISITE_LOGO" group="CONF_MESSAGE[Minisite]" type="image" label="CONF_MESSAGE[Minisite Logo]" description="CONF_MESSAGE[Top-right logo displayed on minisite page]" mandatory="false"
editable="true"
uploadAction="store_binary_temp"
loadAction="get_global_binary_param"
defaultImage="plugins/gui.ajax/PydioLogo250.png"
expose="true"
/>
</server_settings>
<client_settings>
<resources>
<i18n namespace="share_center" path="plugins/action.share/res/i18n"/>
<js file="plugins/action.share/qrcode.js" className="QRCode" autoload="true"/>
<js file="plugins/action.share/class.ShareCenter.js" className="ShareCenter" autoload="true"/>
</resources>
</client_settings>
<registry_contributions>
<actions>
<action name="share">
<gui text="292" title="292" src="share.png" iconClass="icon-share" hasAccessKey="false">
<context selection="true" dir="" recycle="hidden" actionBar="false" contextMenu="false" infoPanel="false"/>
<selectionContext dir="false" evalMetadata="!metadata.get('ajxp_mime') || !metadata.get('ajxp_mime').startsWith('shared_')" file="true" recycle="false" unique="false"/>
</gui>
<rightsContext noUser="true" userLogged="only" read="true" write="false" adminOnly=""/>
<processing>
<clientCallback prepareModal="true"><![CDATA[
if(!ajaxplorer.actionBar.shareCenter) ajaxplorer.actionBar.shareCenter = new ShareCenter();
ajaxplorer.actionBar.shareCenter.performShareAction();
]]></clientCallback>
<clientForm id="share_form"><![CDATA[
<div id="share_form" box_width="420" action="share">
<div class="dialogContentMainTitle" ajxp_message_id="share_center.161">AJXP_MESSAGE[share_center.161]</div>
<div class="dialogContentLegend" ajxp_message_id="share_center.162">AJXP_MESSAGE[share_center.162]</div>
<div style="display:none;position:relative;margin-bottom:20px;clear:left; padding-top: 20px;" id="share_result">
<div class="dialogContentMainTitle" ajxp_message_id="share_center.93">AJXP_MESSAGE[share_center.93]</div>
<div class="SF_horizontal_fieldsRow" style="display:none; margin-bottom:7px;">
<div id="handle_existing_links" class="SF_horizontal_actions SF_horizontal_pastilles"></div>
<div style="clear:left;">
<input type="text" placeholder="AJXP_MESSAGE[share_center.90]" name="link_url" id="share_container" class="SF_input SF_number" style="width:230px !important;">
<input type="text" placeholder="AJXP_MESSAGE[share_center.91]" name="link_tag" value="" class="SF_input SF_number" style="width:113px !important;">
</div>
<div id="handle_existing_links" class="SF_horizontal_actions">
<span data-action="remove" class="SF_horizontal_action icon-minus-sign SF_horizontal_action_destructive"></span>
</div>
<div class="share_qrcode" style="display:none;"></div>
<div style="clear:both"></div>
</div>
<div id="generate_indicator" style="position:absolute;top:35px;right:12px;display:none;"><img src="AJXP_THEME_FOLDER/images/autocompleter-loader.gif"></div>
</div>
</div>
<div id="share_folder_chooser" box_width="360">
<div class="dialogContentMainTitle" ajxp_message_id="share_center.28">AJXP_MESSAGE[share_center.28]</div>
<ul class="share_chooser_list">
<li data-shareListValue="workspace">
<div class="shareChooserTitle" ajxp_message_id="share_center.63">AJXP_MESSAGE[share_center.63]</div>
<div class="dialogLegend" ajxp_message_id="share_center.64">AJXP_MESSAGE[share_center.64]</div>
</li>
<li data-shareListValue="minisite_public">
<div class="shareChooserTitle" ajxp_message_id="share_center.65">AJXP_MESSAGE[share_center.65]</div>
<div class="dialogLegend" ajxp_message_id="share_center.66">AJXP_MESSAGE[share_center.66]</div>
</li>
<li data-shareListValue="minisite_private">
<div class="shareChooserTitle" ajxp_message_id="share_center.67">AJXP_MESSAGE[share_center.67]</div>
<div class="dialogLegend" ajxp_message_id="share_center.68">AJXP_MESSAGE[share_center.68]</div>
</li>
</ul>
</div>
<div id="share_folder_form" action="share">
<div id="share-folder-type-chooser" class="mode-minipub mode-ws no_share_leaf">
<input type="radio" name="share-type" id="share-type-minisite" checked> <label for="share-type-minisite">AJXP_MESSAGE[share_center.133]</label><br>
<input type="radio" name="share-type" id="share-type-workspace"> <label for="share-type-workspace">AJXP_MESSAGE[share_center.134]</label>
<div class="dialogLegend mode-minipub">AJXP_MESSAGE[share_center.135]</div>
<div class="dialogLegend mode-ws">AJXP_MESSAGE[share_center.136]</div>
</div>
<div id="share-folder-type-leaf" class="mode-minipub dialogLegend only_share_leaf">AJXP_MESSAGE[share_center.137]</div>
<div id="target_repository_toggle" class="dialogLegend">
<span class="mode-minipub no_share_leaf">AJXP_MESSAGE[share_center.138]</span>
<span class="mode-ws no_share_leaf">AJXP_MESSAGE[share_center.139]</span>
<span class="mode-minipub only_share_leaf">AJXP_MESSAGE[share_center.140]</span>
<a><span class="params_view">AJXP_MESSAGE[share_center.141]</span><span class="params_hide">AJXP_MESSAGE[share_center.142]</span></a>
<div class="SF_horizontal_actions SF_horizontal_pastilles"></div>
</div>
<div style="display:none;position:relative;margin:10px;min-height:85px;" id="share_result" class="">
<div class="dialogContentMainTitle" style="margin-bottom: 5px;" ajxp_message_id="share_center.29">AJXP_MESSAGE[share_center.29]</div>
<div id="generate_indicator" style="position:absolute;top:2px;right:4px;display:none;"><img src="AJXP_THEME_FOLDER/images/autocompleter-loader.gif"></div>
<div class="SF_horizontal_fieldsRow">
<input type="text" id="share_container" style="clear:left; width: 95%; margin:15px 5px 0; font-size:13px;"/>
<div class="non_macos">AJXP_MESSAGE[share_center.143]</div>
<div class="macos_only" style="display:none;">AJXP_MESSAGE[share_center.144]</div>
<div class="share_qrcode" style="margin-top:5px; clear:left; display:none;"></div>
</div>
</div>
<div id="target_repository" style="margin-bottom:15px;">
<div id="public_link_parameters" style="margin:0 5px;min-height: 20px;">
<!-- LABEL & DESCRIPTION -->
<div class="SF_element">
<div class="SF_label" ajxp_message_id="share_center.35" title="AJXP_MESSAGE[share_center.35]">AJXP_MESSAGE[share_center.35]</div>
<input type="text" value="" id="repo_label" name="repo_label" class="SF_input" placeholder="AJXP_MESSAGE[share_center.35]"/>
</div>
<div class="SF_element">
<div class="SF_label" title="">AJXP_MESSAGE[share_center.145]</div>
<input type="text" id="repo_description" name="repo_description" class="SF_input" placeholder="AJXP_MESSAGE[share_center.146]"/>
<br style="clear:both;">
</div>
<div class="mode-minipub">
<div id="target_user_simple" class="mode-minipub" style="margin:0 5px;"></div>
<!-- EDITABLE HASH -->
<div id="editable_hash_container">
<div class="dialogContentMainTitle">Link</div>
<div id="editable_hash_link" style="margin:10px;font-size:13px;"><input type="text" name="minisite_hash_update" value="" style="width: 90px;padding: 0 2px;margin: 0 1px;"></div>
</div>
<!-- SECURITY -->
<div class="dialogContentMainTitle">AJXP_MESSAGE[share_center.147]</div>
<div class="SF_element">
<div class="SF_label" ajxp_message_id="share_center.23" style="width:130px;" title="AJXP_MESSAGE[share_center.23]">AJXP_MESSAGE[share_center.23]</div>
<input type="text" name="guest_user_pass" value="" placeholder="AJXP_MESSAGE[share_center.148]" autocomplete="off" class="SF_input" style="width:40% !important;">
<div class="SF_horizontal_labelRow">
<div class="SF_label" ajxp_message_id="share_center.21" style="width:40% !important;" title="AJXP_MESSAGE[share_center.21]">AJXP_MESSAGE[share_center.21]</div>
<div class="SF_label" ajxp_message_id="share_center.22" style="width:40% !important;" title="AJXP_MESSAGE[share_center.22]">AJXP_MESSAGE[share_center.22]</div>
</div>
<div class="SF_horizontal_fieldsRow">
<input type="text" name="expiration" value="0" placeholder="AJXP_MESSAGE[share_center.149]" class="SF_input SF_number" style="width:40% !important;">
<input type="text" name="downloadlimit" value="0" placeholder="AJXP_MESSAGE[share_center.149]" class="SF_input SF_number" style="width:40% !important;">
</div>
<br style="clear: left;"/>
<div class="SF_label" style="padding: 5px 0px 0px 2px;">AJXP_MESSAGE[share_center.150]</div>
<div class="SF_element share-accesscontrol-container" style="padding:2px 5px;">
<input type="checkbox" style="clear:none;" id="simple_right_read" name="simple_right_read" checked="true" class=""> <label class="" for="simple_right_read"> AJXP_MESSAGE[share_center.72]</label>
<input type="checkbox" style="clear:none;" id="simple_right_download" name="simple_right_download" checked="true" class=""> <label class="" for="simple_right_download"> AJXP_MESSAGE[share_center.73]</label>
<input type="checkbox" style="clear:none;" id="simple_right_write" name="simple_right_write" class=""> <label class="" for="simple_right_write"> AJXP_MESSAGE[share_center.74]</label>
</div>
</div>
<!-- LAYOUT -->
<div class="dialogContentMainTitle no_share_leaf">AJXP_MESSAGE[share_center.151]</div>
<div class="no_share_leaf" style="padding-top:8px;">
<div class="layout_template_container SF_element"></div>
</div>
<br style="clear: left;"/>
<div class="SF_element" id="public_pass_container" style="display:none;height:20px;"></div>
</div>
</div>
<div id="share_update">
<div class="largeButton">AJXP_MESSAGE[share_center.152]</div>
</div>
</div>
<div id="target_user" style="margin:0 12px;position:relative;display:none;" class="mode-ws mode-minipriv">
<div class="dialogContentMainTitle mode-ws" ajxp_message_id="share_center.30" style="display:none;">AJXP_MESSAGE[share_center.30]</div>
<div style="clear: both; margin-top:20px;" class="mode-minipriv"> </div>
<div class="editable_users_header">
<span id="header_read" ajxp_message_id="share_center.31">AJXP_MESSAGE[share_center.31]</span>
<span id="header_write" ajxp_message_id="share_center.32">AJXP_MESSAGE[share_center.32]</span>
<span id="header_watch" ajxp_message_id="share_center.33">AJXP_MESSAGE[share_center.33]</span>
</div>
<input type="text" class="dialogFocus" value="" style="width:98%;" placeholder="AJXP_MESSAGE[share_center.34]" id="shared_user"/>
<div id="complete_indicator" style="position:absolute;top:25px;right:4px;display:none;"><img src="AJXP_THEME_FOLDER/images/autocompleter-loader.gif"></div>
<div id="shared_users_autocomplete_choices" class="autocomplete" style="margin-top:0px !important;z-index:20000 !important;"></div>
<div class="editable_users_list grey_gradient_light_inputs" id="shared_users_summary" style="margin-bottom:7px;"></div>
</div>
<div id="share_generate" class="mode-minipub mode-minipriv" style="display:none;">
<div align="center" style="margin: 15px 0 0;text-align:center;">
<div align="center" id="generate_publiclet" class="largeButton" style="margin-bottom:15px;"><span class="icon-retweet" style="font-size:14px;"></span> <img style="display:none;" id="generate_image" src="AJXP_THEME_FOLDER/images/actions/16/share.png" height="16" width="16"/><span>AJXP_MESSAGE[308]</span></div>
</div>
<br style="clear:both;"/>
</div>
<div id="shareDialogButtons" style="display:none;"></div>
<br style="clear:both;"/>
</div>
<style type="text/css">
.share_chooser_list {
margin: 0;
padding: 0;
}
.share_chooser_list li {
list-style: none;
margin: 0;
padding: 5px 10px;
cursor: pointer;
border-radius: 3px;
border: 1px solid #cccccc;
margin: 7px 0;
box-shadow: inset 1px 1px 1px white;
}
.shareChooserTitle {
font-size: 14px;
margin-bottom: 5px;
}
.share_chooser_list li.selected {
border: 1px solid rgb(117, 128, 139);
background-color: rgba(226, 238, 255, 0.46) !important;
box-shadow: inset 1px 1px 1px rgba(0, 0, 0, 0.16);
}
.share_qrcode {
margin: 43px auto 10px;
width: 130px;
padding: 10px;
background-color: white;
box-shadow: 2px 2px 3px rgba(0, 0, 0, 0.42);
border-radius: 4px;
}
#generate_publiclet, #unshare_button{
float: none;
width: 41%;
margin: 0 auto;
}
</style>
]]>
</clientForm>
<clientListener name="init"><![CDATA[
if(ajaxplorer.user && !ajaxplorer.user.canWrite() || ajaxplorer.getPluginConfigs("action.share").get("ENABLE_FOLDER_SHARING") == "disable" ){
var action = ajaxplorer.getActionBar().getActionByName('share');
if(action) action.selectionContext.dir = false;
}
]]></clientListener>
<serverCallback methodName="switchAction" developerComment="Main action for sharing a file or a folder">
<input_param description="Path of the resource to share" name="file" type="path" mandatory="true"/>
<input_param description="Specific type of sharing" name="sub_action" type="delegate_repo|create_minisite|public_link" mandatory="true"/>
<input_param description="For editing the data of an existing workspace/minisite" name="repository_id" type="string" mandatory="false"/>
<input_param description="For a workspace, directly set a watch on this for the current user" name="self_watch_folder" type="boolean"/>
<input_param description="For a minisite, will determine whether it will be public (true) or private (false), creating a temporary user in the first case." name="create_guest_user" type="boolean"/>
<input_param description="For a workspace/private minisite, define zero or more ACL for users" name="user_[n]" type="string"/>
<input_param description="For a workspace/private minisite, read right for user N" name="right_read_[n]" type="boolean"/>
<input_param description="For a workspace/private minisite, write right for user N" name="right_write_[n]" type="boolean"/>
<input_param description="For a workspace/private minisite, watch status for user N" name="right_watch_[n]" type="boolean"/>
<input_param description="For a public link, set a maximum number of downloads authorized" name="downloadlimit" type="integer"/>
<input_param description="For a public link, set a maximum number of authorized days" name="expiration" type="integer"/>
<input_param description="For a public link, set a password" name="password" type="string"/>
<input_param description="Additional plugins data that can be stored in the shared resource" name="PLUGINS_DATA" type="FORM_DATA"/>
</serverCallback>
</processing>
</action>
<action name="share-edit-shared">
<gui src="share.png" iconClass="icon-share" text="share_center.125" title="share_center.126">
<context dir="true" recycle="hidden" selection="true" actionBar="true" actionBarGroup="get,share_list_toolbar,info_panel_share" behaviour="hidden"/>
<selectionContext dir="true" file="true" evalMetadata="metadata.get('ajxp_shared')" recycle="false" unique="true" behaviour="hidden"/>
</gui>
<processing>
<clientCallback prepareModal="true"><![CDATA[
if(!ajaxplorer.actionBar.shareCenter) ajaxplorer.actionBar.shareCenter = new ShareCenter();
ajaxplorer.actionBar.shareCenter.performShareAction();
]]></clientCallback>
</processing>
</action>
<action name="share-folder-workspace">
<gui src="share.png" iconClass="icon-share" text="share_center.113" title="share_center.114">
<context dir="true" recycle="hidden" selection="true"/>
<selectionContext dir="true" file="false" evalMetadata="!metadata.get('ajxp_shared')" recycle="false" unique="true"/>
</gui>
<processing>
<clientCallback prepareModal="true"><![CDATA[
if(!ajaxplorer.actionBar.shareCenter) ajaxplorer.actionBar.shareCenter = new ShareCenter();
ajaxplorer.actionBar.shareCenter.performShare('workspace');
]]></clientCallback>
</processing>
</action>
<action name="share-file-minisite">
<gui src="share.png" iconClass="icon-share" text="292" title="292">
<context dir="true" recycle="hidden" selection="true" actionBar="true" actionBarGroup="get,info_panel_share" />
<selectionContext dir="false" file="true" recycle="false" unique="true" evalMetadata="!metadata.get('ajxp_shared')" />
</gui>
<processing>
<clientCallback prepareModal="true"><![CDATA[
if(!ajaxplorer.actionBar.shareCenter) ajaxplorer.actionBar.shareCenter = new ShareCenter();
ajaxplorer.actionBar.shareCenter.performShare('minisite-public');
]]></clientCallback>
</processing>
</action>
<action name="share-selection-minisite">
<gui src="share.png" iconClass="icon-share" text="share_center.123" title="share_center.124">
<context dir="true" recycle="false" selection="true"/>
<selectionContext dir="false" file="true" multipleOnly="true" recycle="false" unique="false"/>
</gui>
<processing>
<clientCallback prepareModal="true"><![CDATA[
if(!ajaxplorer.actionBar.shareCenter) ajaxplorer.actionBar.shareCenter = new ShareCenter();
ajaxplorer.actionBar.shareCenter.performShare('minisite-public');
]]></clientCallback>
</processing>
</action>
<action name="share-folder-minisite-public">
<gui src="share.png" iconClass="icon-share" text="292" title="292">
<context dir="true" recycle="hidden" selection="true" actionBar="true" actionBarGroup="get,info_panel_share"/>
<selectionContext dir="true" file="false" recycle="false" unique="true" evalMetadata="!metadata.get('ajxp_shared')" />
</gui>
<processing>
<clientCallback prepareModal="true"><![CDATA[
if(!ajaxplorer.actionBar.shareCenter) ajaxplorer.actionBar.shareCenter = new ShareCenter();
ajaxplorer.actionBar.shareCenter.performShare('minisite-public');
]]></clientCallback>
</processing>
</action>
<action name="load_shared_element_data">
<processing>
<serverCallback methodName="switchAction" developerComment="Loads all current sharing data for a given resource. Workspace must support metadata management (metastore).">
<input_param description="Path of the resource to share" name="file" type="path" mandatory="true"/>
<input_param description="Type of element to load (file or folder)" name="element_type" type="file|repository" mandatory="true"/>
<output type="application/json"/>
</serverCallback>
</processing>
</action>
<action name="unshare">
<processing>
<serverCallback methodName="switchAction" developerComment="Stop sharing a folder, or remove a public link from a file.">
<input_param description="Path of the resource to unshare" name="file" type="path" mandatory="true"/>
<input_param description="Type of element to load (file or folder)" name="element_type" type="file|repository" mandatory="true"/>
<input_param description="If the resource is a file, send also the element_id, as many links can be generated for one file" name="element_id" type="string"/>
</serverCallback>
</processing>
</action>
<action name="toggle_link_watch">
<processing>
<serverCallback methodName="switchAction" developerComment="Toggle a shared element status for being watched or not.">
<input_param description="Path of the resource to unshare" name="file" type="path" mandatory="true"/>
<input_param description="Type of element to load (file or folder)" name="element_type" type="file|repository" mandatory="true"/>
<input_param description="If the resource is a file, send also the element_id, as many links can be generated for one file" name="element_id" type="string"/>
</serverCallback>
</processing>
</action>
<action name="reset_counter">
<processing>
<serverCallback methodName="switchAction" developerComment="Reset download counter for a given link generated on a file.">
<input_param description="Path of the resource to unshare" name="file" type="path" mandatory="true"/>
<input_param description="Send also the element_id, as many links can be generated for one file" name="element_id" type="string"/>
</serverCallback>
</processing>
</action>
<action name="update_shared_element_data">
<processing>
<serverCallback methodName="switchAction">
<input_param description="Path of the resource to unshare" name="file" type="path" mandatory="true"/>
<input_param description="Send also the element_id, as many links can be generated for one file" name="element_id" type="string"/>
<input_param description="Name of the property to modify (only tags supported)" name="p_name" type="string" mandatory="true" default="tags"/>
<input_param description="Value of the property to modify" name="p_value" type="string" mandatory="true"/>
</serverCallback>
</processing>
</action>
<action name="forward_change_event">
<processing>
<serverCallback methodName="forwardEventToSharesAction"/>
</processing>
</action>
<action name="sharelist-edit">
<gui src="share.png" iconClass="icon-share" text="share_center.125" title="share_center.126">
<context dir="true" recycle="false" selection="true" actionBar="true" actionBarGroup="share_list_toolbar-selection" behaviour="hidden"/>
<selectionContext dir="true" file="true" evalMetadata="metadata.get('ajxp_shared')" recycle="false" unique="true" behaviour="hidden"/>
</gui>
<processing>
<clientCallback prepareModal="true"><![CDATA[
if(!ajaxplorer.actionBar.shareCenter) ajaxplorer.actionBar.shareCenter = new ShareCenter();
if(window.actionManager){
ajaxplorer.actionBar.shareCenter.performShareAction(window.actionManager.getDataModel());
}
]]></clientCallback>
</processing>
</action>
<action name="sharelist-load">
<gui src="share.png" iconClass="icon-refresh" text="149" title="149">
<context dir="true" recycle="false" selection="false" actionBar="true" actionBarGroup="share_list_toolbar" behaviour="hidden"/>
</gui>
<processing>
<clientCallback prepareModal="true"><![CDATA[
if(window.actionManager){
window.actionManager.getDataModel().requireContextChange(window.actionManager.getDataModel().getRootNode(), true);
}
]]></clientCallback>
</processing>
<processing>
<serverCallback methodName="switchAction" sdkMethodName="loadShareList">
<input_param description="Parent repository ID" name="parent_repository_id" type="string" mandatory="false"/>
<input_param name="user_context" type="string" description="Either global (all users, requires admin right) or current (current user)" default="current"/>
</serverCallback>
</processing>
</action>
<action name="sharelist-clearExpired">
<gui text="user_dash.25" title="user_dash.26" iconClass="icon-time" src="edit_clear_history.png" accessKey="" hasAccessKey="false">
<context dir="true" selection="false" recycle="false"
actionBar="true" contextMenu="false" infoPanel="false"
actionBarGroup="share_list_toolbar" inZip="false"/>
</gui>
<rightsContext noUser="true" userLogged="only" read="true" write="true" adminOnly=""/>
<processing>
<clientCallback prepareModal="true"><![CDATA[
var conn = new Connexion();
conn.addParameter("get_action", "sharelist-clearExpired");
var dm = window.actionManager.getDataModel();
conn.onComplete = function(transport){
ajaxplorer.actionBar.parseXmlMessage(transport.responseXML);
if(window.actionManager){
dm.requireContextChange(dm.getRootNode(), true);
}
};
conn.sendAsync();
]]></clientCallback>
<serverCallback methodName="switchAction" developerComment="Clear expired links" restParams="/"/>
</processing>
</action>
<!--
<action name="sharelist-migrate">
<gui src="share.png" iconClass="icon-sort-by-attributes-alt" text="share_center.127" title="share_center.128">
<context dir="false" recycle="false" selection="false" actionBar="true" actionBarGroup="share_list_toolbar" behaviour="hidden"/>
</gui>
<rightsContext adminOnly="true" noUser="false" read="false" userLogged="true" write="false"/>
<processing>
<clientCallback prepareModal="true"><![CDATA[
if(window.actionManager){
var id = window.actionManager.getDataModel().getRootNode().getPath();
}
]]></clientCallback>
<serverCallback methodName="switchAction" developerComment="Migrate old publiclets to new format"/>
</processing>
</action>
-->
<action name="share_current_page">
<gui src="" iconClass="icon-share" text="share_center.110" title="share_center.110">
<context dir="true" recycle="false" selection="false" actionBarGroup="minisite-share-actions" actionBar="true"/>
</gui>
<processing>
<clientCallback dialogOpenForm="share_current_url" dialogSkipButtons="true" prepareModal="true">
<dialogOnOpen><![CDATA[
modal.getForm().down("#crt-page-url").setValue(document.location.href);
if(!ajaxplorer.getContextHolder().isEmpty() && ajaxplorer.getActionBar().getActionByName("download")){
var tpl = new Template('<div style="font-size: 16px; padding-top:15px; text-align:left;">#{title} <a href="#{link}" target="_blank" class="icon-link" style="font-size: 0.8em;"></a></div><input type="text" value="#{link}" style="width: 98%;">');
var node = ajaxplorer.getContextHolder().getUniqueNode();
var editors = ajaxplorer.findEditorsForMime(node.getAjxpMime(), true);
if(editors.length && Class.getByName(editors[0].editorClass)){
var staticClass = Class.getByName(editors[0].editorClass).prototype;
if(staticClass.getRESTPreviewLinks){
var links = staticClass.getRESTPreviewLinks(node);
$H(links).each(function(pair){
modal.getForm().down("#additional_links").insert(tpl.evaluate({title:pair.key,link:document.location.href + "?dl=true&ct=true"+pair.value}));
});
}
}
var dlLink = document.location.href + "?dl=true&file=" + encodeURIComponent(node.getPath());
modal.getForm().down("#additional_links").insert(tpl.evaluate({title:"Direct Download",link:dlLink}));
}
]]></dialogOnOpen>
<dialogOnComplete><![CDATA[
hideLightBox();
]]></dialogOnComplete>
<dialogOnCancel><![CDATA[]]></dialogOnCancel>
</clientCallback>
<clientForm id="share_current_url"><![CDATA[
<div id="share_current_url" box_width="300" style="text-align:center;">
<input type="text" id="crt-page-url" onclick="$(this).select();" value="" style="width: 387px;text-align: center;font-size: 19px;margin: 10px 0;padding: 5px;">
<div class="non_macos">AJXP_MESSAGE[share_center.143]</div>
<div class="macos_only" style="display:none;">AJXP_MESSAGE[share_center.144]</div>
<br>
<div id="additional_links" style="padding-bottom:10px;"></div>
</div>
]]></clientForm>
</processing>
</action>
<action name="download">
<pre_processing>
<serverCallback methodName="preProcessDownload" applyCondition="$apply=isSet($_SESSION['CURRENT_MINISITE']);"/>
</pre_processing>
</action>
</actions>
<client_configs>
<component_config className="InfoPanel">
<infoPanelExtension mime="meta:ajxp_shared" attributes="" modifier="ShareCenter.prototype.loadInfoPanel">
<messages>
<message key="type_string" id="share_center.50"/>
</messages>
<html><![CDATA[
<div id="ajxp_shared_info_panel" data-infoPanelPosition="first">
<div class="panelHeader infoPanelGroup" colspan="2">
<span class="user_meta_change" style="display: none;" data-ajxpaction="share-edit-shared" >AJXP_MESSAGE[457]</span>
<span class="icon-share" data-ajxpAction="share-edit-shared" title="AJXP_MESSAGE[share_center.55]"></span>#{type_string}
</div>
<div class="infoPanelTable" cellspacing="0" border="0" cellpadding="0"></div>
</div>
]]></html>
</infoPanelExtension>
</component_config>
<component_config className="AjxpTabulator::userdashboard_main_tab">
<additional_tab id="shared_pane2"
tabInfo='{"id":"my-shared2","iconClass":"icon-share","element":"shared_pane2","closeable":false,"label":"share_center.98","title":"share_center.99","dontFocus":true,"position":3}'
paneInfo='{"type":"widget"}'><![CDATA[
<div id="shared_pane2" ajxpClass="AjxpPane">
<div id="buttons_bar" class="action_bar" ajxpClass="ActionsToolbar" ajxpOptions='{"dataModelElementId":"shared_files_list","toolbarsList":["share_list_toolbar-selection", "share_list_toolbar"],"skipBubbling":true, "skipCarousel":true,"submenuOffsetTop":2}'></div>
<div id="shared_files_list" ajxpClass="FetchedResultPane" ajxpOptions='{"displayMode":"list", "fixedDisplayMode":"list", "groupByData":"1", "fit":"height","selectionChangeCallback":false,"updateGlobalContext":false,"nodeProviderProperties":{"get_action":"sharelist-load","user_context":"current"}}'></div>
</div>
]]></additional_tab>
</component_config>
</client_configs>
<hooks>
<serverCallback hookName="node.info" methodName="nodeSharedMetadata"/>
<serverCallback hookName="node.change" methodName="updateNodeSharedData"/>
<serverCallback hookName="user.after_delete" methodName="cleanUserShares" defer="true"/>
<serverCallback methodName="forwardEventToShares" hookName="node.change" defer="true"/>
</hooks>
</registry_contributions>
<class_definition filename="plugins/action.share/class.ShareCenter.php" classname="ShareCenter"/>
<dependencies>
<activePlugin pluginName="access.AJXP_STREAM_PROVIDER|access.ajxp_user|access.ajxp_conf"/>
</dependencies>
</ajxp_plugin>