Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
erp5
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Carlos Ramos Carreño
erp5
Commits
6e377384
Commit
6e377384
authored
Aug 16, 2017
by
Vincent Bechu
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[erp5_officejs] Change global setting url in dav configurator
parent
0c1e24fb
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
11 additions
and
20 deletions
+11
-20
bt5/erp5_officejs/PathTemplateItem/web_page_module/gadget_officejs_page_jio_dav_configurator_js.js
...ge_module/gadget_officejs_page_jio_dav_configurator_js.js
+9
-18
bt5/erp5_officejs/PathTemplateItem/web_page_module/gadget_officejs_page_jio_dav_configurator_js.xml
...e_module/gadget_officejs_page_jio_dav_configurator_js.xml
+2
-2
No files found.
bt5/erp5_officejs/PathTemplateItem/web_page_module/gadget_officejs_page_jio_dav_configurator_js.js
View file @
6e377384
...
@@ -4,22 +4,14 @@
...
@@ -4,22 +4,14 @@
(
function
(
window
,
rJS
,
RSVP
)
{
(
function
(
window
,
rJS
,
RSVP
)
{
"
use strict
"
;
"
use strict
"
;
function
setjIODAVConfiguration
(
gadget
)
{
function
setjIODAVConfiguration
(
gadget
,
options
)
{
var
dav_url
=
gadget
.
props
.
element
.
querySelector
(
"
input[name='dav_url']
"
).
value
;
return
gadget
.
getSetting
(
"
portal_type
"
,
"
Web Page
"
)
return
gadget
.
getSetting
(
"
portal_type
"
,
"
Web Page
"
)
.
push
(
function
(
portal_type
)
{
.
push
(
function
(
portal_type
)
{
var
old_date
=
new
Date
(),
var
configuration
=
{
configuration
=
{};
// We are looking for documents modified in the past 3 month
old_date
=
new
Date
(
old_date
.
getFullYear
(),
old_date
.
getMonth
()
-
3
);
configuration
=
{
type
:
"
replicate
"
,
type
:
"
replicate
"
,
// XXX This drop the signature lists...
// XXX This drop the signature lists...
query
:
{
query
:
{
query
:
'
portal_type:"
'
+
portal_type
+
'
"
'
,
query
:
'
portal_type:"
'
+
portal_type
+
'
"
'
,
// XX Synchonizing the whole module is too much, here is a way to start quietly
//+ 'AND local_roles: ("Owner") '
//+ 'AND validation_state: ("draft", "released_alive", "shared_alive", "published_alive") ',
limit
:
[
0
,
100
]
limit
:
[
0
,
100
]
},
},
use_remote_post
:
false
,
use_remote_post
:
false
,
...
@@ -66,14 +58,13 @@
...
@@ -66,14 +58,13 @@
property
:
{
property
:
{
"
portal_type
"
:
[
"
portal_type
"
:
[
"
switchPropertyValue
"
,
"
switchPropertyValue
"
,
{
"
PDF
"
:
"
pdf
"
,
"
Web Page
"
:
"
txt
"
}
{
"
PDF
"
:
"
pdf
"
,
"
Web Page
"
:
"
txt
"
}
]
]
},
},
sub_storage
:
{
sub_storage
:
{
type
:
"
dav
"
,
type
:
"
dav
"
,
url
:
gadget
.
props
.
element
.
querySelector
(
"
input[name='dav_url']
"
).
value
,
url
:
options
.
dav_url
,
basic_login
:
btoa
(
gadget
.
props
.
element
.
querySelector
(
"
input[name='dav_username']
"
).
value
basic_login
:
btoa
(
options
.
username
+
'
:
'
+
options
.
password
),
+
'
:
'
+
gadget
.
props
.
element
.
querySelector
(
"
input[name='dav_password']
"
).
value
),
with_credentials
:
true
with_credentials
:
true
}
}
}
}
...
@@ -87,7 +78,7 @@
...
@@ -87,7 +78,7 @@
return
gadget
.
setSetting
(
'
jio_storage_name
'
,
"
DAV
"
);
return
gadget
.
setSetting
(
'
jio_storage_name
'
,
"
DAV
"
);
})
})
.
push
(
function
()
{
.
push
(
function
()
{
return
gadget
.
setGlobalSetting
(
'
dav_url
'
,
dav_url
);
return
gadget
.
setGlobalSetting
(
'
dav_url
'
,
options
.
dav_url
);
})
})
.
push
(
function
()
{
.
push
(
function
()
{
return
gadget
.
setSetting
(
'
sync_reload
'
,
true
);
return
gadget
.
setSetting
(
'
sync_reload
'
,
true
);
...
@@ -95,7 +86,7 @@
...
@@ -95,7 +86,7 @@
.
push
(
function
()
{
.
push
(
function
()
{
return
gadget
.
redirect
({
return
gadget
.
redirect
({
command
:
"
display
"
,
command
:
"
display
"
,
options
:
{
page
:
'
sync
'
,
auto_repair
:
'
true
'
}
options
:
{
page
:
'
ojs_
sync
'
,
auto_repair
:
'
true
'
}
});
});
});
});
}
}
...
@@ -155,7 +146,7 @@
...
@@ -155,7 +146,7 @@
.
declareService
(
function
()
{
.
declareService
(
function
()
{
var
gadget
=
this
;
var
gadget
=
this
;
return
gadget
.
getSetting
(
"
global_setting_gadget_url
"
,
"
officejs_setting_gadget/app/
"
)
return
gadget
.
getSetting
(
"
global_setting_gadget_url
"
,
"
../
officejs_setting_gadget/app/
"
)
.
push
(
function
(
global_setting_gadget_url
)
{
.
push
(
function
(
global_setting_gadget_url
)
{
return
gadget
.
declareGadget
(
global_setting_gadget_url
,
{
return
gadget
.
declareGadget
(
global_setting_gadget_url
,
{
"
scope
"
:
"
global_setting_gadget
"
,
"
scope
"
:
"
global_setting_gadget
"
,
...
@@ -214,7 +205,7 @@
...
@@ -214,7 +205,7 @@
"
editable
"
:
1
,
"
editable
"
:
1
,
"
key
"
:
"
password
"
,
"
key
"
:
"
password
"
,
"
hidden
"
:
0
,
"
hidden
"
:
0
,
"
type
"
:
"
String
Field
"
"
type
"
:
"
Password
Field
"
}
}
}},
}},
"
_links
"
:
{
"
_links
"
:
{
...
...
bt5/erp5_officejs/PathTemplateItem/web_page_module/gadget_officejs_page_jio_dav_configurator_js.xml
View file @
6e377384
...
@@ -238,7 +238,7 @@
...
@@ -238,7 +238,7 @@
</item>
</item>
<item>
<item>
<key>
<string>
serial
</string>
</key>
<key>
<string>
serial
</string>
</key>
<value>
<string>
961.
10686.10882.5973
</string>
</value>
<value>
<string>
961.
29545.56354.24985
</string>
</value>
</item>
</item>
<item>
<item>
<key>
<string>
state
</string>
</key>
<key>
<string>
state
</string>
</key>
...
@@ -256,7 +256,7 @@
...
@@ -256,7 +256,7 @@
</tuple>
</tuple>
<state>
<state>
<tuple>
<tuple>
<float>
1502
107775.92
</float>
<float>
1502
901834.19
</float>
<string>
UTC
</string>
<string>
UTC
</string>
</tuple>
</tuple>
</state>
</state>
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment