|  | @@ -5,129 +5,148 @@
 | 
	
		
			
				|  |  |        运营预警
 | 
	
		
			
				|  |  |      </h2>
 | 
	
		
			
				|  |  |      <div class="m-core">
 | 
	
		
			
				|  |  | -      <el-form :inline="true"
 | 
	
		
			
				|  |  | -               :model="searchForm">
 | 
	
		
			
				|  |  | +      <save-form :inline="true" :model="searchForm" @submit='search' @reset='onReSet'>
 | 
	
		
			
				|  |  |          <el-form-item>
 | 
	
		
			
				|  |  | -          <el-select v-model.trim="searchForm.organId"
 | 
	
		
			
				|  |  | -                     @clear="onClear('organId')"
 | 
	
		
			
				|  |  | -                     placeholder='请选择分部'
 | 
	
		
			
				|  |  | -                     clearable
 | 
	
		
			
				|  |  | -                     filterable>
 | 
	
		
			
				|  |  | -            <el-option v-for='(item,index) in organList'
 | 
	
		
			
				|  |  | -                       :key="index"
 | 
	
		
			
				|  |  | -                       :value="item.id"
 | 
	
		
			
				|  |  | -                       :label="item.name"></el-option>
 | 
	
		
			
				|  |  | +          <el-select
 | 
	
		
			
				|  |  | +            v-model.trim="searchForm.organId"
 | 
	
		
			
				|  |  | +            placeholder="请选择分部"
 | 
	
		
			
				|  |  | +            clearable
 | 
	
		
			
				|  |  | +            filterable
 | 
	
		
			
				|  |  | +          >
 | 
	
		
			
				|  |  | +            <el-option
 | 
	
		
			
				|  |  | +              v-for="(item, index) in selects.branchs"
 | 
	
		
			
				|  |  | +              :key="index"
 | 
	
		
			
				|  |  | +              :value="item.id"
 | 
	
		
			
				|  |  | +              :label="item.name"
 | 
	
		
			
				|  |  | +            ></el-option>
 | 
	
		
			
				|  |  |            </el-select>
 | 
	
		
			
				|  |  |          </el-form-item>
 | 
	
		
			
				|  |  |          <el-form-item>
 | 
	
		
			
				|  |  | -          <el-select v-model.trim="searchForm.userId"
 | 
	
		
			
				|  |  | -                     @clear="onClear('userId')"
 | 
	
		
			
				|  |  | -                     clearable
 | 
	
		
			
				|  |  | -                     filterable
 | 
	
		
			
				|  |  | -                     placeholder="指导老师">
 | 
	
		
			
				|  |  | -            <el-option v-for="(item,index) in teacherList"
 | 
	
		
			
				|  |  | -                       :key='index'
 | 
	
		
			
				|  |  | -                       :value="item.id"
 | 
	
		
			
				|  |  | -                       :label="item.username"></el-option>
 | 
	
		
			
				|  |  | -          </el-select>
 | 
	
		
			
				|  |  | +          <remote-search
 | 
	
		
			
				|  |  | +            :commit="'setTeachers'"
 | 
	
		
			
				|  |  | +            v-model="searchForm.userId"
 | 
	
		
			
				|  |  | +          />
 | 
	
		
			
				|  |  |          </el-form-item>
 | 
	
		
			
				|  |  |          <el-form-item>
 | 
	
		
			
				|  |  | -          <el-date-picker v-model.trim="searchForm.monthStr"
 | 
	
		
			
				|  |  | -                          @clear="onClear('monthStr')"
 | 
	
		
			
				|  |  | -                          type="month"
 | 
	
		
			
				|  |  | -                          value-format="yyyy-MM"
 | 
	
		
			
				|  |  | -                          placeholder="选择月">
 | 
	
		
			
				|  |  | +          <el-date-picker
 | 
	
		
			
				|  |  | +            v-model.trim="searchForm.monthStr"
 | 
	
		
			
				|  |  | +            type="month"
 | 
	
		
			
				|  |  | +            value-format="yyyy-MM"
 | 
	
		
			
				|  |  | +            placeholder="选择月"
 | 
	
		
			
				|  |  | +          >
 | 
	
		
			
				|  |  |            </el-date-picker>
 | 
	
		
			
				|  |  |          </el-form-item>
 | 
	
		
			
				|  |  |          <el-form-item>
 | 
	
		
			
				|  |  | -          <el-button type="danger"
 | 
	
		
			
				|  |  | -                     @click="search">搜索</el-button>
 | 
	
		
			
				|  |  | -          <el-button @click="onReSet"
 | 
	
		
			
				|  |  | -                     type="primary">重置</el-button>
 | 
	
		
			
				|  |  | +          <el-button type="danger" native-type="submit">搜索</el-button>
 | 
	
		
			
				|  |  | +          <el-button native-type="reset" type="primary">重置</el-button>
 | 
	
		
			
				|  |  |          </el-form-item>
 | 
	
		
			
				|  |  | -      </el-form>
 | 
	
		
			
				|  |  | +      </save-form>
 | 
	
		
			
				|  |  |        <div class="tableWrap">
 | 
	
		
			
				|  |  | -        <el-table :data='tableList'
 | 
	
		
			
				|  |  | -                  :header-cell-style="{background:'#EDEEF0',color:'#444'}">
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           prop="monthStr"
 | 
	
		
			
				|  |  | -                           label="月份">
 | 
	
		
			
				|  |  | +        <el-table
 | 
	
		
			
				|  |  | +          :data="tableList"
 | 
	
		
			
				|  |  | +          :header-cell-style="{ background: '#EDEEF0', color: '#444' }"
 | 
	
		
			
				|  |  | +        >
 | 
	
		
			
				|  |  | +          <el-table-column align="center" prop="monthStr" label="月份">
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           prop="organName"
 | 
	
		
			
				|  |  | -                           label="分部">
 | 
	
		
			
				|  |  | +          <el-table-column align="center" prop="organName" label="分部">
 | 
	
		
			
				|  |  | +                <template slot-scope="scope">
 | 
	
		
			
				|  |  | +              <div>
 | 
	
		
			
				|  |  | +                <copy-text>{{ scope.row.organName }}</copy-text>
 | 
	
		
			
				|  |  | +              </div>
 | 
	
		
			
				|  |  | +            </template>
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           prop="realName"
 | 
	
		
			
				|  |  | -                           label="老师">
 | 
	
		
			
				|  |  | +          <el-table-column align="center" prop="realName" label="老师">
 | 
	
		
			
				|  |  | +                 <template slot-scope="scope">
 | 
	
		
			
				|  |  | +              <div>
 | 
	
		
			
				|  |  | +                <copy-text>{{ scope.row.realName }}</copy-text>
 | 
	
		
			
				|  |  | +              </div>
 | 
	
		
			
				|  |  | +            </template>
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           prop="subjectListStr"
 | 
	
		
			
				|  |  | -                           label="专业">
 | 
	
		
			
				|  |  | +          <el-table-column align="center" prop="subjectListStr" label="专业">
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           prop="musicCourseNum"
 | 
	
		
			
				|  |  | -                           label="乐团节数">
 | 
	
		
			
				|  |  | +          <el-table-column
 | 
	
		
			
				|  |  | +            align="center"
 | 
	
		
			
				|  |  | +            prop="musicCourseNum"
 | 
	
		
			
				|  |  | +            label="乐团节数"
 | 
	
		
			
				|  |  | +          >
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           prop="vipCourseNum"
 | 
	
		
			
				|  |  | -                           label="小课节数">
 | 
	
		
			
				|  |  | +          <el-table-column align="center" prop="vipCourseNum" label="小课节数">
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           prop="expectMusicCourseSalary"
 | 
	
		
			
				|  |  | -                           label="预计乐团课酬">
 | 
	
		
			
				|  |  | +          <el-table-column
 | 
	
		
			
				|  |  | +            align="center"
 | 
	
		
			
				|  |  | +            prop="expectMusicCourseSalary"
 | 
	
		
			
				|  |  | +            label="预计乐团课酬"
 | 
	
		
			
				|  |  | +          >
 | 
	
		
			
				|  |  |              <template slot-scope="scope">
 | 
	
		
			
				|  |  |                <div>
 | 
	
		
			
				|  |  | -                {{scope.row.expectMusicCourseSalary | moneyFormat}}
 | 
	
		
			
				|  |  | +                {{ scope.row.expectMusicCourseSalary | moneyFormat }}
 | 
	
		
			
				|  |  |                </div>
 | 
	
		
			
				|  |  |              </template>
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           prop="expectVipCourseSalary"
 | 
	
		
			
				|  |  | -                           label="预计小课课酬">
 | 
	
		
			
				|  |  | +          <el-table-column
 | 
	
		
			
				|  |  | +            align="center"
 | 
	
		
			
				|  |  | +            prop="expectVipCourseSalary"
 | 
	
		
			
				|  |  | +            label="预计小课课酬"
 | 
	
		
			
				|  |  | +          >
 | 
	
		
			
				|  |  |              <template slot-scope="scope">
 | 
	
		
			
				|  |  |                <div>
 | 
	
		
			
				|  |  | -                {{scope.row.expectVipCourseSalary | moneyFormat}}
 | 
	
		
			
				|  |  | +                {{ scope.row.expectVipCourseSalary | moneyFormat }}
 | 
	
		
			
				|  |  |                </div>
 | 
	
		
			
				|  |  |              </template>
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           label="预计课酬合计"
 | 
	
		
			
				|  |  | -                           prop="expectTotalSalary">
 | 
	
		
			
				|  |  | +          <el-table-column
 | 
	
		
			
				|  |  | +            align="center"
 | 
	
		
			
				|  |  | +            label="预计课酬合计"
 | 
	
		
			
				|  |  | +            prop="expectTotalSalary"
 | 
	
		
			
				|  |  | +          >
 | 
	
		
			
				|  |  |              <template slot-scope="scope">
 | 
	
		
			
				|  |  |                <div>
 | 
	
		
			
				|  |  | -                {{scope.row.expectTotalSalary | moneyFormat}}
 | 
	
		
			
				|  |  | +                {{ scope.row.expectTotalSalary | moneyFormat }}
 | 
	
		
			
				|  |  |                </div>
 | 
	
		
			
				|  |  |              </template>
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  | -          <el-table-column align='center'
 | 
	
		
			
				|  |  | -                           prop="averageClassMinutes"
 | 
	
		
			
				|  |  | -                           label="平均上课时长">
 | 
	
		
			
				|  |  | +          <el-table-column
 | 
	
		
			
				|  |  | +            align="center"
 | 
	
		
			
				|  |  | +            prop="averageClassMinutes"
 | 
	
		
			
				|  |  | +            label="平均上课时长"
 | 
	
		
			
				|  |  | +          >
 | 
	
		
			
				|  |  |            </el-table-column>
 | 
	
		
			
				|  |  |          </el-table>
 | 
	
		
			
				|  |  | -        <pagination :total="pageInfo.total"
 | 
	
		
			
				|  |  | -                    :page.sync="pageInfo.page"
 | 
	
		
			
				|  |  | -                    :limit.sync="pageInfo.limit"
 | 
	
		
			
				|  |  | -                    :page-sizes="pageInfo.page_size"
 | 
	
		
			
				|  |  | -                    @pagination="getList" />
 | 
	
		
			
				|  |  | +        <pagination
 | 
	
		
			
				|  |  | +          sync
 | 
	
		
			
				|  |  | +          :total.sync="pageInfo.total"
 | 
	
		
			
				|  |  | +          :page.sync="pageInfo.page"
 | 
	
		
			
				|  |  | +          :limit.sync="pageInfo.limit"
 | 
	
		
			
				|  |  | +          :page-sizes="pageInfo.page_size"
 | 
	
		
			
				|  |  | +          @pagination="getList"
 | 
	
		
			
				|  |  | +        />
 | 
	
		
			
				|  |  |        </div>
 | 
	
		
			
				|  |  |      </div>
 | 
	
		
			
				|  |  |    </div>
 | 
	
		
			
				|  |  |  </template>
 | 
	
		
			
				|  |  |  <script>
 | 
	
		
			
				|  |  | -import { getEmployeeOrgan, teacherCourseStatistics, getTeacher } from '@/api/buildTeam'
 | 
	
		
			
				|  |  | -import pagination from '@/components/Pagination/index'
 | 
	
		
			
				|  |  | -let nowDate = new Date()
 | 
	
		
			
				|  |  | -let nowMonth = nowDate.getFullYear() + '-' + ((nowDate.getMonth() + 1) >= 10 ? (nowDate.getMonth() + 1) : '0' + (nowDate.getMonth() + 1))
 | 
	
		
			
				|  |  | +import {
 | 
	
		
			
				|  |  | +  getEmployeeOrgan,
 | 
	
		
			
				|  |  | +  teacherCourseStatistics,
 | 
	
		
			
				|  |  | +  getTeacher,
 | 
	
		
			
				|  |  | +} from "@/api/buildTeam";
 | 
	
		
			
				|  |  | +import pagination from "@/components/Pagination/index";
 | 
	
		
			
				|  |  | +let nowDate = new Date();
 | 
	
		
			
				|  |  | +let nowMonth =
 | 
	
		
			
				|  |  | +  nowDate.getFullYear() +
 | 
	
		
			
				|  |  | +  "-" +
 | 
	
		
			
				|  |  | +  (nowDate.getMonth() + 1 >= 10
 | 
	
		
			
				|  |  | +    ? nowDate.getMonth() + 1
 | 
	
		
			
				|  |  | +    : "0" + (nowDate.getMonth() + 1));
 | 
	
		
			
				|  |  |  export default {
 | 
	
		
			
				|  |  | -  name: 'operationalList',
 | 
	
		
			
				|  |  | +  name: "operationalList",
 | 
	
		
			
				|  |  |    components: { pagination },
 | 
	
		
			
				|  |  | -  data () {
 | 
	
		
			
				|  |  | +  data() {
 | 
	
		
			
				|  |  |      return {
 | 
	
		
			
				|  |  |        searchForm: {
 | 
	
		
			
				|  |  |          organId: null,
 | 
	
		
			
				|  |  |          monthStr: nowMonth,
 | 
	
		
			
				|  |  | -        userId: null
 | 
	
		
			
				|  |  | +        userId: null,
 | 
	
		
			
				|  |  |        },
 | 
	
		
			
				|  |  |        tableList: [{}],
 | 
	
		
			
				|  |  |        organList: [],
 | 
	
	
		
			
				|  | @@ -137,60 +156,51 @@ export default {
 | 
	
		
			
				|  |  |          limit: 10, // 限制显示条数
 | 
	
		
			
				|  |  |          page: 1, // 当前页
 | 
	
		
			
				|  |  |          total: 0, // 总条数
 | 
	
		
			
				|  |  | -        page_size: [10, 20, 40, 50] // 选择限制显示条数
 | 
	
		
			
				|  |  | -      }
 | 
	
		
			
				|  |  | -    }
 | 
	
		
			
				|  |  | +        page_size: [10, 20, 40, 50], // 选择限制显示条数
 | 
	
		
			
				|  |  | +      },
 | 
	
		
			
				|  |  | +    };
 | 
	
		
			
				|  |  |    },
 | 
	
		
			
				|  |  | -  mounted () {
 | 
	
		
			
				|  |  | +  mounted() {
 | 
	
		
			
				|  |  |      // 获取分部
 | 
	
		
			
				|  |  | -    getEmployeeOrgan().then(res => {
 | 
	
		
			
				|  |  | -      if (res.code == 200) {
 | 
	
		
			
				|  |  | -        this.organList = res.data;
 | 
	
		
			
				|  |  | -      }
 | 
	
		
			
				|  |  | -    })
 | 
	
		
			
				|  |  | +    // getEmployeeOrgan().then(res => {
 | 
	
		
			
				|  |  | +    //   if (res.code == 200) {
 | 
	
		
			
				|  |  | +    //     this.organList = res.data;
 | 
	
		
			
				|  |  | +    //   }
 | 
	
		
			
				|  |  | +    // })
 | 
	
		
			
				|  |  | +    this.$store.dispatch("setBranchs");
 | 
	
		
			
				|  |  |      // 获取老师列表
 | 
	
		
			
				|  |  | -    getTeacher({ organId: this.organId }).then(res => {
 | 
	
		
			
				|  |  | -      if (res.code == 200) {
 | 
	
		
			
				|  |  | -        this.teacherList = res.data;
 | 
	
		
			
				|  |  | -      }
 | 
	
		
			
				|  |  | -    })
 | 
	
		
			
				|  |  | +    // getTeacher({ organId: this.organId }).then(res => {
 | 
	
		
			
				|  |  | +    //   if (res.code == 200) {
 | 
	
		
			
				|  |  | +    //     this.teacherList = res.data;
 | 
	
		
			
				|  |  | +    //   }
 | 
	
		
			
				|  |  | +    // })
 | 
	
		
			
				|  |  |      this.getList();
 | 
	
		
			
				|  |  |    },
 | 
	
		
			
				|  |  |    methods: {
 | 
	
		
			
				|  |  | -    search () {
 | 
	
		
			
				|  |  | -      this.pageInfo.page = 1
 | 
	
		
			
				|  |  | -      this.getList()
 | 
	
		
			
				|  |  | +    search() {
 | 
	
		
			
				|  |  | +      this.pageInfo.page = 1;
 | 
	
		
			
				|  |  | +      this.getList();
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  | -    onClear (type) {
 | 
	
		
			
				|  |  | -      if (type == 'organId') {
 | 
	
		
			
				|  |  | -        this.searchForm.organId = null
 | 
	
		
			
				|  |  | -      } else if (type == 'monthStr') {
 | 
	
		
			
				|  |  | -        this.searchForm.monthStr = null
 | 
	
		
			
				|  |  | -      } else if (type == 'userId') {
 | 
	
		
			
				|  |  | -        this.searchForm.userId = null
 | 
	
		
			
				|  |  | -      }
 | 
	
		
			
				|  |  | -    },
 | 
	
		
			
				|  |  | -    onReSet () {
 | 
	
		
			
				|  |  | +    onReSet() {
 | 
	
		
			
				|  |  |        this.searchForm = {
 | 
	
		
			
				|  |  |          organId: null,
 | 
	
		
			
				|  |  |          monthStr: null,
 | 
	
		
			
				|  |  | -        userId: null
 | 
	
		
			
				|  |  | -      }
 | 
	
		
			
				|  |  | -      this.getList()
 | 
	
		
			
				|  |  | +        userId: null,
 | 
	
		
			
				|  |  | +      };
 | 
	
		
			
				|  |  | +      this.getList();
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  | -    getList () {
 | 
	
		
			
				|  |  | -      let params = this.searchForm
 | 
	
		
			
				|  |  | -      teacherCourseStatistics(params).then(res => {
 | 
	
		
			
				|  |  | -        let result = res.data
 | 
	
		
			
				|  |  | +    getList() {
 | 
	
		
			
				|  |  | +      let params = this.searchForm;
 | 
	
		
			
				|  |  | +      teacherCourseStatistics(params).then((res) => {
 | 
	
		
			
				|  |  | +        let result = res.data;
 | 
	
		
			
				|  |  |          if (res.code == 200) {
 | 
	
		
			
				|  |  | -          this.tableList = result.rows
 | 
	
		
			
				|  |  | -          this.pageInfo.total = result.total
 | 
	
		
			
				|  |  | +          this.tableList = result.rows;
 | 
	
		
			
				|  |  | +          this.pageInfo.total = result.total;
 | 
	
		
			
				|  |  |          }
 | 
	
		
			
				|  |  | -      })
 | 
	
		
			
				|  |  | +      });
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  | -
 | 
	
		
			
				|  |  | -  }
 | 
	
		
			
				|  |  | -}
 | 
	
		
			
				|  |  | +  },
 | 
	
		
			
				|  |  | +};
 | 
	
		
			
				|  |  |  </script>
 | 
	
		
			
				|  |  |  <style lang="scss" scoped>
 | 
	
		
			
				|  |  | -</style>
 | 
	
		
			
				|  |  | +</style>
 |