This commit is contained in:
Vinjor 2024-10-30 15:37:26 +08:00
parent 780b080efe
commit 161567d6e7
8 changed files with 53 additions and 48 deletions

View File

@ -28,4 +28,7 @@
* { * {
box-sizing: border-box; box-sizing: border-box;
} }
.image-view-img{
background: white;
}
</style> </style>

View File

@ -42,10 +42,15 @@
</view> </view>
</view> </view>
<view class="footer"> <view class="footer">
<view @click="projectDis" v-if="order.ticketsStatus == '04' && roleCanPg" class="btn pg"> <view @click="projectDis" v-if="order.ticketsStatus == '04' && (userInfo.roleCodes.includes('service_advisor') || userInfo.roleCodes.includes('general_inspection'))" class="btn pg">
项目派工 项目派工
</view> </view>
<view @click="projectDis" v-if="order.ticketsStatus == '05' && roleCanPg" class="btn pg"> <view @click="projectDis" v-if="order.ticketsStatus == '05' && userInfo.roleCodes.includes('repair_staff') && ifLeader && order.canOperate" class="btn pg">
<!--维修班组长且当前施工人是本班组内的人可以重新派工-->
重新派工
</view>
<view @click="projectDis" v-if="order.ticketsStatus == '05' && (userInfo.roleCodes.includes('service_advisor') || userInfo.roleCodes.includes('general_inspection'))" class="btn pg">
<!--服务顾问和总检可以重新派工-->
重新派工 重新派工
</view> </view>
<view @click="receiveOrder(order.id)" v-if="order.ticketsStatus == '05' && order.ticketsWorkStatus=='01' && roleCanJd" class="btn qc"> <view @click="receiveOrder(order.id)" v-if="order.ticketsStatus == '05' && order.ticketsWorkStatus=='01' && roleCanJd" class="btn qc">
@ -92,27 +97,29 @@ export default {
}, },
data() { data() {
return { return {
//
roleCanPg:false,
// //
roleCanQc:false, roleCanQc:false,
// //
roleCanJd:false, roleCanJd:false,
//--- //---
roleCanSg:false, roleCanSg:false,
//
userInfo:{},
ifLeader:false,
} }
}, },
mounted(){ mounted(){
let userInfo = getUserInfo() this.ifLeader = getStrData('ifLeader')
if(userInfo.roleCodes.includes("service_advisor") || userInfo.roleCodes.includes("general_inspection") || (userInfo.roleCodes.includes("repair_staff") && getStrData("ifLeader"))){ this.userInfo = getUserInfo()
// if(this.userInfo.roleCodes.includes("service_advisor") || this.userInfo.roleCodes.includes("general_inspection") || (this.userInfo.roleCodes.includes("repair_staff") && getStrData("ifLeader"))){
//,
this.roleCanPg = true this.roleCanPg = true
} }
if(userInfo.roleCodes.includes("service_advisor")){ if(this.userInfo.roleCodes.includes("service_advisor")){
// //
this.roleCanQc = true this.roleCanQc = true
} }
if(userInfo.roleCodes.includes("repair_staff") && this.order.nowRepairId==userInfo.id){ if(this.userInfo.roleCodes.includes("repair_staff") && this.order.nowRepairId==userInfo.id){
//, //,
this.roleCanJd = true this.roleCanJd = true
} }

View File

@ -97,14 +97,6 @@ export default {
params:params params:params
}).then((res) => { }).then((res) => {
if (res.code == 200) { if (res.code == 200) {
res.data.map((item)=>{
getDictTextByCodeAndValue("repair_unit",item.wares.unit).then(value => {
item.wares.unit = value
}).catch(error => {
item.wares.unit = "未知"
console.error(error);
});
})
this.repairList = res.data this.repairList = res.data
} }
}) })

View File

@ -306,7 +306,7 @@ export default {
}) })
} else { } else {
uni.showToast({ uni.showToast({
title: '请输入手机号', title: '请输入手机号码|车牌号|车架号',
icon: 'none' icon: 'none'
}) })
} }

View File

@ -553,30 +553,30 @@ export default {
} }
} }
if(this.loginUser.roleCodes.includes("repair_staff")){ if(this.loginUser.roleCodes.includes("repair_staff")){
// //
if(this.ticketInfo.nowRepairId==this.loginUser.id && "05"==this.ticketInfo.ticketsStatus){ this.content.push({
//, text: '配件申请', active: false, code: "apply"
this.content.push({ })
text: '配件申请', active: false,code:"apply" if ("05" == this.ticketInfo.ticketsStatus && this.ticketInfo.nowRepairId == this.loginUser.id) {
}) //
if("02"==this.ticketInfo.ticketsWorkStatus){ if ("02" == this.ticketInfo.ticketsWorkStatus) {
// //
this.content.push({ this.content.push({
text: '拍照上传', active: false,code:"working" text: '拍照上传', active: false, code: "working"
}) })
this.content.push({ this.content.push({
text: '阶段完成', active: false,code:"done_half" text: '阶段完成', active: false, code: "done_half"
}) })
this.content.push({ this.content.push({
text: '项目完成', active: false,code:"other" text: '项目完成', active: false, code: "other"
}) })
this.content.push({ this.content.push({
text: '移交总检', active: false,code:"done" text: '移交总检', active: false, code: "done"
}) })
// //
this.selectNowRepair() this.selectNowRepair()
} }
if("03"==this.ticketInfo.ticketsWorkStatus || "04"==this.ticketInfo.ticketsWorkStatus) { if ("03" == this.ticketInfo.ticketsWorkStatus || "04" == this.ticketInfo.ticketsWorkStatus) {
// //
this.content.push({ this.content.push({
text: '开始施工', active: false, code: "start" text: '开始施工', active: false, code: "start"

View File

@ -1,10 +1,10 @@
<template> <template>
<view class="page"> <view class="page">
<VNavigationBar background-color="rgba(0,0,0,0)" title="签名" title-color="#333"></VNavigationBar> <VNavigationBar background-color="rgba(0,0,0,0)" title="客户签名" title-color="#333"></VNavigationBar>
<view class="container"> <view class="container">
<!-- <view class="instruction">--> <view class="instruction">
<!-- 确定维修项目无误后请签名--> 确定维修项目无误后请客户签字确认
<!-- </view>--> </view>
<canvas <canvas
canvas-id="signatureCanvas" canvas-id="signatureCanvas"
class="canvas" class="canvas"
@ -38,6 +38,7 @@ export default {
onLoad(data) { onLoad(data) {
// canvas // canvas
this.context = uni.createCanvasContext("signatureCanvas", this); this.context = uni.createCanvasContext("signatureCanvas", this);
this.context.fillStyle = "white";
if (data.data){ if (data.data){
console.log('传递过来的内容', JSON.parse(data.data)) console.log('传递过来的内容', JSON.parse(data.data))
this.data = JSON.parse(data.data) this.data = JSON.parse(data.data)

View File

@ -67,8 +67,7 @@
{ {
"path": "pages/project/project", "path": "pages/project/project",
"style": { "style": {
"navigationBarTitleText": "新增维修项目", "navigationBarTitleText": "新增维修项目"
"enablePullDownRefresh": true
} }
} }
], ],
@ -94,29 +93,25 @@
{ {
"path": "choosePeople/choosePeople", "path": "choosePeople/choosePeople",
"style": { "style": {
"navigationBarTitleText": "", "navigationBarTitleText": ""
"enablePullDownRefresh": true
} }
}, },
{ {
"path": "chooseImg/chooseImg", "path": "chooseImg/chooseImg",
"style": { "style": {
"navigationBarTitleText": "", "navigationBarTitleText": ""
"enablePullDownRefresh": true
} }
}, },
{ {
"path": "reviewList/reviewList", "path": "reviewList/reviewList",
"style": { "style": {
"navigationBarTitleText": "", "navigationBarTitleText": ""
"enablePullDownRefresh": true
} }
}, },
{ {
"path": "inWare/inWare", "path": "inWare/inWare",
"style": { "style": {
"navigationBarTitleText": "", "navigationBarTitleText": ""
"enablePullDownRefresh": true
} }
} }
] ]
@ -204,8 +199,7 @@
{ {
"path": "signature/signature", "path": "signature/signature",
"style": { "style": {
"navigationBarTitleText": "", "navigationBarTitleText": ""
"enablePullDownRefresh": true
} }
} }
] ]

View File

@ -4,7 +4,7 @@
<view class="body"> <view class="body">
<u-form labelPosition="top"> <u-form labelPosition="top">
<view class="card"> <view class="card">
<u-form-item borderBottom label="上传图片" labelWidth="200"> <u-form-item borderBottom label="上传行驶证自动识别" labelWidth="200">
<u-upload></u-upload> <u-upload></u-upload>
</u-form-item> </u-form-item>
<u-form-item borderBottom label="车牌号" labelWidth="200" @click="carInputClick();"> <u-form-item borderBottom label="车牌号" labelWidth="200" @click="carInputClick();">
@ -194,6 +194,14 @@ export default {
this.getBrandList() this.getBrandList()
}, },
methods: { methods: {
/**
* 打开摄像头
*/
openCameraScan(){
uni.navigateTo({
url: '/pages/myCar/scan-frame'
});
},
typeSelect(e) { typeSelect(e) {
console.log('e', e) console.log('e', e)
}, },