Compare commits

..

11 Commits

Author SHA1 Message Date
winter_born
55f0be6eb8 data is virtual complete 2026-04-15 14:56:21 +08:00
winter_born
f210bcc168 none data,complete all 2026-04-15 12:57:04 +08:00
winter_born
4c8a4ae4f5 除了数据分析都完成 2026-04-15 10:56:46 +08:00
c87a4f63e3 除了数据分析和底边登录其余完成 2026-04-15 00:40:21 +08:00
zsc
4b6a45afb3 index页面的楷模列表 2026-04-14 16:39:58 +08:00
winter_born
cd75d35969 “index_page完成了” 2026-04-14 08:59:12 +08:00
fdda9425a7 完成了api获取 2026-04-13 23:44:51 +08:00
winter_born
c53a6b2640 50%进度,做完第一套b部分 2026-04-13 16:28:59 +08:00
df3ae29701 完成了b部分的第二块,还有一个组件没有完成 2026-04-13 00:20:43 +08:00
winter_born
b1933043a2 123 2026-04-10 13:46:23 +08:00
8fbcafb8be 写了一部分student.vue 2026-04-09 23:33:31 +08:00
27 changed files with 1269 additions and 224 deletions

View File

@@ -1 +0,0 @@
# files_second

118
components/index_page.vue Normal file
View File

@@ -0,0 +1,118 @@
<template>
<view>
<view class="page" v-for="i in processedResult">
<view>
<image :src="`http://124.93.196.45:10091/Neusoft/times-model${i[2]}`"></image>
</view>
<view>
<p>中宣部授予{{i[0]}}时代楷模</p>
<p>模特姓名{{i[0]}}</p>
<p>{{i[1]}}</p>
</view>
</view>
</view>
</template>
<script>
export default {
props: {
end: {
type: Number,
default: 5
}
},
data() {
return {
result: []
}
},
computed: {
processedResult(){
return this.result.slice(0,this.end)
}
},
async mounted() {
this.result = (await this.requests("down", `/appModel/app-o/list`)).rows
this.result = this.result.map(x => [x.modelName, x.content, x.picPath])
console.log(this.result);
},
methods: {
async requests(updown = "down", path) {
let response
if (updown == "up") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({
"password": "0CYdq6Hn",
"username": "6dOMIgIU"
})
})
} else if (updown == "down") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": "eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6ImJjYtrrMxSx0OvYuqZ_0UL738RhVLuq-IxBIyHH1kt0gXAANbdsg"
},
})
}
const data = await response.json()
console.log(data)
return data
}
}
}
</script>
<style>
.page {
border-radius: 15px;
background-color: #fff;
height: 12vh;
display: flex;
align-items: center;
margin: 10px;
}
.page view:first-of-type {
width: 30%;
height: 95%;
margin: 3%;
}
.page view:first-of-type image {
width: 100%;
height: 100%;
}
.page view:nth-child(2) {
width: 65%;
}
.page view:nth-child(2) p:first-of-type {
font-size: 1.2rem;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.page view:nth-child(2) p:nth-child(2) {
font-size: 0.9rem;
}
.page view:nth-child(2) p:nth-child(3) {
width: 100%;
font-size: 0.9rem;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
overflow: hidden;
text-overflow: ellipsis;
}
</style>

126
components/part.vue Normal file
View File

@@ -0,0 +1,126 @@
<template>
<view class="part_content" :class="{ 'overflow-visible': isopen }">
<view class="part" @touchstart="part_start" @touchmove="part_move" @touchend="part_end"
:style="{ transform: 'translateX(' + offsetx + 'px)'}">
<p>{{part_title}}</p>
<p>{{part_content}}</p>
</view>
<view class="detele" :style="{ transform: 'translateX('+ (movemax +rightoffsetx+5) + 'px)' }"
>
删除
</view>
</view>
</template>
<script>
export default {
props: {
part_title: {},
part_content: {},
index: Number
},
data() {
return {
startX: 0,
startOffset: 0,
offsetx: 0,
rightoffsetx: 20,
movemax: 100,
isopen: false
}
},
methods: {
part_start(e) {
this.startX = e.touches[0].clientX;
this.startOffset = this.offsetx;
},
part_move(e) {
this.isopen = true;
let moveX = e.touches[0].clientX - this.startX;
let newOffset = this.startOffset + moveX;
if (newOffset > 0) {
newOffset = 0;
} else if (newOffset < -this.movemax) {
newOffset = -this.movemax;
}
this.rightoffsetx = newOffset;
this.offsetx = newOffset;
},
part_end(e) {
if (this.offsetx < -this.movemax / 2) {
this.offsetx = -this.movemax;
this.isopen = true;
} else {
this.offsetx = 0;
this.rightoffsetx = 20;
this.isopen = false;
}
}
}
}
</script>
<style>
* {
margin: 0;
padding: 0;
}
.part_content {
height: 10vh;
background-color: white;
border-radius: 15px;
padding: 3%;
margin: 2%;
background-color: #fff;
overflow: hidden;
position: relative;
z-index: 2;
}
.part_content.overflow-visible {
overflow: visible !important;
}
.part {
width: 100%;
margin: 10px;
}
.part p:first-child {
font-size: 1.2rem;
margin-bottom: 10px;
white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.part p:nth-child(2) {
font-size: 0.8rem;
overflow: hidden;
text-overflow: ellipsis;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
overflow: hidden;
text-overflow: ellipsis;
}
.detele {
text-align: center;
background-color:#C2050F;
position: absolute;
top: 0;
right: 0px;
bottom: 0;
width: 100px;
z-index: 1;
transform: translateX(100px);
display: flex;
align-items: center;
justify-content: center;
color: #fff;
}
</style>

View File

@@ -0,0 +1,180 @@
<template>
<view class="page_div">
<view>
<p>中宣部授予肖文儒时代楷模称号</p>
<p>2022-04-15 08:00</p>
<p>为了贯彻落实习近平总书记在中央人才工作会议上的重要讲话精神大力倡导尊重知识尊重人才理念中央宣传部以云计算工程的算工程的算工程的算工程的</p>
</view>
<view v-show="write_none">
<view>
<p>学习笔记</p>
<p @click="if_none">删除</p>
</view>
<view>
<textarea v-model="useInput" />
</view>
</view>
<view @click="insertShow()">
<image :src="path[0]"></image>
<p :style="{color:path[1]}">添加笔记</p>
</view>
</view>
</template>
<script>
export default {
data() {
return {
useInput: "",
block_none: true,
write_none: false,
imagepath: [
["/static/experience_2.png", "orange"],
["/static/experience_1.png", "red"]
],
postif: true
}
},
methods: {
insertShow() {
this.write_none = true;
this.postif = !this.postif
if (this.postif) {
uni.showModal({
content: '是否保存',
success: res => {
if (res.confirm) {
console.log(this.useInput)
}
}
});
}
},
if_none() {
uni.showModal({
content: '是否删除',
success: res => {
if (res.confirm) {
this.write_none = false;
this.useInput = ""
} else if (res.cancel) {
this.write_none = true;
}
}
})
},
async requests(updown, path) {
let response
if (updown == "up") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({
"password": "0CYdq6Hn",
"username": "6dOMIgIU"
})
})
} else if (updown == "down") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": (await this.requests("up", "/app/login")).token
},
})
}
const data = await response.json()
console.log(data)
return data
}
},
async onLoad(){
await this.requests("down","")
},
computed: {
path() {
if (this.write_none) {
return this.imagepath[0]
} else {
return this.imagepath[1]
}
}
},
}
</script>
<style>
.page_div {
background-color: #fff;
border-radius: 15px;
padding: 3%;
margin: 2%;
}
.page_div>view:first-child {
border-bottom: 1px solid darkgray;
padding-bottom: 10px;
}
.page_div>view:first-child p:first-child {
font-size: 1.1rem;
}
.page_div>view:first-child p:nth-child(2) {
font-size: 0.8rem;
}
.page_div>view:first-child p:nth-child(3) {
font-size: 0.9rem;
display: -webkit-box;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
overflow: hidden;
text-overflow: ellipsis;
}
.page_div>view:nth-child(2) {
display: flex;
flex-direction: column;
padding-bottom: 5px;
border-bottom: 1px solid darkgray;
}
.page_div>view:nth-child(2)>view:first-child {
display: flex;
justify-content: space-between;
}
.page_div>view:nth-child(2)>view:first-child p:nth-child(2) {
color: #C2050F;
}
.page_div>view:nth-child(2)>view:nth-child(2) {
background-color: darkgray;
border-radius: 10px;
padding: 5px;
}
.page_div>view:last-child {
margin-top: 10px;
height: 5vh;
color: rgb(255, 56, 59);
display: flex;
justify-content: center;
align-items: center;
}
.page_div>view:last-child image {
width: 4vw;
height: 2vh
}
</style>

18
js_sdk/u-charts/echarts.min.js vendored Normal file

File diff suppressed because one or more lines are too long

View File

@@ -1,6 +1,6 @@
import Vue from 'vue'
import App from './App'
import Card from "componets/card.vue"
Vue.config.productionTip = false

View File

@@ -6,17 +6,51 @@
"navigationBarTitleText": "uni-app"
}
}
,{
"path" : "pages/index/student",
,
{
"path": "pages/index/student",
"style": {
"navigationBarTitleText": ""
}
}
,{
"path" : "components/part",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
}
},
{
"path": "components/student_write",
"style": {
"navigationBarTitleText": ""
}
}
,{
"path" : "pages/index/text/text",
"path" : "pages/index/voluteer",
"style" :
{
"navigationBarTitleText": "",
"enablePullDownRefresh": false
}
},
{
"path": "components/index_page",
"style": {
"navigationBarTitleText": ""
}
},
{
"path": "pages/index/voluteer_son",
"style": {
"navigationBarTitleText": ""
}
}
,{
"path" : "pages/index/dataprocess",
"style" :
{
"navigationBarTitleText": "",

View File

@@ -1,63 +0,0 @@
@font-face {
font-family: MuiiconSpread;
font-weight: normal;
font-style: normal;
src: url('../fonts/mui-icons-extra.ttf') format('truetype'); /* iOS 4.1- */
}
.mui-icon-extra
{
font-family: MuiiconSpread;
font-size: 24px;
font-weight: normal;
font-style: normal;
line-height: 1;
display: inline-block;
text-decoration: none;
-webkit-font-smoothing: antialiased;
}
.mui-icon-extra-cold:before { content: "\e500"; }
.mui-icon-extra-share:before { content: "\e200"; }
.mui-icon-extra-class:before { content: "\e118"; }
.mui-icon-extra-custom:before { content: "\e117"; }
.mui-icon-extra-new:before { content: "\e103"; }
.mui-icon-extra-card:before { content: "\e104"; }
.mui-icon-extra-grech:before { content: "\e105"; }
.mui-icon-extra-trend:before { content: "\e106"; }
.mui-icon-extra-filter:before { content: "\e207"; }
.mui-icon-extra-holiday:before { content: "\e300"; }
.mui-icon-extra-cart:before { content: "\e107"; }
.mui-icon-extra-heart:before { content: "\e180"; }
.mui-icon-extra-computer:before { content: "\e600"; }
.mui-icon-extra-express:before { content: "\e108"; }
.mui-icon-extra-gift:before { content: "\e109"; }
.mui-icon-extra-gold:before { content: "\e102"; }
.mui-icon-extra-lamp:before { content: "\e601"; }
.mui-icon-extra-rank:before { content: "\e110"; }
.mui-icon-extra-notice:before { content: "\e111"; }
.mui-icon-extra-sweep:before { content: "\e202"; }
.mui-icon-extra-arrowleftcricle:before { content: "\e401"; }
.mui-icon-extra-dictionary:before { content: "\e602"; }
.mui-icon-extra-heart-filled:before { content: "\e119"; }
.mui-icon-extra-xiaoshuo:before { content: "\e607"; }
.mui-icon-extra-top:before { content: "\e403"; }
.mui-icon-extra-people:before { content: "\e203"; }
.mui-icon-extra-topic:before { content: "\e603"; }
.mui-icon-extra-hotel:before { content: "\e301"; }
.mui-icon-extra-like:before { content: "\e206"; }
.mui-icon-extra-regist:before { content: "\e201"; }
.mui-icon-extra-order:before { content: "\e113"; }
.mui-icon-extra-alipay:before { content: "\e114"; }
.mui-icon-extra-find:before { content: "\e400"; }
.mui-icon-extra-arrowrightcricle:before { content: "\e402"; }
.mui-icon-extra-calendar:before { content: "\e115"; }
.mui-icon-extra-prech:before { content: "\e116"; }
.mui-icon-extra-cate:before { content: "\e501"; }
.mui-icon-extra-comment:before { content: "\e209"; }
.mui-icon-extra-at:before { content: "\e208"; }
.mui-icon-extra-addpeople:before { content: "\e204"; }
.mui-icon-extra-peoples:before { content: "\e205"; }
.mui-icon-extra-calc:before { content: "\e101"; }
.mui-icon-extra-classroom:before { content: "\e604"; }
.mui-icon-extra-phone:before { content: "\e404"; }
.mui-icon-extra-university:before { content: "\e605"; }
.mui-icon-extra-outline:before { content: "\e606"; }

View File

@@ -0,0 +1,83 @@
<template>
<view>
<view id="chart" style="width: 100%; height: 400px;"></view>
<view id="pie" style="width: 100%; height: 400px;"></view>
<view id="category" style="width: 100%; height: 400px;"></view>
</view>
</template>
<script>
import * as echarts from "../../js_sdk/u-charts/echarts.min.js"
export default {
data() {
return {
chart: null,
category: null,
pie: null
}
},
mounted() {
this.$nextTick(() => {
this.chart = echarts.init(document.getElementById('chart'))
this.chart.setOption({
color: ['#614321', '#456124'],
xAxis: {
data: ['Mon', 'Tue', 'Wed', 'Thu', 'Fri', 'Sat', 'Sun']
},
yAxis: {},
series: [{
type: 'bar',
data: [23, 24, 18, 25, 27, 100, 25]
}, {
type: 'bar',
data: [23, 24, 18, 25, 27, 42, 25]
}]
})
})
this.$nextTick(() => {
this.pie = echarts.init(document.getElementById("pie"))
this.pie.setOption({
series: [{
type: "pie",
data: [{
value: 10,
name: "10%"
}, {
value: 20,
name: "20%"
}, {
value: 25,
name: "25%"
}, {
value: 10,
name: "10%"
}, {
value: 15,
name: "15%"
}, {
value: 20,
name: "20%"
}]
}]
})
})
this.$nextTick(() => {
this.category = echarts.init(document.getElementById("category"))
this.category.setOption({
xAxis: {
data: [30, 20, 31, 41, 73, 42, 25]
},
yAxis: {},
series: [{
type: "line",
data: [23, 24, 18, 25, 27, 42, 25]
}, {
type: "line",
data: [32, 24, 42, 25, 72, 42, 25]
}]
})
})
}
}
</script>

View File

@@ -2,11 +2,17 @@
<view class="begin">
<view class="headers">
<text class="text1">时代楷模</text>
<view class="div">
学习雷锋同志弘扬雷锋精神
<view class="div" v-if="banner_title">
{{banner_title.data.topicContent}}
</view>
<view class="headers_middle">
<swiper :indicator-dots="false" :autoplay="true" :interval="3000" :duration="1000">
<swiper-item v-for="path in banner_content">
<view class="swiper-item">
<image :src="`http://124.93.196.45:10091/Neusoft/times-model${path}`"></image>
</view>
</swiper-item>
</swiper>
</view>
<view class="headers_bottom">
@@ -16,111 +22,130 @@
</view>
<view class="bottom_right">
<p>2021年河北省最美基层高校毕业生先进事迹发布</p>
<p>河北省委宣传部省人社局在最美河北.....</p>
<p>河北省委宣传部省人社局在最美河北最美河北最美河北最美河北最美河北最美河北最美河北最美河北</p>
</view>
>
</view>
</view>
<view>
<!-- <view class="row_1">
<view class="uni-section">
<view></view>
<p @click="toggleColor()" :style="{color:textColor}">楷模列表</p>
</view>
<view class="section">
<view></view>
<p>英雄故事</p>
</view>
<view class="section">
<view></view>
<p>英雄故事</p>
</view>
</view>
<view class="row_2">
<view class="section">
<view></view>
<p>英雄故事</p>
</view>
<view class="section">
<view></view>
<p>英雄故事</p>
</view> -->
<card class="card" v-for="imagepath of imagepaths" :image_path="imagepath.path" :value="imagepath.value">
</card>
<!-- </view> -->
</view>
<view>
<text class="title">楷模列表</text>
<view class="page">
<view></view>
<view>
<p>中宣部授予肖文儒时代楷模...</p>
<p>模特姓名肖文儒</p>
<p>38年来国家安全生产应急救援中心副主任兼工程师肖文儒参与过多次重...</p>
</view>
<indexpage ref="as" :end="part_nums"></indexpage>
<button @click="showmore()">显示更多</button>
</view>
<view class="index_end">
<view class="nav_bottom" v-for="(path_image,index) in endbottom" @click="gowhere(index)">
<image :src="path_image[0]"></image>
<p>{{path_image[1]}}</p>
</view>
</view>
</view>
</template>
<script>
import card from "../../componets/card.vue"
import card from "../../components/card.vue"
import indexpage from "../../components/index_page.vue"
export default {
components: {
card
card,
indexpage
},
data() {
const imagepath = Array.from({
length: 4
}).map((_, x) => `../../static/a${x+1}.png`)
const textarray = ["首页", "公益", "心得", "我的"]
const endbottom = imagepath.map((value, index) => [value, textarray[index]])
return {
isRed: false,
list: [{
id: 1,
name: ""
}]
endbottom,
banner_title: null,
part_nums: 5,
banner_content: null
}
},
computed: {
textColor() {
return this.isRed ? 'red' : 'black'
},
imagepaths() {
const base_url = "http://124.93.196.45:10091/Neusoft/times-model/appStudy/app/historyList"
let Path = Array.from({
length: 6
}, (_, x) => `../../static/c${x+1}.png`);
// let value = Array.from({
// length: 6
// }, (_, x) => `英雄故事`);
let value = ["楷模列表", "英雄故事", "身边英雄", "物资捐赠", "数据分析", "更多"]
async function text() {
const text = await fetch(base_url, {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": "eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6ImIyOGYwYjkzLTU0ZTktNDM3MC05NTczLWUzMWE5MDA2OGM5MyJ9.Gqqt22q3ZxXWZ04gHq5F0tTKPypHRqjGOhCe1NcUjvSplv6GschoZW_3xc_MOI-T38u_81kTXX7LAt7PXemM3w"
}
})
return await text.json()
}
text().then(data => console.log(data));
return Path.map((path, index) => ({
path: path,
value: value[index]
}))
}
},
methods: {
toggleColor() {
this.isRed = !this.isRed
showmore() {
this.part_nums = Math.min(this.part_nums + 5, 42)
},
async requests(updown, path) {
let response
if (updown == "up") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({
"password": "0CYdq6Hn",
"username": "6dOMIgIU"
})
})
} else if (updown == "down") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": (await this.requests("up", "/app/login")).token
},
})
}
const data = await response.json()
console.log(data)
return data
},
gowhere(index) {
switch (index) {
case 1:
uni.navigateTo({
url: '/pages/index/voluteer'
});
break;
case 2:
uni.navigateTo({
url: '/pages/index/student'
});
break;
}
}
}
},
async mounted() {
this.banner_title = await this.requests("down", "/appNotice/app-o/modelSpirit")
let datavalue = []
for (let i = 1; i < 4; i++) {
datavalue.push(this.requests("down", `/appNotice/app-o/loopMapDetail?id=${i}`))
}
datavalue = (await Promise.all(datavalue)).map(x => x.data.picPath)
this.banner_content = datavalue
console.log(datavalue)
},
}
</script>
<style>
.begin {
background-color: rgb(246, 246, 246);
* {
padding: 0;
margin: 0;
}
.begin {
background-color: rgb(221,221,221);
}
.text1 {
@@ -131,7 +156,6 @@
font-weight: bold;
padding-bottom: 3%;
background-color: #fff !important;
/* margin-right: -1px; */
}
.headers .div {
@@ -143,11 +167,20 @@
}
.headers_middle {
height: 20vh;
height: 25vh;
border: 1px red solid;
background-color: #fff !important;
}
.headers_middle swiper {
height: 100%;
}
.headers_middle swiper .swiper-item image {
width: 100%;
height: 25vh;
}
.headers_bottom {
height: 10vh;
display: flex;
@@ -173,6 +206,7 @@
}
.bottom_right {
width: 80%;
height: 10vh;
border-radius: 0px 15px 15px 0px;
}
@@ -188,6 +222,9 @@
.bottom_right p:nth-child(2) {
font-size: 0.9rem;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.headers+view {
@@ -199,12 +236,14 @@
justify-items: center;
}
.card {width: 55%;text-align: center;}
.card {
width: 55%;
text-align: center;
}
.headers+view+view {
background-color: rgb(246, 246, 246);
margin: 10px 15px;
padding-bottom: 10px;
padding-bottom: 65px;
}
.title {
@@ -215,31 +254,29 @@
margin-bottom: 10px;
}
.page {
border-radius: 15px;
background-color: #fff;
height: 12vh;
.index_end {
display: flex;
border-radius: 15px;
justify-content: space-around;
position: fixed;
bottom: 0;
left: 0;
width: 100vw;
background-color: #fff;
height:65px;
}
.nav_bottom {
display: flex;
flex-direction: column;
align-items: center;
}
.page view:first-of-type {
width: 25%;
height: 75%;
margin: 3%;
background-color: red;
.nav_bottom image {
width: 40px;
height: 40px;
}
.page view:nth-child(2) p:first-of-type {
font-size: 1.2rem;
}
.page view:nth-child(2) p:nth-child(2) {
font-size: 0.9rem;
}
.page view:nth-child(2) p:nth-child(3) {
font-size: 0.9rem;
.nav_bottom:nth-child(1) p {
color: #C2050F;
}
</style>

View File

@@ -1,45 +1,177 @@
<template>
<view>
<view>学习笔记</view>
<view>
<view>学习感言</view>
<view>学习历史</view>
<view class="begin">
<view class="title">
学习心得
</view>
<uni-segmented-control :current="current" :values="value" style-type="text" @clickItem="onCheck"
activeColor="red"></uni-segmented-control>
<view class="content">
<view v-show="current === 0">
<part v-for="index in 3" class="student_part" :part_title="part_title" :part_content="part_content">
</part>
<view class="student_button">
新建感言
</view>
</view>
<view v-show="current === 1">
<studentwrite></studentwrite>
<studentwrite></studentwrite>
</view>
</view>
<view class="student_end">
<view class="nav_bottom" v-for="(path_image,index) in endbottom" @click="gowhere(index)">
<image :src="path_image[0]"></image>
<p>{{path_image[1]}}</p>
</view>
</view>
</view>
</template>
<script>
import part from "../../components/part.vue"
import studentwrite from "../../components/student_write.vue"
export default {
components: {
part,
studentwrite
},
data() {
async function get() {
const form = new FormData();
form.append("content", "neirong")
form.append("picPath","img")
form.append("title","biaoti")
const text = await fetch("http://124.93.196.45:10091/Neusoft/times-model/appStudy/app/createStatement", {
method: "POST",
headers: {
"Authorization": "eyJhbGciOiJIUzUxMiJ9.eyJsb2dpbl91c2VyX2tleSI6ImU2YTJjMGY1LWEwMWUtNDMzNi04ZTMzLTdlNWNhODM1MjRhZCJ9.B8-7Lc5z589K7pAa-W-ZG9aFgFEHI4HC_xT3tKoZpyzijBksZ1dQNCaMtvjOzDMDkZYbFHk-5oyQ0CFZGsuK8w"
},
body: form
})
console.log(await text.json())
}
get()
const imagepath = Array.from({
length: 4
}).map((_, x) => `../../static/a${x+1}.png`)
const textarray = ["首页", "公益", "心得", "我的"]
const endbottom = imagepath.map((value, index) => [value, textarray[index]])
console.log(endbottom)
return {
current: 0,
value: ["学习感言", "学习历史"],
part_title: "山西省委常委交流集中学习心得和体会,坚交流集中学习心得和体会,坚交流集中学习心得和体会,坚交流集中学习心得和体会,坚交流集中学习心得和体会,坚",
part_content: "8月18日山西省委常委就集体学习《论群众路线》《厉行节约、反对浪费》两本重要论述摘编相互交流学习心相互交流学习心相互交流学习心相互交流学习心相互交流学习心相互交流学习心相互交流学习心相互交流学习心相互交流学习心相互交流学习心",
endbottom,
useInput: "",
write_none: false
}
},
methods: {
onCheck(e) {
if (this.current != e.currentIndex) {
this.current = e.currentIndex
}
},
insertShow() {
this.write_none = true;
},
if_none() {
this.write_none = false;
this.useInput = ""
},
async requests(updown, path) {
let response
if (updown == "up") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({
"password": "0CYdq6Hn",
"username": "6dOMIgIU"
})
})
} else if (updown == "down") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": (await this.requests("up", "/app/login")).token
},
})
}
const data = await response.json()
console.log(data)
return data
},
gowhere(index) {
switch (index) {
case 0:
uni.navigateTo({
url: '/pages/index/index'
});
break;
case 1:
uni.navigateTo({
url: '/pages/index/voluteer'
});
break;
}
}
},
async mounted() {
await this.requests("down", "/appStudy/app/deleteStatement")
}
}
</script>
<style>
.begin {
background-color: rgb(244, 244, 244);
height: 95vh;
display: flex;
flex-direction: column;
}
.title {
font-size: 1.3rem;
font-weight: bold;
text-align: center;
}
.content {
margin-top: 20px;
flex: 1;
}
.student_button {
position: absolute;
left: 25%;
bottom: 20%;
text-align: center;
border-radius: 50px;
background-color: #C2050F;
color: white;
width: 200px;
height: 50px;
line-height: 50px;
font-size: 1.1rem;
}
.student_end {
display: flex;
justify-content: space-around;
background-color: white;
position: fixed;
bottom: 0;
left: 0;
width: 100vw;
height:65px;
}
.nav_bottom {
display: flex;
flex-direction: column;
align-items: center;
}
.nav_bottom image {
width: 40px;
height: 40px;
}
.nav_bottom:nth-child(3) p {
color: #C2050F;
}
</style>

View File

@@ -1,39 +0,0 @@
<template>
<view>
<view class="headers_top">
学习心得
</view>
<uni-segmented-control :current="current" :values="value" @clickItem="oncheck()" activeColor="red" styleType="text"></uni-segmented-control>
<view class="content">
<view v-show="current === 0">
</view>
<view v-show="current === 1">
选项卡2的内容
</view>
</view>
</view>
</template>
<script>
export default {
data() {
return {
current:0,
value:["学习感言","学习历史"]
}
},
methods: {
oncheck(e){
if(this.current != e.currentIndex){
this.current = e.currentIndex
}
}
}
}
</script>
<style>
.headers_top{font-size:1.3rem;font-weight: bold;text-align: center;}
</style>

235
pages/index/voluteer.vue Normal file
View File

@@ -0,0 +1,235 @@
<template>
<view class="begin">
<view class="title">
公益活动
</view>
<uni-segmented-control styleType="text" activeColor="red" :current="current" :values="value"
@clickItem="togglecurrent"></uni-segmented-control>
<view class="content">
<view v-show="current === 0">
<view class="voluteer_card" v-for="ever in morevalue">
<image :src="`http://124.93.196.45:10091/Neusoft/times-model${ever[0]}`"></image>
<view class="voluteer_card_bottom">
<p>{{ever[1]}}</p>
<p>活动时间
{{ever[2]}}~ {{ever[3]}}
</p>
<p>发起方{{ever[4]}}</p>
<p>简介{{ever[5]}}</p>
</view>
<view>
<view>
<image src="../../static/baoming_icon.png"></image>
<text>已报名{{ever[6]}}</text>
</view>
<view @click="goto(ever[7])">去报名</view>
</view>
</view>
<view class="voluteer_bottom">
<view class="nav_bottom" v-for="(path_image,index) in endbottom" @click="gowhere(index)">
<image :src="path_image[0]"></image>
<p>{{path_image[1]}}</p>
</view>
</view>
</view>
<view v-show="current === 1">
</view>
</view>
</view>
</template>
<script>
export default {
data() {
const imagepath = Array.from({
length: 4
}).map((_, x) => `../../static/a${x+1}.png`)
const textarray = ["首页", "公益", "心得", "我的"]
const endbottom = imagepath.map((value, index) => [value, textarray[index]])
return {
current: 0,
value: ["全部活动", "已报名"],
morevalue: null,
endbottom
}
},
methods: {
togglecurrent(e) {
if (this.current != e.currentIndex) {
this.current = e.currentIndex
}
},
async requests(updown, path) {
let response
if (updown == "up") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({
"password": "0CYdq6Hn",
"username": "6dOMIgIU"
})
})
} else if (updown == "down") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": (await this.requests("up", "/app/login")).token
},
})
}
const data = await response.json()
console.log(data)
return data
},
goto(id) {
uni.navigateTo({
url: `/pages/index/voluteer_son?id=${id}`
})
},
gowhere(index) {
switch (index) {
case 0:
uni.navigateTo({
url: '/pages/index/index'
});
break;
case 2:
uni.navigateTo({
url: '/pages/index/student'
});
break;
}
}
},
async mounted() {
// await this.requests("down","/activity/app-o/detail?id=1")
this.morevalue = (await this.requests("down", "/activity/app-o/list")).rows.map(x => [x.picPath, x.title, x
.startDate, x.endDate, x.sponsor, x.content, x.signUpNum, x.id
])
console.log(this.morevalue);
}
}
</script>
<style>
* {
padding: 0;
margin: 0;
}
.begin {
background-color: rgb(221, 221, 221);
height: 100vh;
display: flex;
flex-direction: column;
}
.title {
font-size: 1.3rem;
font-weight: bold;
text-align: center;
}
.content {
height: 110vh;
overflow: scroll;
}
.voluteer_card {
height: 42vh;
background-color: #fff;
margin: 2%;
border-radius: 10px;
display: flex;
flex-direction: column;
justify-content: space-evenly;
}
.voluteer_card image {
width: 100%;
height: 24vh;
border-radius: 10px;
}
.voluteer_card_bottom {
padding: 0% 4% 2% 4%;
}
.voluteer_card_bottom p:nth-child(1) {
font-size: 1.1rem;
}
.voluteer_card_bottom p:not(:nth-child(1)) {
font-size: 0.8rem;
padding: 1% 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.voluteer_card_bottom p:last-child {
padding-bottom: 2%;
border-bottom: 1px solid rgb(220, 220, 220);
}
.voluteer_card_bottom+view {
display: flex;
justify-content: space-between;
align-items: center;
padding: 0% 4% 2% 4%;
}
.voluteer_card_bottom+view>view:first-child {
display: flex;
justify-content: space-evenly;
align-items: center;
}
.voluteer_card_bottom+view>view:first-child image {
width: 20px;
height: 20px;
}
.voluteer_card_bottom+view>view:nth-child(2) {
text-align: center;
line-height: 30px;
width: 100px;
height: 30px;
background-color: red;
color: white;
border-radius: 15px;
}
.voluteer_bottom {
display: flex;
justify-content: space-around;
background-color: white;
position: fixed;
bottom: 0;
left: 0;
width: 100vw;
height: 65px;
}
.nav_bottom {
display: flex;
flex-direction: column;
align-items: center;
}
.nav_bottom image {
width: 40px;
height: 40px;
}
.nav_bottom:nth-child(2) p {
color: #C2050F;
}
</style>

View File

@@ -0,0 +1,185 @@
<template>
<view class="begin">
<view class="title">
活动详情
</view>
<view class="content">
<view class="voluteer_card" v-if="ever">
<image :src="`http://124.93.196.45:10091/Neusoft/times-model${ever.picPath}`"></image>
<view class="voluteer_card_bottom">
<p>{{ever.title}}</p>
<p>活动时间
{{ever.startDate}}~{{ever.endDate}}
</p>
<p>发起方{{ever.sponsor}}</p>
</view>
</view>
<view class="voluteer_card_all">
<p>活动详情</p>
<p>{{ever.content}}</p>
</view>
<view class="voluteer_bottom">
<view><text>{{ever.signUpNum}}</text>人已报名</view>
<view @click="succ">报名</view>
</view>
</view>
</view>
</template>
<script>
export default {
props: {},
data() {
return {
id: null,
morevalue: null,
ever: null
}
},
async mounted() {
this.ever = (await this.requests("down", `/activity/app-o/detail?id=${this.id}`)).data
console.log(this.ever);
},
onLoad(option) {
this.id = option.id
},
methods: {
async requests(updown, path) {
let response
if (updown == "up") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "POST",
headers: {
"Content-Type": "application/json",
},
body: JSON.stringify({
"password": "0CYdq6Hn",
"username": "6dOMIgIU"
})
})
} else if (updown == "down") {
response = await fetch(`http://124.93.196.45:10091/Neusoft/times-model${path}`, {
method: "GET",
headers: {
"Content-Type": "application/json",
"Authorization": (await this.requests("up", "/app/login")).token
},
})
}
const data = await response.json()
console.log(data)
return data
},
succ(){
uni.showToast({
title: '报名成功!',
icon: 'success'
})
}
}
}
</script>
<style>
.begin {
background-color: rgb(221, 221, 221);
}
.title {
font-size: 1.3rem;
font-weight: bold;
text-align: center;
background-color: #fff;
}
.voluteer_card {
height: 34.5vh;
background-color: #fff;
margin: 2%;
border-radius: 10px;
}
.voluteer_card image {
width: 100%;
height: 25vh;
border-radius: 10px;
}
.voluteer_card_bottom {
padding: 0% 4%;
}
.voluteer_card_bottom p:nth-child(1) {
font-size: 1.2rem;
font-weight: bold;
}
.voluteer_card_bottom p:not(:nth-child(1)) {
font-size: 0.8rem;
padding: 1% 0;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
}
.voluteer_card_bottom p:last-child {
padding-bottom: 2%;
}
.voluteer_card_bottom+view {
display: flex;
justify-content: space-between;
align-items: center;
padding: 0% 4% 2% 4%;
}
.voluteer_card_all {
height: 60vh;
background-color: #fff;
margin: 2%;
border-radius: 10px;
padding: 3%;
}
.voluteer_card_all p:first-child {
font-size: 1.2rem;
font-weight: bold;
border-left: 5px solid #C2050F;
padding-left: 3%;
}
.voluteer_card_all p:nth-child(2) {
padding: 5%;
}
.voluteer_bottom {
display: flex;
justify-content: space-around;
height: 5vh;
line-height: 5vh;
background-color: white;
position: fixed;
bottom: 0;
left: 0;
width: 100vw;
text-align: center;
}
.voluteer_bottom view:nth-child(1) {
width: 50%;
background-color: #f9f9f9;
}
.voluteer_bottom view:nth-child(1) text {
color: #C2050F;
font-weight:bold ;
}
.voluteer_bottom view:nth-child(2) {
width: 50%;
background-color:#C2050F;
}
</style>

BIN
static/a1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 22 KiB

BIN
static/a2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB

BIN
static/a3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

BIN
static/a4.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

BIN
static/baoming_icon.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 486 B

BIN
static/experience_1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 698 B

BIN
static/experience_2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 723 B

BIN
static/hero.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 156 KiB

BIN
static/homebg.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 125 KiB

BIN
static/img_my_hero_add.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 KiB

BIN
static/listbg.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 18 KiB

BIN
static/listbg2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 20 KiB