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 fcbbd572
authored
Jul 02, 2024
by
前端
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
添加记录,this指向
1 parent
e7906e85
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
10 additions
and
15 deletions
components/HomeFrame/components/RecordList.vue
mixin/click.js
utils/RecordManager.js
components/HomeFrame/components/RecordList.vue
View file @
fcbbd57
...
@@ -133,7 +133,8 @@ import dayjs from 'dayjs'
...
@@ -133,7 +133,8 @@ import dayjs from 'dayjs'
const
dayImgUrl
=
require
(
'@/assets/images/common/day.webp'
)
const
dayImgUrl
=
require
(
'@/assets/images/common/day.webp'
)
const
weekImgUrl
=
require
(
'@/assets/images/common/week.webp'
)
const
weekImgUrl
=
require
(
'@/assets/images/common/week.webp'
)
const
monthImgUrl
=
require
(
'@/assets/images/common/month.webp'
)
const
monthImgUrl
=
require
(
'@/assets/images/common/month.webp'
)
import
utils
from
"@/utils/utils.js"
;
import
RecordManager
from
"@/utils/RecordManager"
;
const
recordManager
=
RecordManager
.
getInstance
();
export
default
{
export
default
{
name
:
''
,
name
:
''
,
data
()
{
data
()
{
...
@@ -217,11 +218,11 @@ export default {
...
@@ -217,11 +218,11 @@ export default {
this
.
sticky
=
e
.
detail
.
scrollTop
>=
148
this
.
sticky
=
e
.
detail
.
scrollTop
>=
148
}
,
}
,
getRecordNum
()
{
getRecordNum
()
{
let
recordFailListAll
=
JSON
.
parse
(
uni
.
$storage
.
get
(
"recordList"
)
||
"[]"
);
let
recordFailListAll
=
recordManager
.
getRecords
(
);
const
{
shopMerchantId
,
sceneType
}
=
uni
.
$storage
.
get
(
"userInfo"
);
const
{
shopMerchantId
,
sceneType
,
phone
}
=
uni
.
$storage
.
get
(
"userInfo"
);
let
recordFailList
=
recordFailListAll
.
filter
(
i
=>
{
let
recordFailList
=
recordFailListAll
.
filter
(
i
=>
{
console
.
log
(
i
.
bussinessType
,
sceneType
)
console
.
log
(
i
.
bussinessType
,
sceneType
)
return
i
.
merchantId
==
shopMerchantId
&&
i
.
bussinessType
==
(
sceneType
==
0
?
1
:
2
)
return
i
.
merchantId
==
shopMerchantId
&&
i
.
bussinessType
==
(
sceneType
==
0
?
1
:
2
)
&&
i
.
loginPhone
==
phone
}
)
}
)
this
.
recordFailList
=
recordFailList
this
.
recordFailList
=
recordFailList
}
,
}
,
...
...
mixin/click.js
View file @
fcbbd57
...
@@ -179,16 +179,10 @@ export default {
...
@@ -179,16 +179,10 @@ export default {
file
:
i
,
file
:
i
,
};
};
});
});
let
recordList
=
JSON
.
parse
(
uni
.
$storage
.
get
(
"recordList"
)
||
"[]"
);
recordManager
.
addRecord
({
recordList
=
[
...
this
.
getParams
(),
...
recordList
,
recordUrlList
,
{
});
...
this
.
getParams
(),
recordUrlList
,
},
];
console
.
log
(
recordList
,
"recordList"
);
uni
.
$storage
.
set
(
"recordList"
,
JSON
.
stringify
(
recordList
));
unlock
();
unlock
();
},
},
//结束接待
//结束接待
...
...
utils/RecordManager.js
View file @
fcbbd57
...
@@ -41,7 +41,7 @@ class RecordManager {
...
@@ -41,7 +41,7 @@ class RecordManager {
},
100
);
},
100
);
}
else
{
}
else
{
this
.
locker
=
true
;
this
.
locker
=
true
;
resolve
(
this
.
unlock
);
resolve
(
this
.
unlock
.
bind
(
this
)
);
}
}
});
});
}
}
...
...
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