|  | @@ -4,6 +4,9 @@
 | 
	
		
			
				|  |  |        <el-button icon="el-icon-refresh" circle @click="handleQuery"></el-button>
 | 
	
		
			
				|  |  |      </div>
 | 
	
		
			
				|  |  |      <dynamic-table :rows="rows" :columns="columns">
 | 
	
		
			
				|  |  | +      <template #index="{$index}">
 | 
	
		
			
				|  |  | +        {{ (queryParams.pageNum - 1) * queryParams.pageSize + $index + 1 }}
 | 
	
		
			
				|  |  | +      </template>
 | 
	
		
			
				|  |  |        <template #type="{display}">
 | 
	
		
			
				|  |  |          {{ translateType(display) }}
 | 
	
		
			
				|  |  |        </template>
 | 
	
	
		
			
				|  | @@ -12,7 +15,10 @@
 | 
	
		
			
				|  |  |            <el-button v-if="row.type == paperWorkType.value" type="text" icon="el-icon-edit"
 | 
	
		
			
				|  |  |                       @click="clickEditPaper(row)">编辑
 | 
	
		
			
				|  |  |            </el-button>
 | 
	
		
			
				|  |  | -          <el-button type="text" icon="el-icon-connection" @click="clickPublish(row)">发布</el-button>
 | 
	
		
			
				|  |  | +          <el-button type="text" icon="el-icon-connection" @click="clickPublish(row)">
 | 
	
		
			
				|  |  | +            发布
 | 
	
		
			
				|  |  | +            <template v-if="row.publishedCount">({{ row.publishedCount }})</template>
 | 
	
		
			
				|  |  | +          </el-button>
 | 
	
		
			
				|  |  |          </div>
 | 
	
		
			
				|  |  |        </template>
 | 
	
		
			
				|  |  |      </dynamic-table>
 | 
	
	
		
			
				|  | @@ -34,7 +40,7 @@
 | 
	
		
			
				|  |  |  
 | 
	
		
			
				|  |  |  <script>
 | 
	
		
			
				|  |  |  import DynamicTable from '@/components/dynamic-table/index'
 | 
	
		
			
				|  |  | -import { getHomeworks, publicStudentHomework } from '@/api/webApi/homework'
 | 
	
		
			
				|  |  | +import { getHomeworks, getHomeworkStudents, publicStudentHomework } from '@/api/webApi/homework'
 | 
	
		
			
				|  |  |  import consts from '@/common/mx-const'
 | 
	
		
			
				|  |  |  import { download, listCustomerPaperQeustions } from '@/api/webApi/webQue'
 | 
	
		
			
				|  |  |  import { mapGetters } from 'vuex'
 | 
	
	
		
			
				|  | @@ -51,11 +57,11 @@ export default {
 | 
	
		
			
				|  |  |          pageSize: 20
 | 
	
		
			
				|  |  |        },
 | 
	
		
			
				|  |  |        columns: [
 | 
	
		
			
				|  |  | -        { prop: 'id', label: 'ID', width: '80px' },
 | 
	
		
			
				|  |  | +        { prop: 'id', label: '序号', width: '80px', slotBody: 'index' },
 | 
	
		
			
				|  |  |          { prop: 'type', label: '类型', width: '120px', slotBody: 'type' },
 | 
	
		
			
				|  |  |          { prop: 'title', label: '标题' },
 | 
	
		
			
				|  |  |          { prop: 'createTime', label: '创建时间', width: '180px' },
 | 
	
		
			
				|  |  | -        { prop: 'action', label: '操作', width: '120px', slotBody: 'action' }],
 | 
	
		
			
				|  |  | +        { prop: 'action', label: '操作', width: '180px', slotBody: 'action' }],
 | 
	
		
			
				|  |  |        rows: [],
 | 
	
		
			
				|  |  |        total: 0,
 | 
	
		
			
				|  |  |        uploadWork: null,
 | 
	
	
		
			
				|  | @@ -63,6 +69,7 @@ export default {
 | 
	
		
			
				|  |  |          title: '发布作业',
 | 
	
		
			
				|  |  |          pageName: '',
 | 
	
		
			
				|  |  |          selectType: '',
 | 
	
		
			
				|  |  | +        defaultSelected: [],
 | 
	
		
			
				|  |  |          dialogVisible: false
 | 
	
		
			
				|  |  |        }
 | 
	
		
			
				|  |  |      }
 | 
	
	
		
			
				|  | @@ -107,9 +114,11 @@ export default {
 | 
	
		
			
				|  |  |      clickDownloadPaper(paperId) {
 | 
	
		
			
				|  |  |        download(paperId, this.period)
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  | -    clickPublish(work) {
 | 
	
		
			
				|  |  | +    async clickPublish(work) {
 | 
	
		
			
				|  |  | +      const res = await getHomeworkStudents({ workId: work.id })
 | 
	
		
			
				|  |  |        this.uploadWork = work
 | 
	
		
			
				|  |  |        this.uploadOption.selectType = 'student'
 | 
	
		
			
				|  |  | +      this.uploadOption.defaultSelected = res.data.map(item => item.customerCode) || []
 | 
	
		
			
				|  |  |        this.uploadOption.dialogVisible = true
 | 
	
		
			
				|  |  |      },
 | 
	
		
			
				|  |  |      async handleUploadReady(type, name, selectData) {
 |