|
@@ -1,150 +1,12 @@
|
|
|
-<script setup lang="ts">
|
|
|
-import { getImageUrl, imagePreview } from "@/utils";
|
|
|
-import { useCustomizeStore } from "@/store";
|
|
|
-import { useRoute } from "vue-router";
|
|
|
-import HeaderPart from "@/views/customize/components/HeaderPart.vue";
|
|
|
-import { ISingleRecord } from "@/types/customize.d";
|
|
|
-import { computed, onMounted, ref } from "vue";
|
|
|
-import ConfirmJoin from "@/views/customize/components/ConfirmJoin.vue";
|
|
|
-
|
|
|
-const { b: babyId, i: id, p: isParent, o: isMyRoute } = useRoute().query;
|
|
|
-
|
|
|
-const customizeStore = useCustomizeStore();
|
|
|
-
|
|
|
-const { getSingleRecord, sendSingleRecord, joinSemesterReport } = customizeStore;
|
|
|
-
|
|
|
-const showConfirm = ref(false);
|
|
|
-
|
|
|
-const singleRecord = computed<ISingleRecord>(() => {
|
|
|
- // return customizeStore.singleRecord;
|
|
|
- return {
|
|
|
- "recordId": "1782591626363899905",
|
|
|
- "babyId": "1382262152722042882",
|
|
|
- "sendReport": 0,
|
|
|
- "recordDate": "2024-04-23",
|
|
|
- "teacherName": "雷lEi\uD83C\uDF88",
|
|
|
- "babyNames": [
|
|
|
- "王凯昊"
|
|
|
- ],
|
|
|
- "joinSemester": 1,
|
|
|
- "sceneName": "区域活动",
|
|
|
- "story": {
|
|
|
- "images": [
|
|
|
- "https://app-resources-luojigou.luojigou.vip/3649ac71b59e4fb1b8c025928c70e37e"
|
|
|
- ],
|
|
|
- "videos": [],
|
|
|
- "content": ""
|
|
|
- },
|
|
|
- "domainList": [
|
|
|
- {
|
|
|
- "domainName": "逻辑思维通用领域",
|
|
|
- "abilityList": [
|
|
|
- {
|
|
|
- "abilityName": "批判思维能力",
|
|
|
- "description": {
|
|
|
- "growth": "S1.在成人的帮助下,幼儿能够模仿其他学生的作品(例:运用自己喜欢的相似的材料)。",
|
|
|
- "behave": "看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
- "behaviours": [],
|
|
|
- "example": "无",
|
|
|
- "tactics": "【环创】:\n1.创作机会和条件,支持幼儿自发的艺术表现和创造。\n2.为幼儿提供丰富的便于幼儿取放的材料、工具或物品。\n【师幼】:\n1.和幼儿一起发现并感受周边事物的特征。\n2.倾听幼儿的所见所想,鼓励幼儿大胆表达。",
|
|
|
- "education": "1.家长可以和幼儿一起玩串珠的游戏,家长示范,幼儿模仿。\n2.家长可以和幼儿一起进行阅读绘本,一起模仿绘本里动物或者人物的动作、声音和表情等。"
|
|
|
- },
|
|
|
- "descriptionExtra": {
|
|
|
- "growth": "",
|
|
|
- "behave": "2024年04月23日,在来来来,王凯昊、朱婷、陈树炎、李佩、雷晴、刘雯雯、孙艺洲、钱小豪、宝宝、田甜小朋友正在来来来活动。\n看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
- "behaviours": [],
|
|
|
- "example": "",
|
|
|
- "tactics": "来来来12345",
|
|
|
- "education": ""
|
|
|
- }
|
|
|
- }
|
|
|
- ]
|
|
|
- }
|
|
|
- ]
|
|
|
- }
|
|
|
-});
|
|
|
-const isImages = computed(() => {
|
|
|
- return singleRecord.value.story?.images.length !== 0;
|
|
|
-});
|
|
|
-const isVideo = computed(() => {
|
|
|
- return singleRecord.value.story?.videos.length !== 0;
|
|
|
-});
|
|
|
-const isContent = computed(() => {
|
|
|
- return singleRecord.value.story?.content && singleRecord.value.story?.content.length !== 0;
|
|
|
-});
|
|
|
-const isHas = computed(() => {
|
|
|
- return singleRecord.value.story && (isImages.value || isVideo.value || isContent.value);
|
|
|
-});
|
|
|
-
|
|
|
-async function confirm() {
|
|
|
- // console.log("confirm");
|
|
|
- await joinSemesterReport(singleRecord.value.recordId, 0);
|
|
|
- showConfirm.value = false;
|
|
|
-}
|
|
|
-
|
|
|
-function formatNames(names: string[]) {
|
|
|
- let str = "";
|
|
|
- names.map((name, nameIndex) => {
|
|
|
- if (nameIndex !== 0) {
|
|
|
- str += "、";
|
|
|
- }
|
|
|
- str += name;
|
|
|
- });
|
|
|
- return str;
|
|
|
-}
|
|
|
-
|
|
|
-function send() {
|
|
|
- if (singleRecord.value.sendReport) return;
|
|
|
- if (typeof babyId === "string" && typeof id === "string")
|
|
|
- sendSingleRecord({
|
|
|
- babyId,
|
|
|
- id,
|
|
|
- recordType: "1",
|
|
|
- });
|
|
|
-}
|
|
|
-
|
|
|
-function changeJoinState() {
|
|
|
- if (singleRecord.value.joinSemester === 1) {
|
|
|
- showConfirm.value = true;
|
|
|
- } else {
|
|
|
- joinSemesterReport(singleRecord.value.recordId, 1);
|
|
|
- }
|
|
|
-}
|
|
|
-
|
|
|
-function getStyle(index: number, length: number) {
|
|
|
- return {
|
|
|
- borderRadius: `${
|
|
|
- length === 1 ? "17px" : index === 0 ? "17px 17px 0 0" : index === length - 1 ? "0 0 17px 17px" : "0"
|
|
|
- }`,
|
|
|
- borderTop: `${index === 0 ? "4px solid #b6dcff" : "none"}`,
|
|
|
- borderBottom: `${index === length - 1 ? "4px solid #b6dcff" : "none"}`,
|
|
|
- boxShadow: `${index === 0 ? "0 1px 6px 0 rgba(42, 105, 253, 0.16)" : "none"}`,
|
|
|
- };
|
|
|
-}
|
|
|
-
|
|
|
-onMounted(async () => {
|
|
|
- // await getTestTeachToken();
|
|
|
-
|
|
|
- if (typeof babyId === "string" && typeof id === "string") await getSingleRecord(babyId, id);
|
|
|
-});
|
|
|
-
|
|
|
-/**
|
|
|
- * 行为记录单次报告
|
|
|
- *
|
|
|
- * b: babyId
|
|
|
- * i: recordId
|
|
|
- *
|
|
|
- * http://192.168.1.17:8989/#/customize/SingleReport?b=1304672468777553921&i=1716737882201264130
|
|
|
- */
|
|
|
-</script>
|
|
|
|
|
|
<template>
|
|
|
<div class="single-report">
|
|
|
<HeaderPart
|
|
|
:isParent="isParent"
|
|
|
- exportTable
|
|
|
- :isMyRoute="isMyRoute"
|
|
|
- @send="send"
|
|
|
+ :exportWord="true"
|
|
|
+ :isMyRoute="isMyRoute"
|
|
|
+ :record="singleRecord"
|
|
|
+ @send="send"
|
|
|
@change="changeJoinState"
|
|
|
/>
|
|
|
|
|
@@ -214,7 +76,7 @@ onMounted(async () => {
|
|
|
:poster="singleRecord.story?.videos[0] + '?vframe/jpg/offset/1'"
|
|
|
class="video"
|
|
|
></video>
|
|
|
- <div v-if="isContent" class="content">{{ singleRecord.story?.content }}</div>
|
|
|
+ <div v-if="isContent" class="content" >{{ singleRecord.story?.content }}</div>
|
|
|
</div>
|
|
|
</div>
|
|
|
|
|
@@ -230,20 +92,19 @@ onMounted(async () => {
|
|
|
<div class="title">能力名称:{{ ability.abilityName }}</div>
|
|
|
<template v-if="!isContent" >
|
|
|
<img :src="getImageUrl('desc_name_02')" alt="" class="name" />
|
|
|
- <div class="desc green">{{ ability.descriptionExtra?.behave || ability.description.behave }}</div>
|
|
|
+ <div class="desc green" v-html="ability.descriptionExtra?.behave.replaceAll('\n', '<br/>') || ability.description.behave.replaceAll('\n', '<br/>')"></div>
|
|
|
</template>
|
|
|
|
|
|
<img :src="getImageUrl('desc_name_01')" alt="" class="name" />
|
|
|
- <div class="desc">{{ ability.description.growth }}</div>
|
|
|
+ <div class="desc" v-html="ability.description.growth.replaceAll('\n', '<br/>')"></div>
|
|
|
|
|
|
|
|
|
<img :src="getImageUrl('family_title')" alt="" class="name" />
|
|
|
<div class="strategy">
|
|
|
<div class="strategy-title">一日活动</div>
|
|
|
- <div class="strategy-content">{{ ability.descriptionExtra?.tactics || ability.description.tactics }}</div>
|
|
|
+ <div class="strategy-content" v-html="ability.descriptionExtra?.tactics.replaceAll('\n', '<br/>') || ability.description.tactics.replaceAll('\n', '<br/>')"></div>
|
|
|
<div class="strategy-title">家园共育</div>
|
|
|
- <div class="strategy-content">
|
|
|
- {{ ability.descriptionExtra?.education || ability.description.education }}
|
|
|
+ <div class="strategy-content" v-html="ability.descriptionExtra!.education.replaceAll('\n', '<br/>') || ability.description.education.replaceAll('\n', '<br/>') " >
|
|
|
</div>
|
|
|
</div>
|
|
|
</div>
|
|
@@ -254,6 +115,209 @@ onMounted(async () => {
|
|
|
<ConfirmJoin :show="showConfirm" @close="showConfirm = false" @confirm="confirm" />
|
|
|
</template>
|
|
|
|
|
|
+<script setup lang="ts">
|
|
|
+import { getImageUrl, imagePreview } from "@/utils";
|
|
|
+import { useCustomizeStore } from "@/store";
|
|
|
+import { useRoute } from "vue-router";
|
|
|
+import HeaderPart from "@/views/customize/components/HeaderPart.vue";
|
|
|
+import { ISingleRecord } from "@/types/customize.d";
|
|
|
+import { computed, onMounted, ref } from "vue";
|
|
|
+import ConfirmJoin from "@/views/customize/components/ConfirmJoin.vue";
|
|
|
+
|
|
|
+const { b: babyId, i: id, p: isParent, o: isMyRoute } = useRoute().query;
|
|
|
+
|
|
|
+const customizeStore = useCustomizeStore();
|
|
|
+
|
|
|
+const { getSingleRecord, sendSingleRecord, joinSemesterReport } = customizeStore;
|
|
|
+
|
|
|
+const showConfirm = ref(false);
|
|
|
+
|
|
|
+const singleRecord = computed<ISingleRecord>(() => {
|
|
|
+ return customizeStore.singleRecord;
|
|
|
+ // return {
|
|
|
+ // "recordId": "1782591626363899905",
|
|
|
+ // "babyId": "1382262152722042882",
|
|
|
+ // "sendReport": 0,
|
|
|
+ // "recordDate": "2024-04-23",
|
|
|
+ // "teacherName": "雷lEi\uD83C\uDF88",
|
|
|
+ // "babyNames": [
|
|
|
+ // "王凯昊"
|
|
|
+ // ],
|
|
|
+ // "joinSemester": 1,
|
|
|
+ // "sceneName": "区域活动",
|
|
|
+ // "story": {
|
|
|
+ // "images": [
|
|
|
+ // "https://app-resources-luojigou.luojigou.vip/3649ac71b59e4fb1b8c025928c70e37e"
|
|
|
+ // ],
|
|
|
+ // "videos": ['https://app-resources-luojigou.luojigou.vip/3649ac71b59e4fb1b8c025928c70e37e'],
|
|
|
+ // "content": ""
|
|
|
+ // },
|
|
|
+ // "domainList": [
|
|
|
+ // {
|
|
|
+ // "domainName": "逻辑思维通用领域",
|
|
|
+ // "abilityList": [
|
|
|
+ // {
|
|
|
+ // "abilityName": "批判思维能力",
|
|
|
+ // "description": {
|
|
|
+ // "growth": "S1.在成人的帮助下,幼儿能够模仿其他学生的作品(例:运用自己喜欢的相似的材料)。",
|
|
|
+ // "behave": "看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
+ // "behaviours": [],
|
|
|
+ // "example": "无",
|
|
|
+ // "tactics": "【环创】:\n1.创作机会和条件,支持幼儿自发的艺术表现和创造。\n2.为幼儿提供丰富的便于幼儿取放的材料、工具或物品。\n【师幼】:\n1.和幼儿一起发现并感受周边事物的特征。\n2.倾听幼儿的所见所想,鼓励幼儿大胆表达。",
|
|
|
+ // "education": "1.家长可以和幼儿一起玩串珠的游戏,家长示范,幼儿模仿。\n2.家长可以和幼儿一起进行阅读绘本,一起模仿绘本里动物或者人物的动作、声音和表情等。"
|
|
|
+ // },
|
|
|
+ // "descriptionExtra": {
|
|
|
+ // "growth": "",
|
|
|
+ // "behave": "2024年04月23日,在来来来,王凯昊、朱婷、陈树炎、李佩、雷晴、刘雯雯、孙艺洲、钱小豪、宝宝、田甜小朋友正在来来来活动。\n看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
+ // "behaviours": [],
|
|
|
+ // "example": "",
|
|
|
+ // "tactics": "来来来12345",
|
|
|
+ // "education": ""
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // "abilityName": "很强大的学习能力",
|
|
|
+ // "description": {
|
|
|
+ // "growth": "S1.在成人的帮助下,幼儿能够模仿其他学生的作品(例:运用自己喜欢的相似的材料)。",
|
|
|
+ // "behave": "看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
+ // "behaviours": [],
|
|
|
+ // "example": "无",
|
|
|
+ // "tactics": "【环创】:\n1.创作机会和条件,支持幼儿自发的艺术表现和创造。\n2.为幼儿提供丰富的便于幼儿取放的材料、工具或物品。\n【师幼】:\n1.和幼儿一起发现并感受周边事物的特征。\n2.倾听幼儿的所见所想,鼓励幼儿大胆表达。",
|
|
|
+ // "education": "1.家长可以和幼儿一起玩串珠的游戏,家长示范,幼儿模仿。\n2.家长可以和幼儿一起进行阅读绘本,一起模仿绘本里动物或者人物的动作、声音和表情等。"
|
|
|
+ // },
|
|
|
+ // "descriptionExtra": {
|
|
|
+ // "growth": "",
|
|
|
+ // "behave": "2024年04月23日,在来来来,王凯昊、朱婷、陈树炎、李佩、雷晴、刘雯雯、孙艺洲、钱小豪、宝宝、田甜小朋友正在来来来活动。\n看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
+ // "behaviours": [],
|
|
|
+ // "example": "",
|
|
|
+ // "tactics": "来来来12345",
|
|
|
+ // "education": ""
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ // ]
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // "domainName": "科学探索通用领域",
|
|
|
+ // "abilityList": [
|
|
|
+ // {
|
|
|
+ // "abilityName": "科学探索能力",
|
|
|
+ // "description": {
|
|
|
+ // "growth": "S1.在成人的帮助下,幼儿能够模仿其他学生的作品(例:运用自己喜欢的相似的材料)。",
|
|
|
+ // "behave": "看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
+ // "behaviours": [],
|
|
|
+ // "example": "无",
|
|
|
+ // "tactics": "【环创】:\n1.创作机会和条件,支持幼儿自发的艺术表现和创造。\n2.为幼儿提供丰富的便于幼儿取放的材料、工具或物品。\n【师幼】:\n1.和幼儿一起发现并感受周边事物的特征。\n2.倾听幼儿的所见所想,鼓励幼儿大胆表达。",
|
|
|
+ // "education": "1.家长可以和幼儿一起玩串珠的游戏,家长示范,幼儿模仿。\n2.家长可以和幼儿一起进行阅读绘本,一起模仿绘本里动物或者人物的动作、声音和表情等。"
|
|
|
+ // },
|
|
|
+ // "descriptionExtra": {
|
|
|
+ // "growth": "",
|
|
|
+ // "behave": "2024年04月23日,在来来来,王凯昊、朱婷、陈树炎、李佩、雷晴、刘雯雯、孙艺洲、钱小豪、宝宝、田甜小朋友正在来来来活动。\n看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
+ // "behaviours": [],
|
|
|
+ // "example": "",
|
|
|
+ // "tactics": "来来来12345",
|
|
|
+ // "education": ""
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ // {
|
|
|
+ // "abilityName": "超级无敌的学习能力",
|
|
|
+ // "description": {
|
|
|
+ // "growth": "S1.在成人的帮助下,幼儿能够模仿其他学生的作品(例:运用自己喜欢的相似的材料)。",
|
|
|
+ // "behave": "看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
+ // "behaviours": [],
|
|
|
+ // "example": "无",
|
|
|
+ // "tactics": "【环创】:\n1.创作机会和条件,支持幼儿自发的艺术表现和创造。\n2.为幼儿提供丰富的便于幼儿取放的材料、工具或物品。\n【师幼】:\n1.和幼儿一起发现并感受周边事物的特征。\n2.倾听幼儿的所见所想,鼓励幼儿大胆表达。",
|
|
|
+ // "education": "1.家长可以和幼儿一起玩串珠的游戏,家长示范,幼儿模仿。\n2.家长可以和幼儿一起进行阅读绘本,一起模仿绘本里动物或者人物的动作、声音和表情等。"
|
|
|
+ // },
|
|
|
+ // "descriptionExtra": {
|
|
|
+ // "growth": "",
|
|
|
+ // "behave": "2024年04月23日,在来来来,王凯昊、朱婷、陈树炎、李佩、雷晴、刘雯雯、孙艺洲、钱小豪、宝宝、田甜小朋友正在来来来活动。\n看到其他小朋友在画上贴贴纸,他也会找喜欢的贴纸。",
|
|
|
+ // "behaviours": [],
|
|
|
+ // "example": "",
|
|
|
+ // "tactics": "来来来12345",
|
|
|
+ // "education": ""
|
|
|
+ // }
|
|
|
+ // },
|
|
|
+ // ]
|
|
|
+ // },
|
|
|
+ // ]
|
|
|
+ // }
|
|
|
+});
|
|
|
+
|
|
|
+const isImages = computed(() => {
|
|
|
+ return singleRecord.value.story?.images.length !== 0;
|
|
|
+});
|
|
|
+const isVideo = computed(() => {
|
|
|
+ return singleRecord.value.story?.videos.length !== 0;
|
|
|
+});
|
|
|
+const isContent = computed(() => {
|
|
|
+ return singleRecord.value.story?.content && singleRecord.value.story?.content.length !== 0;
|
|
|
+});
|
|
|
+const isHas = computed(() => {
|
|
|
+ return singleRecord.value.story && (isImages.value || isVideo.value || isContent.value);
|
|
|
+});
|
|
|
+
|
|
|
+async function confirm() {
|
|
|
+ // console.log("confirm");
|
|
|
+ await joinSemesterReport(singleRecord.value.recordId, 0);
|
|
|
+ showConfirm.value = false;
|
|
|
+}
|
|
|
+
|
|
|
+function formatNames(names: string[]) {
|
|
|
+ let str = "";
|
|
|
+ names.map((name, nameIndex) => {
|
|
|
+ if (nameIndex !== 0) {
|
|
|
+ str += "、";
|
|
|
+ }
|
|
|
+ str += name;
|
|
|
+ });
|
|
|
+ return str;
|
|
|
+}
|
|
|
+
|
|
|
+function send() {
|
|
|
+ if (singleRecord.value.sendReport) return;
|
|
|
+ if (typeof babyId === "string" && typeof id === "string")
|
|
|
+ sendSingleRecord({
|
|
|
+ babyId,
|
|
|
+ id,
|
|
|
+ recordType: "1",
|
|
|
+ });
|
|
|
+}
|
|
|
+
|
|
|
+function changeJoinState() {
|
|
|
+ if (singleRecord.value.joinSemester === 1) {
|
|
|
+ showConfirm.value = true;
|
|
|
+ } else {
|
|
|
+ joinSemesterReport(singleRecord.value.recordId, 1);
|
|
|
+ }
|
|
|
+}
|
|
|
+
|
|
|
+function getStyle(index: number, length: number) {
|
|
|
+ return {
|
|
|
+ borderRadius: `${
|
|
|
+ length === 1 ? "17px" : index === 0 ? "17px 17px 0 0" : index === length - 1 ? "0 0 17px 17px" : "0"
|
|
|
+ }`,
|
|
|
+ borderTop: `${index === 0 ? "4px solid #b6dcff" : "none"}`,
|
|
|
+ borderBottom: `${index === length - 1 ? "4px solid #b6dcff" : "none"}`,
|
|
|
+ boxShadow: `${index === 0 ? "0 1px 6px 0 rgba(42, 105, 253, 0.16)" : "none"}`,
|
|
|
+ };
|
|
|
+}
|
|
|
+
|
|
|
+onMounted(async () => {
|
|
|
+ // await getTestTeachToken();
|
|
|
+
|
|
|
+ if (typeof babyId === "string" && typeof id === "string") await getSingleRecord(babyId, id);
|
|
|
+});
|
|
|
+
|
|
|
+/**
|
|
|
+ * 行为记录单次报告
|
|
|
+ *
|
|
|
+ * b: babyId
|
|
|
+ * i: recordId
|
|
|
+ *
|
|
|
+ * http://192.168.1.17:8989/#/customize/SingleReport?b=1304672468777553921&i=1716737882201264130
|
|
|
+ */
|
|
|
+</script>
|
|
|
+
|
|
|
<style scoped lang="scss">
|
|
|
.single-report {
|
|
|
position: fixed;
|