mirror of
https://github.com/kuaifan/dootask.git
synced 2026-01-30 17:20:26 +00:00
no message
This commit is contained in:
parent
38eaf2eb02
commit
3c9447e1b6
1
resources/assets/js/functions/web.js
vendored
1
resources/assets/js/functions/web.js
vendored
@ -615,6 +615,7 @@ import {convertLocalResourcePath} from "../components/Replace/utils";
|
|||||||
* @returns {string}
|
* @returns {string}
|
||||||
*/
|
*/
|
||||||
filterInvalidLine(content) {
|
filterInvalidLine(content) {
|
||||||
|
if (!content) return '';
|
||||||
return `${content}`
|
return `${content}`
|
||||||
.replace(/^(<p>\s*<\/p>)+|(<p>\s*<\/p>)+$/gi, '')
|
.replace(/^(<p>\s*<\/p>)+|(<p>\s*<\/p>)+$/gi, '')
|
||||||
.replace(/^(<p><br\/*><\/p>)+|(<p><br\/*><\/p>)+$/gi, '')
|
.replace(/^(<p><br\/*><\/p>)+|(<p><br\/*><\/p>)+$/gi, '')
|
||||||
|
|||||||
@ -3056,7 +3056,7 @@ export default {
|
|||||||
},
|
},
|
||||||
|
|
||||||
onVisible(v) {
|
onVisible(v) {
|
||||||
this.startMsgId = $A.runNum(v.length > 0 ? v[0] : 0)
|
this.startMsgId = $A.runNum(v.length ? v[Math.min(1, v.length - 1)] : 0)
|
||||||
},
|
},
|
||||||
|
|
||||||
onBack() {
|
onBack() {
|
||||||
|
|||||||
12
resources/assets/js/store/actions.js
vendored
12
resources/assets/js/store/actions.js
vendored
@ -990,29 +990,29 @@ export default {
|
|||||||
...dataMap.json.map(key => $A.IDBJson(key))
|
...dataMap.json.map(key => $A.IDBJson(key))
|
||||||
]);
|
]);
|
||||||
|
|
||||||
// 更新state
|
// 更新 state
|
||||||
[...dataMap.string, ...dataMap.array, ...dataMap.json].forEach((key, index) => {
|
[...dataMap.string, ...dataMap.array, ...dataMap.json].forEach((key, index) => {
|
||||||
state[key] = data[index];
|
state[key] = data[index];
|
||||||
});
|
});
|
||||||
|
|
||||||
// 特殊处理cacheDialogs
|
// 特殊处理 cacheDialogs
|
||||||
state.cacheDialogs = state.cacheDialogs.map(item => ({
|
state.cacheDialogs = state.cacheDialogs.map(item => ({
|
||||||
...item,
|
...item,
|
||||||
loading: false,
|
loading: false,
|
||||||
}));
|
}));
|
||||||
|
|
||||||
// 特殊处理dialogDrafts
|
// 特殊处理 dialogDrafts
|
||||||
state.dialogDrafts = state.dialogDrafts.filter(item => !!item.content).map(item => ({
|
state.dialogDrafts = state.dialogDrafts.filter(item => !!item.content).map(item => ({
|
||||||
...item,
|
...item,
|
||||||
tag: !!item.content,
|
tag: !!item.content,
|
||||||
}));
|
}));
|
||||||
|
|
||||||
// TranslationLanguage检查
|
// TranslationLanguage 检查
|
||||||
if (typeof languageList[state.cacheTranslationLanguage] === "undefined") {
|
if (typeof languageList[state.cacheTranslationLanguage] === "undefined") {
|
||||||
state.cacheTranslationLanguage = languageName;
|
state.cacheTranslationLanguage = languageName;
|
||||||
}
|
}
|
||||||
|
|
||||||
// TranscriptionLanguage检查
|
// TranscriptionLanguage 检查
|
||||||
if (typeof languageList[state.cacheTranscriptionLanguage] === "undefined") {
|
if (typeof languageList[state.cacheTranscriptionLanguage] === "undefined") {
|
||||||
state.cacheTranscriptionLanguage = '';
|
state.cacheTranscriptionLanguage = '';
|
||||||
}
|
}
|
||||||
@ -1024,7 +1024,7 @@ export default {
|
|||||||
state.userIsAdmin = $A.inArray("admin", state.userInfo.identity);
|
state.userIsAdmin = $A.inArray("admin", state.userInfo.identity);
|
||||||
}
|
}
|
||||||
|
|
||||||
// 处理ServerUrl
|
// 处理 ServerUrl
|
||||||
if (state.cacheServerUrl) {
|
if (state.cacheServerUrl) {
|
||||||
window.systemInfo.apiUrl = state.cacheServerUrl
|
window.systemInfo.apiUrl = state.cacheServerUrl
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user