Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
micro-customization-system
/
micro-trialrun
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 1d9ef990
authored
Sep 24, 2021
by
吴娟华
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
'1.2.1'
1 parent
b36a4e46
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
133 additions
and
58 deletions
src/views/reportManage/outStore.vue
src/views/vehicleManage/index.vue
src/views/vehicleManage/userList.vue
src/views/vehicleManage/vehicleList.vue
src/views/reportManage/outStore.vue
View file @
1d9ef99
...
@@ -159,7 +159,7 @@ export default {
...
@@ -159,7 +159,7 @@ export default {
},
},
btnClick
(
type
,
scope
)
{
btnClick
(
type
,
scope
)
{
this
.
$Common
.
exportExcel
({
this
.
$Common
.
exportExcel
({
url
:
`
${
store
.
state
.
baseURL
}
${
REPORT_API
.
REPORT_EXPORT
}
`
,
url
:
`
${
store
.
state
.
baseURL
}
/trialdrive/notinstorereport/export
`
,
method
:
'GET'
,
method
:
'GET'
,
data
:
this
.
searchDataForm
,
data
:
this
.
searchDataForm
,
fileName
:
'无在店统计报表'
+
moment
().
format
(
'YYYY.MM.DD'
)
fileName
:
'无在店统计报表'
+
moment
().
format
(
'YYYY.MM.DD'
)
...
...
src/views/vehicleManage/index.vue
View file @
1d9ef99
...
@@ -22,7 +22,7 @@
...
@@ -22,7 +22,7 @@
</basic-table>
</basic-table>
<basic-dialog
:title=
"vehicleTitle"
:isVisible=
"vehicleVisible"
:hasOk=
"vehicleHasOk"
@
confirmDialog=
"handleConfirm('create')"
@
closeDialog=
"handleClose('create')"
>
<basic-dialog
:title=
"vehicleTitle"
:isVisible=
"vehicleVisible"
:hasOk=
"vehicleHasOk"
@
confirmDialog=
"handleConfirm('create')"
@
closeDialog=
"handleClose('create')"
>
<slot>
<slot>
<rule-form
:ruleForm=
"vehicleForm"
:rules=
"vehicleRules"
:ruleData=
"vehicleData"
:labelWidth=
"'120px'"
ref=
'vehicleRuleForm'
></rule-form>
<rule-form
v-loading=
"formLoading"
:ruleForm=
"vehicleForm"
:rules=
"vehicleRules"
:ruleData=
"vehicleData"
:labelWidth=
"'120px'"
ref=
'vehicleRuleForm'
></rule-form>
</slot>
</slot>
</basic-dialog>
</basic-dialog>
<!-- 导入 -->
<!-- 导入 -->
...
@@ -288,8 +288,8 @@ export default {
...
@@ -288,8 +288,8 @@ export default {
prop
:
"serveType"
,
prop
:
"serveType"
,
type
:
"select"
,
type
:
"select"
,
options
:
[
options
:
[
{
label
:
"未上牌"
,
value
:
"0"
},
{
label
:
"未上牌"
,
value
:
0
},
{
label
:
"已上牌"
,
value
:
"1"
},
{
label
:
"已上牌"
,
value
:
1
},
],
],
clearable
:
true
,
clearable
:
true
,
},
},
...
@@ -349,8 +349,8 @@ export default {
...
@@ -349,8 +349,8 @@ export default {
prop
:
"serveType"
,
prop
:
"serveType"
,
type
:
"select"
,
type
:
"select"
,
options
:
[
options
:
[
{
label
:
"未上牌"
,
value
:
"0"
},
{
label
:
"未上牌"
,
value
:
0
},
{
label
:
"已上牌"
,
value
:
"1"
},
{
label
:
"已上牌"
,
value
:
1
},
],
],
clearable
:
true
,
clearable
:
true
,
},
},
...
@@ -403,6 +403,8 @@ export default {
...
@@ -403,6 +403,8 @@ export default {
userArr
:[],
userArr
:[],
userData
:[],
userData
:[],
userListModalVisible
:
false
,
userListModalVisible
:
false
,
formLoading
:
false
,
isViewMode
:
false
,
};
};
},
},
watch
:
{
watch
:
{
...
@@ -416,7 +418,9 @@ export default {
...
@@ -416,7 +418,9 @@ export default {
}
}
},
},
mounted
()
{
mounted
()
{
this
.
getModels
();
this
.
vehicleListPromise
=
new
Promise
((
resolve
,
reject
)
=>
{
this
.
getModels
(
resolve
);
})
dictInfo
(
"trialdrive_vehicle_model"
).
then
((
res
)
=>
{
dictInfo
(
"trialdrive_vehicle_model"
).
then
((
res
)
=>
{
this
.
vehicleData
.
find
((
item
)
=>
item
.
prop
==
"modelId"
).
options
=
this
.
vehicleData
.
find
((
item
)
=>
item
.
prop
==
"modelId"
).
options
=
res
.
data
;
res
.
data
;
...
@@ -483,62 +487,89 @@ export default {
...
@@ -483,62 +487,89 @@ export default {
this
.
$refs
.
vehicleRuleForm
.
$children
[
0
].
clearValidate
();
this
.
$refs
.
vehicleRuleForm
.
$children
[
0
].
clearValidate
();
break
;
break
;
case
"edit"
:
case
"edit"
:
this
.
formLoading
=
true
this
.
vehicleVisible
=
!
this
.
vehicleVisible
;
this
.
vehicleVisible
=
!
this
.
vehicleVisible
;
this
.
isReadonly
=
false
;
this
.
isReadonly
=
false
;
if
(
this
.
vehicleVisible
)
{
this
.
isViewMode
=
false
//let _list = this.vehicleDefalutData;
this
.
vehicleListPromise
.
then
(()
=>
{
this
.
vehicleTitle
=
"编辑车辆"
;
if
(
this
.
vehicleVisible
)
{
this
.
vehicleHasOk
=
true
;
//let _list = this.vehicleDefalutData;
this
.
vehicleTitle
=
"编辑车辆"
;
this
.
vehicleHasOk
=
true
;
infoVehicle
({
tempId
:
scope
.
tempId
}).
then
((
res
)
=>
{
infoVehicle
({
tempId
:
scope
.
tempId
}).
then
((
res
)
=>
{
const
{
code
,
data
}
=
res
;
const
{
code
,
data
}
=
res
;
if
(
code
==
200
)
{
if
(
code
==
200
)
{
//动态创建车系、车型选择框
//动态创建车系、车型选择框
let
_list
=
this
.
creatSelect
(
data
);
let
_list
=
this
.
creatSelect
(
data
);
_list
.
map
((
k
)
=>
{
_list
.
map
((
k
)
=>
{
this
.
$set
(
k
,
"disabled"
,
false
);
if
(
k
.
prop
==
'vin'
||
k
.
prop
==
'sn'
||
k
.
prop
==
'shopName'
)
{
});
this
.
$set
(
k
,
"disabled"
,
true
);
this
.
vehicleData
=
_
.
cloneDeep
(
_list
);
}
else
{
this
.
$set
(
k
,
"disabled"
,
false
);
}
});
this
.
vehicleData
=
_
.
cloneDeep
(
_list
);
this
.
vehicleArr
.
forEach
((
item
)
=>
{
this
.
vehicleArr
.
forEach
((
item
)
=>
{
if
(
item
==
"serveType"
)
if
(
item
==
"serveType"
)
this
.
$set
(
this
.
vehicleForm
,
item
,
data
[
item
]
+
""
);
this
.
$set
(
this
.
vehicleForm
,
item
,
data
[
item
]);
else
this
.
$set
(
this
.
vehicleForm
,
item
,
data
[
item
]);
else
{
});
this
.
$set
(
this
.
vehicleForm
,
item
,
data
[
item
]);
this
.
vehicleForm
.
tempId
=
data
.
id
;
if
(
item
==
'brandId'
)
{
}
this
.
changeCarBrand
(
data
.
brandId
,
true
)
});
}
}
}
});
this
.
vehicleForm
.
tempId
=
data
.
id
;
this
.
formLoading
=
false
}
});
}
})
break
;
break
;
case
"view"
:
case
"view"
:
console
.
log
(
"view"
);
console
.
log
(
"view"
);
this
.
formLoading
=
true
this
.
vehicleVisible
=
!
this
.
vehicleVisible
;
this
.
vehicleVisible
=
!
this
.
vehicleVisible
;
this
.
isReadonly
=
true
;
this
.
isReadonly
=
true
;
if
(
this
.
vehicleVisible
)
{
this
.
isViewMode
=
true
infoVehicle
({
tempId
:
scope
.
tempId
}).
then
((
res
)
=>
{
this
.
vehicleListPromise
.
then
(()
=>
{
const
{
code
,
data
}
=
res
;
if
(
this
.
vehicleVisible
)
{
if
(
code
==
200
)
{
infoVehicle
({
tempId
:
scope
.
tempId
}).
then
((
res
)
=>
{
//动态创建车系、车型选择框
const
{
code
,
data
}
=
res
;
let
_list
=
this
.
creatSelect
(
data
);
if
(
code
==
200
)
{
_list
.
map
((
k
)
=>
{
//动态创建车系、车型选择框
this
.
$set
(
k
,
"disabled"
,
true
);
let
_list
=
this
.
creatSelect
(
data
);
});
_list
.
map
((
k
)
=>
{
this
.
vehicleData
=
_
.
cloneDeep
(
_list
);
this
.
$set
(
k
,
"disabled"
,
true
);
});
this
.
vehicleData
=
_
.
cloneDeep
(
_list
);
this
.
vehicleArr
.
forEach
((
item
)
=>
{
this
.
vehicleArr
.
forEach
((
item
)
=>
{
if
(
item
==
"serveType"
)
if
(
item
==
"serveType"
)
this
.
$set
(
this
.
vehicleForm
,
item
,
data
[
item
]
+
""
);
this
.
$set
(
this
.
vehicleForm
,
item
,
data
[
item
]);
else
this
.
$set
(
this
.
vehicleForm
,
item
,
data
[
item
]);
else
{
});
this
.
$set
(
this
.
vehicleForm
,
item
,
data
[
item
]);
}
if
(
item
==
'brandId'
)
{
});
this
.
changeCarBrand
(
data
.
brandId
,
'view'
)
this
.
vehicleTitle
=
"查看车辆"
;
}
this
.
vehicleHasOk
=
false
;
}
//this.vehicleData.map((item) => this.$set(item, "disabled", true));
});
// if (item.type == 'input') this.$set(item, 'readonly', true)
}
// else this.$set(item, 'disabled', true)
});
// })
this
.
vehicleTitle
=
"查看车辆"
;
}
this
.
vehicleHasOk
=
false
;
this
.
formLoading
=
false
//this.vehicleData.map((item) => this.$set(item, "disabled", true));
// if (item.type == 'input') this.$set(item, 'readonly', true)
// else this.$set(item, 'disabled', true)
// })
}
})
break
;
break
;
case
"delete"
:
case
"delete"
:
this
.
$confirm
(
"是否要删除?"
,
"提示"
,
{
this
.
$confirm
(
"是否要删除?"
,
"提示"
,
{
...
@@ -598,6 +629,7 @@ export default {
...
@@ -598,6 +629,7 @@ export default {
url
:
`
${
store
.
state
.
baseURL
}${
VEHICLE_API
.
VEHICLE_EXPORT
}
`
,
url
:
`
${
store
.
state
.
baseURL
}${
VEHICLE_API
.
VEHICLE_EXPORT
}
`
,
method
:
"GET"
,
method
:
"GET"
,
data
:
this
.
searchForm
,
data
:
this
.
searchForm
,
fileName
:
'试驾车辆列表'
+
moment
().
format
(
'YYYY.MM.DD'
)
});
});
break
;
break
;
case
"chooseVehicle"
:
case
"chooseVehicle"
:
...
@@ -682,6 +714,7 @@ export default {
...
@@ -682,6 +714,7 @@ export default {
},
},
// 特约店弹窗
// 特约店弹窗
selectStore
()
{
selectStore
()
{
return
if
(
this
.
isReadonly
)
return
;
if
(
this
.
isReadonly
)
return
;
this
.
filterText
=
""
;
this
.
filterText
=
""
;
this
.
filterDialogTitle
=
"选择特约店"
;
this
.
filterDialogTitle
=
"选择特约店"
;
...
@@ -753,7 +786,7 @@ export default {
...
@@ -753,7 +786,7 @@ export default {
},
},
// 获取车辆数据
// 获取车辆数据
getModels
()
{
getModels
(
resolve
)
{
let
_this
=
this
;
let
_this
=
this
;
GETVEHICLETREE
().
then
((
res
)
=>
{
GETVEHICLETREE
().
then
((
res
)
=>
{
if
(
res
.
code
!=
200
)
{
if
(
res
.
code
!=
200
)
{
...
@@ -764,11 +797,12 @@ export default {
...
@@ -764,11 +797,12 @@ export default {
let
m
=
o
.
find
((
k
)
=>
k
.
prop
==
"brandId"
);
let
m
=
o
.
find
((
k
)
=>
k
.
prop
==
"brandId"
);
m
.
options
=
_list
;
m
.
options
=
_list
;
_this
.
vehicleList
=
_list
;
_this
.
vehicleList
=
_list
;
resolve
()
});
});
},
},
// 监听车型选择
// 监听车型选择
changeCarBrand
(
e
)
{
changeCarBrand
(
e
,
flag
)
{
let
list
=
this
.
vehicleDefalutData
;
let
list
=
this
.
vehicleDefalutData
;
let
m
=
this
.
vehicleList
;
let
m
=
this
.
vehicleList
;
let
o
=
m
.
find
((
k
)
=>
k
.
id
==
e
);
let
o
=
m
.
find
((
k
)
=>
k
.
id
==
e
);
...
@@ -793,6 +827,29 @@ export default {
...
@@ -793,6 +827,29 @@ export default {
}
else
{
}
else
{
list
.
splice
(
idx
+
1
,
0
,
n
);
list
.
splice
(
idx
+
1
,
0
,
n
);
}
}
if
(
flag
)
{
let
row
=
list
.
find
((
item
)
=>
item
.
prop
===
'seriesId'
)
setTimeout
(()
=>
{
let
id
=
this
.
vehicleForm
.
typeId
this
.
changeCarModel
(
this
.
vehicleForm
.
seriesId
,
row
)
this
.
vehicleForm
.
typeId
=
id
},
500
)
}
list
.
map
((
k
)
=>
{
if
(
flag
==
'view'
)
{
this
.
$set
(
k
,
"disabled"
,
true
);
}
else
{
if
(
k
.
prop
==
'vin'
||
k
.
prop
==
'sn'
||
k
.
prop
==
'shopName'
)
{
this
.
$set
(
k
,
"disabled"
,
true
);
}
else
{
this
.
$set
(
k
,
"disabled"
,
false
);
}
}
});
this
.
$set
(
this
,
"vehicleDefalutData"
,
list
);
this
.
$set
(
this
,
"vehicleDefalutData"
,
list
);
this
.
vehicleData
=
_
.
cloneDeep
(
list
);
this
.
vehicleData
=
_
.
cloneDeep
(
list
);
delete
this
.
vehicleForm
.
seriesId
;
delete
this
.
vehicleForm
.
seriesId
;
...
@@ -834,6 +891,17 @@ export default {
...
@@ -834,6 +891,17 @@ export default {
}
else
{
}
else
{
list
.
splice
(
idx
+
1
,
0
,
n
);
list
.
splice
(
idx
+
1
,
0
,
n
);
}
}
list
.
map
((
k
)
=>
{
if
(
k
.
prop
===
'typeId'
)
{
if
(
this
.
isViewMode
){
this
.
$set
(
k
,
'disabled'
,
true
)
}
else
{
this
.
$set
(
k
,
'disabled'
,
false
)
}
}
});
this
.
$set
(
this
,
"vehicleDefalutData"
,
list
);
this
.
$set
(
this
,
"vehicleDefalutData"
,
list
);
this
.
vehicleData
=
_
.
cloneDeep
(
list
);
this
.
vehicleData
=
_
.
cloneDeep
(
list
);
delete
this
.
vehicleForm
.
typeId
;
delete
this
.
vehicleForm
.
typeId
;
...
...
src/views/vehicleManage/userList.vue
View file @
1d9ef99
...
@@ -113,7 +113,7 @@
...
@@ -113,7 +113,7 @@
<el-button
<el-button
size=
"small"
size=
"small"
class=
"pull-right"
class=
"pull-right"
@
click=
"highSearch
Visible = false
"
@
click=
"highSearch
Cancel
"
>
取消
</el-button
>
取消
</el-button
>
>
<el-button
<el-button
...
@@ -656,8 +656,8 @@ export default {
...
@@ -656,8 +656,8 @@ export default {
});
});
},
},
filterConfirm
()
{
filterConfirm
()
{
const
{
label
,
id
,
childre
n
}
=
this
.
$refs
.
tree
.
getCurrentNode
();
const
{
label
,
id
,
origi
n
}
=
this
.
$refs
.
tree
.
getCurrentNode
();
if
(
children
)
{
if
(
origin
.
type
!=
"u"
)
{
this
.
$message
({
this
.
$message
({
message
:
"请选择下级所属组织"
,
message
:
"请选择下级所属组织"
,
type
:
"error"
,
type
:
"error"
,
...
@@ -678,6 +678,10 @@ export default {
...
@@ -678,6 +678,10 @@ export default {
this
.
highSearchVisible
=
true
this
.
highSearchVisible
=
true
}
}
},
},
highSearchCancel
()
{
this
.
filterVisible
=
false
this
.
highSearchVisible
=
false
},
},
},
components
:
{
components
:
{
InfiniteLoading
,
InfiniteLoading
,
...
...
src/views/vehicleManage/vehicleList.vue
View file @
1d9ef99
...
@@ -385,6 +385,7 @@ export default {
...
@@ -385,6 +385,7 @@ export default {
pType
:
"view"
,
pType
:
"view"
,
},
},
],
],
align
:
'left'
,
},
},
},
},
getListApi
:
getVehicleList
,
getListApi
:
getVehicleList
,
...
@@ -1007,6 +1008,7 @@ export default {
...
@@ -1007,6 +1008,7 @@ export default {
url
:
`
${
store
.
state
.
baseURL
}
/trialdrive/vehicle/vehicleinfo/export`
,
url
:
`
${
store
.
state
.
baseURL
}
/trialdrive/vehicle/vehicleinfo/export`
,
method
:
"GET"
,
method
:
"GET"
,
data
:
this
.
searchForm
,
data
:
this
.
searchForm
,
fileName
:
'车辆管理'
+
moment
().
format
(
'YYYY.MM.DD'
)
});
});
break
;
break
;
case
"freq"
:
case
"freq"
:
...
@@ -1223,6 +1225,7 @@ export default {
...
@@ -1223,6 +1225,7 @@ export default {
}
}
this
.
$set
(
this
.
vehicleForm
,
"organizationName"
,
label
);
this
.
$set
(
this
.
vehicleForm
,
"organizationName"
,
label
);
this
.
vehicleForm
.
organizationId
=
id
;
this
.
vehicleForm
.
organizationId
=
id
;
this
.
$refs
.
vehicleRuleForm
.
$children
[
0
].
validateField
(
'organizationName'
)
this
.
closeFilter
();
this
.
closeFilter
();
},
},
filterNode
(
value
,
data
)
{
filterNode
(
value
,
data
)
{
...
...
Write
Preview
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