Browse Source

修改销售员、挂单页优化

master
tianyi@bogon 3 years ago
parent
commit
a8f6a9cc80
  1. 514
      pages/index/addHangOrder.vue
  2. 2
      pages/index/index.vue
  3. 2
      pages/index/order.vue
  4. 34
      pages/inventory/addinventory.vue
  5. 14
      pages/inventory/goodsList1.vue
  6. 2
      pages/inventory/inventory.vue
  7. 2
      pages/login/login.vue

514
pages/index/addHangOrder.vue

@ -1,3 +1,4 @@
<!-- 新增挂单 -->
<template>
<view class="">
<view>
@ -8,21 +9,41 @@
<ul>
<!-- <li v-for="(item, index) in indexList" :key="index" @tap="clickCollapse"> -->
<li @tap="clickCollapse">
<view class="name">{{item.categoryName}}</view>
<view class="name">张三的订单</view>
<view class="bj-btn" @tap.stop="inputDialogToggle('edit', item)">编辑</view>
<view class="bj-btn" @tap.stop="scanCodeAdd">新增</view>
<view class="bj-btn" @tap="toggle('center')">语音备注</view>
<uni-icons type="bottom" size="25"></uni-icons>
<!-- <view class="name">{{item.categoryName}}</view> -->
<view class="name">
<view>张三的订单</view>
<view class="name-date">
<text>销售员</text>
<text>2023-10-10 12:01:23</text>
</view>
</view>
<view class="btn-list">
<view class="bj-btn" @tap.stop="inputDialogToggle('edit', item)">编辑</view>
<view class="bj-btn" @tap.stop="scanCodeAdd">扫码开单</view>
<view class="bj-btn" @tap="toggle('center')">语音备注</view>
</view>
<uni-icons type="bottom" size="25" style="position: absolute;bottom:0;right:0;"></uni-icons>
</li>
</ul>
</view>
<view class="order-collapse-item" v-if="isCollapse">
<view class="collapse-1">
<view class="order-notes">
备注:
<view class="order-notes">
备注:张三13895968700北京丰台总部基地给张三9折折扣张三13895968700北京丰台总部基地给张三9折折扣张三13895968700北京丰台总部基地给张三9折折扣
</view>
</view>
<view class="shop-list">
<view>
女士连衣裙(HD738206579)
<img src="/static/images/datu.png" @tap="" alt="">
</view>
<view>颜色:黑色,尺码:s码 * 2</view>
<view>颜色:黑色,尺码:s码 * 2</view>
<view><uni-icons color="red" type="minus" size="26"></uni-icons></view>
</view>
<view class="save-btn">保存</view>
</view>
</view>
<!-- 语音识别弹出层 -->
<view>
@ -31,7 +52,7 @@
<view class="popup-title">
<text>语音录入</text>
<uni-icons @tap='close' type="closeempty" color='red' size="16"
style="height:40rpx;line-height: 40rpx;position: absolute;right: 0;"></uni-icons>
style="height:40rpx;line-height: 40rpx;position: absolute !important;bottom:0;right: 30rpx;"></uni-icons>
</view>
<view class="popup-container">
<textarea name="" id="" style="width:100%;border:1px solid #eee;" v-model="voiceText"
@ -50,62 +71,69 @@
<view class="voice-model" v-if="recordState == true">
<img src="/static/images/maikefeng.png" alt="">
<view class="voice-text">语音识别中...</view>
</view>
<!-- 商品弹出层 -->
<view>
<uni-popup ref="shopPopup" background-color="#fff" @change="change">
<view class="shop-popup-content">
<view class="shop-popup-title">
<view class="shop-popup-title-left">
<img src="/static/images/logo.png" alt="">
</view>
<view class="shop-popup-title-right">
<view class="shop-popup-title-right-box" style="color: #088FEB;">创意小众单肩包</view>
<view class="shop-popup-title-right-box">QS2023101001</view>
<view class="shop-popup-title-right-box" style="color: darkorange;" @tap="inputDialogToggle">
<text style="margin-right:20rpx;">¥0.00</text>
<text style="color: 088FEB;">临时改价</text>
</view>
</view>
</view>
<view class="shop-popup-container">
<ul>
<!-- <li v-for="items in attrList" :key="items.id"> -->
<li>
<view class="shop-title-fur">
<view class="shop-name">男装</view>
</view>
<view class="shop-content-fur">
<!-- <view class="content-low" v-for="item in items.attributeValue" :key="item.id" @tap="delItem(item, 'attrNameDel')">男装</view> -->
<view class="shop-content-low">男装</view>
</view>
</li>
</ul>
<view class="shop-checkList">
<view class="shop-checkList-box">
<text>女装</text>
<text>S码</text>
<text>黄色</text>
</view>
<uni-number-box :value="numberValue" @change="change" />
</view>
</view>
<view class="shop-popup-bottom">
<view class="shop-popup-bottom-left">
<text>2 款 9 件</text>
<text>¥2952.00</text>
</view>
<view class="shop-popup-bottom-right">
<view class="bottom-btn" @tap="">选好了</view>
</view>
</view>
</view>
</uni-popup>
</view>
<!-- 弹出输入框 -->
<uni-popup ref="inputDialog" type="dialog">
<uni-popup-dialog ref="inputClose" mode="input" title="临时改价" placeholder="请输入临时售价"
@confirm="dialogInputConfirm"></uni-popup-dialog>
</view>
<!-- 商品弹出层 -->
<view>
<uni-popup ref="shopPopup" background-color="#fff" @change="change">
<view class="shop-popup-content">
<view class="shop-popup-title">
<view class="shop-popup-title-left">
<img src="/static/images/logo.png" alt="">
</view>
<view class="shop-popup-title-right">
<view class="shop-popup-title-right-box" style="color: #088FEB;">创意小众单肩包</view>
<view class="shop-popup-title-right-box">QS2023101001</view>
<view class="shop-popup-title-right-box" style="color: darkorange;"
@tap="inputDialogToggle">
<text style="margin-right:20rpx;">¥0.00</text>
<text style="color: 088FEB;">临时改价</text>
</view>
</view>
</view>
<view class="shop-popup-container">
<ul>
<!-- <li v-for="items in attrList" :key="items.id"> -->
<li>
<view class="shop-title-fur">
<view class="shop-name">男装</view>
</view>
<view class="shop-content-fur">
<!-- <view class="content-low" v-for="item in items.attributeValue" :key="item.id" @tap="delItem(item, 'attrNameDel')">男装</view> -->
<view class="shop-content-low">男装</view>
</view>
</li>
</ul>
<view class="shop-checkList">
<view class="shop-checkList-box">
<text>女装</text>
<text>S码</text>
<text>黄色</text>
</view>
<uni-number-box :value="numberValue" @change="change" />
</view>
</view>
<view class="shop-popup-bottom">
<view class="shop-popup-bottom-left">
<text>2 款 9 件</text>
<text>¥2952.00</text>
</view>
<view class="shop-popup-bottom-right">
<view class="bottom-btn" @tap="">选好了</view>
</view>
</view>
</view>
</uni-popup>
</view>
<!-- 弹出输入框 -->
<uni-popup ref="inputDialog" type="dialog">
<uni-popup-dialog ref="inputClose" mode="input" title="临时改价" placeholder="请输入临时售价"
@confirm="dialogInputConfirm"></uni-popup-dialog>
</uni-popup>
<!-- 查看大图弹出层 -->
<uni-popup ref="imgPopup" background-color="#fff" @change="change">
<view class="img-popup-content">
<img src="/static/images/logo.png" alt="">
</view>
</uni-popup>
</view>
</template>
@ -187,10 +215,10 @@
//扫一扫功能
scanCodeAdd() {
uni.scanCode({
success: (res) => {
console.log(typeof(res.result))
this.toggle('bottom',res.result);
success: (res) => {
console.log(typeof(res.result))
this.toggle('bottom', res.result);
},
fail: (res) => {
uni.showToast({
@ -199,32 +227,32 @@
})
}
})
},
//弹出商品规格选择
toggle(type,id) {
this.type = type
if(type == 'bottom'){
this.$refs.shopPopup.open(type)
this.getById(id);
}else{
this.$refs.popup.open(type)
}
},
//临时改价弹窗
inputDialogToggle() {
this.$refs.inputDialog.open()
},
//通过商品id查询商品详细信息
getById(id){
this.tui.request("/app/product/getById", "POST", {
id:id
}, false, false).then((res) => {
if (res.code == 200) {
} else {
this.tui.toast(res.message)
}
}).catch((res) => {})
},
//弹出商品规格选择
toggle(type, id) {
this.type = type
if (type == 'bottom') {
this.$refs.shopPopup.open(type)
this.getById(id);
} else {
this.$refs.popup.open(type)
}
},
//临时改价弹窗
inputDialogToggle() {
this.$refs.inputDialog.open()
},
//通过商品id查询商品详细信息
getById(id) {
this.tui.request("/app/product/getById", "POST", {
id: id
}, false, false).then((res) => {
if (res.code == 200) {
} else {
this.tui.toast(res.message)
}
}).catch((res) => {})
}
}
}
@ -251,11 +279,12 @@
.order-list li {
width: 95%;
height: 100rpx;
line-height: 100rpx;
height: 160rpx;
line-height: 80rpx;
font-size: 37rpx;
border-bottom: 0.5px solid #eee;
margin: 0 auto;
position: relative;
}
.name {
@ -263,25 +292,50 @@
float: left;
}
.name-date {
font-size: 28rpx;
}
.bj-btn {
width: auto;
/* height: 60rpx; */
font-size: 26rpx;
background: #fff;
margin: 0;
margin-top: 20rpx;
float: left;
padding-right: 20rpx;
line-height: 60rpx;
padding-right: 36rpx;
color: blue;
text-decoration: underline;
}
.save-btn{
width: 95%;
height: 80rpx;
text-align: center;
line-height: 80rpx;
margin: 0 auto;
background: #088FEB;
color: #fff;
}
.order-collapse-item {
display: flex;
text-align: center;
background: #eee;
height: 110rpx;
height: auto;
width: 95%;
border-radius: 20rpx;
margin: 0 auto;
padding: 20rpx;
}
.order-notes {
height: 100rpx;
line-height: 50rpx;
text-overflow: ellipsis;
overflow: hidden;
white-space: pre-wrap;
text-overflow: -o-ellipsis-lastline;
display: -webkit-box; //特别显示模式
-webkit-line-clamp: 2; //行数
line-clamp: 2;
-webkit-box-orient: vertical; //盒子中内容竖直排列
}
.popup-content {
@ -342,127 +396,133 @@
width: 200rpx;
height: 200rpx;
margin: 0 auto;
}
.shop-popup-content {
align-items: center;
justify-content: center;
padding: 15px;
height: 1200rpx;
background-color: #fff;
}
.shop-popup-title-right-box {
height: 50rpx;
line-height: 50rpx;
}
.shop-popup-title-right {
width: 400rpx;
margin-left: 30rpx;
}
.shop-popup-title-left {
width: 150rpx;
height: 150rpx;
}
.shop-popup-title-left image {
width: 150rpx;
height: 150rpx;
}
.shop-popup-title {
display: flex;
height: 180rpx;
border-bottom: 1px solid #eee;
}
.shop-popup-container {
width: 95%;
border-radius: 10upx;
background: #fff;
height: auto;
margin: 20upx auto;
}
.shop-title-fur {
width: 95%;
height: 70rpx;
margin: 0 auto;
}
.shop-name {
font-size: 30rpx;
width: 50%;
float: left;
height: 70rpx;
line-height: 70rpx;
}
.shop-content-fur {
padding-bottom: 25rpx;
}
.shop-content-low {
width: auto;
border: 1px solid #eee;
display: inline-block;
min-width: 90rpx;
padding: 5rpx;
font-size: 35rpx;
text-align: center;
color: #777;
margin: 20rpx 0 0 20rpx;
}
.shop-content-low:hover {
background: #eee;
}
.shop-checkList {
display: flex;
height: 50rpx;
font-size: 28rpx;
line-height: 50rpx;
padding: 20rpx 10rpx;
border-top: 1px solid #eee;
}
.shop-checkList-box {
height: 50rpx;
width: 60%;
}
.shop-popup-bottom {
width: 100%;
height: 100rpx;
position: fixed;
bottom: 0;
display: flex;
}
.shop-popup-bottom-left {
width: 50%;
line-height: 80rpx;
}
.shop-popup-bottom-right {
width: 50%;
line-height: 100rpx;
.bottom-btn {
width: 70%;
line-height: 35px;
height: 70rpx;
text-align: center;
/* margin-top: 10rpx; */
color: #fff;
font-size: 28rpx;
margin: 0 auto;
background: linear-gradient(90deg, #60F3FF, #088FEB);
border-radius: 70rpx;
}
}
.btn-list {
width: 47%;
float: left;
}
.shop-popup-content {
align-items: center;
justify-content: center;
padding: 15px;
height: 1200rpx;
background-color: #fff;
}
.shop-popup-title-right-box {
height: 50rpx;
line-height: 50rpx;
}
.shop-popup-title-right {
width: 400rpx;
margin-left: 30rpx;
}
.shop-popup-title-left {
width: 150rpx;
height: 150rpx;
}
.shop-popup-title-left image {
width: 150rpx;
height: 150rpx;
}
.shop-popup-title {
display: flex;
height: 180rpx;
border-bottom: 1px solid #eee;
}
.shop-popup-container {
width: 95%;
border-radius: 10upx;
background: #fff;
height: auto;
margin: 20upx auto;
}
.shop-title-fur {
width: 95%;
height: 70rpx;
margin: 0 auto;
}
.shop-name {
font-size: 30rpx;
width: 50%;
float: left;
height: 70rpx;
line-height: 70rpx;
}
.shop-content-fur {
padding-bottom: 25rpx;
}
.shop-content-low {
width: auto;
border: 1px solid #eee;
display: inline-block;
min-width: 90rpx;
padding: 5rpx;
font-size: 35rpx;
text-align: center;
color: #777;
margin: 20rpx 0 0 20rpx;
}
.shop-content-low:hover {
background: #eee;
}
.shop-checkList {
display: flex;
height: 50rpx;
font-size: 28rpx;
line-height: 50rpx;
padding: 20rpx 10rpx;
border-top: 1px solid #eee;
}
.shop-checkList-box {
height: 50rpx;
width: 60%;
}
.shop-popup-bottom {
width: 100%;
height: 100rpx;
position: fixed;
bottom: 0;
display: flex;
}
.shop-popup-bottom-left {
width: 50%;
line-height: 80rpx;
}
.shop-popup-bottom-right {
width: 50%;
line-height: 100rpx;
.bottom-btn {
width: 70%;
line-height: 35px;
height: 70rpx;
text-align: center;
/* margin-top: 10rpx; */
color: #fff;
font-size: 28rpx;
margin: 0 auto;
background: linear-gradient(90deg, #60F3FF, #088FEB);
border-radius: 70rpx;
}
}
</style>

2
pages/index/index.vue

@ -86,7 +86,7 @@
<li v-for="item in inventoryList" :key="item.id">
<uni-card :title="item.id" :sub-title="'¥'+item.totalAmount" :thumbnail="item.img"
@tap="gotoDetail(item.id)">
<view class="uni-body">{{ item.createBy }} - {{ item.createTime }}</view>
<view class="uni-body">{{ item.createByName }} - {{ item.createTime }}</view>
</uni-card>
</li>
</ul>

2
pages/index/order.vue

@ -9,7 +9,7 @@
<li v-for="item in inventoryList" @tap="gotoDetail(item.id)">
<uni-card :title="item.id" :sub-title="item.createTime" :extra="'¥'+item.totalAmount"
thumbnail="/static/images/logo.png">
<view class="uni-body"><text class="cardText">销售员:</text> {{item.createBy}}</view>
<view class="uni-body"><text class="cardText">销售员:</text> {{item.createByName}}</view>
<view class="uni-body"> <text class="cardText"> 营业额:</text> <text class="priceText">
{{item.realAmount}} </text> <text decode class="cardText">
{{'&nbsp;&nbsp;&nbsp;&nbsp; 欠款: '}} </text> <text class="priceText">{{item.noEarn}}

34
pages/inventory/addinventory.vue

@ -1,26 +1,5 @@
<template>
<!-- <view>
<view class="formBox">
<uni-forms ref="form" :modelValue="formData" labelWidth="85px">
<uni-forms-item label="店铺名称" name="name">
<uni-easyinput type="text" v-model="shopName" disabled />
</uni-forms-item>
</uni-forms>
<uni-card title="选择商品">
<u-grid :col="2" border>
<u-grid-item index="add" @tap.stop="scanCodeAdd">
<u-icon name="scan" size="36"></u-icon>
</u-grid-item>
<u-grid-item @tap.stop="goodsAdd">
<u-icon name="plus" size="28"></u-icon>
</u-grid-item>
</u-grid>
</uni-card>
</view>
<view class="tui-tabbar">
<u-button type="primary" :plain="true" shape="circle" @tap.stop="submit(ret)">保存</u-button>
</view>
</view> -->
<!-- 新增库存页 -->
<template>
<view class="page1">
<view class="content">
<view class="content-box">
@ -32,11 +11,6 @@
<uni-icons type="right" size="16" style="margin-left: 80rpx;line-height: 80rpx;"></uni-icons>
</view>
</view>
<!-- <view class="content-list">
<view class="list-name">销售员</view>
<uni-data-select class="uni-data-select" :localdata="categoryList" v-model="value"
placeholder="请选择销售员" @change="categoryChange"></uni-data-select>
</view> -->
</view>
<view class="content-box">
<view class="shop-box" style="border-bottom: 1px solid #eee;margin-bottom: 20rpx;">
@ -71,10 +45,6 @@
</view>
</view>
<view class="content-box">
<!-- <view class="price-box-title">
<text>商品数量:5 </text>
<text style="text-align: left;padding-left: 40rpx;color: red;">金额:500.00</text>
</view> -->
<!-- 账号权限是否可以维护成本价格(主账号和被授权的账号可以维护),参数名:shop_admin_cost,维护在用户表中,存在前后端缓存里,把备注栏挪出来,谁都可以备注 -->
<view class="price-box-list">
<view class="content-list">

14
pages/inventory/goodsList1.vue

@ -1,3 +1,4 @@
<!-- 销售商品 -->
<template>
<view class="page1">
<view class="content">
@ -285,9 +286,13 @@
})
},
//切换销售员
categoryChange(e) {
this.xsyId = e
console.log(e)
categoryChange(e) {
for (i=0;i<this.categoryList.length;i++) {
if(this.categoryList[i].value== e){
this.xsyId = e;
this.createByName = this.categoryList[i].text
}
}
},
//点击切换折叠状态
clickCollapse() {
@ -346,7 +351,8 @@
totalAmount: 100, //应付金额
transportType: 0, //this.radioType
discount: 10,
createBy: this.xsyId,
createBy: this.xsyId,
createByName:this.createByName,
userId: "1704126992443641856",
remark: '123'
},

2
pages/inventory/inventory.vue

@ -1,3 +1,4 @@
<!-- 库存列表页 -->
<template>
<view style="display: flex;flex-direction: column;height: 1280rpx;">
<view class="" style="display: flex;border-top: 1px solid #eee;border-bottom: 1px solid #eee;">
@ -36,7 +37,6 @@
</view>
</view>
<view class="search">
<!-- <u-search placeholder="输入商品名称/编号查询" v-model="keyword"></u-search> -->
<uni-search-bar class="uni-mt-10" radius="5" placeholder="商品名称/编号" cancelButton="none" @confirm="search" />
<view class="title-right-bottom title-btn"
style="width:22%;float: left;height:75rpx;line-height: 75rpx;margin-top:20rpx;"

2
pages/login/login.vue

@ -202,7 +202,7 @@
this.choose = true
this.setTime()
this.tui.request("/common/captcha/sendLoginSms/" + this.phone, "GET", {
type:this.wayValue
}).then((res) => {
if (res.code == 200) {
uni.showToast({

Loading…
Cancel
Save