Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
严立
/
cd-bid
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
37498856
authored
Aug 25, 2020
by
严立
Browse files
Options
_('Browse Files')
Download
Email Patches
Plain Diff
Signed-off-by: yanl <yanl@xmmakeit.com>
parent
8d92d56a
Show whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
38 additions
and
9 deletions
src/common/js/host.js
src/common/js/request/header.js
src/common/js/request/request.js
src/common/js/rule/rule.js
src/view/personal/supplier-info-change.vue
src/view/register-specialist.vue
src/view/register-supplier.vue
src/view/specialist/specialist-info-change.vue
src/common/js/host.js
View file @
37498856
...
@@ -5,14 +5,14 @@ let output = {
...
@@ -5,14 +5,14 @@ let output = {
// agentSignIn: 'http://bid-vue.meiqicloud.com/'
// agentSignIn: 'http://bid-vue.meiqicloud.com/'
// 测试环境
// 测试环境
base
:
'/Api/'
,
//
base: '/Api/',
resources
:
'http://bid-web.meiqicloud.com'
,
//
resources: 'http://bid-web.meiqicloud.com',
agentSignIn
:
'http://bid-vue.meiqicloud.com/'
//
agentSignIn: 'http://bid-vue.meiqicloud.com/'
// 正式环境
// 正式环境
//
base: '/Api/',
base
:
'/Api/'
,
//
resources: 'https://www.fjbidding.com',
resources
:
'https://www.fjbidding.com'
,
//
agentSignIn: 'https://www.fjbidding.com/admin/'
agentSignIn
:
'https://www.fjbidding.com/admin/'
}
}
output
.
uploadFile
=
output
.
base
+
'bid/common/webupload/upload'
output
.
uploadFile
=
output
.
base
+
'bid/common/webupload/upload'
...
...
src/common/js/request/header.js
View file @
37498856
let
output
=
function
(
funcXMLHttpRequest
,
funcConfigure
)
{
let
output
=
function
(
funcXMLHttpRequest
,
funcConfigure
)
{
funcXMLHttpRequest
.
setRequestHeader
(
'expires'
,
'-10'
)
funcXMLHttpRequest
.
setRequestHeader
(
'pragma'
,
'no-cache'
)
funcXMLHttpRequest
.
setRequestHeader
(
'Cache-Control'
,
'no-cache'
)
switch
(
funcConfigure
.
sendType
)
{
switch
(
funcConfigure
.
sendType
)
{
case
'json'
:
case
'json'
:
funcXMLHttpRequest
.
setRequestHeader
(
'Content-Type'
,
'application/json;'
)
funcXMLHttpRequest
.
setRequestHeader
(
'Content-Type'
,
'application/json;'
)
...
...
src/common/js/request/request.js
View file @
37498856
...
@@ -43,7 +43,6 @@ let output = {
...
@@ -43,7 +43,6 @@ let output = {
// 请求之前修改
// 请求之前修改
iHeader
(
funcXMLHttpRequest
,
funcConfigure
)
iHeader
(
funcXMLHttpRequest
,
funcConfigure
)
iInterceptors
.
request
(
funcXMLHttpRequest
,
funcConfigure
,
funcUrl
)
iInterceptors
.
request
(
funcXMLHttpRequest
,
funcConfigure
,
funcUrl
)
funcXMLHttpRequest
.
send
()
funcXMLHttpRequest
.
send
()
funcXMLHttpRequest
.
onreadystatechange
=
function
()
{
funcXMLHttpRequest
.
onreadystatechange
=
function
()
{
if
(
funcXMLHttpRequest
.
readyState
!==
4
)
{
if
(
funcXMLHttpRequest
.
readyState
!==
4
)
{
...
...
src/common/js/rule/rule.js
View file @
37498856
...
@@ -35,7 +35,7 @@ let output = {
...
@@ -35,7 +35,7 @@ let output = {
},
},
email
:
function
(
rule
,
value
,
callback
)
{
email
:
function
(
rule
,
value
,
callback
)
{
let
funcRegExp
=
new
RegExp
(
/^
[
A-Za-z0-9
\u
4e00-
\u
9fa5
]
+@
[
a-zA-Z0-9_-
]
+
(\.[
a-zA-Z0-9_-
]
+
)
+$/
,
'ig'
)
let
funcRegExp
=
new
RegExp
(
/^
[
.
A-Za-z0-9
\u
4e00-
\u
9fa5
]
+@
[
a-zA-Z0-9_-
]
+
(\.[
a-zA-Z0-9_-
]
+
)
+$/
,
'ig'
)
if
(
!
funcRegExp
.
test
(
value
))
{
if
(
!
funcRegExp
.
test
(
value
))
{
callback
(
new
Error
(
rule
.
message
))
callback
(
new
Error
(
rule
.
message
))
return
return
...
...
src/view/personal/supplier-info-change.vue
View file @
37498856
...
@@ -424,6 +424,7 @@
...
@@ -424,6 +424,7 @@
},
},
registerInfo
:
function
()
{
registerInfo
:
function
()
{
console
.
log
(
JSON
.
stringify
(
this
.
uploadOption
))
let
funcParam
=
{
let
funcParam
=
{
'companyName'
:
this
.
formRegister
.
companyName
,
'companyName'
:
this
.
formRegister
.
companyName
,
'companyCode'
:
this
.
formRegister
.
companyCode
,
'companyCode'
:
this
.
formRegister
.
companyCode
,
...
@@ -431,7 +432,7 @@
...
@@ -431,7 +432,7 @@
'address'
:
this
.
formRegister
.
companyAddress
,
'address'
:
this
.
formRegister
.
companyAddress
,
'email'
:
this
.
formRegister
.
email
,
'email'
:
this
.
formRegister
.
email
,
'license'
:
this
.
uploadOption
.
license
.
image
[
0
].
url
,
'license'
:
this
.
uploadOption
.
license
.
image
[
0
].
url
,
'bidStatement'
:
this
.
uploadOption
.
quote
.
image
[
0
].
url
,
'bidStatement'
:
this
.
formRegister
.
isQuote
===
'0'
?
''
:
this
.
uploadOption
.
quote
.
image
[
0
].
url
,
'isJoinBid'
:
this
.
formRegister
.
isQuote
,
'isJoinBid'
:
this
.
formRegister
.
isQuote
,
'taxType'
:
this
.
formRegister
.
companyTax
,
'taxType'
:
this
.
formRegister
.
companyTax
,
'phone'
:
this
.
formRegister
.
companyPhone
,
'phone'
:
this
.
formRegister
.
companyPhone
,
...
@@ -519,6 +520,8 @@
...
@@ -519,6 +520,8 @@
onUploadChange
:
function
(
funcType
,
funcFile
,
funcFileList
)
{
onUploadChange
:
function
(
funcType
,
funcFile
,
funcFileList
)
{
if
(
funcFile
.
status
===
'ready'
)
{
if
(
funcFile
.
status
===
'ready'
)
{
if
(
this
.
checkFileFormat
(
funcType
,
funcFile
))
{
if
(
this
.
checkFileFormat
(
funcType
,
funcFile
))
{
// 针对 ie 浏览器不支持 new file 功能直接放过
try
{
// 重新定义上传文件名称
// 重新定义上传文件名称
let
funcFileFormat
=
funcFile
.
name
.
substring
(
funcFile
.
name
.
lastIndexOf
(
'.'
),
funcFile
.
name
.
length
)
let
funcFileFormat
=
funcFile
.
name
.
substring
(
funcFile
.
name
.
lastIndexOf
(
'.'
),
funcFile
.
name
.
length
)
let
funcFileName
=
funcType
+
(
new
Date
()
-
0
)
+
funcFileFormat
let
funcFileName
=
funcType
+
(
new
Date
()
-
0
)
+
funcFileFormat
...
@@ -526,9 +529,14 @@
...
@@ -526,9 +529,14 @@
funcCopyFile
.
uid
=
funcFile
.
raw
.
uid
funcCopyFile
.
uid
=
funcFile
.
raw
.
uid
funcFile
.
raw
=
funcCopyFile
funcFile
.
raw
=
funcCopyFile
funcFile
.
name
=
funcFileName
funcFile
.
name
=
funcFileName
}
catch
(
err
)
{
}
this
.
formRegister
[
funcType
+
'Image'
]
=
'image'
this
.
formRegister
[
funcType
+
'Image'
]
=
'image'
this
.
uploadOption
[
funcType
].
image
.
push
(
funcFile
)
this
.
uploadOption
[
funcType
].
image
.
push
(
funcFile
)
console
.
log
(
'push'
,
this
.
uploadOption
[
funcType
].
image
)
}
else
{
}
else
{
let
funcImageBuffer
=
JSON
.
stringify
(
this
.
uploadOption
[
funcType
].
image
)
let
funcImageBuffer
=
JSON
.
stringify
(
this
.
uploadOption
[
funcType
].
image
)
this
.
uploadOption
[
funcType
].
image
=
[]
this
.
uploadOption
[
funcType
].
image
=
[]
...
@@ -644,6 +652,7 @@
...
@@ -644,6 +652,7 @@
}
}
this
.
uploadOption
[
funcType
].
image
=
funcImageList
this
.
uploadOption
[
funcType
].
image
=
funcImageList
console
.
log
(
'this.uploadOption[funcType].image'
,
this
.
uploadOption
[
funcType
].
image
)
}
}
},
},
...
...
src/view/register-specialist.vue
View file @
37498856
...
@@ -875,10 +875,16 @@
...
@@ -875,10 +875,16 @@
// 重新定义上传文件名称
// 重新定义上传文件名称
let
funcFileFormat
=
funcFile
.
name
.
substring
(
funcFile
.
name
.
lastIndexOf
(
'.'
),
funcFile
.
name
.
length
)
let
funcFileFormat
=
funcFile
.
name
.
substring
(
funcFile
.
name
.
lastIndexOf
(
'.'
),
funcFile
.
name
.
length
)
let
funcFileName
=
funcType
+
(
new
Date
()
-
0
)
+
funcFileFormat
let
funcFileName
=
funcType
+
(
new
Date
()
-
0
)
+
funcFileFormat
// 针对 ie 浏览器不支持 new file 功能直接放过
try
{
let
funcCopyFile
=
new
File
([
funcFile
.
raw
],
funcFileName
,
{
type
:
funcFile
.
raw
.
type
})
let
funcCopyFile
=
new
File
([
funcFile
.
raw
],
funcFileName
,
{
type
:
funcFile
.
raw
.
type
})
funcCopyFile
.
uid
=
funcFile
.
raw
.
uid
funcCopyFile
.
uid
=
funcFile
.
raw
.
uid
funcFile
.
raw
=
funcCopyFile
funcFile
.
raw
=
funcCopyFile
funcFile
.
name
=
funcFileName
funcFile
.
name
=
funcFileName
}
catch
(
err
)
{
}
this
.
formRegister
[
funcType
+
'Image'
]
=
'image'
this
.
formRegister
[
funcType
+
'Image'
]
=
'image'
this
.
uploadOption
[
funcType
].
image
.
push
(
funcFile
)
this
.
uploadOption
[
funcType
].
image
.
push
(
funcFile
)
...
...
src/view/register-supplier.vue
View file @
37498856
...
@@ -925,10 +925,16 @@
...
@@ -925,10 +925,16 @@
// 重新定义上传文件名称
// 重新定义上传文件名称
let
funcFileFormat
=
funcFile
.
name
.
substring
(
funcFile
.
name
.
lastIndexOf
(
'.'
),
funcFile
.
name
.
length
)
let
funcFileFormat
=
funcFile
.
name
.
substring
(
funcFile
.
name
.
lastIndexOf
(
'.'
),
funcFile
.
name
.
length
)
let
funcFileName
=
funcType
+
(
new
Date
()
-
0
)
+
funcFileFormat
let
funcFileName
=
funcType
+
(
new
Date
()
-
0
)
+
funcFileFormat
// 针对 ie 浏览器不支持 new file 功能直接放过
try
{
let
funcCopyFile
=
new
File
([
funcFile
.
raw
],
funcFileName
,
{
type
:
funcFile
.
raw
.
type
})
let
funcCopyFile
=
new
File
([
funcFile
.
raw
],
funcFileName
,
{
type
:
funcFile
.
raw
.
type
})
funcCopyFile
.
uid
=
funcFile
.
raw
.
uid
funcCopyFile
.
uid
=
funcFile
.
raw
.
uid
funcFile
.
raw
=
funcCopyFile
funcFile
.
raw
=
funcCopyFile
funcFile
.
name
=
funcFileName
funcFile
.
name
=
funcFileName
}
catch
(
err
)
{
}
this
.
formRegister
[
funcType
+
'Image'
]
=
'image'
this
.
formRegister
[
funcType
+
'Image'
]
=
'image'
this
.
uploadOption
[
funcType
].
image
.
push
(
funcFile
)
this
.
uploadOption
[
funcType
].
image
.
push
(
funcFile
)
...
...
src/view/specialist/specialist-info-change.vue
View file @
37498856
...
@@ -703,10 +703,16 @@
...
@@ -703,10 +703,16 @@
// 重新定义上传文件名称
// 重新定义上传文件名称
let
funcFileFormat
=
funcFile
.
name
.
substring
(
funcFile
.
name
.
lastIndexOf
(
'.'
),
funcFile
.
name
.
length
)
let
funcFileFormat
=
funcFile
.
name
.
substring
(
funcFile
.
name
.
lastIndexOf
(
'.'
),
funcFile
.
name
.
length
)
let
funcFileName
=
funcType
+
(
new
Date
()
-
0
)
+
funcFileFormat
let
funcFileName
=
funcType
+
(
new
Date
()
-
0
)
+
funcFileFormat
// 针对 ie 浏览器不支持 new file 功能直接放过
try
{
let
funcCopyFile
=
new
File
([
funcFile
.
raw
],
funcFileName
,
{
type
:
funcFile
.
raw
.
type
})
let
funcCopyFile
=
new
File
([
funcFile
.
raw
],
funcFileName
,
{
type
:
funcFile
.
raw
.
type
})
funcCopyFile
.
uid
=
funcFile
.
raw
.
uid
funcCopyFile
.
uid
=
funcFile
.
raw
.
uid
funcFile
.
raw
=
funcCopyFile
funcFile
.
raw
=
funcCopyFile
funcFile
.
name
=
funcFileName
funcFile
.
name
=
funcFileName
}
catch
(
err
)
{
}
this
.
formRegister
[
funcType
+
'Image'
]
=
'image'
this
.
formRegister
[
funcType
+
'Image'
]
=
'image'
this
.
uploadOption
[
funcType
].
image
.
push
(
funcFile
)
this
.
uploadOption
[
funcType
].
image
.
push
(
funcFile
)
...
...
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