Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
D
dsk-operate-sys-cscec
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
fulixin
dsk-operate-sys-cscec
Commits
5881fe82
Commit
5881fe82
authored
Oct 26, 2023
by
tianhongyang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bug fix
parent
96864d26
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
50 additions
and
29 deletions
+50
-29
BatchImportCom.vue
...rc/views/project/projectList/component/BatchImportCom.vue
+19
-14
BidOpeningRecord.vue
.../views/project/projectList/component/BidOpeningRecord.vue
+31
-15
No files found.
dsk-operate-ui/src/views/project/projectList/component/BatchImportCom.vue
View file @
5881fe82
...
...
@@ -17,26 +17,30 @@
</div>
</el-dialog>
<!--导入结果-->
<el-dialog
title=
"导入
结果"
:visible
.
sync=
"upload.showResult"
width=
"500px
"
class=
"batch-import-upload-dialog-container"
<el-dialog
title=
"导入
失败"
:visible
.
sync=
"upload.showResult"
width=
"60%
"
class=
"batch-import-upload-dialog-container"
custom-class=
"batch-import-upload-dialog"
@
close=
"importResultClose"
>
<div
class=
"batch-import-upload-inner"
>
<div
class=
"result-count"
>
<span
class=
"success"
>
导入成功:
</span>
<span>
{{
uploadResult
.
successCount
}}
条
</span>
</div>
<div
class=
"result-count"
>
<span
class=
"error"
>
导入失败:
</span>
<span>
{{
uploadResult
.
errorCount
}}
条
</span>
</div>
<el-table
:data=
"uploadResult.errorMsg"
border
stripe
v-if=
"uploadResult.errorMsg.length"
class=
"error-msg-list-table"
>
<el-table-column
label=
"序号"
type=
"index"
></el-table-column>
<el-table
:data=
"uploadResult.errorMsg"
border
stripe
v-if=
"uploadResult.errorMsg.length"
class=
"error-msg-list-table"
max-height=
"500px"
>
<el-table-column
label=
"导入状态"
>
<template
slot-scope=
"scope"
>
<span
style=
"color:red;"
>
导入失败
</span>
</
template
>
</el-table-column>
<el-table-column
label=
"投标人"
>
<
template
slot-scope=
"scope"
>
<span></span>
</
template
>
</el-table-column>
<el-table-column
label=
"导入失败原因"
>
<
template
slot-scope=
"scope"
>
<span>
{{
scope
.
row
}}
</span>
<span
style=
"color:red;"
>
{{
scope
.
row
}}
</span>
</
template
>
</el-table-column>
</el-table>
<el-row
style=
"padding-top: 20px;text-align: right"
>
<el-button
@
click=
"upload.showResult = false"
>
取消
</el-button>
<el-button
type=
"primary"
@
click=
"upload.showResult = false"
>
确定
</el-button>
</el-row>
</div>
</el-dialog>
</div>
...
...
@@ -99,7 +103,7 @@ export default {
this
.
upload
.
showResult
=
true
;
}
}
else
{
this
.
$message
.
success
(
`上传失败,
${
response
.
msg
?
response
.
msg
:
"请根据模板正确填写表格内容!"
}
`
);
this
.
$message
.
error
(
`上传失败,
${
response
.
msg
?
response
.
msg
:
"请根据模板正确填写表格内容!"
}
`
);
}
},
// 提交上传文件
...
...
@@ -135,6 +139,7 @@ export default {
top
:
0px
;
background
:
#fff
;
z-index
:
99
;
padding-bottom
:
0px
;
}
.batch-import-upload-inner
{
width
:
100%
;
...
...
dsk-operate-ui/src/views/project/projectList/component/BidOpeningRecord.vue
View file @
5881fe82
...
...
@@ -72,7 +72,7 @@ export default {
// 必填字符串长度验证
function
requiredStrLengthValidator
(
target
)
{
return
function
(
rule
,
value
,
callback
)
{
if
(
!
value
||
!
value
?.
toString
()?.
trim
())
{
if
(
value
&&
!
value
?.
toString
()?.
trim
())
{
return
callback
(
new
Error
(
`请输入
${
target
}
`
));
}
return
callback
();
...
...
@@ -101,7 +101,7 @@ export default {
// 金额验证
const
amountReg
=
/^
(?!
0
\d)\d
+
(\.\d
+
)?
$/
;
function
amountValidator
(
rule
,
value
,
callback
)
{
if
((
!
value
&&
value
!=
"0"
)
||
!
value
?.
toString
()?.
trim
())
{
if
((
value
&&
value
!=
"0"
)
&&
!
value
?.
toString
()?.
trim
())
{
return
callback
(
new
Error
(
`请输入投标金额`
));
}
if
(
value
&&
!
amountReg
.
test
(
value
))
{
...
...
@@ -147,11 +147,11 @@ export default {
tenderAmount
:
""
},
formRules
:
{
tenderer
:
[{
required
:
true
,
trigger
:
"blur"
,
validator
:
requiredStrLengthValidator
(
"投标人"
)
}],
tendererNature
:
[{
required
:
true
,
trigger
:
"blur"
,
validator
:
requiredStrLengthValidator
(
"企业性质"
)
}],
tenderer
:
[{
trigger
:
"blur"
,
validator
:
requiredStrLengthValidator
(
"投标人"
)
}],
tendererNature
:
[{
trigger
:
"blur"
,
validator
:
requiredStrLengthValidator
(
"企业性质"
)
}],
businessManager
:
[{
trigger
:
[
"change"
,
"blur"
],
validator
:
strLengthValidator
(
"项目经理"
)
}],
contact
:
[{
trigger
:
[
"blur"
],
validator
:
phoneNumberValidator
}],
tenderAmount
:
[{
required
:
true
,
trigger
:
[
"blur"
],
validator
:
amountValidator
}],
tenderAmount
:
[{
trigger
:
[
"blur"
],
validator
:
amountValidator
}],
},
selectionArray
:
[],
// 展示新增弹窗
...
...
@@ -250,9 +250,15 @@ export default {
// 验证通过提交数据
async
validatorSuccess
()
{
try
{
const
temp
=
JSON
.
parse
(
JSON
.
stringify
(
this
.
formData
));
const
keys
=
Object
.
keys
(
temp
);
const
flag
=
keys
.
every
(
key
=>
(
key
==
"id"
?
true
:
(
temp
[
key
]
&&
temp
[
key
]
!=
"0"
)
?
true
:
false
));
if
(
!
flag
)
{
return
this
.
dialogClose
();
}
const
result
=
this
.
formData
.
id
?
await
modifyBidOpeningRecordApi
(
this
.
formData
)
:
await
addBidOpeningRecordApi
(
this
.
formData
);
if
(
result
.
code
==
200
)
{
console
.
log
(
result
);
this
.
$message
.
success
(
`
${
this
.
formData
.
id
?
"修改成功!"
:
"新增成功!"
}
`
);
this
.
dialogClose
();
await
this
.
getTableList
();
}
...
...
@@ -273,16 +279,26 @@ export default {
},
// 批量删除
async
batchDeletion
(
id
)
{
try
{
if
(
!
this
.
selectionArray
?.
length
&&
!
id
)
return
;
const
array
=
id
?
[{
id
}]
:
this
.
selectionArray
;
const
result
=
await
removeBidOpeningRecordApi
((
array
.
map
(
item
=>
item
.
id
)).
join
(
","
));
if
(
result
.
code
==
200
)
{
this
.
getTableList
();
if
(
!
this
.
selectionArray
?.
length
&&
!
id
)
return
;
this
.
$confirm
(
'此操作将会删除该数据, 是否继续?'
,
'提示'
,
{
confirmButtonText
:
'确定'
,
cancelButtonText
:
'取消'
,
type
:
'warning'
}).
then
(
async
()
=>
{
try
{
const
array
=
id
?
[{
id
}]
:
this
.
selectionArray
;
const
result
=
await
removeBidOpeningRecordApi
((
array
.
map
(
item
=>
item
.
id
)).
join
(
","
));
if
(
result
.
code
==
200
)
{
this
.
$message
({
type
:
'success'
,
message
:
'删除成功!'
});
this
.
getTableList
();
}
}
catch
(
error
)
{
console
.
log
(
error
);
}
}
catch
(
error
)
{
console
.
log
(
error
);
}
}).
catch
(()
=>
{
});
},
// 复选框选中
selectionChange
(
array
)
{
...
...
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