wangfukang 3 years ago
parent
commit
9ddd17d9c7
  1. BIN
      pages/.DS_Store
  2. BIN
      pages/billing/.DS_Store
  3. 241
      pages/billing/changeGoods1.vue
  4. 20
      pages/index/addHangOrder.vue
  5. 23
      pages/index/downStearmList.vue
  6. 13
      pages/index/shareStyle.vue
  7. 3
      pages/index/waitStorageDetail.vue
  8. 9
      pages/inventory/addGoods.vue
  9. 2
      pages/inventory/addinventory.vue
  10. 28
      pages/inventory/changeGoods1.vue
  11. 4
      pages/inventory/gategory.vue
  12. 1
      pages/inventory/gategoryLow.vue
  13. 66
      pages/inventory/goodsList1.vue
  14. 7
      pages/inventory/inventory.vue
  15. 3
      pages/inventory/inventoryDetail.vue
  16. 14
      pages/login/login.vue
  17. 4
      pages/login/register.vue
  18. 2
      pages/other/custom.vue
  19. 246
      pages/other/logistics.vue
  20. 18
      pages/other/logisticsDetail.vue
  21. 1
      pages/rebate/detail.vue
  22. 3
      pages/rebate/rebate.vue
  23. 2
      pages/rebate/withdrawal.vue
  24. 7
      pages/staff/addStaff/addStaff.vue
  25. 5
      pages/staff/clock/clock.vue
  26. 5
      pages/staff/signRule/signRule.vue

BIN
pages/.DS_Store

Binary file not shown.

BIN
pages/billing/.DS_Store

Binary file not shown.

241
pages/billing/changeGoods1.vue

@ -63,8 +63,7 @@
<view class="popup-content"> <view class="popup-content">
<view class="popup-title"> <view class="popup-title">
<view class="popup-title-left"> <view class="popup-title-left">
<img :src="goodsDetail.productPicture" <img :src="goodsDetail.productPicture" alt="">
alt="">
</view> </view>
<view class="popup-title-right"> <view class="popup-title-right">
<view class="popup-title-right-box" style="color: #088FEB;">{{goodsDetail.productName}} <view class="popup-title-right-box" style="color: #088FEB;">{{goodsDetail.productName}}
@ -87,11 +86,13 @@
</view> </view>
</li> </li>
</ul> </ul>
<view class="checkList" v-for="(item,index) in temporaryList" :key="index"> <view>
<view class="checkList-box"> <view class="checkList" v-for="(item,index) in temporaryList" :key="index">
{{item.name}} <view class="checkList-box">
{{item.name}}
</view>
<uni-number-box max="100000" v-model="item.productCount" @change="temporaryChange" />
</view> </view>
<uni-number-box max="100000" v-model="item.productCount" @change="temporaryChange" />
</view> </view>
</view> </view>
<view class="popup-bottom" v-for="(item,index) in temporaryList" :key="index"> <view class="popup-bottom" v-for="(item,index) in temporaryList" :key="index">
@ -112,8 +113,7 @@
<view v-for="(item,index) in carList" :key="index" style="position: relative;"> <view v-for="(item,index) in carList" :key="index" style="position: relative;">
<view class="popup-title"> <view class="popup-title">
<view class="popup-title-left"> <view class="popup-title-left">
<img :src="item.productPicture" <img :src="item.productPicture" alt="">
alt="">
</view> </view>
<view class="popup-title-right"> <view class="popup-title-right">
<view class="popup-title-right-box" style="color: #088FEB;">{{item.productName}}</view> <view class="popup-title-right-box" style="color: #088FEB;">{{item.productName}}</view>
@ -135,7 +135,8 @@
<view class="checkList-box"> <view class="checkList-box">
{{item1.attributeList | sliceMsg}} {{item1.attributeList | sliceMsg}}
</view> </view>
<uni-number-box max="100000" v-model="item1.productCount" @change="carChange($event,index,index1)" /> <uni-number-box max="100000" v-model="item1.productCount"
@change="carChange($event,index,index1)" />
</view> </view>
</view> </view>
</view> </view>
@ -184,25 +185,25 @@
carType: 0, carType: 0,
type: '' type: ''
} }
}, },
filters: { filters: {
sliceMsg(val) { sliceMsg(val) {
var name = '' var name = ''
if (typeof(val) == 'string') { if (typeof(val) == 'string') {
let newObj = JSON.parse(val) let newObj = JSON.parse(val)
for (let as in newObj) { for (let as in newObj) {
name += newObj[as] + '/' name += newObj[as] + '/'
} }
} }
return name; return name;
}, },
maxNum(val) { maxNum(val) {
if (val >= 10) { if (val >= 10) {
return 10 return 10
} else if (val < 0) { } else if (val < 0) {
return 0 return 0
} }
} }
}, },
onLoad() { onLoad() {
this.getGategoryList() this.getGategoryList()
@ -272,15 +273,14 @@
if (this.temporaryList.length == 0) { if (this.temporaryList.length == 0) {
this.temporaryList.push(this.attributeList); this.temporaryList.push(this.attributeList);
} else { } else {
for (var i = 0; i < this.temporaryList.length; i++) { for (var i = 0; i < this.temporaryList.length; i++) {
console.log(this.temporaryList[i].name.indexOf(this.attributeList.name))
if (this.temporaryList[i].name.indexOf(this.attributeList.name) != -1) { if (this.temporaryList[i].name.indexOf(this.attributeList.name) != -1) {
return return
}else{ } else {
if (this.temporaryList.length == (i + 1)) { if (this.temporaryList.length == (i + 1)) {
this.temporaryList.push(this.attributeList); this.temporaryList.push(this.attributeList);
return return
} }
} }
} }
@ -315,36 +315,31 @@
pageSize: '10' pageSize: '10'
}, false, false).then((res) => { }, false, false).then((res) => {
if (res.code == 200) { if (res.code == 200) {
this.shopList = res.result.records this.shopList = res.result.records
} else { } else {
this.tui.toast(res.message) this.tui.toast(res.message)
} }
}).catch((res) => {}) }).catch((res) => {})
}, },
change(){ change() {
}, },
// //
carChange(e,index,index1) { carChange(e, index, index1) {
console.log(this.carList) this.carNum = 0
this.carNum = 0 for (let i = 0; i < this.carList.length; i++) {
for (let i = 0; i < this.carList.length; i++) { this.carList[i].num = 0
this.carList[i].num = 0 for (let m = 0; m < this.carList[i].saleDetailQueryDTO.length; m++) {
for (let m = 0; m < this.carList[i].saleDetailQueryDTO.length; m++) { this.carList[i].num += this.carList[i].saleDetailQueryDTO[m].productCount
this.carList[i].num += this.carList[i].saleDetailQueryDTO[m].productCount }
} this.carNum += this.carList[i].num
this.carNum += this.carList[i].num
} }
}, },
//弹出购物车或者商品规格选择弹窗 //弹出购物车或者商品规格选择弹窗
toggle(type, item) { toggle(type, item) {
// open 方法传入参数 等同在 uni-popup 组件上绑定 type属性
if (type == 'carPopup') { if (type == 'carPopup') {
this.oldList = this.carList
this.oldList = this.carList
console.log(this.carList)
// this.newFun()
this.carNum = 0 this.carNum = 0
for (let i = 0; i < this.carList.length; i++) { for (let i = 0; i < this.carList.length; i++) {
this.carNum += this.carList[i].num this.carNum += this.carList[i].num
@ -359,21 +354,19 @@
}, },
//选择商品查询商品规格 //选择商品查询商品规格
checkGoods(item) { checkGoods(item) {
this.goodsDetail = item; this.goodsDetail = item;
this.temporaryList = [] this.temporaryList = []
this.columns = [] this.columns = []
this.keyList = [] this.keyList = []
console.log(this.temporaryList) if (this.carList != '') {
console.log(this.carList) this.zNum = 0
if(this.carList != ''){ for (let i = 0; i < this.carList.length; i++) {
this.zNum = 0
for(let i=0;i<this.carList.length;i++){ if (item.id == this.carList[i].id) {
this.zNum = this.carList[i].num
if(item.id == this.carList[i].id){ this.temporaryList = this.carList[i].saleDetailQueryDTO
this.zNum = this.carList[i].num }
this.temporaryList = this.carList[i].saleDetailQueryDTO }
}
}
} }
this.tui.request("/app/productAttribute/selectAttributeAndValueByCategoryId", "POST", { this.tui.request("/app/productAttribute/selectAttributeAndValueByCategoryId", "POST", {
categoryId: this.goodsDetail.categoryId categoryId: this.goodsDetail.categoryId
@ -453,30 +446,30 @@
saleDetailQueryDTO1: [], saleDetailQueryDTO1: [],
wholesalePrice: this.goodsDetail.wholesalePrice, wholesalePrice: this.goodsDetail.wholesalePrice,
lsprice: this.goodsDetail.price lsprice: this.goodsDetail.price
}
if(this.carList.length == 0){
this.carList.push(data)
}else{
let aa = true;
for(let i = 0; i < this.carList.length; i++){
if(this.carList[i].id == data.id){
this.carList[i] = data
aa = false
}
}
if(aa){
this.carList.push(data)
}
} }
if (this.carList.length == 0) {
this.carList.push(data)
} else {
let aa = true;
for (let i = 0; i < this.carList.length; i++) {
if (this.carList[i].id == data.id) {
this.carList[i] = data
aa = false
}
}
if (aa) {
this.carList.push(data)
}
}
for (let i = 0; i < this.carList.length; i++) { for (let i = 0; i < this.carList.length; i++) {
this.carList[i].num = 0 this.carList[i].num = 0
for (let m = 0; m < this.carList[i].saleDetailQueryDTO.length; m++) { for (let m = 0; m < this.carList[i].saleDetailQueryDTO.length; m++) {
this.carList[i].num += this.carList[i].saleDetailQueryDTO[m].productCount this.carList[i].num += this.carList[i].saleDetailQueryDTO[m].productCount
} }
} }
this.temporaryList = [] this.temporaryList = []
this.purchasePrice = '' this.purchasePrice = ''
this.zPrice = '' this.zPrice = ''
@ -496,48 +489,49 @@
uni.showModal({ uni.showModal({
title: "提示", title: "提示",
content: "确定删除此条商品吗?", content: "确定删除此条商品吗?",
success: function(res) { success: function(res) {
if (res.confirm) { if (res.confirm) {
for(let i=0;i<that.carList.length;i++){ for (let i = 0; i < that.carList.length; i++) {
if(that.carList[i].id == item.id){ if (that.carList[i].id == item.id) {
that.carNum -= that.carList[i].num that.carNum -= that.carList[i].num
that.carList.splice(i, 1) that.carList.splice(i, 1)
} }
} }
that.carType = that.carList.length that.carType = that.carList.length
} }
that.$forceUpdate() that.$forceUpdate()
} }
}) })
}, },
//删除商品下的某一个规格 //删除商品下的某一个规格
delShopSpec(index,index1) { delShopSpec(index, index1) {
var that = this; var that = this;
uni.showModal({ uni.showModal({
title: "提示", title: "提示",
content: "确定删除此条商品吗?", content: "确定删除此条商品吗?",
success: function(res) { success: function(res) {
if (res.confirm) { if (res.confirm) {
for(let i=0;i<that.carList.length;i++){ for (let i = 0; i < that.carList.length; i++) {
for(let m=0;m<that.carList[i].saleDetailQueryDTO.length;m++){ for (let m = 0; m < that.carList[i].saleDetailQueryDTO.length; m++) {
if(that.carList[i].id == index){ if (that.carList[i].id == index) {
if(that.carList[i].saleDetailQueryDTO[m].attributeList == index1){ if (that.carList[i].saleDetailQueryDTO[m].attributeList == index1) {
that.carList[i].num -= that.carList[i].saleDetailQueryDTO[m].productCount that.carList[i].num -= that.carList[i].saleDetailQueryDTO[m]
that.carNum -= that.carList[i].saleDetailQueryDTO[m].productCount .productCount
that.carList[i].saleDetailQueryDTO.splice(m, 1) that.carNum -= that.carList[i].saleDetailQueryDTO[m].productCount
continue; that.carList[i].saleDetailQueryDTO.splice(m, 1)
} continue;
} }
}
}
if(that.carList[i].saleDetailQueryDTO.length == 0){ }
that.carList.splice(i, 1) if (that.carList[i].saleDetailQueryDTO.length == 0) {
} that.carList.splice(i, 1)
} }
that.carType = that.carList.length }
} that.carType = that.carList.length
that.$forceUpdate() }
} that.$forceUpdate()
}
}) })
}, },
//选择是零售价还是批发价 //选择是零售价还是批发价
@ -576,6 +570,8 @@
padding: 15px; padding: 15px;
height: 1200rpx; height: 1200rpx;
background-color: #fff; background-color: #fff;
margin-bottom: 30rpx;
overflow: scroll;
} }
.popup-pay-content { .popup-pay-content {
@ -728,7 +724,6 @@
} }
.content-right { .content-right {
// width: 550rpx;
flex: 1; flex: 1;
overflow-y: scroll; overflow-y: scroll;
} }

20
pages/index/addHangOrder.vue

@ -618,7 +618,6 @@
}, },
//带参数跳转到开单页 //带参数跳转到开单页
goSaleGoods(item) { goSaleGoods(item) {
console.log(item)
if(item){ if(item){
let dataList = [] let dataList = []
for (let i = 0; i < item.saleDetailDTOList.length; i++) { for (let i = 0; i < item.saleDetailDTOList.length; i++) {
@ -640,7 +639,6 @@
obj.createByName = item.createByName obj.createByName = item.createByName
dataList.push(obj) dataList.push(obj)
} }
console.log(dataList)
uni.setStorageSync('carList1', JSON.stringify(dataList)) uni.setStorageSync('carList1', JSON.stringify(dataList))
uni.setStorageSync('khName', '') uni.setStorageSync('khName', '')
} }
@ -848,16 +846,14 @@
white-space: nowrap; white-space: nowrap;
} }
.btn-list { .shop-popup-content {
// flex: 1; align-items: center;
} justify-content: center;
padding: 15px;
.shop-popup-content { height: 1200rpx;
align-items: center; background-color: #fff;
justify-content: center; margin-bottom: 30rpx;
padding: 15px; overflow: scroll;
height: 1200rpx;
background-color: #fff;
} }
.shop-popup-title { .shop-popup-title {

23
pages/index/downStearmList.vue

@ -6,7 +6,7 @@
</view> </view>
<view class="content-box"> <view class="content-box">
<view class="content-right"> <view class="content-right">
<view class="right-box" v-for="item in shopList" :key="item" @tap="toggle('bottom',item)"> <view class="right-box" v-for="(item,index) in shopList" :key="index" @tap="toggle('bottom',item)">
<view class="box-left"> <view class="box-left">
<img :src="item.productPicture" alt=""> <img :src="item.productPicture" alt="">
</view> </view>
@ -101,7 +101,6 @@
</view> </view>
<!-- 弹出输入框 --> <!-- 弹出输入框 -->
<uni-popup ref="inputDialog" background-color="#fff"> <uni-popup ref="inputDialog" background-color="#fff">
<!-- 省市区选择 show:是否显示 @sureSelectArea:确认事件 @hideShow:隐藏事件-->
<cc-selectDity :show="show" @sureSelectArea="onsetCity" @hideShow="onhideShow"></cc-selectDity> <cc-selectDity :show="show" @sureSelectArea="onsetCity" @hideShow="onhideShow"></cc-selectDity>
<view class="popup-pay-content"> <view class="popup-pay-content">
<view class="popup-pay-title"> <view class="popup-pay-title">
@ -298,14 +297,11 @@
this.temporaryList.push(this.attributeList); this.temporaryList.push(this.attributeList);
} else { } else {
for (var i = 0; i < this.temporaryList.length; i++) { for (var i = 0; i < this.temporaryList.length; i++) {
console.log(this.temporaryList[i].name.indexOf(this.attributeList.name))
if (this.temporaryList[i].name.indexOf(this.attributeList.name) != -1) { if (this.temporaryList[i].name.indexOf(this.attributeList.name) != -1) {
console.log(this.temporaryList)
return return
}else{ }else{
if (this.temporaryList.length == (i + 1)) { if (this.temporaryList.length == (i + 1)) {
this.temporaryList.push(this.attributeList); this.temporaryList.push(this.attributeList);
console.log(this.temporaryList)
return return
} }
} }
@ -354,8 +350,6 @@
this.temporaryList = [] this.temporaryList = []
this.columns = [] this.columns = []
this.keyList = [] this.keyList = []
console.log(this.temporaryList)
console.log(this.carList)
if(this.carList != ''){ if(this.carList != ''){
this.zNum = 0 this.zNum = 0
for(let i=0;i<this.carList.length;i++){ for(let i=0;i<this.carList.length;i++){
@ -407,7 +401,6 @@
this.$refs.inputDialog.open() this.$refs.inputDialog.open()
}, },
carChange(e,index,index1) { carChange(e,index,index1) {
console.log(this.carList)
this.carNum = 0 this.carNum = 0
for (let i = 0; i < this.carList.length; i++) { for (let i = 0; i < this.carList.length; i++) {
this.carList[i].num = 0 this.carList[i].num = 0
@ -628,12 +621,14 @@
border-radius: 10px; border-radius: 10px;
} }
.popup-content { .popup-content {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
padding: 15px; padding: 15px;
height: 1200rpx; height: 1200rpx;
background-color: #fff; background-color: #fff;
margin-bottom: 30rpx;
overflow: scroll;
} }
.popup-title-right-box { .popup-title-right-box {

13
pages/index/shareStyle.vue

@ -455,7 +455,6 @@
} }
.content-right { .content-right {
// width: 550rpx;
flex: 1; flex: 1;
overflow-y: scroll; overflow-y: scroll;
} }
@ -526,11 +525,13 @@
} }
.popup-content { .popup-content {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
padding: 15px; padding: 15px;
height: 1200rpx; height: 1200rpx;
background-color: #fff; background-color: #fff;
margin-bottom: 30rpx;
overflow: scroll;
} }
.popup-title-right-box { .popup-title-right-box {

3
pages/index/waitStorageDetail.vue

@ -299,13 +299,10 @@
.tui-size-24 { .tui-size-24 {
font-size: 24rpx; font-size: 24rpx;
// line-height: 24rpx;
} }
.tui-price-large { .tui-price-large {
font-size: 32rpx; font-size: 32rpx;
// line-height: 30rpx;
.lineText { .lineText {
text-decoration: line-through; text-decoration: line-through;
font-size: 12px; font-size: 12px;

9
pages/inventory/addGoods.vue

@ -51,13 +51,11 @@
data() { data() {
return { return {
fileList1: [], fileList1: [],
// 表单数据
formData: { formData: {
productName: '', productName: '',
price: '', price: '',
productSn: '', productSn: '',
wholesalePrice: '', wholesalePrice: '',
// classification: '',
productPicture: [], productPicture: [],
productIntro: '', productIntro: '',
categoryId: '', categoryId: '',
@ -115,14 +113,7 @@
} }
} }
}, },
onShow() {
// let that = this
// uni.$on('classForm', function(data) {
// that.formData.classification = data
// })
},
onLoad(option) { onLoad(option) {
console.log('option',option)
if(option.dataList){ if(option.dataList){
this.dataList = JSON.parse(option.dataList) this.dataList = JSON.parse(option.dataList)
this.formData.productName = this.dataList.productName this.formData.productName = this.dataList.productName

2
pages/inventory/addinventory.vue

@ -556,7 +556,6 @@
content: "确定删除此条商品吗?", content: "确定删除此条商品吗?",
success: function(res) { success: function(res) {
if(res.confirm){ if(res.confirm){
console.log(that.carList.get(id))
that.carList.get(id).productCount -= that.carList.get(id).stockLogList.get(name); that.carList.get(id).productCount -= that.carList.get(id).stockLogList.get(name);
that.carList.get(id).stockLogList.delete(name) that.carList.get(id).stockLogList.delete(name)
that.carList.get(id).price = that.carList.get(id).productCount * that.carList.get(id).purchasePrice that.carList.get(id).price = that.carList.get(id).productCount * that.carList.get(id).purchasePrice
@ -657,7 +656,6 @@
}, },
//修改已选规格的数量 //修改已选规格的数量
GoodsNumChange(e,index,index1){ GoodsNumChange(e,index,index1){
console.log(this.carList)
let that = this; let that = this;
this.carList.get(index).stockLogList.set(index1,e) this.carList.get(index).stockLogList.set(index1,e)
this.carList.get(index).productCount = 0 this.carList.get(index).productCount = 0

28
pages/inventory/changeGoods1.vue

@ -326,10 +326,10 @@
}, },
//获取弹出层状态 //获取弹出层状态
change(e) { change(e) {
console.log('当前模式:' + e.type + ',状态:' + e.show);
}, },
carChange(e,index,index1) { carChange(e,index,index1) {
console.log(this.carList)
this.carNum = 0 this.carNum = 0
for (let i = 0; i < this.carList.length; i++) { for (let i = 0; i < this.carList.length; i++) {
this.carList[i].num = 0 this.carList[i].num = 0
@ -363,8 +363,6 @@
this.temporaryList = [] this.temporaryList = []
this.columns = [] this.columns = []
this.keyList = [] this.keyList = []
console.log(this.temporaryList)
console.log(this.carList)
if(this.carList != ''){ if(this.carList != ''){
this.zNum = 0 this.zNum = 0
for(let i=0;i<this.carList.length;i++){ for(let i=0;i<this.carList.length;i++){
@ -420,9 +418,6 @@
if(item.delFlag == 0){ if(item.delFlag == 0){
title = '请将商品上架后再操作!' title = '请将商品上架后再操作!'
} }
// else if(item.delFlag == 1){
// title = '请将商品入库后再操作!'
// }
uni.showToast({ uni.showToast({
title: title, title: title,
icon: 'none' icon: 'none'
@ -491,9 +486,7 @@
this.goodsDetail.attributeList[i].value[m].isChecked = false this.goodsDetail.attributeList[i].value[m].isChecked = false
} }
} }
this.$refs.popup.close() this.$refs.popup.close()
console.log(this.carList)
}, },
//删除整条商品 //删除整条商品
delShop(item){ delShop(item){
@ -571,11 +564,13 @@
} }
.popup-content { .popup-content {
align-items: center; align-items: center;
justify-content: center; justify-content: center;
padding: 15px; padding: 15px;
height: 1200rpx; height: 1200rpx;
background-color: #fff; background-color: #fff;
margin-bottom: 30rpx;
overflow: scroll;
} }
.popup-title-right-box { .popup-title-right-box {
@ -699,8 +694,7 @@
border-right: 3px solid red; border-right: 3px solid red;
} }
.content-right { .content-right {
// width: 550rpx;
flex: 1; flex: 1;
overflow-y: scroll; overflow-y: scroll;
} }

4
pages/inventory/gategory.vue

@ -58,7 +58,6 @@
this.tui.request("/app/productCategory/list", "get", { this.tui.request("/app/productCategory/list", "get", {
// shopId: 1, // shopId: 1,
}, false, true).then((res) => { }, false, true).then((res) => {
console.log(res, 'res');
if (res.code == 200) { if (res.code == 200) {
this.indexList = res.result; this.indexList = res.result;
} else{ } else{
@ -98,7 +97,6 @@
this.tui.request("/app/productCategory/save", "post", { this.tui.request("/app/productCategory/save", "post", {
categoryName: e categoryName: e
}, false, true).then((res) => { }, false, true).then((res) => {
console.log(res, 'res');
if (res.code == 200) { if (res.code == 200) {
this.getGategoryList() this.getGategoryList()
uni.showToast({ uni.showToast({
@ -152,7 +150,6 @@
this.tui.request("/app/productCategory/delById", "post", { this.tui.request("/app/productCategory/delById", "post", {
id: this.delItems.id, id: this.delItems.id,
}, false, true).then((res) => { }, false, true).then((res) => {
console.log(res, 'res');
if (res.code == 200) { if (res.code == 200) {
this.getGategoryList() this.getGategoryList()
uni.showToast({ uni.showToast({
@ -175,7 +172,6 @@
}, },
//跳转子分类页 //跳转子分类页
goGategoryLow(id) { goGategoryLow(id) {
// console.log(id)
uni.navigateTo({ uni.navigateTo({
url: '/pages/inventory/gategoryLow?id='+id url: '/pages/inventory/gategoryLow?id='+id
}) })

1
pages/inventory/gategoryLow.vue

@ -136,7 +136,6 @@
}, false, true).then((res) => { }, false, true).then((res) => {
if (res.code == 200) { if (res.code == 200) {
item.attributeValue = res.result; item.attributeValue = res.result;
// item.attributeValue = res.result;
}else{ }else{
this.tui.toast(res.message) this.tui.toast(res.message)
} }

66
pages/inventory/goodsList1.vue

@ -195,7 +195,7 @@
<view class="content-list" v-if="radioType == '4'"> <view class="content-list" v-if="radioType == '4'">
<view class="list-name" style="width:150rpx;padding-left:0;">选择车号</view> <view class="list-name" style="width:150rpx;padding-left:0;">选择车号</view>
<view class="list-val"> <view class="list-val">
<input type="text" placeholder="请选择" disabled <input type="text" placeholder="请选择" disabled :value="wlName.companyName"
style="border-bottom: 1px solid #fff;text-align: center;" style="border-bottom: 1px solid #fff;text-align: center;"
@tap.stop="goPopleList('fcName')"> @tap.stop="goPopleList('fcName')">
<uni-icons type="right" size="16" <uni-icons type="right" size="16"
@ -427,7 +427,8 @@
saleDetailList: [], saleDetailList: [],
yNum: 150, yNum: 150,
clearMsg:'', clearMsg:'',
priceType:'' priceType:'',
multiple:1
} }
}, },
components: { components: {
@ -550,7 +551,7 @@
}) })
this.getAllPrice() this.getAllPrice()
this.getAmountAndWho() this.getAmountAndWho()
this.noPay = this.shouldPay // this.noPay = this.shouldPay
}, },
filters: { filters: {
sliceMsg(val) { sliceMsg(val) {
@ -657,10 +658,7 @@
this.noPay = this.relPrice - e.target.value; this.noPay = this.relPrice - e.target.value;
}, },
getImg(key) { getImg(key) {
return this.carList.get(key).productPicture return this.carList.get(key).productPicture
// value[1].productPicture
}, },
//切换销售员 //切换销售员
categoryChange(e) { categoryChange(e) {
@ -673,15 +671,13 @@
}, },
//扫一扫功能 //扫一扫功能
scanCodeAdd() { scanCodeAdd() {
// this.clearMsg = '1'
uni.setStorageSync('saoma','1') uni.setStorageSync('saoma','1')
uni.scanCode({ uni.scanCode({
success: (res) => { success: (res) => {
this.toggle('bottom', res.result); this.toggle('bottom', res.result);
}, },
fail: (res) => { fail: (res) => {
// this.clearMsg = '1'
uni.showToast({ uni.showToast({
title: '扫描失败', title: '扫描失败',
icon: 'none' icon: 'none'
@ -795,8 +791,7 @@
} }
}).catch((res) => {}) }).catch((res) => {})
}, },
temporaryChange(val) { temporaryChange(val) {
console.log('扫一扫',this.temporaryList)
this.zNum = 0 this.zNum = 0
for (var i = 0; i < this.temporaryList.length; i++) { for (var i = 0; i < this.temporaryList.length; i++) {
this.zNum += this.temporaryList[i].productCount this.zNum += this.temporaryList[i].productCount
@ -805,10 +800,6 @@
//折扣种类选择 //折扣种类选择
discountChange(e) { discountChange(e) {
let that = this; let that = this;
// if(this.carList.size == 0){
// this.tui.toast("请先选择商品")
// return
// }
that.shouldPay = 0 that.shouldPay = 0
this.discountType = e.detail.value; this.discountType = e.detail.value;
this.carList.forEach(function(value, key) { this.carList.forEach(function(value, key) {
@ -819,7 +810,6 @@
}) })
this.price = this.shouldPay //永远不变的总金额/实际折扣后的总金额 this.price = this.shouldPay //永远不变的总金额/实际折扣后的总金额
this.discountNum = 10 this.discountNum = 10
// shouldPay
for (let i = 0; i < this.items.length; i++) { for (let i = 0; i < this.items.length; i++) {
if (this.items[i].value === e.detail.value) { if (this.items[i].value === e.detail.value) {
this.discountCurrent = i; this.discountCurrent = i;
@ -1121,14 +1111,14 @@
onPrint(opt) { onPrint(opt) {
let that = this; let that = this;
that.yNum = 150 that.yNum = 150
let strCmd = blesdk.CreatCPCLPage(600, 1040, 1, 0); let strCmd = blesdk.CreatCPCLPage(600, 2080, 1, 0);
strCmd += blesdk.addCPCLSETMAG(2, 2) strCmd += blesdk.addCPCLSETMAG(2, 2)
blesdk.addCPCLSETBOLD('bold') blesdk.addCPCLSETBOLD('bold')
strCmd += blesdk.addCPCLLocation(2); //对齐指令 0-左对齐 1-右对齐 2-居中 strCmd += blesdk.addCPCLLocation(2);
strCmd += blesdk.addCPCLText('0', '30', '24', '0', 0, uni.getStorageSync('shopName')) strCmd += blesdk.addCPCLText('0', '30', '24', '0', 0, uni.getStorageSync('shopName'))
strCmd += blesdk.addCPCLSETMAG(1, 1) strCmd += blesdk.addCPCLSETMAG(1, 1)
strCmd += blesdk.addCPCLLocation(0); //对齐指令 0-左对齐 1-右对齐 2-居中 strCmd += blesdk.addCPCLLocation(0);
strCmd += blesdk.addCPCLText('0', '100', '24', '0', 0, '客户:' + this.khName.name) strCmd += blesdk.addCPCLText('0', '100', '24', '0', 0, '客户:' + this.khName.name)
strCmd += blesdk.addCPCLText('0', '130', '24', '0', 0, '销售:' + this.createByName) strCmd += blesdk.addCPCLText('0', '130', '24', '0', 0, '销售:' + this.createByName)
strCmd += blesdk.addCPCLText('280', '130', '24', '0', 0, '日期:' + this.formatDate(new Date(), strCmd += blesdk.addCPCLText('280', '130', '24', '0', 0, '日期:' + this.formatDate(new Date(),
@ -1137,33 +1127,53 @@
'=========================================================') '=========================================================')
this.carList.forEach(function(value, key) { this.carList.forEach(function(value, key) {
strCmd += blesdk.addCPCLText('0', that.yNum += 30, '24', '0', 0, value.productName + '(' + strCmd += blesdk.addCPCLText('0', that.countPrint(), '24', '0', 0, value.productName + '(' +
value.productSn + ')' + '折扣:' + (value.discount < 10 ? value.discount : '无折扣')) value.productSn + ')' + '折扣:' + (value.discount < 10 ? value.discount : '无折扣'))
value.stockLogList.forEach(function(value1, key1) { value.stockLogList.forEach(function(value1, key1) {
strCmd += blesdk.addCPCLText('0', that.yNum += 30, '24', '0', 0, (that.slicePrint( strCmd += blesdk.addCPCLText('0', that.countPrint(), '24', '0', 0, (that.slicePrint(
key1)) + '*' + value1) key1)) + '*' + value1)
strCmd += blesdk.addCPCLText('200', that.yNum, '24', '0', 0, '单价:' + value.lsprice) strCmd += blesdk.addCPCLText('200', that.yNum, '24', '0', 0, '单价:' + value.lsprice)
strCmd += blesdk.addCPCLText('360', that.yNum, '24', '0', 0, '总价:' + (value strCmd += blesdk.addCPCLText('360', that.yNum, '24', '0', 0, '总价:' + (value
.lsprice * value1)) .lsprice * value1))
}) })
}) })
strCmd += blesdk.addCPCLText('0', this.yNum += 20, '24', '0', 0, strCmd += blesdk.addCPCLText('0', this.countPrint(), '24', '0', 0,
'===============================================================') '===============================================================')
strCmd += blesdk.addCPCLText('0', this.yNum += 30, '24', '0', 0, '总数量:' + this.totalAmount) strCmd += blesdk.addCPCLText('0', this.countPrint(), '24', '0', 0, '总数量:' + this.totalAmount)
strCmd += blesdk.addCPCLText('200', this.yNum, '24', '0', 0, '总金额' + this.shouldPay) strCmd += blesdk.addCPCLText('200', this.yNum, '24', '0', 0, '总金额' + this.shouldPay)
strCmd += blesdk.addCPCLText('400', this.yNum, '24', '0', 0, '应收:' + this.relPrice) strCmd += blesdk.addCPCLText('400', this.yNum, '24', '0', 0, '应收:' + this.relPrice)
strCmd += blesdk.addCPCLText('0', this.yNum += 30, '24', '0', 0, '实收:' + this.priceOk) strCmd += blesdk.addCPCLText('0', this.countPrint(), '24', '0', 0, '实收:' + this.priceOk)
strCmd += blesdk.addCPCLText('200', this.yNum, '24', '0', 0, '欠款:' + (this.relPrice - this.priceOk)) strCmd += blesdk.addCPCLText('200', this.yNum, '24', '0', 0, '欠款:' + (this.relPrice - this.priceOk))
strCmd += blesdk.addCPCLText('400', this.yNum, '24', '0', 0, '其他费用:' + (this.otherExpense == '' ? 0 : this.otherExpense)) strCmd += blesdk.addCPCLText('400', this.yNum, '24', '0', 0, '其他费用:' + (this.otherExpense == '' ? 0 : this.otherExpense))
strCmd += blesdk.addCPCLText('0', this.yNum += 30, '24', '0', 0, '备注:' + (this.remark == '' ? '无' : this.remark)) if(this.remark.length >20){
strCmd += blesdk.addCPCLLocation(0); //对齐指令 0-左对齐 1-右对齐 2-居中 let position = 20;
let part1 = this.remark.substring(0, position);
let part2 = this.remark.substring(position);
strCmd += blesdk.addCPCLText('0', this.countPrint(), '24', '0', 0, '备注:' + part1)
strCmd += blesdk.addCPCLText('0', this.countPrint(), '24', '0', 0, part2)
}else{
strCmd += blesdk.addCPCLText('0', this.countPrint(), '24', '0', 0, '备注:' + this.remark)
}
strCmd += blesdk.addCPCLLocation(0);
strCmd += blesdk.addCPCLPrint(); strCmd += blesdk.addCPCLPrint();
this.bufferData = strCmd; this.bufferData = strCmd;
console.log(strCmd);
this.$nextTick(()=>{ this.$nextTick(()=>{
uni.redirectTo({ uni.redirectTo({
url: "/pages/index/order" url: "/pages/index/order"
}) })
}) })
},
//计算打印机当前行高度
countPrint(){
if((this.yNum + 30) >= (1040 * this.multiple)){
this.yNum = this.yNum + (1040 * this.multiple - this.yNum) + 50
this.multiple ++
return this.yNum
}else{
return this.yNum += 30
}
}, },
//截取 //截取
slicePrint(val) { slicePrint(val) {
@ -1214,8 +1224,7 @@
carlist.discount = 0; carlist.discount = 0;
}else{ }else{
carlist.discount = e.detail.value; carlist.discount = e.detail.value;
} }
console.log(carlist.discount)
carlist.discountAmount = carlist.unitPrice * carlist.discount / 10 carlist.discountAmount = carlist.unitPrice * carlist.discount / 10
carlist.price = carlist.unitPrice * carlist.discount / 10 * carlist.productCount carlist.price = carlist.unitPrice * carlist.discount / 10 * carlist.productCount
@ -1248,7 +1257,6 @@
content: "确定删除此条商品吗?", content: "确定删除此条商品吗?",
success: function(res) { success: function(res) {
if (res.confirm) { if (res.confirm) {
console.log(that.carList.get(id))
that.carList.get(id).productCount -= that.carList.get(id).stockLogList.get(name); that.carList.get(id).productCount -= that.carList.get(id).stockLogList.get(name);
that.carList.get(id).stockLogList.delete(name); that.carList.get(id).stockLogList.delete(name);
that.carList.get(id).price = that.carList.get(id).productCount * that.carList.get(id).unitPrice that.carList.get(id).price = that.carList.get(id).productCount * that.carList.get(id).unitPrice

7
pages/inventory/inventory.vue

@ -109,7 +109,6 @@
} }
}, },
onShow() { onShow() {
console.log('onshow');
this.getGategoryList() this.getGategoryList()
this.getWarnMsg() this.getWarnMsg()
this.type=uni.getStorageSync('type') this.type=uni.getStorageSync('type')
@ -173,7 +172,6 @@
pageSize: '10' pageSize: '10'
}, false, false).then((res) => { }, false, false).then((res) => {
if (res.code == 200) { if (res.code == 200) {
console.log(res.result.records)
this.shopList = res.result.records this.shopList = res.result.records
} else { } else {
this.tui.toast(res.message) this.tui.toast(res.message)
@ -246,11 +244,7 @@
<style lang="scss" scoped> <style lang="scss" scoped>
.search { .search {
// padding: 20upx;
background-color: #fff; background-color: #fff;
// position: fixed;
// top: 0;
// z-index: 100;
width: 100%; width: 100%;
background-color: #fff; background-color: #fff;
} }
@ -264,7 +258,6 @@
.title-right { .title-right {
width: 30%; width: 30%;
/* margin-top: 110rpx; */
border-left: 1px solid #eee; border-left: 1px solid #eee;
background: #fff; background: #fff;
} }

3
pages/inventory/inventoryDetail.vue

@ -112,13 +112,11 @@
}, },
//去新增商品页编辑 //去新增商品页编辑
goToAddGoods(){ goToAddGoods(){
//去编辑页的时候,分类不能更改了
uni.navigateTo({ uni.navigateTo({
url: "/pages/inventory/addGoods?dataList="+JSON.stringify(this.dataList) url: "/pages/inventory/addGoods?dataList="+JSON.stringify(this.dataList)
}) })
}, },
onPrint(opt) { onPrint(opt) {
//快递单600*1040 入库单440*320
let strCmd = blesdk.CreatCPCLPage(440, 320, 1, 0); let strCmd = blesdk.CreatCPCLPage(440, 320, 1, 0);
strCmd += blesdk.addCPCLText('0', '30', '24', '0', 0, '商品名:'+this.dataList.productName) strCmd += blesdk.addCPCLText('0', '30', '24', '0', 0, '商品名:'+this.dataList.productName)
strCmd += blesdk.addCPCLText('0', '80', '24', '0', 0, '货 号:'+this.dataList.productSn) strCmd += blesdk.addCPCLText('0', '80', '24', '0', 0, '货 号:'+this.dataList.productSn)
@ -128,7 +126,6 @@
strCmd += blesdk.addCPCLQRCode(260, 170, 'H', '1', 6, this.dataList.id) //二维码 strCmd += blesdk.addCPCLQRCode(260, 170, 'H', '1', 6, this.dataList.id) //二维码
strCmd += blesdk.addCPCLLocation(0); //对齐指令 0-左对齐 1-右对齐 2-居中 strCmd += blesdk.addCPCLLocation(0); //对齐指令 0-左对齐 1-右对齐 2-居中
strCmd += blesdk.addCPCLPrint(); strCmd += blesdk.addCPCLPrint();
console.log('这是是数据',strCmd)
this.bufferData = strCmd; this.bufferData = strCmd;
}, },
} }

14
pages/login/login.vue

@ -99,7 +99,6 @@
}, },
computed: mapState(['type']), computed: mapState(['type']),
onLoad() { onLoad() {
// uni.clearStorageSync()
if (uni.getStorageSync('hiver_token')) { if (uni.getStorageSync('hiver_token')) {
uni.reLaunch({ uni.reLaunch({
url: '/pages/index/index' url: '/pages/index/index'
@ -122,8 +121,7 @@
} }
}).catch((res) => {}) }).catch((res) => {})
}, },
sectionChange(index) { sectionChange(index) {
console.log('给他赋值',index)
this.wayValue = index; this.wayValue = index;
}, },
//登录 //登录
@ -157,7 +155,6 @@
saveLogin: true, saveLogin: true,
type: this.wayValue type: this.wayValue
}, true, true).then((res) => { }, true, true).then((res) => {
console.log(res)
if (res.code == 200) { if (res.code == 200) {
uni.setStorageSync("hiver_token", res.result.lcomToken) uni.setStorageSync("hiver_token", res.result.lcomToken)
uni.setStorageSync("transCompany", res.result.logiticsCompany.id) uni.setStorageSync("transCompany", res.result.logiticsCompany.id)
@ -175,10 +172,6 @@
this.tui.request(loginUrl, "POST", data, true, true).then((res) => { this.tui.request(loginUrl, "POST", data, true, true).then((res) => {
if (res.code == 200) { if (res.code == 200) {
uni.setStorageSync("hiver_token", res.result.accessToken) uni.setStorageSync("hiver_token", res.result.accessToken)
// let state = {
// token: res.result.accessToken
// }
// this.login(state)
//多店铺的时候,在这里加上打开店铺选择弹窗 //多店铺的时候,在这里加上打开店铺选择弹窗
if(this.wayValue == 2){ //下游客户登录 if(this.wayValue == 2){ //下游客户登录
setTimeout(() => { setTimeout(() => {
@ -196,7 +189,6 @@
setTimeout(() => { setTimeout(() => {
uni.reLaunch({ uni.reLaunch({
url: '/pages/index/index' url: '/pages/index/index'
// url: '/pages/index/logistics'
}) })
}, 200) }, 200)
this.tui.toast('登录成功', 2000, true) this.tui.toast('登录成功', 2000, true)
@ -247,7 +239,7 @@
} }
}).catch((res) => {}) }).catch((res) => {})
} else if (reg(this.mobile, this.clock) && this.isChoose == true) { } else if (reg(this.mobile, this.clock) && this.isChoose == true) {
console.log('通过了')
} }
}, },
setTime() { // 倒计时函数 setTime() { // 倒计时函数
@ -267,7 +259,6 @@
}, },
//注册 //注册
goRegister() { goRegister() {
console.log("111");
uni.navigateTo({ uni.navigateTo({
url: '/pages/login/register' url: '/pages/login/register'
}) })
@ -292,7 +283,6 @@
<style lang="scss" scoped> <style lang="scss" scoped>
.content { .content {
// margin-top: 190rpx;z
height: 1624rpx; height: 1624rpx;
background: #fff; background: #fff;
} }

4
pages/login/register.vue

@ -104,7 +104,7 @@
this.tui.toast(res) this.tui.toast(res)
}) })
}else if(reg(this.formData.mobile,this.clock) && this.isChoose == true){ }else if(reg(this.formData.mobile,this.clock) && this.isChoose == true){
console.log('通过了')
} }
}, },
setTime(){// 倒计时函数 setTime(){// 倒计时函数
@ -141,7 +141,7 @@
} }
}) })
}).catch(err => { }).catch(err => {
console.log('表单错误信息:', err);
}) })
} }
} }

2
pages/other/custom.vue

@ -77,7 +77,6 @@
}, },
methods: { methods: {
sectionChange(index) { sectionChange(index) {
console.log(index)
this.current = index this.current = index
this.bList = [] this.bList = []
if (index == 0) { if (index == 0) {
@ -132,7 +131,6 @@
}) })
}, },
dateChange() { dateChange() {
console.log(this.range)
this.query.startDate = this.range[0] this.query.startDate = this.range[0]
this.query.endDate = this.range[1] this.query.endDate = this.range[1]
this.sectionChange(this.current) this.sectionChange(this.current)

246
pages/other/logistics.vue

@ -2,15 +2,15 @@
<view> <view>
<view> <view>
<button size="default" type="default" @tap="goAddPeople" hover-class="is-hover">上线</button> <button size="default" type="default" @tap="goAddPeople" hover-class="is-hover">上线</button>
</view> </view>
<view class="contentPadding"> <view class="contentPadding">
<view class="title"> <view class="title">
<i class="iconfont icon-huaban"> 今日订单 <i class="iconfont icon-huaban"> 今日订单
<view class="btn" @tap="gotoSearchData"> <view class="btn" @tap="gotoSearchData">
历史订单 > 历史订单 >
</view> </view>
</i> </i>
</view> </view>
</view> </view>
<view class="item-wrapper"> <view class="item-wrapper">
<u-subsection :list="list" :current="current" @change="sectionChange"></u-subsection> <u-subsection :list="list" :current="current" @change="sectionChange"></u-subsection>
@ -36,6 +36,8 @@
</view> </view>
</view> </view>
<u-modal :show="modalShow" title="详细地址" :content='content' @confirm="modalShow = false"></u-modal> <u-modal :show="modalShow" title="详细地址" :content='content' @confirm="modalShow = false"></u-modal>
<uni-fab ref="fab" :content="content" :horizontal="horizontal"
@trigger="trigger" />
</view> </view>
</template> </template>
@ -47,8 +49,8 @@
return { return {
range: '', range: '',
name: '', name: '',
shopList: [], shopList: [],
list: ['待指派', '待取货','待送达'], list: ['待指派', '待取货', '待送达'],
modalShow: false, modalShow: false,
content: '地址地址地址', content: '地址地址地址',
query: { query: {
@ -59,8 +61,15 @@
}, },
transCompany: '' transCompany: ''
}, },
}, },
bList:[] bList: [],
horizontal: 'right',
content: [{
iconPath: '/static/images/tabbar/home.png',
selectedIconPath: '/static/images/tabbar/home-sel.png',
text: '地址配置',
active: false
}]
} }
}, },
created() { created() {
@ -70,110 +79,102 @@
this.query.saleVO.searchDateVo.endDate = date + ' 23:59:59' this.query.saleVO.searchDateVo.endDate = date + ' 23:59:59'
this.query.saleVO.transCompany = id this.query.saleVO.transCompany = id
this.range = date this.range = date
this.getShopList() this.getShopList()
this.getAllList() this.getAllList()
}, },
methods: { methods: {
sectionChange(index) { sectionChange(index) {
console.log(index) this.current = index
this.current = index this.bList = []
this.bList = [] if (index == 0) {
if (index == 0) { this.getAllList()
this.getAllList() }
} if (index == 1) {
if (index == 1) { this.getList()
this.getList() }
} if (index == 2) {
if (index == 2) { this.getReturnList()
this.getReturnList() }
} },
}, trigger(e) {
getList() { // console.log(e)
this.tui.request('/app/sale/listAll', 'post', { // this.content[e.index].active = !e.item.active
remarkSR:2, //e.item.text
shopId: this.shopId,
searchDateVo: this.query
}, false, false, false).then(res => {
if (res.code !== 200) return
this.bList = res.result
})
},
getAllList() {
this.tui.request('/app/sale/listAll', 'post', {
remarkSR:2,
shopId: this.shopId,
searchDateVo: this.query
}, false, false, false).then(res => {
if (res.code !== 200) return
this.bList = res.result.saleList
})
},
getReturnList() {
this.tui.request('/app/sale/listAll', 'post', {
remarkSR:3,
shopId: this.shopId,
searchDateVo: this.query
}, false, false, false).then(res => {
if (res.code !== 200) return
this.bList = res.result.returnSaleList
})
},
dateChange() {
console.log(this.range)
this.query.startDate = this.range[0]
this.query.endDate = this.range[1]
this.sectionChange(this.current)
},
gotoInfo() {
uni.navigateTo({
url: `/pages/index/shopInfo`
})
},
gotoSearchData() {
uni.navigateTo({ uni.navigateTo({
url: '/pages/other/logisticsDetail' url: `/pages/other/logisticsAddress`
}) })
},
getList() {
this.tui.request('/app/sale/listAll', 'post', {
remarkSR: 2,
shopId: this.shopId,
searchDateVo: this.query
}, false, false, false).then(res => {
if (res.code !== 200) return
this.bList = res.result
})
},
getAllList() {
this.tui.request('/app/sale/listAll', 'post', {
remarkSR: 2,
shopId: this.shopId,
searchDateVo: this.query
}, false, false, false).then(res => {
if (res.code !== 200) return
this.bList = res.result.saleList
})
},
getReturnList() {
this.tui.request('/app/sale/listAll', 'post', {
remarkSR: 3,
shopId: this.shopId,
searchDateVo: this.query
}, false, false, false).then(res => {
if (res.code !== 200) return
this.bList = res.result.returnSaleList
})
},
dateChange() {
this.query.startDate = this.range[0]
this.query.endDate = this.range[1]
this.sectionChange(this.current)
},
gotoInfo() {
uni.navigateTo({
url: `/pages/index/shopInfo`
})
},
gotoSearchData() {
uni.navigateTo({
url: '/pages/other/logisticsDetail'
})
}, },
getShopList() { getShopList() {
// this.tui.request('/app/sale/listCompany', 'POST', {}, false, true, false).then(res => {
// if (res.code !== 200) return
// this.shopList = res.result.map((v) => {
// return {
// text: v.shopName,
// value: v.id
// }
// })
// })
const that = this const that = this
uni.request({ uni.request({
url: tui.interfaceUrl() + '/app/sale/listCompany', url: tui.interfaceUrl() + '/app/sale/listCompany',
data: this.query.saleVO, data: this.query.saleVO,
header: { header: {
'content-type': 'application/json', 'content-type': 'application/json',
// 'Authorization': tui.getToken()
'appWLToken': tui.getToken() 'appWLToken': tui.getToken()
}, },
method: 'post', //'GET','POST' method: 'post',
dataType: 'json', dataType: 'json',
success: (res) => { success: (res) => {
that.shopList = res.data.result that.shopList = res.data.result
console.log(res)
}, },
fail: (res) => { fail: (res) => {
tui.toast("网络不给力,请稍后再试~") tui.toast("网络不给力,请稍后再试~")
console.log(res)
} }
}) })
}, },
onCellClick(item) { onCellClick(item) {
this.modalShow = true this.modalShow = true
this.content = item.receiveAddress this.content = item.receiveAddress
console.log('item', item)
}, },
onDatePackerChange(date) { onDatePackerChange(date) {
console.log(date)
if (!date) { if (!date) {
this.query.saleVO.searchDateVo.startDate = '' this.query.saleVO.searchDateVo.startDate = ''
this.query.saleVO.searchDateVo.endDate = '' this.query.saleVO.searchDateVo.endDate = ''
@ -209,7 +210,7 @@
color: #ffffff; color: #ffffff;
background: #5fd9ee; background: #5fd9ee;
width: 90%; width: 90%;
margin:20rpx auto; margin: 20rpx auto;
} }
.example-body {} .example-body {}
@ -235,36 +236,37 @@
overflow: hidden; overflow: hidden;
white-space: nowrap; white-space: nowrap;
text-overflow: ellipsis; text-overflow: ellipsis;
} }
.contentPadding {
padding: 0 20upx; .contentPadding {
background-color: #fff; padding: 0 20upx;
color: #909399; background-color: #fff;
color: #909399;
.title {
padding-left: 20rpx; .title {
font-size: 32rpx; padding-left: 20rpx;
color: #303133; font-size: 32rpx;
line-height: 66rpx; color: #303133;
line-height: 66rpx;
image {
display: inline-block; image {
width: 40rpx; display: inline-block;
vertical-align: middle; width: 40rpx;
} vertical-align: middle;
}
.btn {
text-align: right; .btn {
width: 24%; text-align: right;
float: right; width: 24%;
font-size: 26rpx; float: right;
color: $u-primary; font-size: 26rpx;
} color: $u-primary;
} }
}
.grid-text {
font-size: 28rpx; .grid-text {
margin-bottom: 26rpx; font-size: 28rpx;
} margin-bottom: 26rpx;
}
} }
</style> </style>

18
pages/other/logisticsDetail.vue

@ -63,7 +63,6 @@
}, },
methods: { methods: {
sectionChange(index) { sectionChange(index) {
console.log(index)
this.current = index this.current = index
this.bList = [] this.bList = []
if (index == 0) { if (index == 0) {
@ -107,7 +106,6 @@
}) })
}, },
dateChange() { dateChange() {
console.log(this.range)
this.query.startDate = this.range[0] this.query.startDate = this.range[0]
this.query.endDate = this.range[1] this.query.endDate = this.range[1]
this.sectionChange(this.current) this.sectionChange(this.current)
@ -125,43 +123,29 @@
}) })
}, },
getShopList() { getShopList() {
// this.tui.request('/app/sale/listCompany', 'POST', {}, false, true, false).then(res => {
// if (res.code !== 200) return
// this.shopList = res.result.map((v) => {
// return {
// text: v.shopName,
// value: v.id
// }
// })
// })
const that = this const that = this
uni.request({ uni.request({
url: tui.interfaceUrl() + '/app/sale/listCompany', url: tui.interfaceUrl() + '/app/sale/listCompany',
data: this.query.saleVO, data: this.query.saleVO,
header: { header: {
'content-type': 'application/json', 'content-type': 'application/json',
// 'Authorization': tui.getToken()
'appWLToken': tui.getToken() 'appWLToken': tui.getToken()
}, },
method: 'post', //'GET','POST' method: 'post',
dataType: 'json', dataType: 'json',
success: (res) => { success: (res) => {
that.shopList = res.data.result that.shopList = res.data.result
console.log(res)
}, },
fail: (res) => { fail: (res) => {
tui.toast("网络不给力,请稍后再试~") tui.toast("网络不给力,请稍后再试~")
console.log(res)
} }
}) })
}, },
onCellClick(item) { onCellClick(item) {
this.modalShow = true this.modalShow = true
this.content = item.receiveAddress this.content = item.receiveAddress
console.log('item', item)
}, },
onDatePackerChange(date) { onDatePackerChange(date) {
console.log(date)
if (!date) { if (!date) {
this.query.saleVO.searchDateVo.startDate = '' this.query.saleVO.searchDateVo.startDate = ''
this.query.saleVO.searchDateVo.endDate = '' this.query.saleVO.searchDateVo.endDate = ''

1
pages/rebate/detail.vue

@ -31,7 +31,6 @@
}, false, false, true).then((res) => { }, false, false, true).then((res) => {
if (res.code !== 200) return if (res.code !== 200) return
this.commissionList = res.result this.commissionList = res.result
console.log(res)
}) })
} }
} }

3
pages/rebate/rebate.vue

@ -62,16 +62,13 @@
}, },
methods: { methods: {
onCardClick(e) { onCardClick(e) {
console.log(e)
}, },
getList() { getList() {
console.log('this.$store', this.$store.shopId)
this.tui.request('/app/returnCommission/listWithReturned', 'get', { this.tui.request('/app/returnCommission/listWithReturned', 'get', {
shopId: '001' shopId: '001'
}, false, false, true).then((res) => { }, false, false, true).then((res) => {
if (res.code !== 200) return if (res.code !== 200) return
this.notYetCommissionList = res.result this.notYetCommissionList = res.result
console.log(res)
}) })
}, },
getCommissionList() { getCommissionList() {

2
pages/rebate/withdrawal.vue

@ -30,7 +30,6 @@
export default { export default {
name: "withdrawal", name: "withdrawal",
onLoad(options) { onLoad(options) {
console.log(options)
this.canBalance = options.balance this.canBalance = options.balance
}, },
data() { data() {
@ -42,7 +41,6 @@ export default {
computed:{ computed:{
canSave() { canSave() {
if (!this.balance) return true if (!this.balance) return true
console.log(this.balance < this.canBalance,this.balance , this.canBalance)
if (+this.balance > +this.canBalance) return true if (+this.balance > +this.canBalance) return true
return false return false
} }

7
pages/staff/addStaff/addStaff.vue

@ -62,8 +62,7 @@
}, },
onLoad(options) { onLoad(options) {
const type = options.type const type = options.type
const item = JSON.parse(options.item) const item = JSON.parse(options.item)
console.log(item)
this.type = options.type this.type = options.type
if (type === 'edit') { if (type === 'edit') {
this.addForm.nickname = item.nickname this.addForm.nickname = item.nickname
@ -77,7 +76,6 @@
}, },
methods: { methods: {
onFormSubmit() { onFormSubmit() {
console.log('submit')
this.$refs.addForm.validate().then(async () => { this.$refs.addForm.validate().then(async () => {
let url; let url;
if(this.type=='edit'){ if(this.type=='edit'){
@ -90,12 +88,11 @@
true, false) true, false)
if (res.code == 200) { if (res.code == 200) {
uni.navigateBack() uni.navigateBack()
console.log(res)
} else { } else {
this.tui.toast(res.message) this.tui.toast(res.message)
} }
}, (reason) => { }, (reason) => {
console.log(reason)
}) })
} }
} }

5
pages/staff/clock/clock.vue

@ -78,10 +78,10 @@
const amapObject = new amap.AMapWX({ key: 'f06653d65bcefa97e94ab08917389842' }) const amapObject = new amap.AMapWX({ key: 'f06653d65bcefa97e94ab08917389842' })
amapObject.getRegeo({ amapObject.getRegeo({
success: (res) => { success: (res) => {
console.log(res, res[0].regeocodeData.formatted_address)
}, },
fail: (err) => { fail: (err) => {
console.log(err)
} }
}) })
// if (!this.isClock) { // if (!this.isClock) {
@ -95,7 +95,6 @@
// } else { // } else {
// this.tui.toast(res.message) // this.tui.toast(res.message)
// } // }
// console.log(res)
// }) // })
// } // }
} }

5
pages/staff/signRule/signRule.vue

@ -51,12 +51,11 @@
this.addForm.longitude = res[0].longitude this.addForm.longitude = res[0].longitude
}, },
fail: (err) => { fail: (err) => {
console.log(err)
} }
}) })
}, },
onFormSubmit() { onFormSubmit() {
console.log('submit')
this.$refs.addForm.validate().then(async () => { this.$refs.addForm.validate().then(async () => {
let url; let url;
if (this.type == 'edit') { if (this.type == 'edit') {
@ -69,12 +68,10 @@
true, false) true, false)
if (res.code == 200) { if (res.code == 200) {
uni.navigateBack() uni.navigateBack()
console.log(res)
} else { } else {
this.tui.toast(res.message) this.tui.toast(res.message)
} }
}, (reason) => { }, (reason) => {
console.log(reason)
}) })
}, },
start(e) { start(e) {

Loading…
Cancel
Save