Commit 77f50345 authored by 姬鋆屾's avatar 姬鋆屾

parent cfaec5d1
...@@ -489,6 +489,7 @@ export default { ...@@ -489,6 +489,7 @@ export default {
}, },
// 当某一行被点击时会触发该事件 // 当某一行被点击时会触发该事件
handleRowClick(row, column, event) {}, handleRowClick(row, column, event) {},
handleCellClick(row, column, event) {},
// 合并表格行列 // 合并表格行列
handleSpanMethod() {}, handleSpanMethod() {},
// 自定义表格排序 // 自定义表格排序
...@@ -619,6 +620,7 @@ export default { ...@@ -619,6 +620,7 @@ export default {
methods: { methods: {
handleSelectionChange: this.handleSelectionChange, handleSelectionChange: this.handleSelectionChange,
handleRowClick: this.handleRowClick, handleRowClick: this.handleRowClick,
handleCellClick: this.handleCellClick,
tableRowClassName: this.tableRowClassName, tableRowClassName: this.tableRowClassName,
handleSpanMethod: this.handleSpanMethod, handleSpanMethod: this.handleSpanMethod,
handleSortChange: this.handleSortChange, handleSortChange: this.handleSortChange,
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
@selection-change="handleSelectionChange" @selection-change="handleSelectionChange"
@sort-change="handleSortChange" @sort-change="handleSortChange"
@row-click="handleRowClick" @row-click="handleRowClick"
@cell-click="handleCellClick"
:row-class-name="tableRowClassName" :row-class-name="tableRowClassName"
:empty-text="emptytxt ? emptytxt : emptyText" :empty-text="emptytxt ? emptytxt : emptyText"
border border
...@@ -81,6 +82,11 @@ export default { ...@@ -81,6 +82,11 @@ export default {
required: false, required: false,
default: () => {}, default: () => {},
}, },
handleCellClick: {
type: Function,
required: false,
default: () => {},
},
handleSortChange: { handleSortChange: {
type: Function, type: Function,
required: false, required: false,
......
...@@ -182,6 +182,7 @@ ...@@ -182,6 +182,7 @@
:handleSelectableMethod="config.methods.handleSelectableMethod" :handleSelectableMethod="config.methods.handleSelectableMethod"
:handleSelectionChange="config.methods.handleSelectionChange" :handleSelectionChange="config.methods.handleSelectionChange"
:handleRowClick="config.methods.handleRowClick" :handleRowClick="config.methods.handleRowClick"
:handleCellClick="config.methods.handleCellClick"
/> />
<DataTableFlow <DataTableFlow
......
...@@ -71,6 +71,7 @@ ...@@ -71,6 +71,7 @@
>图片凭证: >图片凭证:
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -82,6 +83,7 @@ ...@@ -82,6 +83,7 @@
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image> </el-image>
<span v-else>--</span>
</el-col> </el-col>
</el-row> </el-row>
</div> </div>
...@@ -115,7 +117,7 @@ ...@@ -115,7 +117,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-row> </el-row>
<div v-if="form.checkResult=='加分或扣分'"> <div v-if="form.checkResult == '加分或扣分'">
<el-row> <el-row>
<el-form-item <el-form-item
:label="form.view == '查看' ? '绩效规则:' : '修改规则:'" :label="form.view == '查看' ? '绩效规则:' : '修改规则:'"
......
...@@ -86,6 +86,7 @@ ...@@ -86,6 +86,7 @@
<el-col :span="12" <el-col :span="12"
>图片凭证: >图片凭证:
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -96,8 +97,9 @@ ...@@ -96,8 +97,9 @@
" "
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image </el-image>
></el-col> <span v-else>--</span>
</el-col>
</el-row> </el-row>
</div> </div>
</div> </div>
...@@ -130,7 +132,7 @@ ...@@ -130,7 +132,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-row> </el-row>
<div v-if="form.checkResult=='加分或扣分'"> <div v-if="form.checkResult == '加分或扣分'">
<el-row> <el-row>
<el-form-item <el-form-item
:label="form.view == '查看' ? '绩效规则:' : '修改规则:'" :label="form.view == '查看' ? '绩效规则:' : '修改规则:'"
......
...@@ -63,6 +63,7 @@ ...@@ -63,6 +63,7 @@
<el-col :span="24"> <el-col :span="24">
图片凭证: 图片凭证:
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -73,8 +74,9 @@ ...@@ -73,8 +74,9 @@
" "
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image </el-image>
></el-col> <span v-else>--</span>
</el-col>
</el-row> </el-row>
</div> </div>
</div> </div>
...@@ -107,7 +109,7 @@ ...@@ -107,7 +109,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-row> </el-row>
<div v-if="form.checkResult=='加分或扣分'"> <div v-if="form.checkResult == '加分或扣分'">
<el-row> <el-row>
<el-form-item <el-form-item
:label="form.view == '查看' ? '绩效规则:' : '修改规则:'" :label="form.view == '查看' ? '绩效规则:' : '修改规则:'"
......
...@@ -65,6 +65,7 @@ ...@@ -65,6 +65,7 @@
<el-col :span="24"> <el-col :span="24">
图片凭证: 图片凭证:
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -75,8 +76,9 @@ ...@@ -75,8 +76,9 @@
" "
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image </el-image>
></el-col> <span v-else>--</span>
</el-col>
</el-row> </el-row>
</div> </div>
</div> </div>
...@@ -109,7 +111,7 @@ ...@@ -109,7 +111,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-row> </el-row>
<div v-if="form.checkResult=='加分或扣分'"> <div v-if="form.checkResult == '加分或扣分'">
<el-row> <el-row>
<el-form-item <el-form-item
:label="form.view == '查看' ? '绩效规则:' : '修改规则:'" :label="form.view == '查看' ? '绩效规则:' : '修改规则:'"
......
...@@ -61,6 +61,7 @@ ...@@ -61,6 +61,7 @@
<el-col :span="24" <el-col :span="24"
>图片凭证: >图片凭证:
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -71,8 +72,9 @@ ...@@ -71,8 +72,9 @@
" "
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image </el-image>
></el-col> <span v-else>--</span>
</el-col>
</el-row> </el-row>
</div> </div>
</div> </div>
...@@ -105,7 +107,7 @@ ...@@ -105,7 +107,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-row> </el-row>
<div v-if="form.checkResult=='加分或扣分'"> <div v-if="form.checkResult == '加分或扣分'">
<el-row> <el-row>
<el-form-item <el-form-item
:label="form.view == '查看' ? '绩效规则:' : '修改规则:'" :label="form.view == '查看' ? '绩效规则:' : '修改规则:'"
......
...@@ -66,6 +66,7 @@ ...@@ -66,6 +66,7 @@
<el-col :span="12" <el-col :span="12"
>图片凭证: >图片凭证:
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -76,8 +77,9 @@ ...@@ -76,8 +77,9 @@
" "
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image </el-image>
></el-col> <span v-else>--</span>
</el-col>
</el-row> </el-row>
</div> </div>
</div> </div>
...@@ -110,7 +112,7 @@ ...@@ -110,7 +112,7 @@
</el-radio-group> </el-radio-group>
</el-form-item> </el-form-item>
</el-row> </el-row>
<div v-if="form.checkResult=='加分或扣分'"> <div v-if="form.checkResult == '加分或扣分'">
<el-row> <el-row>
<el-form-item <el-form-item
:label="form.view == '查看' ? '绩效规则:' : '修改规则:'" :label="form.view == '查看' ? '绩效规则:' : '修改规则:'"
......
...@@ -123,6 +123,7 @@ ...@@ -123,6 +123,7 @@
<el-form-item label="图片凭证:"> <el-form-item label="图片凭证:">
<div v-if="form.view == '查看'"> <div v-if="form.view == '查看'">
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -134,6 +135,7 @@ ...@@ -134,6 +135,7 @@
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image> </el-image>
<span v-else>--</span>
</div> </div>
<ImageUpload <ImageUpload
v-else v-else
......
...@@ -175,6 +175,7 @@ ...@@ -175,6 +175,7 @@
<el-form-item label="图片凭证:"> <el-form-item label="图片凭证:">
<div v-if="form.view == '查看'"> <div v-if="form.view == '查看'">
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -186,6 +187,7 @@ ...@@ -186,6 +187,7 @@
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image> </el-image>
<span v-else>--</span>
</div> </div>
<ImageUpload <ImageUpload
v-else v-else
......
...@@ -149,6 +149,7 @@ ...@@ -149,6 +149,7 @@
<el-form-item label="图片凭证:"> <el-form-item label="图片凭证:">
<div v-if="form.view == '查看'"> <div v-if="form.view == '查看'">
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -160,6 +161,7 @@ ...@@ -160,6 +161,7 @@
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image> </el-image>
<span v-else>--</span>
</div> </div>
<ImageUpload <ImageUpload
v-else v-else
...@@ -484,10 +486,9 @@ export default { ...@@ -484,10 +486,9 @@ export default {
}); });
}, },
replaceImage(val) { replaceImage(val) {
this.form.filePaths = val; this.form.filePaths = val;
this.$forceUpdate(this.form); this.$forceUpdate(this.form);
}, },
staffChange(val) { staffChange(val) {
console.log(val); console.log(val);
......
...@@ -127,6 +127,7 @@ ...@@ -127,6 +127,7 @@
<el-form-item label="图片凭证:"> <el-form-item label="图片凭证:">
<div v-if="form.view == '查看'"> <div v-if="form.view == '查看'">
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -138,6 +139,7 @@ ...@@ -138,6 +139,7 @@
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image> </el-image>
<span v-else>--</span>
</div> </div>
<ImageUpload <ImageUpload
v-else v-else
......
...@@ -87,6 +87,7 @@ ...@@ -87,6 +87,7 @@
<el-form-item label="图片凭证:"> <el-form-item label="图片凭证:">
<div v-if="form.view == '查看'"> <div v-if="form.view == '查看'">
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -98,6 +99,7 @@ ...@@ -98,6 +99,7 @@
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image> </el-image>
<span v-else>--</span>
</div> </div>
<ImageUpload <ImageUpload
v-else v-else
......
...@@ -140,6 +140,7 @@ ...@@ -140,6 +140,7 @@
<el-form-item label="图片凭证:"> <el-form-item label="图片凭证:">
<div v-if="form.view == '查看'"> <div v-if="form.view == '查看'">
<el-image <el-image
v-if="form.filePaths"
style="width: 100px; height: 100px" style="width: 100px; height: 100px"
:src=" :src="
`${ `${
...@@ -151,6 +152,7 @@ ...@@ -151,6 +152,7 @@
:preview-src-list="form.filePaths" :preview-src-list="form.filePaths"
> >
</el-image> </el-image>
<span v-else>--</span>
</div> </div>
<ImageUpload <ImageUpload
v-else v-else
......
...@@ -381,6 +381,7 @@ export default { ...@@ -381,6 +381,7 @@ export default {
}; };
}, },
methods: { methods: {
handleRowClick(val) { handleRowClick(val) {
val.check = !val.check; val.check = !val.check;
val.check val.check
......
...@@ -103,6 +103,11 @@ export default { ...@@ -103,6 +103,11 @@ export default {
sessionStorage.setItem("type", this.type); sessionStorage.setItem("type", this.type);
}, },
methods: { methods: {
handleCellClick(row, column, event, cell) {
if (column.label == "负责窗口数量") {
this.$refs.windowdrawerform.edit(row);
}
},
/** 重写新增方法 */ /** 重写新增方法 */
toAdd(row) { toAdd(row) {
this.$refs.windowdrawerform.add(row); this.$refs.windowdrawerform.add(row);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment