Merge branch 'master' of http://114.132.189.42:9002/r/center-lims-before into master
| | |
| | | "renderkid": "^2.0.4" |
| | | } |
| | | }, |
| | | "print-js": { |
| | | "version": "1.6.0", |
| | | "resolved": "https://registry.npmmirror.com/print-js/-/print-js-1.6.0.tgz", |
| | | "integrity": "sha512-BfnOIzSKbqGRtO4o0rnj/K3681BSd2QUrsIZy/+WdCIugjIswjmx3lDEZpXB2ruGf9d4b3YNINri81+J0FsBWg==" |
| | | }, |
| | | "printj": { |
| | | "version": "1.1.2", |
| | | "resolved": "https://registry.npmjs.org/printj/-/printj-1.1.2.tgz", |
| | |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | <div class="search_thing"> |
| | | <div class="search_thing" style="width: 390px;"> |
| | | <div class="search_label" style="width: 90px;">时间范围:</div> |
| | | <div class="search_input"> |
| | | <el-date-picker |
| | |
| | | size="small" |
| | | type="daterange" |
| | | range-separator="至" |
| | | format="yyyy-MM-dd HH:mm:ss" |
| | | value-format="yyyy-MM-dd HH:mm:ss" |
| | | format="yyyy-MM-dd" |
| | | value-format="yyyy-MM-dd" |
| | | start-placeholder="开始日期" |
| | | end-placeholder="结束日期" @change="refreshTable()" clearable> |
| | | </el-date-picker> |
| | |
| | | <p style="font-size: 14px;margin-right: 30px;"> |
| | | 总工时汇总:<span style="font-size: 16px;color: #3A7BFA;" v-if="totalInfo">{{ (totalInfo['产量工时汇总']+totalInfo['辅助工时汇总'])? (totalInfo['产量工时汇总']+totalInfo['辅助工时汇总']):0 }}</span> 产量工时汇总:<span style="font-size: 16px;color: #3A7BFA;" v-if="totalInfo">{{totalInfo['产量工时汇总']?totalInfo['产量工时汇总']:0}}</span> 辅助工时汇总:<span style="font-size: 16px;color: #3A7BFA;" v-if="totalInfo">{{totalInfo['辅助工时汇总']?totalInfo['辅助工时汇总']:0}}</span> |
| | | </p> |
| | | <el-button size="small" type="primary" style="margin-right: 16px;" @click="openAdd" v-show="currentTable == 'ValueTable0'&&add">录入数据</el-button> |
| | | <el-button size="small" type="primary" @click="openAdd" v-show="currentTable == 'ValueTable0'&&add">录入数据</el-button> |
| | | <el-button size="small" type="primary" |
| | | v-if="down" |
| | | @click="handleOut" :loading="outLoading">导 出</el-button> |
| | | <el-button size="small" type="primary" v-show="currentTable == 'ValueTable0'&&add" @click="openBatchCheck(0)">批量审核</el-button> |
| | | <el-button size="small" type="primary" v-show="currentTable == 'ValueTable0'&&add" @click="openBatchCheck(1)">批量批准</el-button> |
| | | </div> |
| | | </div> |
| | | <div class="table"> |
| | | <ValueTable ref="ValueTable0" |
| | | v-if="currentTable == 'ValueTable0'" |
| | | v-if="currentTable == 'ValueTable0'" :isColumnWidth="true" |
| | | :url="$api.auxiliaryWorkingHoursDay.selectAuxiliaryWorkingHoursDay" |
| | | :delUrl="$api.auxiliaryWorkingHoursDay.deleteAuxiliaryWorkingHoursDay" :componentData="componentData" :key="upIndex" |
| | | @delete="handleDelete" /> |
| | | <ValueTable ref="ValueTable1" |
| | | v-if="currentTable == 'ValueTable1'" |
| | | <ValueTable ref="ValueTable1" v-if="currentTable == 'ValueTable1'" :isColumnWidth="true" |
| | | :url="$api.auxiliaryOutputWorkingHours.selectAuxiliaryOutputWorkingHours" :componentData="componentData1" :key="upIndex1" /> |
| | | </div> |
| | | <el-dialog :title="formData.id?'编辑':'录入数据'" :visible.sync="addVisible" width="600px" :before-close="handleClose"> |
| | |
| | | </el-option> |
| | | </el-select> |
| | | </el-form-item> |
| | | <el-form-item label="复核说明:"> |
| | | <el-input v-model="formData0.reviewerRemark" type="textarea" :rows="3" size="small" :disabled="title=='批准'"></el-input> |
| | | </el-form-item> |
| | | </el-form> |
| | | </el-col> |
| | | <el-col :span="12"> |
| | |
| | | <el-input v-model="formData0.number" size="small" :disabled="title=='批准'"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="数量:" required> |
| | | <el-input v-model="formData0.amount" size="small" :disabled="title=='批准'"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="复核数量:" required> |
| | | <el-input v-model="formData0.reviewerNumber" size="small" :disabled="title=='批准'"></el-input> |
| | | </el-form-item> |
| | | <el-form-item label="核准工时:"> |
| | |
| | | </el-form> |
| | | </el-col> |
| | | </el-row> |
| | | <el-form :model="formData0" label-width="90px"> |
| | | <el-form-item label="复核说明:"> |
| | | <el-input v-model="formData0.reviewerRemark" type="textarea" |
| | | :rows="3" size="small" :disabled="title=='批准'"></el-input> |
| | | </el-form-item> |
| | | </el-form> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-row> |
| | | <el-button @click="submitCheck(0)" :loading="checkLoadN">{{title=='审核'?'不通过':'不批准'}}</el-button> |
| | |
| | | </el-row> |
| | | </span> |
| | | </el-dialog> |
| | | <el-dialog |
| | | :title="batchCheckTitle" |
| | | :visible.sync="batchCheckDialog" |
| | | width="30%" |
| | | :before-close="closeBatchCheckDialog"> |
| | | <span>{{batchCheckDialogMessage}}</span> |
| | | <span slot="footer" class="dialog-footer"> |
| | | <el-button @click="batchCheckDialog = false">{{batchCheckTitle=='批量审核'?'不通过':'不批准'}}</el-button> |
| | | <el-button type="primary" @click="batchCheck">{{batchCheckTitle=='批量审核'?'通 过':'批 准'}}</el-button> |
| | | </span> |
| | | </el-dialog> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | down:false, |
| | | add:false, |
| | | componentData: { |
| | | entity: { |
| | | week: null, |
| | | weekDay: null, |
| | | dateTime: new Date(), |
| | | name:null, |
| | | orderBy: { |
| | | field: 'id', |
| | | order: 'desc' |
| | | } |
| | | }, |
| | | isIndex: true, |
| | | showSelect: false, |
| | | select: false, |
| | | do: [{ |
| | | id: 'delete', |
| | | font: '删除', |
| | | type: 'text', |
| | | method: 'doDiy' |
| | | }, { |
| | | id: 'handleEdit', |
| | | font: '编辑', |
| | | type: 'text', |
| | | method: 'handleEdit' |
| | | },{ |
| | | id: 'handleCheck', |
| | | font: '审核', |
| | | type: 'text', |
| | | method: 'handleCheck' |
| | | }, { |
| | | id: 'handleRatify', |
| | | font: '批准', |
| | | type: 'text', |
| | | method: 'handleRatify' |
| | | }], |
| | | tagField: { |
| | | shift:{ |
| | | select:[] |
| | | }, |
| | | state:{ |
| | | select:[ |
| | | { |
| | | label:'已提交', |
| | | value:'已提交', |
| | | type:'primary' |
| | | }, |
| | | { |
| | | label:'已审核', |
| | | value:'已审核', |
| | | type:'warning' |
| | | }, |
| | | { |
| | | label:'已批准', |
| | | value:'已批准', |
| | | type:'success' |
| | | }, |
| | | ] |
| | | }, |
| | | weekDay:{ |
| | | select:[] |
| | | } |
| | | entity: { |
| | | week: null, |
| | | weekDay: null, |
| | | dateTime: null, |
| | | name:null, |
| | | orderBy: { |
| | | field: 'id', |
| | | order: 'desc' |
| | | } |
| | | }, |
| | | isIndex: true, |
| | | showSelect: true, |
| | | select: true, |
| | | selectMethod: 'handleChangeTask', |
| | | do: [{ |
| | | id: 'delete', |
| | | font: '删除', |
| | | type: 'text', |
| | | method: 'doDiy' |
| | | }, { |
| | | id: 'handleEdit', |
| | | font: '编辑', |
| | | type: 'text', |
| | | method: 'handleEdit' |
| | | },{ |
| | | id: 'handleCheck', |
| | | font: '审核', |
| | | type: 'text', |
| | | method: 'handleCheck', |
| | | disabFun: (row, index) => { |
| | | return row.state === '已审核' || row.state === '已批准' |
| | | } |
| | | }, { |
| | | id: 'handleRatify', |
| | | font: '批准', |
| | | type: 'text', |
| | | method: 'handleRatify', |
| | | disabFun: (row, index) => { |
| | | return row.state === '已批准' |
| | | } |
| | | }], |
| | | tagField: { |
| | | shift:{ |
| | | select:[] |
| | | }, |
| | | linkEvent: {}, |
| | | selectField: { |
| | | shift:{ |
| | | select:[] |
| | | }, |
| | | state:{ |
| | | select:[ |
| | | { |
| | | label:'已提交', |
| | | value:'已提交', |
| | | type:'primary' |
| | | }, |
| | | { |
| | | label:'已审核', |
| | | value:'已审核', |
| | | type:'warning' |
| | | }, |
| | | { |
| | | label:'已批准', |
| | | value:'已批准', |
| | | type:'success' |
| | | }, |
| | | ] |
| | | }, |
| | | weekDay:{ |
| | | select:[] |
| | | } |
| | | state:{ |
| | | select:[ |
| | | { |
| | | label:'已提交', |
| | | value:'已提交', |
| | | type:'primary' |
| | | }, |
| | | { |
| | | label:'已审核', |
| | | value:'已审核', |
| | | type:'warning' |
| | | }, |
| | | { |
| | | label:'已批准', |
| | | value:'已批准', |
| | | type:'success' |
| | | }, |
| | | ] |
| | | }, |
| | | requiredAdd: [], |
| | | requiredUp: [] |
| | | weekDay:{ |
| | | select:[] |
| | | } |
| | | }, |
| | | linkEvent: {}, |
| | | selectField: { |
| | | shift:{ |
| | | select:[] |
| | | }, |
| | | state:{ |
| | | select:[ |
| | | { |
| | | label:'已提交', |
| | | value:'已提交', |
| | | type:'primary' |
| | | }, |
| | | { |
| | | label:'已审核', |
| | | value:'已审核', |
| | | type:'warning' |
| | | }, |
| | | { |
| | | label:'已批准', |
| | | value:'已批准', |
| | | type:'success' |
| | | }, |
| | | ] |
| | | }, |
| | | weekDay:{ |
| | | select:[] |
| | | } |
| | | }, |
| | | requiredAdd: [], |
| | | requiredUp: [] |
| | | }, |
| | | entityCopy: {}, |
| | | upIndex: 0, |
| | |
| | | entity: { |
| | | week: null, |
| | | weekDay: null, |
| | | dateTime: null, |
| | | dateTime: [], |
| | | name:null, |
| | | orderBy: { |
| | | field: 'id', |
| | |
| | | reviewerNonproductiveTime:'', |
| | | auxiliaryProject:'', |
| | | reviewerRemark:'', |
| | | nameUser: '' |
| | | }, |
| | | checkVisible:false, |
| | | checkLoadN:false, |
| | |
| | | ], |
| | | totalInfo:null, |
| | | auxiliaryWorking:null, |
| | | outLoading:false |
| | | outLoading:false, |
| | | batchCheckTitle: '批量审核', |
| | | batchCheckDialog: false, |
| | | ValueTable0Selected: [], |
| | | batchCheckDialogMessage: '' |
| | | } |
| | | }, |
| | | watch:{ |
| | |
| | | let year = currentDate.getFullYear(); |
| | | let month = String(currentDate.getMonth() + 1).padStart(2, '0'); |
| | | let day = String(currentDate.getDate()).padStart(2, '0'); |
| | | let formattedDate1 = `${year}-${month}-${day} 00:00:00`; |
| | | let formattedDate2 = `${year}-${month}-${day} 23:59:59`; |
| | | let formattedDate1 = `${year}-${month}-${day}`; |
| | | let formattedDate2 = `${year}-${month}-${day}`; |
| | | this.entity.dateTime.push(formattedDate1); |
| | | this.entity.dateTime.push(formattedDate2); |
| | | this.componentData1.entity.dateTime.push(formattedDate1); |
| | | this.componentData1.entity.dateTime.push(formattedDate2); |
| | | this.refreshTable() |
| | | }, |
| | | getPower(){ |
| | | let power = JSON.parse(sessionStorage.getItem('power')) |
| | |
| | | getYearAndMonthAndDays(date){ |
| | | return getYearAndMonthAndDays(date) |
| | | }, |
| | | refreshTable(){ |
| | | refreshTable(e){ |
| | | let entity = {} |
| | | if(this.entity.week1&&this.entity.week2){ |
| | | entity.week = JSON.stringify([this.entity.week1,this.entity.week2]) |
| | |
| | | if(this.currentTable=='ValueTable0'){ |
| | | entity.state = this.entity.state |
| | | this.componentData.entity = {...this.componentData.entity,...entity} |
| | | this.$refs['ValueTable0'].selectList() |
| | | this.$refs['ValueTable0'].selectList(e) |
| | | }else{ |
| | | this.componentData1.entity = {...this.componentData1.entity,...entity} |
| | | this.$refs['ValueTable1'].selectList() |
| | | this.$refs['ValueTable1'].selectList(e) |
| | | } |
| | | this.collectWorkingHours() |
| | | }, |
| | | refresh(){ |
| | | this.entity = {} |
| | |
| | | this.addLoad = false |
| | | if (res.code == 201) return |
| | | this.$message.success('已提交') |
| | | this.addVisible = false |
| | | this.refreshTable() |
| | | this.formData.number = '' |
| | | this.formData.amount = '' |
| | | this.formData.remarks = '' |
| | | this.formData.approvedWorkingHour = '' |
| | | this.formData.nonproductiveTime = '' |
| | | this.formData.auxiliaryProject = '' |
| | | // this.addVisible = false |
| | | this.refreshTable('page') |
| | | this.collectWorkingHours() |
| | | }) |
| | | }else{ |
| | |
| | | this.addLoad = false |
| | | if (res.code == 201) return |
| | | this.$message.success('操作成功') |
| | | this.addVisible = false |
| | | this.refreshTable() |
| | | this.formData.number = '' |
| | | this.formData.amount = '' |
| | | this.formData.remarks = '' |
| | | this.formData.approvedWorkingHour = '' |
| | | this.formData.nonproductiveTime = '' |
| | | this.formData.auxiliaryProject = '' |
| | | // this.addVisible = false |
| | | this.refreshTable('page') |
| | | this.collectWorkingHours() |
| | | }) |
| | | } |
| | |
| | | this.title = '批准' |
| | | this.formData0 = row; |
| | | this.checkVisible = true |
| | | }, |
| | | handleChangeTask (row) { |
| | | this.ValueTable0Selected = JSON.parse(JSON.stringify(row)) |
| | | }, |
| | | openBatchCheck (e) { |
| | | if (this.ValueTable0Selected.length > 0) { |
| | | const isChecked = this.ValueTable0Selected.every(item => item.state === '已提交') |
| | | const isApprove = this.ValueTable0Selected.every(item => item.state !== '已批准') |
| | | console.log('this.isApprove---', isApprove) |
| | | this.batchCheckTitle = e === 0 ? '批量审核' : '批量批准' |
| | | this.batchCheckDialogMessage = e === 0 ? '是否全部通过审核?' : '是否全部通过批准?' |
| | | if (this.batchCheckTitle === '批量审核') { |
| | | if (isChecked) { |
| | | this.batchCheckDialog = true |
| | | } else { |
| | | this.$message.error('请选择未审核或未批准的数据') |
| | | } |
| | | } else { |
| | | if (isApprove) { |
| | | this.batchCheckDialog = true |
| | | } else { |
| | | this.$message.error('请选择未批准的数据') |
| | | } |
| | | } |
| | | } else { |
| | | this.$message.error('请选择至少一条数据') |
| | | } |
| | | }, |
| | | batchCheck () { |
| | | const e = this.batchCheckTitle === '批量审核' ? 0 : 1 |
| | | this.$refs.ValueTable0.batchCheck(e) |
| | | }, |
| | | closeBatchCheckDialog () { |
| | | this.batchCheckDialog = false |
| | | }, |
| | | submitBatchCheckDialog () { |
| | | this.batchCheckDialog = false |
| | | this.refreshTable('page') |
| | | this.collectWorkingHours() |
| | | }, |
| | | submitCheck(e){ |
| | | if(!this.formData0.number){ |
| | |
| | | if (res.code == 201) return |
| | | this.$message.success('操作成功') |
| | | this.checkVisible = false |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | this.collectWorkingHours() |
| | | }) |
| | | }else{ |
| | |
| | | if (res.code == 201) return |
| | | this.$message.success('操作成功') |
| | | this.checkVisible = false |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | this.collectWorkingHours() |
| | | }) |
| | | } |
| | |
| | | return String(d) |
| | | }, |
| | | collectWorkingHours(){ |
| | | this.$axios.post(this.$api.auxiliaryOutputWorkingHours.collectWorkingHours).then(res => { |
| | | this.totalInfo = res.data |
| | | }) |
| | | let entity = {} |
| | | if(this.entity.week1&&this.entity.week2){ |
| | | entity.week = JSON.stringify([this.entity.week1,this.entity.week2]) |
| | | }else{ |
| | | entity.week = '' |
| | | } |
| | | if(this.entity.dateTime){ |
| | | entity.dateTime = JSON.stringify(this.entity.dateTime) |
| | | }else{ |
| | | entity.dateTime = '' |
| | | } |
| | | entity.weekDay = this.entity.weekDay |
| | | entity.name = this.entity.name |
| | | this.$axios.post(this.$api.auxiliaryOutputWorkingHours.collectWorkingHours,{ |
| | | entity:entity |
| | | }, { |
| | | headers: { |
| | | 'Content-Type': 'application/json' |
| | | } |
| | | }).then(res => { |
| | | this.totalInfo = res.data |
| | | }) |
| | | }, |
| | | selectshiftByUser(){ |
| | | this.$axios.post(this.$api.auxiliaryWorkingHoursDay.selectshiftByUser).then(res => { |
| | |
| | | height: calc(100% - 60px - 80px - 10px - 40px - 25px); |
| | | padding: 20px; |
| | | } |
| | | >>>.el-dialog__wrapper { |
| | | z-index: 9999 !important; /* 根据需要调整层级 */ |
| | | } |
| | | </style> |
| | |
| | | </div> |
| | | <div class="table"> |
| | | <ValueTable ref="ValueTable0" |
| | | v-if="currentTable == 'value0'" |
| | | v-if="currentTable == 'value0'" :isColumnWidth="true" |
| | | :url="$api.auxiliaryOriginalHours.selectAuxiliaryOriginalHours" |
| | | :componentData="componentData" :key="upIndex" /> |
| | | <ValueTable ref="ValueTable1" |
| | | v-if="currentTable == 'value1'" |
| | | v-if="currentTable == 'value1'" :isColumnWidth="true" |
| | | :url="$api.auxiliaryCorrectionHours.selectAuxiliaryCorrectionHours" |
| | | :inputUrl="$api.auxiliaryCorrectionHours.upload" |
| | | :componentData="componentData0" |
| | |
| | | // 删除公式formItem |
| | | const index = this.domains.indexOf(item) |
| | | if (index !== -1 && this.domains.length > 1) { |
| | | this.$axios.get(this.$api.deviceScope.deleteDataAcquisitionConfiguration + "?id=" + item.id).then(res => { |
| | | if(res.code == 200) { |
| | | this.domains.splice(index, 1) |
| | | } |
| | | }) |
| | | if(item.id){ |
| | | this.$axios.get(this.$api.deviceScope.deleteDataAcquisitionConfiguration + "?id=" + item.id).then(res => { |
| | | if(res.code == 200) { |
| | | this.domains.splice(index, 1) |
| | | } |
| | | }) |
| | | } else { |
| | | this.domains.splice(index, 1) |
| | | } |
| | | } else { |
| | | this.$message.error('不允许删除最后一条数据!'); |
| | | } |
| | |
| | | :summary-method="getSummaries" :row-class-name="tableRowClassName" :row-key="record=>record.id" |
| | | :current-row-key="data.currentId" :highlight-current-row="data.highlight===undefined||data.highlight" |
| | | :span-method="spanMethod" :key="specialKey"> |
| | | <el-table-column type="selection" width="65" v-if="data.showSelect" :key="Math.random()"> |
| | | <el-table-column type="selection" :width="selectionWidth" v-if="data.showSelect" :key="Math.random()"> |
| | | </el-table-column> |
| | | <el-table-column type="index" align="center" label="序号" width="65" v-if="data.isIndex" :key="Math.random()"> |
| | | <el-table-column type="index" align="center" label="序号" :width="selectionWidth" v-if="data.isIndex" :key="Math.random()"> |
| | | </el-table-column> |
| | | <el-table-column :prop="a.label" :label="a.value" :sortable="data.sort==false?false:'custom'" |
| | | v-for="(a, ai) in tableHead" :key="ai" show-overflow-tooltip min-width="155" v-if="!data.headNoShow||(data.headNoShow&&data.headNoShow.length==0)||(data.headNoShow&&data.headNoShow.length>0&&!data.headNoShow.find(d=>d==a.label))"> |
| | | <el-table-column :prop="a.label" :label="a.value" :sortable="data.sort==false?false:'custom'" :isColumnWidth="isColumnWidth" :width="a.width" |
| | | v-for="(a, ai) in tableHead" :key="ai" show-overflow-tooltip :min-width="columnMinWidth" v-if="!data.headNoShow||(data.headNoShow&&data.headNoShow.length==0)||(data.headNoShow&&data.headNoShow.length>0&&!data.headNoShow.find(d=>d==a.label))"> |
| | | <template slot-scope="scope"> |
| | | <div v-if="showType(a.label, data.tagField) != null"> |
| | | <template v-if="typeof(scope.row[a.label]) == 'object'"> |
| | |
| | | } from 'jquery'; |
| | | export default { |
| | | props: { |
| | | selectionWidth: { |
| | | type: String, |
| | | default: () => '65' |
| | | }, |
| | | columnMinWidth: { |
| | | type: String, |
| | | default: () => '155' |
| | | }, |
| | | isColumnWidth: { |
| | | type: Boolean, |
| | | default: () => false |
| | | }, |
| | | tableRowClassName: { |
| | | type: Function |
| | | }, |
| | |
| | | this.selectList('page') |
| | | }, |
| | | selectList(val) { |
| | | console.log('val---', val) |
| | | console.log('this.page---', this.page) |
| | | this.loading = true |
| | | if(val===undefined){ |
| | | this.page.current = 1; |
| | | } |
| | | if (val === 'lastPage') { |
| | | this.page.current = this.page.current - 1 // 例如删除本页最后一条数据,将当前页面定为上一页,除第一页外 |
| | | } |
| | | if (this.data.isPage != undefined && this.data.isPage != true) { |
| | | this.page = { |
| | |
| | | this.total = res.data.body.total |
| | | this.tableHead = res.data.head |
| | | this.tableData = res.data.body.records |
| | | if (this.tableData.length === 0 && this.page.current > 1) { |
| | | this.selectList('lastPage') |
| | | } |
| | | if (this.isColumnWidth) { |
| | | this.tableHead.forEach(item => { |
| | | if (item.value.length === 4) { |
| | | item.width = 120 |
| | | } else if (item.value.length === 3){ |
| | | item.width = 100 |
| | | } else if (item.value.length === 5){ |
| | | item.width = 130 |
| | | } else if (item.value.length === 7){ |
| | | item.width = 160 |
| | | } else if (item.value.length === 6){ |
| | | item.width = 150 |
| | | } else { |
| | | item.width = 86 |
| | | } |
| | | }) |
| | | } |
| | | // console.log(JSON.stringify(this.tableHead)+"---------"+JSON.stringify(this.tableData)) |
| | | for (var a in this.data.selectField) { |
| | | if (this.data.selectField[a].choose == true) { |
| | |
| | | return |
| | | } |
| | | this.$message.success('删除成功') |
| | | this.selectList() |
| | | this.selectList('page') |
| | | this.$emit('delete') |
| | | }).catch(e => { |
| | | this.$message.error('删除失败') |
| | |
| | | } |
| | | this.$message.success('修改成功') |
| | | this.upDia = false |
| | | this.selectList() |
| | | this.selectList('page') |
| | | this.$refs.eltable.doLayout(); |
| | | this.upLoad = false |
| | | }).catch(e => { |
| | |
| | | } |
| | | this.$message.success('添加成功') |
| | | this.addDia = false |
| | | this.selectList() |
| | | this.selectList('page') |
| | | this.addLoad = false |
| | | }).catch(e => { |
| | | this.addDia = false |
| | |
| | | this.$message.error('请选择要删除的数据') |
| | | } |
| | | }, |
| | | // 日工时管理辅助工时--批量审核和批准 |
| | | batchCheck(e) { |
| | | if (this.multipleSelection && this.multipleSelection.length > 0) { |
| | | const list = JSON.parse(JSON.stringify(this.multipleSelection)) |
| | | const url = e === 0 ? this.$api.auxiliaryWorkingHoursDay.check : this.$api.auxiliaryWorkingHoursDay.approve |
| | | const state = e === 0 ? '已审核' : '已批准' |
| | | list.forEach(item => { |
| | | this.$axios.post(url, {id: item.id, state: state |
| | | },{ |
| | | headers: { |
| | | 'Content-Type': 'application/json' |
| | | } |
| | | } |
| | | ).then(res => { |
| | | if (res.code === 201) { |
| | | return |
| | | } |
| | | this.$parent.submitBatchCheckDialog() |
| | | this.$message.success('操作成功') |
| | | }) |
| | | }) |
| | | } else { |
| | | this.$message.error('请选择至少一条数据') |
| | | } |
| | | }, |
| | | getRedColor(label,row){ |
| | | if(this.data.cellSpecialStyle&&this.data.cellSpecialStyle.redColorByKey&&label.includes(this.data.cellSpecialStyle.redColorByKey)&&row[(label.replace(this.data.cellSpecialStyle.redColorByKey, ""))]){ |
| | | return true |
| | |
| | | </el-date-picker> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing"> |
| | | <div class="search_thing" style="width: 340px"> |
| | | <div class="search_label">委托单位:</div> |
| | | <div class="search_input"><el-input size="small" placeholder="请输入" clearable |
| | | v-model="componentData.entity.company" @keyup.enter.native="refreshTable()"></el-input></div> |
| | | <div class="search_input"> |
| | | <!-- <el-input size="small" placeholder="请输入" clearable--> |
| | | <!-- @keyup.enter.native="refreshTable()"></el-input>--> |
| | | <el-select @focus="getCompanyOptions" @change="refreshTable()" clearable |
| | | size="small" v-model="componentData.entity.company" style="width: 100%"> |
| | | <el-option v-for="item in companyOptions" :key="item.value" |
| | | :label="item.label" :value="item.value"> |
| | | </el-option> |
| | | </el-select> |
| | | </div> |
| | | </div> |
| | | <div class="search_thing" style="padding-left: 30px;"> |
| | | <el-button size="small" @click="refresh()">重 置</el-button> |
| | |
| | | </div> |
| | | <div class="table"> |
| | | <ValueTable ref="ValueTable" :url="$api.insOrder.costStatistics" :componentData="componentData" :key="upIndex" |
| | | @handleWeave="handleWeave" /> |
| | | @handleWeave="handleWeave" :column-min-width="'140'"/> |
| | | </div> |
| | | </div> |
| | | <el-dialog title="在线编制" :visible.sync="claimVisible" width="70%" :modal-append-to-body="false"> |
| | |
| | | claimVisible: false, |
| | | dates: [], |
| | | index2: 0, |
| | | total: 0 |
| | | total: 0, |
| | | companyOptions: [], // 委托单位枚举值 |
| | | entity: { |
| | | orderBy: { |
| | | field: 'id', |
| | | order: 'asc' |
| | | } |
| | | }, |
| | | page: { |
| | | current: -1, |
| | | size: -1, |
| | | }, |
| | | } |
| | | }, |
| | | mounted() { |
| | |
| | | this.index2++ |
| | | this.componentData.entity.dates = `["${startDate}","${endDate}"]` |
| | | }, |
| | | getCompanyOptions () { |
| | | this.$axios.post(this.$api.user.selectCustomPageList, { |
| | | page: this.page, |
| | | entity: this.entity |
| | | }, { |
| | | headers: { |
| | | 'Content-Type': 'application/json' |
| | | } |
| | | } |
| | | ).then(res => { |
| | | if (res.code === 200) { |
| | | const list = res.data.body.records |
| | | this.companyOptions = [] |
| | | list.map((item) => { |
| | | const obj = Object.assign({ |
| | | value: item.id, |
| | | label: item.company, |
| | | }) |
| | | this.companyOptions.push(obj) |
| | | }) |
| | | } |
| | | }).catch(e => { |
| | | this.$message.error('查询失败') |
| | | }) |
| | | }, |
| | | refreshTable() { |
| | | this.$refs['ValueTable'].selectList() |
| | | this.getTotal() |
| | |
| | | this.loading = false; |
| | | this.$message.success("认领成功") |
| | | this.claimVisible = false |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | } |
| | | }).catch(error => { |
| | | console.error(error) |
| | | this.loading = false; |
| | | }) |
| | | }, |
| | | refreshTable() { |
| | | this.$refs.insOrderPlan.selectList() |
| | | refreshTable(e) { |
| | | this.$refs.insOrderPlan.selectList(e) |
| | | }, |
| | | changeRowClass({ |
| | | row, |
| | |
| | | }, |
| | | goback() { |
| | | this.state = 0 |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | }, |
| | | handleInspection(row){ |
| | | this.state = 1; |
| | |
| | | if (res.code === 200) { |
| | | this.loading = false; |
| | | this.$message.success("操作成功") |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | } |
| | | this.connectVisible = false |
| | | }).catch(error => { |
| | |
| | | |
| | | <template> |
| | | <div class="inspection_order"> |
| | | <div style="width: 100%;height: 100%;" v-if="active == 0"> |
| | | <div style="width: 100%;height: 100%;" v-show="active == 0"> |
| | | <div> |
| | | <el-row class="title"> |
| | | <el-col :span="12" style="padding-left: 20px;text-align: left;">检验下单</el-col> |
| | |
| | | this.personList = data |
| | | }) |
| | | }, |
| | | refreshTable() { |
| | | this.$refs['ValueTable'].selectList() |
| | | refreshTable(e) { |
| | | this.$refs['ValueTable'].selectList(e) |
| | | }, |
| | | refresh() { |
| | | this.componentData.entity = this.HaveJson(this.entityCopy) |
| | |
| | | this.$message.success('修改成功') |
| | | this.upLoad = false |
| | | this.issuedDialogVisible = false |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | }).catch(e => { |
| | | this.$message.error('修改失败') |
| | | this.upLoad = false |
| | |
| | | if (res.code===200){ |
| | | this.upLoad=false |
| | | this.quashDialogVisible=false |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | this.$message.success("更新成功") |
| | | } |
| | | }) |
| | |
| | | if (res.code===200){ |
| | | this.upLoad = false |
| | | this.quashDialogVisible = false |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | this.$message.success("更新成功") |
| | | } |
| | | }) |
| | |
| | | // 下单 |
| | | playOrder(num) { |
| | | this.active = num |
| | | this.refreshTable('page') |
| | | }, |
| | | handleTab(m, i) { |
| | | this.tabIndex = i; |
| | |
| | | // } |
| | | }, |
| | | methods: { |
| | | refreshTable() { |
| | | this.$refs['ValueTable'].selectList() |
| | | refreshTable(e) { |
| | | this.$refs['ValueTable'].selectList(e) |
| | | }, |
| | | refresh() { |
| | | this.componentData.entity = this.HaveJson(this.entityCopy) |
| | |
| | | document.body.appendChild(link); |
| | | link.click(); |
| | | }, |
| | | // 还原操作 |
| | | handleRestore(row) { |
| | | this.$axios.post(this.$api.insReport.upReportUrl, { |
| | | id: row.id |
| | | }).then(res => { |
| | | if (res.code === 200) { |
| | | this.$message.success('操作成功') |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | } |
| | | }) |
| | | }, |
| | |
| | | } |
| | | this.issuedVisible = true; |
| | | }, |
| | | // 审核通过 |
| | | subIssued() { |
| | | this.loadingIssued = true; |
| | | this.$axios.post(this.$api.insReport.examineReport, { |
| | |
| | | return |
| | | } |
| | | this.$message.success('提交成功') |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | this.currentInfo = null; |
| | | this.issuedVisible = false; |
| | | }).catch(e => { |
| | |
| | | } |
| | | this.approveVisible = true; |
| | | }, |
| | | // 批准通过 |
| | | subApprove() { |
| | | this.loadingApprove = true; |
| | | this.$axios.post(this.$api.insReport.ratifyReport, { |
| | |
| | | return |
| | | } |
| | | this.$message.success('已批准') |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | this.currentInfo = null; |
| | | this.approveVisible = false; |
| | | }) |
| | | }, |
| | | // 提交操作 |
| | | handleSubmit(row) { |
| | | this.$confirm('是否提交当前报告?', "提交", { |
| | | confirmButtonText: "提交", |
| | |
| | | return |
| | | } |
| | | this.$message.success('提交成功') |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | }).catch(e => { |
| | | this.$message.error('提交失败') |
| | | }) |
| | | }).catch(() => {}) |
| | | }, |
| | | // 审核不通过原因提交 |
| | | handleIssuedReason() { |
| | | if (!this.reason) { |
| | | return this.$message.error('请输入原因') |
| | |
| | | return |
| | | } |
| | | this.$message.success('操作成功') |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | this.currentInfo = null; |
| | | this.reason = ''; |
| | | this.issuedVisible = false; |
| | |
| | | this.loadingIssuedReason = false; |
| | | }) |
| | | }, |
| | | // 不批准原因提交 |
| | | handleApproveReason() { |
| | | if (!this.reason) { |
| | | return this.$message.error('请输入原因') |
| | |
| | | return |
| | | } |
| | | this.$message.success('操作成功') |
| | | this.refreshTable() |
| | | this.refreshTable('page') |
| | | this.currentInfo = null; |
| | | this.reason = ''; |
| | | this.issuedVisible = false; |
| | |
| | | // window.excelExport = this.excelExport |
| | | }, |
| | | methods: { |
| | | refreshTable() { |
| | | this.$refs['ValueTable'].selectList() |
| | | refreshTable(e) { |
| | | this.$refs['ValueTable'].selectList(e) |
| | | }, |
| | | refresh() { |
| | | this.componentData.entity = this.HaveJson(this.entityCopy) |