Просмотр исходного кода

除了首页家长端点击孩子头像之外,全部修改完成

FANGLH 7 лет назад
Родитель
Сommit
a7591b36ea

+ 3 - 3
frontend/wechat-web/src/modules/announce/AnnounceRelease.jsx

@@ -52,7 +52,7 @@ class AnnounceRelease extends Component {
         const targetProps = {
             targetData: targetData,
             targetValues: targetList,
-            title: '发布对象',
+            title: '通知对象',
             targetCount: targetCount,
             onTargetChange: this.onTargetChange.bind(this),
             onTargetFocus: this.onTargetFocus.bind(this)
@@ -61,7 +61,7 @@ class AnnounceRelease extends Component {
         const defaultTargetProps = {
             targetData: [],
             targetValues: targetList,
-            title: '发布对象',
+            title: '通知对象',
             targetCount: targetCount,
             onTargetChange: this.onTargetChange.bind(this),
             onTargetFocus: this.onTargetFocus.bind(this)
@@ -184,7 +184,7 @@ class AnnounceRelease extends Component {
             return
         }
         if (isObjEmpty(this.checkNodes)) {
-            Toast.fail('请选择发布对象')
+            Toast.fail('请选择通知对象')
             return
         }
 

+ 2 - 2
frontend/wechat-web/src/modules/hiPages/send-vote/SendVote.js

@@ -141,7 +141,7 @@ class SendVote extends Component {
         const targetProps = {
             targetData: this.state.targetData,
             targetValues: this.state.targetList,
-            title: '发布对象',
+            title: '投票对象',
             targetCount: this.state.targetCount,
             onTargetChange: this.onTargetChange.bind(this),
             onTargetFocus: this.onTargetFocus.bind(this)
@@ -150,7 +150,7 @@ class SendVote extends Component {
         const defaultTargetProps = {
             targetData: [],
             targetValues: this.state.targetList,
-            title: '发布对象',
+            title: '投票对象',
             targetCount: this.state.targetCount,
             onTargetChange: this.onTargetChange.bind(this),
             onTargetFocus: this.onTargetFocus.bind(this)

+ 2 - 2
frontend/wechat-web/src/modules/hiPages/sendMeetting/SendMeet.js

@@ -154,7 +154,7 @@ class SendMeet extends Component {
                             dismissText: '取消'
                         }}
                         onChange={date => this.setState({startValue: date})}>
-                        <List.Item arrow="horizontal">会议开始时间</List.Item>
+                        <List.Item arrow="horizontal">开始时间</List.Item>
                     </DatePicker>
                     <div className="comhline_sty1"></div>
                     <DatePicker
@@ -164,7 +164,7 @@ class SendMeet extends Component {
                             dismissText: '取消'
                         }}
                         onChange={date => this.setState({endValue: date})}>
-                        <List.Item arrow="horizontal">会议结束时间</List.Item>
+                        <List.Item arrow="horizontal">结束时间</List.Item>
                     </DatePicker>
                     <div className="comhline_sty1"></div>
                     <Picker

+ 8 - 4
frontend/wechat-web/src/modules/home/HomePage.jsx

@@ -23,7 +23,6 @@ import icon_home_change from "../../style/imgs/icon_home_change.png";
 
 const operation = Modal.operation;
 
-
 class HomePage extends Component {
 
     constructor() {
@@ -31,6 +30,7 @@ class HomePage extends Component {
 
         this.state = {
             studentIndex: 0,
+            selectStuName:'',//被切换之后的选中的孩子
         }
     }
 
@@ -251,7 +251,9 @@ class HomePage extends Component {
                         }
                     })
 
-                    this.setState({studentIndex})
+                    this.setState({studentIndex:studentIndex,
+                        selectStuName:this.props.userInfo.parent.students[studentIndex].stuName
+                    })
                 }
 
                 this.mySwiper.init()
@@ -299,7 +301,8 @@ class HomePage extends Component {
         if (userInfo.userRole === 1) {
             if (userInfo.parent) {
                 schoolName = userInfo.parent.schoolName
-                userName = userInfo.parent.parentsName
+                // userName = userInfo.parent.parentsName
+                userName = this.state.selectStuName
             }
         } else if (userInfo.userRole === 2) {
             if (userInfo.teacher) {
@@ -443,7 +446,8 @@ class HomePage extends Component {
             setTimeout(() => {
                 Toast.success('切换成功!', 1)
                 this.setState({
-                    studentIndex: stuIndex
+                    studentIndex: stuIndex,
+                    selectStuName:this.props.userInfo.parent.students[stuIndex].stuName
                 })
                 switchUser({
                     parent: {

+ 2 - 2
frontend/wechat-web/src/modules/leave/LeaveAddCPage.js

@@ -96,7 +96,7 @@ class LeaveAddCPage extends Component {
                         dismissText: '取消'
                     }}
                     onChange={date => this.setState({startValue: date})}>
-                    <List.Item arrow="horizontal">请假开始时间</List.Item>
+                    <List.Item arrow="horizontal"></List.Item>
                 </DatePicker>
 
                 <div className="comhline_sty1"></div>
@@ -108,7 +108,7 @@ class LeaveAddCPage extends Component {
                         dismissText: '取消'
                     }}
                     onChange={date => this.setState({endValue: date})}>
-                    <List.Item arrow="horizontal">请假结束时间</List.Item>
+                    <List.Item arrow="horizontal">结束时间</List.Item>
                 </DatePicker>
 
                 <div className="comhline_sty"></div>

+ 2 - 2
frontend/wechat-web/src/modules/leave/LeaveAddPage.js

@@ -75,7 +75,7 @@ class LeaveAddPage extends Component{
                         dismissText: '取消'
                     }}
                     onChange={date => this.setState({startValue: date})}>
-                    <List.Item arrow="horizontal">请假开始时间</List.Item>
+                    <List.Item arrow="horizontal">开始时间</List.Item>
                 </DatePicker>
 
                 <div className="comhline_sty1"></div>
@@ -87,7 +87,7 @@ class LeaveAddPage extends Component{
                         dismissText: '取消'
                     }}
                     onChange={date => this.setState({endValue: date})}>
-                    <List.Item arrow="horizontal">请假结束时间</List.Item>
+                    <List.Item arrow="horizontal">结束时间</List.Item>
                 </DatePicker>
 
                 <div className="comhline_sty"></div>

+ 8 - 0
frontend/wechat-web/src/modules/leave/LeaveListPage.js

@@ -130,6 +130,10 @@ class LeaveListPage extends React.Component{
                     data: this.state.data,
                     isRefreshing: false,
                     isLoading: false
+                },function () {
+                    if(this.state.data.length == 0){
+
+                    }
                 })
 
             }).catch((error) => {
@@ -253,6 +257,10 @@ class LeaveListPage extends React.Component{
                         }
                         this.setState({
                             data: this.state.data
+                        },function () {
+                            if(this.state.data.length == 0){
+
+                            }
                         })
                     }else{