|
|
@@ -64,6 +64,12 @@
|
|
|
</el-table-column>
|
|
|
<el-table-column prop="sourceDesc" label="来源说明" min-width="160" show-overflow-tooltip />
|
|
|
<el-table-column prop="createdAt" label="入账时间" min-width="160" />
|
|
|
+ <el-table-column label="操作" width="170" align="center">
|
|
|
+ <template slot-scope="{ row }">
|
|
|
+ <el-button type="text" size="mini" :loading="row._disposing" @click="restoreLedger(row)">恢复生效</el-button>
|
|
|
+ <el-button type="text" size="mini" class="reject-btn" :loading="row._disposing" @click="vetoLedger(row)">否决学时</el-button>
|
|
|
+ </template>
|
|
|
+ </el-table-column>
|
|
|
</el-table>
|
|
|
</div>
|
|
|
|
|
|
@@ -100,7 +106,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { creditAccountList, creditLedgerDetail, creditObjectedList, creditLedgerPending, creditScan } from '@/api/credit'
|
|
|
+import { creditAccountList, creditLedgerDetail, creditObjectedList, creditObjectedDispose, creditLedgerPending, creditScan } from '@/api/credit'
|
|
|
import CreditLedgerTable from '@/components/CreditLedgerTable.vue'
|
|
|
|
|
|
export default {
|
|
|
@@ -223,6 +229,36 @@ export default {
|
|
|
self.scanResult = null
|
|
|
})
|
|
|
}).catch(function () {})
|
|
|
+ },
|
|
|
+ // 恢复生效:驳回异议,学时有效
|
|
|
+ restoreLedger: function (row) {
|
|
|
+ var self = this
|
|
|
+ if (row._disposing) return
|
|
|
+ row._disposing = true
|
|
|
+ creditObjectedDispose({ id: row.ledgerId, approved: true }).then(function () {
|
|
|
+ row._disposing = false
|
|
|
+ self.$message.success('已驳回异议,学时恢复生效')
|
|
|
+ self.reload()
|
|
|
+ }).catch(function (e) {
|
|
|
+ row._disposing = false
|
|
|
+ self.$message.error((e && e.message) || '处置失败')
|
|
|
+ })
|
|
|
+ },
|
|
|
+ // 否决学时:同意异议,学时作废
|
|
|
+ vetoLedger: function (row) {
|
|
|
+ var self = this
|
|
|
+ if (row._disposing) return
|
|
|
+ this.$confirm('将否决该异议并作废学时,不可恢复', '提示', { type: 'warning' }).then(function () {
|
|
|
+ row._disposing = true
|
|
|
+ creditObjectedDispose({ id: row.ledgerId, approved: false }).then(function () {
|
|
|
+ row._disposing = false
|
|
|
+ self.$message.success('已同意异议,学时作废')
|
|
|
+ self.reload()
|
|
|
+ }).catch(function (e) {
|
|
|
+ row._disposing = false
|
|
|
+ self.$message.error((e && e.message) || '处置失败')
|
|
|
+ })
|
|
|
+ }).catch(function () {})
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
@@ -311,6 +347,13 @@ export default {
|
|
|
font-size: 13px;
|
|
|
color: #6B7B8C;
|
|
|
}
|
|
|
+.reject-btn {
|
|
|
+ color: #C0392B;
|
|
|
+}
|
|
|
+.reject-btn:hover {
|
|
|
+ color: #C0392B;
|
|
|
+ opacity: .85;
|
|
|
+}
|
|
|
.drawer-body {
|
|
|
padding: 0 20px 20px;
|
|
|
}
|