Commit 6c7293ec authored by Romain Courteaud's avatar Romain Courteaud

[erp5_officejs*] Clean up appstore web components

Update appcache

Drop unused scripts

Thanks to Vincent Bechu for his work on this commit.
parent 61785ee1
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="File" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Access_contents_information_Permission</string> </key>
<value>
<tuple>
<string>Anonymous</string>
<string>Assignee</string>
<string>Assignor</string>
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Change_local_roles_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_View_Permission</string> </key>
<value>
<tuple>
<string>Anonymous</string>
<string>Assignee</string>
<string>Assignor</string>
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>5e1e205815a1a2206586fc6c5347cc49</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>text/json</string> </value>
</item>
<item>
<key> <string>default_reference</string> </key>
<value> <string>data/application_sample.json</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>gadget_officejs_appstore_data_application_sample_json</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>File</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>application_sample.json</string> </value>
</item>
<item>
<key> <string>version</string> </key>
<value> <string>001</string> </value>
</item>
<item>
<key> <string>workflow_history</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>data</string> </key>
<value>
<dictionary>
<item>
<key> <string>document_publication_workflow</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>edit_workflow</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAQ=</string> </persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="WorkflowHistoryList" module="Products.ERP5Type.patches.WorkflowTool"/>
</pickle>
<pickle>
<tuple>
<none/>
<list>
<dictionary>
<item>
<key> <string>action</string> </key>
<value> <string>publish</string> </value>
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>error_message</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>time</string> </key>
<value>
<object>
<klass>
<global name="DateTime" module="DateTime.DateTime"/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>1497861289.05</float>
<string>UTC</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key> <string>validation_state</string> </key>
<value> <string>published</string> </value>
</item>
</dictionary>
</list>
</tuple>
</pickle>
</record>
<record id="4" aka="AAAAAAAAAAQ=">
<pickle>
<global name="WorkflowHistoryList" module="Products.ERP5Type.patches.WorkflowTool"/>
</pickle>
<pickle>
<tuple>
<none/>
<list>
<dictionary>
<item>
<key> <string>action</string> </key>
<value> <string>edit</string> </value>
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
<value>
<none/>
</value>
</item>
<item>
<key> <string>error_message</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>970.31168.35810.58043</string> </value>
</item>
<item>
<key> <string>state</string> </key>
<value> <string>current</string> </value>
</item>
<item>
<key> <string>time</string> </key>
<value>
<object>
<klass>
<global name="DateTime" module="DateTime.DateTime"/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>1537862969.45</float>
<string>UTC</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</tuple>
</pickle>
</record>
</ZopeData>
[
{
"application_image_type": "image",
"application_image_url": "http://www.officejs.com/app/task_manager/icon_taskmanager.png",
"application_toc_accept": true,
"application_published":"08/11/2013",
"application_submitted":"08/11/2013",
"application_description":"The Task Manager is a web mobile applicaion based on HTML5, CSS3, Javascript, Jquery, Jquery Mobile, Grunt, Requirejs and many other plugins, no servers side language like php, java and so on... is needed. Data are fetch and retrieved by a more powerfull API named JIO. busness rules are now implemented by the client layer, data can be store either on localstorage for the browser or on remote storage like S3, Webdav, xwiki, dropbox and so on. The librairy named jIO provide methods(get, post, put, allDocs) for manipulating data. The application is integrating webapp, enabling offline support. At runtime, all files are downloaded into the user's device (browser cache), witch make the application faster the new time. It can run on laptop, tablets, smartphone and all devices having a web browser regardless of the OS.",
"application_url":"http://taskman.app.officejs.com/",
"application_title":"Task Manager JS",
"application_category":"Projects",
"application_title_i18n":"application.custom.task_manager_js.title",
"application_description_i18n":"application.custom.task_manager_js.description"
},
{
"application_image_type": "image",
"application_image_url": "http://www.officejs.com/app/text_editor/icon_text_editor.png",
"application_toc_accept": true,
"application_published":null,
"application_submitted":"08/15/2013",
"application_description":"COMING SOON",
"application_url":"",
"application_title":"Text Editor JS",
"application_category":"Documents",
"application_title_i18n":"application.custom.text_editor_js.title",
"application_description_i18n":"application.custom.text_editor_js.description"
},
{
"application_image_type": "image",
"application_image_url": "http://www.officejs.com/app/workflow_manager/icon_workflow2.png",
"application_toc_accept": true,
"application_published": null,
"application_submitted":"08/15/2013",
"application_description":"COMING SOON",
"application_url":"",
"application_title":"Workflow JS",
"application_category":"Projects",
"application_title_i18n":"application.custom.workflow_js.title",
"application_description_i18n":"application.custom.workflow_js.description"
},
{
"application_image_type": "image",
"application_image_url": "http://www.officejs.com/app/contact_manager/icon_contacts.png",
"application_toc_accept": true,
"application_published": null,
"application_submitted":"08/15/2013",
"application_description":"COMING SOON",
"application_url":"",
"application_title":"Contacts JS",
"application_category":"Contacts",
"application_title_i18n":"application.custom.contacts_js.title",
"application_description_i18n":"application.custom.contacts_js.description"
}
]
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="File" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Access_contents_information_Permission</string> </key>
<value>
<tuple>
<string>Anonymous</string>
<string>Assignee</string>
<string>Assignor</string>
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Change_local_roles_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_View_Permission</string> </key>
<value>
<tuple>
<string>Anonymous</string>
<string>Assignee</string>
<string>Assignor</string>
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>8408bb71d10c97cb5973881ae8b71cbc</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>application/x-trash</string> </value>
</item>
<item>
<key> <string>default_reference</string> </key>
<value> <string>data/application_sample.json.bak</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>gadget_officejs_appstore_data_application_sample_json_bak</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>File</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>application_sample.json.bak</string> </value>
</item>
<item>
<key> <string>version</string> </key>
<value> <string>001</string> </value>
</item>
<item>
<key> <string>workflow_history</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>data</string> </key>
<value>
<dictionary>
<item>
<key> <string>document_publication_workflow</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>edit_workflow</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAQ=</string> </persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="WorkflowHistoryList" module="Products.ERP5Type.patches.WorkflowTool"/>
</pickle>
<pickle>
<tuple>
<none/>
<list>
<dictionary>
<item>
<key> <string>action</string> </key>
<value> <string>publish</string> </value>
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>error_message</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>time</string> </key>
<value>
<object>
<klass>
<global name="DateTime" module="DateTime.DateTime"/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>1497861289.07</float>
<string>UTC</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key> <string>validation_state</string> </key>
<value> <string>published</string> </value>
</item>
</dictionary>
</list>
</tuple>
</pickle>
</record>
<record id="4" aka="AAAAAAAAAAQ=">
<pickle>
<global name="WorkflowHistoryList" module="Products.ERP5Type.patches.WorkflowTool"/>
</pickle>
<pickle>
<tuple>
<none/>
<list>
<dictionary>
<item>
<key> <string>action</string> </key>
<value> <string>edit</string> </value>
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>error_message</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>0.0.0.0</string> </value>
</item>
<item>
<key> <string>state</string> </key>
<value> <string>current</string> </value>
</item>
<item>
<key> <string>time</string> </key>
<value>
<object>
<klass>
<global name="DateTime" module="DateTime.DateTime"/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>1497861289.06</float>
<string>UTC</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</tuple>
</pickle>
</record>
</ZopeData>
......@@ -40,6 +40,4 @@ web_site_module/officejs_todomvc
web_site_module/officejs_wallsearch
web_site_module/officejs_wallsearch/**
web_site_module/officejs_whiteboard
web_site_module/officejs_appstore
web_site_module/officejs_appstore/**
web_site_module/officejs_media_player/**
\ No newline at end of file
......@@ -40,6 +40,4 @@ web_site_module/officejs_todomvc
web_site_module/officejs_wallsearch
web_site_module/officejs_wallsearch/**
web_site_module/officejs_whiteboard
web_site_module/officejs_appstore
web_site_module/officejs_appstore/**
web_site_module/officejs_media_player/**
\ No newline at end of file
......@@ -14,8 +14,6 @@ web_page_module/officejs_audioplayer_*
web_page_module/officejs_todomvc_*
web_page_module/ojs_*
web_page_module/wallsearch_privacy_policy_html
web_site_module/officejs_appstore
web_site_module/officejs_appstore/**
web_site_module/officejs_audioplayer
web_site_module/officejs_audioplayer/**
web_site_module/officejs_bookmark_manager
......
portal = context.getPortalObject()
person = context.ERP5Site_getAuthenticatedMemberPersonValue()
# Generate Version Number
# XXX Should Check that version of this software doesn't already exists
import hashlib
version = hashlib.sha224("%s-%s-%s" % (context.getReference(), version_title, DateTime())).hexdigest()[:10]
# Create Software Publication
# It carries the software publication process
software_publication = portal.software_publication_module.newContent(
portal_type="Software Publication",
description=description,
source=person.getRelativeUrl(),
# We should probably use a more simple reference using an incremental id generator
reference="SP-" + context.getReference() + "-" + version,
title=context.getTitle() + ' release ' + version_title,
)
# Create Software Release
# This is the result of the publication process. It is an aggregate of the line
software_release = portal.software_release_module.newContent(
portal_type="Software Release",
reference=context.getReference() + "-" + version,
title=context.getTitle() + ' release ' + version_title + '-' + version,
# XXX the follow_up lkink is actually nonsense and redundant
follow_up=context.getRelativeUrl(),
version=version_title,
)
# Create Software Publication Line
software_publication_line = software_publication.newContent(
portal_type="Software Publication Line",
title=software_publication.getTitle() + " Publication",
resource=context.getRelativeUrl(),
aggregate=[
software_release.getRelativeUrl(),
context.getSaleSupplyLineAggregate(),
]
)
# Create Web Section And Web Section Predicate
# The predicate look for version and validation_state=submitted
web_site = context.SoftwareProduct_fixRelatedWebSite()
section = web_site['development'].Base_createCloneDocument(batch_mode=True)
section.edit(
title="%s %s" % (context.getTitle(), version_title),
short_title=context.getTitle(),
description=context.getDescription(),
id=version_title,
)
membership_criterion_category_list = ['follow_up/' + software_release.getRelativeUrl()]
def webSectionUpdatePredicate(current_section):
current_section.setCriterionPropertyList([
'version',
'validation_state',
])
current_section.setCriterion('version', version)
current_section.setCriterion('validation_state', 'submitted')
current_section.setMembershipCriterionCategoryList(membership_criterion_category_list)
for child_section in current_section.objectValues(portal_type="Web Section"):
webSectionUpdatePredicate(child_section)
webSectionUpdatePredicate(section)
# Clone all curent Web Document and share them with the correct Version
web_document_list = portal.portal_catalog(
portal_type=portal.getPortalDocumentTypeList(),
strict_follow_up_uid=context.getUid(),
validation_state="draft",
# XXX This is hackish
sort_on=[("modification_date", "descending")],
)
# We clone all related Web Document, set the correct version and submit them
for web_document in web_document_list:
released_web_document = web_document.Base_createCloneDocument(batch_mode=True)
released_web_document.setVersion(version)
released_web_document.setFollowUpValue(software_release)
released_web_document.submit()
if released_web_document.getPublicationSection() == "application/landing_page":
section.setAggregate(released_web_document.getRelativeUrl())
# For now everything is submitted on creation, maybe it should be done by the developer
software_release.submit()
software_publication.submit()
return software_publication.Base_redirect(
'',
keep_items={
'portal_status_message': context.Base_translateString("Software Publication Request Created"),
},
)
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>version_title, description, **kw</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>SoftwareProduct_createSoftwarePublication</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ERP5 Form" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_objects</string> </key>
<value>
<tuple/>
</value>
</item>
<item>
<key> <string>action</string> </key>
<value> <string>SoftwareProduct_createSoftwarePublication</string> </value>
</item>
<item>
<key> <string>description</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>edit_order</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>enctype</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>group_list</string> </key>
<value>
<list>
<string>left</string>
<string>right</string>
<string>center</string>
<string>bottom</string>
<string>hidden</string>
</list>
</value>
</item>
<item>
<key> <string>groups</string> </key>
<value>
<dictionary>
<item>
<key> <string>bottom</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>center</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>hidden</string> </key>
<value>
<list/>
</value>
</item>
<item>
<key> <string>left</string> </key>
<value>
<list>
<string>your_version_title</string>
<string>your_description</string>
</list>
</value>
</item>
<item>
<key> <string>right</string> </key>
<value>
<list/>
</value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>SoftwareProduct_createSoftwarePublicationDialog</string> </value>
</item>
<item>
<key> <string>method</string> </key>
<value> <string>POST</string> </value>
</item>
<item>
<key> <string>name</string> </key>
<value> <string>SoftwareProduct_createSoftwarePublicationDialog</string> </value>
</item>
<item>
<key> <string>pt</string> </key>
<value> <string>form_dialog</string> </value>
</item>
<item>
<key> <string>row_length</string> </key>
<value> <int>4</int> </value>
</item>
<item>
<key> <string>stored_encoding</string> </key>
<value> <string>UTF-8</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Create Software Publication</string> </value>
</item>
<item>
<key> <string>unicode_mode</string> </key>
<value> <int>0</int> </value>
</item>
<item>
<key> <string>update_action</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>update_action_title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>required</string>
<string>title</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>your_description</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_description</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>Base_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>required</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Version Description</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>delegated_list</string> </key>
<value>
<list>
<string>required</string>
<string>title</string>
</list>
</value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>your_version_title</string> </value>
</item>
<item>
<key> <string>message_values</string> </key>
<value>
<dictionary>
<item>
<key> <string>external_validator_failed</string> </key>
<value> <string>The input failed the external validator.</string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>overrides</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>tales</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</value>
</item>
<item>
<key> <string>values</string> </key>
<value>
<dictionary>
<item>
<key> <string>field_id</string> </key>
<value> <string>my_version</string> </value>
</item>
<item>
<key> <string>form_id</string> </key>
<value> <string>WebPage_viewFieldLibrary</string> </value>
</item>
<item>
<key> <string>required</string> </key>
<value> <int>1</int> </value>
</item>
<item>
<key> <string>target</string> </key>
<value> <string>Click to edit the target</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>Version Title</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
portal = context.getPortalObject()
# First make sure the site is in the correct state
website = context.SoftwareProduct_fixRelatedWebSite()
software_product = context
# Should make a script for that
if software_product.getId() != software_product.getReference().lower():
software_product.setId(context.getReference().lower())
base_id = "%s-" % (context.getId())
# Start with the document list
path_list = []
document_list = portal.portal_catalog(
portal_type= portal.getPortalDocumentTypeList(),
validation_state="draft",
strict_follow_up_uid=context.getUid(),
select_list=('relative_url', ),
)
for brain in document_list:
document = brain.getObject()
# Update ID is necessary
if not document.getId() == base_id + document.getReference().replace('.', '_'):
document.setId(base_id + document.getReference().replace('.', '_'))
path_list.append(document.getRelativeUrl())
# Append the software product
path_list.append(context.getRelativeUrl())
# Add the website development section (Really????)
path_list.append(website.getRelativeUrl())
path_list.append(website['development'].getRelativeUrl())
path_list.append(website['development'].getRelativeUrl() + "/**")
if business_template_path:
bt5 = portal.restrictedTraverse(business_template_path)
else:
bt5 = portal.portal_templates.newContent(
portal_type="Business Template",
title='officejs-' + context.getReference().lower() + '-export',
)
bt5.edit(
template_path_list=path_list,
template_keep_last_workflow_history_only_path_list=path_list,
version=DateTime().HTML4(),
)
return bt5.Base_redirect(
'',
keeps_items={
'portal_status_message': portal.Base_translateString("Portal Template updated")
}
)
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>Script_magic</string> </key>
<value> <int>3</int> </value>
</item>
<item>
<key> <string>_bind_names</string> </key>
<value>
<object>
<klass>
<global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
</klass>
<tuple/>
<state>
<dictionary>
<item>
<key> <string>_asgns</string> </key>
<value>
<dictionary>
<item>
<key> <string>name_container</string> </key>
<value> <string>container</string> </value>
</item>
<item>
<key> <string>name_context</string> </key>
<value> <string>context</string> </value>
</item>
<item>
<key> <string>name_m_self</string> </key>
<value> <string>script</string> </value>
</item>
<item>
<key> <string>name_subpath</string> </key>
<value> <string>traverse_subpath</string> </value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</state>
</object>
</value>
</item>
<item>
<key> <string>_params</string> </key>
<value> <string>business_template_path=""</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>SoftwareProduct_prepareBT5</string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
[
{
"application_image_type": "image",
"application_image_url": "http://www.officejs.com/app/task_manager/icon_taskmanager.png",
"application_toc_accept": true,
"application_published":"08/11/2013",
"application_submitted":"08/11/2013",
"application_description":"The Task Manager is a web mobile applicaion based on HTML5, CSS3, Javascript, Jquery, Jquery Mobile, Grunt, Requirejs and many other plugins, no servers side language like php, java and so on... is needed. Data are fetch and retrieved by a more powerfull API named JIO. busness rules are now implemented by the client layer, data can be store either on localstorage for the browser or on remote storage like S3, Webdav, xwiki, dropbox and so on. The librairy named jIO provide methods(get, post, put, allDocs) for manipulating data. The application is integrating webapp, enabling offline support. At runtime, all files are downloaded into the user's device (browser cache), witch make the application faster the new time. It can run on laptop, tablets, smartphone and all devices having a web browser regardless of the OS.",
"application_url":"http://taskman.app.officejs.com/",
"application_title":"Task Manager JS",
"application_category":"Projects",
"application_title_i18n":"application.custom.task_manager_js.title",
"application_description_i18n":"application.custom.task_manager_js.description"
},
{
"application_image_type": "image",
"application_image_url": "http://www.officejs.com/app/text_editor/icon_text_editor.png",
"application_toc_accept": true,
"application_published":null,
"application_submitted":"08/15/2013",
"application_description":"COMING SOON",
"application_url":"",
"application_title":"Text Editor JS",
"application_category":"Documents",
"application_title_i18n":"application.custom.text_editor_js.title",
"application_description_i18n":"application.custom.text_editor_js.description"
},
{
"application_image_type": "image",
"application_image_url": "http://www.officejs.com/app/workflow_manager/icon_workflow2.png",
"application_toc_accept": true,
"application_published": null,
"application_submitted":"08/15/2013",
"application_description":"COMING SOON",
"application_url":"",
"application_title":"Workflow JS",
"application_category":"Projects",
"application_title_i18n":"application.custom.workflow_js.title",
"application_description_i18n":"application.custom.workflow_js.description"
},
{
"application_image_type": "image",
"application_image_url": "http://www.officejs.com/app/contact_manager/icon_contacts.png",
"application_toc_accept": true,
"application_published": null,
"application_submitted":"08/15/2013",
"application_description":"COMING SOON",
"application_url":"",
"application_title":"Contacts JS",
"application_category":"Contacts",
"application_title_i18n":"application.custom.contacts_js.title",
"application_description_i18n":"application.custom.contacts_js.description"
}
]
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="File" module="erp5.portal_type"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_Access_contents_information_Permission</string> </key>
<value>
<tuple>
<string>Anonymous</string>
<string>Assignee</string>
<string>Assignor</string>
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Add_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Change_local_roles_Permission</string> </key>
<value>
<tuple>
<string>Assignor</string>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_Modify_portal_content_Permission</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item>
<item>
<key> <string>_View_Permission</string> </key>
<value>
<tuple>
<string>Anonymous</string>
<string>Assignee</string>
<string>Assignor</string>
<string>Associate</string>
<string>Auditor</string>
<string>Manager</string>
<string>Owner</string>
</tuple>
</value>
</item>
<item>
<key> <string>content_md5</string> </key>
<value> <string>8408bb71d10c97cb5973881ae8b71cbc</string> </value>
</item>
<item>
<key> <string>content_type</string> </key>
<value> <string>application/x-trash</string> </value>
</item>
<item>
<key> <string>default_reference</string> </key>
<value> <string>data/application_sample.json.bak</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>store_officejs_data_application_sample_json_bak</string> </value>
</item>
<item>
<key> <string>portal_type</string> </key>
<value> <string>File</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string>application_sample.json.bak</string> </value>
</item>
<item>
<key> <string>version</string> </key>
<value> <string>001</string> </value>
</item>
<item>
<key> <string>workflow_history</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="2" aka="AAAAAAAAAAI=">
<pickle>
<global name="PersistentMapping" module="Persistence.mapping"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>data</string> </key>
<value>
<dictionary>
<item>
<key> <string>document_publication_workflow</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value>
</item>
<item>
<key> <string>edit_workflow</string> </key>
<value>
<persistent> <string encoding="base64">AAAAAAAAAAQ=</string> </persistent>
</value>
</item>
</dictionary>
</value>
</item>
</dictionary>
</pickle>
</record>
<record id="3" aka="AAAAAAAAAAM=">
<pickle>
<global name="WorkflowHistoryList" module="Products.ERP5Type.patches.WorkflowTool"/>
</pickle>
<pickle>
<tuple>
<none/>
<list>
<dictionary>
<item>
<key> <string>action</string> </key>
<value> <string>publish</string> </value>
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>error_message</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>time</string> </key>
<value>
<object>
<klass>
<global name="DateTime" module="DateTime.DateTime"/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>1497861289.07</float>
<string>UTC</string>
</tuple>
</state>
</object>
</value>
</item>
<item>
<key> <string>validation_state</string> </key>
<value> <string>published</string> </value>
</item>
</dictionary>
</list>
</tuple>
</pickle>
</record>
<record id="4" aka="AAAAAAAAAAQ=">
<pickle>
<global name="WorkflowHistoryList" module="Products.ERP5Type.patches.WorkflowTool"/>
</pickle>
<pickle>
<tuple>
<none/>
<list>
<dictionary>
<item>
<key> <string>action</string> </key>
<value> <string>edit</string> </value>
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>error_message</string> </key>
<value> <string></string> </value>
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>0.0.0.0</string> </value>
</item>
<item>
<key> <string>state</string> </key>
<value> <string>current</string> </value>
</item>
<item>
<key> <string>time</string> </key>
<value>
<object>
<klass>
<global name="DateTime" module="DateTime.DateTime"/>
</klass>
<tuple>
<none/>
</tuple>
<state>
<tuple>
<float>1497861289.06</float>
<string>UTC</string>
</tuple>
</state>
</object>
</value>
</item>
</dictionary>
</list>
</tuple>
</pickle>
</record>
</ZopeData>
<!DOCTYPE html>
<html>
<head>
<meta http-equiv="Content-type" content="text/html; charset=utf-8" />
<meta name="viewport" content="width=device-width" />
<title></title>
<link rel="stylesheet" href="css/jquery-mobile/jquery-mobile.latest.css">
<link rel="stylesheet" href="css/extensions.css">
<link rel="stylesheet" href="css/fontawesome.css">
<link rel="stylesheet" href="css/themes.css">
<link rel="stylesheet" href="css/css.css">
</head>
<body>
<!-- global panel -->
<!-- global header -->
<div id="all" data-role="page" data-theme="slapos-white" data-module="all">
<div class="ui-content">
<!-- nothing to see here -->
</div>
<div style="text-align:center;">
<a href="http://www.miibeian.gov.cn/" style="color:white">沪ICP备14008524号</a>
</div>
</div>
<!-- global footer (not used) -->
<!-- global popup -->
<!-- JQM -->
<script src="js/libs/jquery/jquery.js"></script>
<script src="js/libs/jquery-mobile/jquery-mobile.js"></script>
<script src="js/extensions.js"></script>
<!-- JIO -->
<script src="js/libs/jio/sha256.amd.js"></script>
<script src="js/libs/jio/rsvp-custom.js"></script>
<script src="js/libs/jio/jio.js"></script>
<script src="js/libs/jio/complex_queries.js"></script>
<script src="js/libs/jio/localstorage.js"></script>
<!-- plugins -->
<script src="js/plugins/validval/jquery.validVal.js"></script>
<script src="js/plugins/i18next/i18next.js"></script>
<!-- stuff happens here -->
<script src="js/erp5_loader.js"></script>
</body>
</html>
......@@ -104,23 +104,9 @@
<item>
<key> <string>text_content</string> </key>
<value> <string>CACHE MANIFEST\n
# generated on Fri, 09 Jun 2016 11:45:33 +0000\n
# XXX + fonts\n
# images/ajax-loader.gif\n
# generated on Mon, 28 Jan 2019 11:45:33 +0000\n
CACHE:\n
appstore/app/contact_manager/icon_contacts.png\n
appstore/app/contact_manager/icon_taskmanager.png\n
appstore/app/contact_manager/icon_text_editor.png\n
appstore/app/contact_manager/icon_workflow2.png\n
appstore/app/icon_contacts.png\n
appstore/app/icon_workflow2.png\n
appstore/app/taskman-editor.png\n
appstore/app/taskman-spreadsheet.png\n
appstore/app/taskman-svg.png\n
appstore/app/taskman.png\n
appstore/app/text_editor/icon_text_editor.png\n
appstore/app/text_editor/icon_workflow2.png\n
appstore/app/workflow_manager/icon_workflow2.png\n
\n
appstore/contest/index.html\n
appstore/css/css.css\n
appstore/css/extensions.css\n
......@@ -147,7 +133,6 @@ appstore/data/all.json\n
appstore/data/all_apps.json\n
appstore/data/application_fieldlist.json\n
appstore/data/application_sample.json\n
appstore/data/application_sample.json.bak\n
appstore/data/apps.json\n
appstore/data/category.json\n
appstore/data/category_fieldlist.json\n
......@@ -355,7 +340,7 @@ NETWORK:\n
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>970.54551.8564.49527</string> </value>
<value> <string>973.19272.23311.6092</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -373,7 +358,7 @@ NETWORK:\n
</tuple>
<state>
<tuple>
<float>1539100352.98</float>
<float>1548694049.98</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -107,24 +107,11 @@
<item>
<key> <string>text_content</string> </key>
<value> <string>CACHE MANIFEST\n
# generated on Fri, 09 Jun 2016 11:45:33 +0000\n
# generated on Wed, 30 Jun 2019 11:45:33 +0000\n
# XXX + fonts\n
# images/ajax-loader.gif\n
CACHE:\n
${logo_list}\n
appstore/app/contact_manager/icon_contacts.png\n
appstore/app/contact_manager/icon_taskmanager.png\n
appstore/app/contact_manager/icon_text_editor.png\n
appstore/app/contact_manager/icon_workflow2.png\n
appstore/app/icon_contacts.png\n
appstore/app/icon_workflow2.png\n
appstore/app/taskman-editor.png\n
appstore/app/taskman-spreadsheet.png\n
appstore/app/taskman-svg.png\n
appstore/app/taskman.png\n
appstore/app/text_editor/icon_text_editor.png\n
appstore/app/text_editor/icon_workflow2.png\n
appstore/app/workflow_manager/icon_workflow2.png\n
appstore/contest/index.html\n
appstore/css/css.css\n
appstore/css/extensions.css\n
......@@ -151,7 +138,6 @@ appstore/data/all.json\n
appstore/data/all_apps.json\n
appstore/data/application_fieldlist.json\n
appstore/data/application_sample.json\n
appstore/data/application_sample.json.bak\n
appstore/data/apps.json\n
appstore/data/category.json\n
appstore/data/category_fieldlist.json\n
......@@ -345,7 +331,7 @@ NETWORK:\n
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>P1</string> </value>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
......@@ -359,7 +345,7 @@ NETWORK:\n
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>970.32839.48025.22852</string> </value>
<value> <string>973.21680.16689.44390</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -377,7 +363,7 @@ NETWORK:\n
</tuple>
<state>
<tuple>
<float>1538057221.35</float>
<float>1548838531.78</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -85,7 +85,7 @@
</item>
<item>
<key> <string>id</string> </key>
<value> <string>gadget_officejs_old_landing_v1_html</string> </value>
<value> <string>store_officejs_landing_v1_html</string> </value>
</item>
<item>
<key> <string>language</string> </key>
......@@ -105,7 +105,7 @@
</item>
<item>
<key> <string>title</string> </key>
<value> <string>OfficeJS Old Landing Page</string> </value>
<value> <string>OfficeJS Store Landing Page</string> </value>
</item>
<item>
<key> <string>version</string> </key>
......@@ -236,7 +236,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>960.9692.10606.25634</string> </value>
<value> <string>972.19793.15063.31249</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -254,7 +254,7 @@
</tuple>
<state>
<tuple>
<float>1498048697.48</float>
<float>1544798597.76</float>
<string>UTC</string>
</tuple>
</state>
......
......@@ -169,7 +169,7 @@
<key> <string>categories</string> </key>
<value>
<tuple>
<string>aggregate/web_page_module/gadget_officejs_old_landing_v1_html</string>
<string>aggregate/web_page_module/store_officejs_landing_v1_html</string>
<string>caching_policy/one-day-max-modification-date</string>
</tuple>
</value>
......@@ -425,7 +425,7 @@
</item>
<item>
<key> <string>actor</string> </key>
<value> <string>P1</string> </value>
<value> <string>zope</string> </value>
</item>
<item>
<key> <string>comment</string> </key>
......@@ -439,7 +439,7 @@
</item>
<item>
<key> <string>serial</string> </key>
<value> <string>970.35421.15652.18176</string> </value>
<value> <string>972.19793.15063.31249</string> </value>
</item>
<item>
<key> <string>state</string> </key>
......@@ -457,7 +457,7 @@
</tuple>
<state>
<tuple>
<float>1538038912.16</float>
<float>1544798605.03</float>
<string>UTC</string>
</tuple>
</state>
......
web_page_module/officejs_old_landing_v1_html
web_page_module/store_officejs_*
document_module/store_officejs_*
image_module/store_officejs_*
......
web_page_module/officejs_old_landing_v1_html
web_page_module/store_officejs_*
document_module/store_officejs_*
image_module/store_officejs_*
......
document_module/store_officejs_*
image_module/store_officejs_*
portal_alarms/officejs_process_submit_software_publication
web_page_module/officejs_old_landing_v1_html
portal_alarms/officejs_process_update_appstore
web_page_module/store_officejs_*
web_site_module/application-list/store
web_site_module/application-list/store/**
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment