Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
glsx
/
gl_tape
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
3
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 6ceb0202
authored
Jun 20, 2024
by
李伟康
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
commit 车型销售
1 parent
9e9c5ad0
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
69 additions
and
10 deletions
components/CarBrands.vue
components/Employee.vue
pages/equity/index.vue
components/CarBrands.vue
View file @
6ceb020
...
@@ -83,7 +83,31 @@ export default {
...
@@ -83,7 +83,31 @@ export default {
if
(
carBrandList
.
length
)
this
.
selectCar
(
carBrandList
[
0
],
true
)
if
(
carBrandList
.
length
)
this
.
selectCar
(
carBrandList
[
0
],
true
)
},
},
open
()
{
open
()
{
this
.
$refs
.
carBrandListVisible
.
open
()
uni
.
showLoading
({
mask
:
true
})
const
userInfo
=
uni
.
$storage
.
get
(
"userInfo"
),
{
shopMerchantId
}
=
userInfo
;
/**获取品牌车型 */
uni
.
$api
.
commonApi
.
getMerchantCarBrandList
([
shopMerchantId
])
.
then
(({
data
})
=>
{
let
list
=
data
[
0
].
carBrandList
,
carBrandList
=
[];
list
?.
map
((
e
)
=>
{
e
.
childs
.
map
((
i
)
=>
{
i
.
brandId
=
e
.
id
;
carBrandList
.
push
(
i
);
});
});
this
.
$store
.
dispatch
(
"setCarBrandsList"
,
carBrandList
);
this
.
$refs
.
carBrandListVisible
.
open
()
uni
.
hideLoading
()
}).
catch
(()
=>
{
this
.
$refs
.
carBrandListVisible
.
open
()
uni
.
hideLoading
()
})
},
},
selectCar
(
e
,
auto
=
false
)
{
selectCar
(
e
,
auto
=
false
)
{
let
{
clickFlga
}
=
this
let
{
clickFlga
}
=
this
...
...
components/Employee.vue
View file @
6ceb020
...
@@ -57,7 +57,24 @@ export default {
...
@@ -57,7 +57,24 @@ export default {
},
},
methods
:
{
methods
:
{
open
()
{
open
()
{
this
.
$refs
.
employeeBoxVisible
.
open
()
uni
.
showLoading
({
mask
:
true
})
const
userInfo
=
uni
.
$storage
.
get
(
"userInfo"
),
{
shopMerchantId
}
=
userInfo
;
/**获取销售人员 */
uni
.
$api
.
commonApi
.
getEmployeeList
({
merchantId
:
shopMerchantId
,
})
.
then
((
res
)
=>
{
this
.
$store
.
dispatch
(
"setEmployeeList"
,
res
);
this
.
$refs
.
employeeBoxVisible
.
open
()
uni
.
hideLoading
()
}).
catch
(()
=>
{
this
.
$refs
.
employeeBoxVisible
.
open
()
uni
.
hideLoading
()
})
},
},
handleSelect
(
item
)
{
handleSelect
(
item
)
{
this
.
close
();
this
.
close
();
...
...
pages/equity/index.vue
View file @
6ceb020
...
@@ -82,6 +82,16 @@ export default {
...
@@ -82,6 +82,16 @@ export default {
return
false
;
return
false
;
},
},
onShow
()
{
onShow
()
{
var
localStorageSpace
=
function
()
{
var
allStrings
=
''
;
for
(
var
key
in
window
.
localStorage
)
{
if
(
window
.
localStorage
.
hasOwnProperty
(
key
))
{
allStrings
+=
window
.
localStorage
[
key
];
}
}
return
allStrings
?
3
+
((
allStrings
.
length
*
16
)
/
(
8
*
1024
))
+
' KB'
:
'Empty (0 KB)'
;
}
console
.
log
(
'localStorage当前占用'
+
localStorageSpace
())
this
.
init
();
this
.
init
();
},
},
async
onReachBottom
()
{
async
onReachBottom
()
{
...
@@ -120,14 +130,22 @@ export default {
...
@@ -120,14 +130,22 @@ export default {
},
},
// 查询素材
// 查询素材
async
getSoure
()
{
async
getSoure
()
{
let
{
moduleList
,
toolList
}
=
await
uni
.
$api
.
systemApi
.
getMockData
();
try
{
await
moduleList
.
map
(
async
e
=>
{
uni
.
showLoading
({
if
(
e
.
receptionSourceDetailList
)
e
.
receptionSourceDetailList
=
await
uni
.
$api
.
systemApi
.
imgToBase64
(
e
.
receptionSourceDetailList
,
'detailUrl'
)
mask
:
true
if
(
e
.
carTypeList
)
e
.
carTypeList
=
await
uni
.
$api
.
systemApi
.
imgToBase64
(
e
.
carTypeList
)
})
})
let
{
moduleList
,
toolList
}
=
await
uni
.
$api
.
systemApi
.
getMockData
();
this
.
moduleList
=
moduleList
await
moduleList
.
map
(
async
e
=>
{
this
.
toolList
=
toolList
if
(
e
.
receptionSourceDetailList
)
e
.
receptionSourceDetailList
=
await
uni
.
$api
.
systemApi
.
imgToBase64
(
e
.
receptionSourceDetailList
,
'detailUrl'
)
uni
.
$api
.
systemApi
.
updateMockData
(
moduleList
,
'moduleList'
)
if
(
e
.
carTypeList
)
e
.
carTypeList
=
await
uni
.
$api
.
systemApi
.
imgToBase64
(
e
.
carTypeList
)
})
uni
.
hideLoading
()
this
.
moduleList
=
moduleList
this
.
toolList
=
toolList
uni
.
$api
.
systemApi
.
updateMockData
(
moduleList
,
'moduleList'
)
}
catch
(
error
)
{
uni
.
hideLoading
()
}
},
},
errorImg
(
index
)
{
errorImg
(
index
)
{
this
.
moduleList
[
index
].
showAlt
=
true
this
.
moduleList
[
index
].
showAlt
=
true
...
...
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