Browse Source

Merge branch 'Inspection' into online

lex-xin 4 years ago
parent
commit
fb01df6249

+ 6 - 4
src/api/teamServer.js

@@ -1,12 +1,14 @@
 import request from '@/utils/request'
+import request2 from '@/utils/request2'
 // import qs from 'qs'
 let api = '/api-web'
 // 获取分部
 export function getTeamList (data) {
-  return request({
+  return request2({
     url: api + '/musicGroup/queryPage',
-    method: 'get',
-    params: data
+    method: 'post',
+    data: data,
+    requestType: 'form'
   })
 }
 
@@ -17,4 +19,4 @@ export function getPayType (data) {
     method: 'get',
     params: data
   })
-}
+}

+ 33 - 1
src/views/stuRecodeManager/index.vue

@@ -275,7 +275,30 @@
               </div>
             </template>
           </el-table-column>
+          <el-table-column
+            align="center"
+            fixed="right"
+            label="操作"
+            v-if="permission('visit/add')"
+          >
+            <template slot-scope="scope">
+              <el-button
+                type="text"
+                v-if="permission('visit/add')"
+                @click="addVisit(scope.row)"
+              >新增回访</el-button>
+            </template>
+          </el-table-column>
         </el-table>
+        <el-dialog title="新增回访" width="500px" :visible.sync="visitVisible">
+          <visit
+            v-if="visitVisible && detail"
+            :detail="detail"
+            :username="detail.username"
+            @close="visitVisible = false"
+            @submited="getList"
+          />
+        </el-dialog>
         <pagination
           sync
           :total.sync="rules.total"
@@ -296,15 +319,19 @@ import pagination from "@/components/Pagination/index";
 import load from "@/utils/loading";
 import { getTimes } from "@/utils";
 import qs from 'qs';
+import { permission } from '@/utils/directivePage'
 import { findStudentAttendance } from "@/api/buildTeam";
 import { Export } from '@/utils/downLoadFile'
 import cleanDeep from 'clean-deep'
 // import { queryTeacherAttendances } from "@/api/recodeManager";
 import { courseType, courseListType, stuAttendance } from "@/utils/searchArray";
+import visit from '@/views/withdrawal-application/modals/visit'
 export default {
-  components: { pagination },
+  components: { pagination, visit },
   data() {
     return {
+      visitVisible: false,
+      detail: null,
       searchForm: {
         studentID: "",
         groupType: "",
@@ -346,10 +373,15 @@ export default {
   },
 
   methods: {
+    permission,
     async init() {
       await this.$store.dispatch("setBranchs");
       this.getList();
     },
+    addVisit(row) {
+      this.visitVisible = true
+      this.detail = row
+    },
     // 导出
     async onExport () {
       const { dates, ...rest } = this.searchForm;

+ 2 - 2
src/views/withdrawal-application/modals/visit.vue

@@ -65,7 +65,7 @@ import cleanDeep from 'clean-deep'
 import { visitChiose } from "@/utils/searchArray";
 import { addVisit } from "@/views/returnVisitManager/api"
 export default {
-  props: ['detail'],
+  props: ['detail', 'username'],
   data() {
     return {
       visitChiose,
@@ -90,7 +90,7 @@ export default {
   },
   computed: {
     userName() {
-      return this.detail.user?.username
+      return this.username || this.detail.user?.username
     }
   },
   methods: {

+ 2 - 2
vue.config.js

@@ -21,8 +21,8 @@ const name = defaultSettings.title || '管乐迷后台管理系统' // page titl
 // let target = 'http://192.168.3.139:8000' // 箭河
 // let target = 'http://192.168.3.38:8000' //邹璇
 // let target = 'http://192.168.3.57:8000' //勇哥
-let target = 'http://dev.dayaedu.com' // 测试服
-// let target = 'http://192.168.3.196:80' // 乔
+// let target = 'http://dev.dayaedu.com' // 测试服
+let target = 'http://192.168.3.134' // 乔
 // All configuration item explanations can be find in https://cli.vuejs.org/config/
 module.exports = {
   /**