|
@@ -40,7 +40,7 @@
|
|
|
</template>
|
|
</template>
|
|
|
|
|
|
|
|
<script>
|
|
<script>
|
|
|
- import { approveTaskWithVariables } from '@/api/bpm/task';
|
|
|
|
|
|
|
+import {approveTaskWithVariables, rejectTask} from '@/api/bpm/task';
|
|
|
import { deviceNotPass, batchUpdate } from '@/api/bpm/components/bomApprover';
|
|
import { deviceNotPass, batchUpdate } from '@/api/bpm/components/bomApprover';
|
|
|
|
|
|
|
|
|
|
|
|
@@ -79,14 +79,15 @@
|
|
|
},
|
|
},
|
|
|
async _approveTaskWithVariables(status) {
|
|
async _approveTaskWithVariables(status) {
|
|
|
if (status == 1) {
|
|
if (status == 1) {
|
|
|
- approveTaskWithVariables({
|
|
|
|
|
|
|
+ let API = !!status ? approveTaskWithVariables : rejectTask;
|
|
|
|
|
+ API({
|
|
|
businessId: this.businessId,
|
|
businessId: this.businessId,
|
|
|
id: this.taskId,
|
|
id: this.taskId,
|
|
|
reason: this.form.reason,
|
|
reason: this.form.reason,
|
|
|
variables: { pass: true }
|
|
variables: { pass: true }
|
|
|
}).then((res) => {
|
|
}).then((res) => {
|
|
|
if (res.data.code != '-1') {
|
|
if (res.data.code != '-1') {
|
|
|
-
|
|
|
|
|
|
|
+
|
|
|
this.updateDate()
|
|
this.updateDate()
|
|
|
|
|
|
|
|
this.$emit('handleAudit', {
|
|
this.$emit('handleAudit', {
|