Browse Source

Merge branch 'master' of http://47.112.200.206:3000/aijia/kmt

TheLittlePrince 5 years ago
parent
commit
d1d16ded03

File diff suppressed because it is too large
+ 3319 - 1179
package-lock.json


+ 4 - 0
package.json

@@ -23,6 +23,7 @@
     "js-cookie": "^2.2.0",
     "popper.js": "^1.14.7",
     "postcss-pxtorem": "^4.0.1",
+    "postcss-url": "^8.0.0",
     "qs": "^6.5.1",
     "v-viewer": "^1.4.0",
     "vue": "^2.5.2",
@@ -55,6 +56,8 @@
     "copy-webpack-plugin": "^4.0.1",
     "cross-spawn": "^5.0.1",
     "css-loader": "^0.28.0",
+    "css-mqpacker": "^7.0.0",
+    "cssnano": "^4.1.10",
     "eslint": "^3.19.0",
     "eslint-config-standard": "^6.2.1",
     "eslint-friendly-formatter": "^3.0.0",
@@ -74,6 +77,7 @@
     "opn": "^5.1.0",
     "optimize-css-assets-webpack-plugin": "^2.0.0",
     "ora": "^1.2.0",
+    "postcss-import": "^12.0.1",
     "rimraf": "^2.6.0",
     "selenium-server": "^3.0.1",
     "semver": "^5.3.0",

+ 3 - 0
src/api/index.js

@@ -59,6 +59,8 @@ const CheckHomeworkStatus = urlFn('/api/kmt/correctSys/checkHomeworkStatus')
 const FindSubjectCharts = urlFn('/api/kmt/correctSys/findSubjectCharts')
 // 匹配知识点老师薪酬列表
 const GetKnowledgeTeacherSalaryList = urlFn('/api/kmt/correctSys/getKnowledgeTeacherSalaryList')
+// 老师资料表
+const AllTeacherInfoList = urlFn('/api/kmt/correctSys/allTeacherInfoList')
 // 校区群管理员数据监控(知识点匹配老师)
 const MonitorKnowTeacherList = urlFn('/api/kmt/correctSys/monitorKnowTeacherList')
 // 数据监控某天(匹配知识点老师)
@@ -97,6 +99,7 @@ export {
     CheckHomeworkStatus,
     FindSubjectCharts,
     GetKnowledgeTeacherSalaryList,
+	AllTeacherInfoList,
     MonitorKnowTeacherList,
     MonitorKnowTeacherOneDayList,
     MonitorKnowTeacherOneMonthList,

+ 39 - 7
src/components/SuperComponent.vue

@@ -5,7 +5,7 @@
     </div>
     <!--v-show="roles.indexOf(item.id) >= 0"-->
     <el-col
-      :span="3"
+      :span="2"
       v-for="(item, index) of menuData"
       :key="item.id"
       @click.native="secondNavClick(item,index)"
@@ -20,7 +20,7 @@
             <span class="box-text">{{getRemindCount.auditCount+'项审核'}}</span>
             <!-- <span class="box-text">{{getRemindCount.distributeCount+'份作业'}}</span> -->
       </div>
-        <div class="box" v-if="index==3 && getRemindCount.distributeCount >0">
+        <div class="box-one" v-if="index==3 && getRemindCount.distributeCount >0">
             <span class="box-text">{{getRemindCount.distributeCount+'份作业'}}</span>
       </div>
     </el-col>
@@ -81,12 +81,12 @@ export default {
         },
         {
           id: "2",
-          name: " 批改老师注册审核",
+          name: " 老师注册审核",
           href: "CheckTeacherAudit"
         },
         {
           id: "3",
-          name: "批改老师薪酬表",
+          name: "老师薪酬表",
           href: "CheckTeacherPay"
         },
         {
@@ -98,7 +98,12 @@ export default {
           id: "5",
           name: "作业统计",
           href: "HomeworkTotally"
-        }
+        },
+				{
+				  id: "6",
+				  name: "排班",
+				  href: "composeType"
+				},
       ],
       checkindex: 0,
     };
@@ -143,6 +148,8 @@ export default {
         this.$router.push("/super/" + "HomeworkRecycle");
       } else if (sessionStorage.getItem("tabIndex") == 4) {
         this.$router.push("/super/" + "HomeworkTotally");
+      } else if (sessionStorage.getItem("tabIndex") == 5) {
+        this.$router.push("/super/" + "ComposeType");
       }
       // this.$router.push("/super/" + val.href);
       // this.checkindex = index;
@@ -255,8 +262,8 @@ export default {
 }
 .box {
   position: relative;
-  top: 0px;
-  left: 0px;
+  top: -130px;
+  left: 100px;
   min-width: 75px;
   height: 34px;
   background: #ff6767;
@@ -265,6 +272,18 @@ export default {
   border-radius: 17px;
   display: inline-block;
 }
+.box-one{
+	position: relative;
+	top: -130px;
+	left: 80px;
+	min-width: 75px;
+	height: 34px;
+	background: #ff6767;
+	-moz-border-radius: 12px;
+	-webkit-border-radius: 12px;
+	border-radius: 17px;
+	display: inline-block;
+}
 .box:before {
   position: absolute;
   content: "";
@@ -278,6 +297,19 @@ export default {
   border-bottom: 5px solid transparent;
   transform: rotate(-45deg);
 }
+.box-one:before {
+  position: absolute;
+  content: "";
+  width: 0;
+  height: 0;
+  right: 100%;
+  top: 25px;
+  left: -5px;
+  border-top: 5px solid transparent;
+  border-right: 18px solid #ff6767;
+  border-bottom: 5px solid transparent;
+  transform: rotate(-45deg);
+}
 .showModel {
   width: 100%;
   height: 100%;

+ 133 - 19
src/pages/super/CheckTeacherAudit.vue

@@ -73,23 +73,6 @@
                 </div>
               </template>
           </el-table-column>
-          <el-table-column
-            prop=""
-            label="可批改时间"
-            header-align="center"
-            width="445"
-          >
-            <template slot-scope="scope">
-                 <div class="buttonAppoval">
-               <div class="TeacherApporTime" v-for="(v, k) of scope.row.periodList" :key=k v-show="v">
-                  <span>{{v}}</span>
-                </div>
-            </div>
-                  <!-- <div>
-                    <el-button type="info" round v-for="(v, k) of scope.row.periodList" :key=k v-show="v">{{v}}</el-button>
-                </div> -->
-            </template>
-          </el-table-column>
             <el-table-column
             prop=""
             label="老师类型"
@@ -101,6 +84,27 @@
                 </div>
               </template>
           </el-table-column>
+					<el-table-column
+					  prop=""
+					  label="身份证"
+					  header-align="center"
+					  width="200"
+					>
+					  <template slot-scope="scope">
+							<img :src='BASE_URL+scope.row.idFace' alt="" class="identity-card" v-if="scope.row.idFace">
+							<span class="bank-active" @click="isShow(3,scope.row.idFace)">查看</span>
+					  </template>
+					</el-table-column>
+					<el-table-column
+					  prop=""
+					  label="银行卡"
+					  header-align="center"
+					  width="120"
+					>
+					  <template slot-scope="scope">
+								<div class="bank-active" @click="isShow(4,scope.row)">{{scope.row.bankName}}</div>
+					  </template>
+					</el-table-column>
           <el-table-column prop="status" label="" header-align="center" width="250">
             <template slot-scope="scope">
               <el-button type="danger" @click="isShow(2,scope.row.teacherId,scope.row.name)">不通过</el-button>
@@ -110,7 +114,7 @@
 
         </el-table>
         <!-- 分页显示 -->
-        <div class="page-block" v-if="parseInt(applyTeacherList.pages) > 10">
+        <div class="page-block" v-if="parseInt(applyTeacherList.pages)" >
           <el-pagination
             background
             @size-change="handleSizeChange"
@@ -124,7 +128,54 @@
   
 
     </el-row>
-
+		<!-- 查看身份证 -->
+		<div class='showModel' @click="allShowModel(3)" v-if="cardShow"></div>
+		<div class='model' v-if="cardShow" style="width: 34%;left: 33%;">
+		  <div class='model-text'>
+		    <div class="model-text-items">
+		      <div><img src="../../assets/img/del@2x.png" alt="" @click="allShowModel(3)" class="model-text-items-close"></div>
+		    </div>
+		    <div class="model-btn">
+		      <img :src='BASE_URL+imgCard' alt="" class="model-btn-info-img">
+		    </div>
+		  </div>
+		</div>
+		<!-- 查看身份证详情-->
+		<div class='showModel' @click="allShowModel(4)" v-if="cardInfoShow"></div>
+		<div class='model' v-if="cardInfoShow" style="width: 34%;left: 33%;">
+		  <div class='model-text'>
+		    <div class="model-text-items">
+		      <div><img src="../../assets/img/del@2x.png" alt="" @click="allShowModel(4)" class="model-text-items-close"></div>
+		    </div>
+		    <div class="model-info">
+					<div class="model-info-items">
+						<div class="model-info-items-left">开户银行</div>
+						<div class="model-info-items-right">
+							<img :src='BASE_URL+cardInfo.bankIcon' alt="" class="model-info-items-right-img">
+							<span>{{cardInfo.bankName}}</span>
+						</div>
+					</div>
+					<div class="model-info-items">
+						<div class="model-info-items-left">开户支行</div>
+						<div class="model-info-items-right">
+							<span>{{cardInfo.bankBranch}}</span>
+						</div>
+					</div>
+					<div class="model-info-items">
+						<div class="model-info-items-left">银行卡号</div>
+						<div class="model-info-items-right">
+							<span>{{cardInfo.cardNumber}}</span>
+						</div>
+					</div>
+					<div class="model-info-items">
+						<div class="model-info-items-left">开户人姓名</div>
+						<div class="model-info-items-right">
+							<span>{{cardInfo.cardholder}}</span>
+						</div>
+					</div>
+				</div>
+		  </div>
+		</div>
     <!--是否通过-->
     <div class='showModel' @click="allShowModel(1)" v-if="hiddenModel"></div>
     <div class='model' v-if="hiddenModel">
@@ -170,6 +221,10 @@
         applicantId:'',
         operate:'',
         list:[],
+				cardShow:false,
+				cardInfoShow:false,
+				imgCard:'',
+				cardInfo:'',
         isPigai:false,
             options: [
         {
@@ -308,6 +363,12 @@
         } else if (str == 2){
           _this.isPigai = true;
           _this.hiddenModel = false;
+        } else if (str == 3){
+          _this.cardShow = true;
+					_this.imgCard = res
+        } else if (str == 4){
+          _this.cardInfoShow = true;
+					_this.cardInfo = res
         }
 
       },
@@ -319,6 +380,10 @@
           _this.hiddenModel = false;
         } else if (str == 2){
           _this.isPigai = false;
+        } else if (str == 3){
+          _this.cardShow = false;
+        } else if (str == 4){
+          _this.cardInfoShow = false;
         }
       },
       // 表格表头设置
@@ -354,6 +419,12 @@
               subject:res[i].subject,
               type:res[i].type,
               myManager:res[i].myManager,
+							idFace:res[i].idFace,
+							bankName:res[i].bankName,
+							bankIcon:res[i].bankIcon,
+							cardholder:res[i].cardholder,
+							cardNumber:res[i].cardNumber,
+							bankBranch:res[i].bankBranch
             })
           }
           return d
@@ -636,6 +707,49 @@
 .activetype{
   color:#52cc60;
 }
+.bank-active{
+	color: #52CC60;
+	font-size: 16px;
+	text-decoration: underline;
+	cursor: pointer;
+}
+.identity-card{
+	width: 52px;
+	height: 51px;
+	border-radius: 4px;
+	margin-right: 17px;
+}
+.model-btn-info-img{
+	width: 451px;
+	height: 298px;
+}
+.model-info{
+	margin-bottom: 50px;
+	padding: 0 58px;
+}
+.model-info-items{
+	height:70px;
+	background:rgba(246,247,251,1);
+	border-radius:6px;
+	line-height: 70px;
+	margin-bottom: 20px;
+	color: #393939;
+	font-size: 24px;
+}
+.model-info-items-left{
+	display: inline-block;
+	width: 25%;
+	text-align: right;
+}
+.model-info-items-right{
+	display: inline-block;
+	width: 70%;
+	padding-left: 60px;
+}
+.model-info-items-right-img{
+	width: 35px;
+	height: 35px;
+}
   /*.all_pagination{*/
     /*text-align: center !important;*/
   /*}*/

+ 163 - 17
src/pages/super/CheckTeacherPay.vue

@@ -21,25 +21,27 @@
             </div>
           </el-col>
           <el-col :span="10" :offset="1">
-            <div
+            <!-- <div
               @click="handApor()"
               :class="{superactive:Activeindex == false,ApporStyles:true}"
             >批改老师</div>
             <div
               @click="AutoApor()"
               :class="{superactive:Activeindex == true,ApporStyles:true}"
-            >匹配知识点老师</div>
+            >匹配知识点老师</div> -->
+						<div  v-for="(item, key) of teacherList" :key="key" @click="teacherType(key)" :class="{superactive:ActiveIndex == key,ApporStyles:true}">{{item}}</div>
           </el-col>
           <el-col :span="4" :offset="4">
             <div class="main-header-item">
               <i class="el-icon-printer"></i>
-              <span v-if="this.showApporAways == false" @click="excel()">导出表格</span>
-               <span v-if="this.showApporAways == true" @click="ApporvalAutoexcel()">导出表格</span>
+              <span v-if="ActiveIndex == 0" @click="excel()">导出表格</span>
+               <span v-if="ActiveIndex == 1" @click="ApporvalAutoexcel()">导出表格</span>
+							 <span v-if="ActiveIndex == 2" @click="TeacherInfoExcel()">导出表格</span>
             </div>
           </el-col>
         </el-row>
         <!--批改老师列表  -->
-        <el-col v-if="this.showApporAways == false">
+        <el-col v-if="ActiveIndex == 0">
           <el-table
           :data="getTeacherSalaryList.list"
           :header-cell-class-name="tableheaderClassName"
@@ -91,7 +93,7 @@
         </div>
         </el-col>
         <!-- 匹配知识点老师 -->
-            <div  v-if="this.showApporAways == true">
+          <div  v-if="ActiveIndex == 1">
           <el-table
            style="width: 100%"
           :data="GetKnowledgeTeacherSalaryList.list"
@@ -131,6 +133,48 @@
             :total="parseInt(GetKnowledgeTeacherSalaryList.pages)"
           ></el-pagination>
         </div>
+				<!-- 老师资料表 -->
+				<div v-if="ActiveIndex == 2">
+				 <el-table
+           style="width: 100%"
+          :data="this.AllTeacherInfoList.list"
+          :header-cell-class-name="tableheaderClassName"
+          :header-cell-style="{
+          'background-color': '#F6F7FB',
+          'color': '#393939',
+          'font-size': '16px'
+           }"
+          size="medium"
+          border
+          stripe
+        >
+          <el-table-column label="注册老师" header-align="center">
+            <template slot-scope="scope">
+              <div class="scope-list">
+                <img :src="BASE_URL+scope.row.imgUrl" alt class="table-img" v-if="scope.row.imgUrl" />
+                <img src="../../assets/img/user.jpg" alt v-if="!scope.row.imgUrl" class="table-img" />
+                <span class="scope-name">{{scope.row.name}}</span>
+              </div>
+            </template>
+          </el-table-column>
+            <el-table-column prop="bankName" label="开户行" header-align="center"></el-table-column>
+          <el-table-column  prop="bankBranch" label="开户支行" header-align="center">
+          </el-table-column>
+          <el-table-column prop="cardholder" label="开户人姓名" header-align="center"></el-table-column>
+					<el-table-column prop="cardNumber" label="银行卡号" header-align="center" ></el-table-column>
+        </el-table>
+        <!-- 分页显示 -->
+          <el-pagination
+            background
+            @size-change="handleSizeChange2"
+            @current-change="pageChange2"
+              :page-sizes="[10,50,100,200]"
+               :current-page.sync="currentPage"
+            layout="sizes, total,prev, pager, next"
+               :hide-on-single-page="true"
+            :total="parseInt(AllTeacherInfoList.pages)"
+          ></el-pagination>
+        </div>
       </el-col>
     </el-row>
 
@@ -167,13 +211,14 @@ export default {
   data() {
     return {
       showApporAways:false,
-      Activeindex: false,
+      ActiveIndex: 0,
       BASE_URL: IMG_BASE_URL,
       selMonth: "",
       hiddenModel: false,
       isPigai: false,
       currentPageSize:10,
       currentPage:1,
+			teacherList:['批改老师','匹配知识点老师','老师资料表'],
       ItemList: [
         {
           text: "数据监控"
@@ -209,7 +254,13 @@ export default {
         oneMonth: "",
         pageNo: 1,
         pageSize: 10
-      }
+      },
+			filters1: {
+			  MaxtimeValue: "",
+			  oneMonth: "",
+			  pageNo: 1,
+			  pageSize: 10
+			},
     };
   },
   watch: {},
@@ -217,7 +268,8 @@ export default {
     ...mapGetters([
       "getUser",
       "getTeacherSalaryList",
-      "GetKnowledgeTeacherSalaryList"
+      "GetKnowledgeTeacherSalaryList",
+			"AllTeacherInfoList"
     ])
   },
   methods: {
@@ -348,13 +400,71 @@ export default {
         }
       }
     },
+		  //老师资料表
+		TeacherInfoExcel() {
+		  try {
+		    //var curTbl = document.getElementById(tableId);
+		    //var lenRow = curTbl.rows.length;
+		    var curTbl = $(".el-table")[0];
+		    var lenRow = curTbl.rows.length;
+		    //创建AX对象excel
+		    var oXL = new ActiveXObject("Excel.Application");
+		    //获取workbook对象
+		    var oWB = oXL.Workbooks.Add();
+		    var oSheet = oWB.ActiveSheet;
+		
+		    //取得表格行数
+		    for (var i = 0; i < lenRow; i++) {
+		      var lenCol = curTbl.rows(i).cells.length;
+		      //取得每行的列数
+		      for (var j = 0; j < lenCol; j++) {
+		        oSheet.Cells(i + 1, j + 1).value = curTbl
+		          .rows(i)
+		          .cells(j).innerText;
+		      }
+		    }
+		    oXL.Visible = true; //设置excel可见属性
+		    //oXL.UserControl = true;
+		    //oXL=null
+		  } catch (e) {
+		    if (!+"\v1") {
+		      //ie浏览器
+		      alert("无法启动Excel,请确保电脑中已经安装了Excel!");
+		    } else {
+		      let arr = this.AllTeacherInfoList.list;
+		      let str =
+		        "注册老师,开户行,开户支行,开户人姓名,银行卡号";
+		      for (let i = 0; i < arr.length; i++) {
+		        str +=
+		          "\n" +
+		          arr[i].name +
+		          "," +
+		          arr[i].bankName +
+		          "," +
+		          arr[i].bankBranch +
+		          "," +
+		          arr[i].cardholder +
+							"," +
+							arr[i].cardNumber;
+		      }
+		      var uri = "data:text/csv;charset=utf-8," + encodeURIComponent(str);
+		      var downloadLink = document.createElement("a");
+		      downloadLink.href = uri;
+		      downloadLink.download = "export.csv";
+		
+		      document.body.appendChild(downloadLink);
+		      downloadLink.click();
+		      document.body.removeChild(downloadLink);
+		    }
+		  }
+		},
     // 手动批改
     handApor() {
       this.Activeindex = false;
        this.showApporAways = false;
        this.filters.pageNo = 1;
        this.selMonth = '';
-     this.filters.pageSize = 10;
+      this.filters.pageSize = 10;
        this.currentPage = 1;
        this.GetTeacherSalaryList()
     },
@@ -368,6 +478,27 @@ export default {
          this.filters0.pageSize = 10;
       this.GetKnownleageSalaryList();
     },
+		// 选择老师
+		teacherType(k) {
+			this.ActiveIndex = k;
+			if (k == 0) {
+			  this.filters.pageNo = 1;
+			   this.filters.pageSize = 10;
+			   this.currentPage = 1;
+			   this.GetTeacherSalaryList()
+			} else if (k == 1) {
+			   this.filters0.pageNo = 1;
+			   this.currentPage = 1;
+			   this.filters0.pageSize = 10;
+			   this.GetKnownleageSalaryList();
+			} else if (k == 2) {
+			   this.filters1.pageNo = 1;
+			   this.currentPage = 1;
+			   this.filters1.pageSize = 10;
+			   this.AllInfoList();
+			}
+		},
+		// 匹配知识点老师薪酬列表
     GetKnownleageSalaryList (){
        this.$store.dispatch("GetKnowledgeTeacherSalaryInfo", {
         pageNo: this.filters0.pageNo,
@@ -376,6 +507,15 @@ export default {
         maxCreateTime: this.formatDate()
       });
     },
+		// 老师资料列表
+		AllInfoList (){
+			this.$store.dispatch("AllTeacherInfoList", {
+			  pageNo: this.filters1.pageNo,
+			  pageSize: this.filters1.pageSize,
+			  oneMonth: this.selMonth,
+			  maxCreateTime: this.formatDate()
+			});
+		},
     //弹框
     isShow(str) {
       let _this = this;
@@ -422,13 +562,9 @@ export default {
         maxCreateTime: this.formatDate()
       });
     },
+		
     GetTeacherSalaryListDatas(){
-        if (this.Activeindex == false){
-            this.GetTeacherSalaryList();
-      }
-       if (this.Activeindex == true){
-          this.GetKnownleageSalaryList()
-      }
+			this.teacherType(this.ActiveIndex)
     },
     // 分页
     pageChange(val) {
@@ -442,6 +578,12 @@ export default {
       this.filters0.pageNo = val;
       this.GetKnownleageSalaryList();
     },
+		   // 分页
+		pageChange2(val) {
+		   this.currentPage = val;
+		  this.filters1.pageNo = val;
+		  this.AllInfoList();
+		},
     changeDateSlot(dateSlot) {
       if (dateSlot) {
         this.filters.startDate = dateSlot[0];
@@ -475,6 +617,10 @@ export default {
       this.filters0.pageSize = val;
       this.GetKnownleageSalaryList();
     },
+		 handleSizeChange2(val) {
+		  this.filters1.pageSize = val;
+		  this.AllInfoList();
+		},
     // 排序
     sortChange(sort) {
       this.filters.orderField = sort.prop;
@@ -492,7 +638,7 @@ export default {
   },
   mounted() {
     sessionStorage.setItem("tabIndex", 2);
-    console.log(sessionStorage.getItem("tabIndex"));
+		
     this.GetTeacherSalaryList();
   }
 };

+ 815 - 0
src/pages/super/ComposeType.vue

@@ -0,0 +1,815 @@
+<!-- 活动解析 -->
+<template>
+  <div>
+    <!-- table 表格 -->
+    <el-row :gutter="20" class="main-items" >
+      <el-col class="aside" :span="3" :offset="2" style="padding: 0 !important;">
+        <div
+          class="table-aside"
+          v-for="(v, k) in ItemList"
+          :key="k"
+          :class="{active:k == modelindex}"
+          @click="selectTitle(k)"
+        >{{v.text}}</div>
+      </el-col>
+      <!--排班表-->
+      <el-col :span="17" class="main" v-if="modelindex == 0">
+        <el-row :gutter="20" >
+          <el-col :span="6" :offset="2" >
+            <div class="selectBox">
+              <div
+                class="Ageclass"
+                @click="choiceclass()"
+                @mouseover="selectStyle()"
+                @mouseout="outStyle()"
+              >
+                <span class="age-tip">{{selecttitlepag}}</span>
+                <span :class="[gardeListDown ?'el-icon-caret-top':'el-icon-caret-bottom']"></span>
+              </div>
+              <div
+                class="class-download"
+                v-show="gardeListDown"
+                @mouseover="selectStyle()"
+                @mouseout="outStyle()"
+              >
+                <ul v-for="(item, k) in options" :key="k">
+                  <li @click="selectTip(item)">{{item.label}}</li>
+                </ul>
+              </div>
+            </div>
+            <div class="selectBox">
+              <div
+                class="Ageclass"
+                @click="choiceclass()"
+                @mouseover="selectStyle1()"
+                @mouseout="outStyle1()"
+              >
+                <span class="age-tip">{{selecttitleage}}</span>
+                <span :class="[gardeListDownage ?'el-icon-caret-top':'el-icon-caret-bottom']"></span>
+              </div>
+              <div
+                class="class-download"
+                v-show="gardeListDownage"
+                @mouseover="selectStyle1()"
+                @mouseout="outStyle1()"
+              >
+                <ul v-for="(item, k) in grades" :key="k">
+                  <li @click="selectTipage(item)">{{item.label}}</li>
+                </ul>
+              </div>
+            </div>
+          </el-col>
+          <el-col :span="12" class='month'>
+           <span >{{currentDateStr }}排班情况</span>
+          </el-col>
+        </el-row>
+        <el-row :gutter="24" >
+					<el-col :span="20" :offset="2" >
+						<!-- 日期 -->
+						<div class="date">
+								<div class="calendar-week">
+									<div class="week-item" v-for="item of weekList" :key="item">{{ item }}</div>
+								</div>
+								<div class="calendar-inner">
+									<div class="calendar-item" v-for="(item, index) of calendarList" :key="index" 
+											:class="[item.disable ? 'disabled' : '']">
+											<el-popover
+											placement="bottom"
+											width="500"
+											trigger="click">
+													<div class="month-day">{{month}}月{{today}}日</div>
+													<el-table :data="gridData" :header-cell-style="{
+          'color': '#393939',
+          'font-size': '14px'
+           }">
+														<el-table-column width="150" label="日期" header-align="center" align="center">
+																<template slot-scope="scope">
+																	<span :class="[scope.$index == 0?'date-time-active':'']">{{scope.row.date}}</span>
+																</template>
+														</el-table-column>
+														<el-table-column width="60" label="最少" header-align="center" align="center">
+																<template slot-scope="scope">
+																	<span :class="[scope.$index == 0?'date-time-active':'']">{{scope.row.less}}</span>
+																</template>
+														</el-table-column>
+														<el-table-column width="60" label="饱和" header-align="center" align="center">
+																<template slot-scope="scope">
+																	<span :class="[scope.$index == 0?'date-time-active':'']">{{scope.row.saturation}}</span>
+																</template>
+														</el-table-column>
+														<el-table-column width="60" label="已选" header-align="center" align="center">
+																<template slot-scope="scope">
+																	<span :class="[scope.$index == 0?'date-time-active':'']">{{scope.row.select}}</span>
+																</template>
+														</el-table-column>
+														<el-table-column width="130" property="" label="" header-align="center" align="center">
+															<template slot-scope="scope">
+																<el-button size="small" type="primary" round :class="[scope.$index == 0?'date-btn-active':'']">排班</el-button>
+															</template>
+														</el-table-column>
+													</el-table>
+													<div slot="reference"  @click="classSet(index,item.date,item.month)" :class="[item.status ? 'checked' : '']" class="day-setting">
+														<div class="date-day">{{ item.date }}</div>
+														<div class="people">
+															<div class="people-items" v-for="(item, key) of levelList" :key="key">
+																<div class="people-items-num" :class="[key == 2?'num-red':'']">22</div>
+																<div class="people-items-text">{{item}}</div>
+															</div>
+														</div>
+													</div>
+											</el-popover>
+									</div>
+								</div>
+						</div>
+					</el-col>
+				</el-row>
+      </el-col>
+      <!--排班设置-->
+      <el-col :span="17" class="main" v-if="modelindex == 1">
+        <el-row :gutter="20" >
+          <el-col :span="18" class='month' :offset="2">
+           <span >{{currentDateStr }}排班设置</span>
+          </el-col>
+        </el-row>
+        <el-row :gutter="24" >
+          <el-col :span="20" :offset="2" >
+            <!-- 日期 -->
+            <div class="date">
+                <div class="calendar-week">
+                  <div class="week-item" v-for="item of weekList" :key="item">{{ item }}</div>
+                </div>
+                <div class="calendar-inner">
+                  <div class="calendar-item" v-for="(item, index) of setCalendarList" :key="index" 
+                      :class="[item.disable ? 'disabled' : '']" >
+                      <el-popover
+                      placement="bottom"
+                      width="108"
+                      trigger="click">
+                          <div class='date-set'>
+                            <div>待开放</div>
+                            <div>不开放</div>
+                          </div> 
+                          <div slot="reference" v-if="!item.disable" @click="settingClick(index)" :class="[item.status ? 'checked' : '']" class="day-setting">
+                            <div class="date-day-set-num">{{ item.date }}</div>
+                            <div class="date-day-set">待开放</div>
+                          </div>
+                      </el-popover>
+                  </div>
+                </div>
+            </div>
+          </el-col>
+        </el-row>
+      </el-col>
+    </el-row>
+
+  </div>
+</template>
+<script>
+  import { mapGetters, mapActions } from "vuex";
+  import { IMG_BASE_URL } from '@/ImgConfig'
+  export default {
+    components: { },
+    name: "actvResolveLabel",
+    props: {},
+    data() {
+      return {
+        BASE_URL:IMG_BASE_URL,
+        selMonth:'',
+        hiddenModel:false,
+        isPigai:false,
+        gardeListDown: false,
+        gardeListDownage: false,
+        modelindex:0,
+				selecttitlepag: "选老师",
+				selecttitleage: "选科目",
+				current: {},   // 当前时间
+        weekList: ['一', '二', '三', '四', '五', '六', '日'],
+        calendarList: [],  // 排班列表
+				setCalendarList: [],  // 排班设置列表
+        shareDate: new Date(), // 享元模式,用来做优化的
+				month:'',
+				today:'',
+				gridData: [{
+          date: '10:00-12:00',
+          less: '22',
+          saturation: '25',
+					select:'43'
+        }, {
+          date: '15:00-17:00',
+          less: '22',
+          saturation: '25',
+          select:'53'
+        }, {
+          date: '17:00-19:00',
+          less: '22',
+          saturation: '25',
+          select:'3'
+        }, {
+          date: '19:00-21:00',
+          less: '22',
+          saturation: '5',
+          select:'13'
+        }],
+        filters: {
+          actvNm: "",
+          actvCrtUserId: "",
+          actvType: "",
+          actvSmallType: "",
+          // 排序
+          MaxtimeValue:'',
+          oneMonth:'',
+          pageNo: 1,
+          pageSize: 10,
+          count: 0,
+          orderField: "",
+          orderAD: ""
+        },
+				levelList:['最少','饱和','已选'],
+        ItemList: [
+        {
+          text: "排班表"
+        },
+        {
+          text: "排班设置"
+        }
+      ],
+      options: [
+        {
+          value: "0",
+          label: "1~2年级",
+          str: "一年级,二年级"
+        },
+        {
+          value: "1",
+          label: "3~4年级",
+          str: "三年级,四年级"
+        },
+        
+      ],
+       grades: [
+        {
+          value: "0",
+          label: "语文",
+          str: "语文"
+        },
+        {
+          value: "1",
+          label: "数学",  
+          str: "数学"
+        },
+        {
+          value: "2",
+          label: "英语",
+          str: "英语"
+        },
+        {
+          value: "3",
+          label: "全部"
+          // str:""
+        }
+      ],
+        allotList:{
+          pageNo: 1,
+          pageSize: 10,
+          count: 0,
+          grade:'',
+          subject:'',
+          homeworkId:'',
+          TeacherType:''
+        }
+      };
+    },
+    watch: {},
+  // ,'homeworkRecoveryList'
+    computed: {
+      ...mapGetters(["getUser",'homeworkRecoveryList','TeacherAllotList']),
+			// 显示当前时间
+        currentDateStr() {
+            let { year, month } = this.current;
+            return `${this.pad(month + 1)}月`;
+        }
+    },
+    methods: {
+      ...mapActions(["setUser"]),
+      // 表格头部样式
+      tableheaderClassName({ row, rowIndex }) {
+        return "table-head-th";
+      },
+      //弹框
+      isShow(str,t,id,type){
+          this.isPigai = true;
+          this.allotList.grade = str;
+          this.allotList.subject = t;
+          this.allotList.homeworkId = id
+            this.allotList.TeacherType = type
+          this.TeacherAllot()
+      },
+      
+     selectStyle() {
+      this.gardeListDown = true;
+    },
+    outStyle() {
+      this.gardeListDown = false;
+    },
+		selectStyle1() {
+		  this.gardeListDownage = true;
+		},
+    outStyle1() {
+      this.gardeListDownage = false;
+    },
+      selectTitle(k) {
+      this.modelindex = k;
+      
+    },
+		selectTip(item) {
+		  
+		  this.selecttitlepag = item.label;
+		  this.gardeListDown = false;
+		},
+		selectTipage(item) {
+		  
+		  this.selecttitleage = item.label;
+		  this.gardeListDownage = false;
+		},
+      // 分页
+      pageChange(val) {
+        this.allotList.pageNo = val;
+        this.TeacherAllot();
+      },
+      pageChange1(val) {
+        this.filters.pageNo = val;
+        this.HomeworkRecoveryList();
+      },
+      changeDateSlot(dateSlot) {
+        if (dateSlot) {
+          this.filters.startDate = dateSlot[0];
+          this.filters.endDate = dateSlot[1];
+        } else {
+          this.filters.startDate = null;
+          this.filters.endDate = null;
+        }
+      },
+      actvTypeChange(typeList) {
+        switch (typeList.length) {
+          case 1:
+            this.filters.actvType = typeList[0];
+            this.filters.actvSmallType = null;
+            break;
+          case 2:
+            this.filters.actvType = null;
+            this.filters.actvSmallType = typeList[1];
+            break;
+          default:
+            this.filters.actvType = null;
+            this.filters.actvSmallType = null;
+            break;
+        }
+      },
+      handleSizeChange(val) {
+        this.allotList.pageSize = val;
+        this.TeacherAllot();
+      },
+      handleSizeChange1(val) {
+        this.filters.pageSize = val;
+        this.HomeworkRecoveryList();
+      },
+      // 排序
+      sortChange(sort) {
+        this.filters.orderField = sort.prop;
+        this.filters.orderAD = sort.order != null ? sort.order : "";
+        this.itemListReshow();
+      },
+      clearSearch() {
+        this.filters.actvNm = null;
+        this.filters.actvCrtUserId = null;
+        this.filters.actvType = null;
+        this.filters.actvSmallType = null;
+        this.filtersActvType = [];
+        this.createDateSlot = null;
+      },
+			// 日期处理
+			init() {
+            // 初始化当前时间
+            this.setCurrent();
+            this.calendarCreator();
+        },
+        // 判断当前月有多少天
+        getDaysByMonth(year, month) {
+            return new Date(year, month + 1, 0).getDate();
+        },
+        getFirstDayByMonths(year, month) {
+            return new Date(year, month, 1).getDay();
+        },
+        getLastDayByMonth(year, month) {
+            return new Date(year, month + 1, 0).getDay();
+        },
+        // 对小于 10 的数字,前面补 0
+        pad(str) {
+            return str < 10 ? `0${str}` : str;
+        },
+        // 点击上一月
+        prevMonth() {
+            this.current.month--;
+            // 因为 month的变化 会超出 0-11 的范围, 所以需要重新计算
+            this.correctCurrent();
+            // 生成新日期
+            this.calendarCreator();
+        },
+        // 点击下一月
+        nextMonth() {
+            this.current.month++;
+            // 因为 month的变化 会超出 0-11 的范围, 所以需要重新计算
+            this.correctCurrent();
+            // 生成新日期
+            this.calendarCreator();
+        },
+        // 格式化时间,与主逻辑无关
+        stringify(year, month, date) {
+            let str = [year, this.pad(month + 1), this.pad(date)].join('-');
+            return str;
+        },
+        // 设置或初始化 current
+        setCurrent(d = new Date()) {
+            let year = d.getFullYear();
+            let month = d.getMonth();
+            let date = d.getDate();
+            this.current = {
+                year,
+                month,
+                date
+            }
+        },
+        // 修正 current
+        correctCurrent() {
+            let { year, month, date } = this.current;
+
+            let maxDate = this.getDaysByMonth(year, month);
+            // 预防其他月跳转到2月,2月最多只有29天,没有30-31
+            date = Math.min(maxDate, date);
+
+            let instance = new Date(year, month, date);
+            this.setCurrent(instance);
+        },
+        // 生成日期
+        calendarCreator() {
+            // 一天有多少毫秒
+            const oneDayMS = 24 * 60 * 60 * 1000;
+
+            let list = [];
+						let setList = [];
+            let { year, month } = this.current;
+						
+            // 当前月份第一天是星期几, 0-6
+            let firstDay = this.getFirstDayByMonths(year, month);
+            // 填充多少天                         
+            let prefixDaysLen = firstDay === 0 ? 6 : firstDay - 1;
+            // 毫秒数
+            let begin = new Date(year, month, 1).getTime() - oneDayMS * prefixDaysLen;
+
+            // 当前月份最后一天是星期几, 0-6
+            let lastDay = this.getLastDayByMonth(year, month);
+            // 填充多少天, 和星期的排放顺序有关
+            let suffixDaysLen = lastDay === 0 ? 0 : 7 - lastDay;
+            // 毫秒数
+            let end = new Date(year, month + 1, 0).getTime() + oneDayMS * suffixDaysLen;
+						// 计算今天几号
+						let today = new Date().getDate();
+						// 饱和度
+						// console.log(today)
+            while (begin <= end) {
+                // 享元模式,避免重复 new Date
+                this.shareDate.setTime(begin);
+                let year = this.shareDate.getFullYear();
+                let curMonth = this.shareDate.getMonth();
+                let date = this.shareDate.getDate();
+								// console.log(curMonth,date)
+								// 排班
+                list.push({
+                    year: year,
+                    month: curMonth,
+                    date: date,
+                    disable: curMonth !== month || date < today,
+										status:false,
+                    value: this.stringify(year, curMonth, date)
+                });
+								// 排班设置
+								setList.push({
+								    year: year,
+								    month: curMonth,
+								    date: date,
+										status:false,
+								    disable: curMonth !== month,
+								    value: this.stringify(year, curMonth, date)
+								});
+                begin += oneDayMS;
+            }
+
+            this.calendarList = list;
+						this.setCalendarList = setList;
+						console.log(this.calendarList)
+						},
+						// 排班点击
+					 classSet(k,d,m){
+						 // console.log(k,d,m)
+						 this.month = m + 1;
+						 this.today = d;
+						 for (var i in this.calendarList) {
+							 this.calendarList[i].status = false;
+						 }
+						 this.calendarList[k].status = !this.calendarList[k].status;
+					 },
+					 // 排班设置点击
+					 settingClick(k){
+					 		for (var i in this.setCalendarList) {
+					 					this.setCalendarList[i].status = false;
+					 				}
+					 		this.setCalendarList[k].status = !this.setCalendarList[k].status;
+					 },
+					 
+    },
+    mounted() {
+      sessionStorage.setItem('tabIndex',5);
+			this.init();
+    }
+  };
+</script>
+
+<!-- Add "scoped" attribute to limit CSS to this component only -->
+<style scoped>
+
+  .main{
+    background-color: #fff;
+    margin-top: 16px;
+    padding: 0 !important;
+    border: 1px solid #E1E1E1;
+    min-height: 980px;
+  }
+
+  el-table{
+    color: #999999;
+    font-size: 18px;
+  }
+  .main-items{
+    color: #393939;
+    text-align: center;
+    line-height: 80px;
+  }
+  .aside {
+  background-color: #fff;
+  margin-top: 16px;
+  margin-right: 16px;
+  padding: 0;
+  min-height: 880px;
+}
+.selectBox {
+  position: relative;
+  float: left;
+  display: inline-block;
+	margin-top: 57px;
+}
+.Ageclass {
+  display: inline-block;
+  height: 40px;
+  width: 120px;
+  background-color: #f1f2f4;
+  line-height: 40px;
+  font-size: 16px;
+  cursor: pointer;
+}
+.active {
+  background-color: #52cc60 !important;
+  color: #fff !important;
+}
+.table-aside {
+  color: #666666;
+  font-size: 18px;
+  text-align: center;
+  line-height: 60px;
+  cursor: pointer;
+}
+el-table {
+  color: #999999;
+  font-size: 18px;
+}
+
+  .input-with-select .el-input-group__prepend {
+    background-color: #fff;
+  }
+
+  .showModel {
+    width: 100%;
+    height: 100%;
+    position: fixed;
+    top: 0;
+    left: 0;
+    background: #000000;
+    opacity: 0.2;
+    overflow: hidden;
+    z-index: 1000;
+    color: #fff;
+  }
+  .model {
+    z-index: 10000;
+    width: 60%;
+    height: auto;
+    position: fixed;
+    top: 15%;
+    left: 30%;
+    margin: auto;
+    background: #fff;
+    border-radius: 10px;
+    text-align: center;
+  }
+
+  .model-text {
+    background: rgba(255, 255, 255, 1);
+    border-radius: 10px;
+  }
+
+  .model-items-left {
+    width: 100%;
+    color: #393939;
+    font-size: 24px;
+  }
+  .model-items-left-top {
+    display: flex;
+    justify-content: space-between;
+  }
+
+  .model-items-left-top-img {
+    width: 68px;
+    height: 68px;
+    border-radius: 8px;
+    position: relative;
+    bottom: 25px;
+  }
+  .model-items-left-top-number {
+    color: #7e7e7e;
+    font-size: 18px;
+    margin-left: 10px;
+  }
+
+  .el-table .table-head-th{
+    background-color:#F6F7FB;
+    font-size: 16px !important;
+    color: #393939;
+
+  }
+  .month{
+    color:#393939;
+    font-size:30px;
+		margin-top: 57px;
+  }
+  .model-manager {
+    display: flex;
+    justify-content: space-between;
+    margin: 30px;
+    color: #393939;
+    font-size: 24px;
+  }
+  .allocation-items{
+    width: 45%;
+    display: inline-block;
+    margin-right: 20px;
+    margin-bottom:30px;
+  }
+  .allocation{
+    color: #52CC60;
+    font-size: 20px;
+    text-decoration: underline;
+    cursor: pointer;
+  }
+.el-pagination.is-background .el-pager li:not(.disabled).active {
+    background-color:#52cc60!important;
+    color: #fff;
+}
+  .pages{
+    margin: 15px 0;
+  }
+	.age-tip {
+	  width: 80%;
+	  height: 40px;
+	  color: #747070;
+	  font-size: 12px;
+	}
+	.class-download {
+	  background-color: #fff;
+	  width: 160px;
+	  z-index: 999999;
+	  position: absolute;
+	  border: 1px solid #e0dddd;
+	  border-radius: 5px;
+	  top: 58px;
+	}
+	.class-download ul li {
+	  height: 40px;
+	  line-height: 40px;
+	  text-align: center;
+	  cursor: pointer;
+	  color: #b6b6b6;
+	}
+	.class-download ul li:hover {
+	  background-color: #52cc60;
+	  color: #ffff;
+	}
+ .date{
+	 margin-top: 68px;
+ }
+ .calendar-week{
+	 border: 1px solid #E5E5E5;
+	 text-align: center;
+	 border-right: none;
+	 display: flex;
+ }
+ .week-item{
+	 display: inline-block;
+	 background: #F9F9F9;
+	 width: 14.28%;
+	 border-right: 1px solid #E5E5E5;
+ }
+ .calendar-inner{
+	 border-left:1px solid #E5E5E5;
+ }
+ .calendar-item {
+    float: left;
+    width: 14.28%;
+    height: 130px;
+    line-height: 130px;
+    text-align: center;
+		border-bottom:1px solid #E5E5E5;
+		border-right:1px solid #E5E5E5;
+		border-left:1px solid #E5E5E5;
+}
+.day-setting{
+	height: 130px;
+	line-height: 130px;
+}
+.calendar-item.disabled {
+    color: #ccc;
+		background:rgba(255,255,255,0.2);
+}
+.checked {
+    background: #F6F7FB;
+}
+.date-day{
+	font-size: 16px;
+	line-height: 60px;
+	color: #aaa;
+}
+.people{
+	display: flex;
+	justify-content: space-around;
+	font-size: 14px;
+}
+.people-items{
+	display: inline-block;
+	line-height: 70px;
+	margin-top: 10px;
+}
+.people-items-num{
+	line-height: 15px;
+	padding: 3px 8px;
+}
+.people-items-text{
+	line-height: 30px;
+}
+.num-red{
+	background:rgba(255,100,101,1);
+  border-radius:9px;
+	color: #fff;
+}
+.month-day{
+	margin: 10px 30px;
+	color: #393939;
+	font-size: 20px;
+}
+.date-set{
+  text-align: center;
+  width:100%;
+}
+.date-set>div{
+  color:#393939;
+  font-size:16px;
+  margin:25px;
+}
+.date-day-set{
+	line-height: 40px;
+	color: #393939;;
+	font-size: 16px;
+}
+.date-day-set-num{
+	font-size: 16px;
+	line-height: 70px;
+	color: #aaa;
+}
+.date-red{
+	color: #FF6465;
+}
+.date-time-active{
+	color: #e5e5e5;
+}
+.date-btn-active{
+	background:rgba(114,151,255,0.3);
+	border:none;
+}
+</style>

+ 7 - 0
src/router/index.js

@@ -19,6 +19,7 @@ import CheckTeacherPay from "@/pages/Super/CheckTeacherPay";
 import SuperAdmin from "@/pages/Super/SuperAdmin";
 import HomeworkRecycle from "@/pages/Super/HomeworkRecycle";
 import HomeworkTotally from "@/pages/Super/HomeworkTotally";
+import ComposeType from "@/pages/Super/ComposeType";
 // 在线批改老师
 import Onlineteacher from "@/pages/OnlineTeacher/onlineteacher";
 import Redirect_uri from "@/pages/aikmt/Redirect_uri"; //微信登陆路由重定向页面
@@ -94,6 +95,12 @@ export const constantRouterMap =
           component: HomeworkTotally,
           meta: { title: '作业统计', roles: ['3'] }
         },
+				{
+				  path: "ComposeType",
+				  name: "ComposeType",
+				  component: ComposeType,
+				  meta: { title: '排班', roles: ['3'] }
+				},
        ]
      },
     //  校区管理员角色路由

+ 1 - 0
src/store/getters.js

@@ -40,6 +40,7 @@ const getters = {
   FindSubjectEngCharts :state => state.user.FindSubjectEngCharts,
   AllFindSubjectEngCharts :state => state.user.AllFindSubjectEngCharts,
   GetKnowledgeTeacherSalaryList:state => state.user.GetKnowledgeTeacherSalaryList,
+  AllTeacherInfoList:state => state.user.AllTeacherInfoList,
   FindCalendarList:state => state.user.FindCalendarList,
   FindHaveTeacherList:state => state.user.FindHaveTeacherList,
   FindNoHaveTeacherList:state => state.user.FindNoHaveTeacherList,

+ 21 - 2
src/store/modules/user.js

@@ -4,7 +4,7 @@ import { GET_UUIONID_TOKEN,GET_TOKEN,GetInfo,InfoWatch,InfoWatchDay,
   GetStudentDetail,GetManagerDetail,Downgrade,SuperManagerList,
   SuperApplyTeacherList,ApplyOperate,GetTeacherSalaryList,DealCorrectTeacher,
   GetAllotManagerList,AllotTeacherToManager,HomeworkRecoveryList,errorWarning,errorDetail,logout,
-  CheckHomeworkStatus,FindSubjectCharts,GetRemindCount,GetKnowledgeTeacherSalaryList,MonitorKnowTeacherList, MonitorKnowTeacherOneDayList,UnmatchHomeworkList,
+  CheckHomeworkStatus,FindSubjectCharts,GetRemindCount,GetKnowledgeTeacherSalaryList,AllTeacherInfoList,MonitorKnowTeacherList, MonitorKnowTeacherOneDayList,UnmatchHomeworkList,
   MonitorKnowTeacherOneMonthList
   } from '@/api'
   import { APPOR_BASE_URL } from '@/ImgConfig'
@@ -48,7 +48,8 @@ const user = {
     FindSubjectmathCharts:[],
     FindSubjectEngCharts:[],
     AllFindSubjectEngCharts:[],
-    GetKnowledgeTeacherSalaryList:[]
+    GetKnowledgeTeacherSalaryList:[],
+		AllTeacherInfoList:[]
   },
 
   mutations: {
@@ -165,6 +166,9 @@ const user = {
     SET_UNALLOT_TEACHER_SALARY:(state,GetKnowledgeTeacherSalaryList) => {
       state.GetKnowledgeTeacherSalaryList = GetKnowledgeTeacherSalaryList
     },
+		SET_ALL_TEACHER_INFO_LIST:(state,AllTeacherInfoList) => {
+		  state.AllTeacherInfoList = AllTeacherInfoList
+		},
   },
 
   actions: {
@@ -503,6 +507,21 @@ const user = {
         })
       })
     },
+		// 老师资料表
+		AllTeacherInfoList({ commit, state }, data) {
+		  return new Promise((resolve, reject) => {
+		    axios.post(AllTeacherInfoList, data).then(response => {
+		      const data = response.data || {}
+		      if (response.code === "999"){
+		        // debugger
+		        commit('SET_ALL_TEACHER_INFO_LIST', data);
+		      }
+		      resolve(response)
+		    }).catch(error => {
+		      reject(error)
+		    })
+		  })
+		},
 
         // 未批改作业列表
         UnallotHomeworkList({ commit, state }, data) {