This commit is contained in:
lyc 2024-11-07 14:14:46 +08:00
parent d05e50218d
commit 756d7fdaa1
4 changed files with 124 additions and 89 deletions

View File

@ -0,0 +1,39 @@
<template>
<div class="container-header flex">
<div class="header-left flex">
<el-button link>
高中语文课程标准<i class="iconfont icon-xiangxia"></i>
</el-button>
</div>
<div class="header-right flex">
<el-button link>
课标研读模板一<i class="iconfont icon-xiangxia"></i>
</el-button>
</div>
</div>
</template>
<script setup>
</script>
<style lang="scss" scoped>
.container-header {
height: 45px;
background: #fff;
border-radius: 5px 5px 0 0;
box-shadow: 0px 0px 20px 0px rgba(99, 99, 99, 0.06);
.header-left {
width: 50%;
align-items: center;
padding-left: 20px;
}
.icon-xiangxia {
margin-left: 5px;
font-weight: bold;
}
}
</style>

View File

@ -0,0 +1,13 @@
<template>
<div class="page-template">
<Header/>
</div>
</template>
<script setup>
import Header from './container/header.vue'
</script>
<style lang="scss" scoped>
</style>

View File

@ -1,75 +1,50 @@
<template> <template>
<div class="read-container"> <div class="read-container">
<el-scrollbar height="100%">
<div class="template-list" v-loading="loading">
<el-row v-for="item in 6">
<el-col :span="24">
<div class="template-item">
<div class="item-header"><span class="blue">#</span>{{ item }}</div>
<div class="item-text" >
<div class="item-icon">
<i class="iconfont icon-ai"></i>
</div>
<div class="item-answer" v-html="item"></div>
</div>
</div>
</el-col>
</el-row>
<div class="template-list"> <!-- <el-row>
<el-row> <el-col :span="24">
<el-col :span="24"> <div class="template-item template-item-result">
<div class="template-item"> <div class="result-item-header">
<div class="item-header"><span class="blue">#</span>核心素养与课程目标</div> <i class="iconfont icon-xiaoxi"></i>
<div class="item-text" > 语言建构与运用是指学生在丰富的语言实践中通过主动的积累梳理和整合逐步掌握祖国语言文字特点及其运用规律形成个体言语经验......
<div class="item-icon">
<i class="iconfont icon-ai"></i>
</div> </div>
<div class="item-answer" v-html="str"></div> <div class="result-icon-btn flex pl-25">
</div> <div class="flex">
</div> <span><i class="iconfont icon-fuzhi"></i>复制</span>
</el-col> <span><i class="iconfont icon-bianji-gangbi"></i>写想法</span>
</el-row> </div>
<el-row> <div>
<el-col :span="24"> <span><i class="iconfont icon-tianjia"></i>加入备课篮</span>
<div class="template-item"> </div>
<div class="item-header"><span class="blue">#</span>课程内容相关</div>
<div class="item-text">研读课程标准提取出与本课相关的课程内容要求
</div>
</div>
</el-col>
</el-row>
<el-row>
<el-col :span="24">
<div class="template-item">
<div class="item-header"><span class="blue">#</span>学业质量要求</div>
<div class="item-text">研读课程标准提取出与本课相关的学业水平要求包括水平一水平二水平三各自的要求描述
</div>
</div>
</el-col>
</el-row>
<el-row>
<el-col :span="24">
<div class="template-item">
<div class="item-header"><span class="blue">#</span>教学实施建议</div>
<div class="item-text">研读课程标准提取出与本课相关的教学实施建议
</div>
</div>
</el-col>
</el-row>
<el-row>
<el-col :span="24">
<div class="template-item template-item-result">
<div class="result-item-header">
<i class="iconfont icon-xiaoxi"></i>
语言建构与运用是指学生在丰富的语言实践中通过主动的积累梳理和整合逐步掌握祖国语言文字特点及其运用规律形成个体言语经验......
</div>
<div class="result-icon-btn flex pl-25">
<div class="flex">
<span><i class="iconfont icon-fuzhi"></i>复制</span>
<span><i class="iconfont icon-bianji-gangbi"></i>写想法</span>
</div> </div>
<div> <div class="line"></div>
<span><i class="iconfont icon-tianjia"></i>加入备课篮</span> <div class="other-msg pl-25">
<div class="other-user flex">
<i class="iconfont icon-touxiang"></i>
重庆市酉阳县二中 - 李丽
</div>
<div class="other-text flex">北师大王宁老师说语言建构有两方面的含义一是指出于表达思想的目的二是指在个人言语经验的基础上逐步建构起自己的言语体系</div>
</div> </div>
</div> </div>
<div class="line"></div> </el-col>
<div class="other-msg pl-25"> </el-row> -->
<div class="other-user flex"> </div>
<i class="iconfont icon-touxiang"></i> </el-scrollbar>
重庆市酉阳县二中 - 李丽
</div>
<div class="other-text flex">北师大王宁老师说语言建构有两方面的含义一是指出于表达思想的目的二是指在个人言语经验的基础上逐步建构起自己的言语体系</div>
</div>
</div>
</el-col>
</el-row>
</div>
</div> </div>
</template> </template>
@ -90,6 +65,8 @@ const props = defineProps({
} }
}) })
const loading = ref(false)
// ID // ID
const params = reactive( const params = reactive(
{ {
@ -108,43 +85,43 @@ const curNode = reactive({})
const getConversation = async() =>{ const getConversation = async() =>{
const { user: { userId } } = userStore const { user: { userId } } = userStore
const result = await conversation({ user_id: String(userId) }) const result = await conversation({ user_id: String(userId) })
console.log('result=====',result)
params.conversation_id = result.data.data.id params.conversation_id = result.data.data.id
getCompletion() getCompletion()
} }
// //
const resultList = ref([])
const getCompletion = async() =>{ const getCompletion = async() =>{
console.log('params=====>',params) console.log('params=====>',params)
for (const item of props.curTemp) { for (const item of props.curTemp) {
try { try {
console.log(item.name) loading.value = true
params.messages[0].content = `根据${curNode.edustage}语文课标,提炼出${item.name}` params.messages[0].content = `根据${curNode.edustage}语文课标,提炼出${item.name}`
completion(params).then(res =>{ const res = await completion(params)
console.log('对话结果===》', res) console.log('对话结果===》', res)
let answer = res.data.data.answer let answer = res.data.data.answer
const arr = getResult(answer); answer = getResult(answer);
console.log(arr,'arr') resultList.value.push({
title: item.name,
answer
}) })
} finally{ } finally{
loading.value = false
} }
} }
} }
// //
let getResult = () => { let getResult = (text) => {
let text = "根据高中的语文课程标准和相关内容,我总结出了以下的核心素养和课标目标:\n\n**核心素养:**\n\n1. 语言建构与运用Language Construction and Application学生能够正确地使用语言文字表达思想、情感和经验。\n2. 思维发展与提升Thinking Development and Enhancement学生能够独立思考、分析问题、解决问题并且具有良好的思维品质。\n3. 审美鉴赏与创造Aesthetic Appreciation and Creation学生能够欣赏和理解不同类型的文学作品具备自觉的审美意识和高尚的审美情趣。\n4. 文化传承与理解Cultural Heritage and Understanding学生能够了解和尊重中国文化、历史和社会背景并且具有良好的文化素养。\n\n**课标目标:**\n\n1. 提升学生综合素质,着力发展核心素养,使学生具有理想信念和社会责任感。\n2. 培养学生的语言文字运用能力,掌握学习语文的基本方法,养成良好的学习习惯。\n3. 提高学生思维能力的发展与思维品质的提升,让学生能够独立思考、分析问题、解决问题。\n4. 培养学生自觉的审美意识和高尚的审美情趣,让学生在语言文字运用的学习中受到美的熏陶。\n\n这些核心素养和课标目标是根据高中语文课程标准提炼出来的旨在帮助教师更好地指导学生发展核心素养并且提高学生综合素质。" text = text.replace(/^\n\n(.*?)\n\n$/s, '<div>$1</div>');
str.value = text.replace(/^\n\n(.*?)\n\n$/s, '<div>$1</div>'); text = text.replace(/^\n(.*?)\n$/s, '<p>$1</p>');
str.value = str.value.replace(/^\n(.*?)\n$/s, '<p>$1</p>'); text = text.replace(/\*\*(.*?)\*\*/g, "<div class='text-tit'>$1</div>");
str.value = str.value.replace(/\*\*(.*?)\*\*/g, "<div class='text-tit'>$1</div>"); text = text.replace(/(\d+\..*?)\n/g, "<div class='text-num'>$1</div>\n");
str.value = str.value.replace(/(\d+\..*?)\n/g, "<div class='text-num'>$1</div>\n"); return text
console.log(str.value)
} }
@ -153,17 +130,18 @@ onMounted(() => {
Object.assign(curNode, data); Object.assign(curNode, data);
console.log(props.curTemp,'curTemp') console.log(props.curTemp,'curTemp')
// getConversation() // getConversation()
// getResult()
//
getCompletion()
}) })
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.read-container { .read-container {
display: flex;
flex-direction: column;
width: 100%;
padding: 15px; padding: 15px;
height: 100%;
.el-dropdown-link { .el-dropdown-link {
font-weight: bold; font-weight: bold;
@ -186,6 +164,9 @@ onMounted(() => {
} }
} }
.right-con{
display: flex;
}
.template-list { .template-list {

View File

@ -1,5 +1,6 @@
<template> <template>
<div class="page-curriculum flex"> <TemplateStudy/>
<!-- <div class="page-curriculum flex">
<el-row> <el-row>
<el-col :span="12" class="flex"> <el-col :span="12" class="flex">
<div class="page-left"> <div class="page-left">
@ -38,11 +39,12 @@
</div> </div>
</el-col> </el-col>
</el-row> </el-row>
</div> </div> -->
</template> </template>
<script setup> <script setup>
import { ref } from 'vue' import { ref } from 'vue'
import TemplateStudy from '@/components/template-study/index.vue'
import ReadTemplate from './container/read-template.vue'; import ReadTemplate from './container/read-template.vue';
import QuestionAnswer from './container/question-answer.vue' import QuestionAnswer from './container/question-answer.vue'
import ReadResult from './container/read-result.vue' import ReadResult from './container/read-result.vue'