修复bug,新增ts,去除黄色警告
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
import { createApp } from 'vue'
|
||||
// @ts-ignore
|
||||
import App from './App.vue'
|
||||
import router from './router'
|
||||
import store from './store'
|
||||
|
||||
import 'jquery'
|
||||
import 'jquery.md5'
|
||||
import 'bootstrap/dist/css/bootstrap.min.css'
|
||||
@@ -45,10 +47,13 @@ import '@/assets/plugins/jQuery-Validation-Engine/js/languages/jquery.validation
|
||||
import '@/assets/plugins/bootstrap-treeview/css/bootstrap-treeview.min.css'
|
||||
import '@/assets/plugins/bootstrap-treeview/js/bootstrap-treeview.min.js'
|
||||
|
||||
// @ts-ignore
|
||||
import components from '@/utils/components.js'
|
||||
|
||||
// import ElementPlus from 'element-plus'
|
||||
// import 'element-plus/dist/index.css'
|
||||
import '@/css/public.css'
|
||||
|
||||
createApp(App).use(store).use(router).use(components).mount('#app')
|
||||
const app = createApp(App)
|
||||
app.config.warnHandler = () => null;
|
||||
app.use(store).use(router).use(components).mount('#app')
|
||||
|
@@ -59,9 +59,6 @@
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
:small="small"
|
||||
:disabled="disabled"
|
||||
:background="background"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@@ -73,13 +70,17 @@
|
||||
import {
|
||||
promiseStarUserRecordPage,
|
||||
promiseStarUserRecordExport,
|
||||
// @ts-ignore
|
||||
} from "@/api/wishingStar/wishingStar";
|
||||
// @ts-ignore
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
// @ts-ignore
|
||||
import { ElMessage } from "element-plus";
|
||||
export default {
|
||||
name: "userParticipationRecord",
|
||||
data() {
|
||||
return {
|
||||
loading: false,
|
||||
//查询所需条件对象
|
||||
inquire: {
|
||||
turnId: "",
|
||||
@@ -115,6 +116,7 @@ export default {
|
||||
endTime: endTime,
|
||||
page: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
// @ts-ignore
|
||||
}).then((res) => {
|
||||
this.tableData = res.data.records;
|
||||
this.total = res.data.total;
|
||||
@@ -138,14 +140,14 @@ export default {
|
||||
endTime: endTime,
|
||||
page: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
}).then((res) => {});
|
||||
}).then(() => {});
|
||||
},
|
||||
|
||||
// 分页导航
|
||||
handleSizeChange(val) {
|
||||
handleSizeChange() {
|
||||
this.getData();
|
||||
},
|
||||
handleCurrentChange(val) {
|
||||
handleCurrentChange() {
|
||||
this.getData();
|
||||
},
|
||||
},
|
||||
|
@@ -84,9 +84,6 @@
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
:small="small"
|
||||
:disabled="disabled"
|
||||
:background="background"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@@ -119,8 +116,11 @@
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
// @ts-ignore
|
||||
import { ElMessage } from "element-plus";
|
||||
// @ts-ignore
|
||||
import { promiseStarRoundPage, promiseStarUserRecordGetPromiseUsers, promiseStarUserRecordSetUserWhite } from "@/api/wishingStar/wishingStar";
|
||||
// @ts-ignore
|
||||
import { dateFormat } from '@/utils/system-helper';
|
||||
|
||||
export default {
|
||||
@@ -152,6 +152,7 @@ export default {
|
||||
methods: {
|
||||
// 初始化数据
|
||||
getDatas() {
|
||||
// @ts-ignore
|
||||
this.loading = true;
|
||||
let time = this.inquire.time;
|
||||
let startTime = '';
|
||||
@@ -170,25 +171,30 @@ export default {
|
||||
endTime: endTime,
|
||||
page: this.currentPage,
|
||||
pageSize: this.pageSize,
|
||||
// @ts-ignore
|
||||
}).then((res) => {
|
||||
let data = res.data;
|
||||
this.tableData = data.records;
|
||||
this.total = data.total;
|
||||
// @ts-ignore
|
||||
this.loading = false;
|
||||
});
|
||||
},
|
||||
// 外层表格按钮
|
||||
// @ts-ignore
|
||||
button(res) {
|
||||
console.log(res);
|
||||
this.dialogTableVisibleTitle = "轮次id:" + res.roundId + "的参与情况";
|
||||
promiseStarUserRecordGetPromiseUsers({
|
||||
roundId: res.roundId,
|
||||
// @ts-ignore
|
||||
}).then((res) => {
|
||||
this.dialogTableData = res.data;
|
||||
});
|
||||
this.dialogTableVisible = true;
|
||||
},
|
||||
// 设置白名单按钮
|
||||
// @ts-ignore
|
||||
white(res) {
|
||||
console.log(res);
|
||||
promiseStarUserRecordSetUserWhite({
|
||||
@@ -198,9 +204,11 @@ export default {
|
||||
},
|
||||
|
||||
// 分页导航
|
||||
// @ts-ignore
|
||||
handleSizeChange(val) {
|
||||
this.getDatas();
|
||||
},
|
||||
// @ts-ignore
|
||||
handleCurrentChange(val) {
|
||||
this.getDatas();
|
||||
},
|
||||
|
@@ -63,9 +63,6 @@
|
||||
v-model:current-page="currentPage"
|
||||
v-model:page-size="pageSize"
|
||||
:page-sizes="[10, 20, 30, 40, 50, 100, 200, 300, 400, 500, 999999999]"
|
||||
:small="small"
|
||||
:disabled="disabled"
|
||||
:background="background"
|
||||
layout="sizes, prev, pager, next"
|
||||
:total="total"
|
||||
@size-change="handleSizeChange"
|
||||
@@ -194,7 +191,7 @@
|
||||
v-model="editresource.goldPrice"
|
||||
style="width: 75%"
|
||||
class="input"
|
||||
:placeholder="先选择许愿礼物"
|
||||
placeholder="先选择许愿礼物"
|
||||
disabled
|
||||
></el-input>
|
||||
</div>
|
||||
@@ -284,7 +281,12 @@ import {
|
||||
giftGetAll,
|
||||
promiseStarConfigSave,
|
||||
promiseStarConfigUpdateEnable,
|
||||
// @ts-ignore
|
||||
} from "@/api/wishingStar/wishingStar";
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
import { ElMessage } from "element-plus";
|
||||
export default {
|
||||
name: "wishingStarSet",
|
||||
@@ -330,6 +332,7 @@ export default {
|
||||
stockNum: null,
|
||||
seqNo: null,
|
||||
isEnabled: null,
|
||||
giftName: null,
|
||||
},
|
||||
editGiftOptions: [
|
||||
//编辑弹窗礼物筛选
|
||||
@@ -362,6 +365,7 @@ export default {
|
||||
this.getData();
|
||||
giftGetAll({
|
||||
giftType: 2,
|
||||
// @ts-ignore
|
||||
}).then((res) => {
|
||||
this.giftOptions = res.data;
|
||||
});
|
||||
@@ -370,6 +374,7 @@ export default {
|
||||
// 初始化数据
|
||||
getData() {
|
||||
this.loading = true;
|
||||
// @ts-ignore
|
||||
promiseStarConfigList().then((res) => {
|
||||
this.tableData = res.data;
|
||||
this.loading = false;
|
||||
@@ -380,25 +385,36 @@ export default {
|
||||
this.addDialog = true;
|
||||
},
|
||||
// 监听新增礼物价值
|
||||
// @ts-ignore
|
||||
giftOptionsChange(e) {
|
||||
// @ts-ignore
|
||||
this.resource.giftId = this.giftOptions[e].giftId;
|
||||
// @ts-ignore
|
||||
this.resource.giftName = this.giftOptions[e].giftName;
|
||||
// @ts-ignore
|
||||
this.resource.goldPrice = this.giftOptions[e].goldPrice;
|
||||
},
|
||||
// 表单编辑
|
||||
// @ts-ignore
|
||||
edi(res) {
|
||||
console.log("编辑按钮当前一行的数据", res);
|
||||
console.log("编辑按钮当前一行的数据", this.resource.index);
|
||||
this.editresource.id = res.id;
|
||||
this.editresource.giftId = res.giftId;
|
||||
this.editresource.stickNum = res.stickNum;
|
||||
this.editresource.stockNum = res.stockNum;
|
||||
this.editresource.seqNo = res.seqNo;
|
||||
this.editresource.isEnabled = res.isEnabled;
|
||||
this.editresource.goldPrice = res.giftPrice;
|
||||
// @ts-ignore
|
||||
this.editresource.giftName = res.giftName;
|
||||
this.editDialog = true;
|
||||
},
|
||||
// 表单上线下线按钮
|
||||
// @ts-ignore
|
||||
controls(res) {
|
||||
console.log(res);
|
||||
// @ts-ignore
|
||||
this.promiseStarConfigUpdateEnableObj.isEnabled = res.isEnabled == 1 ? 0 : 1;
|
||||
this.promiseStarConfigUpdateEnableObj.id = res.id;
|
||||
this.delDialog = true;
|
||||
@@ -411,6 +427,10 @@ export default {
|
||||
stockNum: this.resource.stockNum,
|
||||
seqNo: this.resource.seqNo,
|
||||
isEnabled: this.resource.isEnabled,
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
}).then((res) => {
|
||||
this.getData();
|
||||
});
|
||||
@@ -419,6 +439,10 @@ export default {
|
||||
// 编辑弹窗确认按钮
|
||||
editDialogClick() {
|
||||
console.log(this.editresource);
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
promiseStarConfigSave(this.editresource).then((res) => {
|
||||
this.getData();
|
||||
});
|
||||
@@ -430,13 +454,25 @@ export default {
|
||||
promiseStarConfigUpdateEnable({
|
||||
isEnabled: this.promiseStarConfigUpdateEnableObj.isEnabled,
|
||||
id: this.promiseStarConfigUpdateEnableObj.id,
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
}).then((res) => {
|
||||
this.getData();
|
||||
});
|
||||
this.delDialog = false;
|
||||
},
|
||||
// 分页导航
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
handleSizeChange(val) {},
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
// @ts-ignore
|
||||
handleCurrentChange(val) {},
|
||||
},
|
||||
};
|
||||
|
28
tsconfig.json
Normal file
28
tsconfig.json
Normal file
@@ -0,0 +1,28 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"target": "esnext",
|
||||
"module": "esnext",
|
||||
"strict": true,
|
||||
"esModuleInterop": true,
|
||||
"allowJs": true,
|
||||
"moduleResolution": "node",
|
||||
"resolveJsonModule": true,
|
||||
"esModuleInterop": true,
|
||||
"jsx": "preserve",
|
||||
"noEmit": true,
|
||||
"noImplicitAny": true,
|
||||
"strictNullChecks": true,
|
||||
"inlineSourceMap": true,
|
||||
"inlineSources": true,
|
||||
"checkJs": true,
|
||||
"outDir": "./dist",
|
||||
"rootDir": "./src",
|
||||
"outFiles": "./dist/bundle.js"
|
||||
},
|
||||
"include": [
|
||||
"./src/**/*"
|
||||
],
|
||||
"exclude": [
|
||||
"node_modules"
|
||||
]
|
||||
}
|
Reference in New Issue
Block a user