提交 6eac8e6b authored 作者: 刘旭's avatar 刘旭

更新

上级 45e13e52
import request from "@/utils/request"
import request from "@/utils/request";
// 登录
export const getUserInfo = (code: string) => {
alert(code)
alert(code);
request(
"/LQKJ.K3.PeiXunSystem.WebApi.WebApiService.User,LQKJ.K3.PeiXunSystem.WebApi.common.kdsvc",
"POST",
{ code }
)
}
);
};
// 注册
export const register = (data: any) => {
......@@ -16,8 +16,8 @@ export const register = (data: any) => {
"/LQKJ.K3.PeiXunSystem.WebApi.WebApiEditService.Quit,LQKJ.K3.PeiXunSystem.WebApi.common.kdsvc",
"POST",
data
)
}
);
};
// 上传图片
export const uploadImage = (data: any) => {
......@@ -25,8 +25,8 @@ export const uploadImage = (data: any) => {
"/LQKJ.K3.PeiXunSystem.WebApi.WebApiEditService.Image,LQKJ.K3.PeiXunSystem.WebApi.common.kdsvc",
"POST",
data
)
}
);
};
/**
* @brief 手机密码登录
......@@ -38,4 +38,4 @@ export const teachLogin = (data: any) =>
"/LQKJ.K3.PeiXunSystem.WebApi.WebApiService.TeachLogin,LQKJ.K3.PeiXunSystem.WebApi.common.kdsvc",
"POST",
data
)
);
......@@ -42,6 +42,7 @@
</view>
<view
style="
width: 30%;
display: flex;
flex-direction: column;
align-items: end;
......@@ -78,7 +79,7 @@
<template #foot>
<view class="course-footer">
<view>所属班级:{{ courseItem.className }}</view>
<view @tap="toSeeMore">
<view @tap="toSeeMore" style="width: 40%; text-align: end">
<text>查看更多 </text>
<u-icon name="arrow-right-double" color="#05A8FF" size="24" />
</view>
......@@ -327,7 +328,7 @@ const collapseChange = (e: any) => {
.course-collapse-footer {
display: flex;
justify-content: space-between;
align-items: center;
align-items: flex-start;
font-size: 24rpx;
font-weight: 400;
color: rgba(34, 34, 34, 0.5);
......
......@@ -50,7 +50,7 @@
</template>
<template #foot>
<view class="foot">
<text>{{ lecturerItem.FINTRODUCE }}</text>
<text @click="toSeeMore">{{ lecturerItem.FINTRODUCE }}</text>
</view>
</template>
</u-card>
......@@ -61,6 +61,7 @@
<script setup lang="ts">
import { baseUrl } from "@/utils/request";
import { hidePhoneNumber, toast } from "@/utils/util";
import { useCourseStore } from "@/store/modules/courseStore";
import taughtsPopup from "./taughtsPopup.vue";
const props = defineProps({
......@@ -69,6 +70,7 @@ const props = defineProps({
} as any,
});
const courseStore = useCourseStore();
const show = ref(false);
const taughtsRef = ref();
......@@ -96,9 +98,24 @@ const downTitleImage = () => {
const showTaughts = () => {
taughtsRef.value.taughtList = props.lecturerItem.FCANCOURSES;
console.log(taughtsRef.value.taughtList);
show.value = true;
};
const toSeeMore = () => {
let data = [
{
Url: props.lecturerItem.FPHOTO,
teachName: props.lecturerItem.FNAME,
teachMsg: props.lecturerItem.FINTRODUCE,
},
];
courseStore.setTeachs(data);
setTimeout(() => {
uni.navigateTo({
url: "/pages/course/seeMore",
});
}, 300);
};
</script>
<style lang="scss" scoped>
......@@ -147,6 +164,7 @@ const showTaughts = () => {
font-size: 28rpx;
font-weight: 400;
color: #666666;
margin-right: 10rpx;
}
}
}
......
......@@ -4,17 +4,18 @@
<view class="search">
<view class="search-btn">属地</view>
<u-input
v-model="listQuery.territoriality"
v-model="listQuery.Sd"
placeholder=""
border
border-color="#F8F8F8"
@confirm="search($event, 'Sd')"
/>
<uni-search-bar
placeholder="关键词"
bgColor="#ffffff"
clearButton="auto"
cancelButton="none"
@confirm="search"
@confirm="search($event)"
/>
</view>
<view v-if="teachPointsList.length">
......@@ -47,12 +48,12 @@ const listQuery = reactive({
pageSize: 10,
total: 0,
Area: "",
territoriality: "",
Sd: "",
});
const search = (val: any) => {
const search = (val: any, type?: string) => {
if (type !== "Sd") listQuery.Area = val.value;
teachPointsList.value = [];
listQuery.Area = val.value;
init();
};
......@@ -73,7 +74,7 @@ const init = async () => {
if (res.code == 200) {
if (res.total > 10) status.value = "loadmore";
else status.value = "nomore";
teachPointsList.value = [...teachPointsList.value, ...res.data];
teachPointsList.value = [...teachPointsList.value, ...(res.data || [])];
listQuery.total = res.total;
console.log(teachPointsList.value);
} else status.value = "nomore";
......
......@@ -3,14 +3,14 @@ export const useCourseStore = defineStore({
state() {
return {
Teachs: [],
}
};
},
getters: {
getTeachs: (state: any) => state.Teachs,
},
actions: {
async setTeachs(Teachs: any) {
this.Teachs = Teachs
this.Teachs = Teachs;
},
},
})
});
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论