Commit fde55b76 by 莫晓莉

mxl

parent 627840de
...@@ -39,3 +39,8 @@ export const satisfactionEvaluation = (data) => { ...@@ -39,3 +39,8 @@ export const satisfactionEvaluation = (data) => {
export const getApplyProject = (data) => { export const getApplyProject = (data) => {
return request('getApplyProject', data) return request('getApplyProject', data)
} }
//获取历史反馈
export const getSatisfactionEvaluation = (data) => {
return request('getSatisfactionEvaluation', data)
}
...@@ -37,7 +37,7 @@ ...@@ -37,7 +37,7 @@
,{ ,{
"path" : "pages/evaluate-history/evaluate-history", "path" : "pages/evaluate-history/evaluate-history",
"style" : { "style" : {
"navigationBarTitleText": "历史评价" "navigationBarTitleText": "反馈历史"
} }
} }
,{ ,{
......
...@@ -7,12 +7,12 @@ ...@@ -7,12 +7,12 @@
<view class="ser-name ellipsis2" style="">服务名称</view> <view class="ser-name ellipsis2" style="">服务名称</view>
<view class="time">2020.9.10</view> <view class="time">2020.9.10</view>
</view> </view>
<view> <!-- <view>
<text></text> <text></text>
<text></text> <text></text>
<text></text> <text></text>
<text></text> <text></text>
</view> </view> -->
<view style="color:#ccc;"> <view style="color:#ccc;">
服务好,非常满意 服务好,非常满意
</view> </view>
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
</view> </view>
</view> </view>
<view class="flex m-list" style=""> <!-- <view class="flex m-list" style="">
<image class="head-img" style="" src="../../static/img/app-icon.png"></image> <image class="head-img" style="" src="../../static/img/app-icon.png"></image>
<view> <view>
<view class="flex"> <view class="flex">
...@@ -50,26 +50,29 @@ ...@@ -50,26 +50,29 @@
</view> </view>
</view> </view>
</view> </view> -->
</view> </view>
</template> </template>
<script> <script>
import { import {
getApplyProject getSatisfactionEvaluation
} from "@/api/login" } from "@/api/login"
export default { export default {
data() { data() {
return { return {
page:1,
size:5
} }
}, },
onShow() {
this.getSatisfactionEvaluation();
},
methods: { methods: {
getApplyProject(){ getSatisfactionEvaluation(){
getApplyProject({ getSatisfactionEvaluation({page:this.page,size:this.size}).then(res => {
phone: this.addForm.phone
}).then(res => {
if (res.code == 200) { if (res.code == 200) {
console.log(res);
uni.showToast({ uni.showToast({
icon: 'success', icon: 'success',
title: '获取成功', title: '获取成功',
......
...@@ -28,9 +28,9 @@ ...@@ -28,9 +28,9 @@
<view class="category-title"> <view class="category-title">
反馈项目<text style="color:red;">*</text> 反馈项目<text style="color:red;">*</text>
</view> </view>
<picker style="border:1upx solid #ccc;" @change="proChange" :value="projectTypeIndex" :range="projectTypeList" range-key="projectName"> <picker style="border:1upx solid #ccc;" @change="ChangeProId" :value="applyProjectListIndex" :range="applyProjectList" range-key="disableUserProjectTypeName">
<view class="flex-a-c" style="height:80upx;line-height: 80upx;padding:0 25upx;"> <view class="flex-a-c" style="height:80upx;line-height: 80upx;padding:0 25upx;">
<view class="flex1 picker-content">{{projectTypeIndex>-1?projectTypeList[projectTypeIndex].projectName:'点击选择'}}</view> <view class="flex1 picker-content">{{applyProjectListIndex>-1?applyProjectList[applyProjectListIndex].disableUserProjectTypeName:'点击选择'}}</view>
<view class="trangle"></view> <view class="trangle"></view>
</view> </view>
</picker> </picker>
...@@ -68,11 +68,14 @@ ...@@ -68,11 +68,14 @@
<script> <script>
import { import {
getApplyProject,
satisfactionEvaluation satisfactionEvaluation
} from "@/api/login" } from "@/api/login"
export default { export default {
data() { data() {
return { return {
applyProjectListIndex:-1,
applyProjectList:[],//已经通过审批的服务
projectId:0, projectId:0,
evaluationForm: {}, evaluationForm: {},
imageUrl: [], // imageUrl: [], //
...@@ -157,6 +160,9 @@ ...@@ -157,6 +160,9 @@
} }
}, },
onShow() {
this.getApplyProject();
},
methods: { methods: {
// uni-app上传图片 // uni-app上传图片
uploadPictures() { uploadPictures() {
...@@ -217,6 +223,13 @@ ...@@ -217,6 +223,13 @@
}, },
// 提交反馈 // 提交反馈
satisfactionEvaluation() { satisfactionEvaluation() {
if (this.evaluationForm.projectId == undefined) {
uni.showToast({
icon: 'none',
title: '请选择反馈服务'
});
return;
}
if (this.evaluationForm.remark == undefined) { if (this.evaluationForm.remark == undefined) {
uni.showToast({ uni.showToast({
icon: 'none', icon: 'none',
...@@ -246,6 +259,22 @@ ...@@ -246,6 +259,22 @@
} }
}) })
}, },
getApplyProject(){
getApplyProject({size:20,page:1}).then(res => {
if (res.code == 200) {
var list=res.data.data.rows;
this.applyProjectList=list;
}
})
},
//选择项目
ChangeProId(e) {
this.applyProjectListIndex = e.detail.value;
this.evaluationForm.projectId=this.applyProjectList[this.applyProjectListIndex].id;
this.evaluationForm.sort=this.applyProjectList[this.applyProjectListIndex].disableUserProjectTypeName;
this.evaluationForm.disableUserProjectTypeId=this.applyProjectList[this.applyProjectListIndex].disableUserProjectTypeId;
},
} }
} }
......
...@@ -60,14 +60,14 @@ ...@@ -60,14 +60,14 @@
<navigator url="../reg/reg">注册账号</navigator> <navigator url="../reg/reg">注册账号</navigator>
</view> </view>
<view class="oauth-row" v-if="hasProvider" v-bind:style="{top: positionTop + 'px'}"> <!-- <view class="oauth-row" v-if="hasProvider" v-bind:style="{top: positionTop + 'px'}">
<view class="oauth-image" v-for="provider in providerList" :key="provider.value"> <view class="oauth-image" v-for="provider in providerList" :key="provider.value">
<image :src="provider.image" @tap="oauth(provider.value)"></image> <image :src="provider.image" @tap="oauth(provider.value)"></image>
<!-- #ifdef MP-WEIXIN -->
<button v-if="!isDevtools" open-type="getUserInfo" @getuserinfo="getUserInfo"></button> <button v-if="!isDevtools" open-type="getUserInfo" @getuserinfo="getUserInfo"></button>
<!-- #endif -->
</view> </view>
</view> </view> -->
</view> </view>
</template> </template>
......
<template> <template>
<view class="content"> <view class="content">
<view v-if="hasLogin" class="hello"> <view v-if="token" class="hello">
<view class="title"> <view class="title">
您好 {{userName}},您已成功登录。 您好 {{user.name}},您已成功登录。
</view> </view>
<view class="ul"> <view class="ul">
<view>这是 uni-app 带登录模板的示例App首页。</view> <view>这是 uni-app 带登录模板的示例App首页。</view>
<view>在 “我的” 中点击 “退出” 可以 “注销当前账户”</view> <view>在 “我的” 中点击 “退出” 可以 “注销当前账户”</view>
</view> </view>
</view> </view>
<view v-if="!hasLogin" class="hello"> <view v-if="!token" class="hello">
<view class="title"> <view class="title">
您好 游客。 您好 游客。
</view> </view>
...@@ -32,13 +32,20 @@ ...@@ -32,13 +32,20 @@
getUserByToken getUserByToken
} from "@/api/login" } from "@/api/login"
export default { export default {
data() {
return {
token:'',
user:{}
}
},
onLoad: function() { onLoad: function() {
const token=uni.getStorageSync('token'); const token=uni.getStorageSync('token');
const user=uni.getStorageSync('user'); const user=uni.getStorageSync('user');
uni.setStorageSync('token',token);
console.log("token=",token); console.log("token=",token);
console.log("user=",user); console.log("user=",user);
this.token=token;
this.user=user;
if(!token){ if(!token){
// uni.switchTab({ // uni.switchTab({
// url:'/pages/login/login' // url:'/pages/login/login'
......
<template> <template>
<view> <view>
<view class="menu-bar"> <view class="menu-bar">
<block v-for="(tab,index) in StatusList" :key="tab.id"> <block v-for="(tab,index) in StatusList" :key="index">
<view :data-current="index" @click="ontabtap" class="tybe-tab" :class="statusIndex==index ? 'z-active' : ''">{{tab.name}}</view> <view :data-current="index" @click="ontabtap" class="tybe-tab" :class="statusIndex==index ? 'z-active' : ''">{{tab.name}}</view>
</block> </block>
<!-- <view class="tybe-tab">已审批</view> <!-- <view class="tybe-tab">已审批</view>
...@@ -28,7 +28,7 @@ ...@@ -28,7 +28,7 @@
</view> </view>
</view> --> </view> -->
<view class="list-area"> <view class="list-area">
<view v-for="item in applyProjectList" :key="item.id" class="m-his-list" style=""> <view v-for="(item,index) in applyProjectList" :key="index" class="m-his-list" style="">
<view class="his-item">申请人:{{item.name}}</view> <view class="his-item">申请人:{{item.name}}</view>
<view class="his-item mt10">伤残等级:一级</view> <view class="his-item mt10">伤残等级:一级</view>
<view class="his-item mt10">伤残类别{{}}</view> <view class="his-item mt10">伤残类别{{}}</view>
...@@ -49,6 +49,8 @@ ...@@ -49,6 +49,8 @@
export default { export default {
data() { data() {
return { return {
page:1,
size:5,
statusIndex:0, statusIndex:0,
StatusList:[ StatusList:[
{ {
...@@ -132,8 +134,9 @@ ...@@ -132,8 +134,9 @@
this.getApplyProject(this.statusIndex); this.getApplyProject(this.statusIndex);
} }
}, },
// 分页获取列表
getApplyProject(status){ getApplyProject(status){
getApplyProject({status:status}).then(res => { getApplyProject({status:status,page:this.page,size:this.size}).then(res => {
if (res.code == 200) { if (res.code == 200) {
// uni.showToast({ // uni.showToast({
// icon: 'success', // icon: 'success',
......
...@@ -33,7 +33,7 @@ ...@@ -33,7 +33,7 @@
<view class="center-list"> <view class="center-list">
<view class="center-list-item border-bottom" @click="commentHis"> <view class="center-list-item border-bottom" @click="commentHis">
<text class="list-icon">&#xe60b;</text> <text class="list-icon">&#xe60b;</text>
<text class="list-text">历史评价</text> <text class="list-text">反馈历史</text>
<text class="navigat-arrow">&#xe65e;</text> <text class="navigat-arrow">&#xe65e;</text>
</view> </view>
<view class="center-list-item" @click="aplHis"> <view class="center-list-item" @click="aplHis">
......
export default { export default {
baseURL:'http://192.168.7.122:9888/API-SERVER', //接口请求地址 baseURL:'http://192.168.7.122:9100', //接口请求地址
fileURL:'http://192.168.7.122:9100' //文件请求地址 fileURL:'http://192.168.7.122:9100' //文件请求地址
} }
\ No newline at end of file
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