Browse Source

页面修改

dev
0.0 2 years ago
parent
commit
9656182c9d
  1. 6
      src/option/basic/basicForklift.js
  2. 18
      src/option/basic/basicPdarecords.js
  3. 67
      src/views/basic/forklift/basicForklift.vue
  4. 66
      src/views/basic/pda/basicPda.vue
  5. 180
      src/views/basic/pdarecords/basicPdarecords.vue

6
src/option/basic/basicForklift.js

@ -150,15 +150,15 @@ export default {
search: true,
},
{
label: "付款周期;(月)",
label: "付款周期(月)",
prop: "paymentCycle",
},
{
label: "押金;(元)",
label: "押金(元)",
prop: "deposit",
},
{
label: "付款方式;1-先付后租,2-先租后付",
label: "付款方式",
prop: "paymentMethod",
},
{

18
src/option/basic/basicPdarecords.js

@ -1,5 +1,5 @@
export default {
size: 'small',
size: 'medium',
expand: false,
index: true,
border: true,
@ -89,13 +89,15 @@ export default {
display: false,
hide: true,
},
{
label: "关联pdaid",
prop: "masterId",
},
// {
// label: "关联pdaid",
// prop: "masterId",
// },
{
label: "反馈日期",
prop: "feedbackTime",
format: "yyyy-MM-dd",
valueFormat: "yyyy-MM-dd",
},
{
label: "营业部",
@ -103,7 +105,7 @@ export default {
search: true,
},
{
label: "维修PDA品牌/SN",
label: "维修品牌",
prop: "brand",
search: true,
},
@ -123,7 +125,7 @@ export default {
search: true,
},
{
label: "是否保修期;1-否,2-是",
label: "是否保修期",
prop: "isLiability",
search: true,
},
@ -132,7 +134,7 @@ export default {
prop: "problemDescription",
},
{
label: "维修费用;单位(元)",
label: "维修费(元)",
prop: "maintenanceCosts",
},
{

67
src/views/basic/forklift/basicForklift.vue

@ -164,7 +164,7 @@ z<template>
<el-col :span="11">
<el-form-item label="类型" prop="forkliftType">
<el-select v-model="form.forkliftType" clearable placeholder="请选择类型;1-高叉,2-托盘车,3-坐叉">
<el-select v-model="form.forkliftType" clearable placeholder="请选择类型">
<el-option
v-for="item in forkliftTypeData"
:key="item.dictKey"
@ -291,12 +291,13 @@ z<template>
<el-col :span="11">
<el-form-item label="付款方式" prop="paymentMethod">
<el-select v-model="form.paymentMethod" clearable placeholder="请选择付款方式;1-先付后租,2-先租后付">
<el-select v-model="form.paymentMethod" clearable placeholder="请选择付款方式">
<el-option
v-for="item in paymentMethodData"
:key="item.dictKey"
:label="item.dictValue"
:value="item.dictKey">
{{item.dictKey}}
</el-option>
</el-select>
</el-form-item>
@ -323,12 +324,12 @@ z<template>
<el-col :span="11">
<el-form-item label="所属仓库" prop="owningWarehouse">
<el-select v-model="form.owningWarehouse" clearable placeholder="请选择付款方式仓库">
<el-select v-model="form.owningWarehouse" clearable placeholder="请选择仓库">
<el-option
v-for="item in owningWarehouseData"
:key="item.dictKey"
:label="item.dictValue"
:value="item.dictKey">
:value="item.dictKey+''">
</el-option>
</el-select>
</el-form-item>
@ -356,6 +357,7 @@ z<template>
import {getList, getDetail, add, update, remove} from "@/api/basic/basicForklift";
import option from "@/option/basic/basicForklift";
import {mapGetters} from "vuex";
import {getDictionaryBiz} from "@/api/system/dict";
// import {getDictionary} from '@/api/system/dict'
export default {
@ -399,6 +401,10 @@ export default {
this.init();
this.onLoad(this.page);
},
created() {
//
this.queryDictionary();
},
computed: {
...mapGetters(["permission"]),
ids() {
@ -412,6 +418,23 @@ export default {
methods: {
init() {
},
queryDictionary(){
getDictionaryBiz("basic_business_line").then(res=>{
this.businessLineData =res.data.data
})
getDictionaryBiz("basic_forklift_supplier").then(res=>{
this.supplierData =res.data.data
})
getDictionaryBiz("basic_forklift_assettype").then(res=>{
this.assetTypeData =res.data.data
})
getDictionaryBiz("basic_forklift_type").then(res=>{
this.forkliftTypeData =res.data.data
})
getDictionaryBiz("basic_forklift_payment").then(res=>{
this.paymentMethodData =res.data.data
})
},
searchHide() {
this.search = !this.search;
},
@ -527,6 +550,42 @@ export default {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
// eslint-disable-next-line no-empty
for (let i = 0; i < data.records.length; i++) {
// 线
for (let j = 0; j < this.businessLineData.length; j++) {
// eslint-disable-next-line no-empty
if (data.records[i].businessLine == this.businessLineData[j].dictKey){
data.records[i].businessLine=this.businessLineData[j].dictValue;
}
}
//
for (let j = 0; j < this.supplierData.length; j++) {
// eslint-disable-next-line no-empty
if (data.records[i].supplier == this.supplierData[j].dictKey){
data.records[i].supplier=this.supplierData[j].dictValue;
}
}
for (let j = 0; j < this.assetTypeData.length; j++) {
// eslint-disable-next-line no-empty
if (data.records[i].assetType == this.assetTypeData[j].dictKey){
data.records[i].assetType=this.assetTypeData[j].dictValue;
}
}
for (let j = 0; j < this.forkliftTypeData.length; j++) {
// eslint-disable-next-line no-empty
if (data.records[i].forkliftType == this.forkliftTypeData[j].dictKey){
data.records[i].forkliftType=this.forkliftTypeData[j].dictValue;
}
}
for (let j = 0; j < this.paymentMethodData.length; j++) {
// eslint-disable-next-line no-empty
if (data.records[i].paymentMethod == this.paymentMethodData[j].dictKey){
data.records[i].paymentMethod=this.paymentMethodData[j].dictValue;
}
}
}
this.page.total = data.total;
this.data = data.records;
this.loading = false;

66
src/views/basic/pda/basicPda.vue

@ -81,6 +81,7 @@
<el-table-column prop="menu" label="操作" :width="180" align="center">
<template slot-scope="{row}">
<el-button :size="option.size" type="text" icon="el-icon-view" @click="handleView(row)">查看</el-button>
<el-button :size="option.size" type="text" icon="el-icon-view" @click="handleViewrecords(row)">查看维修记录</el-button>
<el-button :size="option.size" type="text" icon="el-icon-edit" @click="handleEdit(row)">编辑</el-button>
<el-button :size="option.size" type="text" icon="el-icon-delete" @click="rowDel(row)">删除</el-button>
</template>
@ -236,6 +237,27 @@
<el-button icon="el-icon-circle-close" :size="option.size" @click="box = false"> </el-button>
</span>
</el-dialog>
<!-- 查看维修记录 -->
<!-- <el-dialog :title="title" :visible.sync="recordbox" width="80%" :before-close="beforeClose" >-->
<!-- <el-table ref="table" :size="optionrecords.size" @selection-change="selectionChange" :data="datarecords"-->
<!-- style="width: 100%"-->
<!-- :border="optionrecords.border">-->
<!-- <el-table-column v-if="optionrecords.index" label="序号" type="index" width="50" align="center">-->
<!-- </el-table-column>-->
<!-- <template v-for="(item,index) in optionrecords.column">-->
<!-- &lt;!&ndash; table字段 &ndash;&gt;-->
<!-- <el-table-column v-if="item.hide!==true"-->
<!-- :prop="item.prop"-->
<!-- :label="item.label"-->
<!-- :width="item.width"-->
<!-- :key="index">-->
<!-- </el-table-column>-->
<!-- </template>-->
<!-- </el-table>-->
<!-- </el-dialog>-->
</div>
</basic-container>
</template>
@ -243,8 +265,9 @@
<script>
import {getList, getDetail, add, update, remove} from "@/api/basic/basicdataPda";
import option from "@/option/basic/basicdataPda";
import optionrecords from "@/option/basic/basicPdarecords";
import {mapGetters} from "vuex";
//import {getDictionary} from '@/api/system/dict'
import {getDictionaryBiz} from '@/api/system/dict'
export default {
data() {
@ -253,6 +276,8 @@ export default {
title: '',
//
box: false,
//
recordbox:false,
//
search: true,
//
@ -271,18 +296,27 @@ export default {
form: {},
//
selectionList: [],
//
//
stateData:[],
//
isDepositData:[],
//
option: option,
//
optionrecords: optionrecords,
//
data: [],
datarecords: [],
}
},
mounted() {
this.init();
this.onLoad(this.page);
},
created() {
//
this.queryDictionary();
},
computed: {
...mapGetters(["permission"]),
ids() {
@ -294,6 +328,15 @@ export default {
}
},
methods: {
queryDictionary(){
getDictionaryBiz("yes_no").then(res=>{
this.isDepositData =res.data.data
})
getDictionaryBiz("basic_pad_state").then(res=>{
this.stateData =res.data.data
})
},
init() {
},
searchHide() {
@ -348,6 +391,15 @@ export default {
this.form = res.data.data;
});
},
handleViewrecords(row) {
console.log("row.id>>>>>>>>>",row.id);
this.$router.push({
path: '/basic/pdarecords/basicPdarecords',
query: {
data:row.id
}
})
},
handleDelete() {
if (this.selectionList.length === 0) {
this.$message.warning("请选择至少一条数据");
@ -411,6 +463,16 @@ export default {
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;
// eslint-disable-next-line no-empty
for (let i = 0; i < data.records.length; i++) {
// eslint-disable-next-line no-empty
for (let j = 0; j < this.stateData.length; j++) {
// eslint-disable-next-line no-empty
if (data.records[i].state == this.stateData[j].dictKey){
data.records[i].state=this.stateData[j].dictValue;
}
}
}
this.page.total = data.total;
this.data = data.records;
this.loading = false;

180
src/views/basic/pdarecords/basicPdarecords.vue

@ -1,42 +1,42 @@
<template>
<basic-container>
<div class="avue-crud">
<el-row :hidden="!search" style="padding:5px">
<!-- 查询模块 -->
<el-form :inline="true" :size="option.size" :model="query">
<template>
<el-form-item label="字段">
<el-input v-model="query.businessDepartment" placeholder="请输入营业部"></el-input>
</el-form-item>
<el-form-item label="字段">
<el-input v-model="query.brand" placeholder="请输入维修PDA品牌/SN"></el-input>
</el-form-item>
<el-form-item label="字段">
<el-input v-model="query.dealer" placeholder="请输入采买经销商"></el-input>
</el-form-item>
<el-form-item label="字段">
<el-input v-model="query.maintenanceCompany" placeholder="请输入维修公司"></el-input>
</el-form-item>
<el-form-item label="字段">
<el-input v-model="query.repairTrackingNub" placeholder="请输入寄检修快递单号"></el-input>
</el-form-item>
<el-form-item label="字段">
<el-input v-model="query.isLiability" placeholder="请输入是否保修期;1-否,2-是"></el-input>
</el-form-item>
<el-form-item label="字段">
<el-input v-model="query.returnDate" placeholder="请输入寄回日期"></el-input>
</el-form-item>
<el-form-item label="字段">
<el-input v-model="query.returnOrderNub" placeholder="请输入维修寄回单号"></el-input>
</el-form-item>
</template>
<!-- 查询按钮 -->
<el-form-item>
<el-button type="primary" icon="el-icon-search" @click="searchChange">搜索</el-button>
<el-button icon="el-icon-delete" @click="searchReset()">清空</el-button>
</el-form-item>
</el-form>
</el-row>
<!-- <el-row :hidden="!search" style="padding:5px">-->
<!-- &lt;!&ndash; 查询模块 &ndash;&gt;-->
<!-- <el-form :inline="true" :size="option.size" :model="query">-->
<!-- <template>-->
<!-- <el-form-item label="字段">-->
<!-- <el-input v-model="query.businessDepartment" placeholder="请输入营业部"></el-input>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="字段">-->
<!-- <el-input v-model="query.brand" placeholder="请输入维修PDA品牌/SN"></el-input>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="字段">-->
<!-- <el-input v-model="query.dealer" placeholder="请输入采买经销商"></el-input>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="字段">-->
<!-- <el-input v-model="query.maintenanceCompany" placeholder="请输入维修公司"></el-input>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="字段">-->
<!-- <el-input v-model="query.repairTrackingNub" placeholder="请输入寄检修快递单号"></el-input>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="字段">-->
<!-- <el-input v-model="query.isLiability" placeholder="请输入是否保修期;1-否,2-是"></el-input>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="字段">-->
<!-- <el-input v-model="query.returnDate" placeholder="请输入寄回日期"></el-input>-->
<!-- </el-form-item>-->
<!-- <el-form-item label="字段">-->
<!-- <el-input v-model="query.returnOrderNub" placeholder="请输入维修寄回单号"></el-input>-->
<!-- </el-form-item>-->
<!-- </template>-->
<!-- &lt;!&ndash; 查询按钮 &ndash;&gt;-->
<!-- <el-form-item>-->
<!-- <el-button type="primary" icon="el-icon-search" @click="searchChange">搜索</el-button>-->
<!-- <el-button icon="el-icon-delete" @click="searchReset()">清空</el-button>-->
<!-- </el-form-item>-->
<!-- </el-form>-->
<!-- </el-row>-->
<el-row>
<div class="avue-crud__menu">
<!-- 头部左侧按钮模块 -->
@ -59,7 +59,7 @@
:border="option.border">
<el-table-column type="selection" v-if="option.selection" width="55" align="center"></el-table-column>
<el-table-column type="expand" v-if="option.expand" align="center"></el-table-column>
<el-table-column v-if="option.index" label="#" type="index" width="50" align="center">
<el-table-column v-if="option.index" label="序号" type="index" width="50" align="center">
</el-table-column>
<template v-for="(item,index) in option.column">
<!-- table字段 -->
@ -97,45 +97,94 @@
<el-dialog :title="title" :visible.sync="box" width="50%" :before-close="beforeClose" append-to-body>
<el-form :disabled="view" :size="option.size" ref="form" :model="form" label-width="80px">
<!-- 表单字段 -->
<el-form-item label="关联pdaid" prop="masterId">
<el-input v-model="form.masterId" placeholder="请输入关联pdaid"/>
</el-form-item>
<el-form-item label="反馈日期" prop="feedbackTime">
<el-input v-model="form.feedbackTime" placeholder="请输入反馈日期"/>
<!-- <el-form-item label="关联pdaid" prop="masterId">-->
<!-- <el-input v-model="form.masterId" placeholder="请输入关联pdaid"/>-->
<!-- </el-form-item>-->
<el-row>
<el-col :span="11">
<el-form-item label="反馈日期" prop="feedbackTime" label-width="80px">
<el-date-picker v-model="form.feedbackTime" placeholder="请输入反馈日期" type="date" value-format="yyyy-MM-dd"></el-date-picker>
</el-form-item>
</el-col>
<el-col :span="11">
<el-form-item label="营业部" prop="businessDepartment">
<el-input v-model="form.businessDepartment" placeholder="请输入营业部"/>
</el-form-item>
<el-form-item label="维修PDA品牌/SN" prop="brand">
<el-input v-model="form.brand" placeholder="请输入维修PDA品牌/SN"/>
</el-col>
</el-row>
<el-row>
<el-col :span="11">
<el-form-item label="维修公司" prop="maintenanceCompany">
<el-input v-model="form.maintenanceCompany" placeholder="请输入维修公司"/>
</el-form-item>
</el-col>
<el-col :span="11">
<el-form-item label="采买经销商" prop="dealer">
<el-input v-model="form.dealer" placeholder="请输入采买经销商"/>
</el-form-item>
<el-form-item label="维修公司" prop="maintenanceCompany">
<el-input v-model="form.maintenanceCompany" placeholder="请输入维修公司"/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="11">
<el-form-item label="寄检修快递单号" prop="repairTrackingNub">
<el-input v-model="form.repairTrackingNub" placeholder="请输入寄检修快递单号"/>
</el-form-item>
<el-form-item label="是否保修期;1-否,2-是" prop="isLiability">
<el-input v-model="form.isLiability" placeholder="请输入是否保修期;1-否,2-是"/>
</el-col>
<el-col :span="11">
<el-form-item label="是否保修期" prop="isLiability">
<el-select v-model="form.isLiability" clearable placeholder="是否保修期">
<el-option
v-for="item in isLiabilityData"
:key="item.dictKey"
:label="item.dictValue"
:value="item.dictKey">
</el-option>
</el-select>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="11">
<el-form-item label="问题描述" prop="problemDescription">
<el-input v-model="form.problemDescription" placeholder="请输入问题描述"/>
</el-form-item>
<el-form-item label="维修费用;单位(元)" prop="maintenanceCosts">
</el-col>
<el-col :span="11">
<el-form-item label="维修费(元)" prop="maintenanceCosts">
<el-input v-model="form.maintenanceCosts" placeholder="请输入维修费用;单位(元)"/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="11">
<el-form-item label="寄回日期" prop="returnDate">
<el-input v-model="form.returnDate" placeholder="请输入寄回日期"/>
<el-date-picker v-model="form.returnDate" placeholder="请输入寄回日期" type="date" value-format="yyyy-MM-dd"></el-date-picker>
</el-form-item>
<el-form-item label="维修寄回单号" prop="returnOrderNub">
</el-col>
<el-col :span="11">
<el-form-item label="寄回单号" prop="returnOrderNub">
<el-input v-model="form.returnOrderNub" placeholder="请输入维修寄回单号"/>
</el-form-item>
</el-col>
</el-row>
<el-row>
<el-col :span="11">
<el-form-item label="备注" prop="notes">
<el-input v-model="form.notes" placeholder="请输入备注"/>
</el-form-item>
</el-col>
</el-row>
</el-form>
<!-- 表单按钮 -->
<span v-if="!view" slot="footer" class="dialog-footer">
@ -151,6 +200,7 @@
import {getList, getDetail, add, update, remove} from "@/api/basic/basicPdarecords";
import option from "@/option/basic/basicPdarecords";
import {mapGetters} from "vuex";
import {getDictionaryBiz} from "@/api/system/dict";
// import {getDictionary} from '@/api/system/dict'
export default {
@ -178,14 +228,31 @@ export default {
form: {},
//
selectionList: [],
isLiabilityData:[],
//
option: option,
masterId:null,
//
data: [],
}
},
watch:{
$router:{
// eslint-disable-next-line no-unused-vars
handler (newName, oldName) {
this.query.masterId = this.$route.query.data
this.masterId = this.$route.query.data
this.onLoad(this.page);
},
},
},
created() {
//
this.queryDictionary();
},
mounted() {
this.init();
console.log("this.$route.data",this.$route.query.data);
this.onLoad(this.page);
},
computed: {
@ -199,6 +266,12 @@ export default {
}
},
methods: {
queryDictionary(){
getDictionaryBiz("yes_no").then(res=>{
this.isDepositData =res.data.data
})
},
init() {
},
searchHide() {
@ -214,6 +287,8 @@ export default {
},
handleSubmit() {
if (!this.form.id) {
this.form.masterId = this.$route.query.data
console.log("this.form.masterId>>>>>>>>>>>>>",this.form.masterId)
add(this.form).then(() => {
this.box = false;
this.onLoad(this.page);
@ -313,6 +388,7 @@ export default {
this.onLoad(this.page);
},
onLoad(page, params = {}) {
this.query.masterId =this.$route.query.data
this.loading = true;
getList(page.currentPage, page.pageSize, Object.assign(params, this.query)).then(res => {
const data = res.data.data;

Loading…
Cancel
Save