Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
F
fns_front_2
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
chenqikuai
fns_front_2
Commits
05a344a5
Commit
05a344a5
authored
Dec 15, 2021
by
chenqikuai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix: 版本管理,清除数据库
parent
73bc2377
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
12 additions
and
11 deletions
+12
-11
App.vue
src/App.vue
+0
-1
app.ts
src/config/app.ts
+9
-6
main.ts
src/main.ts
+3
-2
chatutils.ts
src/utils/chatutils.ts
+0
-1
index.vue
src/views/withMenu/ChatList/index.vue
+0
-1
No files found.
src/App.vue
View file @
05a344a5
...
...
@@ -202,7 +202,6 @@ export default defineComponent({
watch
(
()
=>
route
.
path
,
(
n
)
=>
{
console
.
log
(
n
);
const
result
=
checkRoute
(
n
);
// console.log(result, " result");
new
Bridge
().
bridge_quitApp
(
result
);
...
...
src/config/app.ts
View file @
05a344a5
...
...
@@ -14,17 +14,20 @@ export const getVersionGroup = (version: string) => {
return
version
.
split
(
"."
).
map
((
i
)
=>
Number
(
i
));
};
export
const
checkVersionAndDoSomething
=
()
=>
{
export
const
checkVersionAndDoSomething
=
async
()
=>
{
const
oldVersion
=
get_version
();
const
currentVersion
=
APPVERSION
;
set_version
();
console
.
log
(
"version:"
,
currentVersion
);
if
(
oldVersion
||
(
oldVersion
&&
compareVersion
(
oldVersion
,
"0.4.2"
)
===
-
1
)
)
{
Dexie
.
delete
(
"MyAppDatabase"
);
if
(
!
oldVersion
||
compareVersion
(
oldVersion
,
"0.4.2"
)
===
-
1
)
{
return
Dexie
.
delete
(
"MyAppDatabase"
)
.
then
((
r
)
=>
{
console
.
log
(
r
,
"success"
);
})
.
catch
((
f
)
=>
{
console
.
log
(
f
,
"faill"
);
});
}
};
...
...
src/main.ts
View file @
05a344a5
...
...
@@ -33,6 +33,9 @@ import "@quasar/extras/eva-icons/eva-icons.css";
import
longPress
from
"@/plugins/longPress"
;
import
{
format
}
from
"@/utils/time"
;
import
{
checkVersionAndDoSomething
}
from
"./config/app"
;
checkVersionAndDoSomething
();
(
function
()
{
if
(
process
.
env
.
VUE_APP_MODE
===
"DEV"
)
{
// eslint-disable-next-line no-var
...
...
@@ -45,8 +48,6 @@ import { checkVersionAndDoSomething } from "./config/app";
}
})();
checkVersionAndDoSomething
();
const
app
=
createApp
(
App
);
app
.
config
.
globalProperties
.
$format
=
format
;
...
...
src/utils/chatutils.ts
View file @
05a344a5
...
...
@@ -19,7 +19,6 @@ export function getTargetIdFromDisplayMsg(msg: DisplayMessage) {
}
export
async
function
checkPendingMsgAndSendIt
()
{
console
.
log
(
"检查pending的消息,然后发送"
);
const
addr
=
getUserMsg
()?.
userInfo
.
addr
;
if
(
addr
)
{
const
pendingMessageList
=
...
...
src/views/withMenu/ChatList/index.vue
View file @
05a344a5
...
...
@@ -85,7 +85,6 @@ const renderList = async () => {
getFromId
()
as
string
);
console
.
log
(
list
,
"show list"
);
cardList
.
value
=
list
;
const
reqlist
=
list
.
map
((
i
)
=>
{
...
...
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