Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
AddToSpecification
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Брызгалов Сергей Александрович
AddToSpecification
Commits
30ae82ee
Commit
30ae82ee
authored
Apr 28, 2023
by
Брызгалов Сергей Александрович
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Small fix
parent
e9223d07
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
10 additions
and
5 deletions
+10
-5
581d7afe-2c9b-4e5c-80cd-e8c7a9ca333a.vsidx
...leContentIndex/581d7afe-2c9b-4e5c-80cd-e8c7a9ca333a.vsidx
+0
-0
7f6371aa-06ac-4c8e-81d3-c51404b09997.vsidx
...leContentIndex/7f6371aa-06ac-4c8e-81d3-c51404b09997.vsidx
+0
-0
a8632d66-84cd-4c06-b4ae-5aca8a31729d.vsidx
...leContentIndex/a8632d66-84cd-4c06-b4ae-5aca8a31729d.vsidx
+0
-0
.suo
.vs/AddToSpecification/v17/.suo
+0
-0
AddToSpecification.cs
AddToSpecification/AddToSpecification.cs
+10
-5
No files found.
.vs/AddToSpecification/FileContentIndex/581d7afe-2c9b-4e5c-80cd-e8c7a9ca333a.vsidx
0 → 100644
View file @
30ae82ee
File added
.vs/AddToSpecification/FileContentIndex/7f6371aa-06ac-4c8e-81d3-c51404b09997.vsidx
0 → 100644
View file @
30ae82ee
File added
.vs/AddToSpecification/FileContentIndex/a8632d66-84cd-4c06-b4ae-5aca8a31729d.vsidx
0 → 100644
View file @
30ae82ee
File added
.vs/AddToSpecification/v17/.suo
View file @
30ae82ee
No preview for this file type
AddToSpecification/AddToSpecification.cs
View file @
30ae82ee
...
...
@@ -41,7 +41,6 @@ namespace Actions
}
catch
(
Exception
ex
)
{
Log
.
Error
(
ex
);
}
}
...
...
@@ -104,6 +103,7 @@ namespace Actions
rndtBomHeader
.
LO
=
(
decimal
)
rndtRqLo
.
LO
;
}
}
var
attribute
=
newSpecification
.
Attributes
.
FirstOrDefault
(
c
=>
c
.
ShortDescription
==
"Curator"
);
if
(!(
attribute
is
null
))
{
...
...
@@ -164,11 +164,17 @@ namespace Actions
}
}
}
var
infoFieldFormulation
=
newSpecification
.
InfoCards
.
SelectMany
(
c
=>
c
.
InfoFields
).
FirstOrDefault
(
c
=>
c
.
ShortDescription
==
"FM_FormulaObjLink"
);
var
infoFieldFormulation
=
newSpecification
.
InfoCards
.
SelectMany
(
c
=>
c
.
InfoFields
)
.
FirstOrDefault
(
c
=>
c
.
ShortDescription
==
"FM_FormulaObjLink"
);
if
(
infoFieldFormulation
!=
null
)
{
var
connection
=
DatabaseContext
.
Database
.
Connection
;
var
serverName
=
connection
.
GetType
().
GetProperty
(
"WorkstationId"
).
GetValue
(
connection
,
null
)?.
ToString
().
ToLower
();
var
serverName
=
connection
.
GetType
()
.
GetProperty
(
"WorkstationId"
)
.
GetValue
(
connection
,
null
)?
.
ToString
()
.
ToLower
();
string
link
=
@"https://"
+
$"
{
serverName
}
"
+
@"/OpcenterRDnL/Wizards/OpenRequestWizard/Formulation?page=2&filter=[{%22field%22:%22RQ@RndvRq%22,%22operator%22:%22eq%22,%22value%22:%22"
+
...
...
@@ -178,10 +184,9 @@ namespace Actions
string
value
=
$"<a href=
{
link
}
>Рецептура</a>"
;
infoFieldFormulation
.
InfoFieldValue
=
value
;
}
DatabaseContext
.
SaveChanges
();
#
endregion
DatabaseContext
.
SaveChanges
();
Log
.
Warn
(
$"Specification
{
newSpecification
.
ID
}
created!"
);
}
else
if
(
aMaterial
.
ItemChanged
==
RnD
.
Common
.
Enums
.
NullableBool
.
True
&&
aSaveToSpecPref
==
aUpdateSpecPref
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment