Commit dd10cf13 authored by 赵啸非's avatar 赵啸非

Merge remote-tracking branch 'origin/master'

parents 759b05a3 b029236b
......@@ -51,12 +51,10 @@ export const encodeURI = (data) => {
* @returns {string} val 解析后的结果
*/
export function formatterDate(time) {
console.log("time",time)
if(time==='undefined'||time===null) {
return '--'}
if (!time) return '--';
console.log("time11111",time)
let date = new Date(Number(time));
let Y = date.getFullYear() + '-';
let M = (date.getMonth() + 1 < 10 ? '0' + (date.getMonth() + 1) : date.getMonth() + 1) + '-';
......
......@@ -68,10 +68,21 @@
{{ form.deductPerson ? form.deductPerson : "--" }}</el-col
>
<el-col :span="12"
>图片凭证:{{
form.snapPath ? picMatter(form.snapPath) : "--"
}}</el-col
>
>图片凭证:
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image>
</el-col>
</el-row>
</div>
</div>
......@@ -391,7 +402,7 @@ export default {
this.$forceUpdate(this.form);
},
picMatter(val) {
if (val || val !== "--") {
if (val) {
return (
<el-image
src={val.indexOf("http") == -1 ? this.baseUrl + val : val}
......
......@@ -212,7 +212,7 @@ export default {
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
......
......@@ -84,10 +84,20 @@
{{ form.deductTime ? form.deductTime : "--" }}</el-col
>
<el-col :span="12"
>图片凭证:{{
form.snapPath ? picMatter(form.snapPath) : "--"
}}</el-col
>
>图片凭证:
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image
></el-col>
</el-row>
</div>
</div>
......
......@@ -217,7 +217,7 @@ export default {
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
......
......@@ -61,10 +61,20 @@
</el-row>
<el-row>
<el-col :span="24">
图片凭证:{{
form.snapPath ? picMatter(form.snapPath) : "--"
}}</el-col
>
图片凭证:
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image
></el-col>
</el-row>
</div>
</div>
......@@ -248,8 +258,8 @@
/>
<Field
label="图片凭证地址"
prop="snapPath"
v-model="form.snapPath"
prop="filePaths"
v-model="form.filePaths"
type="textarea"
placeholder="请输入图片凭证地址"
/>
......@@ -554,7 +564,7 @@ export default {
happenTime: null,
duration: 0,
alarmTime: null,
snapPath: "",
filePaths: "",
ruleId: null,
ruleName: "",
subMethod: 1,
......
......@@ -219,7 +219,7 @@ export default {
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
......
......@@ -42,7 +42,7 @@
{{ util_formatterDate(form.alarmTime)}}
</el-descriptions-item>
<el-descriptions-item label="图片凭证地址" label-class-name="labelClass" content-class-name="contentClass">
{{form.snapPath}}
{{form.filePaths}}
</el-descriptions-item>
<el-descriptions-item label="绩效规则id" label-class-name="labelClass" content-class-name="contentClass">
{{form.ruleId}}
......
......@@ -63,10 +63,20 @@
</el-row>
<el-row>
<el-col :span="24">
图片凭证:{{
form.snapPath ? picMatter(form.snapPath) : "--"
}}</el-col
>
图片凭证:
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image
></el-col>
</el-row>
</div>
</div>
......
......@@ -207,7 +207,7 @@ export default {
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
......
......@@ -59,10 +59,20 @@
</el-row>
<el-row>
<el-col :span="24"
>图片凭证:{{
form.snapPath ? picMatter(form.snapPath) : "--"
}}</el-col
>
>图片凭证:
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image
></el-col>
</el-row>
</div>
</div>
......
......@@ -215,7 +215,7 @@ export default {
// { label: "绩效规则id", prop: "ruleId", formatter: this.formatter },
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
......
......@@ -64,10 +64,20 @@
<el-row>
<el-col :span="12"
>图片凭证:{{
form.snapPath ? picMatter(form.snapPath) : "--"
}}</el-col
>
>图片凭证:
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image
></el-col>
</el-row>
</div>
</div>
......
......@@ -216,7 +216,7 @@ export default {
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
......
......@@ -35,7 +35,7 @@
}}</el-col
>
<el-col :span="8"
>异常时间:{{ formatterDate(form.errorTime)}}</el-col
>异常时间:{{ formatterDate(form.errorTime) }}</el-col
>
<el-col :span="8"
>上下班时间:{{
......@@ -45,7 +45,7 @@
</el-row>
<el-row>
<el-col :span="10"
>实际打卡时间:{{formatterDate(form.actualAttendTime)}}</el-col
>实际打卡时间:{{ formatterDate(form.actualAttendTime) }}</el-col
>
<el-col :span="9"
>异常结果:{{
......@@ -54,15 +54,15 @@
>
<el-col :span="5"
>加分/扣分方式:{{
form.subAddType ? form.subAddType : "--"
form.subAddType
? util_formatter("subAddType", form.subAddType)
: "--"
}}</el-col
>
</el-row>
<el-row>
<el-col :span="8"
>加分/扣分时间:{{
formatterDate(form.deductTime)
}}</el-col
>加分/扣分时间:{{ formatterDate(form.deductTime) }}</el-col
>
<el-col :span="8"
>加分/扣分人员:{{
......@@ -78,7 +78,9 @@
<el-row>
<el-col :span="8"
>核查结果:{{
form.checkResult ? form.checkResult : "--"
form.checkResult
? util_formatter("checkResult", form.checkResult)
: "--"
}}</el-col
>
<el-col :span="8"
......@@ -113,7 +115,7 @@
>申诉说明:{{ form.appealDesc ? form.appealDesc : "--" }}</el-col
>
<el-col :span="24"
>申诉时间:{{ formatterDate(form.appealTime)}}</el-col
>申诉时间:{{ formatterDate(form.appealTime) }}</el-col
>
<el-col :span="24"
>申诉附件:
......@@ -135,17 +137,21 @@
</el-row>
</div>
</div>
<div class="box" v-if="form.view == '查看' || form.processStatus == 2">
<div class="box" v-if="form.view == '查看'">
<div class="title">申诉结果</div>
<div class="content">
<el-row>
<el-col :span="8"
>申诉结果:{{
form.appealResult ? form.appealResult : "--"
form.appealResult
? util_formatter("appealResult", form.appealResult)
: "--"
}}</el-col
>
<el-col :span="8"
>处理人员{{util_formatter('updateUserId',form.updateUserId+"")}}</el-col
>处理人员:{{
util_formatter("updateUserId", form.updateUserId + "")
}}</el-col
>
<el-col :span="8"
>处理时间: {{ formatterDate(form.updateTime) }}</el-col
......@@ -479,14 +485,19 @@ export default {
// 是否显示弹出层
open: false,
direction: "rtl",
toString: ["subMethod", "subAddType", "processStatus", "appealResult", "updateUserId"],
toString: [
"subMethod",
"subAddType",
"processStatus",
"appealResult",
"updateUserId",
],
toDate: [
"attendanceDate",
"errorTime",
"actualAttendTime",
"checkTime",
"appealTime",
],
// 表单校验
rules: {
......@@ -581,39 +592,14 @@ export default {
this.$get("/perform/attend/appeal/info", { id: row.id }).then((res) => {
if (res.code == 1) {
this.form = res.data;
this.dict = res.dict;
} else {
this.reset();
}
for (let key in this.form) {
key == "actualAttendTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "attendanceDate"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "createTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "errorTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "updateTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "checkTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "reviewTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "appealTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "complainTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "happenTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "alarmTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: key == "alarmTime"
? (this.form[key] = timestampToTime(this.form[key], 6))
: "";
}
this.form.appealResult = "";
this.form.processStatus = 2;
this.form.remark = "";
this.form.view = "核查";
this.open = true;
});
this.pageInfo.type = "edit";
......
......@@ -122,7 +122,18 @@
<el-col :span="22">
<el-form-item label="图片凭证:">
<div v-if="form.view == '查看'">
{{ form.filePaths ? picMatter(form.filePaths) : "--" }}
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image>
</div>
<ImageUpload
v-else
......@@ -439,7 +450,9 @@ export default {
});
},
replaceImage(val) {
this.form.snapPath = val;
this.form.filePaths = val;
this.$forceUpdate(this.form);
},
staffChange(val) {
console.log(val);
......@@ -453,7 +466,6 @@ export default {
// this.urls.currUrl = "perform/attend/record/edit";
// this.getData();
this.$get("/perform/attend/record/info", { id: row.id }).then((res) => {
console.log(res.data);
if (res.code == 1) {
this.form = res.data;
} else {
......@@ -488,6 +500,8 @@ export default {
}).then((res) => {
this.ruleArr = res.data.data;
});
this.form.filePaths = this.form.filePaths ? this.form.filePaths : "";
console.log(this.form);
this.open = true;
});
this.pageInfo.type = "edit";
......@@ -572,7 +586,7 @@ export default {
errorResult: "",
errorTime: "",
fileNames: "",
snapPath: "",
filePaths: "",
goOffTimeStr: "",
processStatus: 1,
remark: "",
......
......@@ -221,7 +221,7 @@ export default {
/*
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
*/
......
......@@ -174,11 +174,22 @@
<el-col :span="22">
<el-form-item label="图片凭证:">
<div v-if="form.view == '查看'">
{{ form.snapPath ? picMatter(form.snapPath) : "--" }}
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image>
</div>
<ImageUpload
v-else
:value="form.snapPath"
:value="form.filePaths"
@input="replaceImage"
></ImageUpload>
</el-form-item>
......@@ -502,7 +513,9 @@ export default {
});
},
replaceImage(val) {
this.form.snapPath = val;
this.form.filePaths = val;
this.$forceUpdate(this.form);
},
staffChange(val) {
let arr = this.staffArr.filter((v) => v.id == val);
......@@ -583,7 +596,7 @@ export default {
score: "",
processStatus: 1,
remark: "",
snapPath: "",
filePaths: "",
fileNames: "",
};
this.open = true;
......
......@@ -224,7 +224,7 @@ export default {
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
......
......@@ -148,11 +148,22 @@
<el-col :span="22">
<el-form-item label="图片凭证:">
<div v-if="form.view == '查看'">
{{ form.snapPath ? picMatter(form.snapPath) : "--" }}
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image>
</div>
<ImageUpload
v-else
:value="form.snapPath"
:value="form.filePaths"
@input="replaceImage"
></ImageUpload>
</el-form-item>
......@@ -278,8 +289,8 @@
/>
<Field
label="图片凭证地址"
prop="snapPath"
v-model="form.snapPath"
prop="filePaths"
v-model="form.filePaths"
type="textarea"
placeholder="请输入图片凭证地址"
/>
......@@ -473,7 +484,10 @@ export default {
});
},
replaceImage(val) {
this.form.snapPath = val;
this.form.filePaths = val;
this.$forceUpdate(this.form);
},
staffChange(val) {
console.log(val);
......@@ -609,7 +623,7 @@ export default {
happenTime: null,
duration: 0,
alarmTime: null,
snapPath: "",
filePaths: "",
ruleId: null,
ruleName: "",
subMethod: "",
......
......@@ -227,7 +227,7 @@ export default {
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
{ label: "绩效规则", prop: "ruleName" },
......
......@@ -200,7 +200,7 @@ export default {
formatter: this.formatterDate,
},
{ label: "图片凭证地址", prop: "snapPath" },
{ label: "图片凭证地址", prop: "filePaths" },
{ label: "绩效规则id", prop: "ruleId", formatter: this.formatter },
......
......@@ -39,7 +39,7 @@
{{ util_formatterDate(form.alarmTime)}}
</el-descriptions-item>
<el-descriptions-item label="图片凭证地址" label-class-name="labelClass" content-class-name="contentClass">
{{form.snapPath}}
{{form.filePaths}}
</el-descriptions-item>
<el-descriptions-item label="绩效规则id" label-class-name="labelClass" content-class-name="contentClass">
{{form.ruleId}}
......
......@@ -126,11 +126,22 @@
<el-col :span="22">
<el-form-item label="图片凭证:">
<div v-if="form.view == '查看'">
{{ form.snapPath ? picMatter(form.snapPath) : "--" }}
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image>
</div>
<ImageUpload
v-else
:value="form.snapPath"
:value="form.filePaths"
@input="replaceImage"
></ImageUpload>
</el-form-item>
......@@ -442,7 +453,9 @@ export default {
});
},
replaceImage(val) {
this.form.snapPath = val;
this.form.filePaths = val;
this.$forceUpdate(this.form);
},
staffChange(val) {
console.log(val);
......
......@@ -214,7 +214,7 @@ export default {
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
{ label: "绩效规则", prop: "ruleName" },
......
......@@ -86,11 +86,22 @@
<el-col :span="22">
<el-form-item label="图片凭证:">
<div v-if="form.view == '查看'">
{{ form.snapPath ? picMatter(form.snapPath) : "--" }}
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image>
</div>
<ImageUpload
v-else
:value="form.snapPath"
:value="form.filePaths"
@input="replaceImage"
></ImageUpload>
</el-form-item>
......@@ -403,8 +414,9 @@ export default {
});
},
replaceImage(val) {
this.form.snapPath = val;
this.$forceUpdate(this.form.snapPath);
this.form.filePaths = val;
this.$forceUpdate(this.form);
},
staffChange(val) {
console.log(val);
......@@ -445,7 +457,7 @@ export default {
: "";
}
this.form.processStatus = 2;
this.form.snapPath ? "" : (this.form.snapPath = "");
this.form.filePaths ? "" : (this.form.filePaths = "");
this.form.view = "核查";
this.staffChange(this.form.staffId);
this.$post("/perform/rules/list", {
......@@ -546,7 +558,7 @@ export default {
remark: "",
categoryId: "",
happenTime: "",
snapPath: "",
filePaths: "",
};
this.resetForm("form");
},
......
......@@ -223,7 +223,7 @@ export default {
// { label: "绩效规则id", prop: "ruleId", formatter: this.formatter },
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
{ label: "绩效规则", prop: "ruleName" },
......
......@@ -139,11 +139,22 @@
<el-col :span="22">
<el-form-item label="图片凭证:">
<div v-if="form.view == '查看'">
{{ form.snapPath ? picMatter(form.snapPath) : "--" }}
<el-image
style="width: 100px; height: 100px"
:src="
`${
form.filePaths.indexOf('http') == -1
? baseUrl + form.filePaths
: form.filePaths
}`
"
:preview-src-list="form.filePaths"
>
</el-image>
</div>
<ImageUpload
v-else
:value="form.snapPath"
:value="form.filePaths"
@input="replaceImage"
></ImageUpload>
</el-form-item>
......@@ -457,7 +468,9 @@ export default {
});
},
replaceImage(val) {
this.form.snapPath = val;
this.form.filePaths = val;
this.$forceUpdate(this.form);
},
staffChange(val) {
console.log(val);
......@@ -587,7 +600,7 @@ export default {
deptId: "",
deptName: "",
fileNames: "",
snapPath: "",
filePaths: "",
processStatus: 1,
remark: "",
reviewDevice: "",
......
......@@ -224,7 +224,7 @@ export default {
{
label: "图片凭证",
prop: "snapPath",
prop: "filePaths",
formatter: this.formatterPic,
},
......
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