Compare commits

..

No commits in common. "278847d927cde09b66650a46cd153969eb629ca9" and "9b668e83100dea3203c7577533106c324eb92815" have entirely different histories.

9 changed files with 35 additions and 146 deletions

View File

@ -109,9 +109,6 @@
<el-button size="mini" type="text" icon="el-icon-view" @click="handleShow(scope.row)" <el-button size="mini" type="text" icon="el-icon-view" @click="handleShow(scope.row)"
>查看 >查看
</el-button> </el-button>
<el-button size="mini" type="text" icon="el-icon-view" @click="handleShowIn(scope.row)"
>查看入库单
</el-button>
<el-button @click="handleInWares(scope.row)" v-if="scope.row.soStatus === '02'" size="mini" type="text" <el-button @click="handleInWares(scope.row)" v-if="scope.row.soStatus === '02'" size="mini" type="text"
icon="el-icon-edit-outline" icon="el-icon-edit-outline"
>入库 >入库
@ -233,40 +230,6 @@
<el-button @click="dialogVisible = false">取消</el-button> <el-button @click="dialogVisible = false">取消</el-button>
</div> </div>
</el-dialog> </el-dialog>
<el-dialog title="入库单" :visible.sync="inDialog" width="80%" v-dialogDrag append-to-body>
<el-table :data="inData" v-loading="inLoading2" :row-key="getRowKey" :expand-row-keys="expands" @expand-change="handleExpand" :stripe="true" :show-overflow-tooltip="true">
<el-table-column type="expand">
<template slot-scope="scope">
<el-table :data="inSoiList" v-loading="inLoading3" :stripe="true" :show-overflow-tooltip="true">
<el-table-column label="序号" align="center" width="55">
<template scope="scope">
<span>{{ scope.$index + 1 }}</span>
</template>
</el-table-column>
<el-table-column label="名称" align="center" prop="repairWares.name" />
<el-table-column label="单价" align="center" prop="goodsPrice" />
<el-table-column label="入库数量" align="center" prop="goodsCount" />
</el-table>
</template>
</el-table-column>
<el-table-column label="序号" align="center" width="55">
<template scope="scope">
<span>{{ scope.$index + 1 }}</span>
</template>
</el-table-column>
<el-table-column label="单号" align="center" prop="soNo" />
<el-table-column label="入库时间" align="center" prop="createTime">
<template slot-scope="scope">
{{parseTime(scope.row.createTime)}}
</template>
</el-table-column>
<el-table-column label="入库人" align="center" prop="userName" />
</el-table>
<div slot="footer" class="dialog-footer">
<el-button @click="inDialog = false">关闭</el-button>
</div>
</el-dialog>
</div> </div>
</template> </template>
@ -282,8 +245,6 @@ import {getRepairSoiByIds, getMapBySoIdAndQuery} from "@/api/repair/stockOperate
import {createUniqueCodeByHead} from "@/utils/createUniqueCode"; import {createUniqueCodeByHead} from "@/utils/createUniqueCode";
import WarehouseChoose from "@/views/repair/Components/WarehouseChoose.vue"; import WarehouseChoose from "@/views/repair/Components/WarehouseChoose.vue";
import {getBaseTypeList} from "@/api/base/type"; import {getBaseTypeList} from "@/api/base/type";
import {getUserProfile} from "@/api/system/user";
import {parseTime} from "../../../../utils/ruoyi";
export default { export default {
name: "SoIndex", name: "SoIndex",
@ -381,61 +342,12 @@ export default {
isRefresh: false, isRefresh: false,
// //
exportLoading: false, exportLoading: false,
inQueryParams:{
pageNo: 1,
pageSize: 10,
userId: null,
mainId: null,
},
inDialog: false,
inData: [],
inTotal: 0,
inLoading2: false,
expands: [],
getRowKey:(row) => {
return row.id
},
inSoiList: [],
inLoading3: false
} }
}, },
mounted() { mounted() {
this.pageSo(); this.pageSo();
}, },
methods: { methods: {
parseTime,
async handleExpand(row, expandedRows){
let that = this
if (expandedRows.length){
that.expands = []
if (row){
that.expands.push(row.id)
try {
that.inLoading3 = true
const resSo = await getRepairSoById(row.id)
const ids = resSo.data.goodsList.map(item => item.id)
const resSoi = await getRepairSoiByIds(ids)
this.inSoiList = resSoi.data
that.inLoading3 = false
}catch{}
}
}else {
that.expands = []
}
},
async handleShowIn(row){
try {
this.inDialog = true
this.inLoading2 = true
this.inQueryParams.mainId = row.id
const user = await getUserProfile();
this.inQueryParams.userId = user.data.id
const res = await getRepairSoPage(this.inQueryParams)
this.inData = res.data.records
this.inTotal = res.data.total
this.inLoading2 = false
}catch{}
},
setSelectedRows() { setSelectedRows() {
this.$nextTick(() => { this.$nextTick(() => {
Object.keys(this.$refs).forEach(key => { Object.keys(this.$refs).forEach(key => {

View File

@ -230,11 +230,11 @@ export default {
getLabelName() { getLabelName() {
switch (this.itemType) { switch (this.itemType) {
case "project": case "project":
return "名称"; return "维修项目";
case "part": case "part":
return "名称"; return "维修配件";
case "other": case "other":
return "名称"; return "附加费用";
default: default:
return ''; return '';
} }

View File

@ -148,11 +148,11 @@ export default {
getLabelName() { getLabelName() {
switch (this.listType) { switch (this.listType) {
case "project": case "project":
return "名称"; return "维修项目";
case "ware": case "ware":
return "名称"; return "维修配件";
case "other": case "other":
return "名称"; return "附加费用";
default: default:
return ''; return '';
} }

View File

@ -53,20 +53,20 @@
</el-button> </el-button>
<!-- 维修工才有 --> <!-- 维修工才有 -->
<el-button <el-button
v-if="scope.row.isFinish !== '1' && (scope.row.ticketsWorkStatus === '01' && userRole === 'repair_staff') && nowUser.id === scope.row.nowRepairId" v-if="(scope.row.ticketsWorkStatus === '01' && userRole === 'repair_staff') && nowUser.id === scope.row.nowRepairId"
size="mini" type="text" icon="el-icon-check" @click="handleTake(scope.row)"> size="mini" type="text" icon="el-icon-check" @click="handleTake(scope.row)">
接单 接单
</el-button> </el-button>
<!-- 服务顾问才有 --> <!-- 服务顾问才有 -->
<el-button v-if=" scope.row.isFinish !== '1' && userRole === 'service_advisor' && scope.row.ticketsWorkStatus === '01'" size="mini" <el-button v-if="userRole === 'service_advisor' && scope.row.ticketsWorkStatus === '01'" size="mini"
type="text" icon="el-icon-check" @click="handleNotify(scope.row)"> type="text" icon="el-icon-check" @click="handleNotify(scope.row)">
通知施工 通知施工
</el-button> </el-button>
<!-- 服务顾问总检班组长才有 --> <!-- 服务顾问总检班组长才有 -->
<el-button v-if="scope.row.isFinish !== '1' && (userRole !== 'repair_staff' && scope.row.ticketsWorkStatus !== '01') || (userRole === 'repair_staff' && leader && nowUser.id === scope.row.nowRepairId && scope.row.ticketsWorkStatus !== '04')" @click="handleReTake(scope.row)" size="mini" type="text" icon="el-icon-refresh" <el-button v-if="(userRole !== 'repair_staff' && scope.row.ticketsWorkStatus !== '01') || (userRole === 'repair_staff' && leader && nowUser.id === scope.row.nowRepairId && scope.row.ticketsWorkStatus !== '04')" @click="handleReTake(scope.row)" size="mini" type="text" icon="el-icon-refresh"
>{{ userRole === 'general_inspection' ? "内返派工" : "修改派工" }} >{{ userRole === 'general_inspection' ? "内返派工" : "修改派工" }}
</el-button> </el-button>
<el-dropdown v-if="scope.row.isFinish !== '1'" <el-dropdown
@command="(command) => handleCommand(command, scope.$index, scope.row)"> @command="(command) => handleCommand(command, scope.$index, scope.row)">
<el-button size="mini" type="text" icon="el-icon-d-arrow-right">更多</el-button> <el-button size="mini" type="text" icon="el-icon-d-arrow-right">更多</el-button>
<el-dropdown-menu slot="dropdown"> <el-dropdown-menu slot="dropdown">
@ -115,7 +115,7 @@
<el-button size="mini" type="text" icon="el-icon-view" @click="handleShow(scope.row)" <el-button size="mini" type="text" icon="el-icon-view" @click="handleShow(scope.row)"
>查看 >查看
</el-button> </el-button>
<el-button v-if="scope.row.isFinish !== '1'" v-hasPermi="['repair:tkm:edit']" size="mini" type="text" icon="el-icon-setting" @click="handleEditTicket(scope.row)"> <el-button v-hasPermi="['repair:tkm:edit']" size="mini" type="text" icon="el-icon-setting" @click="handleEditTicket(scope.row)">
编辑工单 编辑工单
</el-button> </el-button>
</template> </template>

View File

@ -123,9 +123,9 @@
@click="handlePrint(scope.row)" @click="handlePrint(scope.row)"
>下载打印 >下载打印
</el-button> </el-button>
<!-- <el-button size="mini" v-hasPermi="['repair:tk:edit']" type="text" icon="el-icon-setting" @click="handleEditTicket(scope.row)">--> <el-button size="mini" v-hasPermi="['repair:tk:edit']" type="text" icon="el-icon-setting" @click="handleEditTicket(scope.row)">
<!-- 编辑工单--> 编辑工单
<!-- </el-button>--> </el-button>
<el-button size="mini" v-hasPermi="['repair:tk:remove']" type="text" icon="el-icon-remove" @click="handleRemove(scope.row)"> <el-button size="mini" v-hasPermi="['repair:tk:remove']" type="text" icon="el-icon-remove" @click="handleRemove(scope.row)">
删除 删除
</el-button> </el-button>

View File

@ -139,21 +139,6 @@
</template> </template>
<StaffChoose v-model="selectStaff" :is-get="'true'"/> <StaffChoose v-model="selectStaff" :is-get="'true'"/>
</el-descriptions-item> </el-descriptions-item>
<el-descriptions-item>
<template slot="label">
经办人姓名
</template>
<el-input v-model="formData.handleName" />
</el-descriptions-item>
<el-descriptions-item>
<template slot="label">
经办人电话
</template>
<el-input v-model="formData.handleMobile" />
</el-descriptions-item>
<el-descriptions-item>
<!-- 占位 -->
</el-descriptions-item>
<el-descriptions-item> <el-descriptions-item>
<template slot="label"> <template slot="label">
接车图片 接车图片
@ -240,10 +225,10 @@
<el-button size="small" v-if="formData.ticketType === '02'" @click="formData.ticketType = '01'">B单</el-button> <el-button size="small" v-if="formData.ticketType === '02'" @click="formData.ticketType = '01'">B单</el-button>
</el-col> </el-col>
</el-row> </el-row>
<span style="font-size: 16px">维修工时项目</span> <span style="font-size: 16px">维修项目</span>
<TicketItem item-type="project" :in-list-data="projectList" @tableData="projectData" ref="projectTable" <TicketItem item-type="project" :in-list-data="projectList" @tableData="projectData" ref="projectTable"
:coupon-list="couponList" @changeCoupon="changeCoupon"/> :coupon-list="couponList" @changeCoupon="changeCoupon"/>
<span style="font-size: 16px; margin:1rem 0" v-if="createTicketType">更换配件清单</span> <span style="font-size: 16px; margin:1rem 0" v-if="createTicketType">维修配件</span>
<TicketItem v-if="createTicketType" :in-list-data="partList" item-type="part" @tableData="partData" <TicketItem v-if="createTicketType" :in-list-data="partList" item-type="part" @tableData="partData"
:coupon-list="couponList" @changeCoupon="changeCoupon" :coupon-list="couponList" @changeCoupon="changeCoupon"
ref="partTable"/> ref="partTable"/>
@ -352,8 +337,6 @@ export default {
watch: { watch: {
selectUser(val) { selectUser(val) {
if (val) { if (val) {
this.formData.handleName = val.cusName
this.formData.handleMobile = val.phoneNumber
if (!val.isRes) { if (!val.isRes) {
this.selectCar = {} this.selectCar = {}
this.bookingList = [] this.bookingList = []
@ -366,8 +349,6 @@ export default {
} }
} }
} else { } else {
this.formData.handleName = null
this.formData.handleMobile = null
this.selectCar = {} this.selectCar = {}
this.bookingList = [] this.bookingList = []
this.couponList = [] this.couponList = []
@ -426,9 +407,7 @@ export default {
rescueMoney: 0, rescueMoney: 0,
threePackMoney: 0, threePackMoney: 0,
confirmFaultMoney: 0, confirmFaultMoney: 0,
image: null, image: null
handleName: null,
handleMobile: null,
}, },
selectUser: {}, selectUser: {},
selectCar: {}, selectCar: {},
@ -577,9 +556,7 @@ export default {
rescueMoney: 0, rescueMoney: 0,
threePackMoney: 0, threePackMoney: 0,
confirmFaultMoney: 0, confirmFaultMoney: 0,
image: null, image: null
handleName: null,
handleMobile: null,
} }
this.selectUser = {} this.selectUser = {}
this.selectCar = {} this.selectCar = {}

View File

@ -10,7 +10,7 @@
<el-tab-pane label="待处理工单" name="unInspection" v-if="userRole !== 'repair_staff'"> <el-tab-pane label="待处理工单" name="unInspection" v-if="userRole !== 'repair_staff'">
<TicketFinishManager :user-role="userRole" /> <TicketFinishManager :user-role="userRole" />
</el-tab-pane> </el-tab-pane>
<el-tab-pane label="配件申请单" name="getApply"> <el-tab-pane label="配件申请单" name="getApply" v-if="userRole !== 'repair_staff'">
<TicketWares :type="true" :user-role="userRole"/> <TicketWares :type="true" :user-role="userRole"/>
</el-tab-pane> </el-tab-pane>
<el-tab-pane name="finishGetWares" label="领料确认" v-if="userRole === 'repair_staff'"> <el-tab-pane name="finishGetWares" label="领料确认" v-if="userRole === 'repair_staff'">

View File

@ -146,18 +146,18 @@
</el-select> </el-select>
</el-form-item> </el-form-item>
</el-col> </el-col>
<!-- <el-col :span="12">--> <el-col :span="12">
<!-- <el-form-item label="岗位">--> <el-form-item label="岗位">
<!-- <el-select v-model="form.postIds" multiple placeholder="请选择">--> <el-select v-model="form.postIds" multiple placeholder="请选择">
<!-- <el-option--> <el-option
<!-- v-for="item in postOptions"--> v-for="item in postOptions"
<!-- :key="item.id"--> :key="item.id"
<!-- :label="item.name"--> :label="item.name"
<!-- :value="item.id"--> :value="item.id"
<!-- ></el-option>--> ></el-option>
<!-- </el-select>--> </el-select>
<!-- </el-form-item>--> </el-form-item>
<!-- </el-col>--> </el-col>
</el-row> </el-row>
<el-row> <el-row>
<el-col :span="24"> <el-col :span="24">

View File

@ -27,10 +27,10 @@
<svg-icon icon-class="tree" />所属部门 <svg-icon icon-class="tree" />所属部门
<div class="pull-right" v-if="user.dept">{{ user.dept.name }}</div> <div class="pull-right" v-if="user.dept">{{ user.dept.name }}</div>
</li> </li>
<!-- <li class="list-group-item">--> <li class="list-group-item">
<!-- <svg-icon icon-class="tree" />所属岗位--> <svg-icon icon-class="tree" />所属岗位
<!-- <div class="pull-right" v-if="user.posts">{{ user.posts.map(post => post.name).join(',') }}</div>--> <div class="pull-right" v-if="user.posts">{{ user.posts.map(post => post.name).join(',') }}</div>
<!-- </li>--> </li>
<li class="list-group-item"> <li class="list-group-item">
<svg-icon icon-class="peoples" />所属角色 <svg-icon icon-class="peoples" />所属角色
<div class="pull-right" v-if="user.roles">{{ user.roles.map(role => role.name).join(',') }}</div> <div class="pull-right" v-if="user.roles">{{ user.roles.map(role => role.name).join(',') }}</div>