summaryrefslogtreecommitdiff
path: root/addons/document
diff options
context:
space:
mode:
authorrpa (Open ERP) <rpa@tinyerp.com>2009-11-30 11:15:43 +0530
committerrpa (Open ERP) <rpa@tinyerp.com>2009-11-30 11:15:43 +0530
commit0b4a35cc889e4ea75b164fde36a0fbac2c3d3eaf (patch)
tree0d351f5227de6ce079bf3a61b1197b9e43785f2f /addons/document
parent1b495ee8d29e347762fefe3b3d88f71bd805df76 (diff)
parentfe9c6b35c13c70633866e04c57d1b5cce8345dbd (diff)
[Merge]: Merge with Parent branch
bzr revid: rpa@tinyerp.com-20091130054543-42dsu82bluet4jjy
Diffstat (limited to 'addons/document')
-rw-r--r--addons/document/document.py2
-rw-r--r--addons/document/i18n/pt.po165
-rw-r--r--addons/document/security/document_security.xml12
3 files changed, 106 insertions, 73 deletions
diff --git a/addons/document/document.py b/addons/document/document.py
index cd3d667f8bf..4acef4d3ab8 100644
--- a/addons/document/document.py
+++ b/addons/document/document.py
@@ -242,6 +242,7 @@ class document_directory(osv.osv):
_description = 'Document directory'
_columns = {
'name': fields.char('Name', size=64, required=True, select=1),
+ 'company_id': fields.many2one('res.company', 'Company'),
'write_date': fields.datetime('Date Modified', readonly=True),
'write_uid': fields.many2one('res.users', 'Last Modification User', readonly=True),
'create_date': fields.datetime('Date Created', readonly=True),
@@ -269,6 +270,7 @@ class document_directory(osv.osv):
'user_id': lambda self,cr,uid,ctx: uid,
'domain': lambda self,cr,uid,ctx: '[]',
'type': lambda *args: 'directory',
+ 'company_id': lambda self,cr,uid,c: self.pool.get('res.company')._company_default_get(cr, uid, 'document.directory', c),
'ressource_id': lambda *a: 0
}
_sql_constraints = [
diff --git a/addons/document/i18n/pt.po b/addons/document/i18n/pt.po
index 76d8ee4c583..3fd385875df 100644
--- a/addons/document/i18n/pt.po
+++ b/addons/document/i18n/pt.po
@@ -7,51 +7,52 @@ msgstr ""
"Project-Id-Version: OpenERP Server 5.0.0\n"
"Report-Msgid-Bugs-To: support@openerp.com\n"
"POT-Creation-Date: 2009-08-28 16:01+0000\n"
-"PO-Revision-Date: 2009-09-16 15:41+0000\n"
-"Last-Translator: Fabien (Open ERP) <fp@tinyerp.com>\n"
+"PO-Revision-Date: 2009-11-29 23:37+0000\n"
+"Last-Translator: Paulino <Unknown>\n"
"Language-Team: \n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
-"X-Launchpad-Export-Date: 2009-11-17 05:18+0000\n"
+"X-Launchpad-Export-Date: 2009-11-30 04:38+0000\n"
"X-Generator: Launchpad (build Unknown)\n"
#. module: document
#: field:document.directory,create_date:0
msgid "Date Created"
-msgstr ""
+msgstr "Data de criação"
#. module: document
#: field:document.directory,ressource_id:0
msgid "Resource ID"
-msgstr ""
+msgstr "Id do recurso"
#. module: document
#: field:document.directory.content,include_name:0
msgid "Include Record Name"
-msgstr ""
+msgstr "Incluir Nome do Registo"
#. module: document
#: constraint:ir.model:0
msgid ""
"The Object name must start with x_ and not contain any special character !"
msgstr ""
-"O nome do objecto deve começar com x_ e não pode conter um carácter especial!"
+"O nome do objecto deve começar com x_ e não pode conter nenhum caracter "
+"especial!"
#. module: document
#: field:ir.actions.report.xml,model_id:0
msgid "Model Id"
-msgstr ""
+msgstr "ID do Modelo"
#. module: document
#: constraint:document.directory:0
msgid "Error! You can not create recursive Directories."
-msgstr "Erro! Não é possível criar directorias recursivos."
+msgstr "Erro! Não é possível criar pastas recursivamente."
#. module: document
#: model:ir.ui.menu,name:document.menu_document_configuration
msgid "Document Configuration"
-msgstr ""
+msgstr "Configuração de Documento"
#. module: document
#: view:ir.attachment:0
@@ -61,17 +62,17 @@ msgstr "Pré-visualizar"
#. module: document
#: field:ir.attachment,store_method:0
msgid "Storing Method"
-msgstr ""
+msgstr "Método de armazenamento"
#. module: document
#: model:ir.actions.act_window,name:document.action_config_auto_directory
msgid "Auto Configure Directory"
-msgstr ""
+msgstr "Auto-configurar pastas"
#. module: document
#: field:ir.attachment,file_size:0
msgid "File Size"
-msgstr ""
+msgstr "Tamanho do ficheiro"
#. module: document
#: help:document.directory.content,include_name:0
@@ -79,21 +80,23 @@ msgid ""
"Check this field if you want that the name of the file start by the record "
"name."
msgstr ""
+"Assinale este campo se quer que o nome dos ficheiros comece pelo nome do "
+"registo."
#. module: document
#: selection:document.directory,type:0
msgid "Other Resources"
-msgstr ""
+msgstr "Outros recursos"
#. module: document
#: field:document.directory,ressource_parent_type_id:0
msgid "Parent Model"
-msgstr ""
+msgstr "Modelo-Pai"
#. module: document
#: view:document.configuration.wizard:0
msgid "Document Management System."
-msgstr ""
+msgstr "Sistema de gestão documental"
#. module: document
#: view:ir.attachment:0
@@ -103,23 +106,23 @@ msgstr "Anexo"
#. module: document
#: constraint:ir.actions.act_window:0
msgid "Invalid model name in the action definition."
-msgstr ""
+msgstr "Nome de modelo inválido na definição da acção"
#. module: document
#: selection:document.directory,type:0
msgid "Static Directory"
-msgstr ""
+msgstr "Pasta estática"
#. module: document
#: model:ir.model,name:document.model_document_directory_content_type
msgid "Directory Content Type"
-msgstr ""
+msgstr "Tipo de conteúdo da pasta"
#. module: document
#: help:document.directory,domain:0
msgid ""
"Use a domain if you want to apply an automatic filter on visible resources."
-msgstr ""
+msgstr "Use um domínio se quer um filtro automático aos recursos visíveis"
#. module: document
#: help:document.directory,ressource_tree:0
@@ -127,59 +130,61 @@ msgid ""
"Check this if you want to use the same tree structure as the object selected "
"in the system."
msgstr ""
+"Assinale aqui se quer usar a mesma estrutura em árvore como a do objecto "
+"seleccionado no sistema"
#. module: document
#: field:document.directory,type:0
msgid "Type"
-msgstr ""
+msgstr "Tipo"
#. module: document
#: model:ir.actions.act_window,name:document.action_document_directory_tree
#: model:ir.ui.menu,name:document.menu_document_directories_tree
msgid "Directorie's Structure"
-msgstr ""
+msgstr "Estrutura de pastas"
#. module: document
#: field:document.directory,parent_id:0
msgid "Parent Item"
-msgstr ""
+msgstr "Item-pai"
#. module: document
#: view:ir.attachment:0
msgid "File Information"
-msgstr ""
+msgstr "Informação do Ficheiro"
#. module: document
#: field:document.directory,file_ids:0
#: view:ir.attachment:0
msgid "Files"
-msgstr ""
+msgstr "Ficheiros"
#. module: document
#: field:ir.attachment,store_fname:0
msgid "Stored Filename"
-msgstr ""
+msgstr "Ficheiro guardado"
#. module: document
#: field:document.directory,write_uid:0
#: field:ir.attachment,write_uid:0
msgid "Last Modification User"
-msgstr ""
+msgstr "Utilizador da última modificação"
#. module: document
#: view:document.configuration.wizard:0
msgid "Configure"
-msgstr ""
+msgstr "Configurar"
#. module: document
#: field:document.directory,ressource_tree:0
msgid "Tree Structure"
-msgstr ""
+msgstr "Estrutura em árvore"
#. module: document
#: field:ir.attachment,title:0
msgid "Resource Title"
-msgstr ""
+msgstr "Título do recurso"
#. module: document
#: model:ir.actions.todo,note:document.config_auto_directory
@@ -187,11 +192,13 @@ msgid ""
"This wizard will configure the URL of the server of the document management "
"system."
msgstr ""
+"Este assistente vai configurar o URL do servidor do sistema de gestão "
+"documental."
#. module: document
#: model:ir.model,name:document.model_document_directory_content
msgid "Directory Content"
-msgstr ""
+msgstr "Conteúdo da pasta"
#. module: document
#: help:document.directory,ressource_parent_type_id:0
@@ -199,32 +206,34 @@ msgid ""
"If you put an object here, this directory template will appear bellow all of "
"these objects. Don't put a parent directory if you select a parent model."
msgstr ""
+"Se colocar um objecto aqui, este modelo de pasta vai aparecer abaixo destes "
+"objectos. Não atribua uma pasta-mãe se seleccionou um modelo-pai."
#. module: document
#: model:ir.ui.menu,name:document.menu_document
msgid "Document Management"
-msgstr ""
+msgstr "Gestão documental"
#. module: document
#: selection:ir.attachment,store_method:0
msgid "Link"
-msgstr ""
+msgstr "Ligação"
#. module: document
#: view:document.directory:0
msgid "Directory Type"
-msgstr ""
+msgstr "Tipo de pasta"
#. module: document
#: field:document.directory,group_ids:0
#: field:ir.attachment,group_ids:0
msgid "Groups"
-msgstr ""
+msgstr "Grupos"
#. module: document
#: field:document.directory.content,report_id:0
msgid "Report"
-msgstr ""
+msgstr "Relatório"
#. module: document
#: help:document.configuration.wizard,host:0
@@ -232,6 +241,8 @@ msgid ""
"Put here the server address or IP. Keep localhost if you don't know what to "
"write."
msgstr ""
+"Coloque aqui o endereço do servidor ou o IP. Se não sabe, Deixe ficar "
+"\"localhost\"."
#. module: document
#: view:document.configuration.wizard:0
@@ -239,6 +250,8 @@ msgid ""
"This wizard will automatically configure the document management system "
"according to modules installed on your system."
msgstr ""
+"O assistente vai configurar automaticamente o sistema de gestão documental, "
+"de acordo com os módulos instalados."
#. module: document
#: view:ir.attachment:0
@@ -254,12 +267,12 @@ msgstr "Notas"
#: view:ir.attachment:0
#: field:ir.attachment,index_content:0
msgid "Indexed Content"
-msgstr ""
+msgstr "Conteúdo indexado"
#. module: document
#: view:document.directory:0
msgid "Definition"
-msgstr ""
+msgstr "Definição"
#. module: document
#: constraint:ir.ui.view:0
@@ -274,59 +287,63 @@ msgid ""
" * User Authentication\n"
" * Document Indexation\n"
msgstr ""
+"Este é um Sistema de gestão Documental completo:\n"
+" * Interface FTP\n"
+" * Autenticação dos utilizadores\n"
+" * Indexação dos documentos\n"
#. module: document
#: field:document.directory,name:0
msgid "Name"
-msgstr ""
+msgstr "Nome"
#. module: document
#: field:document.directory.content.type,code:0
msgid "Extension"
-msgstr ""
+msgstr "Extensão"
#. module: document
#: selection:ir.attachment,store_method:0
msgid "Database"
-msgstr ""
+msgstr "Base de dados"
#. module: document
#: field:document.directory,content_ids:0
msgid "Virtual Files"
-msgstr ""
+msgstr "Ficheiros virtuais"
#. module: document
#: view:document.directory:0
#: model:ir.ui.menu,name:document.menu_document_directories
msgid "Directories"
-msgstr ""
+msgstr "Pastas"
#. module: document
#: view:document.directory:0
msgid "Seq."
-msgstr ""
+msgstr "Seq."
#. module: document
#: model:ir.module.module,shortdesc:document.module_meta_information
msgid "Integrated Document Management System"
-msgstr ""
+msgstr "Sistema de gestão documental Integrado"
#. module: document
#: field:document.directory.content,directory_id:0
#: field:ir.attachment,parent_id:0
msgid "Directory"
-msgstr ""
+msgstr "Pasta"
#. module: document
#: field:document.directory,user_id:0
#: field:ir.attachment,user_id:0
msgid "Owner"
-msgstr ""
+msgstr "Dono"
#. module: document
#: model:ir.model,name:document.model_document_configuration_wizard
msgid "document.configuration.wizard"
-msgstr ""
+msgstr "document.configuration.wizard"
#. module: document
#: view:ir.attachment:0
@@ -336,35 +353,35 @@ msgstr "Ligado a"
#. module: document
#: selection:ir.attachment,store_method:0
msgid "Filesystem"
-msgstr ""
+msgstr "Sistema de ficheiros"
#. module: document
#: field:document.directory,file_type:0
#: field:document.directory.content.type,name:0
#: field:ir.attachment,file_type:0
msgid "Content Type"
-msgstr ""
+msgstr "Tipo de conteúdo"
#. module: document
#: view:document.directory:0
#: view:ir.attachment:0
msgid "Security"
-msgstr ""
+msgstr "Segurança"
#. module: document
#: model:ir.ui.menu,name:document.menu_document_browse
msgid "Browse Files Using FTP"
-msgstr ""
+msgstr "Navegue pelos ficheiros via FTP"
#. module: document
#: field:document.directory,ressource_type_id:0
msgid "Directories Mapped to Objects"
-msgstr ""
+msgstr "Pastas mapeadas aos objectos"
#. module: document
#: view:ir.attachment:0
msgid "History"
-msgstr ""
+msgstr "Histórico"
#. module: document
#: help:document.directory,ressource_type_id:0
@@ -372,100 +389,102 @@ msgid ""
"Select an object here and Open ERP will create a mapping for each of these "
"objects, using the given domain, when browsing through FTP."
msgstr ""
+"Seleccione um objecto aqui para o OpenERP mapear cada um destes objectos, "
+"usando o domínio dado, ao navegar por FTP."
#. module: document
#: view:ir.attachment:0
msgid "Others Info"
-msgstr ""
+msgstr "Outras Informações"
#. module: document
#: field:document.directory,domain:0
msgid "Domain"
-msgstr ""
+msgstr "Domínio"
#. module: document
#: field:document.directory,write_date:0
#: field:ir.attachment,write_date:0
msgid "Date Modified"
-msgstr ""
+msgstr "Data da modificação"
#. module: document
#: field:document.directory.content,suffix:0
msgid "Suffix"
-msgstr ""
+msgstr "Sufixo"
#. module: document
#: field:document.configuration.wizard,host:0
msgid "Server Address"
-msgstr ""
+msgstr "Endereço do servidor"
#. module: document
#: model:ir.actions.url,name:document.action_document_browse
msgid "Browse Files"
-msgstr ""
+msgstr "Naveguar pelos ficheiros"
#. module: document
#: field:document.directory.content,name:0
msgid "Content Name"
-msgstr ""
+msgstr "Nome do conteúdo"
#. module: document
#: model:ir.model,name:document.model_document_directory
#: field:process.node,directory_id:0
msgid "Document directory"
-msgstr ""
+msgstr "Pasta de documentos"
#. module: document
#: field:document.directory,create_uid:0
msgid "Creator"
-msgstr ""
+msgstr "Autor"
#. module: document
#: view:document.directory:0
msgid "Auto-Generated Files"
-msgstr ""
+msgstr "Ficheiros auto-gerados"
#. module: document
#: field:document.directory.content,sequence:0
msgid "Sequence"
-msgstr ""
+msgstr "Sequência"
#. module: document
#: model:ir.ui.menu,name:document.menu_document_files
msgid "Search a File"
-msgstr ""
+msgstr "Procure um ficheiro"
#. module: document
#: view:document.configuration.wizard:0
msgid "Auto Configure"
-msgstr ""
+msgstr "Auto-configurar"
#. module: document
#: view:document.configuration.wizard:0
msgid "Cancel"
-msgstr ""
+msgstr "Cancelar"
#. module: document
#: field:ir.attachment,partner_id:0
msgid "Partner"
-msgstr ""
+msgstr "Parceiro"
#. module: document
#: view:document.directory:0
msgid "PDF Report"
-msgstr ""
+msgstr "Relatório PDF"
#. module: document
#: field:document.directory.content,extension:0
msgid "Document Type"
-msgstr ""
+msgstr "Tipo de documento"
#. module: document
#: field:document.directory,child_ids:0
msgid "Children"
-msgstr ""
+msgstr "Dependentes"
#. module: document
#: view:document.directory:0
msgid "Contents"
-msgstr ""
+msgstr "Conteúdo"
diff --git a/addons/document/security/document_security.xml b/addons/document/security/document_security.xml
index 52b4e6de990..cddf24cddea 100644
--- a/addons/document/security/document_security.xml
+++ b/addons/document/security/document_security.xml
@@ -10,5 +10,17 @@
<field name="groups_id" eval="[(6,0,[ref('group_document_manager')])]"/>
</record>
+
+ <record model="ir.rule.group" id="document_directory_comp_rule_group">
+ <field name="name">Document Directory multi-company</field>
+ <field name="model_id" ref="model_document_directory"/>
+ <field name="global" eval="True"/>
+ </record>
+ <record model="ir.rule" id="document_directory_comp_rule">
+ <field name="field_id" search="[('model','=','document.directory'),('name','=','company_id')]" model="ir.model.fields"/>
+ <field name="rule_group" ref="document_directory_comp_rule_group"/>
+ <field name="domain_force">['|','|',('company_id','=',False),('company_id.child_ids','child_of',[user.company_id.id]),('company_id','child_of',[user.company_id.id])]</field>
+ </record>
+
</data>
</openerp>