帐套配置

您将创建示例所需的所有数据库字段元素。这些都是实现需求功能所必要的。

配置会计科目

You need to start off with a minimal set of accounts, and to do that you will need a couple of account types. You can structure your accounts into a chart at any time (and, in fact, you can structure them into several additional charts at the same time as you will see in the chapter 从 A 到 Z 配置科目), so you do not need to be concerned unduly about structure.

科目类型

Create account types using Accounting ‣ Configuration ‣ Financial Accounting ‣ Accounts ‣ Account Types and then clicking the New button. You will need the following four types, the first of which is shown in figure 新会计科目类型.

Defining Account Types

科目类型

类型CODE

P&L / BS分类

递延法

视图

视图

/

收入

收入

损益表(利润科目)

未对帐

支出

支出

损益表

未对帐

现金

现金

资产负债表(资产科目)

结余

/doc_static/6.0/_images/openerp_ch03_acctype.png

新会计科目类型

科目

新建科目 Accounting ‣ Configuration ‣ Financial Accounting ‣ Accounts ‣ Accounts and then clicking the New button.

需要会计科目来处理未付款的销售订单和采购订单,货物的收发两个以上,资金的收付款一个。还有这五个的一个 `组织’ 科目视图。所以需要如下6个会计科目,其中之一就是 :ref:`fig-oech03accts`啦。

Defining Accounts

名称

类型CODE

内部类型

上级科目

帐户类型

对账

最小的图

0

视图

 

视图

未选中

应付

无线AP

应付

最小的图 0

支出

已检查

应收

AR

应收

最小的图 0

收入

已检查

现金

C

流动资金

最小的图 0

现金

未选中

采购

P

常规、日常

最小的图 0

支出

未选中

销售

S

常规、日常

最小的图 0

收入

未选中

/doc_static/6.0/_images/openerp_ch03_accts.png

新帐户

The Account Type entry is taken from the list of types that you just created. Although it looks a bit like a text box, it does not behave in quite the same way. A single Del or Backspace keystroke is all you need to delete the whole text, and when you type the name (or part of the name), you still need to associate that text with the entry by clicking the Search icon to the right of the field.

属性

您正在定义一些默认属性,这样在每一次业务操作中就无需考虑该使用使用科目。有四个地方涉及主要的新属性,分别是伙伴的应收应付,产品类别的费用和收入。

Create properties using Administration ‣ Configuration ‣ Parameters ‣ Configuration Parameters and then clicking the New button. You may have switch to Extended view to be able to access this menu.

Defining Properties

名称

字段

类型

默认值

property_account_payable

应付账户

多对一(Many2One)

(account.account) AP应付

property_account_receivable

应收账户

多对一(Many2One)

(account.account) AR应收

property_account_expense_categ

费用账户

多对一(Many2One)

(account.account) P购买

property_account_income_categ

收入账户

多对一(Many2One)

(account.account) S 卖

小技巧

账号性质配置错误

在配置会计科目及特性的时候非常容易犯错,但是影响却不明显。当添加一个采购或销售订单 (见后文, 例如, 采购)时,会计科目是必填项,如果很勤奋的话,在创建合作伙伴的时候,都将很快发现这些错误。

如果你在这个阶段把他们配置好,你就不会知道后面的表单将会自动完成。如果你没有完全正确的把这些设置好,你将无法保存订单。解决办法就是更正之前配置错误的地方或者手动设置账户。

因为配置很单调,如果能够找到一个满足要求的配置好了的帐套就极好。

配置账簿

You will also need to configure some journals, which are used to record the transactions from one account to another when invoices are raised and then paid. Create journals from the menu Accounting ‣ Configuration ‣ Financial Accounting ‣ Journals ‣ Journals and then click the New button.

Defining Journals

日记账名称

类型CODE

类型

Display Mode

对象实体序列

默认借方科目

默认贷方科目

采购日记账

PUJ

采购

Sale/Purchase Journal View

采购日记账

P购买

P购买

销售日记账

SAJ

销售

Sale/Purchase Journal View

销售日记账

S 卖出

S 卖出

银行日记账

BNK

现金

Cash Journal View

账户日记

C 现金

C 现金

小技巧

配置错误日志

在配置账簿时也很容易出错,并且影响也不明显。通常在创建发票的时候会发现这个错误(发生在处理过程中的不同地方,取决于你的设置)。比如,确认一张基于采购订单的发票草稿(另一个例子,见后文, 采购),这时候就必须要有一个账簿。

如果在这里已经正确地配置了会计科目和类型,无法知道的情况下这些字段就会自动的填充。如果没有正确地配置好,那么相应的订单表单和草稿发票就会出现错误,直到纠正这些错误或者手动设置对应账簿。

配置公司信息

In case you had chosen to Skip Configuration Wizards when you first created the database, you may configure your company information in the following manner. Start configuring your database by renaming the Main Company from its default of OpenERP S.A. to the name of your own company or (in this case) another example company. When you print standard documents such as quotations, orders and invoices you will find this configuration information used in the document headers and footers.

To do this, click Sales ‣ Address Book ‣ Customers and click the name of the only company there, which is OpenERP S.A. . This gives you a read-only form view of the company, so make it editable by clicking the Edit button to the upper left of the form.

小技巧

Web客户端可编辑的表单

When toggling from the list view to the form view of an item, you can generally click its name in the list view to show a non-editable view, or the pencil icon by the left-hand edge of the line to open it in an editable view. You can toggle between editable and non-editable once you are in form view.

按下面的数据输入:

  • 名称 : Ambitious Plumbing Enterprises雄心水暖公司(就一公司名称) ,

  • Contact Name : George Turnbull .

保存前,点击 会计(Accounting) 页签查看伙伴的科目设置,应收账款(Account Receivable)应付账款(Account Payable) 字段从你刚刚建立的会计属性下带下来已经有了科目值。如果您不用该科目,可以录入其他更合适的科目,但OpenERP会限制您录入一些有意义的科目。

在第一个标签, General一般, 如您愿意,您可以作任何改动,例如地址啊电话号码等等,然后点击 :guilabel:`保存`按钮。

From the MAIN MENU, click Administration ‣ Companies ‣ Companies and edit the only entry there:

  • 公司名称 : AmbiPlum ,

  • Partner : 已显示为 Ambitious Plumbing Enterprises雄心水暖公司(就一公司名称) ,

  • Report Header : Ambitious Plumbing ,

  • Report Footer 1 : Best Plumbing Services, Great Prices ,

  • Report Footer 2 : Ambitious – our Registered Company Details .

Figure 修改公司详情 shows the effect of this. You can also change various other company-wide parameters for reports and scheduling in the other tabs, and you can upload a company logo of a specific size for the reports. Click Save to store this.

/doc_static/6.0/_images/openerp_ch03_co.png

修改公司详情

You can leave the currency at its default setting of EUR for this example. Or you can change it in this Company and the two default Pricelists (Sales ‣ Configuration ‣ Pricelists ‣ Pricelists) if you feel compelled to do that.

注解

货币

在本手册中的示例是使用 USD 美元和 EUR欧元作基础货币为例子来讲解滴。至于您,本手册读者,您可自行定夺 (也许使用 CAD, CNY人民币, GBP, 或Rs) 。

新建业务伙伴,伙伴分类及伙伴联系人

现在,您将创建一个供应商类别和客户类别。“合作伙伴类别”只是用来对合作伙伴进行分组,但是对他的操作没有影响。所以你可以按照你的喜好来划分。接下来你将设置一个供应商和一个客户,并为他们各自建立一个联系人。

To do this, use the menu Sales ‣ Configuration ‣ Address Book ‣ Partner Categories and click New to open a new form for defining Partner Categories. Define the two categories that follow by just entering their Category Name and saving them:

  • 供应商(Suppliers) ,

  • 客户(Customers) .

Then create two partners from the menu Sales ‣ Address Book ‣ Customers. Click on the New button to open a blank form and then add the following data for the first partner first:

  • 名称 : Plumbing Component Suppliers ,

  • Customer checkbox : unchecked ,

  • Supplier checkbox : checked ,

  • Contact Name : Jean Poolley ,

  • Address Type : Default ,

  • add Suppliers to the Partner Categories field by selecting it from the Search Partner Categories list,

  • 然后点击 保存(Save) 按钮保存业务伙伴。

新业务伙伴表单 显示了操作的结果。

/doc_static/6.0/_images/openerp_03_part.png

新业务伙伴表单

注解

Contact Types

If you have recorded several contacts for the same partner you can specify which contact is used for various documents by specifying the Address Type.

For example the delivery address can differ from the invoice address for a partner. If the Address Types are correctly assigned, then OpenERP can automatically select the appropriate address during the creation of the document – an invoice is addressed to the contact that has been assigned the Address Type of Invoice, otherwise to the Default address.

录入第二个合作伙伴的数据时,同录入第一个一样,参考下面的数据录入:

  • 姓名(Name) : Smith and Offspring,

  • Customer checkbox : checked,

  • Supplier checkbox : unchecked,

  • Contact Name : Stephen Smith,

  • Address Type : Default,

  • add Customers in the Categories field,

  • 保存(Save) 表单。

To check your work, you can go to the menu Sales ‣ Configuration ‣ Address Book ‣ Partner Categories and click on each category in turn to see the companies in the category.

注解

多业务伙伴分类

如果这个合作伙伴也是一个供应商,那么你就增加一个”供应商”类别,但在这演示中不是必须的.你可以把合作伙伴分配到多个层次结构的类别中.

新建商品信息及其分类

Unlike partner categories and their assigned partners, product categories do have an effect on the products assigned to them – and a product may belong to only one category. Under the main menu link Warehouse or Sale, select the menu Configuration ‣ Products ‣ Products Categories and click New to get an empty form for defining a product category.

Enter Radiators in the Name field. You will see that other fields, specifically those in the Accounting Properties section, have been automatically filled in with values of accounts and journals. These are the values that will affect products – equivalent fields in a product will take on these values if they, too, are blank when their form is saved. Click Save.

注解

属性字段

Properties have a rather unusual behavior. They are defined by parameters in the menus in Administration ‣ Configuration ‣ Parameters ‣ Configuration Parameters, and they update fields only when a form is saved, and only when the fields are empty at the time the form is saved. You can manually override any of these properties as you need.

属性字段应用于整个OpenERP系统,特别是经营多个公司的情景。在这种情景下,用户可以根据不同的公司在合作伙伴的表单中填写属性字段。

例如,对于以此分类,不同业务伙伴的付款条件可以不同。

注解

计量单位

UOM是计量单位的缩写。OpenERP为每个产品设有多种计量单位:例如,你可以用公斤和吨来收或售,OpenERP中的每个类别的转换是自动(只要你在产品设定之初已经建立的转化比率)。

小技巧

管理双测量单位

整个存储管理可以实现双单位计量(UOM和UOS,对销售单位)。举例,一个农业食品公司可以用单位‘块’来存储和销售火腿,但用重量来购买和估值。这两种单位之间没有直接关系,因此称重量的操作必须做。

这个功能是在农业食品行业至关重要,并且在制造业以及化学品和其他许多行业也是同样的重要。

现在可以进 仓库(Warehouse) 或者 销售Sale 菜单创建新的产品:

  1. 转到 Product产品菜单 ‣ Products产品 然后点击 New新建

  2. 新建一个产品类型:将 钛合金散热器 输入到 Name 栏位。

  3. Click the Search icon to the right of the Category field to select the Radiators category.

  4. 产品类型(Product Type) 字段使用 库存商品(Stockkable Product)。 生产方式(Procurement Method)供应方式(Supply method)库存单位(Default Unit Of Measure) 以及 采购单位(Purchase Unit Of Measure) 就使用默认值就好了。

  5. 输入 57.50 到 成本价 栏位,然后输入 132.50 到 销售价 栏位。

    /doc_static/6.0/_images/product.png

    Product Form

  6. Click the Accounting tab, then click Save and observe that Accounting Properties here remain empty. When product transactions occur, the Income and Expense accounts that you have just defined in the Product Category are used by the Product unless an account is specified here, directly in the product, to override that.

  7. 一旦产品保存后,它就变成不可编辑状态。如果已经输入的数据不正确或者必填区域留白的话,将弹出一个错误提示,表单将可编辑并且需要一个个点击表单的选项找到红色区域,然后正确填写。

配置库位信息

点击 仓库 ‣ 库存控制‣ 库位结构 来查看库位的层次结构. 这些是数据库被创建时已经定义的最基础的库位. 你将用这些默认的层次结构在这个例子里.

OpenERP有三个类型预定义的顶级库“物理库位”、“伙伴库位”和“虚拟库位”,其中前两种的用法顾名思义,另一个的设置是为了方便OpenERP使用。

  1. From the Main Menu click on Warehouse ‣ Configuration ‣ Warehouse Management ‣ Locations to reach a list view of the locations (not the tree view).

  2. Click on the name of a location, such as Physical Locations/OpenERP S.A. to open a descriptive form view. Each location has a Location Type and a Parent Location that defines the hierarchical structure. While you are here you should change the location’s name to Ambitious Plumbing Enterprises , since it was named before you changed the company name.

  3. From the Main Menu click Warehouse ‣ Configuration Warehouse Management ‣ Warehouses to view a list of warehouses. There is only the one at the moment, which should also be renamed from OpenERP S.A. to Ambitious Plumbing Enterprises .

对于销售的产品,仓库包括一个输入库位、存储库位和输出库位。你可以设置仓库地址来关联一个业务伙伴的库位。这并不一定是你自己的公司(虽然它可以是); 您可以轻松地指定可以用你的名义处理库位的其他合作伙伴。

注解

库位结构

每个仓库由三个库位组成 Location Input, Location Output, 和 Location Stock. ,`。 Location Stock 存储库位’及其子库位就是您的有效库位。

So the Location Input can be placed as a child of the Location Stock, which means that when Location Stock is interrogated for product quantities, it also takes account of the contents of the Location Input. Location Input could be used as a goods-in QC location. The Location Output must never be placed as a child of Location Stock, since items in Location Output, which can be considered to be packed ready for customer shipment, should not be thought of as available for sale elsewhere.

设置会计科目表

新建立账套的时候你可以设置一个科目表,但为了本次练习只需要你刚建立的少量科目(只是少数必须的科目,不包括分层,税或统计)。

A number of account charts have been predefined for OpenERP, some of which meet the needs of national authorities (the number of those created for OpenERP is growing as various contributors create and freely publish them). You can take one of those without changing it if it is suitable, or you can take anything as your starting point and design a complete chart of accounts to meet your exact needs, including accounts for inventory, asset depreciation, equity and taxation.

You can also run multiple charts of accounts in parallel – so you can put all of your transaction accounts into several charts, with different arrangements for taxation and depreciation, aggregated differently for various needs.

Before you can use any chart of accounts for anything, you need to specify a Fiscal Year. This defines the different time periods available for accounting transactions. An initial Fiscal Year was created during the database setup, so you do not need to do any more on this. You can also create a Fiscal Year manually from Accounting ‣ Configuration ‣ Financial Accounting ‣ Periods ‣ Fiscal Years.

进入菜单:会计(Accounting) ‣ 表(Charts) ‣ 科目一览表(Charts of Accounts) 就可以查看到定义的科目数据。 点击 打开一览表(Open Charts) 可以按科目层次结构来查看科目相关数据。

备份数据库帐套

在登陆页面点击 管理数据库 链接,进入帐套备份,输入正确的 超级管理员密码 后,将备份恢复为一个数据库名为 testing的帐套。

备份操作完成后,你就可以在帐套 testing帐套中进行各种测试,待各种测试均获通过后,则可以将帐套 openerp_ch03做为你生产环境的 live帐套或者 production帐套。

打这儿起, 若您有 admin 权限那么即会连接上这个名为 testing 的数据库。 If you have to make corrections, do that on openerp_ch03 and copy it to a new testing database to continue checking it.

Or you can just continue working with the openerp_ch03 database to get through this chapter. You can recreate openerp_ch03 quite quickly if something goes wrong and you cannot recover from it but, again, you would need to know your super-administrator password for that.