Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
bdc
/
bdcdj-web
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
8a1d878a
authored
2023-06-25 08:55:25 +0800
by
xiaomiao
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'dev' of
http://yun.pashanhoo.com:9090/bdc/bdcdj-web
into dev
2 parents
156a53a1
89b40e5f
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
126 additions
and
102 deletions
src/views/components/imagePreview.vue
src/views/login/index.vue
src/views/workflow/components/clxx/clxx.vue
src/views/workflow/components/clxx/clxxUnify.vue
src/views/components/imagePreview.vue
View file @
8a1d878
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-06-
16 11:12:13
* @LastEditTime: 2023-06-
21 16:35:04
-->
<
template
>
<div
class=
"rlPopup"
>
...
...
@@ -22,7 +22,7 @@
<!--缩略图-->
<div
class=
"thumb-wrap"
>
<div
class=
"thumb-wrap-button"
>
<el-button
type=
"primary"
@
click=
"clickImage"
>
(放大) 显示(缩小)
</el-button>
<el-button
type=
"primary"
@
click=
"clickImage"
v-if=
"previewImg.imgList.length>0"
>
(放大) 显示(缩小)
</el-button>
<el-upload
class=
"fileUpdate"
ref=
"upload"
action=
""
:show-file-list=
"false"
:multiple=
"true"
:auto-upload=
"false"
:on-change=
"handleChange"
accept=
".JPG, .PNG, .JPEG,.jpg, .png, .jpeg"
:before-upload=
"beforeUpload"
>
...
...
@@ -30,8 +30,10 @@
</el-upload>
<el-button
type=
"primary"
icon=
"el-icon-delete-solid"
@
click=
"handleDelete"
v-if=
"!this.$route.query.viewtype && thumbnailImages.length>0"
>
删除
</el-button>
<el-button
type=
"primary"
@
click=
"handleOpenScan"
>
{{
scanTitle
}}
</el-button>
<el-button
type=
"primary"
@
click=
"handleViewScan"
v-if=
"isScan"
>
拍照
</el-button>
<div
v-if=
"!this.$route.query.viewtype"
class=
"pl-5"
>
<el-button
type=
"primary"
@
click=
"handleOpenScan"
>
{{
scanTitle
}}
</el-button>
<el-button
type=
"primary"
@
click=
"handleViewScan"
v-if=
"isScan"
>
拍照
</el-button>
</div>
</div>
<ul>
<li
v-for=
"(img, index) in thumbnailImages"
:key=
"index"
:class=
"
{ active: previewImg.index === index }"
...
...
@@ -46,8 +48,8 @@
</div>
</
template
>
<
script
>
import
{
getAltimeterInfo
}
from
'@/utils/operation.js'
import
PhotoZoom
from
'@/components/PhotoZoom'
import
{
getAltimeterInfo
,
getUuid
}
from
'@/utils/operation.js'
import
{
uploadSjClmx
,
deleteClmx
}
from
"@/api/clxx.js"
;
import
publicPicture
from
'@/components/publicPicture/index.vue'
export
default
{
...
...
@@ -82,12 +84,16 @@
watch
:
{
previewImg
:
{
handler
(
newValue
,
oldValue
)
{
if
(
newValue
.
imgList
.
length
>
0
)
{
if
(
newValue
.
imgList
&&
newValue
.
imgList
.
length
>
0
)
{
this
.
allLi
=
_
.
cloneDeep
(
newValue
.
imgList
).
map
(
item
=>
item
.
fjurl
)
this
.
thumbnailImages
=
newValue
.
imgList
}
else
{
this
.
allLi
=
[]
this
.
thumbnailImages
=
[]
}
},
deep
:
true
deep
:
true
,
immediate
:
true
}
},
created
()
{
...
...
@@ -145,8 +151,8 @@
return
new
Blob
([
u8arr
],
{
type
:
mime
});
}
function
blobToFile
(
blob
)
{
const
options
=
{
type
:
blob
.
type
};
const
file
=
new
File
([
blob
],
options
);
let
name
=
getUuid
(
8
)
+
'.jpg'
const
file
=
new
File
([
blob
],
name
);
return
file
;
}
getAltimeterInfo
().
then
(
res
=>
{
...
...
@@ -242,9 +248,11 @@
type
:
'warning'
}).
then
(
async
()
=>
{
let
bsmClmx
=
this
.
previewImg
.
imgList
[
this
.
previewImg
.
index
].
bsmClmx
let
bsmSj
=
this
.
previewImg
.
imgList
[
this
.
previewImg
.
index
].
bsmSj
this
.
previewImg
.
imgList
=
this
.
previewImg
.
imgList
.
filter
(
item
=>
item
.
bsmClmx
!=
bsmClmx
)
deleteClmx
(
bsmClmx
).
then
(
res
=>
{
if
(
res
.
code
==
200
)
{
that
.
$emit
(
'updateList'
,
res
.
result
)
that
.
$emit
(
'updateList'
,
{
children
:
this
.
previewImg
.
imgList
,
bsmSj
:
bsmSj
}
)
that
.
$message
({
message
:
'删除成功!'
,
type
:
'success'
...
...
src/views/login/index.vue
View file @
8a1d878
<
template
>
<div
id=
"login"
>
<div
class=
"login-logo"
><img
src=
"./images/logo-login.svg"
/></div>
<div
class=
"login-con"
>
<div
class=
"login-img"
>
<div
class=
"content"
></div>
</div>
<div
class=
"login-wrap"
>
<p>
账号登录
</p>
<div
class=
"login-user"
:class=
"
{ 'select-border': change.user }">
<img
class=
"user-icon"
src=
"./images/user.svg"
/>
<input
type=
"text"
class=
"user-input"
placeholder=
"请输入账号"
v-model=
"userInfo.username"
@
focus=
"reduceBorder('user')"
@
blur=
"addBorder('user')"
/>
<span
class=
"warning"
v-show=
"warning.user"
>
账号不能为空
</span>
</div>
<div
class=
"login-user user-mt"
:class=
"
{ 'select-border': change.pass }"
>
<img
class=
"user-icon"
src=
"./images/password.svg"
/>
<input
type=
"password"
class=
"user-input"
placeholder=
"请输入密码"
v-model=
"userInfo.password"
v-show=
"!selectEye"
@
focus=
"reduceBorder('pass')"
@
blur=
"addBorder('pass')"
/>
<input
type=
"text"
class=
"user-input"
placeholder=
"请输入密码"
v-model=
"userInfo.password"
v-show=
"selectEye"
@
focus=
"reduceBorder('pass')"
@
blur=
"addBorder('pass')"
/>
<img
class=
"password-eye"
src=
"./images/open.svg"
@
click=
"selectEyes"
v-show=
"selectEye"
/>
<img
class=
"password-eye"
src=
"./images/close.svg"
@
click=
"selectEyes"
v-show=
"!selectEye"
/>
<span
class=
"warning"
v-show=
"warning.pass"
>
密码不能为空
</span>
<div
class=
"login-content-wrap"
>
<div
class=
"login-logo"
><img
src=
"./images/logo-login.svg"
/></div>
<div
class=
"login-con"
>
<div
class=
"login-img"
>
<div
class=
"content"
></div>
</div>
<div
class=
"login-user login-valid"
:class=
"
{ 'select-border': change.valid }"
>
<img
class=
"user-icon"
src=
"./images/valid.svg"
/>
<input
type=
"text"
class=
"user-input"
placeholder=
"请输入验证码"
v-model=
"userInfo.captchaCode"
@
focus=
"reduceBorder('valid')"
@
blur=
"addBorder('valid')"
/>
<img
class=
"valid-img"
:src=
"codeSrc"
alt=
"暂无验证码"
@
click=
"reloadCaptcha"
/>
<span
class=
"warning"
v-show=
"warning.valid"
>
验证码不能为空
</span>
<div
class=
"login-wrap"
>
<p>
账号登录
</p>
<div
class=
"login-user"
:class=
"
{ 'select-border': change.user }">
<img
class=
"user-icon"
src=
"./images/user.svg"
/>
<input
type=
"text"
class=
"user-input"
placeholder=
"请输入账号"
v-model=
"userInfo.username"
@
focus=
"reduceBorder('user')"
@
blur=
"addBorder('user')"
/>
<span
class=
"warning"
v-show=
"warning.user"
>
账号不能为空
</span>
</div>
<div
class=
"login-user user-mt"
:class=
"
{ 'select-border': change.pass }"
>
<img
class=
"user-icon"
src=
"./images/password.svg"
/>
<input
type=
"password"
class=
"user-input"
placeholder=
"请输入密码"
v-model=
"userInfo.password"
v-show=
"!selectEye"
@
focus=
"reduceBorder('pass')"
@
blur=
"addBorder('pass')"
/>
<input
type=
"text"
class=
"user-input"
placeholder=
"请输入密码"
v-model=
"userInfo.password"
v-show=
"selectEye"
@
focus=
"reduceBorder('pass')"
@
blur=
"addBorder('pass')"
/>
<img
class=
"password-eye"
src=
"./images/open.svg"
@
click=
"selectEyes"
v-show=
"selectEye"
/>
<img
class=
"password-eye"
src=
"./images/close.svg"
@
click=
"selectEyes"
v-show=
"!selectEye"
/>
<span
class=
"warning"
v-show=
"warning.pass"
>
密码不能为空
</span>
</div>
<div
class=
"login-user login-valid"
:class=
"
{ 'select-border': change.valid }"
>
<img
class=
"user-icon"
src=
"./images/valid.svg"
/>
<input
type=
"text"
class=
"user-input"
placeholder=
"请输入验证码"
v-model=
"userInfo.captchaCode"
@
focus=
"reduceBorder('valid')"
@
blur=
"addBorder('valid')"
/>
<img
class=
"valid-img"
:src=
"codeSrc"
alt=
"暂无验证码"
@
click=
"reloadCaptcha"
/>
<span
class=
"warning"
v-show=
"warning.valid"
>
验证码不能为空
</span>
</div>
<div
id=
"loginBtn"
class=
"login-btn"
@
click=
"goHome"
>
登录
</div>
</div>
<div
id=
"loginBtn"
class=
"login-btn"
@
click=
"goHome"
>
登录
</div>
</div>
</div>
</div>
...
...
@@ -211,6 +213,11 @@ export default {
};
</
script
>
<
style
lang=
"scss"
scoped
>
input
::placeholder
{
color
:
#878787
;
font-size
:
14px
;
font-family
:
Arial
,
Helvetica
,
sans-serif
}
#login
{
width
:
100vw
;
height
:
100vh
;
...
...
@@ -218,17 +225,24 @@ export default {
background-size
:
100%
;
overflow
:
hidden
;
position
:
relative
;
.login-content-wrap{
position
:
absolute
;
left
:
50%
;
top
:
calc
(
50%
+
10px
);
transform
:
translate
(
-50%
,
-50%
);
}
.login-logo
{
margin-top
:
18vh
;
height
:
70px
;
width
:
100%
;
text-align
:
center
;
position
:
absolute
;
top
:
-140px
;
}
.login-logo
img
{
height
:
100%
;
}
.login-con
{
margin
:
70px
auto
;
margin
:
0
auto
;
width
:
936px
;
height
:
450px
;
.login-img{
...
...
@@ -284,15 +298,15 @@ export default {
}
.login-user
{
width
:
100%
;
height
:
4
6
px
;
height
:
4
0
px
;
border
:
1px
solid
#E5E5E5
;
box-sizing
:
border-box
;
margin-top
:
3
0
px
;
margin-top
:
3
4
px
;
border-radius
:
2px
;
position
:
relative
;
.user-icon
{
float
:
left
;
margin
:
1
3
px
auto
auto
10px
;
margin
:
1
0
px
auto
auto
10px
;
width
:
28px
;
height
:
18px
;
}
...
...
@@ -303,7 +317,8 @@ export default {
outline
:
0
;
border
:
none
;
color
:
#4a4a4a
;
line-height
:
260%
;
height
:
38px
;
line-height
:
40px
;
}
.password-eye
{
float
:
right
;
...
...
@@ -339,13 +354,14 @@ export default {
}
.login-btn
{
width
:
100%
;
height
:
4
0
px
;
height
:
4
8
px
;
background
:
#74A3F5
;
border-radius
:
4
px
;
border-radius
:
2
px
;
margin
:
0
auto
;
margin-top
:
40px
;
font-size
:
16px
;
line-height
:
40px
;
font-size
:
20px
;
font-weight
:
500
;
line-height
:
48px
;
text-align
:
center
;
color
:
#fff
;
cursor
:
pointer
;
...
...
src/views/workflow/components/clxx/clxx.vue
View file @
8a1d878
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-06-
16 11:12:40
* @LastEditTime: 2023-06-
21 15:34:44
-->
<
template
>
<div
class=
"clxx"
>
...
...
@@ -384,7 +384,7 @@
this
.
previewImg
.
index
=
0
this
.
treeCheckId
=
item
?.
bsmSj
this
.
treeCheckIndex
=
index
this
.
previewImg
.
imgList
=
item
?.
children
this
.
previewImg
.
imgList
=
item
.
children
?
item
.
children
:
[]
this
.
previewImg
.
bsmSj
=
item
?.
bsmSj
},
// 小图片点击
...
...
src/views/workflow/components/clxx/clxxUnify.vue
View file @
8a1d878
<!--
* @Description:
* @Autor: renchao
* @LastEditTime: 2023-06-
19 13:15:13
* @LastEditTime: 2023-06-
21 16:29:37
-->
<
template
>
<div
class=
"clxx"
>
...
...
@@ -120,8 +120,9 @@
this
.
previewImg
.
bsmSj
=
item
.
bsmSj
;
},
updateList
(
val
)
{
console
.
log
(
val
,
'valvalvalval'
);
let
that
=
this
if
(
val
!=
null
)
{
//删除最后一张图片时 val=null
if
(
val
.
children
.
length
!=
[]
)
{
//删除最后一张图片时 val=null
this
.
tableData
.
forEach
(
item
=>
{
if
(
item
.
bsmSj
===
val
.
bsmSj
)
{
item
.
children
=
val
.
children
...
...
@@ -140,7 +141,6 @@
}
})
}
},
// 添加材料目录
handleAdd
()
{
...
...
@@ -173,7 +173,7 @@
this
.
previewImg
.
index
=
0
this
.
treeCheckId
=
item
?.
bsmSj
this
.
treeCheckIndex
=
index
this
.
previewImg
.
imgList
=
item
?.
children
this
.
previewImg
.
imgList
=
item
.
children
?
item
.
children
:
[]
this
.
previewImg
.
bsmSj
=
item
?.
bsmSj
},
// 小图片点击
...
...
Please
register
or
sign in
to post a comment