Types of names of plans in 1s. How to use the plan of types of characteristics in a request for skd

The plan of types of characteristics is a fairly simple object; earlier, when studying, when I analyzed examples in textbooks, it seemed complicated. immediately given in a compartment with other objects. These were examples of characteristics for an item or subconto. So what is PVC?

I think you are familiar with such concepts as Description of Types and Directory. If not, then take a look at the articles below before reading further, then everything will become clearer.

So let's continue. If you already know the Type Descriptions and References, then the Plan of types of characteristics is the Reference + Description of Types. As you can see, everything is simple. And this is the main idea, i.e. By itself, the plan of types of characteristics cannot implement the functionality of the characteristics of an item or subconto; for this, the properties and mechanisms of other objects are additionally used.

Let's take a look at how the characteristics functionality for an item is configured.

Task

So, we have a Nomenclature for which we need to set some additional properties, for example:

In this picture PVC will be responsible for the "Property" column and the value type in the "Value" column.

Those. Property - this will be the PVC element (maybe predefined), and the value type for the "Value" column will be the TypeDescription object that is present in each PVC element.

We create PVC

The picture above shows that the "Additional Values" directory is specified as an available type. This is another PVC functionality - specify a directory in which all the necessary properties can be stored. It is not necessarily possible and not to be specified, but this mechanism greatly facilitates the work. After all, as a rule, the properties and characteristics of the nomenclature are text values, and not other database objects. And all this will be stored in one place, also when creating a new element, only the Additional Features directory will be set by default.

To specify an additional directory, you must first install for this directory Owner of our pvc otherwise it will not be in the selection list, and then select it in the PVC properties on the "Basic" tab.

A little explanation about the work of PVC. First, on the "Basic" tab, we select all types available in this PVC in the "Type of characteristic value" field, and for the elements we set the value type already available in this PVC. In our case, for PVC, you can select only the reference book "Additional Values".

Create a register of information

Here we have created properties (PVC) and a reference book for storing values ​​(Additional Values), now we need to link the nomenclature and properties. For this, the information register is used, in our case it will have the following fields: dimensions "Nomenclature, PropertyNomenclature" and resource "ValueProperty"

If you are using managed form, it will be enough to add for the resource "Property Value" in the "Nomenclature Property Values" register Type connection with the "Nomenclature Property" field, and then, while editing the record of the information register, when selecting a value for the "Nomenclature Property" field, the value type in the "Property Value" field will change .

If you have usual application, then this connection, "Connection by type", will need to be configured in the form for the input field "Property Value" and at the same time it will be necessary to use the method " CastValue()" to get rid of redundant type selection and avoid erroneous situations:

Property value = PropertyNomenclature. ValueType. LeadValue(Property value);

Selection by owner

Because Since we have the "Additional Values" reference book subordinate to the "Nomenclature Properties" PVC, then you can set the filter so that when you select the Nomenclature Property in the "Property Value" field, you can select only from subordinate elements. For managed application, this is done in the properties of the resource, the property is called "Selection parameter associations" you need to select "Filter.Owner (ItemProperty)". For ordinary applications do not need to do anything. by setting Link by type, the program itself will show only subordinate elements.

Important! The "Link by type" property only works with attributes that have PVC type.

In custody

Thus, by means of the information register, we connected the "Nomenclature" reference book with its "Nomenclature Properties" PVC properties and its "Additional Values" reference book with its values.

Important! All the data we are interested in i.e. the characteristics of the nomenclature are stored in the register, and not in the PVC.

For ordinary applications have the ability to open the register, with the properties of the nomenclature by clicking on the "Go" button. we indicated that the "Nomenclature" dimension is "Leading".

For managed Apps have a link in the navigation bar

You guessed it, you can also go to the register and from PVC. dimension "PropertyNomenclature" is also leading.

Using the plan of types of characteristics, you can organize the storage of object properties that are not yet known at the time of configuration development. Those. the user can independently enter new properties, for example, color, size, dimensions, power. Each group of goods may have its own set of properties: for refrigerators - this is the volume of the freezer, the number of compressors, the noise level; for computers - the amount of RAM, the amount of hard disk; for clothes - size, height, color, etc. Then, based on these characteristics, you can build reports, analyze sales volume, and obtain valuable information for decision making.

An important feature of the chart of characteristic types, which distinguishes it from other objects, is its "Value Type" property. This property allows you to define a list of possible data types used for characteristic types. Those. a composite data type is usually used, while you can specify both primitive data types (number, string, date, boolean) and reference data types (CatalogReference, DocumentReference, etc.). For each type of characteristic, the type of values ​​from the list of selected types is indicated, for example, for the characteristic Supplier, select ReferenceReference.Contractors. The user can enter new characteristics in the "Enterprise" mode and specify the value type for them from the list of types specified in the configurator for the characteristic type plan.

Another important property of the plan of types of characteristics is the property "Additional values ​​of characteristics", in which a subordinate reference book is indicated, for example, Values ​​of ObjectsProperties, containing possible values ​​of characteristics. Usually this lookup is used by the user in the "Enterprise" mode when entering new types of characteristics for which there are no suitable lookups in the configuration, then the user can enter a list of possible values ​​for each type of characteristic in the ObjectsPropertiesValues ​​lookup.

As an example, you can see how the properties mechanism is implemented in the typical "Trade Management" configuration. The following objects are used for this:
- Plan of types of characteristics Properties of Objects, whose characteristic value type uses a composite data type, which includes primitive data types (number, string, date, boolean) and references to various application objects: directories, documents, enumerations.
- Reference ValuesPropertiesObjects, subordinate to the plan of types of characteristics ObjectsProperties. This reference contains a list of possible values ​​for this property, for example, a list of all colors for the "Color" property: red, green, white, and so on.
- Information register ValuesPropertiesObjects, which has dimensions Object (ReferenceReference, DocumentReference) and Property (ViewPlanCharacteristicsReference.ObjectProperties) and a Value resource that contains the value of a specific property for a specific object.

Note. To simplify understanding, the mechanism for assigning object properties is not affected here. This mechanism uses the attribute of the plan of types of characteristics and one more register of information.

Another important application of the plan of types of characteristics is the analytical accounting for subconto in accounting. In terms of characteristic types, predefined subconto types are entered, for example, counterparties, nomenclature, contracts, etc. These sub dimension types are then attached to the account stored in the chart of accounts. The user in the "Enterprise" mode can also enter new subcount types in the chart of characteristic types.

As an example, consider how subconto accounting is implemented in the demo configuration "Accounting" supplied on the ITS disk. The following objects are used for this:
- Plan of types of characteristics Types Subconto. Reference data types are used as value types. It is strongly not recommended to use primitive data types for accounting by subconto; this will reduce the performance of the system.
- Chart of accounts Basic, in which this plan of characteristic types is specified as the source of subcontol types
- Directory Subconto, subordinate to the plan of types of characteristics.

Currency accounting implies the reflection of operations on some accounts (usually these are settlement accounts) not only in the currency of regulated accounting (in rubles), but also in other currencies. When generating entries for such accounts, the ruble balance sheet indicator (that is, the one that is reflected in the debit of one account and the credit of another to ensure balance, equality of debit and credit balances and turnovers) is calculated based on the current (or specified in the document) exchange rate, which selected as the currency of mutual settlements with the counterparty. If the exchange rate changes, we are faced with the need to reassess the debt with the attribution of the exchange rate difference to the profit and loss account. If we talk about real accounting, then these procedures look more complicated, but their essence is reduced to the above operation.

Suppose we owe counterparty A $ 1000, at the time the debt arises, the dollar exchange rate is 30 rubles. Speaking in accounting terms, we get the following accounting entry:

D Materials K Settlements with suppliers 30,000 rubles. (1000$)

A month later, the dollar exchange rate changed to 31 rubles. If the debt to the supplier has not yet been repaid, then we, in fact, now owe him not 30,000, but 31,000 rubles. In order to reflect this difference in the accounting accounts, you can use the following posting (we repeat - only the essence of the real-life processes associated with the revaluation is reflected here)

D Profit and loss K Settlements with suppliers 1000 rub.

Please note that we make an accounting entry reflecting only the ruble amount, since it is she who changes when the exchange rate changes. Obviously, with the growth of the exchange rate, in this case, we received an "unexpected" loss in the amount of 1,000 rubles, although the amount of debt in foreign currency did not change. The opposite situation occurs when the exchange rate goes down. If at the time of the revaluation the dollar exchange rate is 29 rubles, we will get an "unexpected" profit:

D Settlements with suppliers K Profit and loss 1000 rubles.

In accounting, there are accounts called off-balance sheet. Such accounts are used to store information without double entry. For example, this may be information about fixed assets leased. The organization, on the one hand, must store information about them, on the other hand, they should not affect the state of the balance sheet, since they do not belong to the organization, it does not charge depreciation on these fixed assets. Therefore, such information is stored on off-balance accounts. Receipt entries for such accounts are made on the debit, expenditure entries - on the credit of the account. Off-balance accounts do not correspond with other accounts.

About analytics

Accounting can be maintained in one or more analytical sections. For example, for a material account, it is quite logical to provide a section Nomenclature, thanks to which you can find out exactly which item positions are taken into account on the account. It is logical to keep records of settlements with counterparties in the context of the counterparties themselves, and, possibly, contracts with counterparties, and currencies. Analytical sections it is accepted, in the terminology of 1C: Enterprise, to call subconto. The phrase "Subconto Nomenclature" should be understood as "Analytical section Nomenclature".

Objects 1C: Enterprise and accounting subsystem

To implement the accounting subsystem, we need the following objects 1C: Enterprise 8:

  1. Characteristic types plan. We will use it to store the types of analytics ( subconto ) that our accounts should have.
  2. Chart of accounts. This is the basis of the accounting subsystem. The Chart of Accounts stores the descriptions of the accounts on which accounting will be kept. Configurations can contain an unlimited number of plans of accounts, however, usually the number of plans of accounts in one configuration does not exceed 1-2. The Chart of Accounts can be compared to a special-purpose reference book, which is designed to store information about accounting accounts.
  3. Accounting register. It is associated with the chart of accounts and is used to store accounting records. Accounting register can be compared to a journal in which accounting records are kept.

When creating the accounting configuration subsystem, we first create plan of types of characteristics- it will need to be referenced when creating a chart of accounts, then - a chart of accounts - without specifying a chart of accounts, we will not be able to create accounting register.

Characteristic types plan

Let's create a new plan of types of characteristics, let's call it TypesSubconto, rice. 1.1


Rice. 1.1.

Characteristic types plan adds a new data type to the system, which is essentially a composite data type. This composite data type usually includes directories, the elements of which are ultimately used in analytical accounting. Characteristic values ​​can be supplied not only by directories, but also, for example, by documents and enumerations.

Add the created plan of types of characteristics into the subsystem Accounting.

When setting plan of types of characteristics its properties are of particular importance Feature value type And Additional characteristic values. They define a set of data types united by a plan of types of characteristics.

To properly set these properties, before continuing, let's create a new directory - let's call it Subconto.

Add a directory to the subsystem Accounting.

Let's choose on the tab Owners directory settings window, plan of types of characteristics TypesSubconto as the owner, set the parameter Using subordination into meaning Elements, rice. 1.2.


Rice. 1.2.

We will not configure other reference values, although this can be done if necessary. We need it in order not to limit the user of the configuration with subconto values ​​that he can set using the existing reference books specified in the plan of types of characteristics. In fact, this will allow the user to independently set the necessary analytical sections without resorting to system configuration and setting plan of types of characteristics.

Let's go to plan of types of characteristics, on the tab Main open its property Feature value type, rice. 1.3.


Rice. 1.3.

Check the box Composite data type, remove the checkbox Line(not recommended for use in plans of types of characteristics

This article describes the links between the plan of types of characteristics, the subordinate directory of additional characteristics and the information register, which stores the values ​​of characteristics.
I am studying 1C 8.2. In the audio course, Gileva reached the plan of types of characteristics. Before that, I read about PVC in several sources. Everything seems to be clear, but since I don’t program on 1s 8 yet, the theory is forgotten over time, and every time a topic about a plan of types of characteristics comes up, I have to painfully remember and build a diagram in my head. Now a specific question arose, everything swam in my head, and it became clear that again nothing was clear. Therefore, I had to deal with it in detail from the very beginning. I decided to write it down for myself, but maybe it will be useful to someone else.
Actually the question: I could not understand the meaning of the “Choice parameter links” property in the information register resource, where the values ​​of the characteristics of the item are stored (register structure: dimensions - item and type of property, resource - value)
The 2nd part of Gilev's video course can be downloaded for example here http://turbobit.net/8ztu277cf9t9/Gil_Base_02.rar.html. There is also a database file. In this article, I use chapters 404-409 of this video course

Feature Type Plan

The elements of this object store types of properties of something. The plan itself does not define what these properties will refer to. Of course, this can be reflected in the name of the plan (for example, the plan will be called “Property types of the item”), but in the configuration this will be determined only when creating a register of information to store property values ​​(in one of the dimensions of the register). In fact, in one plan, types of properties of different objects - goods, contractors, etc. can be defined. But probably more often for different objects their own PVC is created.

So, the plan stores the types of properties of something.

For example, property type - color, property type values ​​- blue, yellow. Property type - material, property type values ​​- leather, substitute.

In the property "Types of the value of characteristics" TYPES are set (and not the types themselves) values types of properties (types of characteristics). The names of the characteristics (properties) themselves are set either by the user or the developer as predefined in the configurator.

In the "Additional values ​​of characteristics" property, the NAME (and not a link) of the reference book, in which the property values ​​will be stored, is set. PVC is the owner of this guide.

Those. if you look at this directory without selection by owner, then there will be exactly the values ​​of all types of characteristics.

Let's open the form of this directory:

Here you can see that the values ​​\u200b\u200bof different properties are stored, both colors and materials. But each value has an owner - a type of property, or, in other words, an element of the plan of types of characteristics, i.e. everything is right here.

It seems to me that it would be more logical to name this property "Value type of additional characteristics" and set not a name, but a link to the reference book, as usual. Because if the user, when creating a new type of properties in the form of a plan, chooses that the value of this type will be an element of this directory, then this means that the value type is a directory.

Let's open the form of the plan of types of characteristics:

Here you can see that the user creates new types of properties, and selects their type from the provided list of types. The list of types, as I said, is set in the property "Types of characteristic values".

Property type - appearance date, value type - date

Property type - storekeeper, value type - link to the directory "Individuals"

If the user has created a “color” property type, then in the form of creating a plan element there will be a link on the right to go to the directory subordinate to the plan, in which the user must create color values. The directory form opens with selection by owner automatically, i.e. in the list form, only colors, not the values ​​of all properties, as in the first figure.


Rice. 4


Next, the information register being created, what it is for. It stores the kinds of properties, the values ​​of the properties, and what those properties refer to. Those. not properties by themselves, but in relation to some object. For example, the information register "Values ​​​​of the properties of goods" (I would call "Nomenclature properties"). Those. that a particular product "computer table" has a color - "blue", and there is a material - "oak". This will be 2 records of the information register:

Rice. 5


Register structure:

measurements- nomenclature and type of property (type - link to the plan).

Resource- value (type Characteristic is a virtual type that includes all types from the plan).

So, let's approach the question, what is this "Choice Parameter Relationships" property in the information register resource. There we have Selection. Owner (Property View). I could not understand what the selection refers to, and what kind of owner, owner of what? We don't know what type the value will be.

Let's go in order: I think that the selection is a property of the list form of the reference book "Custom characteristics"

The syntax helper says that the reference list has a "selection" property of the "selection" type (some properties in the syntax helper are in triangle brackets, they are not displayed in the article):

CatalogList.Directory name (CatalogList.Directory name)
Selection (Filter)

Type Selection:

Selection (Filter)
Collection elements:
ElementSelection
For an object, it is possible to traverse the collection using the operator For each ... From ... Loop. When traversing, selection elements are selected.
It is possible to access the selection element using the [...] operator. The index of the element is passed as an argument (numbering from 0).
Properties:
Filter element name

And the selection also has the property "Name of the selection element"

Those. in this case, the name of the selection element is Owner.

But the owner makes sense only for records in which the element of the "User characteristics" directory acts as a resource. From this I conclude that this property applies only to such records. Those. for records with property types "appearance date" and "storekeeper" it just doesn't make sense. Then everything falls into place.

For example, the information register entry form with a custom characteristic opens:

Rice. 6

If we go to the list form of the “Custom characteristics” reference book to select a color, then there, with the value of the “Selection parameter links” property set, Selection.Owner (PropertyView) will only have colors

Those. only such property values ​​are selected for which the property type is a color. (values ​​with owner "Color", not "Material", for example)

Those. the shape is the same as in the third picture.

The conclusion that the “Selection Parameter Relationships” property refers only to additional values ​​of characteristics confirms the fact that if we clear this property, this will only affect records with additional types of properties, and for example, when choosing a storekeeper, it always opens, like supposedly, a directory of individuals.

Loading...
Top