Merge branch 'master' of http://gitea.xxhhcty.xyz:8080/zcdsj/factory_web
This commit is contained in:
commit
48fd229a69
|
|
@ -69,7 +69,7 @@
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<script setup>
|
<script setup>
|
||||||
import { ref, defineProps, defineEmits, computed, onMounted } from "vue";
|
import { ref, defineProps, defineEmits, computed, onMounted, watch } from "vue";
|
||||||
|
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
multiple: { type: Boolean, default: false },
|
multiple: { type: Boolean, default: false },
|
||||||
|
|
@ -103,8 +103,25 @@ onMounted(() => {
|
||||||
tableData.value = props.options;
|
tableData.value = props.options;
|
||||||
hidePagination.value = true;
|
hidePagination.value = true;
|
||||||
}
|
}
|
||||||
|
watch(
|
||||||
|
() => props.label,
|
||||||
|
async (newVal) => {
|
||||||
|
init()
|
||||||
|
},
|
||||||
|
{ deep: true, immediate: true }
|
||||||
|
);
|
||||||
|
watch(
|
||||||
|
() => props.modelValue,
|
||||||
|
async (newVal) => {
|
||||||
|
init()
|
||||||
|
},
|
||||||
|
{ deep: true, immediate: true }
|
||||||
|
)
|
||||||
|
|
||||||
if (props.label) {
|
});
|
||||||
|
|
||||||
|
const init = () => {
|
||||||
|
if (props.label) {
|
||||||
selectLabel.value = props.label;
|
selectLabel.value = props.label;
|
||||||
} else {
|
} else {
|
||||||
if (props.multiple) {
|
if (props.multiple) {
|
||||||
|
|
@ -133,7 +150,7 @@ onMounted(() => {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
});
|
}
|
||||||
|
|
||||||
const isFixOptions = ref(false);
|
const isFixOptions = ref(false);
|
||||||
const tableData = ref(null);
|
const tableData = ref(null);
|
||||||
|
|
|
||||||
|
|
@ -105,7 +105,7 @@
|
||||||
</scTable>
|
</scTable>
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
<el-drawer :title="titleMap[type] " v-model="limitedVisible" size="50%">
|
<el-drawer :title="titleMap " v-model="limitedVisible" size="50%">
|
||||||
<el-form
|
<el-form
|
||||||
:model="addForm"
|
:model="addForm"
|
||||||
:rules="rules"
|
:rules="rules"
|
||||||
|
|
@ -152,24 +152,14 @@ export default {
|
||||||
name: "index",
|
name: "index",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
workflowName:"",
|
|
||||||
workFlowId:'',
|
|
||||||
apiObj: this.$API.ofm.filerecord.list,
|
apiObj: this.$API.ofm.filerecord.list,
|
||||||
selection: [],
|
|
||||||
checkList: [],
|
|
||||||
transitions:[],
|
|
||||||
timeRange: [],
|
|
||||||
query: {},
|
query: {},
|
||||||
editId: null,
|
editId: null,
|
||||||
isSaving: false,
|
isSaving: false,
|
||||||
limitedVisible: false,
|
limitedVisible: false,
|
||||||
limitedWatch: false,
|
limitedWatch: false,
|
||||||
type: "add",
|
type: "add",
|
||||||
titleMap: {
|
titleMap:"档案管理",
|
||||||
add: "新增",
|
|
||||||
edit: "编辑",
|
|
||||||
show: "查看",
|
|
||||||
},
|
|
||||||
//表单数据
|
//表单数据
|
||||||
addForm: {
|
addForm: {
|
||||||
name: null,
|
name: null,
|
||||||
|
|
@ -188,16 +178,8 @@ export default {
|
||||||
this.addForm = this.getDefaultForm();
|
this.addForm = this.getDefaultForm();
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
},
|
},
|
||||||
handleAdd_outer() {
|
|
||||||
this.addForm = this.getDefaultForm();
|
|
||||||
this.type = "add";
|
|
||||||
this.limitedVisible = true;
|
|
||||||
this.lending_type = "outer";
|
|
||||||
this.addForm.is_lending = true;
|
|
||||||
},
|
|
||||||
handleCancel() {
|
handleCancel() {
|
||||||
this.limitedVisible = false; // 关闭弹窗
|
this.limitedVisible = false; // 关闭弹窗
|
||||||
this.lending_type = ""; // 重置 lending_type
|
|
||||||
this.getDefaultForm()// 清空表单
|
this.getDefaultForm()// 清空表单
|
||||||
},
|
},
|
||||||
submitHandle() {
|
submitHandle() {
|
||||||
|
|
@ -260,54 +242,4 @@ export default {
|
||||||
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
|
||||||
.treeMain {
|
|
||||||
height: 280px;
|
|
||||||
overflow: auto;
|
|
||||||
border: 1px solid #dcdfe6;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar {
|
|
||||||
width: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-track {
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.2);
|
|
||||||
background-color: #fefefe;
|
|
||||||
border-radius: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-thumb {
|
|
||||||
border-radius: 5px;
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
|
|
||||||
background-color: #f5f5f5;
|
|
||||||
}
|
|
||||||
.node rect {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.edgePath path {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #333;
|
|
||||||
stroke-width: 1.5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
g.conditions > rect {
|
|
||||||
fill: #00ffd0;
|
|
||||||
stroke: #000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.el-icon-close {
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel-group {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 6px; /* 按钮之间的间隙,可以调小点 */
|
|
||||||
margin-left: 0; /* 靠左 */
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,89 +0,0 @@
|
||||||
<template>
|
|
||||||
<el-container>
|
|
||||||
<el-main>
|
|
||||||
<el-form
|
|
||||||
:model="addForm"
|
|
||||||
:rules="rules"
|
|
||||||
ref="addForm"
|
|
||||||
label-width="100px"
|
|
||||||
label-position="left"
|
|
||||||
>
|
|
||||||
<el-form-item label="资料名称" prop="name">
|
|
||||||
<el-input v-model="addForm.name" clearable :disabled="mode==='view'"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="档案编号" prop="number">
|
|
||||||
<el-input v-model="addForm.number" clearable :disabled="mode==='view'"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="文件份数" prop="counts">
|
|
||||||
<el-input v-model="addForm.counts" clearable :disabled="mode==='view'"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="存放位置" prop="location">
|
|
||||||
<el-input v-model="addForm.location" clearable :disabled="mode==='view'"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="存档人电话" prop="contacts">
|
|
||||||
<el-input v-model="addForm.contacts" clearable :disabled="mode==='view'"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="接收人(综合办)" prop="reciver" label-width="120px">
|
|
||||||
<el-input v-model="addForm.reciver" clearable :disabled="mode==='view'"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="备注" prop="remark" type="textarea">
|
|
||||||
<el-input v-model="addForm.remark" clearable :disabled="mode==='view'"></el-input>
|
|
||||||
</el-form-item>
|
|
||||||
</el-form>
|
|
||||||
<el-footer v-show="mode!=='show'">
|
|
||||||
<ticketd_b
|
|
||||||
:workflow_key="'borrowrecord'"
|
|
||||||
:title="ticketTitle"
|
|
||||||
:t_id="addForm.id"
|
|
||||||
:ticket_="addForm.ticket_"
|
|
||||||
:submit_b_func="submit_b_func"
|
|
||||||
:ticket_data="ticket_data"
|
|
||||||
ref="ticketd_b"
|
|
||||||
@success="$emit('success')"
|
|
||||||
@colsed="$emit('closed')"
|
|
||||||
/>
|
|
||||||
</el-footer>
|
|
||||||
</el-main>
|
|
||||||
<el-aside width="20%" v-if="addForm.ticket_">
|
|
||||||
<ticketd ::ticket_="addForm.ticket_" @success="$emit('success')"></ticketd>
|
|
||||||
</el-aside>
|
|
||||||
</el-container>
|
|
||||||
</template>
|
|
||||||
|
|
||||||
<script>
|
|
||||||
import ticketd_b from "@/views/wf/ticketd_b.vue";
|
|
||||||
import ticketd from '@/views/wf/ticketd.vue'
|
|
||||||
export default {
|
|
||||||
props: {
|
|
||||||
mode: { type: String, default: "view" }, // add / edit / view
|
|
||||||
modelValue: { type: Object, default: () => ({}) },
|
|
||||||
transitions: { type: Array, default: () => [] },
|
|
||||||
},
|
|
||||||
components: {ticketd, ticketd_b},
|
|
||||||
emits: ["update:modelValue", "submit", "cancel"],
|
|
||||||
data(){
|
|
||||||
return {
|
|
||||||
addForm: { ...this.modelValue },
|
|
||||||
ticketTitle: "档案申请",
|
|
||||||
rules:{
|
|
||||||
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
|
||||||
},
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods:{
|
|
||||||
async submit_b_func() {
|
|
||||||
let that = this;
|
|
||||||
|
|
||||||
this.ticketTitle = `${this.addForm.name}-档案申请`
|
|
||||||
if(that.mode == "add") {
|
|
||||||
let res = await that.$API.ofm.filerecord.create.req(that.addForm);
|
|
||||||
|
|
||||||
that.addForm.id = res.id;
|
|
||||||
} else if (that.mode == "edit") {
|
|
||||||
await that.$API.ofm.filerecord.update.req(that.addForm.id, that.addForm);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
},
|
|
||||||
}
|
|
||||||
</script>
|
|
||||||
|
|
||||||
|
|
@ -6,7 +6,6 @@
|
||||||
type="primary"
|
type="primary"
|
||||||
icon="el-icon-plus"
|
icon="el-icon-plus"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-auth="'fileborrow.create'"
|
|
||||||
></el-button>
|
></el-button>
|
||||||
</div>
|
</div>
|
||||||
<div class="right-panel">
|
<div class="right-panel">
|
||||||
|
|
@ -61,23 +60,22 @@
|
||||||
prop="return_date"
|
prop="return_date"
|
||||||
min-width="100"
|
min-width="100"
|
||||||
></el-table-column>
|
></el-table-column>
|
||||||
<el-table-column label="所在节点" min-width="60">
|
<el-table-column label="审批信息" width="200">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
{{scope.row.ticket_.state_.name}}
|
<el-tag :type="actStateEnum[scope.row.ticket_?.act_state]?.type">
|
||||||
|
{{ actStateEnum[scope.row.ticket_?.act_state]?.text }}
|
||||||
|
</el-tag>
|
||||||
|
<el-tag type="info" effect="plain">{{ scope.row.ticket_?.state_.name }}</el-tag>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="进行状态" min-width="60">
|
|
||||||
<template #default="scope">
|
|
||||||
{{statusOptions[scope.row.ticket_.state_.type]}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作" fixed="right" align="center" width="250">
|
<el-table-column label="操作" fixed="right" align="center" width="250">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
link
|
link
|
||||||
size="small"
|
size="small"
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="borrowEidt(scope.row)"
|
@click="borrowShow(scope.row)"
|
||||||
v-auth="'fileborrow.update'"
|
v-auth="'fileborrow.update'"
|
||||||
>详情
|
>详情
|
||||||
</el-button>
|
</el-button>
|
||||||
|
|
@ -100,16 +98,18 @@
|
||||||
</scTable>
|
</scTable>
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
<el-drawer :title="titleMap[type] "
|
<el-drawer
|
||||||
|
title="档案管理"
|
||||||
v-model="limitedVisible"
|
v-model="limitedVisible"
|
||||||
|
:destroy-on-close="true"
|
||||||
direction="rtl"
|
direction="rtl"
|
||||||
size="70%">
|
size="70%">
|
||||||
|
|
||||||
<div style="display: flex; height: calc(100% - 60px);">
|
<div style="display: flex; height: calc(100% - 60px);">
|
||||||
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
||||||
<borrowlForm
|
<borrowlForm
|
||||||
:mode="type"
|
:mode="mode"
|
||||||
v-model="addForm"
|
:t_id="t_id"
|
||||||
@success="()=>{handleQuery(); limitedVisible = false}"
|
@success="()=>{handleQuery(); limitedVisible = false}"
|
||||||
@closed="limitedVisible = false"
|
@closed="limitedVisible = false"
|
||||||
/>
|
/>
|
||||||
|
|
@ -120,102 +120,37 @@
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
import borrowlForm from "./borrowfile_form.vue";
|
import borrowlForm from "./borrowfile_form.vue";
|
||||||
|
import { actStateEnum, interveneTypeEnum } from "@/utils/enum.js";
|
||||||
export default {
|
export default {
|
||||||
components: { borrowlForm },
|
components: { borrowlForm },
|
||||||
name: "index",
|
name: "index",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
workflowName:"",
|
actStateEnum, interveneTypeEnum,
|
||||||
workFlowId:'',
|
|
||||||
apiObj: this.$API.ofm.borrow.list,
|
apiObj: this.$API.ofm.borrow.list,
|
||||||
selection: [],
|
|
||||||
checkList: [],
|
|
||||||
fileList: [],
|
|
||||||
transitions:[],
|
|
||||||
timeRange: [],
|
|
||||||
query: {},
|
query: {},
|
||||||
editId: null,
|
|
||||||
isSaving: false,
|
|
||||||
limitedVisible: false,
|
limitedVisible: false,
|
||||||
limitedWatch: false,
|
mode: "show",
|
||||||
type: "add",
|
t_id: null,
|
||||||
titleMap: {
|
|
||||||
add: "新增",
|
|
||||||
edit: "编辑",
|
|
||||||
show: "查看",
|
|
||||||
},
|
|
||||||
statusOptions:{
|
|
||||||
0: "审批中",
|
|
||||||
1: "初始中",
|
|
||||||
2: "已完成",
|
|
||||||
},
|
|
||||||
//表单数据
|
|
||||||
addForm: {
|
|
||||||
borrow_file: [],
|
|
||||||
number: null,
|
|
||||||
counts: null,
|
|
||||||
location: null,
|
|
||||||
contacts: null,
|
|
||||||
ticket_: null,
|
|
||||||
reciver: "",
|
|
||||||
remark: [],
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted(){
|
|
||||||
let that = this;
|
|
||||||
that.getInit();
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
getInit() {
|
|
||||||
let that = this;
|
|
||||||
if(this.addForm.ticket_!==null){
|
|
||||||
this.$API.wf.ticket_.ticketTransitions.req(this.addForm.ticket_).then((res) => {
|
|
||||||
that.transitions = res;
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
that.$API.wf.workflow.initkey.req("borrowrecord").then((res) => {
|
|
||||||
that.initForm = res;
|
|
||||||
that.transitions = res.transitions;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.type = "add";
|
this.mode = "add";
|
||||||
this.addForm = this.getDefaultForm();
|
this.t_id = null;
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
},
|
},
|
||||||
|
borrowShow(row) {
|
||||||
|
this.mode = "show";
|
||||||
getDefaultForm(){
|
this.t_id = row.id;
|
||||||
return {
|
|
||||||
borrow_file: [],
|
|
||||||
number: null,
|
|
||||||
counts: null,
|
|
||||||
location: null,
|
|
||||||
contacts: null,
|
|
||||||
ticket_:null,
|
|
||||||
reciver: "",
|
|
||||||
remark: [],
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 审批流结束之后才可以编辑
|
|
||||||
borrowEidt(row) {
|
|
||||||
this.type = "view";
|
|
||||||
this.editId = row.id;
|
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
this.addForm = Object.assign({}, row);
|
|
||||||
},
|
},
|
||||||
async borrowDel(row) {
|
async borrowDel(row) {
|
||||||
var id = row.id;
|
var id = row.id;
|
||||||
var res = await this.$API.ofm.borrow.delete.req(id);
|
var res = await this.$API.ofm.borrow.delete.req(id);
|
||||||
if (res.err_msg) {
|
this.$refs.table.refresh();
|
||||||
this.$message.error(res.err_msg);
|
this.$message.success("删除成功");
|
||||||
} else {
|
|
||||||
this.$refs.table.refresh();
|
|
||||||
this.$message.success("删除成功");
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
//搜索
|
//搜索
|
||||||
handleQuery() {
|
handleQuery() {
|
||||||
|
|
|
||||||
|
|
@ -9,17 +9,21 @@
|
||||||
label-position="left"
|
label-position="left"
|
||||||
>
|
>
|
||||||
<el-form-item label="档案名称">
|
<el-form-item label="档案名称">
|
||||||
<el-select v-model="addForm.borrow_file" multiple placeholder="请选择档案" clearable style="width: 300px;">
|
<xtSelect
|
||||||
<el-option
|
:apiObj="apiObjM2"
|
||||||
v-for="item in fileList"
|
:multiple = "true"
|
||||||
:key="item.id"
|
v-model:obj = "addForm.borrow_file_"
|
||||||
:value="item.id"
|
v-model = "addForm.borrow_file"
|
||||||
:disabled="localMode ==='view'"
|
style="width: 300px;"
|
||||||
:label="item.name"></el-option>
|
placeholder="选择档案名称"
|
||||||
</el-select>
|
>
|
||||||
|
<el-table-column label="档案编号" prop="number"></el-table-column>
|
||||||
|
<el-table-column label="档案名称" prop="name"></el-table-column>
|
||||||
|
</xtSelect>
|
||||||
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="申请人电话" prop="contacts">
|
<el-form-item label="申请人电话" prop="contacts">
|
||||||
<el-input v-model="addForm.contacts" clearable style="width: 300px;" :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="addForm.contacts" clearable style="width: 300px;" :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="借阅时间" prop="borrow_date">
|
<el-form-item label="借阅时间" prop="borrow_date">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
|
|
@ -28,7 +32,7 @@
|
||||||
placeholder="选择日期时间"
|
placeholder="选择日期时间"
|
||||||
align="right"
|
align="right"
|
||||||
value-format="YYYY-MM-DD"
|
value-format="YYYY-MM-DD"
|
||||||
:disabled="localMode ==='view'"
|
:disabled="localMode ==='show'"
|
||||||
>
|
>
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
@ -42,7 +46,7 @@
|
||||||
>
|
>
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="用途" prop="remark" :disabled="localMode ==='view'">
|
<el-form-item label="用途" prop="remark" :disabled="localMode ==='show'">
|
||||||
<el-checkbox-group v-model="addForm.remark">
|
<el-checkbox-group v-model="addForm.remark">
|
||||||
<el-checkbox label="借阅"></el-checkbox>
|
<el-checkbox label="借阅"></el-checkbox>
|
||||||
<el-checkbox label="复印"></el-checkbox>
|
<el-checkbox label="复印"></el-checkbox>
|
||||||
|
|
@ -51,14 +55,14 @@
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-footer v-show="mode!=='show'">
|
<el-footer>
|
||||||
<ticketd_b
|
<ticketd_b
|
||||||
:workflow_key="'borrowrecord'"
|
:workflow_key="'borrowrecord'"
|
||||||
:title="ticketTitle"
|
:title="ticketTitle"
|
||||||
:t_id="addForm.id"
|
:t_id="addForm.id"
|
||||||
:ticket_="addForm.ticket_"
|
:ticket_="addForm.ticket_"
|
||||||
:ticket_data="ticket_data"
|
:ticket_data="ticket_data"
|
||||||
:submit_b_func="submit"
|
:submit_b_func="submit_b_func"
|
||||||
ref="ticketd_b"
|
ref="ticketd_b"
|
||||||
@success="$emit('success')"
|
@success="$emit('success')"
|
||||||
/>
|
/>
|
||||||
|
|
@ -81,12 +85,10 @@ import ticketd_b from "@/views/wf/ticketd_b.vue";
|
||||||
import ticketd from "@/views/wf/ticketd.vue";
|
import ticketd from "@/views/wf/ticketd.vue";
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "index",
|
|
||||||
props: {
|
props: {
|
||||||
mode: {
|
mode: {
|
||||||
type: String, default: "view"
|
type: String, default: "show"
|
||||||
},
|
},
|
||||||
modelValue: { type: Object, default: () => ({}) },
|
|
||||||
t_id: {
|
t_id: {
|
||||||
type: String,
|
type: String,
|
||||||
default: null
|
default: null
|
||||||
|
|
@ -99,14 +101,10 @@ export default {
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
ticketTitle: "档案借阅",
|
ticketTitle: "档案借阅",
|
||||||
addForm: {
|
addForm: {},
|
||||||
ticket_: {
|
|
||||||
state_: { type: '' }
|
|
||||||
},
|
|
||||||
borrow_file: [],
|
|
||||||
...this.modelValue },
|
|
||||||
localMode : this.mode,
|
localMode : this.mode,
|
||||||
query: {},
|
query: {},
|
||||||
|
apiObjM2: this.$API.ofm.filerecord.list,
|
||||||
fileList: [],
|
fileList: [],
|
||||||
ticket_data: {},
|
ticket_data: {},
|
||||||
rules: {
|
rules: {
|
||||||
|
|
@ -117,14 +115,10 @@ export default {
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted(){
|
mounted(){
|
||||||
this.getFileList().then(() => {
|
let that = this;
|
||||||
console.log('fileList:', this.fileList)
|
if (that.t_id){
|
||||||
console.log('addForm.borrow_file:', this.addForm.borrow_file)
|
this.getTid();
|
||||||
});
|
|
||||||
if (this.addForm.ticket_?.state_.type===1){
|
|
||||||
this.localMode = 'edit'
|
|
||||||
};
|
};
|
||||||
this.getTid();
|
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
addForm: {
|
addForm: {
|
||||||
|
|
@ -137,18 +131,13 @@ export default {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async submit() {
|
async submit_b_func() {
|
||||||
let that = this;
|
let that = this;
|
||||||
let res = null;
|
|
||||||
|
|
||||||
if (that.localMode === "add") {
|
if (that.localMode === "add") {
|
||||||
res = await that.$API.ofm.borrow.create.req(that.addForm);
|
let res = await that.$API.ofm.borrow.create.req(that.addForm);
|
||||||
that.addForm.id = res.id;
|
that.addForm.id = res.id;
|
||||||
} else if (that.localMode === "edit") {
|
} else if (that.localMode === "edit") {
|
||||||
res = await that.$API.ofm.borrow.update.req(
|
await that.$API.ofm.borrow.update.req(that.addForm.id, that.addForm);
|
||||||
that.addForm.id,
|
|
||||||
that.addForm
|
|
||||||
);
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
getFileList() {
|
getFileList() {
|
||||||
|
|
@ -173,54 +162,3 @@ export default {
|
||||||
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
|
||||||
.treeMain {
|
|
||||||
height: 280px;
|
|
||||||
overflow: auto;
|
|
||||||
border: 1px solid #dcdfe6;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar {
|
|
||||||
width: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-track {
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.2);
|
|
||||||
background-color: #fefefe;
|
|
||||||
border-radius: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-thumb {
|
|
||||||
border-radius: 5px;
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
|
|
||||||
background-color: #f5f5f5;
|
|
||||||
}
|
|
||||||
.node rect {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.edgePath path {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #333;
|
|
||||||
stroke-width: 1.5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
g.conditions > rect {
|
|
||||||
fill: #00ffd0;
|
|
||||||
stroke: #000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.el-icon-close {
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel-group {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 6px; /* 按钮之间的间隙,可以调小点 */
|
|
||||||
margin-left: 0; /* 靠左 */
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -68,7 +68,7 @@
|
||||||
</el-container>
|
</el-container>
|
||||||
<el-drawer title="会议室预定" v-model="limitedVisible" :size="'80%'" destroy-on-close>
|
<el-drawer title="会议室预定" v-model="limitedVisible" :size="'80%'" destroy-on-close>
|
||||||
<bookingDialog
|
<bookingDialog
|
||||||
v-model="limitedVisible"
|
v-if="limitedVisible"
|
||||||
:mode="mode"
|
:mode="mode"
|
||||||
:t_id="t_id"
|
:t_id="t_id"
|
||||||
:bookingIitem="bookingIitem"
|
:bookingIitem="bookingIitem"
|
||||||
|
|
@ -115,6 +115,8 @@ export default {
|
||||||
//添加
|
//添加
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.mode = "add";
|
this.mode = "add";
|
||||||
|
this.t_id = null;
|
||||||
|
this.bookingIitem = {};
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
},
|
},
|
||||||
handleCancel() {
|
handleCancel() {
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,6 @@
|
||||||
type="primary"
|
type="primary"
|
||||||
icon="el-icon-plus"
|
icon="el-icon-plus"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-auth="'publicity.create'"
|
|
||||||
></el-button>
|
></el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-header>
|
</el-header>
|
||||||
|
|
@ -68,195 +67,88 @@
|
||||||
prop="dept_opinion_review"
|
prop="dept_opinion_review"
|
||||||
min-width="100"
|
min-width="100"
|
||||||
></el-table-column>
|
></el-table-column>
|
||||||
<el-table-column label="所在节点" min-width="60">
|
<el-table-column label="审批信息" width="200">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
{{scope.row.ticket_.state_.name}}
|
<el-tag :type="actStateEnum[scope.row.ticket_?.act_state]?.type">
|
||||||
|
{{ actStateEnum[scope.row.ticket_?.act_state]?.text }}
|
||||||
|
</el-tag>
|
||||||
|
<el-tag type="info" effect="plain">{{ scope.row.ticket_?.state_.name }}</el-tag>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="进行状态" min-width="60">
|
|
||||||
<template #default="scope">
|
|
||||||
{{statusOptions[scope.row.ticket_.state_.type]}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作" fixed="right" align="center" width="250">
|
<el-table-column label="操作" fixed="right" align="center" width="250">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
link
|
link
|
||||||
size="small"
|
size="small"
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="publicityEdit(scope.row)"
|
@click="publicityShow(scope.row)"
|
||||||
v-auth="'publicity.update'"
|
|
||||||
>详情
|
>详情
|
||||||
</el-button>
|
</el-button>
|
||||||
<!-- <el-popconfirm
|
<el-popconfirm
|
||||||
title="确定删除吗?"
|
title="确定删除吗?"
|
||||||
@confirm="publicityDel(scope.row)"
|
@confirm="handleDel(scope.row)"
|
||||||
>
|
>
|
||||||
<template #reference>
|
<template #reference>
|
||||||
<el-button
|
<el-button
|
||||||
link
|
link
|
||||||
size="small"
|
size="small"
|
||||||
type="danger"
|
type="danger"
|
||||||
v-auth="'vehicle.delete'"
|
v-auth="'publicity.delete'"
|
||||||
>删除</el-button
|
>删除</el-button
|
||||||
>
|
>
|
||||||
</template>
|
</template>
|
||||||
</el-popconfirm> -->
|
</el-popconfirm>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</scTable>
|
</scTable>
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
<el-drawer :title="titleMap[type] " v-model="limitedVisible" direction="rtl" size="70%">
|
<el-drawer title="宣传报道" v-model="limitedVisible" direction="rtl" size="70%">
|
||||||
<div style="display: flex; height: calc(100% - 60px);">
|
<div style="display: flex; height: calc(100% - 60px);">
|
||||||
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
||||||
<publicity
|
<publicity
|
||||||
v-if="limitedVisible"
|
:mode="mode"
|
||||||
:mode="type"
|
:t_id="t_id"
|
||||||
:modelValue="addForm"
|
|
||||||
:transitions="transitions"
|
|
||||||
@success="()=>{handleQuery(); limitedVisible = false}"
|
@success="()=>{handleQuery(); limitedVisible = false}"
|
||||||
@closed="clearState"
|
|
||||||
@submit="savePublicity"
|
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-drawer>
|
</el-drawer>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
import publicity from "./publicityForm.vue";
|
import publicity from "./publicityForm.vue";
|
||||||
|
import { actStateEnum, interveneTypeEnum } from "@/utils/enum.js";
|
||||||
export default {
|
export default {
|
||||||
components: {publicity},
|
components: {publicity},
|
||||||
name: "index",
|
name: "index",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
workflowName:"",
|
|
||||||
workFlowId:'',
|
|
||||||
apiObj: this.$API.ofm.publicity.list,
|
apiObj: this.$API.ofm.publicity.list,
|
||||||
transitions:[],
|
actStateEnum, interveneTypeEnum,
|
||||||
timeRange: [],
|
|
||||||
query: {},
|
query: {},
|
||||||
isSaving: false,
|
|
||||||
limitedVisible: false,
|
limitedVisible: false,
|
||||||
limitedWatch: false,
|
mode: "show",
|
||||||
type: "add",
|
t_id: null,
|
||||||
titleMap: {
|
|
||||||
add: "新增",
|
|
||||||
edit: "编辑",
|
|
||||||
show: "查看",
|
|
||||||
},
|
|
||||||
statusOptions:{
|
|
||||||
0: "审批中",
|
|
||||||
1: "初始中",
|
|
||||||
2: "已完成",
|
|
||||||
},
|
|
||||||
//表单数据
|
|
||||||
addForm: {
|
|
||||||
number: null,
|
|
||||||
title: null,
|
|
||||||
participants: null,
|
|
||||||
department: null,
|
|
||||||
pfile: '',
|
|
||||||
level: null,
|
|
||||||
content: [],
|
|
||||||
other_content: '',
|
|
||||||
channel: [],
|
|
||||||
other_channel: null,
|
|
||||||
report_purpose: null,
|
|
||||||
report_name: null,
|
|
||||||
review:null,
|
|
||||||
dept_opinion: [],
|
|
||||||
dept_opinion_review: null,
|
|
||||||
publicity_opinion: null,
|
|
||||||
ticket_: null,
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted(){
|
|
||||||
let that = this;
|
|
||||||
that.getInit();
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
//添加工作流
|
|
||||||
//渲染工单提交按钮
|
|
||||||
getInit() {
|
|
||||||
let that = this;
|
|
||||||
if(this.addForm.ticket_!==null){
|
|
||||||
this.$API.wf.ticket.ticketTransitions.req(this.addForm.ticket_).then((res) => {
|
|
||||||
that.transitions = res;
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
that.$API.wf.workflow.initkey.req("publicity").then((res) => {
|
|
||||||
that.initForm = res;
|
|
||||||
that.transitions = res.transitions;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
clearState(){
|
|
||||||
this.type = ' ';
|
|
||||||
this.addForm = this.getDefaultForm();
|
|
||||||
this.limitedVisible = false;
|
|
||||||
},
|
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.type = "add";
|
this.mode = "add";
|
||||||
this.addForm = this.getDefaultForm();
|
this.t_id = null;
|
||||||
this.$nextTick(()=>{
|
this.limitedVisible = true;
|
||||||
this.limitedVisible = true;
|
|
||||||
})
|
|
||||||
},
|
},
|
||||||
getDefaultForm(){
|
publicityShow(row) {
|
||||||
return {
|
this.mode = "show";
|
||||||
number: null,
|
this.t_id = row.id;
|
||||||
title: null,
|
this.limitedVisible = true;
|
||||||
participants: null,
|
|
||||||
pub_dept: null,
|
|
||||||
pfile: '',
|
|
||||||
level: null,
|
|
||||||
content: [],
|
|
||||||
other_content: '',
|
|
||||||
channel: [],
|
|
||||||
other_channel: null,
|
|
||||||
report_purpose: null,
|
|
||||||
report_name: null,
|
|
||||||
review:null,
|
|
||||||
dept_opinion: [],
|
|
||||||
dept_opinion_review: null,
|
|
||||||
publicity_opinion: null,
|
|
||||||
ticket_: null,
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
// 审批流结束之后才可以编辑
|
async handleDel(row) {
|
||||||
publicityEdit(row) {
|
|
||||||
this.type = "view";
|
|
||||||
this.addForm = Object.assign({}, row);
|
|
||||||
this.$nextTick(()=>{
|
|
||||||
this.limitedVisible = true;
|
|
||||||
})
|
|
||||||
},
|
|
||||||
async publicityDel(row) {
|
|
||||||
var id = row.id;
|
var id = row.id;
|
||||||
var res = await this.$API.ofm.publicity.delete.req(id);
|
await this.$API.ofm.publicity.delete.req(id);
|
||||||
if (res.err_msg) {
|
this.$refs.table.refresh();
|
||||||
this.$message.error(res.err_msg);
|
this.$message.success("删除成功");
|
||||||
} else {
|
|
||||||
this.$refs.table.refresh();
|
|
||||||
this.$message.success("删除成功");
|
|
||||||
}
|
|
||||||
},
|
|
||||||
savePublicity(){
|
|
||||||
this.isSaving = true;
|
|
||||||
this.$API.ofm.publicity.update.req(this.addForm.id, this.addForm).then((res) => {
|
|
||||||
this.isSaving = false;
|
|
||||||
if (res.err_code) {
|
|
||||||
this.$message.error(res.err_msg);
|
|
||||||
} else {
|
|
||||||
this.$message.success("更新成功");
|
|
||||||
// this.limitedVisible = false;
|
|
||||||
this.$refs.table.refresh();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
},
|
||||||
//搜索
|
//搜索
|
||||||
handleQuery() {
|
handleQuery() {
|
||||||
|
|
@ -266,54 +158,5 @@ export default {
|
||||||
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
|
||||||
.treeMain {
|
|
||||||
height: 280px;
|
|
||||||
overflow: auto;
|
|
||||||
border: 1px solid #dcdfe6;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar {
|
|
||||||
width: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-track {
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.2);
|
|
||||||
background-color: #fefefe;
|
|
||||||
border-radius: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-thumb {
|
|
||||||
border-radius: 5px;
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
|
|
||||||
background-color: #f5f5f5;
|
|
||||||
}
|
|
||||||
.node rect {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.edgePath path {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #333;
|
|
||||||
stroke-width: 1.5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
g.conditions > rect {
|
|
||||||
fill: #00ffd0;
|
|
||||||
stroke: #000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.el-icon-close {
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel-group {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 6px; /* 按钮之间的间隙,可以调小点 */
|
|
||||||
margin-left: 0; /* 靠左 */
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -9,35 +9,35 @@
|
||||||
label-position="left"
|
label-position="left"
|
||||||
>
|
>
|
||||||
<el-form-item label="送审稿件标题" prop="title">
|
<el-form-item label="送审稿件标题" prop="title">
|
||||||
<el-input v-model="addForm.title" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="addForm.title" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="文件内容">
|
<el-form-item label="文件内容">
|
||||||
<sc-upload-file
|
<sc-upload-file
|
||||||
v-model="addForm.pfile"
|
v-model="addForm.pfile"
|
||||||
:multiple="false"
|
:multiple="false"
|
||||||
:limit="1"
|
:limit="1"
|
||||||
:disabled="localMode ==='view'"
|
:disabled="localMode ==='show'"
|
||||||
:accept="['.xlsx', '.xls','.pdf','.docx', '.doc', '.jpg', '.png', '.jpeg']"
|
:accept="['.xlsx', '.xls','.pdf','.docx', '.doc', '.jpg', '.png', '.jpeg']"
|
||||||
@success = "fileUPSuccess"
|
@success = "fileUPSuccess"
|
||||||
>
|
>
|
||||||
<el-button type="primary" icon="el-icon-upload" :disabled="localMode ==='view'"> </el-button>
|
<el-button type="primary" icon="el-icon-upload" :disabled="localMode ==='show'"> </el-button>
|
||||||
</sc-upload-file>
|
</sc-upload-file>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="所有撰稿人" prop="participants">
|
<el-form-item label="所有撰稿人" prop="participants">
|
||||||
<el-input v-model="addForm.participants" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="addForm.participants" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="部室/研究院" prop="pub_dept">
|
<el-form-item label="部室/研究院" prop="pub_dept">
|
||||||
<el-input v-model="addForm.pub_dept" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="addForm.pub_dept" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="第一撰稿人涉密等级" prop="level">
|
<el-form-item label="第一撰稿人涉密等级" prop="level">
|
||||||
<el-radio-group v-model="addForm.level" :disabled="localMode ==='view'">
|
<el-radio-group v-model="addForm.level" :disabled="localMode ==='show'">
|
||||||
<el-radio label="重要"></el-radio>
|
<el-radio label="重要"></el-radio>
|
||||||
<el-radio label="一般"></el-radio>
|
<el-radio label="一般"></el-radio>
|
||||||
<el-radio label="非涉密"></el-radio>
|
<el-radio label="非涉密"></el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="稿件内容涉及" prop="content">
|
<el-form-item label="稿件内容涉及" prop="content">
|
||||||
<el-checkbox-group v-model="addForm.content" :disabled="localMode ==='view'">
|
<el-checkbox-group v-model="addForm.content" :disabled="localMode ==='show'">
|
||||||
<el-checkbox label="武器装备科研生产综合事项"></el-checkbox>
|
<el-checkbox label="武器装备科研生产综合事项"></el-checkbox>
|
||||||
<el-checkbox label="其他"></el-checkbox>
|
<el-checkbox label="其他"></el-checkbox>
|
||||||
</el-checkbox-group>
|
</el-checkbox-group>
|
||||||
|
|
@ -47,14 +47,14 @@
|
||||||
placeholder = "请输入名称"
|
placeholder = "请输入名称"
|
||||||
size = "small"
|
size = "small"
|
||||||
style="margin-top: 10;"
|
style="margin-top: 10;"
|
||||||
:disabled="localMode ==='view'"
|
:disabled="localMode ==='show'"
|
||||||
></el-input>
|
></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="宣传报道目的" prop="report_purpose">
|
<el-form-item label="宣传报道目的" prop="report_purpose">
|
||||||
<el-input v-model="addForm.report_purpose" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="addForm.report_purpose" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="宣传渠道" prop="channel">
|
<el-form-item label="宣传渠道" prop="channel">
|
||||||
<el-checkbox-group v-model="addForm.channel" :disabled="localMode ==='view'">
|
<el-checkbox-group v-model="addForm.channel" :disabled="localMode ==='show'">
|
||||||
<el-checkbox label="互联网"></el-checkbox>
|
<el-checkbox label="互联网"></el-checkbox>
|
||||||
<el-checkbox label="信息平台"></el-checkbox>
|
<el-checkbox label="信息平台"></el-checkbox>
|
||||||
<el-checkbox label="官微"></el-checkbox>
|
<el-checkbox label="官微"></el-checkbox>
|
||||||
|
|
@ -67,42 +67,44 @@
|
||||||
placeholder = "请输入渠道名称"
|
placeholder = "请输入渠道名称"
|
||||||
size = "small"
|
size = "small"
|
||||||
style="margin-top: 10;"
|
style="margin-top: 10;"
|
||||||
:disabled="localMode ==='view'"
|
:disabled="localMode ==='show'"
|
||||||
></el-input>
|
></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="第一撰稿人自审" prop="review">
|
<el-form-item label="第一撰稿人自审" prop="review">
|
||||||
<el-radio-group v-model="addForm.review" :disabled="localMode ==='view'">
|
<el-radio-group v-model="addForm.review" :disabled="localMode ==='show'">
|
||||||
<el-radio label="内容不涉及国家秘密和商业秘密,申请公开"></el-radio>
|
<el-radio label="内容不涉及国家秘密和商业秘密,申请公开"></el-radio>
|
||||||
<el-radio label="内容不涉及国家秘密、但涉及商业秘密,申请受控公开"></el-radio>
|
<el-radio label="内容不涉及国家秘密、但涉及商业秘密,申请受控公开"></el-radio>
|
||||||
<el-radio label="内容涉及国家秘密,申请按涉密渠道发布"></el-radio>
|
<el-radio label="内容涉及国家秘密,申请按涉密渠道发布"></el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="所在部室/研究院定密意见" prop="dept_opinion" v-if="addForm.ticket_?.state_?.name === '部门领导审批'">
|
<el-form-item label="所在部室/研究院定密意见" prop="dept_opinion" v-if="['部门领导审批', '总经理审批', '结束'].includes(addForm.ticket_?.state_?.name)">
|
||||||
<div class="dept-opinion-wrap">
|
<div class="dept-opinion-wrap">
|
||||||
<div>
|
<div>
|
||||||
<el-checkbox-group v-model="ticket_data.dept_opinion" style="display: inline;">
|
<el-radio-group v-model="addForm.dept_opinion" style="display: inline;" :disabled="addForm.ticket_?.state_?.name === '总经理审批'">
|
||||||
<el-checkbox label="不符合定密要求"></el-checkbox>
|
<el-radio label="不符合定密要求">不符合定密要求</el-radio>
|
||||||
</el-checkbox-group>
|
<el-radio label="同意内容为涉密事项">同意内容为涉密事项</el-radio>
|
||||||
<span>,应做</span>
|
</el-radio-group>
|
||||||
<el-checkbox-group v-model="ticket_data.dept_opinion" style="display: inline;">
|
</div>
|
||||||
<el-checkbox label="公开"></el-checkbox>
|
|
||||||
<el-checkbox label="受控"></el-checkbox>
|
<!-- 根据选择显示不同的选项 -->
|
||||||
</el-checkbox-group>
|
<div v-if="addForm.dept_opinion === '不符合定密要求'" style="margin-top: 8px;">
|
||||||
|
<span>应做</span>
|
||||||
|
<el-radio-group v-model="disposalMethod" style="display: inline; margin-left: 5px;" :disabled="addForm.ticket_?.state_?.name === '总经理审批'">
|
||||||
|
<el-radio label="公开">公开</el-radio>
|
||||||
|
<el-radio label="受控">受控</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
<span>处理。</span>
|
<span>处理。</span>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div style="margin-top: 8px;">
|
<div v-if="addForm.dept_opinion === '同意内容为涉密事项'" style="margin-top: 8px;">
|
||||||
<el-checkbox-group v-model="ticket_data.dept_opinion" style="display: inline;">
|
<span>涉密等级为:</span>
|
||||||
<el-checkbox label="同意内容为涉密事项"></el-checkbox>
|
<el-radio-group v-model="addForm.secret_level" style="display: inline; margin-left: 5px;">
|
||||||
</el-checkbox-group>
|
<el-radio label="机密">机密</el-radio>
|
||||||
<span>,涉密等级为:</span>
|
<el-radio label="秘密">秘密</el-radio>
|
||||||
<el-checkbox-group v-model="ticket_data.dept_opinion" style="display: inline;">
|
</el-radio-group>
|
||||||
<el-checkbox label="机密"></el-checkbox>
|
|
||||||
<el-checkbox label="秘密"></el-checkbox>
|
|
||||||
</el-checkbox-group>
|
|
||||||
<span>,保密期限(解密时间或解密条件)为:</span>
|
<span>,保密期限(解密时间或解密条件)为:</span>
|
||||||
<el-input
|
<el-input
|
||||||
v-model="ticket_data.secret_period"
|
v-model="addForm.secret_period"
|
||||||
placeholder="请输入期限"
|
placeholder="请输入期限"
|
||||||
style="width: 200px; margin-left: 5px;"
|
style="width: 200px; margin-left: 5px;"
|
||||||
size="small"
|
size="small"
|
||||||
|
|
@ -111,15 +113,15 @@
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="所在部室/研究院审查意见" prop="dept_opinion_review" v-if="addForm.ticket_?.state_?.name === '总经理审批'">
|
<el-form-item label="所在部室/研究院审查意见" prop="dept_opinion_review" v-if="['部门领导审批', '总经理审批', '结束'].includes(addForm.ticket_?.state_?.name)">
|
||||||
<el-radio-group v-model="ticket_data.dept_opinion_review">
|
<el-radio-group v-model="addForm.dept_opinion_review" :disabled="addForm.ticket_?.state_?.name === '总经理审批'">
|
||||||
<el-radio label="内容不涉及国家秘密和商业秘密,同意公开"></el-radio>
|
<el-radio label="内容不涉及国家秘密和商业秘密,同意公开"></el-radio>
|
||||||
<el-radio label="内容不涉及国家秘密、但涉及商业秘密,同意受控公开"></el-radio>
|
<el-radio label="内容不涉及国家秘密、但涉及商业秘密,同意受控公开"></el-radio>
|
||||||
<el-radio label="内容涉及国家秘密,同意按涉密渠道发布"></el-radio>
|
<el-radio label="内容涉及国家秘密,同意按涉密渠道发布"></el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="宣传统战部审查意见" prop="publicity_opinion" v-if="addForm.ticket_?.state_?.name === '总经理审批'">
|
<el-form-item label="宣传统战部审查意见" prop="publicity_opinion" v-if="['总经理审批', '结束'].includes(addForm.ticket_?.state_?.name)">
|
||||||
<el-radio-group v-model="ticket_data.publicity_opinion">
|
<el-radio-group v-model="addForm.publicity_opinion">
|
||||||
<el-radio label="同意公开宣传报道"></el-radio>
|
<el-radio label="同意公开宣传报道"></el-radio>
|
||||||
<el-radio label="同意受控报道"></el-radio>
|
<el-radio label="同意受控报道"></el-radio>
|
||||||
<el-radio label="同意按涉密渠道宣传报道"></el-radio>
|
<el-radio label="同意按涉密渠道宣传报道"></el-radio>
|
||||||
|
|
@ -127,7 +129,7 @@
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-footer v-show="mode!=='show'">
|
<el-footer>
|
||||||
<ticketd_b
|
<ticketd_b
|
||||||
:workflow_key="'publicity'"
|
:workflow_key="'publicity'"
|
||||||
:title="ticketTitle"
|
:title="ticketTitle"
|
||||||
|
|
@ -137,41 +139,41 @@
|
||||||
:submit_b_func="submit_b_func"
|
:submit_b_func="submit_b_func"
|
||||||
ref="ticketd_b"
|
ref="ticketd_b"
|
||||||
@success="$emit('success')"
|
@success="$emit('success')"
|
||||||
@colsed="$emit('closed')"/>
|
/>
|
||||||
</el-footer>
|
</el-footer>
|
||||||
</el-main>
|
</el-main>
|
||||||
<el-aside v-if="addForm.ticket">
|
<el-aside v-if="addForm.ticket">
|
||||||
<ticketd
|
<ticketd
|
||||||
:ticket_="addForm.ticket_"
|
:ticket_="addForm.ticket_"
|
||||||
:ticket_data="ticket_data"
|
:ticket_data="ticket_data"
|
||||||
@success="$emit('success')"
|
@success="$emit('success')"
|
||||||
style="margin-top: 20px;"
|
style="margin-top: 20px;"
|
||||||
/>
|
/>
|
||||||
</el-aside>
|
</el-aside>
|
||||||
</el-container>
|
</el-container>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
import ticketd_b from "@/views/wf/ticketd_b.vue";
|
import ticketd_b from "@/views/wf/ticketd_b.vue";
|
||||||
import ticketd from '@/views/wf/ticketd.vue'
|
import ticketd from '@/views/wf/ticketd.vue'
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: "index",
|
name: "index",
|
||||||
props: {
|
props: {
|
||||||
mode: {
|
mode: {
|
||||||
type: String, default: "view"
|
type: String, default: "show"
|
||||||
},
|
}, // add / edit / show
|
||||||
modelValue: { type: Object, default: () => ({})},
|
t_id: {
|
||||||
transitions: { type: Array, default: () => [] },
|
type: String, default: null
|
||||||
},
|
},
|
||||||
|
},
|
||||||
components: {
|
components: {
|
||||||
ticketd, ticketd_b
|
ticketd, ticketd_b
|
||||||
},
|
},
|
||||||
emits: ["update:modelValue", "submit", "cancel"],
|
|
||||||
data(){
|
data(){
|
||||||
return {
|
return {
|
||||||
ticketTitle: "宣传报道",
|
ticketTitle: "宣传报道",
|
||||||
ticket_data: {},
|
ticket_data: {},
|
||||||
|
addForm:{},
|
||||||
localMode : this.mode,
|
localMode : this.mode,
|
||||||
rules: {
|
rules: {
|
||||||
file_name: [
|
file_name: [
|
||||||
|
|
@ -180,31 +182,54 @@ export default {
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
|
||||||
addForm: {
|
|
||||||
get() {
|
|
||||||
return this.modelValue;
|
|
||||||
},
|
|
||||||
set(val) {
|
|
||||||
this.$emit("update:modelValue", val);
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
mounted() {
|
mounted() {
|
||||||
this.getTid();
|
let that = this;
|
||||||
if (this.addForm.ticket_?.state_.type===1){
|
if (that.t_id) {
|
||||||
this.localMode = 'edit'
|
that.getTid();
|
||||||
|
};
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
'addForm.dept_opinion'(val) {
|
||||||
|
console.log('addForm.dept_opinion 发生变化',val)
|
||||||
|
this.ticket_data.dept_opinion = val
|
||||||
|
},
|
||||||
|
'addForm.secret_period'(val) {
|
||||||
|
this.ticket_data.secret_period = val
|
||||||
|
},
|
||||||
|
'addForm.secret_level'(val) {
|
||||||
|
this.ticket_data.secret_level = val
|
||||||
|
},
|
||||||
|
'addForm.disposal_method'(val) {
|
||||||
|
console.log('addForm.disposal_method 发生变化',val)
|
||||||
|
this.ticket_data.disposal_method = val
|
||||||
|
},
|
||||||
|
'addForm.dept_opinion_review'(val) {
|
||||||
|
this.ticket_data.dept_opinion_review = val
|
||||||
|
},
|
||||||
|
'addForm.publicity_opinion'(val) {
|
||||||
|
console.log('addForm.publicity_opinion 发生变化',val)
|
||||||
|
this.ticket_data.publicity_opinion = val
|
||||||
|
},
|
||||||
|
deep:true
|
||||||
|
},
|
||||||
|
computed: {
|
||||||
|
disposalMethod: {
|
||||||
|
get() {
|
||||||
|
return this.addForm.disposal_method || '';
|
||||||
|
},
|
||||||
|
set(value) {
|
||||||
|
this.addForm.disposal_method = value;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
async submit_b_func() {
|
async submit_b_func() {
|
||||||
let that = this;
|
let that = this;
|
||||||
let res = null;
|
|
||||||
if (that.localMode === "add") {
|
if (that.localMode === "add") {
|
||||||
res = await that.$API.ofm.publicity.create.req(that.addForm);
|
let res = await that.$API.ofm.publicity.create.req(that.addForm);
|
||||||
that.addForm.id = res.id;
|
that.addForm.id = res.id;
|
||||||
} else if (that.localMode === "edit"){
|
} else if (that.localMode === "edit"){
|
||||||
res = await that.$API.ofm.publicity.update.req(
|
await that.$API.ofm.publicity.update.req(
|
||||||
that.addForm.id,
|
that.addForm.id,
|
||||||
that.addForm
|
that.addForm
|
||||||
);
|
);
|
||||||
|
|
@ -227,65 +252,5 @@ export default {
|
||||||
|
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
|
||||||
.treeMain {
|
|
||||||
height: 280px;
|
|
||||||
overflow: auto;
|
|
||||||
border: 1px solid #dcdfe6;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar {
|
|
||||||
width: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-track {
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.2);
|
|
||||||
background-color: #fefefe;
|
|
||||||
border-radius: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-thumb {
|
|
||||||
border-radius: 5px;
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
|
|
||||||
background-color: #f5f5f5;
|
|
||||||
}
|
|
||||||
.node rect {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.edgePath path {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #333;
|
|
||||||
stroke-width: 1.5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
g.conditions > rect {
|
|
||||||
fill: #00ffd0;
|
|
||||||
stroke: #000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.el-icon-close {
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel-group {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 6px; /* 按钮之间的间隙,可以调小点 */
|
|
||||||
margin-left: 0; /* 靠左 */
|
|
||||||
}
|
|
||||||
|
|
||||||
.dept-opinion-wrap {
|
|
||||||
display: flex;
|
|
||||||
flex-direction: column;
|
|
||||||
line-height: 1.8;
|
|
||||||
}
|
|
||||||
|
|
||||||
.dept-opinion-wrap .el-checkbox {
|
|
||||||
margin-right: 6px;
|
|
||||||
}
|
|
||||||
|
|
||||||
</style>
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,14 +6,7 @@
|
||||||
type="primary"
|
type="primary"
|
||||||
icon="el-icon-plus"
|
icon="el-icon-plus"
|
||||||
@click="handleAdd"
|
@click="handleAdd"
|
||||||
v-auth="'seal.create'"
|
>新增</el-button>
|
||||||
>内用</el-button>
|
|
||||||
<el-button
|
|
||||||
type="primary"
|
|
||||||
icon="el-icon-plus"
|
|
||||||
@click="handleAdd_outer"
|
|
||||||
v-auth="'seal.create'"
|
|
||||||
>外借</el-button>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="right-panel">
|
<div class="right-panel">
|
||||||
<el-input
|
<el-input
|
||||||
|
|
@ -87,34 +80,27 @@
|
||||||
<span v-else>否</span>
|
<span v-else>否</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="所在节点" min-width="60">
|
<el-table-column label="审批信息" width="200">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
{{scope.row.ticket_.state_.name}}
|
<el-tag :type="actStateEnum[scope.row.ticket_?.act_state]?.type">
|
||||||
|
{{ actStateEnum[scope.row.ticket_?.act_state]?.text }}
|
||||||
|
</el-tag>
|
||||||
|
<el-tag type="info" effect="plain">{{ scope.row.ticket_?.state_.name }}</el-tag>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="进行状态" min-width="60">
|
|
||||||
<template #default="scope">
|
|
||||||
{{statusOptions[scope.row.ticket_.state_.type]}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column
|
|
||||||
label="备注"
|
|
||||||
prop="reason"
|
|
||||||
min-width="60"
|
|
||||||
></el-table-column>
|
|
||||||
<el-table-column label="操作" fixed="right" align="center" width="250">
|
<el-table-column label="操作" fixed="right" align="center" width="250">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
link
|
link
|
||||||
size="small"
|
size="small"
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="sealEidt(scope.row)"
|
@click="handleShow(scope.row)"
|
||||||
v-auth="'seal.update'"
|
|
||||||
>详情
|
>详情
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-popconfirm
|
<el-popconfirm
|
||||||
title="确定删除吗?"
|
title="确定删除吗?"
|
||||||
@confirm="sealDel(scope.row)"
|
@confirm="handleDel(scope.row)"
|
||||||
>
|
>
|
||||||
<template #reference>
|
<template #reference>
|
||||||
<el-button
|
<el-button
|
||||||
|
|
@ -132,7 +118,7 @@
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
<el-drawer
|
<el-drawer
|
||||||
:title="drawerTitle[mode]"
|
title="印章申请"
|
||||||
v-model="limitedVisible"
|
v-model="limitedVisible"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
direction="rtl"
|
direction="rtl"
|
||||||
|
|
@ -142,8 +128,7 @@
|
||||||
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
||||||
<SealForm
|
<SealForm
|
||||||
:mode="mode"
|
:mode="mode"
|
||||||
v-model="addForm"
|
:t_id="t_id"
|
||||||
:lending_type="lending_type"
|
|
||||||
@success="()=>{handleQuery(); limitedVisible = false}"
|
@success="()=>{handleQuery(); limitedVisible = false}"
|
||||||
@closed="limitedVisible = false"
|
@closed="limitedVisible = false"
|
||||||
/>
|
/>
|
||||||
|
|
@ -152,153 +137,37 @@
|
||||||
</el-drawer>
|
</el-drawer>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
import SealForm from "./sealForm.vue";
|
import SealForm from "./sealForm.vue";
|
||||||
|
import { actStateEnum, interveneTypeEnum } from "@/utils/enum.js";
|
||||||
export default {
|
export default {
|
||||||
components: { SealForm},
|
components: { SealForm},
|
||||||
name: "index",
|
name: "index",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
workflowName:"",
|
actStateEnum, interveneTypeEnum,
|
||||||
workFlowId:'',
|
|
||||||
apiObj: this.$API.ofm.lendingseal.list,
|
apiObj: this.$API.ofm.lendingseal.list,
|
||||||
selection: [],
|
|
||||||
checkList: [],
|
|
||||||
fileList: [],
|
|
||||||
transitions:[],
|
|
||||||
timeRange: [],
|
|
||||||
lending_type: "",
|
|
||||||
query: {},
|
query: {},
|
||||||
editId: null,
|
|
||||||
isSaving: false,
|
|
||||||
limitedVisible: false,
|
limitedVisible: false,
|
||||||
mode: "add",
|
mode: "show",
|
||||||
drawerTitle: {
|
t_id: null,
|
||||||
add: "新增印章使用",
|
|
||||||
edit: "审批流",
|
|
||||||
view: "查看印章使用",
|
|
||||||
},
|
|
||||||
statusOptions:{
|
|
||||||
0: "审批中",
|
|
||||||
1: "初始中",
|
|
||||||
2: "已完成",
|
|
||||||
},
|
|
||||||
currentRow: null,
|
|
||||||
//表单数据
|
|
||||||
addForm: {
|
|
||||||
seal: [],
|
|
||||||
create_by_name: "",
|
|
||||||
seal_other: "",
|
|
||||||
filename: "",
|
|
||||||
file: "",
|
|
||||||
file_count: "",
|
|
||||||
is_lending: false,
|
|
||||||
contacts: "",
|
|
||||||
lending_date: null,
|
|
||||||
return_date: null,
|
|
||||||
actual_return_date: null,
|
|
||||||
reason: "",
|
|
||||||
ticket_:null
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted(){
|
|
||||||
let that = this;
|
|
||||||
that.getInit();
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
//添加工作流
|
|
||||||
//渲染工单提交按钮
|
|
||||||
getInit() {
|
|
||||||
let that = this;
|
|
||||||
if(this.addForm.ticket_!==null){
|
|
||||||
this.$API.wf.ticket_.ticketTransitions.req(this.addForm.ticket_).then((res) => {
|
|
||||||
that.transitions = res;
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
that.$API.wf.workflow.initkey.req("seal").then((res) => {
|
|
||||||
that.initForm = res;
|
|
||||||
that.transitions = res.transitions;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.mode = "add";
|
this.mode = "add";
|
||||||
this.addForm = this.getDefaultForm();
|
this.t_id = null;
|
||||||
this.lending_type = "";
|
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
},
|
},
|
||||||
handleAdd_outer() {
|
handleShow(row) {
|
||||||
this.addForm = this.getDefaultForm();
|
this.mode = "show";
|
||||||
this.mode = "add";
|
this.t_id = row.id;
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
this.lending_type = "outer";
|
|
||||||
this.addForm.is_lending = true;
|
|
||||||
},
|
},
|
||||||
handleCancel() {
|
async handleDel(row) {
|
||||||
this.limitedVisible = false; // 关闭弹窗
|
|
||||||
this.lending_type = ""; // 重置 lending_type
|
|
||||||
this.getDefaultForm()// 清空表单
|
|
||||||
},
|
|
||||||
|
|
||||||
getDefaultForm(){
|
|
||||||
return {
|
|
||||||
seal: [],
|
|
||||||
create_by_name: "",
|
|
||||||
seal_other: "",
|
|
||||||
filename: "",
|
|
||||||
file: "",
|
|
||||||
file_count: "",
|
|
||||||
is_lending: false,
|
|
||||||
contacts: "",
|
|
||||||
lending_date: null,
|
|
||||||
return_date: null,
|
|
||||||
actual_return_date: null,
|
|
||||||
reason: "",
|
|
||||||
ticket_:null
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 审批流结束之后才可以编辑
|
|
||||||
sealEidt(row) {
|
|
||||||
this.mode = "view";
|
|
||||||
this.editId = row.id;
|
|
||||||
this.limitedVisible = true;
|
|
||||||
if (row.is_lending) {
|
|
||||||
this.lending_type = "outer";
|
|
||||||
} else {
|
|
||||||
this.lending_type = "";
|
|
||||||
}
|
|
||||||
this.addForm = Object.assign({}, row);
|
|
||||||
if (row.lending_date && row.return_date) {
|
|
||||||
this.timeRange = [row.lending_date, row.return_date];
|
|
||||||
} else {
|
|
||||||
this.timeRange = [];
|
|
||||||
}
|
|
||||||
if (Array.isArray(row.seal)) {
|
|
||||||
let knownSeals = ["公章", "法人章", "合同章", "财务章"];
|
|
||||||
let otherItem = row.seal.filter((item) => !knownSeals.includes(item));
|
|
||||||
this.addForm.seal = row.seal.filter((item) => knownSeals.includes(item));
|
|
||||||
|
|
||||||
if (otherItem.length > 0) {
|
|
||||||
this.addForm.seal.push("其他");
|
|
||||||
this.addForm.seal_other = otherItem.join(",");
|
|
||||||
}else{
|
|
||||||
this.addForm.seal_other = "";
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
this.addForm.seal = [];
|
|
||||||
}
|
|
||||||
this.addForm.is_lending = true;
|
|
||||||
},
|
|
||||||
async sealDel(row) {
|
|
||||||
var id = row.id;
|
var id = row.id;
|
||||||
var res = await this.$API.ofm.lendingseal.delete.req(id);
|
await this.$API.ofm.lendingseal.delete.req(id);
|
||||||
if (res.err_msg) {
|
this.$refs.table.refresh();
|
||||||
this.$message.error(res.err_msg);
|
this.$message.success("删除成功");
|
||||||
} else {
|
|
||||||
this.$refs.table.refresh();
|
|
||||||
this.$message.success("删除成功");
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
//搜索
|
//搜索
|
||||||
handleQuery() {
|
handleQuery() {
|
||||||
|
|
@ -308,54 +177,4 @@ export default {
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
|
||||||
.treeMain {
|
|
||||||
height: 280px;
|
|
||||||
overflow: auto;
|
|
||||||
border: 1px solid #dcdfe6;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar {
|
|
||||||
width: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-track {
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.2);
|
|
||||||
background-color: #fefefe;
|
|
||||||
border-radius: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-thumb {
|
|
||||||
border-radius: 5px;
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
|
|
||||||
background-color: #f5f5f5;
|
|
||||||
}
|
|
||||||
.node rect {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.edgePath path {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #333;
|
|
||||||
stroke-width: 1.5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
g.conditions > rect {
|
|
||||||
fill: #00ffd0;
|
|
||||||
stroke: #000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.el-icon-close {
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel-group {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 6px; /* 按钮之间的间隙,可以调小点 */
|
|
||||||
margin-left: 0; /* 靠左 */
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,14 +3,14 @@
|
||||||
<el-main>
|
<el-main>
|
||||||
<el-form :model="localForm" label-width="100px" label-position="left" :rules="rules">
|
<el-form :model="localForm" label-width="100px" label-position="left" :rules="rules">
|
||||||
<el-form-item label="文件名称" prop="filename">
|
<el-form-item label="文件名称" prop="filename">
|
||||||
<el-input v-model="localForm.filename" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="localForm.filename" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="联系电话" prop="contacts">
|
<el-form-item label="联系电话" prop="contacts">
|
||||||
<el-input v-model="localForm.contacts" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="localForm.contacts" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="印章类型">
|
<el-form-item label="印章类型">
|
||||||
<el-checkbox-group v-model="localForm.seal" :disabled="localMode ==='view'">
|
<el-checkbox-group v-model="localForm.seal" :disabled="localMode ==='show'">
|
||||||
<el-checkbox label="公章"></el-checkbox>
|
<el-checkbox label="公章"></el-checkbox>
|
||||||
<el-checkbox label="法人章"></el-checkbox>
|
<el-checkbox label="法人章"></el-checkbox>
|
||||||
<el-checkbox label="合同章"></el-checkbox>
|
<el-checkbox label="合同章"></el-checkbox>
|
||||||
|
|
@ -18,29 +18,35 @@
|
||||||
<el-checkbox label="其他"></el-checkbox>
|
<el-checkbox label="其他"></el-checkbox>
|
||||||
</el-checkbox-group>
|
</el-checkbox-group>
|
||||||
<el-input
|
<el-input
|
||||||
v-if="localForm.seal.includes('其他')"
|
v-if="localForm.seal && localForm.seal.includes('其他')"
|
||||||
v-model="localForm.seal_other"
|
v-model="localForm.seal_other"
|
||||||
placeholder = "请输入印章名称"
|
placeholder = "请输入印章名称"
|
||||||
size = "small"
|
size = "small"
|
||||||
style="margin-top: 10;"
|
style="margin-top: 10;"
|
||||||
></el-input>
|
></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<template v-if="lending_type === 'outer'">
|
<el-form-item label="是否借出">
|
||||||
<el-form-item label="借用日期">
|
<el-radio-group v-model="localForm.is_lending" :disabled="localMode ==='show'">
|
||||||
<el-date-picker
|
<el-radio :label="true">是</el-radio>
|
||||||
v-model="timeRange"
|
<el-radio :label="false">否</el-radio>
|
||||||
type="daterange"
|
</el-radio-group>
|
||||||
align="right"
|
<div style="margin-top: 10px; width: 100%;">
|
||||||
value-format="YYYY-MM-DD"
|
<el-date-picker v-if="localForm.is_lending===true"
|
||||||
unlink-panels
|
v-model="timeRange"
|
||||||
range-separator="至"
|
type="daterange"
|
||||||
start-placeholder="开始日期"
|
align="right"
|
||||||
end-placeholder="结束日期"
|
value-format="YYYY-MM-DD"
|
||||||
:disabled="localMode ==='view'"
|
unlink-panels
|
||||||
@change="handleDateChange">
|
range-separator="至"
|
||||||
</el-date-picker>
|
start-placeholder="开始日期"
|
||||||
|
end-placeholder="结束日期"
|
||||||
|
:disabled="localMode ==='show'"
|
||||||
|
@change="handleDateChange">
|
||||||
|
</el-date-picker>
|
||||||
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="实际归还日期" v-if="localForm.ticket_?.state_?.name=='借用中'">
|
<el-form-item label="实际归还日期"
|
||||||
|
v-if="['借用中', '结束'].includes(localForm.ticket_?.state_?.name)">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="localForm.actual_return_date"
|
v-model="localForm.actual_return_date"
|
||||||
type="date"
|
type="date"
|
||||||
|
|
@ -48,6 +54,7 @@
|
||||||
value-format="YYYY-MM-DD"
|
value-format="YYYY-MM-DD"
|
||||||
unlink-panels
|
unlink-panels
|
||||||
placeholder="选择日期"
|
placeholder="选择日期"
|
||||||
|
:disabled="localForm.ticket_?.state_?.name !== '借用中'"
|
||||||
>
|
>
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
@ -57,11 +64,9 @@
|
||||||
placeholder="请输入借用理由"
|
placeholder="请输入借用理由"
|
||||||
v-model="localForm.reason"
|
v-model="localForm.reason"
|
||||||
rows = '3'
|
rows = '3'
|
||||||
:disabled="localMode ==='view'">
|
:disabled="localMode ==='show'">
|
||||||
</el-input>
|
</el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</template>
|
|
||||||
|
|
||||||
<el-form-item label="文件内容">
|
<el-form-item label="文件内容">
|
||||||
<sc-upload-file
|
<sc-upload-file
|
||||||
v-model="localForm.file"
|
v-model="localForm.file"
|
||||||
|
|
@ -69,7 +74,7 @@
|
||||||
:limit="1"
|
:limit="1"
|
||||||
:accept="['.xlsx', '.xls','.pdf','.docx', '.doc', '.jpg', '.png', '.jpeg']"
|
:accept="['.xlsx', '.xls','.pdf','.docx', '.doc', '.jpg', '.png', '.jpeg']"
|
||||||
@success = "fileUPSuccess"
|
@success = "fileUPSuccess"
|
||||||
:disabled="localMode ==='view'"
|
:disabled="localMode ==='show'"
|
||||||
>
|
>
|
||||||
<el-button type="primary" icon="el-icon-upload"> </el-button>
|
<el-button type="primary" icon="el-icon-upload"> </el-button>
|
||||||
</sc-upload-file>
|
</sc-upload-file>
|
||||||
|
|
@ -80,17 +85,16 @@
|
||||||
:min="0"
|
:min="0"
|
||||||
:step="1"
|
:step="1"
|
||||||
controls-position="right"
|
controls-position="right"
|
||||||
:disabled="localMode ==='view'"></el-input-number>
|
:disabled="localMode ==='show'"></el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-footer v-show="localMode!=='show'">
|
<el-footer>
|
||||||
<ticketd_b
|
<ticketd_b
|
||||||
v-if="ticketview"
|
|
||||||
:workflow_key="'seal'"
|
:workflow_key="'seal'"
|
||||||
:title="ticketTitle"
|
:title="ticketTitle"
|
||||||
:t_id="localForm.id"
|
:t_id="localForm.id"
|
||||||
:ticket_="localForm.ticket_"
|
|
||||||
:ticket_data="ticket_data"
|
:ticket_data="ticket_data"
|
||||||
|
:ticket_="localForm.ticket_"
|
||||||
:submit_b_func="submit_b_func"
|
:submit_b_func="submit_b_func"
|
||||||
ref="ticketd_b"
|
ref="ticketd_b"
|
||||||
@success="$emit('success')"
|
@success="$emit('success')"
|
||||||
|
|
@ -99,11 +103,10 @@
|
||||||
</el-main>
|
</el-main>
|
||||||
<el-aside v-if="localForm.ticket_">
|
<el-aside v-if="localForm.ticket_">
|
||||||
<ticketd
|
<ticketd
|
||||||
:ticket_="localForm.ticket_"
|
:ticket_="localForm.ticket_"
|
||||||
:ticket_data="ticket_data"
|
@success="$emit('success')"
|
||||||
@success="$emit('success')"
|
style="margin-top: 20px;"
|
||||||
style="margin-top: 20px;"
|
></ticketd>
|
||||||
/>
|
|
||||||
</el-aside>
|
</el-aside>
|
||||||
</el-container>
|
</el-container>
|
||||||
</template>
|
</template>
|
||||||
|
|
@ -113,64 +116,37 @@ import ticketd_b from "@/views/wf/ticketd_b.vue";
|
||||||
import ticketd from '@/views/wf/ticketd.vue'
|
import ticketd from '@/views/wf/ticketd.vue'
|
||||||
export default {
|
export default {
|
||||||
props: {
|
props: {
|
||||||
mode: { type: String, default: "view" }, // add / edit / view
|
mode: {
|
||||||
lending_type: { type: String, default: "outer" }, // inner / outer
|
type: String, default: "show"
|
||||||
modelValue: { type: Object, default: () => ({}) },
|
}, // add / edit / show
|
||||||
t_id: {
|
t_id: {
|
||||||
type: String,
|
type: String, default: null
|
||||||
default: null
|
},
|
||||||
},
|
},
|
||||||
},
|
|
||||||
components: {ticketd, ticketd_b },
|
components: {ticketd, ticketd_b },
|
||||||
emits: ["update:modelValue", "submit", "cancel"],
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
ticket_data: {},
|
|
||||||
ticketview: false,
|
|
||||||
ticketTitle: "用印申请",
|
ticketTitle: "用印申请",
|
||||||
localForm: {
|
ticket_data: {},
|
||||||
ticket_: {
|
localForm: {},
|
||||||
state_: { type: '' }
|
localMode: this.mode,
|
||||||
},
|
|
||||||
...this.modelValue },
|
|
||||||
localMode : this.mode,
|
|
||||||
timeRange: [],
|
timeRange: [],
|
||||||
rules: {
|
rules: {
|
||||||
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
// console.log('--------this.t_id----------',this.t_id)
|
let that = this;
|
||||||
this.getTid();
|
if (that.t_id) {
|
||||||
this.initTimeRange();
|
that.getTid();
|
||||||
if (this.localForm.ticket_?.state_.type===1){
|
}
|
||||||
this.localMode = 'edit'
|
|
||||||
}
|
|
||||||
if(this.lending_type === 'outer'){
|
|
||||||
this.ticket_data = {
|
|
||||||
is_lending: true
|
|
||||||
};
|
|
||||||
}else{
|
|
||||||
this.ticket_data={is_lending: false}
|
|
||||||
};
|
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
'localForm.actual_return_date'(val) {
|
'localForm.actual_return_date'(val) {
|
||||||
this.ticket_data.actual_return_date = val
|
this.ticket_data.actual_return_date = val
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
computed: {
|
|
||||||
addForm: {
|
|
||||||
get() {
|
|
||||||
return this.modelValue;
|
|
||||||
},
|
|
||||||
set(val) {
|
|
||||||
this.$emit("update:modelValue", val);
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
handleDateChange(val) {
|
handleDateChange(val) {
|
||||||
this.localForm.lending_date = val?.[0] || null
|
this.localForm.lending_date = val?.[0] || null
|
||||||
|
|
@ -178,10 +154,8 @@ export default {
|
||||||
},
|
},
|
||||||
async submit_b_func() {
|
async submit_b_func() {
|
||||||
let that = this;
|
let that = this;
|
||||||
this.ticketTitle = `${this.localForm.filename}-用印申请`
|
|
||||||
if(that.localMode == "add") {
|
if(that.localMode == "add") {
|
||||||
let res = await that.$API.ofm.lendingseal.create.req(that.localForm);
|
let res = await that.$API.ofm.lendingseal.create.req(that.localForm);
|
||||||
|
|
||||||
that.localForm.id = res.id;
|
that.localForm.id = res.id;
|
||||||
} else if (that.localMode == "edit") {
|
} else if (that.localMode == "edit") {
|
||||||
await that.$API.ofm.lendingseal.update.req(that.localForm.id, that.localForm);
|
await that.$API.ofm.lendingseal.update.req(that.localForm.id, that.localForm);
|
||||||
|
|
@ -189,18 +163,16 @@ export default {
|
||||||
},
|
},
|
||||||
getTid (){
|
getTid (){
|
||||||
var that = this;
|
var that = this;
|
||||||
// console.log('----------that--------',that.t_id)
|
if (that.t_id) {
|
||||||
if (that.t_id) {
|
that.$API.ofm.lendingseal.item.req(that.t_id).then(res=>{
|
||||||
that.$API.ofm.lendingseal.item.req(that.t_id).then(res=>{
|
that.localForm = res;
|
||||||
that.localForm = res;
|
that.initTimeRange();
|
||||||
// console.log('----------ticket_--------',that.localForm.ticket_)
|
if(res.ticket_.state_.type == 1 && res.create_by == that.$TOOL.data.get("USER_INFO").id ) {
|
||||||
that.ticketview = true;
|
that.localMode = "edit";
|
||||||
if(res.ticket_.state_.type == 1 && res.create_by == that.$TOOL.data.get("USER_INFO").id ) {
|
}else{
|
||||||
that.localMode = "edit";
|
that.localMode = "show";
|
||||||
}else{
|
}
|
||||||
that.localMode = "show";
|
})
|
||||||
}
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
initTimeRange() {
|
initTimeRange() {
|
||||||
|
|
|
||||||
|
|
@ -80,23 +80,22 @@
|
||||||
prop="actual_km"
|
prop="actual_km"
|
||||||
min-width="100"
|
min-width="100"
|
||||||
></el-table-column>
|
></el-table-column>
|
||||||
<el-table-column label="所在节点" min-width="60">
|
<el-table-column label="审批信息" width="200">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
{{scope.row.ticket_.state_.name}}
|
<el-tag :type="actStateEnum[scope.row.ticket_?.act_state]?.type">
|
||||||
|
{{ actStateEnum[scope.row.ticket_?.act_state]?.text }}
|
||||||
|
</el-tag>
|
||||||
|
<el-tag type="info" effect="plain">{{ scope.row.ticket_?.state_.name }}</el-tag>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="所在节点" min-width="60">
|
|
||||||
<template #default="scope">
|
|
||||||
{{statusOptions[scope.row.ticket_.state_.type]}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作" fixed="right" align="center" width="250">
|
<el-table-column label="操作" fixed="right" align="center" width="250">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
link
|
link
|
||||||
size="small"
|
size="small"
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="vehicleEidt(scope.row)"
|
@click="handleShow(scope.row)"
|
||||||
v-auth="'vehicle.update'"
|
v-auth="'vehicle.update'"
|
||||||
>详情
|
>详情
|
||||||
</el-button>
|
</el-button>
|
||||||
|
|
@ -120,7 +119,7 @@
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
<el-drawer
|
<el-drawer
|
||||||
:title="drawerTitle[type]"
|
:title="车辆审批"
|
||||||
v-model="limitedVisible"
|
v-model="limitedVisible"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
direction="rtl"
|
direction="rtl"
|
||||||
|
|
@ -129,19 +128,18 @@
|
||||||
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
||||||
<VehicleForm
|
<VehicleForm
|
||||||
:mode="type"
|
:mode="type"
|
||||||
v-model="addForm"
|
:t_id="t_id"
|
||||||
:lending_type="lending_type"
|
|
||||||
:transitions="transitions"
|
|
||||||
@success="()=>{handleQuery(); limitedVisible = false}"
|
@success="()=>{handleQuery(); limitedVisible = false}"
|
||||||
@closed="limitedVisible = false"
|
@closed="limitedVisible = false"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-drawer>
|
</el-drawer>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
import VehicleForm from "./vehicleForm.vue";
|
import VehicleForm from "./vehicleForm.vue";
|
||||||
|
import { actStateEnum, interveneTypeEnum } from "@/utils/enum.js";
|
||||||
export default {
|
export default {
|
||||||
components: {
|
components: {
|
||||||
VehicleForm
|
VehicleForm
|
||||||
|
|
@ -149,169 +147,38 @@ export default {
|
||||||
name: "index",
|
name: "index",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
workflowName:"",
|
actStateEnum, interveneTypeEnum,
|
||||||
workFlowId:'',
|
|
||||||
apiObj: this.$API.ofm.vehicle.list,
|
apiObj: this.$API.ofm.vehicle.list,
|
||||||
selection: [],
|
|
||||||
checkList: [],
|
|
||||||
transitions:[],
|
|
||||||
drawerTitle: {
|
|
||||||
add: "新增车辆使用",
|
|
||||||
edit: "编辑车辆使用",
|
|
||||||
view: "查看车辆使用",
|
|
||||||
},
|
|
||||||
statusOptions:{
|
|
||||||
0: "审批中",
|
|
||||||
1: "初始中",
|
|
||||||
2: "已完成",
|
|
||||||
},
|
|
||||||
timeRange: [],
|
|
||||||
lending_type: "",
|
|
||||||
choiceOption: [],
|
|
||||||
query: {},
|
query: {},
|
||||||
editId: null,
|
|
||||||
isSaving: false,
|
|
||||||
limitedVisible: false,
|
limitedVisible: false,
|
||||||
limitedWatch: false,
|
type: "show",
|
||||||
type: "add",
|
t_id: null,
|
||||||
//表单数据
|
|
||||||
addForm: {
|
|
||||||
start_time: null,
|
|
||||||
end_time: null,
|
|
||||||
location: null,
|
|
||||||
via: null,
|
|
||||||
destination: null,
|
|
||||||
start_km: null,
|
|
||||||
end_km: null,
|
|
||||||
is_city: true,
|
|
||||||
reason: null,
|
|
||||||
ticket_:null
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted(){
|
|
||||||
let that = this;
|
|
||||||
that.getInit();
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
getInit() {
|
|
||||||
let that = this;
|
|
||||||
if(this.addForm.ticket_!==null){
|
|
||||||
this.$API.wf.ticket_.ticketTransitions.req(this.addForm.ticket_).then((res) => {
|
|
||||||
that.transitions = res;
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
that.$API.wf.workflow.initkey.req("vehicle").then((res) => {
|
|
||||||
that.initForm = res;
|
|
||||||
that.transitions = res.transitions;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.type = "add";
|
this.type = "add";
|
||||||
this.addForm = this.getDefaultForm();
|
this.t_id = null;
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
},
|
},
|
||||||
getDefaultForm(){
|
|
||||||
return {
|
|
||||||
start_time: null,
|
|
||||||
end_time: null,
|
|
||||||
location: null,
|
|
||||||
via: null,
|
|
||||||
destination: null,
|
|
||||||
start_km: null,
|
|
||||||
end_km: null,
|
|
||||||
is_city: true,
|
|
||||||
reason: null,
|
|
||||||
ticket_:null
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 审批流结束之后才可以编辑
|
// 审批流结束之后才可以编辑
|
||||||
vehicleEidt(row) {
|
handleShow(row) {
|
||||||
this.type = "view";
|
this.type = "show";
|
||||||
this.editId = row.id;
|
this.t_id = row.id;
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
this.addForm = Object.assign({}, row);
|
|
||||||
},
|
},
|
||||||
// 更新审批流
|
|
||||||
saveVehicle() {
|
|
||||||
this.isSaving = true;
|
|
||||||
this.$API.ofm.vehicle.update.req(this.addForm.id, this.addForm).then((res) => {
|
|
||||||
this.isSaving = false;
|
|
||||||
if (res.err_code) {
|
|
||||||
this.$message.error(res.err_msg);
|
|
||||||
} else {
|
|
||||||
this.$message.success("更新成功");
|
|
||||||
this.limitedVisible = false;
|
|
||||||
this.$refs.table.refresh();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
},
|
|
||||||
async vehicleDel(row) {
|
async vehicleDel(row) {
|
||||||
var id = row.id;
|
var id = row.id;
|
||||||
var res = await this.$API.ofm.vehicle.delete.req(id);
|
var res = await this.$API.ofm.vehicle.delete.req(id);
|
||||||
if (res.err_msg) {
|
this.$refs.table.refresh();
|
||||||
this.$message.error(res.err_msg);
|
this.$message.success("删除成功");
|
||||||
} else {
|
|
||||||
this.$refs.table.refresh();
|
|
||||||
this.$message.success("删除成功");
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
//搜索
|
//搜索
|
||||||
handleQuery() {
|
handleQuery() {
|
||||||
this.$refs.table.queryData(this.query);
|
this.$refs.table.queryData(this.query);
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
|
||||||
.treeMain {
|
|
||||||
height: 280px;
|
|
||||||
overflow: auto;
|
|
||||||
border: 1px solid #dcdfe6;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar {
|
|
||||||
width: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-track {
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.2);
|
|
||||||
background-color: #fefefe;
|
|
||||||
border-radius: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-thumb {
|
|
||||||
border-radius: 5px;
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
|
|
||||||
background-color: #f5f5f5;
|
|
||||||
}
|
|
||||||
.node rect {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.edgePath path {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #333;
|
|
||||||
stroke-width: 1.5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
g.conditions > rect {
|
|
||||||
fill: #00ffd0;
|
|
||||||
stroke: #000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.el-icon-close {
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel-group {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 6px; /* 按钮之间的间隙,可以调小点 */
|
|
||||||
margin-left: 0; /* 靠左 */
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -9,29 +9,25 @@
|
||||||
label-position="left"
|
label-position="left"
|
||||||
>
|
>
|
||||||
<el-form-item label="用车事由" prop="reason">
|
<el-form-item label="用车事由" prop="reason">
|
||||||
<el-input v-model="addForm.reason" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="addForm.reason" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="用车范围" prop="is_city">
|
<el-form-item label="用车范围" prop="is_city">
|
||||||
<el-select v-model="addForm.is_city" placeholder="请选择" :disabled="localMode ==='view'">
|
<el-radio-group v-model="addForm.is_city" :disabled="localMode ==='show'">
|
||||||
<el-option
|
<el-radio :label="true">市内</el-radio>
|
||||||
v-for="item in vehicle_scope"
|
<el-radio :label="false">市外</el-radio>
|
||||||
:key="item.is_city"
|
</el-radio-group>
|
||||||
:label="item.name"
|
|
||||||
:value="item.is_city"
|
|
||||||
/>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="出发地点" prop="location">
|
<el-form-item label="出发地点" prop="location">
|
||||||
<el-input v-model="addForm.location" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="addForm.location" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="途经地点" prop="via">
|
<el-form-item label="途经地点" prop="via">
|
||||||
<el-input v-model="addForm.via" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="addForm.via" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="到达地点" prop="destination">
|
<el-form-item label="到达地点" prop="destination">
|
||||||
<el-input v-model="addForm.destination" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="addForm.destination" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="出发公里数" prop="start_km">
|
<el-form-item label="出发公里数" prop="start_km">
|
||||||
<el-input-number v-model="addForm.start_km" clearable :disabled="localMode ==='view'"></el-input-number>
|
<el-input-number v-model="addForm.start_km" clearable :disabled="localMode ==='show'"></el-input-number>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="归还公里数" prop="end_km" v-if="addForm.ticket_?.state_?.name=='用车中'">
|
<el-form-item label="归还公里数" prop="end_km" v-if="addForm.ticket_?.state_?.name=='用车中'">
|
||||||
<el-input-number v-model="addForm.end_km" clearable>
|
<el-input-number v-model="addForm.end_km" clearable>
|
||||||
|
|
@ -41,38 +37,37 @@
|
||||||
<el-form-item label="出车时间">
|
<el-form-item label="出车时间">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="addForm.start_time"
|
v-model="addForm.start_time"
|
||||||
type="date"
|
type="datetime"
|
||||||
align="right"
|
align="right"
|
||||||
value-format="YYYY-MM-DD"
|
value-format="YYYY-MM-DD HH:mm:ss"
|
||||||
unlink-panels
|
unlink-panels
|
||||||
placeholder="选择日期"
|
placeholder="选择日期"
|
||||||
:disabled="mode==='view'"
|
:disabled="mode==='show'"
|
||||||
>
|
>
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="还车时间" v-if="addForm.ticket_?.state_?.name=='用车中'">
|
<el-form-item label="还车时间" v-if="addForm.ticket_?.state_?.name=='用车中'">
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="addForm.end_time"
|
v-model="addForm.end_time"
|
||||||
type="date"
|
type="datetime"
|
||||||
align="right"
|
align="right"
|
||||||
value-format="YYYY-MM-DD"
|
value-format="YYYY-MM-DD HH:mm:ss"
|
||||||
unlink-panels
|
unlink-panels
|
||||||
placeholder="选择日期"
|
placeholder="选择日期"
|
||||||
>
|
>
|
||||||
</el-date-picker>
|
</el-date-picker>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-footer v-show="mode!=='show'">
|
<el-footer>
|
||||||
<ticketd_b
|
<ticketd_b
|
||||||
:workflow_key="'vehicle'"
|
:workflow_key="'vehicle'"
|
||||||
:title="ticketTitle"
|
:title="ticketTitle"
|
||||||
:t_id="addForm.id"
|
:t_id="addForm.id"
|
||||||
:ticket_="addForm.ticket_"
|
|
||||||
:submit_b_func="submit_b_func"
|
:submit_b_func="submit_b_func"
|
||||||
|
:ticket_="addForm.ticket_"
|
||||||
:ticket_data="ticket_data"
|
:ticket_data="ticket_data"
|
||||||
ref="ticketd_b"
|
ref="ticketd_b"
|
||||||
@success="$emit('success')"
|
@success="$emit('success')"
|
||||||
@colsed="$emit('closed')"
|
|
||||||
/>
|
/>
|
||||||
</el-footer>
|
</el-footer>
|
||||||
</el-main>
|
</el-main>
|
||||||
|
|
@ -92,60 +87,33 @@ import ticketd_b from "@/views/wf/ticketd_b.vue";
|
||||||
import ticketd from '@/views/wf/ticketd.vue'
|
import ticketd from '@/views/wf/ticketd.vue'
|
||||||
export default {
|
export default {
|
||||||
props: {
|
props: {
|
||||||
mode: { type: String, default: "view" }, // add / edit / view
|
mode: {
|
||||||
modelValue: { type: Object, default: () => ({}) },
|
type: String, default: "show"
|
||||||
transitions: { type: Array, default: () => [] },
|
}, // add / edit / show
|
||||||
t_id: {
|
t_id: {
|
||||||
type: String,
|
type: String,
|
||||||
default: null
|
default: null
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
components: {ticketd, ticketd_b},
|
components: {ticketd, ticketd_b},
|
||||||
emits: ["update:modelValue", "submit", "cancel"],
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
addForm: {
|
addForm: {},
|
||||||
ticket_: {
|
ticketTitle: "用车申请",
|
||||||
state_: { type: '' }
|
ticket_data: {},
|
||||||
},
|
localMode : this.mode,
|
||||||
...this.modelValue },
|
rules:{
|
||||||
|
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
||||||
ticketTitle: "用车申请",
|
},
|
||||||
ticket_data: {},
|
}
|
||||||
localMode : this.mode,
|
|
||||||
rules:{
|
|
||||||
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
|
||||||
},
|
|
||||||
workflow_key: "vehicle_in",
|
|
||||||
vehicle_scope:[{name: '市内', is_city: true},{name: '市外', is_city: false}],
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
if (this.addForm.ticket_?.state_.type===1){
|
let that = this;
|
||||||
this.localMode = 'edit'
|
if (that.t_id) {
|
||||||
};
|
that.getTid();
|
||||||
this.ticket_data = {
|
}
|
||||||
...this.ticket_data,
|
|
||||||
is_city: this.addForm.is_city,
|
|
||||||
};
|
|
||||||
this.getTid();
|
|
||||||
|
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
// 父组件数据变动 -> 同步到本地
|
|
||||||
modelValue: {
|
|
||||||
handler(val) {
|
|
||||||
this.addForm = { ...val };
|
|
||||||
},
|
|
||||||
deep: true,
|
|
||||||
},
|
|
||||||
// 本地数据变动 -> 同步回父组件
|
|
||||||
addForm: {
|
|
||||||
handler(val) {
|
|
||||||
this.$emit("update:modelValue", val);
|
|
||||||
},
|
|
||||||
deep: true,
|
|
||||||
},
|
|
||||||
addForm: {
|
addForm: {
|
||||||
handler(val) {
|
handler(val) {
|
||||||
Object.assign(this.ticket_data, {
|
Object.assign(this.ticket_data, {
|
||||||
|
|
@ -157,23 +125,16 @@ export default {
|
||||||
deep: true,
|
deep: true,
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
methods: {
|
methods: {
|
||||||
async submit_b_func() {
|
async submit_b_func() {
|
||||||
let that = this;
|
let that = this;
|
||||||
if (this.addForm.is_city === true){
|
if(that.localMode == "add") {
|
||||||
that.workflow_key = "vehicle"
|
let res = await that.$API.ofm.vehicle.create.req(that.addForm);
|
||||||
}else{
|
that.addForm.id = res.id;
|
||||||
that.workflow_key = "vehicle_out"
|
} else if (that.localMode == "edit") {
|
||||||
}
|
await that.$API.ofm.vehicle.update.req(that.addForm.id, that.addForm);
|
||||||
this.ticketTitle = `${this.addForm.reason}-用车申请`
|
}
|
||||||
if(that.localMode == "add") {
|
},
|
||||||
let res = await that.$API.ofm.vehicle.create.req(that.addForm);
|
|
||||||
that.addForm.id = res.id;
|
|
||||||
} else if (that.localMode == "edit") {
|
|
||||||
await that.$API.ofm.vehicle.update.req(that.addForm.id, that.addForm);
|
|
||||||
}
|
|
||||||
},
|
|
||||||
getTid (){
|
getTid (){
|
||||||
var that = this;
|
var that = this;
|
||||||
if (that.t_id) {
|
if (that.t_id) {
|
||||||
|
|
|
||||||
|
|
@ -94,24 +94,22 @@
|
||||||
<span v-else>—</span>
|
<span v-else>—</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="所在节点" min-width="60">
|
<el-table-column label="审批信息" width="200">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
{{scope.row.ticket_?.state_?.name}}
|
<el-tag :type="actStateEnum[scope.row.ticket_?.act_state]?.type">
|
||||||
|
{{ actStateEnum[scope.row.ticket_?.act_state]?.text }}
|
||||||
|
</el-tag>
|
||||||
|
<el-tag type="info" effect="plain">{{ scope.row.ticket_?.state_.name }}</el-tag>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="进行状态" min-width="60">
|
|
||||||
<template #default="scope">
|
|
||||||
{{statusOptions[scope.row.ticket_?.state_?.type]}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作" fixed="right" align="center" width="120">
|
<el-table-column label="操作" fixed="right" align="center" width="120">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
link
|
link
|
||||||
size="small"
|
size="small"
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="paperseEdit(scope.row)"
|
@click="paperseShow(scope.row)"
|
||||||
v-auth="'PaperSe.update'"
|
|
||||||
>详情
|
>详情
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-popconfirm
|
<el-popconfirm
|
||||||
|
|
@ -134,7 +132,7 @@
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
<el-drawer
|
<el-drawer
|
||||||
:title="drawerTitle[mode]"
|
title="专利管理"
|
||||||
v-model="limitedVisible"
|
v-model="limitedVisible"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
direction="rtl"
|
direction="rtl"
|
||||||
|
|
@ -144,8 +142,7 @@
|
||||||
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
||||||
<PaperForm
|
<PaperForm
|
||||||
:mode="mode"
|
:mode="mode"
|
||||||
v-model="addForm"
|
:t_id="t_id"
|
||||||
:transitions="transitions"
|
|
||||||
@success="()=>{handleQuery(); limitedVisible = false}"
|
@success="()=>{handleQuery(); limitedVisible = false}"
|
||||||
@closed="limitedVisible = false"
|
@closed="limitedVisible = false"
|
||||||
/>
|
/>
|
||||||
|
|
@ -156,116 +153,57 @@
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
import PaperForm from "./paperse_form.vue";
|
import PaperForm from "./paperse_form.vue";
|
||||||
|
import { actStateEnum, interveneTypeEnum } from "@/utils/enum.js";
|
||||||
export default {
|
export default {
|
||||||
components: { PaperForm},
|
components: { PaperForm},
|
||||||
name: "index",
|
name: "index",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
workflowName:"",
|
actStateEnum, interveneTypeEnum,
|
||||||
workFlowId:'',
|
|
||||||
apiObj: this.$API.srm.papersecret.list,
|
apiObj: this.$API.srm.papersecret.list,
|
||||||
selection: [],
|
t_id: null,
|
||||||
checkList: [],
|
|
||||||
fileList: [],
|
|
||||||
transitions:[],
|
|
||||||
timeRange: [],
|
|
||||||
lending_type: "",
|
|
||||||
query: {},
|
|
||||||
editId: null,
|
|
||||||
isSaving: false,
|
|
||||||
limitedVisible: false,
|
limitedVisible: false,
|
||||||
mode: "add",
|
mode: "show",
|
||||||
drawerTitle: {
|
fileList: [],
|
||||||
add: "新增论文申密",
|
query: {},
|
||||||
edit: "审批流",
|
|
||||||
view: "查看论文申密",
|
|
||||||
},
|
|
||||||
statusOptions:{
|
|
||||||
0: "审批中",
|
|
||||||
1: "初始中",
|
|
||||||
2: "已完成",
|
|
||||||
},
|
|
||||||
currentRow: null,
|
|
||||||
//表单数据
|
|
||||||
addForm: {
|
|
||||||
paper_name: "",
|
|
||||||
publication_name:"",
|
|
||||||
author: "",
|
|
||||||
paper_type: "",
|
|
||||||
is_chinese_core: false,
|
|
||||||
is_sci: false,
|
|
||||||
tech_status: [],
|
|
||||||
tech_file: [],
|
|
||||||
ticket_:null
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted(){
|
|
||||||
let that = this;
|
|
||||||
that.getInit();
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
//添加工作流
|
|
||||||
//渲染工单提交按钮
|
|
||||||
getInit() {
|
|
||||||
let that = this;
|
|
||||||
if(this.addForm.ticket_!==null){
|
|
||||||
this.$API.wf.ticket_.ticketTransitions.req(this.addForm.ticket_).then((res) => {
|
|
||||||
that.transitions = res;
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
that.$API.wf.workflow.initkey.req("paperse").then((res) => {
|
|
||||||
that.initForm = res;
|
|
||||||
that.transitions = res.transitions;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.mode = "add";
|
this.mode = "add";
|
||||||
this.addForm = this.getDefaultForm();
|
this.t_id = null;
|
||||||
this.lending_type = "";
|
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
},
|
},
|
||||||
handleCancel() {
|
// getDefaultForm(){
|
||||||
this.limitedVisible = false; // 关闭弹窗
|
// return {
|
||||||
this.lending_type = ""; // 重置 lending_type
|
// paper_name: "",
|
||||||
this.getDefaultForm()// 清空表单
|
// publication_name:"",
|
||||||
},
|
// author: "",
|
||||||
|
// paper_type: "",
|
||||||
getDefaultForm(){
|
// is_chinese_core: false,
|
||||||
return {
|
// is_sci: false,
|
||||||
paper_name: "",
|
// tech_status: [{ name: "是否进行过科技成果鉴定", status: "", fileList: [] },
|
||||||
publication_name:"",
|
// { name: "是否发表过文章", status: "", fileList: [] },
|
||||||
author: "",
|
// { name: "是否参与过展会展出", status: "", fileList: [] },
|
||||||
paper_type: "",
|
// { name: "是否应用于生产/销售", status: "", fileList: [] },
|
||||||
is_chinese_core: false,
|
// { name: "是否参与过技术交流", status: "", fileList: [] }],
|
||||||
is_sci: false,
|
// tech_file: [ { name: "论文内容", status: "", pages: "" },
|
||||||
tech_status: [{ name: "是否进行过科技成果鉴定", status: "", fileList: [] },
|
// { name: "图或者照片", pages: "" }],
|
||||||
{ name: "是否发表过文章", status: "", fileList: [] },
|
// ticket_:null
|
||||||
{ name: "是否参与过展会展出", status: "", fileList: [] },
|
// }
|
||||||
{ name: "是否应用于生产/销售", status: "", fileList: [] },
|
// },
|
||||||
{ name: "是否参与过技术交流", status: "", fileList: [] }],
|
|
||||||
tech_file: [ { name: "论文内容", status: "", pages: "" },
|
|
||||||
{ name: "图或者照片", pages: "" }],
|
|
||||||
ticket_:null
|
|
||||||
}
|
|
||||||
},
|
|
||||||
// 审批流结束之后才可以编辑
|
// 审批流结束之后才可以编辑
|
||||||
paperseEdit(row) {
|
paperseShow(row) {
|
||||||
this.mode = "view";
|
this.mode = "show";
|
||||||
this.editId = row.id;
|
this.t_id = row.id;
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
this.addForm = Object.assign({}, row);
|
|
||||||
},
|
},
|
||||||
async papersetDel(row) {
|
async papersetDel(row) {
|
||||||
var id = row.id;
|
var id = row.id;
|
||||||
var res = await this.$API.srm.papersecret.delete.req(id);
|
var res = await this.$API.srm.papersecret.delete.req(id);
|
||||||
if (res.err_msg) {
|
this.$refs.table.refresh();
|
||||||
this.$message.error(res.err_msg);
|
this.$message.success("删除成功");
|
||||||
} else {
|
|
||||||
this.$refs.table.refresh();
|
|
||||||
this.$message.success("删除成功");
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
//搜索
|
//搜索
|
||||||
handleQuery() {
|
handleQuery() {
|
||||||
|
|
|
||||||
|
|
@ -3,28 +3,28 @@
|
||||||
<el-main>
|
<el-main>
|
||||||
<el-form :model="localForm" label-width="150px" label-position="left" :rules="rules">
|
<el-form :model="localForm" label-width="150px" label-position="left" :rules="rules">
|
||||||
<el-form-item label="拟发表论文名称" prop="paper_name">
|
<el-form-item label="拟发表论文名称" prop="paper_name">
|
||||||
<el-input v-model="localForm.paper_name" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="localForm.paper_name" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="拟投期刊名称" prop="publication_name">
|
<el-form-item label="拟投期刊名称" prop="publication_name">
|
||||||
<el-input v-model="localForm.publication_name" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="localForm.publication_name" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="作者" prop="author" >
|
<el-form-item label="作者" prop="author" >
|
||||||
<el-input v-model="localForm.author" clearable ></el-input>
|
<el-input v-model="localForm.author" clearable ></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="拟发表文章类型" prop="paper_type">
|
<el-form-item label="拟发表文章类型" prop="paper_type">
|
||||||
<el-select v-model="localForm.paper_type" placeholder="请选择拟发表文章类型" :disabled="localMode ==='view'">
|
<el-select v-model="localForm.paper_type" placeholder="请选择拟发表文章类型" :disabled="localMode ==='show'">
|
||||||
<el-option label="研究论文" value="研究论文"></el-option>
|
<el-option label="研究论文" value="研究论文"></el-option>
|
||||||
<el-option label="综述" value="综述"></el-option>
|
<el-option label="综述" value="综述"></el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="是否为中文核心" prop="is_chinese_core">
|
<el-form-item label="是否为中文核心" prop="is_chinese_core">
|
||||||
<el-radio-group v-model="localForm.is_chinese_core" :disabled="localMode ==='view'">
|
<el-radio-group v-model="localForm.is_chinese_core" :disabled="localMode ==='show'">
|
||||||
<el-radio :label="true">是</el-radio>
|
<el-radio :label="true">是</el-radio>
|
||||||
<el-radio :label="false">否</el-radio>
|
<el-radio :label="false">否</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="是否被SCI/EI收录" prop="is_sci">
|
<el-form-item label="是否被SCI/EI收录" prop="is_sci">
|
||||||
<el-radio-group v-model="localForm.is_sci" :disabled="localMode ==='view'">
|
<el-radio-group v-model="localForm.is_sci" :disabled="localMode ==='show'">
|
||||||
<el-radio :label="true">是</el-radio>
|
<el-radio :label="true">是</el-radio>
|
||||||
<el-radio :label="false">否</el-radio>
|
<el-radio :label="false">否</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
|
|
@ -34,7 +34,7 @@
|
||||||
<el-col :span="12" v-for="(item, index) in localForm.tech_status || []" :key="index">
|
<el-col :span="12" v-for="(item, index) in localForm.tech_status || []" :key="index">
|
||||||
<div class="class-row">
|
<div class="class-row">
|
||||||
<span>{{ item.name }}</span>
|
<span>{{ item.name }}</span>
|
||||||
<el-radio-group v-model="item.status" @change="handleStatusChange(item)" style="margin-left: 20px;" :disabled="localMode ==='view'">
|
<el-radio-group v-model="item.status" @change="handleStatusChange(item)" style="margin-left: 20px;" :disabled="localMode ==='show'">
|
||||||
<el-radio label="是">是</el-radio>
|
<el-radio label="是">是</el-radio>
|
||||||
<el-radio label="否">否</el-radio>
|
<el-radio label="否">否</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
|
|
@ -42,27 +42,32 @@
|
||||||
<div v-if="item.status === '是'" class="upload-section">
|
<div v-if="item.status === '是'" class="upload-section">
|
||||||
<sc-upload-file
|
<sc-upload-file
|
||||||
multiple
|
multiple
|
||||||
:limit="3"
|
:limit="1"
|
||||||
:accept="['.xlsx', '.xls','.pdf','.docx', '.doc', '.jpg', '.png', '.jpeg']"
|
:accept="['.xlsx', '.xls','.pdf','.docx', '.doc', '.jpg', '.png', '.jpeg']"
|
||||||
@success = "(res)=>fileUPSuccess(res, item)"
|
@success = "(res)=>fileUPSuccess(res, item)"
|
||||||
:disabled="localMode ==='view'"
|
:disabled="localMode ==='show'"
|
||||||
>
|
>
|
||||||
<el-button type="primary" size="small" icon="el-icon-upload"> </el-button>
|
<el-button type="primary" size="small" icon="el-icon-upload"> </el-button>
|
||||||
</sc-upload-file>
|
</sc-upload-file>
|
||||||
|
<div v-if="item.file" class="file-list">
|
||||||
|
<el-link type="primary" :href="item.file" target="_blank">
|
||||||
|
{{ item.file.split('/').pop() }}
|
||||||
|
</el-link>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="技术文件" prop="tech_file">
|
<el-form-item label="技术文件" prop="tech_file">
|
||||||
<div class="file-item" v-for="(item, index) in localForm.tech_file || []" :key="index">
|
<div class="file-item" v-for="(item, index) in localForm.tech_file || []" :key="index">
|
||||||
<el-checkbox class="file-checkbox" v-model="item.checked" @change="handleCheckChange(item)" :disabled="localMode ==='view'">
|
<el-checkbox class="file-checkbox" v-model="item.checked" @change="handleCheckChange(item)" :disabled="localMode ==='show'">
|
||||||
{{ item.name }}
|
{{ item.name }}
|
||||||
</el-checkbox>
|
</el-checkbox>
|
||||||
<el-input
|
<el-input
|
||||||
class="page-input"
|
class="page-input"
|
||||||
v-model="item.pages"
|
v-model="item.pages"
|
||||||
placeholder="页/张数"
|
placeholder="页/张数"
|
||||||
:disabled="!item.checked || localMode ==='view'"
|
:disabled="!item.checked || localMode ==='show'"
|
||||||
type="number"
|
type="number"
|
||||||
min="0">
|
min="0">
|
||||||
<template v-slot:append>页/张</template>
|
<template v-slot:append>页/张</template>
|
||||||
|
|
@ -70,7 +75,7 @@
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-footer v-show="localMode!=='show'">
|
<el-footer>
|
||||||
<ticketd_b
|
<ticketd_b
|
||||||
:workflow_key="'paperse'"
|
:workflow_key="'paperse'"
|
||||||
:title="ticketTitle"
|
:title="ticketTitle"
|
||||||
|
|
@ -80,7 +85,6 @@
|
||||||
:submit_b_func="submit_b_func"
|
:submit_b_func="submit_b_func"
|
||||||
ref="ticketd_b"
|
ref="ticketd_b"
|
||||||
@success="$emit('success')"
|
@success="$emit('success')"
|
||||||
@colsed="$emit('closed')"
|
|
||||||
/>
|
/>
|
||||||
</el-footer>
|
</el-footer>
|
||||||
</el-main>
|
</el-main>
|
||||||
|
|
@ -100,42 +104,48 @@ import ticketd_b from "@/views/wf/ticketd_b.vue";
|
||||||
import ticketd from '@/views/wf/ticketd.vue'
|
import ticketd from '@/views/wf/ticketd.vue'
|
||||||
export default {
|
export default {
|
||||||
props: {
|
props: {
|
||||||
mode: { type: String, default: "view" }, // add / edit / view
|
mode: { type: String,
|
||||||
modelValue: { type: Object, default: () => ({}) },
|
default: "show"
|
||||||
|
},
|
||||||
t_id: {
|
t_id: {
|
||||||
type: String,
|
type: String,
|
||||||
default: null
|
default: null
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
components: {ticketd, ticketd_b},
|
components: {ticketd, ticketd_b},
|
||||||
emits: ["update:modelValue", "submit", "cancel"],
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
ticket_data: {},
|
ticket_data: {},
|
||||||
ticketTitle: "论文申密申请",
|
ticketTitle: "论文申密申请",
|
||||||
localMode : this.mode,
|
localMode : this.mode,
|
||||||
|
localForm: {
|
||||||
|
paper_name: "",
|
||||||
|
publication_name:"",
|
||||||
|
author: "",
|
||||||
|
paper_type: "",
|
||||||
|
is_chinese_core: false,
|
||||||
|
is_sci: false,
|
||||||
|
tech_status: [{ name: "是否进行过科技成果鉴定", status: "", fileList: [] },
|
||||||
|
{ name: "是否发表过文章", status: "", fileList: [] },
|
||||||
|
{ name: "是否参与过展会展出", status: "", fileList: [] },
|
||||||
|
{ name: "是否应用于生产/销售", status: "", fileList: [] },
|
||||||
|
{ name: "是否参与过技术交流", status: "", fileList: [] }],
|
||||||
|
tech_file: [ { name: "论文内容", status: "", pages: "" },
|
||||||
|
{ name: "图或者照片", pages: "" }],
|
||||||
|
ticket_:null
|
||||||
|
},
|
||||||
rules: {
|
rules: {
|
||||||
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
||||||
},
|
},
|
||||||
localForm: {
|
|
||||||
ticket_: { state_: { type: '' } },
|
|
||||||
...(this.modelValue || {}) }
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
console.log('mode', this.localMode)
|
let that = this;
|
||||||
|
if (that.t_id) {
|
||||||
|
that.getTid();
|
||||||
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
|
||||||
localForm: {
|
|
||||||
handler(val) {
|
|
||||||
Object.assign(this.ticket_data, {
|
|
||||||
author: val.author,
|
|
||||||
// 其他需要同步的字段...
|
|
||||||
});
|
|
||||||
},
|
|
||||||
deep: true,
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
async submit_b_func() {
|
async submit_b_func() {
|
||||||
let that = this;
|
let that = this;
|
||||||
|
|
@ -144,7 +154,6 @@ export default {
|
||||||
}
|
}
|
||||||
if(that.localMode == "add") {
|
if(that.localMode == "add") {
|
||||||
let res = await that.$API.srm.papersecret.create.req(that.localForm);
|
let res = await that.$API.srm.papersecret.create.req(that.localForm);
|
||||||
|
|
||||||
that.localForm.id = res.id;
|
that.localForm.id = res.id;
|
||||||
} else if (that.localMode == "edit") {
|
} else if (that.localMode == "edit") {
|
||||||
await that.$API.srm.papersecret.update.req(that.localForm.id, that.localForm);
|
await that.$API.srm.papersecret.update.req(that.localForm.id, that.localForm);
|
||||||
|
|
|
||||||
|
|
@ -98,24 +98,22 @@
|
||||||
<span v-else>—</span>
|
<span v-else>—</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="所在节点" min-width="60">
|
<el-table-column label="审批信息" width="200">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
{{scope.row.ticket_.state_.name}}
|
<el-tag :type="actStateEnum[scope.row.ticket_?.act_state]?.type">
|
||||||
|
{{ actStateEnum[scope.row.ticket_?.act_state]?.text }}
|
||||||
|
</el-tag>
|
||||||
|
<el-tag type="info" effect="plain">{{ scope.row.ticket_?.state_.name }}</el-tag>
|
||||||
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="进行状态" min-width="60">
|
|
||||||
<template #default="scope">
|
|
||||||
{{statusOptions[scope.row.ticket_.state_.type]}}
|
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="操作" fixed="right" align="center" width="120">
|
<el-table-column label="操作" fixed="right" align="center" width="120">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<el-button
|
<el-button
|
||||||
link
|
link
|
||||||
size="small"
|
size="small"
|
||||||
type="primary"
|
type="primary"
|
||||||
@click="patentEdit(scope.row)"
|
@click="patentShow(scope.row)"
|
||||||
v-auth="'patentinfo.update'"
|
|
||||||
>详情
|
>详情
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-popconfirm
|
<el-popconfirm
|
||||||
|
|
@ -138,7 +136,7 @@
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
<el-drawer
|
<el-drawer
|
||||||
:title="drawerTitle[mode]"
|
title="专利审批"
|
||||||
v-model="limitedVisible"
|
v-model="limitedVisible"
|
||||||
:destroy-on-close="true"
|
:destroy-on-close="true"
|
||||||
direction="rtl"
|
direction="rtl"
|
||||||
|
|
@ -148,8 +146,7 @@
|
||||||
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
||||||
<PatentForm
|
<PatentForm
|
||||||
:mode="mode"
|
:mode="mode"
|
||||||
v-model="addForm"
|
:t_id="t_id"
|
||||||
:transitions="transitions"
|
|
||||||
@success="()=>{handleQuery(); limitedVisible = false}"
|
@success="()=>{handleQuery(); limitedVisible = false}"
|
||||||
@closed="limitedVisible = false"
|
@closed="limitedVisible = false"
|
||||||
/>
|
/>
|
||||||
|
|
@ -160,25 +157,19 @@
|
||||||
<script>
|
<script>
|
||||||
|
|
||||||
import PatentForm from "./patent_form.vue";
|
import PatentForm from "./patent_form.vue";
|
||||||
|
import { actStateEnum, interveneTypeEnum } from "@/utils/enum.js";
|
||||||
export default {
|
export default {
|
||||||
components: { PatentForm},
|
components: { PatentForm},
|
||||||
name: "index",
|
name: "index",
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
workflowName:"",
|
actStateEnum, interveneTypeEnum,
|
||||||
workFlowId:'',
|
|
||||||
apiObj: this.$API.srm.patentinfo.list,
|
apiObj: this.$API.srm.patentinfo.list,
|
||||||
selection: [],
|
|
||||||
checkList: [],
|
|
||||||
fileList: [],
|
fileList: [],
|
||||||
transitions:[],
|
|
||||||
timeRange: [],
|
|
||||||
lending_type: "",
|
|
||||||
query: {},
|
query: {},
|
||||||
editId: null,
|
t_id:null,
|
||||||
isSaving: false,
|
|
||||||
limitedVisible: false,
|
limitedVisible: false,
|
||||||
mode: "add",
|
mode: "show",
|
||||||
patentType: {
|
patentType: {
|
||||||
"invention": "发明专利",
|
"invention": "发明专利",
|
||||||
"utility": "实用新型",
|
"utility": "实用新型",
|
||||||
|
|
@ -189,156 +180,53 @@ export default {
|
||||||
'Foreign':'国外申请',
|
'Foreign':'国外申请',
|
||||||
'PCT':'PCT申请',
|
'PCT':'PCT申请',
|
||||||
},
|
},
|
||||||
drawerTitle: {
|
|
||||||
add: "新增专利申密",
|
|
||||||
edit: "审批流",
|
|
||||||
view: "查看专利申密",
|
|
||||||
},
|
|
||||||
statusOptions:{
|
|
||||||
0: "审批中",
|
|
||||||
1: "初始中",
|
|
||||||
2: "已完成",
|
|
||||||
},
|
|
||||||
currentRow: null,
|
|
||||||
//表单数据
|
|
||||||
addForm: {
|
|
||||||
author: "",
|
|
||||||
name: "",
|
|
||||||
type: "",
|
|
||||||
is_public: false,
|
|
||||||
area: null,
|
|
||||||
other_area: null,
|
|
||||||
tech_status: [],
|
|
||||||
tech_file: [],
|
|
||||||
ticket_:null
|
|
||||||
},
|
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
mounted(){
|
|
||||||
let that = this;
|
|
||||||
that.getInit();
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
//添加工作流
|
|
||||||
//渲染工单提交按钮
|
|
||||||
getInit() {
|
|
||||||
let that = this;
|
|
||||||
if(this.addForm.ticket_!==null){
|
|
||||||
this.$API.wf.ticket_.ticketTransitions.req(this.addForm.ticket_).then((res) => {
|
|
||||||
that.transitions = res;
|
|
||||||
})
|
|
||||||
}else{
|
|
||||||
that.$API.wf.workflow.initkey.req("patent").then((res) => {
|
|
||||||
that.initForm = res;
|
|
||||||
that.transitions = res.transitions;
|
|
||||||
});
|
|
||||||
}
|
|
||||||
},
|
|
||||||
handleAdd() {
|
handleAdd() {
|
||||||
this.mode = "add";
|
this.mode = "add";
|
||||||
this.addForm = this.getDefaultForm();
|
this.t_id = null;
|
||||||
this.lending_type = "";
|
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
},
|
},
|
||||||
handleCancel() {
|
|
||||||
this.limitedVisible = false; // 关闭弹窗
|
|
||||||
this.lending_type = ""; // 重置 lending_type
|
|
||||||
this.getDefaultForm()// 清空表单
|
|
||||||
},
|
|
||||||
|
|
||||||
getDefaultForm(){
|
// getDefaultForm(){
|
||||||
return {
|
// return {
|
||||||
name: "",
|
// name: "",
|
||||||
author: "",
|
// author: "",
|
||||||
type: "",
|
// type: "",
|
||||||
is_public: false,
|
// is_public: false,
|
||||||
area: null,
|
// area: null,
|
||||||
other_area: null,
|
// other_area: null,
|
||||||
tech_status: [{ name: "是否进行过科技成果鉴定", status: "", fileList: [] },
|
// tech_status: [{ name: "是否进行过科技成果鉴定", status: "", fileList: [] },
|
||||||
{ name: "是否发表过文章", status: "", fileList: [] },
|
// { name: "是否发表过文章", status: "", fileList: [] },
|
||||||
{ name: "是否参与过展会展出", status: "", fileList: [] },
|
// { name: "是否参与过展会展出", status: "", fileList: [] },
|
||||||
{ name: "是否应用于生产/销售", status: "", fileList: [] },
|
// { name: "是否应用于生产/销售", status: "", fileList: [] },
|
||||||
{ name: "是否参与过技术交流", status: "", fileList: [] }],
|
// { name: "是否参与过技术交流", status: "", fileList: [] }],
|
||||||
tech_file: [ { name: "技术背景材料", status: "", pages: "" },
|
// tech_file: [ { name: "技术背景材料", status: "", pages: "" },
|
||||||
{ name: "技术交底材料", pages: "" },
|
// { name: "技术交底材料", pages: "" },
|
||||||
{ name: "查新检索报告", pages: "" },
|
// { name: "查新检索报告", pages: "" },
|
||||||
{ name: "图或者照片", pages: "" }],
|
// { name: "图或者照片", pages: "" }],
|
||||||
ticket_:null
|
// ticket_:null
|
||||||
}
|
// }
|
||||||
},
|
// },
|
||||||
// 审批流结束之后才可以编辑
|
// 审批流结束之后才可以编辑
|
||||||
patentEdit(row) {
|
patentShow(row) {
|
||||||
this.mode = "view";
|
this.mode = "show";
|
||||||
this.editId = row.id;
|
this.t_id = row.id;
|
||||||
this.limitedVisible = true;
|
this.limitedVisible = true;
|
||||||
this.addForm = Object.assign({}, row);
|
|
||||||
},
|
},
|
||||||
async patentDel(row) {
|
async patentDel(row) {
|
||||||
var id = row.id;
|
var id = row.id;
|
||||||
var res = await this.$API.srm.patentinfo.delete.req(id);
|
var res = await this.$API.srm.patentinfo.delete.req(id);
|
||||||
if (res.err_msg) {
|
this.$refs.table.refresh();
|
||||||
this.$message.error(res.err_msg);
|
this.$message.success("删除成功");
|
||||||
} else {
|
|
||||||
this.$refs.table.refresh();
|
|
||||||
this.$message.success("删除成功");
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
//搜索
|
//搜索
|
||||||
handleQuery() {
|
handleQuery() {
|
||||||
this.$refs.table.queryData(this.query);
|
this.$refs.table.queryData(this.query);
|
||||||
},
|
},
|
||||||
|
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
</script>
|
</script>
|
||||||
<style scoped>
|
|
||||||
.treeMain {
|
|
||||||
height: 280px;
|
|
||||||
overflow: auto;
|
|
||||||
border: 1px solid #dcdfe6;
|
|
||||||
margin-bottom: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar {
|
|
||||||
width: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-track {
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.2);
|
|
||||||
background-color: #fefefe;
|
|
||||||
border-radius: 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
::-webkit-scrollbar-thumb {
|
|
||||||
border-radius: 5px;
|
|
||||||
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
|
|
||||||
background-color: #f5f5f5;
|
|
||||||
}
|
|
||||||
.node rect {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #fff;
|
|
||||||
}
|
|
||||||
|
|
||||||
.edgePath path {
|
|
||||||
stroke: #606266;
|
|
||||||
fill: #333;
|
|
||||||
stroke-width: 1.5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
g.conditions > rect {
|
|
||||||
fill: #00ffd0;
|
|
||||||
stroke: #000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.el-icon-close {
|
|
||||||
cursor: pointer;
|
|
||||||
}
|
|
||||||
|
|
||||||
.left-panel-group {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
gap: 6px; /* 按钮之间的间隙,可以调小点 */
|
|
||||||
margin-left: 0; /* 靠左 */
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@
|
||||||
<el-main>
|
<el-main>
|
||||||
<el-form :model="localForm" label-width="150px" label-position="left" :rules="rules">
|
<el-form :model="localForm" label-width="150px" label-position="left" :rules="rules">
|
||||||
<el-form-item label="拟申请专利名称" prop="name">
|
<el-form-item label="拟申请专利名称" prop="name">
|
||||||
<el-input v-model="localForm.name" clearable :disabled="localMode ==='view'"></el-input>
|
<el-input v-model="localForm.name" clearable :disabled="localMode ==='show'"></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="发明人(设计人)"
|
<el-form-item label="发明人(设计人)"
|
||||||
prop="author"
|
prop="author"
|
||||||
|
|
@ -11,20 +11,20 @@
|
||||||
<el-input v-model="localForm.author" clearable ></el-input>
|
<el-input v-model="localForm.author" clearable ></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="专利类型" prop="type">
|
<el-form-item label="专利类型" prop="type">
|
||||||
<el-select v-model="localForm.type" placeholder="请选择专利类型" :disabled="localMode ==='view'">
|
<el-select v-model="localForm.type" placeholder="请选择专利类型" :disabled="localMode ==='show'">
|
||||||
<el-option label="发明专利" value="invention"></el-option>
|
<el-option label="发明专利" value="invention"></el-option>
|
||||||
<el-option label="实用新型专利" value="utility"></el-option>
|
<el-option label="实用新型专利" value="utility"></el-option>
|
||||||
<el-option label="外观设计专利" value="design"></el-option>
|
<el-option label="外观设计专利" value="design"></el-option>
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="是否公开" prop="is_public">
|
<el-form-item label="是否公开" prop="is_public">
|
||||||
<el-radio-group v-model="localForm.is_public" :disabled="localMode ==='view'">
|
<el-radio-group v-model="localForm.is_public" :disabled="localMode ==='show'">
|
||||||
<el-radio :label="true">是</el-radio>
|
<el-radio :label="true">是</el-radio>
|
||||||
<el-radio :label="false">否</el-radio>
|
<el-radio :label="false">否</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="拟申请地域">
|
<el-form-item label="拟申请地域">
|
||||||
<el-radio-group v-model="localForm.area" :disabled="localMode ==='view'">
|
<el-radio-group v-model="localForm.area" :disabled="localMode ==='show'">
|
||||||
<el-radio label="国内申请" value="Domestic"></el-radio>
|
<el-radio label="国内申请" value="Domestic"></el-radio>
|
||||||
<el-radio label="国外申请" value="Foreign"></el-radio>
|
<el-radio label="国外申请" value="Foreign"></el-radio>
|
||||||
<el-radio label="PCT申请" value="PCT"></el-radio>
|
<el-radio label="PCT申请" value="PCT"></el-radio>
|
||||||
|
|
@ -35,7 +35,7 @@
|
||||||
placeholder = "请输入申请的国家"
|
placeholder = "请输入申请的国家"
|
||||||
size = "small"
|
size = "small"
|
||||||
style="margin-top: 10;"
|
style="margin-top: 10;"
|
||||||
:disabled="localMode ==='view'"
|
:disabled="localMode ==='show'"
|
||||||
></el-input>
|
></el-input>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="技术状态" prop="tech_status">
|
<el-form-item label="技术状态" prop="tech_status">
|
||||||
|
|
@ -43,7 +43,7 @@
|
||||||
<el-col :span="12" v-for="(item, index) in localForm.tech_status || []" :key="index">
|
<el-col :span="12" v-for="(item, index) in localForm.tech_status || []" :key="index">
|
||||||
<div class="class-row">
|
<div class="class-row">
|
||||||
<span>{{ item.name }}</span>
|
<span>{{ item.name }}</span>
|
||||||
<el-radio-group v-model="item.status" @change="handleStatusChange(item)" style="margin-left: 20px;" :disabled="localMode ==='view'">
|
<el-radio-group v-model="item.status" @change="handleStatusChange(item)" style="margin-left: 20px;" :disabled="localMode ==='show'">
|
||||||
<el-radio label="是">是</el-radio>
|
<el-radio label="是">是</el-radio>
|
||||||
<el-radio label="否">否</el-radio>
|
<el-radio label="否">否</el-radio>
|
||||||
</el-radio-group>
|
</el-radio-group>
|
||||||
|
|
@ -51,27 +51,32 @@
|
||||||
<div v-if="item.status === '是'" class="upload-section">
|
<div v-if="item.status === '是'" class="upload-section">
|
||||||
<sc-upload-file
|
<sc-upload-file
|
||||||
multiple
|
multiple
|
||||||
:limit="3"
|
:limit="1"
|
||||||
:accept="['.xlsx', '.xls','.pdf','.docx', '.doc', '.jpg', '.png', '.jpeg']"
|
:accept="['.xlsx', '.xls','.pdf','.docx', '.doc', '.jpg', '.png', '.jpeg']"
|
||||||
@success = "(res)=>fileUPSuccess(res, item)"
|
@success = "(res)=>fileUPSuccess(res, item)"
|
||||||
:disabled="localMode ==='view'"
|
:disabled="localMode ==='show'"
|
||||||
>
|
>
|
||||||
<el-button type="primary" size="small" icon="el-icon-upload"> </el-button>
|
<el-button type="primary" size="small" icon="el-icon-upload"> </el-button>
|
||||||
</sc-upload-file>
|
</sc-upload-file>
|
||||||
|
<div v-if="item.file && localMode ==='show'" class="file-list">
|
||||||
|
<el-link type="primary" :href="item.file" target="_blank">
|
||||||
|
{{ item.file.split('/').pop() }}
|
||||||
|
</el-link>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-col>
|
</el-col>
|
||||||
</el-row>
|
</el-row>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="技术文件" prop="tech_file">
|
<el-form-item label="技术文件" prop="tech_file">
|
||||||
<div class="file-item" v-for="(item, index) in localForm.tech_file || []" :key="index">
|
<div class="file-item" v-for="(item, index) in localForm.tech_file || []" :key="index">
|
||||||
<el-checkbox class="file-checkbox" v-model="item.checked" @change="handleCheckChange(item)" :disabled="localMode ==='view'">
|
<el-checkbox class="file-checkbox" v-model="item.checked" @change="handleCheckChange(item)" :disabled="localMode ==='show'">
|
||||||
{{ item.name }}
|
{{ item.name }}
|
||||||
</el-checkbox>
|
</el-checkbox>
|
||||||
<el-input
|
<el-input
|
||||||
class="page-input"
|
class="page-input"
|
||||||
v-model="item.pages"
|
v-model="item.pages"
|
||||||
placeholder="页数"
|
placeholder="页数"
|
||||||
:disabled="!item.checked || localMode ==='view'"
|
:disabled="!item.checked || localMode ==='show'"
|
||||||
type="number"
|
type="number"
|
||||||
min="0">
|
min="0">
|
||||||
<template v-slot:append>页</template>
|
<template v-slot:append>页</template>
|
||||||
|
|
@ -79,7 +84,7 @@
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<el-footer v-show="localMode!=='show'">
|
<el-footer>
|
||||||
<ticketd_b
|
<ticketd_b
|
||||||
:workflow_key="'patent'"
|
:workflow_key="'patent'"
|
||||||
:title="ticketTitle"
|
:title="ticketTitle"
|
||||||
|
|
@ -89,7 +94,6 @@
|
||||||
:submit_b_func="submit_b_func"
|
:submit_b_func="submit_b_func"
|
||||||
ref="ticketd_b"
|
ref="ticketd_b"
|
||||||
@success="$emit('success')"
|
@success="$emit('success')"
|
||||||
@colsed="$emit('closed')"
|
|
||||||
/>
|
/>
|
||||||
</el-footer>
|
</el-footer>
|
||||||
</el-main>
|
</el-main>
|
||||||
|
|
@ -109,15 +113,16 @@ import ticketd_b from "@/views/wf/ticketd_b.vue";
|
||||||
import ticketd from '@/views/wf/ticketd.vue'
|
import ticketd from '@/views/wf/ticketd.vue'
|
||||||
export default {
|
export default {
|
||||||
props: {
|
props: {
|
||||||
mode: { type: String, default: "view" }, // add / edit / view
|
mode: {
|
||||||
modelValue: { type: Object, default: () => ({}) },
|
type: String,
|
||||||
|
default: "show"
|
||||||
|
}, // add / edit / view
|
||||||
t_id: {
|
t_id: {
|
||||||
type: String,
|
type: String,
|
||||||
default: null
|
default: null
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
components: {ticketd, ticketd_b},
|
components: {ticketd, ticketd_b},
|
||||||
emits: ["update:modelValue", "submit", "cancel"],
|
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
ticket_data: {},
|
ticket_data: {},
|
||||||
|
|
@ -126,33 +131,38 @@ export default {
|
||||||
rules: {
|
rules: {
|
||||||
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
||||||
},
|
},
|
||||||
localForm: {
|
localForm:{
|
||||||
ticket_: { state_: { type: '' } },
|
name: "",
|
||||||
...(this.modelValue || {}) }
|
author: "",
|
||||||
|
type: "",
|
||||||
|
is_public: false,
|
||||||
|
area: null,
|
||||||
|
other_area: null,
|
||||||
|
tech_status: [{ name: "是否进行过科技成果鉴定", status: "", fileList: [] },
|
||||||
|
{ name: "是否发表过文章", status: "", fileList: [] },
|
||||||
|
{ name: "是否参与过展会展出", status: "", fileList: [] },
|
||||||
|
{ name: "是否应用于生产/销售", status: "", fileList: [] },
|
||||||
|
{ name: "是否参与过技术交流", status: "", fileList: [] }],
|
||||||
|
tech_file: [ { name: "技术背景材料", status: "", pages: "" },
|
||||||
|
{ name: "技术交底材料", pages: "" },
|
||||||
|
{ name: "查新检索报告", pages: "" },
|
||||||
|
{ name: "图或者照片", pages: "" }],
|
||||||
|
ticket_:null
|
||||||
|
},
|
||||||
};
|
};
|
||||||
},
|
},
|
||||||
// mounted() {
|
mounted() {
|
||||||
// let that = this;
|
let that = this;
|
||||||
// console.log('666666',that.ticket_data)
|
if (that.t_id) {
|
||||||
// },
|
that.getTid();
|
||||||
watch: {
|
}
|
||||||
localForm: {
|
},
|
||||||
handler(val) {
|
|
||||||
Object.assign(this.ticket_data, {
|
|
||||||
author: val.author,
|
|
||||||
// 其他需要同步的字段...
|
|
||||||
});
|
|
||||||
},
|
|
||||||
deep: true,
|
|
||||||
}
|
|
||||||
},
|
|
||||||
methods: {
|
methods: {
|
||||||
async submit_b_func() {
|
async submit_b_func() {
|
||||||
let that = this;
|
let that = this;
|
||||||
if(that.localForm?.id){
|
if(that.localForm?.id){
|
||||||
that.localMode = "edit";
|
that.localMode = "edit";
|
||||||
}
|
}
|
||||||
console.log('that.localForm',that.localMode, that.localForm)
|
|
||||||
if(that.localMode == "add") {
|
if(that.localMode == "add") {
|
||||||
let res = await that.$API.srm.patentinfo.create.req(that.localForm);
|
let res = await that.$API.srm.patentinfo.create.req(that.localForm);
|
||||||
that.localForm.id = res.id;
|
that.localForm.id = res.id;
|
||||||
|
|
@ -196,19 +206,4 @@ export default {
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
|
||||||
.status-item {
|
|
||||||
margin-bottom: 15px;
|
|
||||||
}
|
|
||||||
.status-row {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
justify-content: space-between;
|
|
||||||
}
|
|
||||||
.upload-section {
|
|
||||||
margin-left: 10px;
|
|
||||||
border-left: 2px solid #eee;
|
|
||||||
padding-left: 10px;
|
|
||||||
}
|
|
||||||
</style>
|
|
||||||
|
|
@ -0,0 +1,289 @@
|
||||||
|
<template>
|
||||||
|
<el-container>
|
||||||
|
<el-header>
|
||||||
|
<div class="left-panel-group">
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-plus"
|
||||||
|
@click="handleAdd"
|
||||||
|
v-auth="'PaperSe.create'"
|
||||||
|
>新增</el-button>
|
||||||
|
</div>
|
||||||
|
<!-- <div class="right-panel">
|
||||||
|
<el-input
|
||||||
|
v-model="query.paper_name"
|
||||||
|
placeholder="发表论文名称"
|
||||||
|
clearable
|
||||||
|
@keyup.enter="handleQuery"
|
||||||
|
></el-input>
|
||||||
|
<el-button
|
||||||
|
type="primary"
|
||||||
|
icon="el-icon-search"
|
||||||
|
@click="handleQuery"
|
||||||
|
></el-button>
|
||||||
|
</div> -->
|
||||||
|
</el-header>
|
||||||
|
<el-main class="nopadding">
|
||||||
|
<scTable ref="table" :apiObj="apiObj" row-key="id">
|
||||||
|
<el-table-column label="#" type="index"></el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="日期"
|
||||||
|
prop="p_date"
|
||||||
|
min-width="60"
|
||||||
|
></el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="归口部门"
|
||||||
|
prop="p_dept"
|
||||||
|
min-width="60"
|
||||||
|
></el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="建设期"
|
||||||
|
prop="const"
|
||||||
|
min-width="60"
|
||||||
|
></el-table-column>
|
||||||
|
<el-table-column label="市级平台" prop="city_p" mim-width="60">
|
||||||
|
<template #default="scope">
|
||||||
|
<span :style="{color: scope.row.city_p ? '#67C23A' : '#F56C6C'}">
|
||||||
|
{{ scope.row.city_p ? '是' : '否'}}
|
||||||
|
</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="省级平台" prop="province_p" mim-width="60">
|
||||||
|
<template #default="scope">
|
||||||
|
<span :style="{color: scope.row.province_p ? '#67C23A' : '#F56C6C'}">
|
||||||
|
{{ scope.row.province_p ? '是' : '否'}}
|
||||||
|
</span>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="负责人"
|
||||||
|
prop="charge"
|
||||||
|
min-width="60"
|
||||||
|
></el-table-column>
|
||||||
|
<el-table-column
|
||||||
|
label="平台基本情况与目标绩效"
|
||||||
|
prop="condition"
|
||||||
|
min-width="60"
|
||||||
|
></el-table-column>
|
||||||
|
<el-table-column label="操作" fixed="right" align="center" width="120">
|
||||||
|
<template #default="scope">
|
||||||
|
<el-button
|
||||||
|
link
|
||||||
|
size="small"
|
||||||
|
type="primary"
|
||||||
|
@click="paperseEdit(scope.row)"
|
||||||
|
v-auth="'PaperSe.update'"
|
||||||
|
>详情
|
||||||
|
</el-button>
|
||||||
|
<el-popconfirm
|
||||||
|
title="确定删除吗?"
|
||||||
|
@confirm="papersetDel(scope.row)"
|
||||||
|
>
|
||||||
|
<template #reference>
|
||||||
|
<el-button
|
||||||
|
link
|
||||||
|
size="small"
|
||||||
|
type="danger"
|
||||||
|
v-auth="'PaperSe.delete'"
|
||||||
|
>删除</el-button
|
||||||
|
>
|
||||||
|
</template>
|
||||||
|
</el-popconfirm>
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
</scTable>
|
||||||
|
</el-main>
|
||||||
|
</el-container>
|
||||||
|
<el-drawer
|
||||||
|
:title="drawerTitle[mode]"
|
||||||
|
v-model="limitedVisible"
|
||||||
|
:destroy-on-close="true"
|
||||||
|
direction="rtl"
|
||||||
|
size="70%"
|
||||||
|
>
|
||||||
|
<div style="display: flex; height: calc(100% - 60px);">
|
||||||
|
<div style="flex: 1; padding-right: 20px; overflow-y: auto;">
|
||||||
|
<PaperForm
|
||||||
|
:mode="mode"
|
||||||
|
v-model="addForm"
|
||||||
|
:transitions="transitions"
|
||||||
|
@success="()=>{handleQuery(); limitedVisible = false}"
|
||||||
|
@closed="limitedVisible = false"
|
||||||
|
/>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</el-drawer>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
|
||||||
|
import PaperForm from "./paperse_form.vue";
|
||||||
|
export default {
|
||||||
|
components: { PaperForm},
|
||||||
|
name: "index",
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
workflowName:"",
|
||||||
|
workFlowId:'',
|
||||||
|
apiObj: this.$API.srm.papersecret.list,
|
||||||
|
selection: [],
|
||||||
|
checkList: [],
|
||||||
|
fileList: [],
|
||||||
|
transitions:[],
|
||||||
|
timeRange: [],
|
||||||
|
lending_type: "",
|
||||||
|
query: {},
|
||||||
|
editId: null,
|
||||||
|
isSaving: false,
|
||||||
|
limitedVisible: false,
|
||||||
|
mode: "add",
|
||||||
|
drawerTitle: {
|
||||||
|
add: "新增论文申密",
|
||||||
|
edit: "审批流",
|
||||||
|
view: "查看论文申密",
|
||||||
|
},
|
||||||
|
statusOptions:{
|
||||||
|
0: "审批中",
|
||||||
|
1: "初始中",
|
||||||
|
2: "已完成",
|
||||||
|
},
|
||||||
|
currentRow: null,
|
||||||
|
//表单数据
|
||||||
|
addForm: {
|
||||||
|
paper_name: "",
|
||||||
|
publication_name:"",
|
||||||
|
author: "",
|
||||||
|
paper_type: "",
|
||||||
|
is_chinese_core: false,
|
||||||
|
is_sci: false,
|
||||||
|
tech_status: [],
|
||||||
|
tech_file: [],
|
||||||
|
ticket_:null
|
||||||
|
},
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted(){
|
||||||
|
let that = this;
|
||||||
|
that.getInit();
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
//添加工作流
|
||||||
|
//渲染工单提交按钮
|
||||||
|
getInit() {
|
||||||
|
let that = this;
|
||||||
|
if(this.addForm.ticket_!==null){
|
||||||
|
this.$API.wf.ticket_.ticketTransitions.req(this.addForm.ticket_).then((res) => {
|
||||||
|
that.transitions = res;
|
||||||
|
})
|
||||||
|
}else{
|
||||||
|
that.$API.wf.workflow.initkey.req("paperse").then((res) => {
|
||||||
|
that.initForm = res;
|
||||||
|
that.transitions = res.transitions;
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
handleAdd() {
|
||||||
|
this.mode = "add";
|
||||||
|
this.addForm = this.getDefaultForm();
|
||||||
|
this.lending_type = "";
|
||||||
|
this.limitedVisible = true;
|
||||||
|
},
|
||||||
|
handleCancel() {
|
||||||
|
this.limitedVisible = false; // 关闭弹窗
|
||||||
|
this.lending_type = ""; // 重置 lending_type
|
||||||
|
this.getDefaultForm()// 清空表单
|
||||||
|
},
|
||||||
|
|
||||||
|
getDefaultForm(){
|
||||||
|
return {
|
||||||
|
paper_name: "",
|
||||||
|
publication_name:"",
|
||||||
|
author: "",
|
||||||
|
paper_type: "",
|
||||||
|
is_chinese_core: false,
|
||||||
|
is_sci: false,
|
||||||
|
tech_status: [{ name: "是否进行过科技成果鉴定", status: "", fileList: [] },
|
||||||
|
{ name: "是否发表过文章", status: "", fileList: [] },
|
||||||
|
{ name: "是否参与过展会展出", status: "", fileList: [] },
|
||||||
|
{ name: "是否应用于生产/销售", status: "", fileList: [] },
|
||||||
|
{ name: "是否参与过技术交流", status: "", fileList: [] }],
|
||||||
|
tech_file: [ { name: "论文内容", status: "", pages: "" },
|
||||||
|
{ name: "图或者照片", pages: "" }],
|
||||||
|
ticket_:null
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 审批流结束之后才可以编辑
|
||||||
|
paperseEdit(row) {
|
||||||
|
this.mode = "view";
|
||||||
|
this.editId = row.id;
|
||||||
|
this.limitedVisible = true;
|
||||||
|
this.addForm = Object.assign({}, row);
|
||||||
|
},
|
||||||
|
async papersetDel(row) {
|
||||||
|
var id = row.id;
|
||||||
|
var res = await this.$API.srm.papersecret.delete.req(id);
|
||||||
|
if (res.err_msg) {
|
||||||
|
this.$message.error(res.err_msg);
|
||||||
|
} else {
|
||||||
|
this.$refs.table.refresh();
|
||||||
|
this.$message.success("删除成功");
|
||||||
|
}
|
||||||
|
},
|
||||||
|
//搜索
|
||||||
|
handleQuery() {
|
||||||
|
this.$refs.table.queryData(this.query);
|
||||||
|
},
|
||||||
|
|
||||||
|
},
|
||||||
|
};
|
||||||
|
</script>
|
||||||
|
<style scoped>
|
||||||
|
.treeMain {
|
||||||
|
height: 280px;
|
||||||
|
overflow: auto;
|
||||||
|
border: 1px solid #dcdfe6;
|
||||||
|
margin-bottom: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
::-webkit-scrollbar {
|
||||||
|
width: 10px;
|
||||||
|
}
|
||||||
|
|
||||||
|
::-webkit-scrollbar-track {
|
||||||
|
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.2);
|
||||||
|
background-color: #fefefe;
|
||||||
|
border-radius: 5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
::-webkit-scrollbar-thumb {
|
||||||
|
border-radius: 5px;
|
||||||
|
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.5);
|
||||||
|
background-color: #f5f5f5;
|
||||||
|
}
|
||||||
|
.node rect {
|
||||||
|
stroke: #606266;
|
||||||
|
fill: #fff;
|
||||||
|
}
|
||||||
|
|
||||||
|
.edgePath path {
|
||||||
|
stroke: #606266;
|
||||||
|
fill: #333;
|
||||||
|
stroke-width: 1.5px;
|
||||||
|
}
|
||||||
|
|
||||||
|
g.conditions > rect {
|
||||||
|
fill: #00ffd0;
|
||||||
|
stroke: #000;
|
||||||
|
}
|
||||||
|
|
||||||
|
.el-icon-close {
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.left-panel-group {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 6px; /* 按钮之间的间隙,可以调小点 */
|
||||||
|
margin-left: 0; /* 靠左 */
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
|
|
@ -0,0 +1,204 @@
|
||||||
|
<template>
|
||||||
|
<el-container>
|
||||||
|
<el-main>
|
||||||
|
<el-form :model="localForm" label-width="150px" label-position="left" :rules="rules">
|
||||||
|
<el-form-item label="拟发表论文名称" prop="paper_name">
|
||||||
|
<el-input v-model="localForm.paper_name" clearable :disabled="localMode ==='view'"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="拟投期刊名称" prop="publication_name">
|
||||||
|
<el-input v-model="localForm.publication_name" clearable :disabled="localMode ==='view'"></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="作者" prop="author" >
|
||||||
|
<el-input v-model="localForm.author" clearable ></el-input>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="拟发表文章类型" prop="paper_type">
|
||||||
|
<el-select v-model="localForm.paper_type" placeholder="请选择拟发表文章类型" :disabled="localMode ==='view'">
|
||||||
|
<el-option label="研究论文" value="研究论文"></el-option>
|
||||||
|
<el-option label="综述" value="综述"></el-option>
|
||||||
|
</el-select>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="是否为中文核心" prop="is_chinese_core">
|
||||||
|
<el-radio-group v-model="localForm.is_chinese_core" :disabled="localMode ==='view'">
|
||||||
|
<el-radio :label="true">是</el-radio>
|
||||||
|
<el-radio :label="false">否</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="是否被SCI/EI收录" prop="is_sci">
|
||||||
|
<el-radio-group v-model="localForm.is_sci" :disabled="localMode ==='view'">
|
||||||
|
<el-radio :label="true">是</el-radio>
|
||||||
|
<el-radio :label="false">否</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="技术状态" prop="tech_status">
|
||||||
|
<el-row>
|
||||||
|
<el-col :span="12" v-for="(item, index) in localForm.tech_status || []" :key="index">
|
||||||
|
<div class="class-row">
|
||||||
|
<span>{{ item.name }}</span>
|
||||||
|
<el-radio-group v-model="item.status" @change="handleStatusChange(item)" style="margin-left: 20px;" :disabled="localMode ==='view'">
|
||||||
|
<el-radio label="是">是</el-radio>
|
||||||
|
<el-radio label="否">否</el-radio>
|
||||||
|
</el-radio-group>
|
||||||
|
</div>
|
||||||
|
<div v-if="item.status === '是'" class="upload-section">
|
||||||
|
<sc-upload-file
|
||||||
|
multiple
|
||||||
|
:limit="3"
|
||||||
|
:accept="['.xlsx', '.xls','.pdf','.docx', '.doc', '.jpg', '.png', '.jpeg']"
|
||||||
|
@success = "(res)=>fileUPSuccess(res, item)"
|
||||||
|
:disabled="localMode ==='view'"
|
||||||
|
>
|
||||||
|
<el-button type="primary" size="small" icon="el-icon-upload"> </el-button>
|
||||||
|
</sc-upload-file>
|
||||||
|
</div>
|
||||||
|
</el-col>
|
||||||
|
</el-row>
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="技术文件" prop="tech_file">
|
||||||
|
<div class="file-item" v-for="(item, index) in localForm.tech_file || []" :key="index">
|
||||||
|
<el-checkbox class="file-checkbox" v-model="item.checked" @change="handleCheckChange(item)" :disabled="localMode ==='view'">
|
||||||
|
{{ item.name }}
|
||||||
|
</el-checkbox>
|
||||||
|
<el-input
|
||||||
|
class="page-input"
|
||||||
|
v-model="item.pages"
|
||||||
|
placeholder="页/张数"
|
||||||
|
:disabled="!item.checked || localMode ==='view'"
|
||||||
|
type="number"
|
||||||
|
min="0">
|
||||||
|
<template v-slot:append>页/张</template>
|
||||||
|
</el-input>
|
||||||
|
</div>
|
||||||
|
</el-form-item>
|
||||||
|
</el-form>
|
||||||
|
<el-footer v-show="localMode!=='show'">
|
||||||
|
<ticketd_b
|
||||||
|
:workflow_key="'paperse'"
|
||||||
|
:title="ticketTitle"
|
||||||
|
:t_id="localForm.id"
|
||||||
|
:ticket_="localForm.ticket_"
|
||||||
|
:ticket_data="ticket_data"
|
||||||
|
:submit_b_func="submit_b_func"
|
||||||
|
ref="ticketd_b"
|
||||||
|
@success="$emit('success')"
|
||||||
|
@colsed="$emit('closed')"
|
||||||
|
/>
|
||||||
|
</el-footer>
|
||||||
|
</el-main>
|
||||||
|
<el-aside v-if="localForm.ticket_">
|
||||||
|
<ticketd
|
||||||
|
:ticket_="localForm.ticket_"
|
||||||
|
:ticket_data="ticket_data"
|
||||||
|
@success="$emit('success')"
|
||||||
|
style="margin-top: 20px;"
|
||||||
|
/>
|
||||||
|
</el-aside>
|
||||||
|
</el-container>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
import ticketd_b from "@/views/wf/ticketd_b.vue";
|
||||||
|
import ticketd from '@/views/wf/ticketd.vue'
|
||||||
|
export default {
|
||||||
|
props: {
|
||||||
|
mode: { type: String, default: "view" }, // add / edit / view
|
||||||
|
modelValue: { type: Object, default: () => ({}) },
|
||||||
|
t_id: {
|
||||||
|
type: String,
|
||||||
|
default: null
|
||||||
|
},
|
||||||
|
},
|
||||||
|
components: {ticketd, ticketd_b},
|
||||||
|
emits: ["update:modelValue", "submit", "cancel"],
|
||||||
|
data() {
|
||||||
|
return {
|
||||||
|
ticket_data: {},
|
||||||
|
ticketTitle: "论文申密申请",
|
||||||
|
localMode : this.mode,
|
||||||
|
rules: {
|
||||||
|
filename: [{ required: true, message: "请输入文件名称", trigger: "blur" }],
|
||||||
|
},
|
||||||
|
localForm: {
|
||||||
|
ticket_: { state_: { type: '' } },
|
||||||
|
...(this.modelValue || {}) }
|
||||||
|
};
|
||||||
|
},
|
||||||
|
mounted() {
|
||||||
|
console.log('mode', this.localMode)
|
||||||
|
},
|
||||||
|
watch: {
|
||||||
|
localForm: {
|
||||||
|
handler(val) {
|
||||||
|
Object.assign(this.ticket_data, {
|
||||||
|
author: val.author,
|
||||||
|
// 其他需要同步的字段...
|
||||||
|
});
|
||||||
|
},
|
||||||
|
deep: true,
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
async submit_b_func() {
|
||||||
|
let that = this;
|
||||||
|
if(that.localForm?.id){
|
||||||
|
that.localMode = "edit";
|
||||||
|
}
|
||||||
|
if(that.localMode == "add") {
|
||||||
|
let res = await that.$API.srm.papersecret.create.req(that.localForm);
|
||||||
|
|
||||||
|
that.localForm.id = res.id;
|
||||||
|
} else if (that.localMode == "edit") {
|
||||||
|
await that.$API.srm.papersecret.update.req(that.localForm.id, that.localForm);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
getTid (){
|
||||||
|
var that = this;
|
||||||
|
if (that.t_id) {
|
||||||
|
that.$API.srm.papersecret.item.req(that.t_id).then(res=>{
|
||||||
|
that.localForm = res;
|
||||||
|
if(res.ticket_?.state_?.type == 1 && res.create_by == that.$TOOL.data.get("USER_INFO").id ) {
|
||||||
|
that.localMode = "edit";
|
||||||
|
}else{
|
||||||
|
that.localMode = "show";
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
},
|
||||||
|
fileUPSuccess(res, item) {
|
||||||
|
if(!item.fileList) {
|
||||||
|
item.fileList = []
|
||||||
|
}
|
||||||
|
item.fileList.push(res.path)
|
||||||
|
item.file = res.path
|
||||||
|
},
|
||||||
|
handleCheckChange(item) {
|
||||||
|
// 如果取消勾选,清空页数
|
||||||
|
if (!item.checked) {
|
||||||
|
item.pages = '';
|
||||||
|
}
|
||||||
|
},
|
||||||
|
// 当选择“否”时清空文件
|
||||||
|
handleStatusChange(item) {
|
||||||
|
if (item.status === "否") {
|
||||||
|
item.file = "";
|
||||||
|
item.fileList = [];
|
||||||
|
}
|
||||||
|
},
|
||||||
|
},
|
||||||
|
};
|
||||||
|
|
||||||
|
</script>
|
||||||
|
<style lang="scss" scoped>
|
||||||
|
.status-item {
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
.status-row {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: space-between;
|
||||||
|
}
|
||||||
|
.upload-section {
|
||||||
|
margin-left: 10px;
|
||||||
|
border-left: 2px solid #eee;
|
||||||
|
padding-left: 10px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
@ -41,8 +41,8 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="总数">
|
<el-table-column label="总数">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span v-if="scope.row.总生产数">{{ scope.row.总生产数 }}</span>
|
|
||||||
<span v-if="scope.row.总切片数">{{ scope.row.总切片数 }}</span>
|
<span v-if="scope.row.总切片数">{{ scope.row.总切片数 }}</span>
|
||||||
|
<span v-else>{{ scope.row.总生产数 }}</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="剪切">
|
<el-table-column label="剪切">
|
||||||
|
|
@ -52,36 +52,30 @@
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="剪切加功率">
|
<el-table-column label="剪切加功率">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span v-if="scope.row['剪切¢18.3mm不合格']">{{ (((scope.row.总切片数-scope.row['剪切¢18.3mm不合格'])/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
<span v-if="scope.row['剪切¢18.3mm不合格']">{{ (((scope.row.总切片数-scope.row['剪切¢18.3mm不合格'].含)/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
||||||
<span v-else>100%</span>
|
<span v-else>100%</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="暗点">
|
<el-table-column label="暗点">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span v-if="scope.row.暗点合格">{{((scope.row.暗点合格/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
<span v-if="scope.row.暗点合格">{{((scope.row.暗点合格.含/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
||||||
<span v-else>0%</span>
|
<span v-else>0%</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="长点率">
|
<el-table-column label="长点率">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span v-if="scope.row.暗点不合格">{{((scope.row.暗点不合格/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
<span v-if="scope.row.暗点不合格">{{((scope.row.暗点不合格.含/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
||||||
<span v-else>0%</span>
|
<span v-else>0%</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="加功率">
|
<el-table-column label="加功率">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span v-if="scope.row.可加工数">{{((scope.row.可加工数/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
<span v-if="scope.row.总切片合格数">{{((scope.row.总切片合格数/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
||||||
</template>
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="不合格数">
|
|
||||||
<template #default="scope">
|
|
||||||
<span v-if="scope.row.不合格数">{{((scope.row.不合格数/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="合格率" prop="合格率">
|
<el-table-column label="合格率" prop="合格率">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
<span v-if="scope.row['剪切¢18.3mm可加工']">{{ scope.row['剪切¢18.3mm不合格']?scope.row.总切片数 - scope.row['剪切¢18.3mm可加工']- scope.row['剪切¢18.3mm不合格']+scope.row.暗点合格:scope.row.总切片数 - scope.row['剪切¢18.3mm可加工']+scope.row.暗点合格}}</span>
|
<span v-if="scope.row.总切片完全合格数">{{((scope.row.总切片完全合格数/scope.row.总切片数)*100).toFixed(2) }}%</span>
|
||||||
<span v-else>{{ scope.row['剪切¢18.3mm不合格']?scope.row.总切片数 - scope.row['剪切¢18.3mm不合格']+scope.row.暗点合格:scope.row.总切片数}}</span>
|
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
</scTable>
|
</scTable>
|
||||||
|
|
@ -134,34 +128,18 @@ export default {
|
||||||
item.可加工数 = 0;
|
item.可加工数 = 0;
|
||||||
if(item['剪切¢18.3mm不合格']){
|
if(item['剪切¢18.3mm不合格']){
|
||||||
if(item['剪切¢18.3mm可加工']){
|
if(item['剪切¢18.3mm可加工']){
|
||||||
item.剪切合格 = item.总切片数 - item['剪切¢18.3mm可加工']- item['剪切¢18.3mm不合格'];
|
item.剪切合格 = item.总切片数 - item['剪切¢18.3mm可加工'].含- item['剪切¢18.3mm不合格'].含;
|
||||||
}else{
|
}else{
|
||||||
item.剪切合格 = item.总切片数 - item['剪切¢18.3mm不合格'];
|
item.剪切合格 = item.总切片数 - item['剪切¢18.3mm不合格'].含;
|
||||||
}
|
|
||||||
if(item.暗点不合格){
|
|
||||||
item.不合格数 = item['剪切¢18.3mm不合格'] + item.暗点不合格;
|
|
||||||
item.可加工数 = item.总切片数 - item['剪切¢18.3mm不合格'] - item.暗点不合格;
|
|
||||||
}else{
|
|
||||||
item.不合格数 = item['剪切¢18.3mm不合格'];
|
|
||||||
item.可加工数 = item.总切片数 - item['剪切¢18.3mm不合格'];
|
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
if(item['剪切¢18.3mm可加工']){
|
if(item['剪切¢18.3mm可加工']){
|
||||||
item.剪切合格 = item.总切片数 - item['剪切¢18.3mm可加工'];
|
item.剪切合格 = item.总切片数 - item['剪切¢18.3mm可加工'].含;
|
||||||
}else{
|
}else{
|
||||||
item.剪切合格 = item.总切片数;
|
item.剪切合格 = item.总切片数;
|
||||||
}
|
}
|
||||||
if(item.暗点不合格){
|
|
||||||
item.不合格数 = item.暗点不合格;
|
|
||||||
item.可加工数 = item.总切片数 - item.暗点不合格;
|
|
||||||
}else{
|
|
||||||
item.不合格数 = 0;
|
|
||||||
item.可加工数 = item.总切片数;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
console.log('data',data)
|
|
||||||
that.tableData = data;
|
that.tableData = data;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
|
||||||
|
|
@ -3,19 +3,19 @@
|
||||||
<el-header>
|
<el-header>
|
||||||
<div class="left-panel"></div>
|
<div class="left-panel"></div>
|
||||||
<div class="right-panel">
|
<div class="right-panel">
|
||||||
<el-cascader
|
<!-- <el-cascader
|
||||||
v-model="query.dept_name"
|
v-model="query.dept_name"
|
||||||
:options="group"
|
:options="group"
|
||||||
:props="groupsProps"
|
:props="groupsProps"
|
||||||
clearable
|
clearable
|
||||||
:show-all-levels="false"
|
:show-all-levels="false"
|
||||||
@change="deptChange">
|
@change="deptChange">
|
||||||
</el-cascader>
|
</el-cascader> -->
|
||||||
<!-- <el-input v-model="query.user_name"
|
<el-input v-model="query.user_name"
|
||||||
placeholder="姓名"
|
placeholder="姓名"
|
||||||
clearable
|
clearable
|
||||||
style="width: 200px;"
|
style="width: 200px;"
|
||||||
></el-input> -->
|
></el-input>
|
||||||
<el-date-picker
|
<el-date-picker
|
||||||
v-model="query.start_date"
|
v-model="query.start_date"
|
||||||
type="date"
|
type="date"
|
||||||
|
|
@ -45,23 +45,20 @@
|
||||||
stripe
|
stripe
|
||||||
>
|
>
|
||||||
<el-table-column type="index" width="50" fixed="left"/>
|
<el-table-column type="index" width="50" fixed="left"/>
|
||||||
<el-table-column label="工段" prop="工段">
|
<el-table-column label="日期" prop="日期" width="120">
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="日期" prop="日期">
|
<el-table-column label="操作人" prop="操作人" width="120">
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column v-for="item in lists" :key="item" :label="item" :prop="item">
|
||||||
<template #default="scope">
|
<template #default="scope">
|
||||||
{{ scope.row.年}}-{{ scope.row.月}}-{{ scope.row.日}}
|
{{ scope.row[item] }}
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="操作人" prop="操作人">
|
<!-- <el-table-column label="生产数" prop="生产数">
|
||||||
</el-table-column>
|
<template #default="scope">
|
||||||
<el-table-column label="生产数" prop="生产数">
|
<span v-for="item in scope.row.list" :key="item">{{ item.text }}:{{ item.value }}、</span>
|
||||||
</el-table-column>
|
</template>
|
||||||
<el-table-column label="合格数" prop="合格数">
|
</el-table-column> -->
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="不合格数" prop="不合格数">
|
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="合格率" prop="合格率">
|
|
||||||
</el-table-column>
|
|
||||||
</scTable>
|
</scTable>
|
||||||
</el-main>
|
</el-main>
|
||||||
</el-container>
|
</el-container>
|
||||||
|
|
@ -78,7 +75,7 @@ export default {
|
||||||
dept_name:'',
|
dept_name:'',
|
||||||
start_date:'',
|
start_date:'',
|
||||||
},
|
},
|
||||||
group: [],
|
mgroups: [],
|
||||||
tableData:[],
|
tableData:[],
|
||||||
groupsProps: {
|
groupsProps: {
|
||||||
value: "name",
|
value: "name",
|
||||||
|
|
@ -107,8 +104,17 @@ export default {
|
||||||
let that = this;
|
let that = this;
|
||||||
let params = {};
|
let params = {};
|
||||||
params.query = that.query;
|
params.query = that.query;
|
||||||
that.$API.bi.dataset.exec.req('performance', params).then((res) => {
|
that.$API.bi.dataset.exec.req('lineDay_p', params).then((res) => {
|
||||||
that.tableData = res.data2.ds0;
|
let data = res.data2.ds0;
|
||||||
|
that.lists = [];
|
||||||
|
data.forEach(item=>{
|
||||||
|
let obj = JSON.parse(item.工段物料生产数);
|
||||||
|
for(let key in obj){
|
||||||
|
item[key]= obj[key];
|
||||||
|
if(that.lists.indexOf(key)>-1){}else{that.lists.push(key)}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
that.tableData = data;
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
deptChange(){
|
deptChange(){
|
||||||
|
|
|
||||||
|
|
@ -61,6 +61,7 @@
|
||||||
row-key="id"
|
row-key="id"
|
||||||
:params="params"
|
:params="params"
|
||||||
:query="query"
|
:query="query"
|
||||||
|
default-expand-all
|
||||||
>
|
>
|
||||||
<el-table-column
|
<el-table-column
|
||||||
label="#"
|
label="#"
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue