This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get install apache2 | |
sudo a2enmod proxy | |
sudo a2enmod proxy_ajp | |
sudo mkdir -p /var/www/<alfresco-domain> | |
sudo chown -R $USER:$USER /var/www/<alfresco-domain> | |
sudo chmod -R 755 /var/www | |
sudo cp /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/<alfresco-domain>.conf | |
sudo vim /etc/apache2/sites-available/<alfresco-domain>.conf |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var ctx = Packages.org.springframework.web.context.ContextLoader.getCurrentWebApplicationContext(); | |
var behaviourFilter = ctx.getBean("policyBehaviourFilter"); | |
// ----------------------------------------------------------------- | |
function findAndReplaceAttribute(query, attribute, value) { | |
nodes = search.luceneSearch(query); | |
for each(var node in nodes) { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var ctx = Packages.org.springframework.web.context.ContextLoader.getCurrentWebApplicationContext(); | |
var javaSiteService = ctx.getBean("siteService"); | |
var site = javaSiteService.getSite(document.nodeRef); | |
var siteManagerGroup = javaSiteService.getSiteRoleGroup(site.getShortName(), "SiteManager", true); | |
var groupAssignee = people.getGroup(siteManagerGroup) | |
var workflow = actions.create("start-workflow"); | |
workflow.parameters.workflowName = "activiti$activitiParallelGroupReview"; | |
workflow.parameters.requiredApprovePercent = 20; | |
workflow.parameters["bpm:workflowDescription"] = "Please review and approve: " + document.name; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
importClass(Packages.org.springframework.web.context.ContextLoader); | |
importClass(Packages.org.alfresco.service.cmr.repository.TransformationOptions); | |
var context = ContextLoader.getCurrentWebApplicationContext(); | |
var alfThumbnailService = context.getBean("thumbnailService"); | |
alfThumbnailService.updateThumbnail(document.getThumbnail("webpreview").nodeRef, new TransformationOptions()); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
importClass(Packages.org.springframework.web.context.ContextLoader); | |
importClass(Packages.org.alfresco.service.cmr.repository.StoreRef); | |
var ctx = ContextLoader.getCurrentWebApplicationContext(); | |
var archiveService = ctx.getBean("nodeArchiveService"); | |
archiveService.purgeAllArchivedNodes(new StoreRef(StoreRef.PROTOCOL_WORKSPACE, "SpacesStore")); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var RunAsUtil = { | |
execute: function(workFunction, runAsUser) { | |
Packages.org.alfresco.repo.security.authentication.AuthenticationUtil.runAs(new Packages.org.alfresco.repo.security.authentication.AuthenticationUtil.RunAsWork() | |
{ | |
doWork: workFunction | |
}, runAsUser); | |
}, | |
doInTransaction: function(workFunction) { | |
var txs = Packages.org.springframework.web.context.ContextLoader.getCurrentWebApplicationContext().getBean("TransactionService"); | |
var th = txs.getRetryingTransactionHelper(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Reference: http://demon.tw/my-work/vbs-json.html | |
VbsJson class for parsing JSON format data with VBS | |
Tags: JavaScript , JSON , VB , VBS , VBScript | |
Title: The VBS resolve VbsJson class of JSON data format of: Demon | |
Link: http://demon.tw/my-work/vbs-json.html | |
Copyright: All articles in this blog are subject to the terms of " Signature - Non-Commercial Use - Share 2.5 China in the Same Way ". |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
qpdf --encrypt "empty_or_password_open" "owner_password" 40 --print=y --modify=n --extract=n --annotate=n -- input.pdf output.pdf |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some basic operations: | |
Split screen vertically: Ctrlb and Shift5 | |
Split screen horizontally: Ctrlb and Shift" | |
Toggle between panes: Ctrlb and o (or arrows < > V ^ toward the desired screen) | |
Close current pane: Ctrlb and x | |
You can achieve more complex layouts by splitting panes. You can also have multiple windows with panes and switch between them. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo apt-get update | |
sudo apt-get install apache2 | |
sudo apache2ctl configtest | |
Se aparecer: | |
AH00558: apache2: Could not reliably determine the server's fully qualified domain name, using 127.0.1.1. Set the 'ServerName' directive globally to suppress this message | |
Syntax OK | |
Editar /etc/apache2/apache2.conf |