xuqiang 4 lat temu
rodzic
commit
29f5c3fe82

+ 183 - 0
src/main/vue/src/components/OrganLog.vue

@@ -0,0 +1,183 @@
+<template>
+    <el-dialog
+        v-loading="saving"
+        @close="closeDialog"
+        title="分配评委"
+        center
+        :visible.sync="dialogVisible"
+        width="800px"
+    >
+        <div class="edit-view">
+            <el-form
+                :model="formData"
+                :rules="rules"
+                ref="form"
+                label-width="110px"
+                label-position="right"
+                size="small"
+                style="max-width: 680px;"
+            >
+                <el-form-item prop="expertMemberUserId" label="分配评委">
+                    <div class="subform">
+                        <div style="margin-bottom: 20px">
+                            <el-select
+                                v-model="employeeId"
+                                style="width: 82.5%; margin-right: 10px;"
+                                multiple
+                                filterable
+                                clearable
+                                placeholder="请选择评委"
+                            >
+                                <el-option
+                                    v-for="item in expert"
+                                    :key="item.value"
+                                    :value="item.value"
+                                    :label="item.label"
+                                >
+                                    <!-- <span style="float: left">{{ item.nickname }}</span>
+                                <span style="float: right; color: #8492a6; font-size: 13px">{{ item.phone }}</span> -->
+                                </el-option>
+                            </el-select>
+                            <el-button @click="chooseEmp">添加</el-button>
+                        </div>
+                        <el-table :data="emps">
+                            <el-table-column prop="nickname" label="用户名"></el-table-column>
+                            <el-table-column prop="phone" label="手机号"></el-table-column>
+                            <el-table-column prop="artType" label="专业"></el-table-column>
+                            <el-table-column label="操作" v-if="formData.status == 'ASSIGN_EXPERT'">
+                                <template slot-scope="{ row }">
+                                    <el-button @click="remove(row)" type="danger" size="mini" plain>移除</el-button>
+                                </template>
+                            </el-table-column>
+                        </el-table>
+                    </div>
+                </el-form-item>
+            </el-form>
+            <el-form-item class="btn">
+                <el-button @click="onSave" :loading="saving" type="primary" v-if="formData.status == 'ASSIGN_EXPERT'"
+                    >保存</el-button
+                >
+                <el-button
+                    type="danger"
+                    v-if="formData.status == 'REVIEW_PENDING'"
+                    @click="saveDismiss"
+                    :loading="loading"
+                >
+                    退回
+                </el-button>
+            </el-form-item>
+            <!-- <div class="btn">
+                <el-button @click="$router.go(-1)">返回</el-button>
+            </div> -->
+        </div>
+    </el-dialog>
+</template>
+<script>
+export default {
+    props: ['dialogVisible'],
+    data() {
+        return {
+            saving: false,
+            formData: {},
+            url: '/user/all1',
+            rules: {},
+            users: [],
+            emps: [],
+            employeeId: '',
+            employeeIds: [],
+            dateRange: [],
+            audits: [],
+            grading: [],
+            artTypes: [],
+            readonly: true,
+            collaborates: [],
+            expert: [],
+            loading: false
+        };
+    },
+    created() {},
+    methods: {
+        closeDialog() {
+            this.$emit('close');
+        },
+        init(row) {
+            this.$http
+                .post('user/all1', { body: 'json' })
+                .then(res => {
+                    console.log(res);
+                    // this.artTypes = this.delChild(res);
+                })
+                .catch(e => {
+                    console.log(e);
+                });
+            let keys = [...this.columnKeys].slice(0, 3).map(item => {
+                return row[item];
+            });
+            let info = this.getInfo(this.showTable, keys);
+            let aid = info.list.map(item => {
+                return item.id;
+            });
+            this.$router.push({
+                path: '/arrangeAssignExpert',
+                query: {
+                    aid: aid.join(',')
+                }
+            });
+        }
+    }
+};
+</script>
+<style lang="less" scoped>
+.edit-view {
+    // padding-left: 20%;
+    .add-con {
+        // background-color: #f7f7f7;
+        width: 100%;
+        // margin-bottom: 10px;
+    }
+}
+.btn {
+    position: fixed;
+    bottom: 0;
+    width: 100%;
+    background: #ffffff;
+    height: 50px;
+    line-height: 50px;
+    z-index: 999;
+    margin-left: -40px;
+    padding-left: 20px;
+}
+.subform {
+    padding: 16px 16px 16px 16px;
+    background: #f7f7f7;
+    border-radius: 5px;
+    border: 1px solid #eee;
+    margin-bottom: 10px;
+}
+.parameters1 {
+    display: flex;
+    align-items: center;
+    // margin-top: 23px;
+}
+.el-divider__text {
+    left: 0;
+    font-size: 18px;
+}
+.el-divider--horizontal {
+    margin: 32px 0;
+}
+/deep/ .el-input.is-disabled .el-input__inner {
+    background-color: #ffffff;
+    color: #606266;
+}
+/deep/ .el-range-editor.is-disabled input {
+    background-color: #ffffff;
+    color: #606266;
+}
+/deep/ .el-range-editor.is-disabled {
+    background-color: #ffffff;
+}
+/deep/ .el-range-editor.is-disabled .el-range-separator {
+    color: #606266;
+}
+</style>

+ 31 - 16
src/main/vue/src/views/performance/ArrangeJudgeList.vue

@@ -92,13 +92,13 @@
         >
             <el-table-column v-if="multipleMode" align="center" type="selection" width="50"> </el-table-column>
             <!-- <el-table-column prop="id" label="ID" width="100"> </el-table-column> -->
-            <el-table-column prop="date" label="活动日期"> </el-table-column>
-            <el-table-column prop="morning" label="活动时间">
+            <el-table-column prop="date" label="活动日期" v-if="onlines"> </el-table-column>
+            <el-table-column prop="morning" label="活动时间" v-if="onlines">
                 <template slot-scope="{ row }">
                     {{ row.morning ? '上午' : '下午' }}
                 </template>
             </el-table-column>
-            <el-table-column prop="address" label="活动地点"> </el-table-column>
+            <el-table-column prop="address" label="活动地点" v-if="onlines"> </el-table-column>
             <el-table-column label="参赛专业">
                 <template slot-scope="{ row }">
                     {{ row.specialtyName ? row.specialtyName.join(',') : '' }}
@@ -171,18 +171,22 @@
                 </el-table-column>
             </el-table>
         </el-dialog>
+        <organ-log :dialogVisible="isShow" @close="isShow = false" ref="public"></organ-log>
     </div>
 </template>
 <script>
 import { mapState } from 'vuex';
 import pageableTable from '@/mixins/pageableTable';
+import OrganLog from '../../components/OrganLog';
 import delChild from '@/mixins/delChild';
 
 export default {
     name: 'ArrangeJudgeList',
     mixins: [pageableTable, delChild],
+    components: { OrganLog },
     data() {
         return {
+            isShow: false,
             multipleMode: false,
             showMore: false,
             search: '',
@@ -190,6 +194,7 @@ export default {
             downloading: false,
             form: {},
             performances: [],
+            onlines: '',
             addresses: [],
             dateRange: '',
             rules: {
@@ -223,6 +228,13 @@ export default {
                 { body: 'json' }
             )
             .then(res => {
+                console.log(res);
+                this.onlines = res.content[0].online;
+                // if (res.content.length > 0) {
+                //     res.content.map(item => {
+                //         return item.online;
+                //     });
+                // }
                 if (res.content.length > 0) {
                     res.content.forEach(item => {
                         this.performances.push({
@@ -238,6 +250,7 @@ export default {
                             { body: 'json' }
                         )
                         .then(res => {
+                            console.log(res);
                             if (res.content.length > 0) {
                                 res.content.forEach(item => {
                                     this.addressList.push({
@@ -360,19 +373,21 @@ export default {
             });
         },
         assignExpert(row) {
-            let keys = [...this.columnKeys].slice(0, 3).map(item => {
-                return row[item];
-            });
-            let info = this.getInfo(this.showTable, keys);
-            let aid = info.list.map(item => {
-                return item.id;
-            });
-            this.$router.push({
-                path: '/arrangeAssignExpert',
-                query: {
-                    aid: aid.join(',')
-                }
-            });
+            this.isShow = true;
+            this.$refs.public.init(row);
+            // let keys = [...this.columnKeys].slice(0, 3).map(item => {
+            //     return row[item];
+            // });
+            // let info = this.getInfo(this.showTable, keys);
+            // let aid = info.list.map(item => {
+            //     return item.id;
+            // });
+            // this.$router.push({
+            //     path: '/arrangeAssignExpert',
+            //     query: {
+            //         aid: aid.join(',')
+            //     }
+            // });
         },
         programme(row) {
             this.$router.push({