|
@@ -10,71 +10,7 @@
|
|
|
|
|
|
<script src="js/util.js"></script>
|
|
<script src="js/util.js"></script>
|
|
<script src="js/login.js"></script>
|
|
<script src="js/login.js"></script>
|
|
- <style>
|
|
|
|
- body {
|
|
|
|
- font-family: Lyon-Text, Georgia, "Songti SC", SimSun, serif;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .vditor-reset {
|
|
|
|
- font-family: Lyon-Text, Georgia, "Songti SC", SimSun, serif !important;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- img {
|
|
|
|
- border: 1px solid #b7b6b6;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .img {
|
|
|
|
- border: 1px solid #b7b6b6;
|
|
|
|
- max-width: 200px;
|
|
|
|
- max-height: 200px;
|
|
|
|
- margin: 10px 10px 0 0 !important;
|
|
|
|
- cursor: pointer;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .editClass button {
|
|
|
|
- display: inline;
|
|
|
|
- /*margin-top: 5px;*/
|
|
|
|
- margin-left: 30px;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .contentLine div {
|
|
|
|
- margin: 5px 0 0;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .border {
|
|
|
|
- /*border: 1px solid #b7b6b6;*/
|
|
|
|
- border-radius: 5px;
|
|
|
|
- padding: 10px;
|
|
|
|
- background-color: white;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- body {
|
|
|
|
- background-color: #f4f4f5;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .myTop {
|
|
|
|
- position: fixed;
|
|
|
|
- top: 0;
|
|
|
|
- background-image: url("./img/gray.png");
|
|
|
|
- /* 背景铺满整个div*/
|
|
|
|
- background-size: 100% 100%;
|
|
|
|
- width: 100%;
|
|
|
|
- padding: 10px;
|
|
|
|
- z-index: 100;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .myText {
|
|
|
|
- border: 1px solid #d2d2d2;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .vditor-reset {
|
|
|
|
- padding: 10px 20px !important;
|
|
|
|
- }
|
|
|
|
-
|
|
|
|
- .vditor-toolbar {
|
|
|
|
- display: none;
|
|
|
|
- }
|
|
|
|
- </style>
|
|
|
|
|
|
+ <link rel="stylesheet" href="memos.css" />
|
|
<script src="js/vue.min.js"></script>
|
|
<script src="js/vue.min.js"></script>
|
|
<script src="elementUI/index.js"></script>
|
|
<script src="elementUI/index.js"></script>
|
|
<link rel="stylesheet" href="elementUI/index.css" />
|
|
<link rel="stylesheet" href="elementUI/index.css" />
|
|
@@ -428,19 +364,11 @@
|
|
</span>
|
|
</span>
|
|
</el-dialog>
|
|
</el-dialog>
|
|
</div>
|
|
</div>
|
|
- <!-- 引入Quill库 -->
|
|
|
|
- <!--<script src="./js/cdn.quilljs.com_1.3.6_quill.js"></script>-->
|
|
|
|
<!--异步请求示例:requestUtil.sync('https://jsonplaceholder.typicode.com/posts/1', 'post', data, headers) .then(data => console.log(data))-->
|
|
<!--异步请求示例:requestUtil.sync('https://jsonplaceholder.typicode.com/posts/1', 'post', data, headers) .then(data => console.log(data))-->
|
|
<script>
|
|
<script>
|
|
- // if (getQueryString("id") !== "tianyunperfect") {
|
|
|
|
- // // location.href = "http://127.0.0.1";
|
|
|
|
- // }
|
|
|
|
-
|
|
|
|
- let authStr =
|
|
|
|
- "bearer eyJhbGciOiJIUzI1NiIsImtpZCI6InYxIiwidHlwIjoiSldUIn0.eyJuYW1lIjoidGlhbnl1bnBlcmZlY3QiLCJpc3MiOiJtZW1vcyIsInN1YiI6IjEiLCJhdWQiOlsidXNlci5hY2Nlc3MtdG9rZW4iXSwiaWF0IjoxNzA5MTc5NTUyfQ.LFxWB4efya1sL7VoJ42xpXxbAip-udT_Kx2OwZ8Y3-E";
|
|
|
|
let myHeaders = {
|
|
let myHeaders = {
|
|
"Content-type": "application/json",
|
|
"Content-type": "application/json",
|
|
- Authorization: authStr,
|
|
|
|
|
|
+ Authorization: "",
|
|
};
|
|
};
|
|
|
|
|
|
function getRandomId() {
|
|
function getRandomId() {
|
|
@@ -486,33 +414,17 @@
|
|
console.log(2);
|
|
console.log(2);
|
|
this.contentList.forEach((item) => {
|
|
this.contentList.forEach((item) => {
|
|
this.resetView(item);
|
|
this.resetView(item);
|
|
- // let ed = new Vditor(item.resource_name, {
|
|
|
|
- // cdn: 'https://ld246.com/js/lib/vditor',
|
|
|
|
- // // height: 360,
|
|
|
|
- // toolbarConfig: {
|
|
|
|
- // pin: true,
|
|
|
|
- // },
|
|
|
|
- // // preview: {
|
|
|
|
- // // theme:{
|
|
|
|
- // // path: ''
|
|
|
|
- // // }
|
|
|
|
- // // },
|
|
|
|
- // theme: 'classic',
|
|
|
|
- // cache: {
|
|
|
|
- // enable: false,
|
|
|
|
- // },
|
|
|
|
- // after: () => {
|
|
|
|
- // ed.setValue(item.content)
|
|
|
|
- // },
|
|
|
|
- // })
|
|
|
|
});
|
|
});
|
|
});
|
|
});
|
|
},
|
|
},
|
|
},
|
|
},
|
|
mounted() {
|
|
mounted() {
|
|
if (!checkLogin()) {
|
|
if (!checkLogin()) {
|
|
- return;
|
|
|
|
|
|
+ // 警告并刷新页面
|
|
|
|
+ alert("登录失败,请先登录");
|
|
|
|
+ location.reload();
|
|
}
|
|
}
|
|
|
|
+ myHeaders.Authorization = "bearer " + getCookie("token");
|
|
if (this.getQueryStr()) {
|
|
if (this.getQueryStr()) {
|
|
this.searchStr = this.getQueryStr();
|
|
this.searchStr = this.getQueryStr();
|
|
}
|
|
}
|
|
@@ -1008,7 +920,7 @@
|
|
{ ids: ids },
|
|
{ ids: ids },
|
|
{}
|
|
{}
|
|
);
|
|
);
|
|
- // {'code': 200, 'res': [{'memo_id': 1, 'resource_name': 'EfdmvRsodBviDQWRmDiTaV'}, {'memo_id': 4, 'resource_name': '2rY5kmn3AHsy23vK4vSskV'}, {'memo_id': 7, 'resource_name': 'FMhzJXjoTa7fdtbbCBjXnt'}]}
|
|
|
|
|
|
+ // {'code': 200, 'res': [{'memo_id': 1, 'resource_name': 'EfdmvRsodBviDQWRmDiTaV'}]}
|
|
// 循环遍历,以memo_id为key,resource_name数组为value
|
|
// 循环遍历,以memo_id为key,resource_name数组为value
|
|
sourceRes["res"].forEach((item) => {
|
|
sourceRes["res"].forEach((item) => {
|
|
if (this.resourceMap[item["memo_id"]]) {
|
|
if (this.resourceMap[item["memo_id"]]) {
|