yujialong 1 year ago
parent c75afe4844
commit 7aa59bf42d
  1. 4
      config/request.js
  2. 29
      order/editCourse/editCourse.vue
  3. 30
      pages/clientDetail/clientDetail.vue

@ -5,9 +5,9 @@
*/
export default {
// baseURL: 'https://huorantech.cn/',
baseURL: 'https://huorantech.cn/',
// baseURL: 'http://192.168.31.151:9000/',
baseURL: 'http://121.37.12.51/',
// baseURL: 'http://121.37.12.51/',
headers: {
'Content-Type': 'application/json;charset=UTF-8'
},

@ -20,7 +20,10 @@
</view>
<view :class="['line', {err: err === 'periodOfUse' + item.dataOrCourseId + item.authority}]">
<view class="name">使用期限</view>
<input class="period" type="number" v-model="item.periodOfUse" placeholder="请输入" :disabled="isEdit" @input="calcDate(item, !item.authority)" @change="handleErr(item, 'periodOfUse')">
<view class="period-wrap">
<input class="period" type="number" v-model="item.periodOfUse" placeholder="请输入" :disabled="isEdit" @input="calcDate(item, !item.authority)" @change="handleErr(item, 'periodOfUse')">
<uni-icons class="edit" type="compose" size="20" color="#b3b3b3"></uni-icons>
</view>
<view v-if="isEdit">{{ units.find(e => e.id === item.options).text }}</view>
<view v-else class="val unit" @click="selectUnit(item)">
<text>{{ units.find(e => e.id === item.options).text }}</text>
@ -30,11 +33,14 @@
<view :class="['line req', {err: err === 'startTime' + item.dataOrCourseId + item.authority}]">
<view class="name">起止日期</view>
<view v-if="isEdit">{{ item.endTime ? item.startTime + ' - ' + item.endTime : item.startTime}}</view>
<uni-datetime-picker v-else type="date" v-model="item.startTime" :border="false" @change="calcDate(item)">
<view :class="['ph', {val: item.startTime}]">
{{ item.endTime ? item.startTime + ' - ' + item.endTime : item.startTime}}
</view>
</uni-datetime-picker>
<view v-else class="val unit">
<uni-datetime-picker type="date" v-model="item.startTime" :border="false" @change="calcDate(item)">
<view :class="['ph', {val: item.startTime}]">
{{ item.endTime ? item.startTime + ' - ' + item.endTime : item.startTime}}
</view>
</uni-datetime-picker>
<image class="icon" src="@/static/image/arrow-down.png" mode="widthFix"></image>
</view>
</view>
<view :class="['line req', {err: err === 'accountNum' + item.dataOrCourseId + item.authority}]">
<view class="name">数量</view>
@ -50,6 +56,7 @@
<view class="inline">
<input type="number" v-model="item.settlementPrice" placeholder="请输入" @change="handleErr(item, 'settlementPrice')">
<uni-icons class="edit" type="compose" size="20" color="#b3b3b3"></uni-icons>
</view>
</view>
<view class="line">
@ -65,6 +72,7 @@
<view class="inline">
<input type="number" v-model="item.finalPrice" placeholder="请输入" :disabled="isEdit && !item.authority" @input="calcFinalValue(item)" @change="handleErr(item, 'finalPrice')">
<uni-icons class="edit" type="compose" size="20" color="#b3b3b3"></uni-icons>
</view>
</view>
</view>
@ -436,7 +444,13 @@
.form-list {
padding: 0 24rpx;
border-top: 0;
.period-wrap {
display: inline-flex;
align-items: center;
}
.period {
flex: none;
width: 100rpx;
text-align: center;
}
.unit {
@ -447,5 +461,8 @@
margin-left: 20rpx;
}
}
.edit {
margin-left: 10rpx;
}
}
</style>

@ -37,27 +37,42 @@
<view :class="['line req', {err: err === 'name'}]">
<view class="name">联系人姓名</view>
<view v-if="isDetail" class="val">{{ form.name }}</view>
<input v-else type="text" placeholder="请输入" v-model="form.name" @change="handleErr('name')">
<template v-else>
<input type="text" placeholder="请输入" v-model="form.name" @change="handleErr('name')">
<uni-icons class="edit" type="compose" size="20" color="#b3b3b3"></uni-icons>
</template>
</view>
<view :class="['line req', {err: err === 'phone'}]">
<view class="name">手机</view>
<view v-if="isDetail" class="val">{{ form.phone }}</view>
<input v-else type="number" maxlength="11" placeholder="请输入" v-model="form.phone" @change="handleErr('phone')">
<template v-else>
<input type="number" maxlength="11" placeholder="请输入" v-model="form.phone" @change="handleErr('phone')">
<uni-icons class="edit" type="compose" size="20" color="#b3b3b3"></uni-icons>
</template>
</view>
<view :class="['line req', {err: err === 'account'}]">
<view class="name">账号</view>
<view v-if="isDetail" class="val">{{ form.account }}</view>
<input v-else type="text" placeholder="请以院校首字母+admin的格式来设置" v-model="form.account" @change="handleErr('account')">
<template v-else>
<input type="text" placeholder="请以院校首字母+admin的格式来设置" v-model="form.account" @change="handleErr('account')">
<uni-icons class="edit" type="compose" size="20" color="#b3b3b3"></uni-icons>
</template>
</view>
<view class="line">
<view class="name">职务</view>
<view v-if="isDetail" class="val">{{ form.position }}</view>
<input v-else type="text" placeholder="请输入" v-model="form.position">
<template v-else>
<input type="text" placeholder="请输入" v-model="form.position">
<uni-icons class="edit" type="compose" size="20" color="#b3b3b3"></uni-icons>
</template>
</view>
<view class="line">
<view class="name">邮箱</view>
<view v-if="isDetail" class="val">{{ form.email }}</view>
<input v-else type="text" placeholder="请输入" v-model="form.email">
<template v-else>
<input type="text" placeholder="请输入" v-model="form.email">
<uni-icons class="edit" type="compose" size="20" color="#b3b3b3"></uni-icons>
</template>
</view>
<view v-if="customerId" class="line">
<view class="name">产品到期时间</view>
@ -355,6 +370,11 @@
margin-right: 10rpx;
}
}
.form-list {
.edit {
margin-left: 10rpx;
}
}
.editIcon {
width: 50rpx;
height: 50rpx;

Loading…
Cancel
Save