Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
csbr-daop
/
fe-data-trusted-space
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
8f3c06d1
authored
2025-02-11 13:30:18 +0800
by
lxs
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'develop' into release-test
2 parents
d30c0b77
810718ac
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
516 additions
and
409 deletions
components.d.ts
src/components/CarouselPanel/index.ts
src/components/CarouselPanel/src/CarouselPanel.vue
src/components/Form/index.vue
src/types/components.d.ts
src/views/data_asset/registerDetail.vue
src/views/data_asset/registerManagemant.vue
src/views/data_asset/registerStart.vue
src/views/data_transaction/entryManagement.vue
components.d.ts
View file @
8f3c06d
...
...
@@ -12,6 +12,7 @@ declare module '@vue/runtime-core' {
ApprovalProcess
:
typeof
import
(
'./src/components/ApprovalProcess/src/ApprovalProcess.vue'
)[
'default'
]
Auth
:
typeof
import
(
'./src/components/Auth/index.vue'
)[
'default'
]
AuthAll
:
typeof
import
(
'./src/components/AuthAll/index.vue'
)[
'default'
]
CarouselPanel
:
typeof
import
(
'./src/components/CarouselPanel/src/CarouselPanel.vue'
)[
'default'
]
ContentWrap
:
typeof
import
(
'./src/components/ContentWrap/src/ContentWrap.vue'
)[
'default'
]
Copyright
:
typeof
import
(
'./src/components/Copyright/index.vue'
)[
'default'
]
Day
:
typeof
import
(
'./src/components/Schedule/component/day.vue'
)[
'default'
]
...
...
src/components/CarouselPanel/index.ts
0 → 100644
View file @
8f3c06d
import
CarouselPanel
from
'./src/CarouselPanel.vue'
export
{
CarouselPanel
}
src/components/CarouselPanel/src/CarouselPanel.vue
0 → 100644
View file @
8f3c06d
<
script
setup
lang=
"ts"
>
import
{
ElCarousel
,
ElCarouselItem
}
from
"element-plus"
;
import
{
CaretBottom
,
CaretRight
}
from
"@element-plus/icons-vue"
;
const
props
=
defineProps
({
carouselInfo
:
{
type
:
Object
,
default
:
()
=>
{
},
},
});
const
emits
=
defineEmits
([
"carouselChange"
]);
const
carouselChange
=
(
current
:
number
,
prev
:
number
)
=>
{
emits
(
"carouselChange"
,
current
);
};
</
script
>
<
template
>
<el-carousel
:height=
"carouselInfo.height ?? '150px'"
:indicator-position=
"carouselInfo.indicatorPosition ?? 'none'"
:arrow=
"carouselInfo.arrow ?? 'hover'"
:trigger=
"carouselInfo.trigger ?? 'hover'"
:loop=
"carouselInfo.loop ?? true"
:autoplay=
"carouselInfo.autoplay ?? true"
:initial-index=
"carouselInfo.initialIndex ?? 0"
@
change=
"carouselChange"
>
<el-carousel-item
class=
"carousel-item"
:class=
"[carouselInfo.itemClass]"
v-for=
"(item, i) in carouselInfo.list"
:key=
"'carousel' + i"
>
<slot
:carousel=
"item"
></slot>
</el-carousel-item>
</el-carousel>
</
template
>
<
style
lang=
"scss"
scoped
></
style
>
src/components/Form/index.vue
View file @
8f3c06d
...
...
@@ -617,7 +617,7 @@ const panelChange = (scope, row) => {
required_mark: item.required,
}">
{{
item
.
label
}}
</span>
}}
</span>
</span>
<div
class=
"header_title_tooltip"
style=
"width: auto"
v-if=
"item.tooltip"
>
...
...
@@ -710,7 +710,7 @@ const panelChange = (scope, row) => {
<div
class=
"item_panel"
:class=
"
{ is_block: panel.block }" v-for="panel in item.children">
<label
:class=
"
{ required_mark: panel.required }">
{{
panel
.
label
}}
</label>
}}
</label>
<el-checkbox
v-if=
"panel.type == 'checkbox'"
v-model=
"formInline[panel.field]"
:disabled=
"panel.disabled || readonly"
:true-label=
"panel.trueValue ?? true"
:false-label=
"panel.falseValue ?? false"
>
{{
panel
.
placeholder
}}
</el-checkbox>
...
...
@@ -793,7 +793,7 @@ const panelChange = (scope, row) => {
<span
class=
"item-label"
slot=
"label"
>
<span
v-if=
"child.label"
:class=
"{ required_mark: child.required }"
>
{{
child.label
}}
</span>
}}
</span>
</span>
<el-select
v-if=
"child.type == 'select'"
v-model=
"formInline[child.field]"
:placeholder=
"child.placeholder"
:disabled=
"child.disabled || readonly"
:filterable=
"child.filterable"
...
...
@@ -852,7 +852,7 @@ const panelChange = (scope, row) => {
<span
class=
"item-label"
slot=
"label"
>
<span
:class=
"
{ required_mark: child.required }">
{{
child
.
label
}}
</span>
}}
</span>
</span>
<el-cascader
v-if=
"child.type == 'cascader'"
v-model=
"formInline[child.field]"
:props=
"child.props"
:options=
"child.options"
:show-all-levels=
"child.showAllLevels ?? true"
...
...
@@ -895,7 +895,7 @@ const panelChange = (scope, row) => {
<div
class=
"item_panel"
v-for=
"child in item.children"
>
<label
:class=
"{ required_mark: child.required }"
>
{{
child.label
}}
</label>
}}
</label>
<div
class=
"tool_item"
>
<el-select
v-model=
"formInline[child.field]"
:class=
"{ is_block: child.block }"
:placeholder=
"child.placeholder"
:multiple=
"child.multiple"
:collapse-tags=
"child.collapse"
...
...
@@ -970,7 +970,7 @@ const panelChange = (scope, row) => {
<span
class=
"item-label"
slot=
"label"
>
<span
:class=
"
{ required_mark: child.required }">
{{
child
.
label
}}
</span>
}}
</span>
</span>
<el-input
:class=
"[child.col,
{ is_block: child.block }]" v-model="formInline[child.field]"
:rows="child.rows ?? 4" type="textarea" :placeholder="child.placeholder"
...
...
@@ -1026,7 +1026,7 @@ const panelChange = (scope, row) => {
<span
class=
"item-label"
slot=
"label"
>
<span
:class=
"
{ required_mark: child.required }">
{{
child
.
label
}}
</span>
}}
</span>
</span>
<div
class=
"input_group"
:class=
"[child.col]"
v-if=
"child.type == 'input-group'"
>
<template
v-for=
"(group, c) in child.children"
>
...
...
@@ -1035,13 +1035,14 @@ const panelChange = (scope, row) => {
<span
class=
"item-label"
slot=
"label"
>
<span
:class=
"
{ required_mark: group.required }">
{{
group
.
label
}}
</span>
}}
</span>
</span>
<el-select
v-if=
"group.type == 'select'"
v-model=
"formInline[group.field]"
:placeholder=
"group.placeholder"
:clearable=
"group.clearable"
:disabled=
"group.disabled || readonly"
:filterable=
"group.filterable"
:multiple=
"group.multiple ?? false"
:collapse-tags=
"group.collapse ?? false"
:collapse-tags-tooltip=
"group.tagsTooltip ?? false"
:collapse-tags-tooltip=
"group.tagsTooltip ?? false"
:allow-create=
"group.allowCreate ?? false"
:default-first-option=
"group.allowCreate ?? false"
@
change=
"(val) => selectChange(val, group)"
>
<el-option
v-for=
"opts in group.options"
:label=
"group.props?.label ? opts[group.props.label] : opts.label"
...
...
@@ -1176,7 +1177,7 @@ const panelChange = (scope, row) => {
<span
class=
"item-label"
slot=
"label"
>
<span
:class=
"
{ required_mark: child.required }">
{{
child
.
label
}}
</span>
}}
</span>
</span>
<el-select
v-if=
"child.type == 'select'"
v-model=
"formInline[child.field]"
:placeholder=
"child.placeholder"
:clearable=
"child.clearable"
:disabled=
"child.disabled || readonly"
...
...
@@ -1227,7 +1228,7 @@ const panelChange = (scope, row) => {
<span
class=
"item-label"
slot=
"label"
:class=
"[child.col]"
>
<span
:class=
"
{ required_mark: child.required }">
{{
child
.
label
}}
</span>
}}
</span>
</span>
<div
class=
"input_popover_panel"
v-if=
"child.type == 'input-popover-panel'"
>
<el-popover
placement=
"bottom-start"
width=
"100%"
trigger=
"click"
:teleported=
"false"
>
...
...
@@ -1281,7 +1282,7 @@ const panelChange = (scope, row) => {
<span
class=
"item-label"
slot=
"label"
>
<span
:class=
"
{ required_mark: child.required }">
{{
child
.
label
}}
</span>
}}
</span>
</span>
<template
v-if=
"child.type == 'upload-image'"
>
<el-upload
:class=
"[child.col, 'avatar-uploader',
{ is_block: child.block }]" action="#"
...
...
src/types/components.d.ts
View file @
8f3c06d
...
...
@@ -12,6 +12,7 @@ declare module '@vue/runtime-core' {
ApprovalProcess
:
typeof
import
(
'./../components/ApprovalProcess/src/ApprovalProcess.vue'
)[
'default'
]
Auth
:
typeof
import
(
'./../components/Auth/index.vue'
)[
'default'
]
AuthAll
:
typeof
import
(
'./../components/AuthAll/index.vue'
)[
'default'
]
CarouselPanel
:
typeof
import
(
'./../components/CarouselPanel/src/CarouselPanel.vue'
)[
'default'
]
ContentWrap
:
typeof
import
(
'./../components/ContentWrap/src/ContentWrap.vue'
)[
'default'
]
Copyright
:
typeof
import
(
'./../components/Copyright/index.vue'
)[
'default'
]
Day
:
typeof
import
(
'./../components/Schedule/component/day.vue'
)[
'default'
]
...
...
src/views/data_asset/registerDetail.vue
View file @
8f3c06d
...
...
@@ -1249,15 +1249,15 @@ const formattedDate = (dateVal) => {
(
assetDetailInfo
.
updateFrequency
?.
includes
(
7
)
?
((
assetDetailInfo
.
updateFrequencyName
>
1
?
','
:
''
)
+
assetDetailInfo
.
updateFrequencyOther
)
:
''
))
??
'--'
}}
<
/span
>
<
/div
>
<
div
class
=
"list_item"
>
<
span
class
=
"item_label"
>
是否完成质量评估
:
<
/span
>
<
span
class
=
"item_value"
>
{{
assetDetailInfo
.
isQualityAssessment
==
'Y'
?
'是'
:
'否'
}}
<
/span
>
<
/div
>
<
div
class
=
"list_item"
v
-
if
=
"(detailType == 'asset' && assetDetailInfo.isQualityAssessment == 'Y')"
>
<
span
class
=
"item_label"
>
质量评估机构
:
<
/span
>
<
span
class
=
"item_value"
>
{{
assetDetailInfo
.
registerAttachment
.
qualityEvaluationInstitution
||
'--'
}}
<
/span
>
<
/div
>
<
div
class
=
"list_item"
v
-
else
-
if
=
"assetDetailInfo.isQualityAssessment != 'Y'"
>
<
span
class
=
"item_label"
>
是否完成质量评估
:
<
/span
>
<
span
class
=
"item_value"
>
{{
assetDetailInfo
.
isQualityAssessment
==
'Y'
?
'是'
:
'否'
}}
<
/span
>
<
/div
>
<
div
class
=
"list_item"
>
<
span
class
=
"item_label"
>
病例总数
(
例
):
<
/span
>
<
span
class
=
"item_value"
>
{{
assetDetailInfo
.
caseNumber
?
changeNum
(
assetDetailInfo
.
caseNumber
,
0
)
:
'--'
...
...
@@ -1289,15 +1289,15 @@ const formattedDate = (dateVal) => {
<
span
class
=
"item_value"
>
{{
assetDetailInfo
.
isRegistered
==
'N'
?
'无'
:
(
assetDetailInfo
.
registeredExchangeName
?.
join
(
','
)
??
'--'
)
}}
<
/span
>
<
/div
>
<
div
class
=
"list_item"
>
<
span
class
=
"item_label"
>
是否完成价值评估
:
<
/span
>
<
span
class
=
"item_value"
>
{{
assetDetailInfo
.
isCostAssessment
==
'Y'
?
'是'
:
'否'
}}
<
/span
>
<
/div
>
<
div
class
=
"list_item"
v
-
if
=
"(detailType == 'asset' && assetDetailInfo.isCostAssessment == 'Y')"
>
<
span
class
=
"item_label"
>
价值评估机构
:
<
/span
>
<
span
class
=
"item_value"
>
{{
assetDetailInfo
.
registerAttachment
.
costAssessmentInstitution
||
'--'
}}
<
/span
>
<
/div
>
<
div
class
=
"list_item"
v
-
else
-
if
=
"assetDetailInfo.isCostAssessment != 'Y'"
>
<
span
class
=
"item_label"
>
是否完成价值评估
:
<
/span
>
<
span
class
=
"item_value"
>
{{
assetDetailInfo
.
isCostAssessment
==
'Y'
?
'是'
:
'否'
}}
<
/span
>
<
/div
>
<
div
class
=
"list_item"
>
<
span
class
=
"item_label"
>
资产类型
:
<
/span
>
<
span
class
=
"item_value"
>
{{
assetDetailInfo
.
damTypeName
||
'--'
}}
<
/span
>
...
...
@@ -1437,7 +1437,44 @@ const formattedDate = (dateVal) => {
</div>
</span>
</div>
<div class="
list_item
is_block
isFile
" :style="
{
width
:
'40%'
,
'margin-right'
:
'28px'
}
"
v-if="
detailType
==
'asset'
&&
assetDetailInfo
.
registerAttachment
?.
commitmentLetter
?.
length
">
<span class="
item_label
" :style="
{
width
:
'auto'
,
'text-align'
:
'left'
}
">承诺函附件</span>
<span v-for="
(
item
)
in
(
assetDetailInfo
.
registerAttachment
?.
commitmentLetter
||
[])
" class="
item_value
"
:style="
{
'padding-left'
:
'0px'
}
">
<div class="
file
-
operate
">
<template
v-if="
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'xls'
||
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'xlsx'
||
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'csv'
">
<img class="
file
-
img
" src="
..
/
..
/
assets
/
images
/
excel
.
png
" />
</template>
<template
v-else-if="
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'doc'
||
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'docx'
">
<img class="
file
-
img
" src="
..
/
..
/
assets
/
images
/
word
.
png
" />
</template>
<template v-else-if="
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'zip'
">
<img class="
file
-
img
" src="
..
/
..
/
assets
/
images
/
zip
.
png
" />
</template>
<template v-else-if="
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'rar'
">
<img class="
file
-
img
" src="
..
/
..
/
assets
/
images
/
RAR
.
png
" />
</template>
<template v-else-if="
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'pdf'
">
<img class="
file
-
img
" src="
..
/
..
/
assets
/
images
/
PDF
.
png
" />
</template>
<template v-else-if="
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'png'
">
<img class="
file
-
img
" src="
..
/
..
/
assets
/
images
/
png
.
png
" />
</template>
<template
v-else-if="
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'jpg'
||
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'jpeg'
">
<img class="
file
-
img
" src="
..
/
..
/
assets
/
images
/
jpg
.
png
" />
</template>
<div class="
file
-
name
"
>
{{
item
.
name
}}
<
/div
>
<
div
:
style
=
"
{
right
:
'36px'
}
"
v-if="
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'pdf'
||
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'png'
||
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'jpg'
||
item
.
name
.
substring
(
item
.
name
.
lastIndexOf
(
'.'
)
+
1
)
==
'jpeg'
"
class="
file
-
preview
" @click="
onUploadFilePreview
(
item
)
">查看</div>
<div :style="
{
right
:
'0px'
}
" class="
file
-
preview
" @click="
onUploadFileDownload
(
item
)
">下载</div>
</div>
</span>
</div>
<div class="
list_item
is_block
isFile
" :style="
{
width
:
'40%'
}
"
v-if="
(
detailType
==
'asset'
&&
assetDetailInfo
.
isQualityAssessment
==
'Y'
)
&&
assetDetailInfo
.
registerAttachment
?.
evaluationFile
?.
length
">
<span class="
item_label
" :style="
{
width
:
'auto'
,
'text-align'
:
'left'
}
">质量评估报告</span>
...
...
@@ -1594,7 +1631,7 @@ const formattedDate = (dateVal) => {
</span>
</div>
<div class="
list_item
is_block
isFile
" :style="
{
width
:
'40%'
,
'margin-right'
:
'28px'
}
"
v-if="
assetDetailInfo
.
registerAttachment
?.
commitmentLetter
?.
length
">
v-if="
detailType
!=
'asset'
&&
assetDetailInfo
.
registerAttachment
?.
commitmentLetter
?.
length
">
<span class="
item_label
" :style="
{
width
:
'auto'
,
'text-align'
:
'left'
}
">承诺函附件</span>
<span v-for="
(
item
)
in
(
assetDetailInfo
.
registerAttachment
?.
commitmentLetter
||
[])
" class="
item_value
"
:style="
{
'padding-left'
:
'0px'
}
">
...
...
src/views/data_asset/registerManagemant.vue
View file @
8f3c06d
...
...
@@ -6,6 +6,7 @@
import
{
ref
}
from
'vue'
;
import
TableTools
from
"@/components/Tools/table_tools.vue"
;
import
{
ElMessage
,
ElMessageBox
}
from
'element-plus'
;
import
{
CarouselPanel
}
from
'@/components/CarouselPanel'
;
import
{
useRouter
,
useRoute
}
from
"vue-router"
;
import
{
MoreFilled
}
from
"@element-plus/icons-vue"
;
import
{
changeNum
,
tagMethod
,
tagType
,
}
from
"@/utils/common"
;
...
...
@@ -26,6 +27,14 @@ const path = route.path;
const
loading
=
ref
(
false
);
const
defaultItemLogo
=
new
URL
(
'@/assets/images/home-finance-product.png'
,
import
.
meta
.
url
).
href
const
carouselInfo
:
any
=
ref
({
list
:
[],
height
:
'176px'
,
loop
:
false
,
autoplay
:
false
,
arrow
:
'hover'
,
itemClass
:
'list-content'
})
const
exchangeList
:
any
=
ref
([]);
const
exchangGuid
=
ref
(
''
);
const
searchItemList
=
ref
([
...
...
@@ -131,18 +140,8 @@ const tableFields = ref([{ label: "序号", type: "index", width: 56, align: "ce
{
label
:
"修改人"
,
field
:
"updateUserName"
,
width
:
140
},
{
label
:
"修改时间"
,
field
:
"updateTime"
,
width
:
180
}]);
/** 是否时企业端。不是企业端,则是服务端。 */
const
isCompanyPlatform
=
ref
(
userData
.
tenantType
==
1
);
const
listDataLoading
=
ref
(
false
);
const
activeListType
=
ref
(
'list'
);
const
listData
:
any
=
ref
([]);
/** 记录点击省略号弹出菜单的visible */
const
cardBtnVisible
:
any
=
ref
(
false
);
const
tableInfo
=
ref
({
id
:
'asset-data-table'
,
rowKey
:
'guid'
,
...
...
@@ -343,7 +342,12 @@ const getTableData = () => {
const
getExchangeData
=
()
=>
{
getExchangeList
().
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
exchangeList
.
value
=
res
.
data
||
[];
const
data
=
res
.
data
||
[];
while
(
data
.
length
)
{
exchangeList
.
value
.
push
(
data
.
splice
(
0
,
4
));
}
carouselInfo
.
value
.
list
=
exchangeList
.
value
;
carouselInfo
.
value
.
arrow
=
exchangeList
.
value
.
length
>
1
?
'hover'
:
'never'
;
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
...
...
@@ -530,9 +534,10 @@ const rejectDialogBtnClick = (btn, info) => {
<TableTools
:searchItems=
"searchItemList"
:searchId=
"'register-data-search'"
@
search=
"toSearch"
/>
</div>
<div
class=
"content_main_wrap"
>
<div
class=
"list-content"
>
<template
v-for=
"(item, i) in exchangeList"
:key=
"item.exchangeGuid"
>
<div
class=
"card-content"
:class=
"
{ active: exchangGuid == item.exchangeGuid }">
<CarouselPanel
:carousel-info=
"carouselInfo"
>
<template
v-slot:default=
"
{ carousel }">
<div
class=
"card-content"
v-for=
"(item, i) in carousel"
:key=
"'item-' + i"
:class=
"
{ active: exchangGuid == item.exchangeGuid, mr8: i
< carousel
.
length
-
1
&&
(
i
+
1
)
%
4
!==
0
}"
>
<div
class=
"header"
>
<img
class=
"left-img"
:src=
"(item.picUrl && typeof item.picUrl == 'string') ? item.picUrl : defaultItemLogo"
alt=
""
/>
...
...
@@ -556,9 +561,8 @@ const rejectDialogBtnClick = (btn, info) => {
<div
class=
"left-btn is_block"
@
click=
"btnClick(
{ value: 'create', ...item })">资产登记
</div>
</div>
</div>
<div
v-if=
"i
< exchangeList
.
length
-
1
"
class=
"space_partition"
></div>
</
template
>
</
div
>
</
CarouselPanel
>
<div
class=
"table_panel_wrap"
>
<Table
:tableInfo=
"tableInfo"
@
tableBtnClick=
"tableBtnClick"
/>
<PageNav
:class=
"[pageInfo.type]"
:pageInfo=
"pageInfo"
@
pageChange=
"pageChange"
/>
...
...
@@ -572,7 +576,6 @@ const rejectDialogBtnClick = (btn, info) => {
<
style
scoped
lang=
"scss"
>
.container_wrap
{
padding
:
0
16px
;
overflow
:
hidden
auto
;
.table_tool_wrap
{
height
:
44px
;
...
...
@@ -586,8 +589,7 @@ const rejectDialogBtnClick = (btn, info) => {
}
.table_panel_wrap
{
flex
:
1
;
height
:
auto
;
height
:
calc
(
100%
-
176px
);
}
}
...
...
@@ -724,21 +726,32 @@ const rejectDialogBtnClick = (btn, info) => {
}
}
.list-content-wrap
{
position
:
relative
;
}
.list-content
{
display
:
flex
;
flex-wrap
:
wrap
;
width
:
100%
;
height
:
176px
;
overflow
:
hidden
;
.card-content
{
width
:
calc
(
25%
-
6px
);
padding
:
16px
;
box-shadow
:
0
0
0
1px
#d9d9d9
;
margin-bottom
:
8px
;
min-width
:
325px
;
max-width
:
400px
;
border
:
1px
solid
var
(
--el-border-color-regular
);
float
:
left
;
&.active
{
box-shadow
:
0
0
0
1px
var
(
--el-color-primary
);
}
&
.mr8
{
margin-right
:
8px
;
}
.header
{
display
:
flex
;
margin-bottom
:
16px
;
...
...
@@ -817,9 +830,5 @@ const rejectDialogBtnClick = (btn, info) => {
}
}
}
.space_partition
{
width
:
8px
;
}
}
</
style
>
...
...
src/views/data_asset/registerStart.vue
View file @
8f3c06d
...
...
@@ -271,31 +271,26 @@ const setBaseFormItemsValue = (info) => {
}
else
{
item
.
children
[
1
].
visible
=
false
;
}
}
else
if
(
item
.
field
===
'costAssessmentInstitutionGuid'
)
{
item
.
default
=
attach
.
costAssessmentInstitutionGuid
?
attach
.
costAssessmentInstitutionGuid
:
(
attach
.
costAssessmentInstitution
||
info
.
costAssessmentInstitutionGuid
);
}
else
if
(
item
.
field
===
'qualityEvaluationInstitutionGuid'
)
{
item
.
default
=
attach
.
qualityEvaluationInstitutionGuid
?
attach
.
qualityEvaluationInstitutionGuid
:
(
attach
.
qualityEvaluationInstitution
||
info
.
qualityEvaluationInstitutionGuid
);
}
else
if
(
item
.
field
==
'isQualityAssessment'
)
{
item
.
default
=
info
[
item
.
field
];
let
quality
=
baseFormItems
.
value
.
find
(
item
=>
item
.
field
==
'qualityEvaluationInstitutionGuid'
);
if
(
info
[
'isQualityAssessment'
]
===
'Y'
)
{
quality
&&
(
quality
.
visible
=
true
);
uploadFormItems
.
value
[
1
].
visible
=
true
;
}
else
{
quality
&&
(
quality
.
visible
=
false
);
uploadFormItems
.
value
[
1
].
visible
=
false
;
}
}
else
if
(
item
.
field
==
'isCostAssessment'
)
{
item
.
default
=
info
[
item
.
field
];
let
quality
=
baseFormItems
.
value
.
find
(
item
=>
item
.
field
==
'costAssessmentInstitutionGuid'
);
if
(
info
[
'isCostAssessment'
]
===
'Y'
)
{
quality
&&
(
quality
.
visible
=
true
);
}
else
if
(
item
.
field
==
'quality'
)
{
item
.
children
[
0
].
default
=
info
[
'isQualityAssessment'
];
item
.
children
[
1
].
default
=
attach
.
qualityEvaluationInstitutionGuid
?
attach
.
qualityEvaluationInstitutionGuid
:
(
attach
.
qualityEvaluationInstitution
||
info
.
qualityEvaluationInstitutionGuid
);
if
(
info
[
'isQualityAssessment'
]
==
'Y'
)
{
item
.
children
[
1
].
visible
=
true
;
uploadFormItems
.
value
[
2
].
visible
=
true
;
}
else
{
quality
&&
(
quality
.
visible
=
false
)
;
item
.
children
[
1
].
visible
=
false
;
uploadFormItems
.
value
[
2
].
visible
=
false
;
}
}
else
if
(
item
.
field
==
'cost'
)
{
item
.
children
[
0
].
default
=
info
[
'isCostAssessment'
];
item
.
children
[
1
].
default
=
attach
.
costAssessmentInstitutionGuid
?
attach
.
costAssessmentInstitutionGuid
:
(
attach
.
costAssessmentInstitution
||
info
.
costAssessmentInstitutionGuid
);
if
(
info
[
'isCostAssessment'
]
==
'Y'
)
{
item
.
children
[
1
].
visible
=
true
;
uploadFormItems
.
value
[
3
].
visible
=
true
;
}
else
{
item
.
children
[
1
].
visible
=
false
;
uploadFormItems
.
value
[
3
].
visible
=
false
;
}
}
else
{
item
.
default
=
info
[
item
.
field
];
}
...
...
@@ -648,79 +643,97 @@ const baseFormItems: any = ref([
},
{
label
:
"是否完成质量评估"
,
type
:
"radio-group"
,
placeholder
:
""
,
field
:
"isQualityAssessment"
,
default
:
'N'
,
options
:
[
type
:
"input-group"
,
field
:
"quality"
,
default
:
""
,
children
:
[
{
label
:
"是"
,
value
:
'Y'
,
type
:
"select"
,
placeholder
:
"请选择"
,
field
:
"isQualityAssessment"
,
default
:
"N"
,
col
:
"w100px"
,
options
:
[
{
label
:
"否"
,
value
:
"N"
,
},
{
label
:
"是"
,
value
:
"Y"
,
},
],
required
:
true
,
},
{
label
:
"否"
,
value
:
'N'
,
label
:
""
,
type
:
"select"
,
placeholder
:
"质量评估机构"
,
col
:
"w60 no-margin-r"
,
field
:
"qualityEvaluationInstitutionGuid"
,
default
:
[],
// index: 0,
props
:
{
label
:
'tenantName'
,
value
:
'guid'
},
options
:
[],
filterable
:
true
,
allowCreate
:
true
,
clearable
:
true
,
visible
:
false
,
required
:
true
,
},
],
required
:
true
,
},
{
label
:
'质量评估机构'
,
type
:
'select'
,
placeholder
:
'请选择'
,
field
:
'qualityEvaluationInstitutionGuid'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'tenantName'
,
value
:
'guid'
},
required
:
true
,
filterable
:
true
,
allowCreate
:
true
,
clearable
:
true
,
style
:
{
width
:
'calc(33.33% - 6px)!important'
},
visible
:
false
,
required
:
true
,
},
{
label
:
"是否完成价值评估"
,
type
:
"radio-group"
,
placeholder
:
""
,
field
:
"isCostAssessment"
,
default
:
'N'
,
options
:
[
type
:
"input-group"
,
field
:
"cost"
,
default
:
""
,
children
:
[
{
label
:
"是"
,
value
:
'Y'
,
type
:
"select"
,
placeholder
:
"请选择"
,
field
:
"isCostAssessment"
,
default
:
"N"
,
col
:
"w100px"
,
options
:
[
{
label
:
"否"
,
value
:
"N"
,
},
{
label
:
"是"
,
value
:
"Y"
,
},
],
required
:
true
,
},
{
label
:
"否"
,
value
:
'N'
,
label
:
""
,
type
:
"select"
,
placeholder
:
"价值评估机构"
,
col
:
"w60 no-margin-r"
,
field
:
"costAssessmentInstitutionGuid"
,
default
:
[],
// index: 0,
props
:
{
label
:
'tenantName'
,
value
:
'guid'
},
options
:
[],
filterable
:
true
,
allowCreate
:
true
,
clearable
:
true
,
visible
:
false
,
required
:
true
,
},
],
required
:
true
,
},
{
label
:
'价值评估机构'
,
type
:
'select'
,
placeholder
:
'请选择'
,
field
:
'costAssessmentInstitutionGuid'
,
default
:
''
,
options
:
[],
props
:
{
label
:
'tenantName'
,
value
:
'guid'
},
required
:
true
,
filterable
:
true
,
allowCreate
:
true
,
clearable
:
true
,
style
:
{
width
:
'calc(33.33% - 6px)!important'
},
visible
:
false
,
required
:
true
,
},
{
label
:
"数据分类"
,
...
...
@@ -1160,14 +1173,14 @@ const baseSelectChange = (val, item, row) => {
getTenantAttach
(
val
).
then
((
res
:
any
)
=>
{
if
(
res
?.
code
==
proxy
.
$passCode
)
{
Object
.
assign
(
attachDataInfo
.
value
,
res
.
data
||
{});
uploadFormItems
.
value
[
0
].
templateUrl
=
attachDataInfo
.
value
.
register_letter
;
uploadFormItems
.
value
[
1
].
templateUrl
=
attachDataInfo
.
value
[
'commitment-letter'
];
uploadFormItems
.
value
[
0
].
templateUrl
=
attachDataInfo
.
value
[
'register_letter'
]
||
''
;
uploadFormItems
.
value
[
1
].
templateUrl
=
attachDataInfo
.
value
[
'commitment-letter'
]
||
''
;
setUploadFormItemsValue
(
row
);
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
})
}
else
if
(
item
.
field
==
'isRegistered'
)
{
}
else
if
(
item
.
field
==
'isRegistered'
||
item
.
field
==
'isQualityAssessment'
||
item
.
field
==
'isCostAssessment'
)
{
setBaseFormItemsValue
(
row
);
}
else
if
(
item
.
field
==
'daName'
)
{
let
da
=
registerCatalogList
.
value
.
find
(
r
=>
r
.
guid
==
val
);
...
...
@@ -1602,7 +1615,29 @@ const propertyRadioGroupChange = (val, row, item) => {
const
uploadFormRef
=
ref
();
const
qualityEvaluationInstitution
=
ref
(
''
);
const
costAssessmentInstitution
=
ref
(
''
);
/** 资产内容 */
/**
* 资产内容
* options: [{
value: 'register_letter',
label: '数据登记承诺及收集函'
}, {
value: 'quality_evaluation_file',
label: '数据质量评价收集'
}, {
value: 'cost_assessment_file',
label: '数据价值评估收集'
}, {
value: 'commitment_letter',
label: '承诺函附件'
}, {
value: 'authorization_file',
label: '授权文件'
},
{
value: 'detail_file',
label: '商品详细介绍(签章版)'
}]
**/
const
uploadFormItems
:
any
=
ref
([
{
label
:
'数据登记承诺及收集函'
,
...
...
@@ -1614,15 +1649,15 @@ const uploadFormItems: any = ref([
field
:
'registerLetter'
,
visible
:
true
,
},
//
{
//
label: '承诺函附件',
//
tip: '支持扩展名:doc .docx .pdf .jpg .png',
//
type: 'upload-file',
//
accept: '.doc, .docx, .pdf, .jpg, .png',
//
required: false,
//
default: [],
//
field: 'commitmentLetter',
//
},
{
label
:
'承诺函附件'
,
tip
:
'支持扩展名:doc .docx .pdf .jpg .png'
,
type
:
'upload-file'
,
accept
:
'.doc, .docx, .pdf, .jpg, .png'
,
required
:
false
,
default
:
[],
field
:
'commitmentLetter'
,
},
{
label
:
'上传质量评估报告'
,
tip
:
'支持扩展名:.png, .pdf,单个文件不得大于5M'
,
...
...
@@ -1643,15 +1678,6 @@ const uploadFormItems: any = ref([
field
:
'assessmentFile'
,
visible
:
false
,
},
{
label
:
'承诺函附件'
,
tip
:
'支持扩展名:doc .docx .pdf .jpg .png'
,
type
:
'upload-file'
,
accept
:
'.doc, .docx, .pdf, .jpg, .png'
,
required
:
false
,
default
:
[],
field
:
'commitmentLetter'
,
},
]);
const
uploadFormRules
=
ref
({
...
...
@@ -2009,11 +2035,11 @@ onBeforeMount(() => {
});
}
if
(
data
.
exchangeGuid
)
{
getTenantAttach
(
userData
.
tenant
Guid
).
then
((
res
:
any
)
=>
{
getTenantAttach
(
data
.
exchange
Guid
).
then
((
res
:
any
)
=>
{
if
(
res
?.
code
==
proxy
.
$passCode
)
{
Object
.
assign
(
attachDataInfo
.
value
,
res
.
data
||
{});
uploadFormItems
.
value
[
0
].
templateUrl
=
attachDataInfo
.
value
.
register_letter
;
uploadFormItems
.
value
[
3
].
templateUrl
=
attachDataInfo
.
value
[
'commitment-letter'
];
uploadFormItems
.
value
[
0
].
templateUrl
=
attachDataInfo
.
value
[
'register_letter'
]
;
uploadFormItems
.
value
[
1
].
templateUrl
=
attachDataInfo
.
value
[
'commitment-letter'
];
setUploadFormItemsValue
(
draftDetailInfo
.
value
);
}
else
{
ElMessage
.
error
(
res
.
msg
);
...
...
@@ -2067,16 +2093,15 @@ onBeforeMount(() => {
return
parentAreaData
.
value
;
}
})
// getTenantAttach(userData.tenantGuid).then((res: any) => {
// if (res?.code == proxy.$passCode) {
// console.log(res.data);
// Object.assign(attachDataInfo.value, res.data || {});
// uploadFormItems.value[2].templateUrl = attachDataInfo.value.quality_evaluation_file;
// uploadFormItems.value[3].templateUrl = attachDataInfo.value.cost_assessment_file;
// } else {
// ElMessage.error(res.msg);
// }
// })
getTenantAttach
(
exGuid
).
then
((
res
:
any
)
=>
{
if
(
res
?.
code
==
proxy
.
$passCode
)
{
Object
.
assign
(
attachDataInfo
.
value
,
res
.
data
||
{});
uploadFormItems
.
value
[
0
].
templateUrl
=
attachDataInfo
.
value
[
'register_letter'
];
uploadFormItems
.
value
[
1
].
templateUrl
=
attachDataInfo
.
value
[
'commitment-letter'
];
}
else
{
ElMessage
.
error
(
res
.
msg
);
}
})
// 获取资产类型
getParamsList
({
dictType
:
'资产类型'
}).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
...
...
@@ -2125,8 +2150,8 @@ onBeforeMount(() => {
getSingleList
({
pageIndex
:
-
1
,
pageSize
:
-
1
,
tenantType
:
"12505"
}).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
qualityEvaluationData
.
value
=
res
.
data
.
records
||
[];
let
item
=
baseFormItems
.
value
.
find
(
item
=>
item
.
field
==
'quality
EvaluationInstitutionGuid
'
);
item
&&
(
item
.
options
=
qualityEvaluationData
.
value
);
let
item
=
baseFormItems
.
value
.
find
(
item
=>
item
.
field
==
'quality'
);
item
&&
(
item
.
children
[
1
].
options
=
qualityEvaluationData
.
value
);
}
else
{
proxy
.
$ElMessage
.
error
(
res
.
msg
);
}
...
...
@@ -2135,8 +2160,8 @@ onBeforeMount(() => {
getSingleList
({
pageIndex
:
-
1
,
pageSize
:
-
1
,
tenantType
:
"12504"
}).
then
((
res
:
any
)
=>
{
if
(
res
.
code
==
proxy
.
$passCode
)
{
costAssessmentData
.
value
=
res
.
data
.
records
||
[];
let
item
=
baseFormItems
.
value
.
find
(
item
=>
item
.
field
==
'cost
AssessmentInstitutionGuid
'
);
item
&&
(
item
.
options
=
costAssessmentData
.
value
);
let
item
=
baseFormItems
.
value
.
find
(
item
=>
item
.
field
==
'cost'
);
item
&&
(
item
.
children
[
1
].
options
=
costAssessmentData
.
value
);
}
else
{
proxy
.
$ElMessage
.
error
(
res
.
msg
);
}
...
...
src/views/data_transaction/entryManagement.vue
View file @
8f3c06d
<
script
lang=
"ts"
setup
name=
"entryManagement"
>
import
{
ref
,
onBeforeMount
}
from
'vue'
;
<
script
lang=
"ts"
setup
name=
"entryManagement"
>
import
{
ref
,
onBeforeMount
}
from
'vue'
;
import
{
useRoute
}
from
"vue-router"
import
{
ElMessage
,
ElMessageBox
}
from
"element-plus"
import
dayjs
from
'dayjs'
;
...
...
@@ -15,6 +13,7 @@ import {
intableUpdate
,
getDocumentList
}
from
"@/api/modules/dataTransaction"
;
import
{
getDamCatalogTable
}
from
'@/api/modules/dataAsset'
;
const
route
=
useRoute
()
const
userStore
=
useUserStore
();
const
searchItemList
=
ref
([
...
...
@@ -29,7 +28,7 @@ const searchItemList = ref([
]);
const
page
=
ref
({
limit
:
50
,
rows
:
0
,
rows
:
0
,
curr
:
1
,
sizes
:
[
{
label
:
"10"
,
value
:
10
},
...
...
@@ -45,123 +44,130 @@ const { proxy } = getCurrentInstance() as any;
const
tableRef
=
ref
()
const
tableInfo
=
ref
({
id
:
'entry-asset-table'
,
loading
:
false
,
isEdit
:
false
,
currentId
:
"0"
,
flag
:
"create"
,
data
:[]
as
any
,
loading
:
false
,
isEdit
:
false
,
currentId
:
"0"
,
flag
:
"create"
,
data
:
[]
as
any
,
})
const
tableSelectInfo
=
ref
({
selectValue
:
""
,
daName
:
""
,
companyGuid
:
""
selectValue
:
""
,
daName
:
""
,
companyGuid
:
""
})
const
columnInfo
=
ref
({
guid
:
""
,
companyName
:
""
,
daName
:
""
,
registerTime
:
""
,
daCode
:
""
,
effectiveDate
:
""
,
intableTime
:
""
,
intableMoney
:
0
,
issuingEntityName
:
""
,
issuingEntityGuid
:
""
,
companyGuid
:
""
,
registerGuid
:
""
guid
:
""
,
companyName
:
""
,
daName
:
""
,
registerTime
:
""
,
daCode
:
""
,
effectiveDate
:
""
,
intableTime
:
""
,
intableMoney
:
0
,
issuingEntityName
:
""
,
issuingEntityGuid
:
""
,
companyGuid
:
""
,
registerGuid
:
""
})
const
companyOption
=
ref
<
any
>
([])
const
companyOption
=
ref
<
any
>
([
{
tenantGuid
:
JSON
.
parse
(
userStore
.
userData
).
tenantGuid
,
tenantName
:
JSON
.
parse
(
userStore
.
userData
).
tenantName
}
])
const
assetsOption
=
ref
<
any
>
([])
const
colums
=
[
{
type
:
"index"
,
label
:
"序号"
,
align
:
"center"
,
width
:
"56"
type
:
"index"
,
label
:
"序号"
,
align
:
"center"
,
width
:
"56"
},
{
prop
:
"companyName"
,
label
:
"公司名称"
,
width
:
"220"
,
componentType
:
"select"
,
// editDisabled:()=> tableInfo.value.flag==="edit" ? true :false,
selectKey
:
"tenantName"
,
selectOption
:()
=>
companyOption
.
value
prop
:
"companyName"
,
label
:
"公司名称"
,
width
:
"220"
,
componentType
:
"select"
,
// editDisabled:()=> tableInfo.value.flag==="edit" ? true :false,
selectKey
:
"tenantName"
,
selectOption
:
()
=>
companyOption
.
value
},
{
prop
:
"daName"
,
label
:
"资产名称"
,
width
:
"180"
,
componentType
:
"select"
,
componentDisabled
:
false
,
//editDisabled:()=> tableInfo.value.flag==="edit" ? true :false,
selectOption
:()
=>
assetsOption
.
value
,
selectKey
:
"daName"
,
prop
:
"intableTime"
,
label
:
"入表时间"
,
width
:
"130"
,
componentType
:
"dateTime"
,
componentDisabled
:
false
},
{
prop
:
"daCode"
,
label
:
"资产编号"
,
width
:
"180"
prop
:
"intableMoney"
,
label
:
"入表金额(万元)"
,
width
:
"200"
,
componentType
:
"number"
,
toFixed
:
true
,
placeholder
:
"0.00"
,
align
:
"right"
,
config
:
{
controls
:
false
,
precision
:
0
},
componentDisabled
:
false
,
input
:
(
value
,
key
,
info
)
=>
{
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
/
[^\d
.
]
/g
,
""
)
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
/
\.{2,}
/g
,
"."
)
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
"."
,
"$#$"
).
replace
(
/
\.
/g
,
""
).
replace
(
"$#$"
,
"."
)
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
/^
(\-)
*
(\d
+
)\.(\d\d\d\d\d\d)
.*$/
,
"$1$2.$3"
)
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
/^
\D
*
(\d{0,12}(?:\.\d{0,6})?)
.*$/g
,
"$1"
)
},
change
:
(
value
,
key
,
info
)
=>
{
let
strArr
=
value
.
split
(
"."
)
if
(
strArr
.
length
>
1
)
{
let
right
=
strArr
[
1
]
if
(
right
===
''
||
right
.
length
<
2
)
{
tableRef
.
value
.
columnInfo
[
key
]
=
parseFloat
(
tableRef
.
value
.
columnInfo
[
key
]
||
0
).
toFixed
(
2
)
}
}
else
{
tableRef
.
value
.
columnInfo
[
key
]
=
parseFloat
(
tableRef
.
value
.
columnInfo
[
key
]
||
0
).
toFixed
(
2
)
}
}
},
{
prop
:
"registerTime"
,
label
:
"登记时间"
,
width
:
"130"
,
componentType
:
"dateTime"
,
prop
:
"daName"
,
label
:
"资产名称"
,
width
:
"180"
,
componentType
:
"select"
,
componentDisabled
:
false
,
//editDisabled:()=> tableInfo.value.flag==="edit" ? true :false,
selectOption
:
()
=>
assetsOption
.
value
,
selectKey
:
"damName"
,
},
{
prop
:
"effectiveDate"
,
label
:
"有效期"
,
width
:
"130"
,
componentType
:
"dateTime"
,
prop
:
"daCode"
,
label
:
"资产编号"
,
width
:
"180"
},
{
prop
:
"issuingEntityName"
,
label
:
"发证主体"
,
width
:
"250"
prop
:
"registerTime"
,
label
:
"登记时间"
,
width
:
"130"
,
componentType
:
"dateTime"
,
},
{
prop
:
"intableTime"
,
label
:
"入表时间"
,
width
:
"130"
,
componentType
:
"dateTime"
,
componentDisabled
:
false
prop
:
"effectiveDate"
,
label
:
"有效期"
,
width
:
"130"
,
componentType
:
"dateTime"
,
},
{
prop
:
"intableMoney"
,
label
:
"入表金额(万元)"
,
width
:
"200"
,
componentType
:
"number"
,
toFixed
:
true
,
placeholder
:
"0.00"
,
align
:
"right"
,
config
:{
controls
:
false
,
precision
:
0
},
componentDisabled
:
false
,
input
:(
value
,
key
,
info
)
=>
{
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
/
[^\d
.
]
/g
,
""
)
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
/
\.{2,}
/g
,
"."
)
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
"."
,
"$#$"
).
replace
(
/
\.
/g
,
""
).
replace
(
"$#$"
,
"."
)
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
/^
(\-)
*
(\d
+
)\.(\d\d\d\d\d\d)
.*$/
,
"$1$2.$3"
)
tableRef
.
value
.
columnInfo
[
key
]
=
tableRef
.
value
.
columnInfo
[
key
].
toString
().
replace
(
/^
\D
*
(\d{0,12}(?:\.\d{0,6})?)
.*$/g
,
"$1"
)
},
change
:(
value
,
key
,
info
)
=>
{
let
strArr
=
value
.
split
(
"."
)
if
(
strArr
.
length
>
1
)
{
let
right
=
strArr
[
1
]
if
(
right
===
''
||
right
.
length
<
2
)
{
tableRef
.
value
.
columnInfo
[
key
]
=
parseFloat
(
tableRef
.
value
.
columnInfo
[
key
]
||
0
).
toFixed
(
2
)
}
}
else
{
tableRef
.
value
.
columnInfo
[
key
]
=
parseFloat
(
tableRef
.
value
.
columnInfo
[
key
]
||
0
).
toFixed
(
2
)
}
}
prop
:
"issuingEntityName"
,
label
:
"发证主体"
,
width
:
"250"
},
]
const
toSearch
=
(
val
:
any
,
clear
:
boolean
=
false
)
=>
{
page
.
value
.
curr
=
1
;
...
...
@@ -175,24 +181,26 @@ const toSearch = (val: any, clear: boolean = false) => {
};
// 查公司
const
documentList
=
async
()
=>
{
const
res
=
await
getDocumentList
({
daName
:
tableSelectInfo
.
value
.
selectValue
,
const
res
=
await
getDocumentList
({
daName
:
tableSelectInfo
.
value
.
selectValue
,
isCompany
:
true
,
type
:
1
})
companyOption
.
value
=
res
.
data
||
[]
type
:
1
})
companyOption
.
value
=
res
.
data
||
[]
return
Promise
.
resolve
()
return
Promise
.
resolve
()
}
// 查资产
const
getAssetsList
=
async
()
=>
{
const
res
=
await
getDocumentList
({
daName
:
tableSelectInfo
.
value
.
selectValue
,
companyGuid
:
tableSelectInfo
.
value
.
companyGuid
,
type
:
1
})
assetsOption
.
value
=
res
.
data
||
[]
return
Promise
.
resolve
()
const
getAssetsList
=
async
()
=>
{
const
res
=
await
getDamCatalogTable
({
pageSize
:
-
1
,
pageIndex
:
1
,
})
assetsOption
.
value
=
res
.
data
.
records
||
[]
console
.
log
(
assetsOption
.
value
,
'---'
)
return
Promise
.
resolve
()
}
//
//
getDamCatalogTable
const
getTableData
=
()
=>
{
tableInfo
.
value
.
loading
=
true
;
getEntryList
({
...
...
@@ -206,42 +214,43 @@ const getTableData = () => {
tableInfo
.
value
.
data
=
data
.
records
||
[];
page
.
value
.
curr
=
data
.
pageIndex
;
page
.
value
.
rows
=
data
.
totalRows
||
0
;
}
}
})
}
const
createOneData
=
()
=>
{
if
(
companyOption
.
value
.
length
>
0
)
{
if
(
companyOption
.
value
.
length
>
0
)
{
findTab
(
true
)
assetsOption
.
value
=
[]
const
currentDate
=
dayjs
().
format
(
'YYYY-MM-DD'
);
tableInfo
.
value
.
flag
=
"create"
//const arr:any = []
tableInfo
.
value
.
data
.
unshift
({
guid
:
BASE_ID
,
companyName
:
""
,
daName
:
""
,
registerTime
:
""
,
daCode
:
""
,
effectiveDate
:
""
,
intableTime
:
currentDate
,
intableMoney
:
0
,
issuingEntityName
:
""
,
companyGuid
:
""
,
registerGuid
:
""
guid
:
BASE_ID
,
companyName
:
""
,
daName
:
""
,
registerTime
:
""
,
daCode
:
""
,
effectiveDate
:
""
,
intableTime
:
currentDate
,
intableMoney
:
0
,
issuingEntityName
:
""
,
companyGuid
:
""
,
registerGuid
:
""
})
//tableInfo.value.data = arr
tableInfo
.
value
.
currentId
=
BASE_ID
tableInfo
.
value
.
isEdit
=
true
tableRef
.
value
.
columnInfo
.
intableTime
=
currentDate
// tableRef.value.columnInfo.companyName = JSON.parse(userStore.userData).tenantName
}
else
{
ElMessage
.
warning
(
"没有可添加的数据!"
)
}
}
const
columnDel
=
(
row
)
=>
{
const
columnDel
=
(
row
)
=>
{
ElMessageBox
.
confirm
(
'是否确定删除所选数据?'
,
'提示'
,
...
...
@@ -252,8 +261,8 @@ const columnDel =(row) => {
}
)
.
then
(()
=>
{
deleteEntryAll
(
row
.
guid
).
then
((
res
:
any
)
=>
{
if
(
res
?.
code
===
proxy
.
$passCode
)
{
deleteEntryAll
(
row
.
guid
).
then
((
res
:
any
)
=>
{
if
(
res
?.
code
===
proxy
.
$passCode
)
{
ElMessage
.
success
(
"删除成功"
)
getTableData
()
documentList
()
...
...
@@ -263,80 +272,80 @@ const columnDel =(row) => {
}
else
{
ElMessage
.
error
(
res
?.
msg
)
}
})
}).
catch
(()
=>
{
}).
catch
(()
=>
{
tableRef
.
value
.
columnInfo
=
{}
})
}
const
columnSave
=
async
(
row
)
=>
{
if
(
!
row
.
companyName
)
{
if
(
!
row
.
companyName
)
{
ElMessage
.
warning
(
"公司名称不能为空"
)
return
}
else
if
(
!
row
.
daName
)
{
}
else
if
(
!
row
.
daName
)
{
ElMessage
.
warning
(
"资产名称不能为空"
)
return
}
else
if
(
!
row
.
intableTime
)
{
}
else
if
(
!
row
.
intableTime
)
{
ElMessage
.
warning
(
"入表时间不能为空"
)
return
}
else
if
(
!
row
.
intableMoney
||
row
.
intableMoney
<=
0
)
{
}
else
if
(
!
row
.
intableMoney
||
row
.
intableMoney
<=
0
)
{
ElMessage
.
warning
(
"入表金额必须大于0"
)
return
}
let
res
:
any
switch
(
tableInfo
.
value
.
flag
)
{
case
"create"
:
res
=
await
createEntry
(
row
);
break
case
"edit"
:
res
=
await
intableUpdate
(
row
);
break
let
res
:
any
switch
(
tableInfo
.
value
.
flag
)
{
case
"create"
:
res
=
await
createEntry
(
row
);
break
case
"edit"
:
res
=
await
intableUpdate
(
row
);
break
}
if
(
res
?.
code
===
proxy
.
$passCode
)
{
ElMessage
.
success
(
`
${
tableInfo
.
value
.
flag
===
'create'
?
'新增'
:
'修改'
}
成功`
);
if
(
res
?.
code
===
proxy
.
$passCode
)
{
ElMessage
.
success
(
`
${
tableInfo
.
value
.
flag
===
'create'
?
'新增'
:
'修改'
}
成功`
);
getTableData
()
columnInfoReset
()
documentList
()
findTab
(
false
)
tableRef
.
value
.
columnInfo
=
{}
}
else
{
}
else
{
ElMessage
.
error
(
res
.
msg
);
//columnCancel()
}
//columnInfoReset()
}
//columnInfoReset()
}
const
columnInfoReset
=
()
=>
{
tableInfo
.
value
.
currentId
=
"0"
tableInfo
.
value
.
isEdit
=
false
columnInfo
.
value
=
{
guid
:
""
,
companyName
:
""
,
daName
:
""
,
registerTime
:
""
,
daCode
:
""
,
effectiveDate
:
""
,
intableTime
:
""
,
intableMoney
:
0
,
issuingEntityName
:
""
,
issuingEntityGuid
:
""
,
companyGuid
:
""
,
registerGuid
:
""
guid
:
""
,
companyName
:
""
,
daName
:
""
,
registerTime
:
""
,
daCode
:
""
,
effectiveDate
:
""
,
intableTime
:
""
,
intableMoney
:
0
,
issuingEntityName
:
""
,
issuingEntityGuid
:
""
,
companyGuid
:
""
,
registerGuid
:
""
}
}
const
columnEdit
=
(
row
)
=>
{
const
columnEdit
=
(
row
)
=>
{
tableInfo
.
value
.
flag
=
"edit"
findTab
(
true
)
tableSelectInfo
.
value
.
companyGuid
=
row
.
companyGuid
assetsOption
.
value
=
[]
addAssetsOption
(
null
,
row
,
true
)
addAssetsOption
(
null
,
row
,
true
)
addCompanyOption
(
row
)
//getAssetsList()
const
info
=
{
...
row
}
const
info
=
{
...
row
}
tableInfo
.
value
.
currentId
=
info
.
guid
tableInfo
.
value
.
isEdit
=
true
tableRef
.
value
.
columnInfo
.
intableMoney
=
tableRef
.
value
.
columnInfo
.
intableMoney
.
toFixed
(
2
)
columnInfo
.
value
=
{
...
info
}
columnInfo
.
value
=
{
...
info
}
}
const
columnCancel
=
()
=>
{
tableInfo
.
value
.
isEdit
=
false
if
(
tableInfo
.
value
.
flag
===
"edit"
)
{
if
(
tableInfo
.
value
.
flag
===
"edit"
)
{
tableInfo
.
value
.
currentId
=
"0"
}
else
{
tableInfo
.
value
.
data
.
shift
()
...
...
@@ -351,13 +360,13 @@ const pageChange = (info) => {
getTableData
()
}
// 选择后赋值
const
handelSelect
=
(
row
,
key
,
row1
)
=>
{
if
(
key
===
"companyName"
)
{
tableSelectInfo
.
value
.
companyGuid
=
row
.
tenantGuid
addAssetsOption
(
row
,
row1
)
columnInfo
.
value
.
companyName
=
row
.
tenantName
tableRef
.
value
.
columnInfo
.
companyName
=
row
.
tenantName
tableRef
.
value
.
columnInfo
.
companyGuid
=
row
.
tenantGuid
const
handelSelect
=
(
row
,
key
,
row1
)
=>
{
if
(
key
===
"companyName"
)
{
tableSelectInfo
.
value
.
companyGuid
=
row
.
tenantGuid
addAssetsOption
(
row
,
row1
)
columnInfo
.
value
.
companyName
=
row
.
tenantName
tableRef
.
value
.
columnInfo
.
companyName
=
row
.
tenantName
tableRef
.
value
.
columnInfo
.
companyGuid
=
row
.
tenantGuid
tableRef
.
value
.
columnInfo
.
daName
=
""
tableRef
.
value
.
columnInfo
.
daCode
=
""
tableRef
.
value
.
columnInfo
.
issuingEntityName
=
""
...
...
@@ -366,23 +375,24 @@ const handelSelect = (row,key,row1) => {
tableRef
.
value
.
columnInfo
.
registerTime
=
""
tableRef
.
value
.
columnInfo
.
effectiveDate
=
""
}
else
{
if
(
tableInfo
.
value
.
flag
===
"create"
)
{
if
(
tableInfo
.
value
.
flag
===
"create"
)
{
console
.
log
(
row
,
'-----'
)
const
currentDate
=
dayjs
().
format
(
'YYYY-MM-DD'
);
columnInfo
.
value
=
{
guid
:
row
.
guid
,
companyName
:
row
.
tenant
Name
,
daName
:
row
.
da
Name
,
registerTime
:
row
.
registerTime
,
daCode
:
row
.
daCode
,
effectiveDate
:
row
.
effectiveDate
,
intableTime
:
currentDate
,
intableMoney
:
0
,
issuingEntityName
:
row
.
issuingEntityName
,
issuingEntityGuid
:
row
.
issuingEntityGuid
,
companyGuid
:
row
.
tenantGuid
,
registerGuid
:
row
.
registerGuid
guid
:
row
.
guid
,
companyName
:
row
.
rightMain
Name
,
daName
:
row
.
dam
Name
,
registerTime
:
row
.
registerTime
,
daCode
:
row
.
daCode
,
effectiveDate
:
row
.
effectiveDate
,
intableTime
:
currentDate
,
intableMoney
:
0
,
issuingEntityName
:
row
.
issuingEntityName
,
issuingEntityGuid
:
row
.
issuingEntityGuid
,
companyGuid
:
row
.
tenantGuid
,
registerGuid
:
row
.
registerGuid
}
const
{
guid
,...
obj
}
=
columnInfo
.
value
const
{
guid
,
...
obj
}
=
columnInfo
.
value
tableRef
.
value
.
columnInfo
=
obj
}
else
{
columnInfo
.
value
.
daName
=
row
.
daName
...
...
@@ -391,71 +401,72 @@ const handelSelect = (row,key,row1) => {
columnInfo
.
value
.
effectiveDate
=
row
.
effectiveDate
columnInfo
.
value
.
issuingEntityName
=
row
.
issuingEntityName
columnInfo
.
value
.
registerGuid
=
row
.
registerGuid
;
tableRef
.
value
.
columnInfo
=
{
...
columnInfo
.
value
}
tableRef
.
value
.
columnInfo
=
{
...
columnInfo
.
value
}
}
// 新增不用传guid 所以删掉,但是往输入框添加数据 通过guid判断
//console.log(columnInfo.value)
// 新增不用传guid 所以删掉,但是往输入框添加数据 通过guid判断
//console.log(columnInfo.value)
}
}
const
findTab
=
(
flag
)
=>
{
const
tab
:
any
=
userStore
.
tabbar
.
find
((
tab
:
any
)
=>
tab
.
fullPath
===
route
.
path
)
tab
.
meta
.
editPage
=
flag
const
tab
:
any
=
userStore
.
tabbar
.
find
((
tab
:
any
)
=>
tab
.
fullPath
===
route
.
path
)
tab
.
meta
.
editPage
=
flag
}
const
addAssetsOption
=
(
values
,
row
,
flag
=
false
)
=>
{
getAssetsList
().
then
(()
=>
{
const
addAssetsOption
=
(
values
,
row
,
flag
=
false
)
=>
{
getAssetsList
().
then
(()
=>
{
const
obj
=
{
costAccessmentGuid
:
null
,
daCode
:
row
.
daCode
,
daName
:
row
.
daName
,
documentFile
:
null
,
documentType
:
1
,
effectiveDate
:
row
.
effectiveDate
,
guid
:
row
.
guid
,
issuingEntityGuid
:
row
.
issuingEntityGuid
,
issuingEntityName
:
row
.
issuingEntityName
,
qualityEvaluationGuid
:
null
,
registerGuid
:
row
.
registerGuid
,
registerTime
:
row
.
registerTime
,
state
:
row
.
state
,
tenantGuid
:
row
.
companyGuid
,
tenantName
:
row
.
companyName
,
}
const
arr
=
assetsOption
.
value
if
(
values
&&
values
.
tenantGuid
===
row
.
companyGuid
)
{
arr
.
unshift
(
obj
)
assetsOption
.
value
=
arr
}
else
if
(
flag
)
{
arr
.
unshift
(
obj
)
assetsOption
.
value
=
arr
}
costAccessmentGuid
:
null
,
daCode
:
row
.
daCode
,
daName
:
row
.
daName
,
documentFile
:
null
,
documentType
:
1
,
effectiveDate
:
row
.
effectiveDate
,
guid
:
row
.
guid
,
issuingEntityGuid
:
row
.
issuingEntityGuid
,
issuingEntityName
:
row
.
issuingEntityName
,
qualityEvaluationGuid
:
null
,
registerGuid
:
row
.
registerGuid
,
registerTime
:
row
.
registerTime
,
state
:
row
.
state
,
tenantGuid
:
row
.
companyGuid
,
tenantName
:
row
.
companyName
,
}
const
arr
=
assetsOption
.
value
if
(
values
&&
values
.
tenantGuid
===
row
.
companyGuid
)
{
arr
.
unshift
(
obj
)
assetsOption
.
value
=
arr
}
else
if
(
flag
)
{
arr
.
unshift
(
obj
)
assetsOption
.
value
=
arr
}
})
}
const
addCompanyOption
=
(
row
)
=>
{
let
flag
=
true
documentList
().
then
(()
=>
{
documentList
().
then
(()
=>
{
const
obj
=
{
tenantName
:
row
.
companyName
,
tenantGuid
:
row
.
companyGuid
}
const
arr
=
companyOption
.
value
arr
.
forEach
((
item
)
=>
{
if
(
item
.
tenantGuid
===
row
.
companyGuid
)
{
flag
=
false
}
})
if
(
flag
)
{
arr
.
unshift
(
obj
)
companyOption
.
value
=
arr
}
tenantName
:
row
.
companyName
,
tenantGuid
:
row
.
companyGuid
}
const
arr
=
companyOption
.
value
arr
.
forEach
((
item
)
=>
{
if
(
item
.
tenantGuid
===
row
.
companyGuid
)
{
flag
=
false
}
})
if
(
flag
)
{
arr
.
unshift
(
obj
)
companyOption
.
value
=
arr
}
})
}
onBeforeMount
(()
=>
{
onBeforeMount
(()
=>
{
//getTableData()
documentList
()
// getAssetsList()
// documentList()
})
</
script
>
...
...
@@ -468,19 +479,9 @@ onBeforeMount(()=> {
</div>
</div>
<div
class=
"table_panel_wrap"
>
<Table
ref=
"tableRef"
:tableInfo=
"tableInfo"
:page=
"page"
:colums=
"colums"
v-model=
"columnInfo"
@
pageChange=
"pageChange"
@
columnSave=
"columnSave"
@
columnDel=
"columnDel"
@
columnEdit=
"columnEdit"
@
columnCancel=
"columnCancel"
@
handelSelect=
"handelSelect"
></Table>
<Table
ref=
"tableRef"
:tableInfo=
"tableInfo"
:page=
"page"
:colums=
"colums"
v-model=
"columnInfo"
@
pageChange=
"pageChange"
@
columnSave=
"columnSave"
@
columnDel=
"columnDel"
@
columnEdit=
"columnEdit"
@
columnCancel=
"columnCancel"
@
handelSelect=
"handelSelect"
></Table>
</div>
</div>
</
template
>
...
...
@@ -490,5 +491,4 @@ onBeforeMount(()=> {
.container_wrap
{
padding
:
0
16px
;
}
</
style
>
\ No newline at end of file
</
style
>
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
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 post a comment