Commit e6276ef236f80989bfc764bd9bf7d95978d17dda
1 parent
a63af57c
超哥牛批
Showing
5 changed files
with
614 additions
and
390 deletions
src/App.vue
src/common/config.js
0 → 100644
src/common/mixins.js
| 1 | import { | 1 | import { |
| 2 | getToken | 2 | getToken |
| 3 | } from '@/utils/auth' | 3 | } from '@/utils/auth' |
| 4 | +import { BASE_URL } from '@/common/config' | ||
| 4 | export default { | 5 | export default { |
| 5 | data() { | 6 | data() { |
| 6 | return { | 7 | return { |
| 7 | - Authorization: '' | 8 | + Authorization: '', |
| 9 | + BASE_URL: BASE_URL | ||
| 8 | }; | 10 | }; |
| 9 | }, | 11 | }, |
| 10 | created() { | 12 | created() { |
src/views/user/picuserimport.vue
| @@ -36,17 +36,18 @@ | @@ -36,17 +36,18 @@ | ||
| 36 | > | 36 | > |
| 37 | <el-upload | 37 | <el-upload |
| 38 | class="upload-demo" | 38 | class="upload-demo" |
| 39 | + ref="uploader" | ||
| 39 | action="/api//UserInfo/ResumeIdentification" | 40 | action="/api//UserInfo/ResumeIdentification" |
| 40 | multiple | 41 | multiple |
| 41 | :headers="{ | 42 | :headers="{ |
| 42 | Authorization: Authorization, | 43 | Authorization: Authorization, |
| 43 | }" | 44 | }" |
| 44 | - :limit="1" | 45 | + :limit="100" |
| 45 | :show-file-list="false" | 46 | :show-file-list="false" |
| 46 | :on-exceed="handleExceed" | 47 | :on-exceed="handleExceed" |
| 47 | :on-success="handleSuccess" | 48 | :on-success="handleSuccess" |
| 48 | > | 49 | > |
| 49 | - <el-button size="small" type="primary">上传待解析图片</el-button> | 50 | + <el-button size="small" type="primary">上传简历</el-button> |
| 50 | </el-upload> | 51 | </el-upload> |
| 51 | </div> | 52 | </div> |
| 52 | </div> | 53 | </div> |
| @@ -172,6 +173,7 @@ export default { | @@ -172,6 +173,7 @@ export default { | ||
| 172 | methods: { | 173 | methods: { |
| 173 | handleExceed() {}, | 174 | handleExceed() {}, |
| 174 | handleSuccess(res) { | 175 | handleSuccess(res) { |
| 176 | + this.$refs.uploader.clearFiles(); | ||
| 175 | this.search(); | 177 | this.search(); |
| 176 | }, | 178 | }, |
| 177 | search(){ | 179 | search(){ |
src/views/user/userlist.vue
| 1 | <template> | 1 | <template> |
| 2 | <div class="app-container"> | 2 | <div class="app-container"> |
| 3 | <div class="seetingsDiv" style=""> | 3 | <div class="seetingsDiv" style=""> |
| 4 | - <div class="flex" style="width:75%"> | ||
| 5 | - | 4 | + <div class="flex" style="width: 75%"> |
| 6 | <el-form :inline="true" class="demo-form-inline"> | 5 | <el-form :inline="true" class="demo-form-inline"> |
| 7 | <el-form-item label="关键字"> | 6 | <el-form-item label="关键字"> |
| 8 | - <el-input placeholder="输入关键字搜索" v-model="query.keyword"></el-input> | 7 | + <el-input |
| 8 | + placeholder="输入关键字搜索" | ||
| 9 | + v-model="query.keyword" | ||
| 10 | + ></el-input> | ||
| 9 | </el-form-item> | 11 | </el-form-item> |
| 10 | <el-form-item label="最高学历"> | 12 | <el-form-item label="最高学历"> |
| 11 | <el-select v-model="query.xueli" placeholder="最高学历"> | 13 | <el-select v-model="query.xueli" placeholder="最高学历"> |
| @@ -21,53 +23,111 @@ | @@ -21,53 +23,111 @@ | ||
| 21 | </el-select> | 23 | </el-select> |
| 22 | </el-form-item> | 24 | </el-form-item> |
| 23 | 25 | ||
| 24 | - | ||
| 25 | <el-form-item> | 26 | <el-form-item> |
| 26 | <el-button type="success" @click="search">搜索</el-button> | 27 | <el-button type="success" @click="search">搜索</el-button> |
| 27 | <el-button type="success" @click="resetSearch">重置</el-button> | 28 | <el-button type="success" @click="resetSearch">重置</el-button> |
| 28 | - <el-button v-if="selectedList.length" type="primary" @click="handleInviteInterview">邀请面试</el-button> | 29 | + <el-button |
| 30 | + v-if="selectedList.length" | ||
| 31 | + type="primary" | ||
| 32 | + @click="handleInviteInterview" | ||
| 33 | + >邀请面试</el-button | ||
| 34 | + > | ||
| 29 | </el-form-item> | 35 | </el-form-item> |
| 30 | </el-form> | 36 | </el-form> |
| 31 | - | ||
| 32 | - | ||
| 33 | - | ||
| 34 | </div> | 37 | </div> |
| 35 | 38 | ||
| 36 | - <el-upload class="upload-demo" action="/api/Account/importUsers?UserClassId=0" multiple :limit="1" | ||
| 37 | - :show-file-list="false" :on-exceed="handleExceed" :on-success="handleSuccess" :file-list="fileList"> | ||
| 38 | - <el-button size="small" type="primary">导入用户</el-button> | ||
| 39 | - </el-upload> | 39 | + <div class="flex aligin-center"> |
| 40 | + <el-link :href="BASE_URL+'/temp/用户导入模板.xlsx'" target="_blank" type="primary" | ||
| 41 | + >下载模板</el-link | ||
| 42 | + > | ||
| 43 | + <el-upload | ||
| 44 | + class="upload-demo" | ||
| 45 | + action="/api/Account/importUsers?UserClassId=0" | ||
| 46 | + multiple | ||
| 47 | + :limit="1" | ||
| 48 | + :show-file-list="false" | ||
| 49 | + :on-exceed="handleExceed" | ||
| 50 | + :on-success="handleSuccess" | ||
| 51 | + :file-list="fileList" | ||
| 52 | + > | ||
| 53 | + <el-button size="small" type="primary">导入用户</el-button> | ||
| 54 | + </el-upload> | ||
| 55 | + </div> | ||
| 40 | </div> | 56 | </div> |
| 41 | - <el-container style=" border: 1px solid #eee;"> | ||
| 42 | - <el-aside width="255px" | ||
| 43 | - style="width: 255px;background-color: #fff;padding: 10px;border-right: 1px solid #dcdfe6;"> | ||
| 44 | - <div style="float:left"> | ||
| 45 | - 所属分类 | ||
| 46 | - </div> | ||
| 47 | - <div style="text-align:right;"> | ||
| 48 | - <el-button size="mini" type="primary" icon="el-icon-plus" circle @click="addcat"></el-button> | ||
| 49 | - <el-button size="mini" type="warning" icon="el-icon-edit" circle @click="editcat"></el-button> | ||
| 50 | - <el-button size="mini" type="danger" icon="el-icon-delete" @click="delcat" circle></el-button> | 57 | + <el-container style="border: 1px solid #eee"> |
| 58 | + <el-aside | ||
| 59 | + width="255px" | ||
| 60 | + style=" | ||
| 61 | + width: 255px; | ||
| 62 | + background-color: #fff; | ||
| 63 | + padding: 10px; | ||
| 64 | + border-right: 1px solid #dcdfe6; | ||
| 65 | + " | ||
| 66 | + > | ||
| 67 | + <div style="float: left">所属分类</div> | ||
| 68 | + <div style="text-align: right"> | ||
| 69 | + <el-button | ||
| 70 | + size="mini" | ||
| 71 | + type="primary" | ||
| 72 | + icon="el-icon-plus" | ||
| 73 | + circle | ||
| 74 | + @click="addcat" | ||
| 75 | + ></el-button> | ||
| 76 | + <el-button | ||
| 77 | + size="mini" | ||
| 78 | + type="warning" | ||
| 79 | + icon="el-icon-edit" | ||
| 80 | + circle | ||
| 81 | + @click="editcat" | ||
| 82 | + ></el-button> | ||
| 83 | + <el-button | ||
| 84 | + size="mini" | ||
| 85 | + type="danger" | ||
| 86 | + icon="el-icon-delete" | ||
| 87 | + @click="delcat" | ||
| 88 | + circle | ||
| 89 | + ></el-button> | ||
| 51 | </div> | 90 | </div> |
| 52 | - <el-input size="small " placeholder="分类筛选" v-model="filterText" style="margin-bottom:10px;margin-top:10px;"> | 91 | + <el-input |
| 92 | + size="small " | ||
| 93 | + placeholder="分类筛选" | ||
| 94 | + v-model="filterText" | ||
| 95 | + style="margin-bottom: 10px; margin-top: 10px" | ||
| 96 | + > | ||
| 53 | </el-input> | 97 | </el-input> |
| 54 | - <el-tree :data="data" :props="props" ref="tree" :filter-node-method="filterNode" @node-click="handleNodeClick"> | 98 | + <el-tree |
| 99 | + :data="data" | ||
| 100 | + :props="props" | ||
| 101 | + ref="tree" | ||
| 102 | + :filter-node-method="filterNode" | ||
| 103 | + @node-click="handleNodeClick" | ||
| 104 | + > | ||
| 55 | </el-tree> | 105 | </el-tree> |
| 56 | - | ||
| 57 | </el-aside> | 106 | </el-aside> |
| 58 | 107 | ||
| 59 | <el-main> | 108 | <el-main> |
| 60 | - | ||
| 61 | - | ||
| 62 | <div class="filter-container"> | 109 | <div class="filter-container"> |
| 63 | - <el-table ref="userList" :data="userList" id="QuestionTable" border style=" | ||
| 64 | - width: 100%; | ||
| 65 | - border-radius: 5px; | ||
| 66 | - box-shadow: 0 0 10px #efefef; | ||
| 67 | - margin-top: 10px; | ||
| 68 | - " @selection-change="handleSelectionChange" :stripe="true"> | 110 | + <el-table |
| 111 | + ref="userList" | ||
| 112 | + :data="userList" | ||
| 113 | + id="QuestionTable" | ||
| 114 | + border | ||
| 115 | + style=" | ||
| 116 | + width: 100%; | ||
| 117 | + border-radius: 5px; | ||
| 118 | + box-shadow: 0 0 10px #efefef; | ||
| 119 | + margin-top: 10px; | ||
| 120 | + " | ||
| 121 | + @selection-change="handleSelectionChange" | ||
| 122 | + :stripe="true" | ||
| 123 | + > | ||
| 69 | <el-table-column type="selection" width="55"> </el-table-column> | 124 | <el-table-column type="selection" width="55"> </el-table-column> |
| 70 | - <el-table-column type="index" prop="date" width="50" align="center"></el-table-column> | 125 | + <el-table-column |
| 126 | + type="index" | ||
| 127 | + prop="date" | ||
| 128 | + width="50" | ||
| 129 | + align="center" | ||
| 130 | + ></el-table-column> | ||
| 71 | <el-table-column prop="date" label="姓名"> | 131 | <el-table-column prop="date" label="姓名"> |
| 72 | <template slot-scope="scope"> | 132 | <template slot-scope="scope"> |
| 73 | <span>{{ scope.row.fullName }}</span> | 133 | <span>{{ scope.row.fullName }}</span> |
| @@ -75,36 +135,51 @@ | @@ -75,36 +135,51 @@ | ||
| 75 | </el-table-column> | 135 | </el-table-column> |
| 76 | <el-table-column prop="date" label="电话号码"> | 136 | <el-table-column prop="date" label="电话号码"> |
| 77 | <template slot-scope="scope"> | 137 | <template slot-scope="scope"> |
| 78 | - <el-tooltip class="item" effect="dark" :content="scope.row.phone" placement="top-start"> | 138 | + <el-tooltip |
| 139 | + class="item" | ||
| 140 | + effect="dark" | ||
| 141 | + :content="scope.row.phone" | ||
| 142 | + placement="top-start" | ||
| 143 | + > | ||
| 79 | <span>{{ scope.row.phone1 }}</span> | 144 | <span>{{ scope.row.phone1 }}</span> |
| 80 | </el-tooltip> | 145 | </el-tooltip> |
| 81 | </template> | 146 | </template> |
| 82 | </el-table-column> | 147 | </el-table-column> |
| 83 | 148 | ||
| 84 | <el-table-column prop="date" label="近期测试"> | 149 | <el-table-column prop="date" label="近期测试"> |
| 85 | - <template slot-scope="{row}"> | ||
| 86 | - <el-button v-if="row.TestPaperTitle || 1==1" type="text" icon="el-icon-star-off" | ||
| 87 | - @click="handleTestHitory(row)"></el-button> | ||
| 88 | - <span>{{row.TestPaperTitle || '无'}}</span> | ||
| 89 | - | 150 | + <template slot-scope="{ row }"> |
| 151 | + <el-button | ||
| 152 | + v-if="row.TestPaperTitle || 1 == 1" | ||
| 153 | + type="text" | ||
| 154 | + icon="el-icon-star-off" | ||
| 155 | + @click="handleTestHitory(row)" | ||
| 156 | + ></el-button> | ||
| 157 | + <span>{{ row.TestPaperTitle || "无" }}</span> | ||
| 90 | </template> | 158 | </template> |
| 91 | </el-table-column> | 159 | </el-table-column> |
| 92 | <el-table-column prop="date" label="电话号码"> | 160 | <el-table-column prop="date" label="电话号码"> |
| 93 | <template slot-scope="scope"> | 161 | <template slot-scope="scope"> |
| 94 | - <el-tooltip class="item" effect="dark" :content="scope.row.phone" placement="top-start"> | 162 | + <el-tooltip |
| 163 | + class="item" | ||
| 164 | + effect="dark" | ||
| 165 | + :content="scope.row.phone" | ||
| 166 | + placement="top-start" | ||
| 167 | + > | ||
| 95 | <span>{{ scope.row.phone1 }}</span> | 168 | <span>{{ scope.row.phone1 }}</span> |
| 96 | </el-tooltip> | 169 | </el-tooltip> |
| 97 | </template> | 170 | </template> |
| 98 | </el-table-column> | 171 | </el-table-column> |
| 99 | 172 | ||
| 100 | - | ||
| 101 | - <el-table-column prop="date" label="性别" sortable> </el-table-column> | ||
| 102 | - <el-table-column prop="date" label="民族" sortable> </el-table-column> | ||
| 103 | - <el-table-column prop="date" label="专业" sortable> </el-table-column> | ||
| 104 | - <el-table-column prop="date" label="毕业院校" sortable> </el-table-column> | ||
| 105 | - <el-table-column prop="date" label="最高学历" sortable> </el-table-column> | ||
| 106 | - | ||
| 107 | - | 173 | + <el-table-column prop="date" label="性别" sortable> |
| 174 | + </el-table-column> | ||
| 175 | + <el-table-column prop="date" label="民族" sortable> | ||
| 176 | + </el-table-column> | ||
| 177 | + <el-table-column prop="date" label="专业" sortable> | ||
| 178 | + </el-table-column> | ||
| 179 | + <el-table-column prop="date" label="毕业院校" sortable> | ||
| 180 | + </el-table-column> | ||
| 181 | + <el-table-column prop="date" label="最高学历" sortable> | ||
| 182 | + </el-table-column> | ||
| 108 | 183 | ||
| 109 | <el-table-column prop="addTime" label="录入时间" sortable> | 184 | <el-table-column prop="addTime" label="录入时间" sortable> |
| 110 | <template slot-scope="scope"> | 185 | <template slot-scope="scope"> |
| @@ -114,19 +189,39 @@ | @@ -114,19 +189,39 @@ | ||
| 114 | 189 | ||
| 115 | <el-table-column prop="date" label="操作" width="180"> | 190 | <el-table-column prop="date" label="操作" width="180"> |
| 116 | <template slot-scope="scope"> | 191 | <template slot-scope="scope"> |
| 117 | - <el-button type="text" icon="el-icon-edit" @click="handleEdit(scope.row)" circle>编辑</el-button> | ||
| 118 | - <el-button type="text" icon="el-icon-delete" circle @click="handleDelete(scope.row,scope.$index)">删除</el-button> | 192 | + <el-button |
| 193 | + type="text" | ||
| 194 | + icon="el-icon-edit" | ||
| 195 | + @click="handleEdit(scope.row)" | ||
| 196 | + circle | ||
| 197 | + >编辑</el-button | ||
| 198 | + > | ||
| 199 | + <el-button | ||
| 200 | + type="text" | ||
| 201 | + icon="el-icon-delete" | ||
| 202 | + circle | ||
| 203 | + @click="handleDelete(scope.row, scope.$index)" | ||
| 204 | + >删除</el-button | ||
| 205 | + > | ||
| 119 | </template> | 206 | </template> |
| 120 | </el-table-column> | 207 | </el-table-column> |
| 121 | </el-table> | 208 | </el-table> |
| 122 | - <el-pagination background @current-change="currentchange" | ||
| 123 | - style="position: static; bottom: 3px; text-align: center; margin-top: 5px" :page-size="this.query.PageSize" | ||
| 124 | - layout="total,prev, pager, next" :total="Count"> | 209 | + <el-pagination |
| 210 | + background | ||
| 211 | + @current-change="currentchange" | ||
| 212 | + style=" | ||
| 213 | + position: static; | ||
| 214 | + bottom: 3px; | ||
| 215 | + text-align: center; | ||
| 216 | + margin-top: 5px; | ||
| 217 | + " | ||
| 218 | + :page-size="this.query.PageSize" | ||
| 219 | + layout="total,prev, pager, next" | ||
| 220 | + :total="Count" | ||
| 221 | + > | ||
| 125 | </el-pagination> | 222 | </el-pagination> |
| 126 | </div> | 223 | </div> |
| 127 | - | ||
| 128 | </el-main> | 224 | </el-main> |
| 129 | - | ||
| 130 | </el-container> | 225 | </el-container> |
| 131 | 226 | ||
| 132 | <el-dialog title="邀请面试-试卷选择" :visible.sync="dialogFormVisible"> | 227 | <el-dialog title="邀请面试-试卷选择" :visible.sync="dialogFormVisible"> |
| @@ -135,15 +230,24 @@ | @@ -135,15 +230,24 @@ | ||
| 135 | <el-input v-model="form.name" autocomplete="off"></el-input> | 230 | <el-input v-model="form.name" autocomplete="off"></el-input> |
| 136 | </el-form-item> --> | 231 | </el-form-item> --> |
| 137 | <el-form-item label="试卷"> | 232 | <el-form-item label="试卷"> |
| 138 | - <el-select v-model="form.TestPaperId" placeholder="请选择试卷" style="width:80%"> | ||
| 139 | - <el-option :value="item.id" v-for="item in testpaperlist">{{'['+item.id+'] '+(item.TestPaperTitle || | ||
| 140 | - '未命名')}}</el-option> | 233 | + <el-select |
| 234 | + v-model="form.TestPaperId" | ||
| 235 | + placeholder="请选择试卷" | ||
| 236 | + style="width: 80%" | ||
| 237 | + > | ||
| 238 | + <el-option :value="item.id" v-for="item in testpaperlist">{{ | ||
| 239 | + "[" + item.id + "] " + (item.TestPaperTitle || "未命名") | ||
| 240 | + }}</el-option> | ||
| 141 | </el-select> | 241 | </el-select> |
| 142 | </el-form-item> | 242 | </el-form-item> |
| 143 | <el-form-item label="允许测评次数"> | 243 | <el-form-item label="允许测评次数"> |
| 144 | - <el-input v-model="form.NumberOfAnswers" type="number" placeholder="请输入允许测评次数" style="width:30%"/> | 244 | + <el-input |
| 245 | + v-model="form.NumberOfAnswers" | ||
| 246 | + type="number" | ||
| 247 | + placeholder="请输入允许测评次数" | ||
| 248 | + style="width: 30%" | ||
| 249 | + /> | ||
| 145 | </el-form-item> | 250 | </el-form-item> |
| 146 | - | ||
| 147 | </el-form> | 251 | </el-form> |
| 148 | <div slot="footer" class="dialog-footer"> | 252 | <div slot="footer" class="dialog-footer"> |
| 149 | <el-button @click="dialogFormVisible = false">取 消</el-button> | 253 | <el-button @click="dialogFormVisible = false">取 消</el-button> |
| @@ -151,54 +255,89 @@ | @@ -151,54 +255,89 @@ | ||
| 151 | </div> | 255 | </div> |
| 152 | </el-dialog> | 256 | </el-dialog> |
| 153 | 257 | ||
| 154 | - <el-dialog title="测试历史记录" :visible.sync="dialogTableVisible" @close=" gridData =[]" height="800" width="80%"> | 258 | + <el-dialog |
| 259 | + title="测试历史记录" | ||
| 260 | + :visible.sync="dialogTableVisible" | ||
| 261 | + @close="gridData = []" | ||
| 262 | + height="800" | ||
| 263 | + width="80%" | ||
| 264 | + > | ||
| 155 | <el-table :data="gridData" height="400"> | 265 | <el-table :data="gridData" height="400"> |
| 156 | - <el-table-column property="TestPaperTitle" label="试卷" sortable></el-table-column> | ||
| 157 | - <el-table-column property="AnswerTime" label="测试时间" width="180" sortable> | 266 | + <el-table-column |
| 267 | + property="TestPaperTitle" | ||
| 268 | + label="试卷" | ||
| 269 | + sortable | ||
| 270 | + ></el-table-column> | ||
| 271 | + <el-table-column | ||
| 272 | + property="AnswerTime" | ||
| 273 | + label="测试时间" | ||
| 274 | + width="180" | ||
| 275 | + sortable | ||
| 276 | + > | ||
| 158 | <template slot-scope="scope"> | 277 | <template slot-scope="scope"> |
| 159 | <span>{{ scope.row.AnswerTime.replace("T", " ") }}</span> | 278 | <span>{{ scope.row.AnswerTime.replace("T", " ") }}</span> |
| 160 | </template> | 279 | </template> |
| 161 | - | ||
| 162 | </el-table-column> | 280 | </el-table-column> |
| 163 | - <el-table-column property="StartTime" label="开始时间" width="180" sortable> | 281 | + <el-table-column |
| 282 | + property="StartTime" | ||
| 283 | + label="开始时间" | ||
| 284 | + width="180" | ||
| 285 | + sortable | ||
| 286 | + > | ||
| 164 | <template slot-scope="scope"> | 287 | <template slot-scope="scope"> |
| 165 | <span>{{ scope.row.StartTime.replace("T", " ") }}</span> | 288 | <span>{{ scope.row.StartTime.replace("T", " ") }}</span> |
| 166 | </template> | 289 | </template> |
| 167 | </el-table-column> | 290 | </el-table-column> |
| 168 | - <el-table-column property="address" label="结束时间" width="180" sortable> | 291 | + <el-table-column |
| 292 | + property="address" | ||
| 293 | + label="结束时间" | ||
| 294 | + width="180" | ||
| 295 | + sortable | ||
| 296 | + > | ||
| 169 | <template slot-scope="scope"> | 297 | <template slot-scope="scope"> |
| 170 | <span>{{ scope.row.EndTime.replace("T", " ") }}</span> | 298 | <span>{{ scope.row.EndTime.replace("T", " ") }}</span> |
| 171 | </template> | 299 | </template> |
| 172 | </el-table-column> | 300 | </el-table-column> |
| 173 | - <el-table-column property="Achievement" label="成绩" sortable></el-table-column> | ||
| 174 | - <el-table-column label="操作"> | 301 | + <el-table-column |
| 302 | + property="Achievement" | ||
| 303 | + label="成绩" | ||
| 304 | + sortable | ||
| 305 | + ></el-table-column> | ||
| 306 | + <el-table-column label="操作"> | ||
| 175 | <template slot-scope="scope"> | 307 | <template slot-scope="scope"> |
| 176 | - <el-button type="success" @click="handleWatchLive(scope.row)">观看直播</el-button> | ||
| 177 | - <el-button type="primary" @click="handleAnswerDetail(scope.row)">答题详情</el-button> | 308 | + <el-button type="success" @click="handleWatchLive(scope.row)" |
| 309 | + >观看直播</el-button | ||
| 310 | + > | ||
| 311 | + <el-button type="primary" @click="handleAnswerDetail(scope.row)" | ||
| 312 | + >答题详情</el-button | ||
| 313 | + > | ||
| 178 | </template> | 314 | </template> |
| 179 | </el-table-column> | 315 | </el-table-column> |
| 180 | - | ||
| 181 | </el-table> | 316 | </el-table> |
| 182 | 317 | ||
| 183 | - <div style="text-align:right;margin-top:20px"> | ||
| 184 | - | 318 | + <div style="text-align: right; margin-top: 20px"> |
| 185 | <el-button type="primary" @click="dialogTableVisible = false"> | 319 | <el-button type="primary" @click="dialogTableVisible = false"> |
| 186 | 确定 | 320 | 确定 |
| 187 | </el-button> | 321 | </el-button> |
| 188 | </div> | 322 | </div> |
| 189 | </el-dialog> | 323 | </el-dialog> |
| 190 | 324 | ||
| 191 | - | ||
| 192 | - | ||
| 193 | - <el-dialog :visible.sync="dialogVisiblecat" :title="dialogTypecat === 'update' ? '修改' : '新增'" width="455px" > | ||
| 194 | - <el-form ref="dataForm" :model="temp" label-width="120px" label-position="right" > | ||
| 195 | - | 325 | + <el-dialog |
| 326 | + :visible.sync="dialogVisiblecat" | ||
| 327 | + :title="dialogTypecat === 'update' ? '修改' : '新增'" | ||
| 328 | + width="455px" | ||
| 329 | + > | ||
| 330 | + <el-form | ||
| 331 | + ref="dataForm" | ||
| 332 | + :model="temp" | ||
| 333 | + label-width="120px" | ||
| 334 | + label-position="right" | ||
| 335 | + > | ||
| 196 | <el-form-item label="分类名称"> | 336 | <el-form-item label="分类名称"> |
| 197 | <el-input v-model="temp.ClassTitle" placeholder="请输入名称" /> | 337 | <el-input v-model="temp.ClassTitle" placeholder="请输入名称" /> |
| 198 | </el-form-item> | 338 | </el-form-item> |
| 199 | - | ||
| 200 | </el-form> | 339 | </el-form> |
| 201 | - <div style="text-align:right;"> | 340 | + <div style="text-align: right"> |
| 202 | <el-button type="danger" @click="dialogVisiblecat = false"> | 341 | <el-button type="danger" @click="dialogVisiblecat = false"> |
| 203 | 取消 | 342 | 取消 |
| 204 | </el-button> | 343 | </el-button> |
| @@ -208,14 +347,31 @@ | @@ -208,14 +347,31 @@ | ||
| 208 | </div> | 347 | </div> |
| 209 | </el-dialog> | 348 | </el-dialog> |
| 210 | 349 | ||
| 211 | - | ||
| 212 | - <el-dialog title="人才用户信息" :visible.sync="dialogClassIVIsible" width="450"> | ||
| 213 | - <el-form ref="adminUserInfo" :model="adminUserInfo" label-width="90px" style="margin-left: 40px;"> | 350 | + <el-dialog |
| 351 | + title="人才用户信息" | ||
| 352 | + :visible.sync="dialogClassIVIsible" | ||
| 353 | + width="450" | ||
| 354 | + > | ||
| 355 | + <el-form | ||
| 356 | + ref="adminUserInfo" | ||
| 357 | + :model="adminUserInfo" | ||
| 358 | + label-width="90px" | ||
| 359 | + style="margin-left: 40px" | ||
| 360 | + > | ||
| 214 | <el-form-item label="名称" prop="fullName"> | 361 | <el-form-item label="名称" prop="fullName"> |
| 215 | - <el-input v-model="adminUserInfo.fullName " placeholder="请输入姓名" style="width: 40%;"></el-input> | 362 | + <el-input |
| 363 | + v-model="adminUserInfo.fullName" | ||
| 364 | + placeholder="请输入姓名" | ||
| 365 | + style="width: 40%" | ||
| 366 | + ></el-input> | ||
| 216 | </el-form-item> | 367 | </el-form-item> |
| 217 | <el-form-item label="电话号码"> | 368 | <el-form-item label="电话号码"> |
| 218 | - <el-input v-model="adminUserInfo.phone " placeholder="请输入电话号码" style="width: 40%;" maxlength="11"></el-input> | 369 | + <el-input |
| 370 | + v-model="adminUserInfo.phone" | ||
| 371 | + placeholder="请输入电话号码" | ||
| 372 | + style="width: 40%" | ||
| 373 | + maxlength="11" | ||
| 374 | + ></el-input> | ||
| 219 | </el-form-item> | 375 | </el-form-item> |
| 220 | <el-form-item label="最高学历"> | 376 | <el-form-item label="最高学历"> |
| 221 | <el-select v-model="adminUserInfo.xueli" placeholder="最高学历"> | 377 | <el-select v-model="adminUserInfo.xueli" placeholder="最高学历"> |
| @@ -226,7 +382,11 @@ | @@ -226,7 +382,11 @@ | ||
| 226 | 382 | ||
| 227 | <el-form-item label="民族"> | 383 | <el-form-item label="民族"> |
| 228 | <el-select v-model="adminUserInfo.minzu" placeholder="民族"> | 384 | <el-select v-model="adminUserInfo.minzu" placeholder="民族"> |
| 229 | - <el-option v-for="item in mzlist" :label="item" :value="item"></el-option> | 385 | + <el-option |
| 386 | + v-for="item in mzlist" | ||
| 387 | + :label="item" | ||
| 388 | + :value="item" | ||
| 389 | + ></el-option> | ||
| 230 | </el-select> | 390 | </el-select> |
| 231 | </el-form-item> | 391 | </el-form-item> |
| 232 | <el-form-item label="性别"> | 392 | <el-form-item label="性别"> |
| @@ -235,345 +395,398 @@ | @@ -235,345 +395,398 @@ | ||
| 235 | <el-option label="女" value="0"></el-option> | 395 | <el-option label="女" value="0"></el-option> |
| 236 | </el-select> | 396 | </el-select> |
| 237 | </el-form-item> | 397 | </el-form-item> |
| 238 | - <el-form-item label="专业" style="margin-top: 40px;" prop="username"> | ||
| 239 | - <el-input v-model="adminUserInfo.zhuanye" placeholder="请输入专业" style="width: 40%;"></el-input> | 398 | + <el-form-item label="专业" style="margin-top: 40px" prop="username"> |
| 399 | + <el-input | ||
| 400 | + v-model="adminUserInfo.zhuanye" | ||
| 401 | + placeholder="请输入专业" | ||
| 402 | + style="width: 40%" | ||
| 403 | + ></el-input> | ||
| 240 | </el-form-item> | 404 | </el-form-item> |
| 241 | - <el-form-item label="毕业院校" style="margin-top: 40px;" prop="username"> | ||
| 242 | - <el-input v-model="adminUserInfo.byyx" placeholder="请输入毕业院校" style="width: 40%;"></el-input> | 405 | + <el-form-item label="毕业院校" style="margin-top: 40px" prop="username"> |
| 406 | + <el-input | ||
| 407 | + v-model="adminUserInfo.byyx" | ||
| 408 | + placeholder="请输入毕业院校" | ||
| 409 | + style="width: 40%" | ||
| 410 | + ></el-input> | ||
| 243 | </el-form-item> | 411 | </el-form-item> |
| 244 | 412 | ||
| 245 | <!-- <el-form-item label="密码" prop="password" > | 413 | <!-- <el-form-item label="密码" prop="password" > |
| 246 | <el-input v-model="adminUserInfo.password " placeholder="请输入密码 不填默认不修改" show-password style="width: 40%;"></el-input> | 414 | <el-input v-model="adminUserInfo.password " placeholder="请输入密码 不填默认不修改" show-password style="width: 40%;"></el-input> |
| 247 | </el-form-item> --> | 415 | </el-form-item> --> |
| 248 | - <el-form-item style="text-align: right;"> | ||
| 249 | - <el-button @click="dialogClassIVIsible=false">取消</el-button> | ||
| 250 | - <el-button type="primary" @click="submitForm('adminUserInfo')">提交</el-button> | 416 | + <el-form-item style="text-align: right"> |
| 417 | + <el-button @click="dialogClassIVIsible = false">取消</el-button> | ||
| 418 | + <el-button type="primary" @click="submitForm('adminUserInfo')" | ||
| 419 | + >提交</el-button | ||
| 420 | + > | ||
| 251 | </el-form-item> | 421 | </el-form-item> |
| 252 | </el-form> | 422 | </el-form> |
| 253 | 423 | ||
| 254 | - <div style="clear: both;"></div> | 424 | + <div style="clear: both"></div> |
| 255 | </el-dialog> | 425 | </el-dialog> |
| 256 | - | ||
| 257 | </div> | 426 | </div> |
| 258 | </template> | 427 | </template> |
| 259 | 428 | ||
| 260 | <script> | 429 | <script> |
| 261 | - import { ImportUserByExcel, GetUserList, AddInvitationAnswerMultiple,UsersDelete } from "@/api/user"; | ||
| 262 | - import { GetUserClassList, UserClassCreate, UserClassUpdate, UserClassDelete } from "@/api/userclass"; | ||
| 263 | - import { GetHistoryList } from '@/api/HistoryAnswer' | ||
| 264 | - | ||
| 265 | - import { | ||
| 266 | - getTestPaperList | ||
| 267 | - } from '@/api/TestPaper' | ||
| 268 | - export default { | ||
| 269 | - data() { | ||
| 270 | - return { | ||
| 271 | - loading:false, | ||
| 272 | - dialogFormVisible: false, | ||
| 273 | - dialogTableVisible: false, | ||
| 274 | - dialogTypecat: 'create', | ||
| 275 | - testpaperlist: [], | ||
| 276 | - form: { | ||
| 277 | - | ||
| 278 | - NumberOfAnswers: 3 | ||
| 279 | - }, | ||
| 280 | - userList: [], | ||
| 281 | - data: [], | ||
| 282 | - dialogVisiblecat: false, | ||
| 283 | - filterText: '', | ||
| 284 | - gridData: [], | ||
| 285 | - Count: 0, | ||
| 286 | - adminUserInfo: {}, | ||
| 287 | - temp: { | ||
| 288 | - ParentId: 0 | ||
| 289 | - }, | ||
| 290 | - mzlist: ['汉族', | ||
| 291 | - '蒙古族 ', '羌族 ', '僳僳族 ', '哈尼族', | ||
| 292 | - '回族', '布朗族', '佤族', '哈萨克族', | ||
| 293 | - '藏族', '撒拉族', '畲族', '傣族', | ||
| 294 | - '维吾尔族', '毛南族', '高山族', '德昂族', | ||
| 295 | - '苗族', '仡佬族', '拉祜族', '保安族', | ||
| 296 | - '彝族', '锡伯族', '水族', '裕固族', | ||
| 297 | - '壮族', '阿昌族', '东乡族', '京族', | ||
| 298 | - '布依族', '普米族', '纳西族', '独龙族', | ||
| 299 | - '朝鲜族', '塔吉克族', '景颇族', '鄂伦春族', | ||
| 300 | - '满族', '怒族', '柯尔克孜族', '赫哲族', | ||
| 301 | - '侗族', '乌孜别克族', '土族', '门巴族', | ||
| 302 | - '瑶族', '俄罗斯族', '达斡尔族', '珞巴族', | ||
| 303 | - '白族', '鄂温克族', '塔塔尔族', '基诺族' | ||
| 304 | - ], | ||
| 305 | - type: "1", | ||
| 306 | - dialogClassIVIsible: false, | ||
| 307 | - query: { | ||
| 308 | - UserTypeEnum: 1, //0:管理员,1普通用户 | ||
| 309 | - PageIndex: 1, | ||
| 310 | - PageSize: 10, | ||
| 311 | - keyword: '' | ||
| 312 | - }, | ||
| 313 | - fileList: [], | ||
| 314 | - selectedList: [], | ||
| 315 | - props: { | ||
| 316 | - label: 'ClassTitle', | ||
| 317 | - children: 'children' | ||
| 318 | - }, | ||
| 319 | - }; | ||
| 320 | - }, | ||
| 321 | - watch: { | ||
| 322 | - filterText(val) { | ||
| 323 | - this.$refs.tree.filter(val); | ||
| 324 | - } | ||
| 325 | - }, | ||
| 326 | - | ||
| 327 | - created() { | ||
| 328 | - this.GetUser(); | ||
| 329 | - this.forceTestPaper(); | ||
| 330 | - this.loadTree(); | ||
| 331 | - }, | ||
| 332 | - methods: { | ||
| 333 | - handleDelete(item,index){ | ||
| 334 | - this.userList.splice(index,1); | ||
| 335 | - UsersDelete({ids:item.id}); | ||
| 336 | - }, | ||
| 337 | - handleWatchLive(item){ | ||
| 338 | - console.log('handleWatchLive',item); | ||
| 339 | - this.$router.push(`/live?id=${item.StreamName}`) | ||
| 340 | - }, | ||
| 341 | - handleAnswerDetail(item){ | ||
| 342 | - window.open(`/#/answerDetail?id=${item.id}`,"_blank") | 430 | +import { |
| 431 | + ImportUserByExcel, | ||
| 432 | + GetUserList, | ||
| 433 | + AddInvitationAnswerMultiple, | ||
| 434 | + UsersDelete, | ||
| 435 | +} from "@/api/user"; | ||
| 436 | +import { | ||
| 437 | + GetUserClassList, | ||
| 438 | + UserClassCreate, | ||
| 439 | + UserClassUpdate, | ||
| 440 | + UserClassDelete, | ||
| 441 | +} from "@/api/userclass"; | ||
| 442 | +import { GetHistoryList } from "@/api/HistoryAnswer"; | ||
| 443 | + | ||
| 444 | +import { getTestPaperList } from "@/api/TestPaper"; | ||
| 445 | +export default { | ||
| 446 | + data() { | ||
| 447 | + return { | ||
| 448 | + loading: false, | ||
| 449 | + dialogFormVisible: false, | ||
| 450 | + dialogTableVisible: false, | ||
| 451 | + dialogTypecat: "create", | ||
| 452 | + testpaperlist: [], | ||
| 453 | + form: { | ||
| 454 | + NumberOfAnswers: 3, | ||
| 343 | }, | 455 | }, |
| 344 | - submitForm() { | ||
| 345 | - this.dialogClassIVIsible = false; | 456 | + userList: [], |
| 457 | + data: [], | ||
| 458 | + dialogVisiblecat: false, | ||
| 459 | + filterText: "", | ||
| 460 | + gridData: [], | ||
| 461 | + Count: 0, | ||
| 462 | + adminUserInfo: {}, | ||
| 463 | + temp: { | ||
| 464 | + ParentId: 0, | ||
| 346 | }, | 465 | }, |
| 347 | - handleEdit(data) { | ||
| 348 | - this.dialogClassIVIsible = true; | ||
| 349 | - this.adminUserInfo = data; | 466 | + mzlist: [ |
| 467 | + "汉族", | ||
| 468 | + "蒙古族 ", | ||
| 469 | + "羌族 ", | ||
| 470 | + "僳僳族 ", | ||
| 471 | + "哈尼族", | ||
| 472 | + "回族", | ||
| 473 | + "布朗族", | ||
| 474 | + "佤族", | ||
| 475 | + "哈萨克族", | ||
| 476 | + "藏族", | ||
| 477 | + "撒拉族", | ||
| 478 | + "畲族", | ||
| 479 | + "傣族", | ||
| 480 | + "维吾尔族", | ||
| 481 | + "毛南族", | ||
| 482 | + "高山族", | ||
| 483 | + "德昂族", | ||
| 484 | + "苗族", | ||
| 485 | + "仡佬族", | ||
| 486 | + "拉祜族", | ||
| 487 | + "保安族", | ||
| 488 | + "彝族", | ||
| 489 | + "锡伯族", | ||
| 490 | + "水族", | ||
| 491 | + "裕固族", | ||
| 492 | + "壮族", | ||
| 493 | + "阿昌族", | ||
| 494 | + "东乡族", | ||
| 495 | + "京族", | ||
| 496 | + "布依族", | ||
| 497 | + "普米族", | ||
| 498 | + "纳西族", | ||
| 499 | + "独龙族", | ||
| 500 | + "朝鲜族", | ||
| 501 | + "塔吉克族", | ||
| 502 | + "景颇族", | ||
| 503 | + "鄂伦春族", | ||
| 504 | + "满族", | ||
| 505 | + "怒族", | ||
| 506 | + "柯尔克孜族", | ||
| 507 | + "赫哲族", | ||
| 508 | + "侗族", | ||
| 509 | + "乌孜别克族", | ||
| 510 | + "土族", | ||
| 511 | + "门巴族", | ||
| 512 | + "瑶族", | ||
| 513 | + "俄罗斯族", | ||
| 514 | + "达斡尔族", | ||
| 515 | + "珞巴族", | ||
| 516 | + "白族", | ||
| 517 | + "鄂温克族", | ||
| 518 | + "塔塔尔族", | ||
| 519 | + "基诺族", | ||
| 520 | + ], | ||
| 521 | + type: "1", | ||
| 522 | + dialogClassIVIsible: false, | ||
| 523 | + query: { | ||
| 524 | + UserTypeEnum: 1, //0:管理员,1普通用户 | ||
| 525 | + PageIndex: 1, | ||
| 526 | + PageSize: 10, | ||
| 527 | + keyword: "", | ||
| 350 | }, | 528 | }, |
| 351 | - handleTestHitory(row) { | ||
| 352 | - GetHistoryList({ UserId: row.id }).then(res => { | ||
| 353 | - this.gridData = res.data.data; | ||
| 354 | - this.dialogTableVisible = true; | ||
| 355 | - }); | ||
| 356 | - | 529 | + fileList: [], |
| 530 | + selectedList: [], | ||
| 531 | + props: { | ||
| 532 | + label: "ClassTitle", | ||
| 533 | + children: "children", | ||
| 357 | }, | 534 | }, |
| 358 | - handleShareSend() { | ||
| 359 | - var rows = this.$refs.userList.selection; | ||
| 360 | - var ids = rows.map(o => { return { UserId: o.id } }) || []; | ||
| 361 | - var postData = { | ||
| 362 | - TestPaperId: this.form.TestPaperId, | ||
| 363 | - NumberOfAnswers: this.form.NumberOfAnswers || 1, | ||
| 364 | - Users: ids | ||
| 365 | - }; | ||
| 366 | - if (!ids || ids.length < 1) { | ||
| 367 | - this.$message.warning('请至少选择一个用户进行发送!'); | ||
| 368 | - return; | ||
| 369 | - } | ||
| 370 | - if (!this.form.TestPaperId) { | ||
| 371 | - | ||
| 372 | - this.$message.warning('请选择试卷后再发送!'); | ||
| 373 | - return; | ||
| 374 | - } | ||
| 375 | - this.$confirm('确认向选择的' + ids.length + '个用户发送试卷连接进行测试吗?', '提示消息', { | ||
| 376 | - confirmButtonText: '确认', | ||
| 377 | - cancelButtonText: '取消', | 535 | + }; |
| 536 | + }, | ||
| 537 | + watch: { | ||
| 538 | + filterText(val) { | ||
| 539 | + this.$refs.tree.filter(val); | ||
| 540 | + }, | ||
| 541 | + }, | ||
| 542 | + | ||
| 543 | + created() { | ||
| 544 | + this.GetUser(); | ||
| 545 | + this.forceTestPaper(); | ||
| 546 | + this.loadTree(); | ||
| 547 | + }, | ||
| 548 | + methods: { | ||
| 549 | + handleDelete(item, index) { | ||
| 550 | + this.userList.splice(index, 1); | ||
| 551 | + UsersDelete({ ids: item.id }); | ||
| 552 | + }, | ||
| 553 | + handleWatchLive(item) { | ||
| 554 | + console.log("handleWatchLive", item); | ||
| 555 | + this.$router.push(`/live?id=${item.StreamName}`); | ||
| 556 | + }, | ||
| 557 | + handleAnswerDetail(item) { | ||
| 558 | + window.open(`/#/answerDetail?id=${item.id}`, "_blank"); | ||
| 559 | + }, | ||
| 560 | + submitForm() { | ||
| 561 | + this.dialogClassIVIsible = false; | ||
| 562 | + }, | ||
| 563 | + handleEdit(data) { | ||
| 564 | + this.dialogClassIVIsible = true; | ||
| 565 | + this.adminUserInfo = data; | ||
| 566 | + }, | ||
| 567 | + handleTestHitory(row) { | ||
| 568 | + GetHistoryList({ UserId: row.id }).then((res) => { | ||
| 569 | + this.gridData = res.data.data; | ||
| 570 | + this.dialogTableVisible = true; | ||
| 571 | + }); | ||
| 572 | + }, | ||
| 573 | + handleShareSend() { | ||
| 574 | + var rows = this.$refs.userList.selection; | ||
| 575 | + var ids = | ||
| 576 | + rows.map((o) => { | ||
| 577 | + return { UserId: o.id }; | ||
| 578 | + }) || []; | ||
| 579 | + var postData = { | ||
| 580 | + TestPaperId: this.form.TestPaperId, | ||
| 581 | + NumberOfAnswers: this.form.NumberOfAnswers || 1, | ||
| 582 | + Users: ids, | ||
| 583 | + }; | ||
| 584 | + if (!ids || ids.length < 1) { | ||
| 585 | + this.$message.warning("请至少选择一个用户进行发送!"); | ||
| 586 | + return; | ||
| 587 | + } | ||
| 588 | + if (!this.form.TestPaperId) { | ||
| 589 | + this.$message.warning("请选择试卷后再发送!"); | ||
| 590 | + return; | ||
| 591 | + } | ||
| 592 | + this.$confirm( | ||
| 593 | + "确认向选择的" + ids.length + "个用户发送试卷连接进行测试吗?", | ||
| 594 | + "提示消息", | ||
| 595 | + { | ||
| 596 | + confirmButtonText: "确认", | ||
| 597 | + cancelButtonText: "取消", | ||
| 378 | callback: (action) => { | 598 | callback: (action) => { |
| 379 | if (action == "confirm") { | 599 | if (action == "confirm") { |
| 380 | - | ||
| 381 | - AddInvitationAnswerMultiple(postData).then(res => { | 600 | + AddInvitationAnswerMultiple(postData).then((res) => { |
| 382 | if (res.data.code == 200) { | 601 | if (res.data.code == 200) { |
| 383 | - this.$message.success('发送成功'); | 602 | + this.$message.success("发送成功"); |
| 384 | this.form = {}; | 603 | this.form = {}; |
| 385 | this.dialogFormVisible = false; | 604 | this.dialogFormVisible = false; |
| 386 | this.GetUser(); | 605 | this.GetUser(); |
| 387 | - } | ||
| 388 | - else { | ||
| 389 | - this.$message.error('发送失败'); | 606 | + } else { |
| 607 | + this.$message.error("发送失败"); | ||
| 390 | } | 608 | } |
| 391 | }); | 609 | }); |
| 392 | } | 610 | } |
| 393 | }, | 611 | }, |
| 394 | - }) | ||
| 395 | - }, | ||
| 396 | - forceTestPaper() { | ||
| 397 | - let parameter = { | ||
| 398 | - pageIndex: 1, | ||
| 399 | - pageSize: 10000, | ||
| 400 | - sort: "id", | ||
| 401 | - sortOrder: 1, | ||
| 402 | - keyword: "" | ||
| 403 | } | 612 | } |
| 404 | - getTestPaperList(parameter).then(res => { | ||
| 405 | - this.testpaperlist = res.data.data; | ||
| 406 | - }); | ||
| 407 | - }, | ||
| 408 | - search() { | ||
| 409 | - this.GetUser(); | ||
| 410 | - }, | ||
| 411 | - handleSuccess() { | ||
| 412 | - this.$message.success('导入完成!'); | ||
| 413 | - this.GetUser(); | ||
| 414 | - }, | ||
| 415 | - handleInviteInterview() { | ||
| 416 | - this.dialogFormVisible = true; | ||
| 417 | - }, | ||
| 418 | - handleSelectionChange(val) { | ||
| 419 | - console.log(val); | ||
| 420 | - this.selectedList = val; | ||
| 421 | - }, | ||
| 422 | - handleExceed() { }, | ||
| 423 | - ImportUser() { }, | ||
| 424 | - | ||
| 425 | - | ||
| 426 | - showcontent(c, row) { | ||
| 427 | - this.showbody = c; | ||
| 428 | - this.dialogVisible_content = true; | ||
| 429 | - }, | ||
| 430 | - submitcat() { | ||
| 431 | - // this.$loading({lock:true,text:'保存中...'}); | ||
| 432 | - if (this.loading) { | ||
| 433 | - return | ||
| 434 | - } | ||
| 435 | - this.loading = true | ||
| 436 | - var postData = this.temp; | ||
| 437 | - if (this.dialogTypecat == 'update') { | ||
| 438 | - if (postData.AddTime == '0001-01-01T00:00:00') postData.AddTime = new Date(); | ||
| 439 | - UserClassUpdate(postData).then(o => { | ||
| 440 | - this.$message({ | ||
| 441 | - message: '提交成功', | ||
| 442 | - type: 'success' | ||
| 443 | - }) | ||
| 444 | - this.dialogVisiblecat = false; | ||
| 445 | - setTimeout(()=>{ | ||
| 446 | - this.loading = false; | ||
| 447 | - },1000); | ||
| 448 | - }); | ||
| 449 | - | ||
| 450 | - } | ||
| 451 | - else { | ||
| 452 | - | ||
| 453 | - UserClassCreate(postData).then(o => { | ||
| 454 | - | ||
| 455 | - this.$message({ | ||
| 456 | - message: '提交成功', | ||
| 457 | - type: 'success' | ||
| 458 | - }) | ||
| 459 | - | ||
| 460 | - this.dialogVisiblecat = false | ||
| 461 | - | ||
| 462 | - this.loadTree(); | ||
| 463 | - setTimeout(()=>{ | ||
| 464 | - this.loading = false; | ||
| 465 | - },1000); | 613 | + ); |
| 614 | + }, | ||
| 615 | + forceTestPaper() { | ||
| 616 | + let parameter = { | ||
| 617 | + pageIndex: 1, | ||
| 618 | + pageSize: 10000, | ||
| 619 | + sort: "id", | ||
| 620 | + sortOrder: 1, | ||
| 621 | + keyword: "", | ||
| 622 | + }; | ||
| 623 | + getTestPaperList(parameter).then((res) => { | ||
| 624 | + this.testpaperlist = res.data.data; | ||
| 625 | + }); | ||
| 626 | + }, | ||
| 627 | + search() { | ||
| 628 | + this.GetUser(); | ||
| 629 | + }, | ||
| 630 | + handleSuccess() { | ||
| 631 | + this.$message.success("导入完成!"); | ||
| 632 | + this.GetUser(); | ||
| 633 | + }, | ||
| 634 | + handleInviteInterview() { | ||
| 635 | + this.dialogFormVisible = true; | ||
| 636 | + }, | ||
| 637 | + handleSelectionChange(val) { | ||
| 638 | + console.log(val); | ||
| 639 | + this.selectedList = val; | ||
| 640 | + }, | ||
| 641 | + handleExceed() {}, | ||
| 642 | + ImportUser() {}, | ||
| 466 | 643 | ||
| 467 | - }); | ||
| 468 | - } | ||
| 469 | - }, | ||
| 470 | - editclose(data) { | ||
| 471 | - // this.dialogVisible_step = false; | ||
| 472 | - this.fetchData() | ||
| 473 | - }, | ||
| 474 | - loadTree() { | ||
| 475 | - GetUserClassList({ ParentId: 0 }).then(res => { | ||
| 476 | - this.data = res.data.data | ||
| 477 | - }) | ||
| 478 | - }, | ||
| 479 | - filterNode(value, data) { | ||
| 480 | - if (!value) return true; | ||
| 481 | - return data.ClassTitle.indexOf(value) !== -1 | ||
| 482 | - }, | ||
| 483 | - addcat() { | ||
| 484 | - this.temp = { AddTime: new Date() } | ||
| 485 | - this.dialogVisiblecat = true | ||
| 486 | - }, | ||
| 487 | - editcat() { | ||
| 488 | - this.dialogTypecat = 'update'; | ||
| 489 | - if (!this.temp.id) { | 644 | + showcontent(c, row) { |
| 645 | + this.showbody = c; | ||
| 646 | + this.dialogVisible_content = true; | ||
| 647 | + }, | ||
| 648 | + submitcat() { | ||
| 649 | + // this.$loading({lock:true,text:'保存中...'}); | ||
| 650 | + if (this.loading) { | ||
| 651 | + return; | ||
| 652 | + } | ||
| 653 | + this.loading = true; | ||
| 654 | + var postData = this.temp; | ||
| 655 | + if (this.dialogTypecat == "update") { | ||
| 656 | + if (postData.AddTime == "0001-01-01T00:00:00") | ||
| 657 | + postData.AddTime = new Date(); | ||
| 658 | + UserClassUpdate(postData).then((o) => { | ||
| 490 | this.$message({ | 659 | this.$message({ |
| 491 | - message: '请选择一个分类进行操作!', | ||
| 492 | - type: 'warning' | ||
| 493 | - }) | ||
| 494 | - return; | ||
| 495 | - } | ||
| 496 | - this.dialogVisiblecat = true; | ||
| 497 | - }, | ||
| 498 | - delcat() { | ||
| 499 | - if (!this.temp.id) { | 660 | + message: "提交成功", |
| 661 | + type: "success", | ||
| 662 | + }); | ||
| 663 | + this.dialogVisiblecat = false; | ||
| 664 | + setTimeout(() => { | ||
| 665 | + this.loading = false; | ||
| 666 | + }, 1000); | ||
| 667 | + }); | ||
| 668 | + } else { | ||
| 669 | + UserClassCreate(postData).then((o) => { | ||
| 500 | this.$message({ | 670 | this.$message({ |
| 501 | - message: '请选择一个分类进行操作!', | ||
| 502 | - type: 'warning' | ||
| 503 | - }) | ||
| 504 | - return; | ||
| 505 | - } | ||
| 506 | - this.$confirm('确认删除该分类吗?', '提示', { | ||
| 507 | - confirmButtonText: '确定', | ||
| 508 | - cancelButtonText: '取消', | ||
| 509 | - type: 'warning' | ||
| 510 | - }).then(() => { | ||
| 511 | - UserClassDelete({ ids: this.temp.id }).then(o => { | ||
| 512 | - this.loadTree(); | ||
| 513 | - this.$message({ | ||
| 514 | - message: '删除成功', | ||
| 515 | - type: 'success' | ||
| 516 | - }) | 671 | + message: "提交成功", |
| 672 | + type: "success", | ||
| 517 | }); | 673 | }); |
| 518 | 674 | ||
| 519 | - }) | ||
| 520 | - }, | ||
| 521 | - handleNodeClick(data, checked, indeterminate) { | ||
| 522 | - this.query.userClassId = data.id; | ||
| 523 | - this.temp = data; | ||
| 524 | - this.GetUser() | ||
| 525 | - }, | 675 | + this.dialogVisiblecat = false; |
| 526 | 676 | ||
| 527 | - resetSearch() { | ||
| 528 | - this.query = { | ||
| 529 | - UserTypeEnum: 1, //0:管理员,1普通用户 | ||
| 530 | - PageIndex: 1, | ||
| 531 | - PageSize: 10, | ||
| 532 | - keyword: '' | ||
| 533 | - }; | ||
| 534 | - this.GetUser(); | ||
| 535 | - }, | ||
| 536 | - GetUser() { | ||
| 537 | - GetUserList(this.query).then((res) => { | ||
| 538 | - this.userList = res.data.data.rows.map((t) => { | ||
| 539 | - if (t.phone) { | ||
| 540 | - t.phone1 = t.phone.replace(t.phone.substring(3, 7), "****"); | ||
| 541 | - } | ||
| 542 | - return t; | 677 | + this.loadTree(); |
| 678 | + setTimeout(() => { | ||
| 679 | + this.loading = false; | ||
| 680 | + }, 1000); | ||
| 681 | + }); | ||
| 682 | + } | ||
| 683 | + }, | ||
| 684 | + editclose(data) { | ||
| 685 | + // this.dialogVisible_step = false; | ||
| 686 | + this.fetchData(); | ||
| 687 | + }, | ||
| 688 | + loadTree() { | ||
| 689 | + GetUserClassList({ ParentId: 0 }).then((res) => { | ||
| 690 | + this.data = res.data.data; | ||
| 691 | + }); | ||
| 692 | + }, | ||
| 693 | + filterNode(value, data) { | ||
| 694 | + if (!value) return true; | ||
| 695 | + return data.ClassTitle.indexOf(value) !== -1; | ||
| 696 | + }, | ||
| 697 | + addcat() { | ||
| 698 | + this.temp = { AddTime: new Date() }; | ||
| 699 | + this.dialogVisiblecat = true; | ||
| 700 | + }, | ||
| 701 | + editcat() { | ||
| 702 | + this.dialogTypecat = "update"; | ||
| 703 | + if (!this.temp.id) { | ||
| 704 | + this.$message({ | ||
| 705 | + message: "请选择一个分类进行操作!", | ||
| 706 | + type: "warning", | ||
| 707 | + }); | ||
| 708 | + return; | ||
| 709 | + } | ||
| 710 | + this.dialogVisiblecat = true; | ||
| 711 | + }, | ||
| 712 | + delcat() { | ||
| 713 | + if (!this.temp.id) { | ||
| 714 | + this.$message({ | ||
| 715 | + message: "请选择一个分类进行操作!", | ||
| 716 | + type: "warning", | ||
| 717 | + }); | ||
| 718 | + return; | ||
| 719 | + } | ||
| 720 | + this.$confirm("确认删除该分类吗?", "提示", { | ||
| 721 | + confirmButtonText: "确定", | ||
| 722 | + cancelButtonText: "取消", | ||
| 723 | + type: "warning", | ||
| 724 | + }).then(() => { | ||
| 725 | + UserClassDelete({ ids: this.temp.id }).then((o) => { | ||
| 726 | + this.loadTree(); | ||
| 727 | + this.$message({ | ||
| 728 | + message: "删除成功", | ||
| 729 | + type: "success", | ||
| 543 | }); | 730 | }); |
| 544 | - this.Count = res.data.data.total; | ||
| 545 | }); | 731 | }); |
| 546 | - }, | ||
| 547 | - currentchange(page) { | ||
| 548 | - this.query.PageIndex = page; | ||
| 549 | - this.GetUser(); | ||
| 550 | - }, | 732 | + }); |
| 733 | + }, | ||
| 734 | + handleNodeClick(data, checked, indeterminate) { | ||
| 735 | + this.query.userClassId = data.id; | ||
| 736 | + this.temp = data; | ||
| 737 | + this.GetUser(); | ||
| 738 | + }, | ||
| 739 | + | ||
| 740 | + resetSearch() { | ||
| 741 | + this.query = { | ||
| 742 | + UserTypeEnum: 1, //0:管理员,1普通用户 | ||
| 743 | + PageIndex: 1, | ||
| 744 | + PageSize: 10, | ||
| 745 | + keyword: "", | ||
| 746 | + }; | ||
| 747 | + this.GetUser(); | ||
| 748 | + }, | ||
| 749 | + GetUser() { | ||
| 750 | + GetUserList(this.query).then((res) => { | ||
| 751 | + this.userList = res.data.data.rows.map((t) => { | ||
| 752 | + if (t.phone) { | ||
| 753 | + t.phone1 = t.phone.replace(t.phone.substring(3, 7), "****"); | ||
| 754 | + } | ||
| 755 | + return t; | ||
| 756 | + }); | ||
| 757 | + this.Count = res.data.data.total; | ||
| 758 | + }); | ||
| 759 | + }, | ||
| 760 | + currentchange(page) { | ||
| 761 | + this.query.PageIndex = page; | ||
| 762 | + this.GetUser(); | ||
| 551 | }, | 763 | }, |
| 552 | - }; | 764 | + }, |
| 765 | +}; | ||
| 553 | </script> | 766 | </script> |
| 554 | 767 | ||
| 555 | <style lang="scss" scoped> | 768 | <style lang="scss" scoped> |
| 556 | - .seetingsDiv { | ||
| 557 | - display: flex; | ||
| 558 | - align-items: center; | ||
| 559 | - width: 100%; | ||
| 560 | - padding-top: 10px; | ||
| 561 | - padding-left: 10px; | ||
| 562 | - /* height: 60px; */ | ||
| 563 | - background: #efefef; | ||
| 564 | - /* line-height: 60px; */ | ||
| 565 | - border-radius: 5px; | ||
| 566 | - box-shadow: 0 0 5px #cdcdcd; | ||
| 567 | - justify-content: space-between; | ||
| 568 | - } | ||
| 569 | - | ||
| 570 | - .seetingsDiv button { | ||
| 571 | - height: 40px; | ||
| 572 | - background-color: #304156; | ||
| 573 | - border: 0px; | ||
| 574 | - margin-left: 10px; | ||
| 575 | - box-shadow: 0 0 5px #cdcdcd; | ||
| 576 | - float: none; | ||
| 577 | - margin-right: 10px; | ||
| 578 | - } | 769 | +.seetingsDiv { |
| 770 | + display: flex; | ||
| 771 | + align-items: center; | ||
| 772 | + width: 100%; | ||
| 773 | + padding-top: 10px; | ||
| 774 | + padding-left: 10px; | ||
| 775 | + /* height: 60px; */ | ||
| 776 | + background: #efefef; | ||
| 777 | + /* line-height: 60px; */ | ||
| 778 | + border-radius: 5px; | ||
| 779 | + box-shadow: 0 0 5px #cdcdcd; | ||
| 780 | + justify-content: space-between; | ||
| 781 | +} | ||
| 782 | + | ||
| 783 | +.seetingsDiv button { | ||
| 784 | + height: 40px; | ||
| 785 | + background-color: #304156; | ||
| 786 | + border: 0px; | ||
| 787 | + margin-left: 10px; | ||
| 788 | + box-shadow: 0 0 5px #cdcdcd; | ||
| 789 | + float: none; | ||
| 790 | + margin-right: 10px; | ||
| 791 | +} | ||
| 579 | </style> | 792 | </style> |
| 580 | \ No newline at end of file | 793 | \ No newline at end of file |