diff --git a/components/city/city-new.vue b/components/city/city-new.vue new file mode 100644 index 0000000..d8bcc13 --- /dev/null +++ b/components/city/city-new.vue @@ -0,0 +1,154 @@ + + + + + \ No newline at end of file diff --git a/components/notices/notice-one/notice-one.vue b/components/notices/notice-one/notice-one.vue index e0cb02c..b3186d2 100644 --- a/components/notices/notice-one/notice-one.vue +++ b/components/notices/notice-one/notice-one.vue @@ -3,10 +3,12 @@ - {{item[theKey]}} + {{item}} - {{list[0][theKey]}} + + {{list[0]}} + 更多 diff --git a/jsFile/public-api.js b/jsFile/public-api.js index db45f1e..2ea892f 100644 --- a/jsFile/public-api.js +++ b/jsFile/public-api.js @@ -20,7 +20,7 @@ export function queryFun(data) { // (客户、项目、备品)详情 export function queryDetail(data) { - return request.post("/universal/api.search/search_info", data); + return request.get("/universal/api.search/search_info", data); } // 处理工单,获取 diff --git a/pages/tabbar/my/my.vue b/pages/tabbar/my/my.vue index 16aa31d..ae45569 100644 --- a/pages/tabbar/my/my.vue +++ b/pages/tabbar/my/my.vue @@ -256,12 +256,6 @@ url: urls[index] }) }, - // 前往设置页面 - goSetUp() { - uni.navigateTo({ - url: '/pagesB/set-up/set-up' - }) - } } } diff --git a/pages/tabbar/pagehome/pagehome.vue b/pages/tabbar/pagehome/pagehome.vue index 68e55bb..9b601a5 100644 --- a/pages/tabbar/pagehome/pagehome.vue +++ b/pages/tabbar/pagehome/pagehome.vue @@ -36,14 +36,15 @@ 实时工单 - {{fault_count || 0}} + {{project_error_count || 0}} - + + @@ -254,6 +255,8 @@ statusHeight: uni.getSystemInfoSync().statusBarHeight + 50, messageNumber: 0 ,// 消息数量 noticeList:[{id:1,title:'系统正在维护中...'}],//公告 + announcement:[], //公告 + announcementNum:0, //公告数量 // 故障报修 repairList:[ {imgsrc:'/static/public/icon-home-repair.png',title:'报修'}, @@ -324,7 +327,7 @@ locationstr:'', contactPhone:'',//客服联系电话 project_count:0,//项目数量 - fault_count:0,//实时工单数量 + project_error_count:0,//实时工单数量 } }, onShow() { @@ -347,19 +350,43 @@ this.$requst.get('/universal/api.home/home').then(res=>{ if(res.code) { let homeObj = res.data; - this.messageNumber = homeObj.message;//消息数量 + console.log(res,'首页信息查询') + this.messageNumber = homeObj.unread_messages;//消息数量 this.contactPhone = homeObj.contact;//客服联系电话 this.project_count = homeObj.project_count;//项目数量 - this.fault_count = homeObj.fault_count;//实时工单数量 + this.project_error_count = homeObj.project_error_count;//实时工单数量 + + this.projectRepairList[0].num = homeObj.pending_order_count; //待接单数量 + this.projectRepairList[1].num = homeObj.pending_count; //待执行数量 + this.projectRepairList[2].num = homeObj.under_repair_count; //维修中数量 + + this.workOrderList[0].num = homeObj.abnormal_order_count; //异常单数量 + this.workOrderList[1].num = homeObj.overdue_order_count; //逾期单数量 + this.workOrderList[2].num = homeObj.time_out_order_count; //超时单数量 + this.workOrderList[3].num = homeObj.work_order_count; //工单池数量 + + this.settlementList[0].num = homeObj.pending_payment_count; //待收款数量 + this.settlementList[1].num = homeObj.paid_for_count; //已收款数量 + + this.stayEventList[0].num = homeObj.approval_count; //待审批数量 + this.stayEventList[1].num = homeObj.pending_payment_count; //待收款数量 + // 重构公告列表 - if(homeObj.notice.length) { - homeObj.notice.forEach(item=>{ - let obj = { - id:1, - title:`${item.name}:${item.content}` - } - this.noticeList.push(obj); - }) + // if(homeObj.notice.length) { + // homeObj.notice.forEach(item=>{ + // let obj = { + // id:1, + // title:`${item.name}:${item.content}` + // } + // this.noticeList.push(obj); + // }) + // } + + // 重构公告列表 + if(homeObj.announcement.length>0){ + this.announcementNum = homeObj.announcement.length; + this.announcement = homeObj.announcement; + console.log(this.announcement,'公告列表') } } }) diff --git a/pagesA/dataQuery/dataQuery.vue b/pagesA/dataQuery/dataQuery.vue index ccf6659..b8bdff4 100644 --- a/pagesA/dataQuery/dataQuery.vue +++ b/pagesA/dataQuery/dataQuery.vue @@ -88,6 +88,7 @@ page: this.page } queryFun(params).then(res => { + console.log(res,'备品列表') if (res.code) { this.total = res.data.total; //设置总条数 if (this.page == 1) this.dataList = []; @@ -95,13 +96,13 @@ res.data.data.forEach(item=>{ let obj = { id:item.spare_id, - name:item.name,//项目名称 + name:item.project_name,//项目名称 brand:item.brand,//核心品牌 quantity: item.quantity,//备品数量 - model:item.model,//规格型号 + model:item.product_model,//规格型号 size:item.size,//产品尺寸 batch_number:item.batch_number,//批次号 - time:item.time,//入库时间 + time:item.warehousing_time,//入库时间 status:item.status //0:正常 1:待维修 } this.dataList.push(obj); diff --git a/pagesA/dataQuery/details.vue b/pagesA/dataQuery/details.vue index f118743..c5539fa 100644 --- a/pagesA/dataQuery/details.vue +++ b/pagesA/dataQuery/details.vue @@ -23,36 +23,10 @@ 基本信息 - - - 客户名称:长沙警校 + + {{item.name}}:{{item.value}} - - 客户编号:xxxxxxxxx - - - 客户等级:VIP1 - - - 所属行业:安防 - - - 客户类型:xxxx - - - 入库时间:2022.3.1 - - - 项目数量:50 - - - 所属区域:长沙 - - - 详细地址:长沙xxxxx - - @@ -60,34 +34,10 @@ 联系人 - - - 姓名:Eveal + + {{item.name}}:{{item.value}} - - 所属部门:产品研发部 - - - 职务:经理 - - - 电话:154751787 - - - 微信:14250 - - - qq:9090000 - - - 邮箱:1216311@qq.com - - - 负责时间段:xxxxx - - - @@ -147,22 +97,15 @@ }, data() { return { - dataArr:{ - customerName:"长沙警校", - customerCode:"xxxxxxxxx", - customerVIP:"VIP1", - industryInvolved:"安防", - customerType:"xxxx", - warehouseTime:"2022.3.1" , - projectNum:"50", - area:"长沙", - - }, + dataArr:[], //基本信息 + contactArr:[], //联系人 clientId:'',//客户id yearArr:[],//年份 currentyear: '',//当前年份 chooseyear:'',//选中的年份 - projectList:[]//项目列表 + projectList:[],//项目列表 + phone:'', //客户电话 + wechart:'', //客户微信 } }, onLoad(op){ @@ -184,8 +127,24 @@ // 查询客户详情信息 queryDetailEv(){ queryDetail({type_id:1,member_id:this.clientId}).then(res=>{ + console.log(res,'客户详情信息') if(res.code) { - + res.data.basic_information.forEach(item=>{ + let obj={ + name:item.name, + value:item.value + } + this.dataArr.push(obj) + }) + res.data.principal.forEach(item=>{ + let obj={ + name:item.name, + value:item.value + } + this.contactArr.push(obj) + }) + this.wechart = res.data.wechat; + this.phone = res.data.phone; } else { this.$toolAll.tools.showToast(res.msg); } @@ -218,16 +177,25 @@ }, // 复制微信 copyWxFun(){ - uni.setClipboardData({ - data: 'hello', - success: function () {} - }); + if(this.wechart !== ''){ + uni.setClipboardData({ + data: this.wechart, + success: function () {} + }); + }else{ + this.$toolAll.tools.showToast('客户微信号为空'); + } + }, // 拨打电话 telFun(){ - uni.makePhoneCall({ - phoneNumber: '13608235524' //仅为示例 - }); + if(this.phone !== ''){ + uni.makePhoneCall({ + phoneNumber: this.phone + }); + }else{ + this.$toolAll.tools.showToast('客户电话号为空'); + } } } } diff --git a/pagesA/peopleManagement/peopleManagement.vue b/pagesA/peopleManagement/peopleManagement.vue index 5ea0a4b..930e007 100644 --- a/pagesA/peopleManagement/peopleManagement.vue +++ b/pagesA/peopleManagement/peopleManagement.vue @@ -4,8 +4,8 @@ - - + + @@ -100,25 +100,25 @@ page:this.page, keyword:this.keyword } - this.$requst.get('/universal/api.user/user_location',params).then(res=>{ + this.$requst.get('/universal/api.order/user_location',params).then(res=>{ if(res.code) { this.total = res.data.total; if(this.page==1) this.dataList = []; if(res.data.data.length) { res.data.data.forEach(item=>{ let obj = { - id:1, + id:item.uid, name: item.name, - imgsrc:'https://s6.jpg.cm/2022/02/14/L4oDhy.jpg', - number:'YG20211207-001', - rate:5, + imgsrc:item.avatar, + number:item.user_number, + rate:item.starlevel, num:item.pending_order, allnum:item.processed_order, address:item.address, phone:item.phone, time:item.register_time, state: false, - isJob: item.is_working ? true : false, + isJob: item.is_working==1 ? true : false, is_check:item.is_check } this.dataList.push(obj); @@ -132,6 +132,7 @@ this.page = 1; this.checkList(); }, + listStateFun(item){ this.dataList.forEach(item1=>{item1.state = false}) item.state = !item.state; @@ -192,6 +193,7 @@ right: 43rpx; top: 50%; margin-top: -14rpx; + z-index: 9; } .peopleManagement-content .li { background-color: #FFFFFF; diff --git a/pagesA/project/details.vue b/pagesA/project/details.vue index 186a0aa..e164189 100644 --- a/pagesA/project/details.vue +++ b/pagesA/project/details.vue @@ -13,7 +13,7 @@ - {{index}}/{{imgNum}} + {{index+1}}/{{imgNum}} {{projectObj.project_name}} {{projectObj.project_number}} @@ -151,7 +151,7 @@ }) }, changeAutoplay(data) { - this.index = data.detail.current - 0 + 1 + this.index = data.detail.current; }, getData(id) { this.$requst.get('/universal/api.project/project_info', { diff --git a/pagesA/workOrder/details.vue b/pagesA/workOrder/details.vue index f146919..4a875de 100644 --- a/pagesA/workOrder/details.vue +++ b/pagesA/workOrder/details.vue @@ -188,32 +188,6 @@ 使用数量:1张 - - - - - - 全彩LED显示屏电源 - 1011-1 - - 配件品牌:华鑫电源 - 规格型号:5A-75B - 使用数量:1张 - - - - - - - 全彩LED显示屏电源 - 1011-1 - - 配件品牌:华鑫电源 - 规格型号:5A-75B - 使用数量:1张 - - @@ -328,9 +302,10 @@ getDetail(type) { let params = { order_id: this.orderId, - type + type:type } this.$requst.get('/universal/api.order/order_info', params).then(res => { + console.log(res.data,'工单详情') if (res.code) { switch (type) { case 1: @@ -377,7 +352,7 @@ swiperCurrentFun(data) { let current = data.detail.current; // 调用工单详情切换事件 - this.detailSwitch(current); + // this.detailSwitch(current); this.detailsNavFun(current); }, detailsNavFun(index) { diff --git a/pagesB/new-product/new-product.vue b/pagesB/new-product/new-product.vue index 494a07c..86efa4d 100644 --- a/pagesB/new-product/new-product.vue +++ b/pagesB/new-product/new-product.vue @@ -31,11 +31,9 @@ }, data() { return { - dataList:[ - {id:1,imgsrc:'/static/del/img001.png',title:'智能会议平板交互电子白板会议一体机视 频会议多媒体教学培训',num:'1台',peopleNum:'1135'}, - ], + dataList:[], page:1, - size:20, + size:10, total:0, ifLoading:true } @@ -58,16 +56,28 @@ title:'加载中...', mask:true }) - // this.$request.get('',{list_rows:this.size,page:this.page}).then(res=>{ - // if(res.code) { - // this.total = res.data.total; - // if(this.page==1) this.dataList = []; - // } else { - // this.$toolAll.tools.showToast(res.msg); - // } + this.$requst.get('/universal/api.new_product/new_product_list',{list_rows:this.size,page:this.page}).then(res=>{ + if(res.code) { + this.total = res.data.total; + let list = res.data.data; + list.forEach(item=>{ + let obj={ + id: item.id, //id + title: item.title, //标题 + summary: item.summary, //简介 + peopleNum: item.purchase, //采购量 + num: item.moq, //起订量 + imgsrc: item.cover_img //封面 + } + this.dataList.push(obj); + }) + console.log(this.dataList,'新产品列表2') + } else { + this.$toolAll.tools.showToast(res.msg); + } uni.hideLoading(); this.ifLoading = false; - // }) + }) }, // 去新产品详情 goDetail(index){ diff --git a/pagesB/service-range/service-range.vue b/pagesB/service-range/service-range.vue index 5967bf7..90a57d4 100644 --- a/pagesB/service-range/service-range.vue +++ b/pagesB/service-range/service-range.vue @@ -30,7 +30,7 @@ 服务范围 * - {{item}} + {{item}}KM @@ -47,7 +47,7 @@