Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@

Procedure BeforeWrite(Cancel, Replacing)
If Not FOServer.IsUseAccounting() Then
ThisObject.Clear();
EndIf;
EndProcedure
76 changes: 76 additions & 0 deletions IRP/src/Catalogs/Countries/Forms/ChoiceForm/Form.form
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@
</dataPath>
<defaultItem>true</defaultItem>
<titleLocation>None</titleLocation>
<excludedCommands>Create</excludedCommands>
<excludedCommands>Copy</excludedCommands>
<items xsi:type="form:FormField">
<name>Code</name>
<id>25</id>
Expand Down Expand Up @@ -300,13 +302,66 @@
<autoCommandBar>
<name>FormCommandBar</name>
<id>-1</id>
<items xsi:type="form:Button">
<name>FormChoose</name>
<id>32</id>
<visible>true</visible>
<enabled>true</enabled>
<userVisible>
<common>true</common>
</userVisible>
<extendedTooltip>
<name>FormChooseExtendedTooltip</name>
<id>33</id>
<type>Label</type>
<autoMaxWidth>true</autoMaxWidth>
<autoMaxHeight>true</autoMaxHeight>
<extInfo xsi:type="form:LabelDecorationExtInfo">
<horizontalAlign>Left</horizontalAlign>
</extInfo>
</extendedTooltip>
<commandName>Form.StandardCommand.Choose</commandName>
<representation>Auto</representation>
<defaultButton>true</defaultButton>
<autoMaxWidth>true</autoMaxWidth>
<autoMaxHeight>true</autoMaxHeight>
<placementArea>UserCmds</placementArea>
<representationInContextMenu>Auto</representationInContextMenu>
</items>
<items xsi:type="form:Button">
<name>FormLoadCountries</name>
<id>30</id>
<visible>true</visible>
<enabled>true</enabled>
<userVisible>
<common>true</common>
</userVisible>
<extendedTooltip>
<name>FormLoadCountriesExtendedTooltip</name>
<id>31</id>
<type>Label</type>
<autoMaxWidth>true</autoMaxWidth>
<autoMaxHeight>true</autoMaxHeight>
<extInfo xsi:type="form:LabelDecorationExtInfo">
<horizontalAlign>Left</horizontalAlign>
</extInfo>
</extendedTooltip>
<commandName>Form.Command.LoadCountries</commandName>
<representation>Auto</representation>
<autoMaxWidth>true</autoMaxWidth>
<autoMaxHeight>true</autoMaxHeight>
<placementArea>UserCmds</placementArea>
<representationInContextMenu>Auto</representationInContextMenu>
</items>
<horizontalAlign>Left</horizontalAlign>
<autoFill>true</autoFill>
</autoCommandBar>
<handlers>
<event>OnCreateAtServer</event>
<name>OnCreateAtServer</name>
</handlers>
<excludedCommands>Create</excludedCommands>
<excludedCommands>Copy</excludedCommands>
<windowOpeningMode>LockOwnerWindow</windowOpeningMode>
<saveWindowSettings>true</saveWindowSettings>
<autoTitle>true</autoTitle>
Expand Down Expand Up @@ -352,6 +407,27 @@ FROM
<getInvisibleFieldPresentations>true</getInvisibleFieldPresentations>
</extInfo>
</attributes>
<formCommands>
<name>LoadCountries</name>
<title>
<key>en</key>
<value>Load countries</value>
</title>
<id>1</id>
<use>
<common>true</common>
</use>
<picture xsi:type="core:PictureRef">
<picture>StdPicture.GotoExternalURL</picture>
</picture>
<action xsi:type="form:FormCommandHandlerContainer">
<handler>
<name>LoadCountries</name>
</handler>
</action>
<representation>TextPicture</representation>
<currentRowUse>Auto</currentRowUse>
</formCommands>
<commandInterface>
<navigationPanel/>
<commandBar/>
Expand Down
7 changes: 6 additions & 1 deletion IRP/src/Catalogs/Countries/Forms/ChoiceForm/Module.bsl
Original file line number Diff line number Diff line change
Expand Up @@ -33,4 +33,9 @@ Procedure InternalCommandActionWithServerContextAtServer(CommandName)
InternalCommandsServer.RunCommandAction(CommandName, ThisObject, List, Items.List.SelectedRows);
EndProcedure

#EndRegion
#EndRegion

&AtClient
Procedure LoadCountries(Command)
OpenForm("Catalog.Countries.Form.LoadCountries");
EndProcedure
6 changes: 3 additions & 3 deletions IRP/src/Catalogs/Countries/Forms/ListForm/Form.form
Original file line number Diff line number Diff line change
Expand Up @@ -404,9 +404,6 @@
<autoMaxWidth>true</autoMaxWidth>
<autoMaxHeight>true</autoMaxHeight>
<placementArea>UserCmds</placementArea>
<picture xsi:type="core:PictureRef">
<picture>StdPicture.GotoExternalURL</picture>
</picture>
<representationInContextMenu>Auto</representationInContextMenu>
</items>
<horizontalAlign>Left</horizontalAlign>
Expand Down Expand Up @@ -574,6 +571,9 @@ FROM
<use>
<common>true</common>
</use>
<picture xsi:type="core:PictureRef">
<picture>StdPicture.GotoExternalURL</picture>
</picture>
<action xsi:type="form:FormCommandHandlerContainer">
<handler>
<name>LoadCountries</name>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -66,6 +66,7 @@
</type>
<minValue xsi:type="core:UndefinedValue"/>
<maxValue xsi:type="core:UndefinedValue"/>
<fillChecking>ShowError</fillChecking>
<fillValue xsi:type="core:UndefinedValue"/>
<fullTextSearch>Use</fullTextSearch>
<dataHistory>Use</dataHistory>
Expand All @@ -81,6 +82,7 @@
</type>
<minValue xsi:type="core:UndefinedValue"/>
<maxValue xsi:type="core:UndefinedValue"/>
<fillChecking>ShowError</fillChecking>
<fillValue xsi:type="core:UndefinedValue"/>
<fullTextSearch>Use</fullTextSearch>
<dataHistory>Use</dataHistory>
Expand All @@ -96,6 +98,7 @@
</type>
<minValue xsi:type="core:UndefinedValue"/>
<maxValue xsi:type="core:UndefinedValue"/>
<fillChecking>ShowError</fillChecking>
<fillValue xsi:type="core:UndefinedValue"/>
<fullTextSearch>Use</fullTextSearch>
<dataHistory>Use</dataHistory>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

Procedure BeforeWrite(Cancel, WriteMode, PostingMode)
If DataExchange.Load Then
Return;
Expand All @@ -14,4 +15,14 @@ Procedure BeforeDelete(Cancel)
If DataExchange.Load Then
Return;
EndIf;
EndProcedure
EndProcedure

Procedure FillCheckProcessing(Cancel, CheckedAttributes)
If ThisObject.Ref = ChartsOfCharacteristicTypes.CurrencyMovementType.SettlementCurrency
Or ThisObject.Ref = ChartsOfCharacteristicTypes.CurrencyMovementType.Default_Legal
Or ThisObject.Ref = ChartsOfCharacteristicTypes.CurrencyMovementType.Default_PartnerTerm Then
CommonFunctionsClientServer.DeleteValueFromArray(CheckedAttributes, "Currency");
CommonFunctionsClientServer.DeleteValueFromArray(CheckedAttributes, "Source");
CommonFunctionsClientServer.DeleteValueFromArray(CheckedAttributes, "Type");
EndIf;
EndProcedure
1 change: 1 addition & 0 deletions IRP/src/CommonModules/Localization/Module.bsl
Original file line number Diff line number Diff line change
Expand Up @@ -1812,6 +1812,7 @@ Function Strings(Lang) Export
Strings.Insert("Error_197", NStr("en = 'Last line should contain 0 in to days'", Lang));
Strings.Insert("Error_198", NStr("en = 'From days and to days cannot be equal to zero'", Lang));
Strings.Insert("Error_199", NStr("en = 'From days and to days cannot be equal'", Lang));
Strings.Insert("Error_200", NStr("en = 'Not set currency rate: from [%1] to [%2] source [%3]'", Lang));



Expand Down
8 changes: 7 additions & 1 deletion IRP/src/CommonModules/PostingServer/Module.bsl
Original file line number Diff line number Diff line change
Expand Up @@ -1253,7 +1253,7 @@ EndFunction

Function UseRegister(Name) Export
// Delete CashInTransit
Return Mid(Name, 7, 1) = "_" Or Mid(Name, 4, 1) = "_" Or Mid(Name, 3, 1) = "_";
Return Mid(Name, 7, 1) = "_" Or Mid(Name, 4, 1) = "_" Or Mid(Name, 3, 1) = "_";
EndFunction

Procedure ExecuteQuery(Ref, QueryArray, Parameters) Export
Expand Down Expand Up @@ -1456,6 +1456,12 @@ EndFunction
Procedure FillPostingTables(Tables, Ref, QueryArray, Parameters) Export
ExecuteQuery(Ref, QueryArray, Parameters);
For Each VT In Tables Do
If Upper(VT.Key) = Upper("T1040T_AccountingAmounts") Or Upper(VT.Key) = Upper("T1050T_AccountingQuantities") Then
If Not FOServer.IsUseAccounting() Then
Continue;
EndIf;
EndIf;

QueryTable = GetQueryTableByName(VT.Key, Parameters);
If QueryTable.Count() Then
CommonFunctionsServer.MergeTables(Tables[VT.Key], QueryTable, "RecordType");
Expand Down
37 changes: 37 additions & 0 deletions IRP/src/Documents/ForeignCurrencyRevaluation/ManagerModule.bsl
Original file line number Diff line number Diff line change
Expand Up @@ -535,6 +535,43 @@ Function PostingGetDocumentDataTables(Ref, Cancel, PostingMode, Parameters, AddI
Query.SetParameter("Company", Ref.Company);
Query.Execute();

Query = New Query;
Query.TempTablesManager = Parameters.TempTablesManager;
Query.Text =
"SELECT
| UniqueCurrencyPairs.CurrencyFrom,
| UniqueCurrencyPairs.CurrencyTo,
| UniqueCurrencyPairs.Source,
| CurrencyRatesSliceLast.Rate
|FROM
| UniqueCurrencyPairs AS UniqueCurrencyPairs
| LEFT JOIN InformationRegister.CurrencyRates.SliceLast(&PeriodSliceLast, (CurrencyFrom, CurrencyTo, Source) IN
| (SELECT
| UniqueCurrencyPairs.CurrencyFrom,
| UniqueCurrencyPairs.CurrencyTo,
| UniqueCurrencyPairs.Source
| FROM
| UniqueCurrencyPairs AS UniqueCurrencyPairs)) AS CurrencyRatesSliceLast
| ON UniqueCurrencyPairs.CurrencyFrom = CurrencyRatesSliceLast.CurrencyFrom
| AND UniqueCurrencyPairs.CurrencyTo = CurrencyRatesSliceLast.CurrencyTo
| AND UniqueCurrencyPairs.Source = CurrencyRatesSliceLast.Source
|WHERE
| CurrencyRatesSliceLast.Rate IS NULL
| and UniqueCurrencyPairs.CurrencyFrom <> UniqueCurrencyPairs.CurrencyTo";

Query.SetParameter("PeriodSliceLast", DocumentDate);
QueryResult = Query.Execute();
QuerySelection = QueryResult.Select();

While QuerySelection.Next() Do
CommonFunctionsClientServer.ShowUsersMessage(StrTemplate(R().Error_200,
QuerySelection.CurrencyFrom, QuerySelection.CurrencyTo, QuerySelection.Source));
EndDo;
If QuerySelection.Count() > 0 Then
Cancel = True;
Return New Structure();
EndIf;

CurrencyRates = Parameters.TempTablesManager.Tables.Find("CurrencyRates").GetData().Unload();

ArrayOfActives = New Array();
Expand Down
1 change: 1 addition & 0 deletions features/External/ImportData.feature
Original file line number Diff line number Diff line change
Expand Up @@ -635,6 +635,7 @@ Scenario: Create chart of characteristic types CurrencyMovementType objects
| 'e1cib/data/ChartOfCharacteristicTypes.CurrencyMovementType?ref=aa78120ed92fbced11eaf128cde918b4' | 'False' | 'e1cib/data/Catalog.Currencies?ref=aa78120ed92fbced11eaf113ba6c1857' | 'e1cib/data/Catalog.IntegrationSettings?ref=aa78120ed92fbced11eaf113ba6c1859' | 'Enum.CurrencyType.Reporting' | 'False' | 'Reporting currency Euro'| '' | '' | '' |



Scenario: Create catalog Currencies objects

And I check or create catalog "Currencies" objects:
Expand Down
34 changes: 34 additions & 0 deletions features/External/Landed cost/ImportCatalogsMultiCurrency.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
#language: en
@tree
@IgnoreOnCIMainBuild
@ExportScenarios

Feature: export scenarios (multi currency landed cost)

Background:
Given I launch TestClient opening script or connect the existing one

Scenario: Create information register CurrencyRates records (MC)

And I check or create information register "CurrencyRates" records:
| 'Period' | 'CurrencyFrom' | 'CurrencyTo' | 'Source' | 'Multiplicity' | 'Rate' |
| '01.02.2025 00:00:00' | 'e1cib/data/Catalog.Currencies?ref=86ffd69b4676df1211ea9f63629ef589' | 'e1cib/data/Catalog.Currencies?ref=86ffd69b4676df1211ea9f63629ef588' | 'e1cib/data/Catalog.IntegrationSettings?ref=86ffd69b4676df1211ea9f6381ded747' | '1' | '40' |
| '01.02.2025 00:00:00' | 'e1cib/data/Catalog.Currencies?ref=86ffd69b4676df1211ea9f63629ef588' | 'e1cib/data/Catalog.Currencies?ref=86ffd69b4676df1211ea9f63629ef589' | 'e1cib/data/Catalog.IntegrationSettings?ref=86ffd69b4676df1211ea9f6381ded747' | '1' | '0,025' |

Scenario: Create catalog Items objects (MC)

And I check or create for catalog "Items" objects with Data Exchange Load parameter set to true:
| 'Ref' | 'DeletionMark' | 'Code' | 'ItemType' | 'Unit' | 'MainPricture' | 'Vendor' | 'ItemID' | 'Description_en' | 'Description_hash' | 'Description_ru' | 'Description_tr' | 'Length' | 'Width' | 'Height' | 'Volume' | 'Weight' |
| 'e1cib/data/Catalog.Items?ref=aabbccdd4676df1211ea9f67cc000001' | 'No' | '0' | 'e1cib/data/Catalog.ItemTypes?ref=86ffd69b4676df1211ea9f66bce7e209' | 'e1cib/data/Catalog.Units?ref=aa78120ed92fbced11eaf113ba6c1862' | 'ValueStorage' | '' | '' | 'MC Item A' | '' | '' | 'MC Item A' | '0' | '0' | '0' | '0' | '0' |
| 'e1cib/data/Catalog.Items?ref=aabbccdd4676df1211ea9f67cc000002' | 'No' | '0' | 'e1cib/data/Catalog.ItemTypes?ref=86ffd69b4676df1211ea9f66bce7e209' | 'e1cib/data/Catalog.Units?ref=aa78120ed92fbced11eaf113ba6c1862' | 'ValueStorage' | '' | '' | 'MC Item B' | '' | '' | 'MC Item B' | '0' | '0' | '0' | '0' | '0' |
| 'e1cib/data/Catalog.Items?ref=aabbccdd4676df1211ea9f67cc000003' | 'No' | '0' | 'e1cib/data/Catalog.ItemTypes?ref=86ffd69b4676df1211ea9f66bce7e209' | 'e1cib/data/Catalog.Units?ref=aa78120ed92fbced11eaf113ba6c1862' | 'ValueStorage' | '' | '' | 'MC Item C' | '' | '' | 'MC Item C' | '0' | '0' | '0' | '0' | '0' |
| 'e1cib/data/Catalog.Items?ref=aabbccdd4676df1211ea9f67cc000004' | 'No' | '0' | 'e1cib/data/Catalog.ItemTypes?ref=86ffd69b4676df1211ea9f77cc8a03c4' | 'e1cib/data/Catalog.Units?ref=aa78120ed92fbced11eaf113ba6c1862' | 'ValueStorage' | '' | '' | 'MC Work' | '' | '' | 'MC Work' | '0' | '0' | '0' | '0' | '0' |

Scenario: Create catalog ItemKeys objects (MC)

And I check or create for catalog "ItemKeys" objects with Data Exchange Load parameter set to true:
| 'Ref' | 'DeletionMark' | 'Code' | 'Item' | 'Unit' | 'Specification' | 'AffectPricingMD5' | 'UniqueMD5' | 'ItemKeyID' | 'Description_en' | 'Description_hash' | 'Description_ru' | 'Description_tr' | 'Height' | 'Length' | 'Volume' | 'Weight' | 'Width' |
| 'e1cib/data/Catalog.ItemKeys?ref=aabbccdd4676df1211ea9f67cd000001' | 'False' | '0' | 'e1cib/data/Catalog.Items?ref=aabbccdd4676df1211ea9f67cc000001' | '' | '' | 'AA 01 F1 8F 7F D7 7D 0E E3 D5 A9 97 81 3F E0 01' | 'AA 01 F1 8F 7F D7 7D 0E E3 D5 A9 97 81 3F E0 01' | '' | 'MC Item A' | '' | '' | 'MC Item A' | '0' | '0' | '0' | '0' | '0' |
| 'e1cib/data/Catalog.ItemKeys?ref=aabbccdd4676df1211ea9f67cd000002' | 'False' | '0' | 'e1cib/data/Catalog.Items?ref=aabbccdd4676df1211ea9f67cc000002' | '' | '' | 'AA 02 F1 8F 7F D7 7D 0E E3 D5 A9 97 81 3F E0 02' | 'AA 02 F1 8F 7F D7 7D 0E E3 D5 A9 97 81 3F E0 02' | '' | 'MC Item B' | '' | '' | 'MC Item B' | '0' | '0' | '0' | '0' | '0' |
| 'e1cib/data/Catalog.ItemKeys?ref=aabbccdd4676df1211ea9f67cd000003' | 'False' | '0' | 'e1cib/data/Catalog.Items?ref=aabbccdd4676df1211ea9f67cc000003' | '' | '' | 'AA 03 F1 8F 7F D7 7D 0E E3 D5 A9 97 81 3F E0 03' | 'AA 03 F1 8F 7F D7 7D 0E E3 D5 A9 97 81 3F E0 03' | '' | 'MC Item C' | '' | '' | 'MC Item C' | '0' | '0' | '0' | '0' | '0' |
| 'e1cib/data/Catalog.ItemKeys?ref=aabbccdd4676df1211ea9f67cd000004' | 'False' | '0' | 'e1cib/data/Catalog.Items?ref=aabbccdd4676df1211ea9f67cc000004' | '' | '' | 'AA 04 F1 8F 7F D7 7D 0E E3 D5 A9 97 81 3F E0 04' | 'AA 04 F1 8F 7F D7 7D 0E E3 D5 A9 97 81 3F E0 04' | '' | 'MC Work' | '' | '' | 'MC Work' | '0' | '0' | '0' | '0' | '0' |
70 changes: 69 additions & 1 deletion features/External/Podgotovka.feature
Original file line number Diff line number Diff line change
Expand Up @@ -1654,7 +1654,14 @@ Scenario: set True value to the constant Use accounting
Then "Functional option settings" window is opened
And I set checkbox "Use accounting"
And I click "Save" button
And I close current window
And I close current window

Scenario: set False value to the constant Use accounting
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Then "Functional option settings" window is opened
And I remove checkbox "Use accounting"
And I click "Save" button
And I close current window

Scenario: set True value to the constant Use job queue for external functions
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Expand Down Expand Up @@ -1693,6 +1700,67 @@ Scenario: set True value to the constant UseSimpleMode
And I execute 1C:Enterprise script at server
| "Constants.UseSimpleMode.Set(True);" |

Scenario: set False value to the constant UseSimpleMode
And I execute 1C:Enterprise script at server
| "Constants.UseSimpleMode.Set(False);" |

Scenario: set True value to the constant Use batch relevance
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Then "Functional option settings" window is opened
And I set checkbox "Use batch relevance"
And I click "Save" button
And I close current window

Scenario: set False value to the constant Use batch relevance
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Then "Functional option settings" window is opened
And I remove checkbox "Use batch relevance"
And I click "Save" button
And I close current window

Scenario: set True value to the constant Use advance relevance
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Then "Functional option settings" window is opened
And I set checkbox "Use advance relevance"
And I click "Save" button
And I close current window

Scenario: set False value to the constant Use advance relevance
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Then "Functional option settings" window is opened
And I remove checkbox "Use advance relevance"
And I click "Save" button
And I close current window

Scenario: set True value to the constant Use batch reallocate
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Then "Functional option settings" window is opened
And I set checkbox "Use batch reallocate"
And I click "Save" button
And I close current window

Scenario: set False value to the constant Use batch reallocate
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Then "Functional option settings" window is opened
And I remove checkbox "Use batch reallocate"
And I click "Save" button
And I close current window

Scenario: set True value to the constant Use preliminary stock
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Then "Functional option settings" window is opened
And I set checkbox "Use shipment and receipt planing orders"
And I set checkbox " - Use preliminary stock"
And I click "Save" button
And I close current window

Scenario: set False value to the constant Use preliminary stock
Given I open hyperlink "e1cib/app/DataProcessor.FunctionalOptionSettings"
Then "Functional option settings" window is opened
And I remove checkbox " - Use preliminary stock"
And I click "Save" button
And I close current window


Scenario: add VAExtension
Given I open hyperlink "e1cib/list/Catalog.Extensions"
Expand Down
Loading