Browse Source

Merge branch 'yijia' of http://47.101.187.29:8081/loumengning/shop into yijia

undefined
v-Brocloni 4 years ago
parent
commit
7193ebabef
53 changed files with 269 additions and 115 deletions
  1. +9
    -8
      addons/unishop/controller/User.php
  2. +2
    -0
      addons/unishop/uniapp/uni-shop/components/upload-images.vue
  3. +2
    -0
      addons/unishop/uniapp/uni-shop/main.js
  4. +2
    -2
      addons/unishop/uniapp/uni-shop/manifest.json
  5. +18
    -18
      addons/unishop/uniapp/uni-shop/pages.json
  6. +3
    -1
      addons/unishop/uniapp/uni-shop/pages/address/address.vue
  7. +1
    -1
      addons/unishop/uniapp/uni-shop/pages/address/addressManage.vue
  8. +3
    -1
      addons/unishop/uniapp/uni-shop/pages/cart/cart.vue
  9. +3
    -3
      addons/unishop/uniapp/uni-shop/pages/money/pay.vue
  10. +1
    -1
      addons/unishop/uniapp/uni-shop/pages/order/createOrder.vue
  11. +1
    -1
      addons/unishop/uniapp/uni-shop/pages/order/evaluate.vue
  12. +27
    -17
      addons/unishop/uniapp/uni-shop/pages/order/order.vue
  13. +3
    -3
      addons/unishop/uniapp/uni-shop/pages/order/orderDetail.vue
  14. +2
    -2
      addons/unishop/uniapp/uni-shop/pages/order/refund.vue
  15. +2
    -2
      addons/unishop/uniapp/uni-shop/pages/product/product.vue
  16. +1
    -1
      addons/unishop/uniapp/uni-shop/pages/public/login.vue
  17. +4
    -2
      addons/unishop/uniapp/uni-shop/pages/set/set.vue
  18. +11
    -11
      addons/unishop/uniapp/uni-shop/pages/user/user.vue
  19. +25
    -25
      addons/unishop/uniapp/uni-shop/pages/userinfo/userinfo.vue
  20. +1
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/index.html
  21. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/index.932a3dd6.js
  22. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/index.d85fe231.js
  23. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-address-address.108e6497.js
  24. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-address-address.a8c2c240.js
  25. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-address-addressManage.3cc361c6.js
  26. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-address-addressManage.4296e717.js
  27. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-money-pay.3e1483db.js
  28. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-money-pay.4d36afdb.js
  29. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-createOrder.e6890570.js
  30. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-createOrder.e85e33f9.js
  31. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-evaluate.696c76e7.js
  32. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-evaluate.8b8c1829.js
  33. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-order.48b2f816.js
  34. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-order.791eba5d.js
  35. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-orderDetail.723fc3b6.js
  36. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-orderDetail.8a407448.js
  37. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-refund.25025ced.js
  38. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-refund.d5c05d8e.js
  39. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-product-product.16700c23.js
  40. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-product-product.a1d624fc.js
  41. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-public-login.15460be0.js
  42. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-public-login.d31ba2ee.js
  43. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-set-set.776c9a1f.js
  44. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-set-set.bba6e200.js
  45. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-user-user.10188c0c.js
  46. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-user-user.31e41caf.js
  47. +0
    -1
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-userinfo-userinfo.4e5b7c2d.js
  48. +1
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-userinfo-userinfo.add1dfed.js
  49. +0
    -0
      addons/unishop/uniapp/uni-shop/unpackage/dist/dev/.automator/mp-weixin/.automator.json
  50. +118
    -0
      application/admin/controller/unishop/Order.php
  51. +1
    -1
      application/admin/view/unishop/market/flash_sale/index.html
  52. +2
    -0
      application/admin/view/unishop/order/index.html
  53. +13
    -0
      public/assets/js/backend/unishop/order.js

+ 9
- 8
addons/unishop/controller/User.php View File

@@ -128,15 +128,16 @@ class User extends Base
*/
public function edit()
{
$userInfo = $this->auth->getUserinfo();
$username = $this->request->post('username', $userInfo['username']);
$mobile = $this->request->post('mobile', $userInfo['mobile']);
$avatar = $this->request->post('avatar', $userInfo['avatar']);

// $userInfo = $this->auth->getUserinfo();
// $username = $this->request->post('username', $userInfo['username']);
$password = $this->request->post('password', "");
// $avatar = $this->request->post('avatar', $userInfo['avatar']);
if (!$password){
$this->error(__('请填写密码'), 0);
}
$user = \app\common\model\User::get($this->auth->id);
$user->username = $username;
$user->mobile = $mobile;
$user->avatar = $avatar;
$pwd= \app\common\library\Auth::instance()->getEncryptPassword($password, $user->salt);
$user->password = $pwd;
if ($user->save()) {
$this->success(__('Modified'), 1);
} else {


+ 2
- 0
addons/unishop/uniapp/uni-shop/components/upload-images.vue View File

@@ -125,6 +125,8 @@ export default {
//删除图片
delImage: function(index){
uni.showModal({
cancelText:'Cancel',
confirmText:'OK',
content: '确定要放弃这张图片么?',
success: (confirmRes)=> {
if (confirmRes.confirm) {


+ 2
- 0
addons/unishop/uniapp/uni-shop/main.js View File

@@ -76,6 +76,8 @@ const checkLogin = () => {
return new Promise(resolve => {
if (Vue.prototype.$store.state.hasLogin == false) {
uni.showModal({
cancelText:'Cancel',
confirmText:'OK',
title: '温馨提示',
content: '你还没登录,请先登录',
success(res) {


+ 2
- 2
addons/unishop/uniapp/uni-shop/manifest.json View File

@@ -63,9 +63,9 @@
},
"h5" : {
"title" : "宜家自购商城",
"domain" : "http://nwx.zhizhuchuxing.cn:8083/",
"domain" : "qdh.zhizhuchuxing.cn",
"router" : {
"base" : "/h5/",
"base" : "/h5",
"mode" : "hash"
},
"template" : "template.h5.html",


+ 18
- 18
addons/unishop/uniapp/uni-shop/pages.json View File

@@ -6,12 +6,12 @@
"style": {
"enablePullDownRefresh": true,
// #ifdef MP
"navigationBarTitleText": "IKEA商城",
"navigationBarTitleText": "IKEA SHOP",
//"navigationStyle": "custom",
// #endif
"app-plus": {
"titleNView": {
"titleText": "IKEA商城"
"titleText": "IKEA SHOP"
//"type": "transparent"
// "searchInput": {
// "backgroundColor": "rgba(231, 231, 231,.7)",
@@ -44,7 +44,7 @@
{
"path": "pages/product/product",
"style": {
"navigationBarTitleText": "详情展示",
"navigationBarTitleText": "Detail Show",
"enablePullDownRefresh": true,
"app-plus": {
"titleNView": {
@@ -55,13 +55,13 @@
}, {
"path": "pages/set/set",
"style": {
"navigationBarTitleText": "设置"
"navigationBarTitleText": "Setting"
}
},
{
"path": "pages/userinfo/userinfo",
"style": {
"navigationBarTitleText": "修改资料"
"navigationBarTitleText": "Modify Information"
}
},
// {
@@ -94,7 +94,7 @@
}, {
"path": "pages/user/user",
"style": {
"navigationBarTitleText": "我的",
"navigationBarTitleText": "My",
// #ifdef MP
"navigationStyle": "custom",
// #endif
@@ -125,7 +125,7 @@
}, {
"path": "pages/order/order",
"style": {
"navigationBarTitleText": "我的订单",
"navigationBarTitleText": "My Order",
"enablePullDownRefresh": true,
"app-plus": {
"bounce": "none"
@@ -136,7 +136,7 @@
"path": "pages/order/orderDetail",
"style": {
"enablePullDownRefresh": true,
"navigationBarTitleText": "订单详情",
"navigationBarTitleText": "Order Detail",
"app-plus": {
"bounce": "none",
"titleNView": {
@@ -150,12 +150,12 @@
}, {
"path": "pages/order/createOrder",
"style": {
"navigationBarTitleText": "创建订单"
"navigationBarTitleText": "Create Order"
}
}, {
"path": "pages/address/address",
"style": {
"navigationBarTitleText": "收货地址"
"navigationBarTitleText": "Shipping Address"
}
}, {
"path": "pages/address/addressManage",
@@ -165,13 +165,13 @@
}, {
"path": "pages/money/pay",
"style": {
"navigationBarTitleText": "支付"
"navigationBarTitleText": "Payment"
}
},
{
"path": "pages/money/paySuccess",
"style": {
"navigationBarTitleText": "支付成功"
"navigationBarTitleText": "Pay Success"
}
}
,{
@@ -183,7 +183,7 @@
,{
"path" : "pages/category/category",
"style" : {
"navigationBarTitleText": "分类",
"navigationBarTitleText": "Classification",
"enablePullDownRefresh": true,
"app-plus": {
"bounce": "none"
@@ -194,7 +194,7 @@
"path" : "pages/product/list",
"style" : {
"enablePullDownRefresh": true,
"navigationBarTitleText": "商品列表"
"navigationBarTitleText": "Product List"
}
}
,{
@@ -208,7 +208,7 @@
"path" : "pages/favorite/favorite",
"style" : {
"enablePullDownRefresh": true,
"navigationBarTitleText": "我的收藏"
"navigationBarTitleText": "My Collection"
}
},
{
@@ -262,13 +262,13 @@
"pagePath": "pages/index/index",
"iconPath": "static/tab-home.png",
"selectedIconPath": "static/tab-home-current.png",
"text": "首页"
"text": "Home"
},
{
"pagePath": "pages/category/category",
"iconPath": "static/tab-cate.png",
"selectedIconPath": "static/tab-cate-current.png",
"text": "分类"
"text": "Classification"
},
// {
// "pagePath": "pages/cart/cart",
@@ -280,7 +280,7 @@
"pagePath": "pages/user/user",
"iconPath": "static/tab-my.png",
"selectedIconPath": "static/tab-my-current.png",
"text": "我的"
"text": "My"
}
]
},


+ 3
- 1
addons/unishop/uniapp/uni-shop/pages/address/address.vue View File

@@ -16,7 +16,7 @@
<text class="yticon icon-lajitong" @click.stop="deleteAddress(item.id,index)"></text>
</view>

<button class="add-btn" @click="addAddress('add')">新增地址</button>
<button class="add-btn" @click="addAddress('add')">Add New Address</button>
</view>
</template>

@@ -69,6 +69,8 @@
async deleteAddress(id, index) {
let [error, res] = await uni.showModal({
title: '确定删除地址?',
cancelText:'Cancel',
confirmText:'OK',
content: this.addressList[index].address
})



+ 1
- 1
addons/unishop/uniapp/uni-shop/pages/address/addressManage.vue View File

@@ -23,7 +23,7 @@
<text class="tit">设为默认</text>
<switch :checked="addressData.is_default" color="#fa436a" @change="switchChange" />
</view>
<button class="add-btn" @click="confirm">提交</button>
<button class="add-btn" @click="confirm">Submit</button>
<mpvue-city-picker @onChange="onChange" @onCancel="onCancel"
@onConfirm="onConfirm" ref="mpvueCityPicker" ></mpvue-city-picker>


+ 3
- 1
addons/unishop/uniapp/uni-shop/pages/cart/cart.vue View File

@@ -47,7 +47,7 @@
<view class="total-box">
<text class="price">¥{{total}}</text>
</view>
<button type="primary" class="no-border confirm-btn" @click="createOrder">去结算</button>
<button type="primary" class="no-border confirm-btn" @click="createOrder">To Settle</button>
</view>
</view>
</view>
@@ -201,6 +201,8 @@
let id = row.cart_id;
uni.showModal({
cancelText:'Cancel',
confirmText:'OK',
content: '确认删除 ' + list[index].title + '?' ,
success: async (e) => {
if (e.confirm) {


+ 3
- 3
addons/unishop/uniapp/uni-shop/pages/money/pay.vue View File

@@ -38,7 +38,7 @@
</view> -->
</view>

<text class="mix-btn" @click="confirm">确认支付</text>
<text class="mix-btn" @click="confirm">Confirm Pay</text>
</view>
</template>

@@ -184,8 +184,8 @@
uni.showModal({
title: '提示',
content: '是否已支付?',
cancelText: '否',
confirmText: '是',
cancelText:'NO',
confirmText:'OK',
success: function(res) {
if (res.confirm) {
uni.redirectTo({


+ 1
- 1
addons/unishop/uniapp/uni-shop/pages/order/createOrder.vue View File

@@ -111,7 +111,7 @@
<text class="price-tip">¥</text>
<text class="price">{{total}}</text>
</view>
<text class="submit" @click="submit">提交订单</text>
<text class="submit" @click="submit">Submit Order</text>
</view>

<!-- 优惠券面板 -->


+ 1
- 1
addons/unishop/uniapp/uni-shop/pages/order/evaluate.vue View File

@@ -19,7 +19,7 @@
<radio class="radio" color="#e64340" :checked='radio' @click="clickRadio" />公开</radio>
<view class="dec">公开头像昵称,大家可以看到我</view>
</view>
<button class="button" @click="submit" type="warn">提交</button>
<button class="button" @click="submit" type="warn">Submit</button>
</view>
</template>



+ 27
- 17
addons/unishop/uniapp/uni-shop/pages/order/order.vue View File

@@ -43,9 +43,9 @@
<!-- <text v-if="item.delivery_price > 0">(含运费¥{{item.delivery_price}})</text> -->
</view>
<view class="action-box b-t" v-if="item.state != 9">
<button class="action-btn" v-if="item.state == 1" @click.stop="button('cancel',item)">取消订单</button>
<button class="action-btn recom" v-if="item.have_paid == 0" @click.stop="button('pay',item)">立即支付</button>
<button class="action-btn recom" v-if="item.state == 2" @click.stop="button('refunded',item)">退款</button>
<button class="action-btn" v-if="item.state == 1" @click.stop="button('cancel',item)">Cancel Order</button>
<button class="action-btn recom" v-if="item.have_paid == 0" @click.stop="button('pay',item)">Pay Immediately</button>
<button class="action-btn recom" v-if="item.state == 2" @click.stop="button('refunded',item)">Refund</button>
<!-- <button class="action-btn" v-if="item.have_paid != 0 && item.have_delivered == 0">提醒发货</button> -->
<!-- <button class="action-btn" v-if="item.have_paid != 0" @click.stop="button('delivery',item)">查看物流</button> -->
<!-- <button class="action-btn" v-if="item.have_paid != 0 && item.have_received == 0" @click.stop="button('recerved',item)">确认收货</button> -->
@@ -76,42 +76,42 @@
tabCurrentIndex: 0,
navList: [{
state: 0,
text: '全部',
text: 'all',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 1,
text: '待付款',
text: 'Unpayment',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 2,
text: '待发货',
text: 'Unshipped',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 3,
text: '待收货',
text: 'Shipped',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 4,
text: '已完成',
text: 'Completed',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 5,
text: '已取消',
text: 'Cancelled',
loadingType: 'more',
orderList: [],
page: 1
@@ -201,6 +201,8 @@
//删除订单
async deleteOrder(index) {
let [error, res] = await uni.showModal({
cancelText:'Cancel',
confirmText:'OK',
title: '确认删除订单'
});
if (res.confirm) {
@@ -216,6 +218,8 @@
async cancelOrder(item) {
let that = this;
let [error, res] = await uni.showModal({
cancelText:'Cancel',
confirmText:'OK',
title: '确认取消订单',
content: '取消之后不可恢复',
});
@@ -251,6 +255,8 @@
async refunded(item) {
let that = this;
let [error, res] = await uni.showModal({
cancelText:'Cancel',
confirmText:'OK',
title: '确认退款',
content: '退款之后不可恢复',
});
@@ -289,6 +295,8 @@
async receivedOrder(item) {
let that = this;
let [error, res] = await uni.showModal({
cancelText:'Cancel',
confirmText:'OK',
title: '确认收货'
});
if (res.confirm == true) {
@@ -344,7 +352,7 @@
stateTip = '待收货';
break;
case 4:
stateTip = '已完成';
stateTip = '待评价';
break;
case 5:
stateTip = '已取消';
@@ -405,42 +413,42 @@
this.navList = [];
this.navList = [{
state: 0,
text: '全部',
text: 'all',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 1,
text: '待付款',
text: 'Unpayment',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 2,
text: '待发货',
text: 'Unshipped',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 3,
text: '待收货',
text: 'Shipped',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 4,
text: '已完成',
text: 'Completed',
loadingType: 'more',
orderList: [],
page: 1
},
{
state: 5,
text: '已取消',
text: 'Cancelled',
loadingType: 'more',
orderList: [],
page: 1
@@ -482,7 +490,9 @@
justify-content: center;
align-items: center;
height: 100%;
font-size: 15px;
font-size: 12px;
padding: 0 2px;
font-weight: 600;
color: $font-color-dark;
position: relative;



+ 3
- 3
addons/unishop/uniapp/uni-shop/pages/order/orderDetail.vue View File

@@ -55,9 +55,9 @@
<!--兼容苹果系统下margin-bottom不生效-->
</view>
<view class="bottom" v-if="order.state != 9">
<button class="action-btn" v-if="order.state == 1" @click.stop="button('cancel')">取消订单</button>
<button class="action-btn recom" v-if="order.have_paid == 0" @click.stop="button('pay')">立即支付</button>
<button class="action-btn recom" v-if="order.state == 2" @click.stop="button('refunded',item)">退款</button>
<button class="action-btn" v-if="order.state == 1" @click.stop="button('cancel')">Cancel Order</button>
<button class="action-btn recom" v-if="order.have_paid == 0" @click.stop="button('pay')">Pay Immediately</button>
<button class="action-btn recom" v-if="order.state == 2" @click.stop="button('refunded',item)">Refund</button>
<!-- <button class="action-btn" v-if="order.have_paid != 0" @click.stop="button('delivery')">查看物流</button> -->
<!-- <button class="action-btn" v-if="order.have_paid != 0 && order.have_received == 0" @click.stop="button('recerved')">确认收货</button> -->
<!-- <button class="action-btn" v-if="order.have_paid != 0" @click.stop="button('refund')">申请售后</button> -->


+ 2
- 2
addons/unishop/uniapp/uni-shop/pages/order/refund.vue View File

@@ -21,7 +21,7 @@
<view class="cell-tit clamp">快递编号
<input style="max-width: 350rpx;" class="input" type="text" v-model="expressNumber" placeholder="请填写快递编号" placeholder-class="placeholder" />
</view>
<button type="warn" @click="confirmDelivery" v-if="order.refund_status == 2">确认发货</button>
<button type="warn" @click="confirmDelivery" v-if="order.refund_status == 2">Confirm Delivery</button>
</view>
<view class="yt-list-cell">
@@ -66,7 +66,7 @@
</view>
</view>
<button v-if="order.status == 1" class="button" @click="submit" type="warn">提交</button>
<button v-if="order.status == 1" class="button" @click="submit" type="warn">Submit</button>
</view>
</template>



+ 2
- 2
addons/unishop/uniapp/uni-shop/pages/product/product.vue View File

@@ -150,7 +150,7 @@
</view>

<view class="action-btn-group">
<button :class="{'only': flash}" type="primary" class=" action-btn no-border buy-now-btn" @click="buy">立即购买</button>
<button :class="{'only': flash}" type="primary" class=" action-btn no-border buy-now-btn" @click="buy">Buy Now</button>
<!-- <button v-if="!flash" type="primary" class=" action-btn no-border add-cart-btn" @click="addCart">加入购物车</button> -->
</view>
</view>
@@ -208,7 +208,7 @@
</text>
</view>
</view>
<button class="btn" @click="toggleSpec">完成</button>
<button class="btn" @click="toggleSpec">Finish</button>
</view>
</view>



+ 1
- 1
addons/unishop/uniapp/uni-shop/pages/public/login.vue View File

@@ -21,7 +21,7 @@
password data-key="password" @input="inputChange" @confirm="toLogin" />
</view>
</view>
<button class="confirm-btn" @click="toLogin" :disabled="logining">登录</button>
<button class="confirm-btn" @click="toLogin" :disabled="logining">Login</button>
<!-- #ifdef MP-WEIXIN -->
<!-- <button class="confirm-btn" open-type="getPhoneNumber" @getphonenumber="loginForWechatMini">授权微信绑定电话号码一键登录</button> -->
<!-- #endif -->


+ 4
- 2
addons/unishop/uniapp/uni-shop/pages/set/set.vue View File

@@ -1,11 +1,11 @@
<template>
<view class="container">
<view class="list-cell b-b m-t" @click="navTo('/pages/userinfo/userinfo')" hover-class="cell-hover" :hover-stay-time="50">
<text class="cell-tit">修改密码</text>
<text class="cell-tit">Change Password</text>
<text class="cell-more yticon icon-you"></text>
</view>
<view class="list-cell log-out-btn" @click="toLogout">
<text class="cell-tit">退出登录</text>
<text class="cell-tit">Sign Out</text>
</view>
</view>
</template>
@@ -31,6 +31,8 @@
//退出登录
toLogout(){
uni.showModal({
cancelText:'Cancel',
confirmText:'OK',
content: '确定要退出登录么',
success: (e)=>{
if(e.confirm){


+ 11
- 11
addons/unishop/uniapp/uni-shop/pages/user/user.vue View File

@@ -8,7 +8,7 @@
<image class="portrait" :src="userInfo.avatar ? userInfo.avatar : '/static/missing-face.png'"></image>
</view>
<view class="info-box">
<text class="username">{{userInfo.username || '游客'}}</text>
<text class="username">{{userInfo.username || 'Tourist'}}</text>
</view>
</view>
<view class="vip-card-box">
@@ -18,7 +18,7 @@
</view> -->
<view class="tit">
<text class="yticon icon-iLinkapp-"></text>
会员
VIP
</view>
<text class="e-m">uniShop</text>
<!-- <text class="e-b">开通会员开发无bug 一测就上线</text> -->
@@ -39,8 +39,8 @@

<!-- 订单 -->
<view class="order-header">
<view class="title">我的订单</view>
<view class="item" @click="$api.navTo('/pages/order/order?state=0')" >查看全部订单
<view class="title">My Order</view>
<view class="item" @click="$api.navTo('/pages/order/order?state=0')" >Check All Order
<text class="yticon right icon-you"></text>
</view>
</view>
@@ -48,27 +48,27 @@
<view class="order-item" @click="$api.navTo('/pages/order/order?state=1')" hover-class="common-hover" :hover-stay-time="50">
<text class="yticon icon-daifukuan"></text>
<text class="num" v-if="orderNum.unpaid > 0">{{orderNum.unpaid}}</text>
<text>待付款</text>
<text>Unpayment</text>
</view>
<view class="order-item" @click="$api.navTo('/pages/order/order?state=2')" hover-class="common-hover" :hover-stay-time="50">
<text class="yticon icon-daifahuo"></text>
<text class="num" v-if="orderNum.undelivered > 0">{{orderNum.undelivered}}</text>
<text>待发货</text>
<text>Unshipped</text>
</view>
<view class="order-item" @click="$api.navTo('/pages/order/order?state=3')" hover-class="common-hover" :hover-stay-time="50">
<text class="yticon icon-daishouhuo"></text>
<text class="num" v-if="orderNum.unreceived > 0">{{orderNum.unreceived}}</text>
<text>待收货</text>
<text>Shipped</text>
</view>
<view class="order-item" @click="$api.navTo('/pages/order/order?state=4')" hover-class="common-hover" :hover-stay-time="50">
<text class="yticon icon-pingjia"></text>
<text class="num" v-if="orderNum.uncomment > 0">{{orderNum.uncomment}}</text>
<text>已完成</text>
<text>Completed</text>
</view>
<view class="order-item" @click="$api.navTo('/pages/order/order?state=5')" hover-class="common-hover" :hover-stay-time="50">
<text class="yticon icon-shouhou"></text>
<text class="num" v-if="orderNum.refund > 0">{{orderNum.refund}}</text>
<text>已取消</text>
<text>Cancelled</text>
</view>
</view>
<!-- 浏览历史 -->
@@ -89,8 +89,8 @@
<!-- <list-cell icon="icon-dizhi" iconColor="#5fcda2" title="地址管理" @eventClick="$api.navTo('/pages/address/address')"></list-cell> -->
<!-- <list-cell icon="icon-share" iconColor="#9789f7" title="分享" tips="邀请好友赢10万大礼"></list-cell> -->
<!-- <list-cell icon="icon-pinglun-copy" iconColor="#ee883b" title="晒单" tips="晒单抢红包"></list-cell> -->
<list-cell icon="icon-shoucang-setting" iconColor="#54b4ef" title="我的收藏" @eventClick="$api.navTo('/pages/favorite/favorite')"></list-cell>
<list-cell icon="icon-setting" iconColor="#e07472" title="设置" border="" @eventClick="$api.navTo('/pages/set/set')"></list-cell>
<list-cell icon="icon-shoucang-setting" iconColor="#54b4ef" title="My Collection" @eventClick="$api.navTo('/pages/favorite/favorite')"></list-cell>
<list-cell icon="icon-setting" iconColor="#e07472" title="Setting" border="" @eventClick="$api.navTo('/pages/set/set')"></list-cell>
</view>
</view>



+ 25
- 25
addons/unishop/uniapp/uni-shop/pages/userinfo/userinfo.vue View File

@@ -19,26 +19,26 @@
</view>
<view class="yt-list-cell">
<view class="cell-tit clamp">登陆密码
<input v-if="mobile" disabled="true" class="input" type="text" v-model="mobile" />
<input v-if="password" disabled="true" class="input" type="text" v-model="password" />
<!-- <button v-else class="input" open-type="getPhoneNumber" @getphonenumber="getPhoneNumber">授权获取微信绑定的手机号码</button> -->
</view>
</view>
<!-- #endif -->
<!-- #ifndef MP-WEIXIN -->
<view class="yt-list-cell">
<view class="cell-tit clamp">用户名
<view class="cell-tit clamp">user
<input class="input" type="text" v-model="username" />
</view>
</view>
<view class="yt-list-cell">
<view class="cell-tit clamp">手机号码
<input v-if="mobile" disabled="true" class="input" type="text" v-model="mobile" />
<view class="cell-tit clamp">password
<input class="input" type="password" v-model="password" />
</view>
</view>
<!-- #endif -->

<view class="yt-list-cell">
<button type="primary" @click="submit">提交保存</button>
<button type="primary" @click="submit">Submit And Save</button>
</view>

</view>
@@ -53,7 +53,7 @@
data() {
return {
username: '',
mobile: '',
password: '',
avatar: ''
};
},
@@ -62,7 +62,7 @@
},
onLoad() {
this.username = this.userInfo.username;
this.mobile = this.userInfo.mobile;
this.password = '';
this.avatar = this.userInfo.avatar ? this.userInfo.avatar : '';
},
methods: {
@@ -73,35 +73,35 @@
getUserInfo(e) {
this.username = e.detail.userInfo.nickName;
},
async getPhoneNumber(e) {
let data = await this.$api.request('/user/decryptData', 'POST', {
encryptedData: e.detail.encryptedData,
iv: e.detail.iv
});
if (data) {
this.mobile = data.phoneNumber;
}
},
// async getPhoneNumber(e) {
// let data = await this.$api.request('/user/decryptData', 'POST', {
// encryptedData: e.detail.encryptedData,
// iv: e.detail.iv
// });
// if (data) {
// this.password = data.phoneNumber;
// }
// },
async submit() {
if (this.username == '') {
this.$api.msg('用户名称不能为空');
return;
}
if (this.username == this.userInfo.username &&
this.mobile == this.userInfo.mobile &&
this.avatar == this.userInfo.avatar) {
this.$api.msg('已修改');
return;
}
// if (this.username == this.userInfo.username &&
// this.password == this.userInfo.password &&
// this.avatar == this.userInfo.avatar) {
// this.$api.msg('已修改');
// return;
// }
let data = await this.$api.request('/user/edit', 'POST', {
username: this.username,
mobile: this.mobile,
password: this.password,
avatar: this.avatar
});
if (data) {
let userInfo = this.userInfo;
userInfo.username = this.username;
userInfo.mobile = this.mobile;
// userInfo.password = this.password;
userInfo.avatar = this.avatar;
this.setUserInfo(userInfo);
}
@@ -199,7 +199,7 @@
display: inline-block;
vertical-align: middle;
margin-left: 20rpx;
width: 550rpx;
width: 540rpx;
float: right;
line-height: 70rpx !important;
height: 70rpx !important;


+ 1
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/index.html View File

@@ -1,3 +1,3 @@
<!DOCTYPE html><html lang=zh-CN><head><meta charset=utf-8><meta http-equiv=X-UA-Compatible content="IE=edge"><meta name=viewport content="width=device-width,user-scalable=no,initial-scale=1,maximum-scale=1,minimum-scale=1"><title>宜家自购商城</title><script>document.addEventListener('DOMContentLoaded', function() {
document.documentElement.style.fontSize = document.documentElement.clientWidth / 20 + 'px'
})</script><link rel=stylesheet href=/h5/static/index.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script>/*BAIDU_STAT*/</script><script src=/h5/static/js/chunk-vendors.82917b4b.js></script><script src=/h5/static/js/index.d85fe231.js></script></body></html>
})</script><link rel=stylesheet href=/h5/static/index.css></head><body><noscript><strong>Please enable JavaScript to continue.</strong></noscript><div id=app></div><script>/*BAIDU_STAT*/</script><script src=/h5/static/js/chunk-vendors.82917b4b.js></script><script src=/h5/static/js/index.932a3dd6.js></script></body></html>

+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/index.932a3dd6.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/index.d85fe231.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-address-address.108e6497.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-address-address.a8c2c240.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-address-addressManage.3cc361c6.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-address-addressManage.4296e717.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-money-pay.3e1483db.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-money-pay.4d36afdb.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-createOrder.e6890570.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-createOrder.e85e33f9.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-evaluate.696c76e7.js View File

@@ -1 +0,0 @@
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-order-evaluate"],{"2ce4":function(t,a,e){"use strict";var i={uniRate:e("57df").default},n=function(){var t=this,a=t.$createElement,e=t._self._c||a;return e("v-uni-view",{staticClass:"bg"},[e("v-uni-view",{staticClass:"header"},[e("v-uni-image",{staticClass:"image",attrs:{src:t.image}}),e("v-uni-view",{staticClass:"right"},[e("v-uni-view",{staticClass:"title"},[t._v(t._s(t.title))]),e("v-uni-view",{staticClass:"spec"},[t._v(t._s(t.spec))])],1)],1),e("v-uni-view",{staticClass:"rate"},[e("v-uni-view",{staticClass:"dec"},[t._v("描述相符")]),e("uni-rate",{staticClass:"start",attrs:{"active-color":"#e64340",margin:"10",size:"30",value:t.rate},on:{change:function(a){arguments[0]=a=t.$handleEvent(a),t.start.apply(void 0,arguments)}}})],1),e("v-uni-view",{staticClass:"comment"},[e("v-uni-textarea",{attrs:{maxlength:"300",placeholder:"写满20字,有机会被选为优质评价被更多人看到哦~","placeholder-class":"placeholder"},on:{input:function(a){arguments[0]=a=t.$handleEvent(a),t.input.apply(void 0,arguments)}}})],1),e("v-uni-view",{staticClass:"bottom"},[e("v-uni-radio",{staticClass:"radio",attrs:{color:"#e64340",checked:t.radio},on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.clickRadio.apply(void 0,arguments)}}}),t._v("公开"),e("v-uni-view",{staticClass:"dec"},[t._v("公开头像昵称,大家可以看到我")])],1),e("v-uni-button",{staticClass:"button",attrs:{type:"warn"},on:{click:function(a){arguments[0]=a=t.$handleEvent(a),t.submit.apply(void 0,arguments)}}},[t._v("提交")])],1)},r=[];e.d(a,"b",(function(){return n})),e.d(a,"c",(function(){return r})),e.d(a,"a",(function(){return i}))},6274:function(t,a,e){"use strict";e.r(a);var i=e("ad5b"),n=e.n(i);for(var r in i)"default"!==r&&function(t){e.d(a,t,(function(){return i[t]}))}(r);a["default"]=n.a},6327:function(t,a,e){var i=e("24fb");a=i(!1),a.push([t.i,'@charset "UTF-8";\n/* 页面左右间距 */\n/* 文字尺寸 */\n/*文字颜色*/\n/* 边框颜色 */\n/* 图片加载中颜色 */\n/* 行为相关颜色 */\n/* 背景颜色*/uni-page-body[data-v-e33988ac]{background:#f5f5f5}.bg[data-v-e33988ac]{margin:%?20?%;border-radius:%?20?%;background-color:#fff;padding-bottom:%?10?%}.header[data-v-e33988ac]{padding:%?20?%}.header .image[data-v-e33988ac]{width:%?120?%;height:%?120?%}.header .right[data-v-e33988ac]{display:inline-block;line-height:%?45?%;vertical-align:text-bottom;padding-bottom:%?10?%;width:%?550?%;padding-left:%?20?%}.header .right .title[data-v-e33988ac]{color:#707277;font-size:%?33?%;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.header .right .spec[data-v-e33988ac]{color:#91949a;font-size:%?30?%}.rate[data-v-e33988ac]{padding:0 %?20?% %?20?%}.rate .dec[data-v-e33988ac]{display:inline-block;color:#707277}.rate .start[data-v-e33988ac]{width:%?400?%;display:inline-block}.comment[data-v-e33988ac]{padding:%?20?%}.comment uni-textarea[data-v-e33988ac]{padding:%?30?%;background-color:#f5f5f5;width:100%}.bottom[data-v-e33988ac]{padding:%?20?% %?20?% %?40?%}.bottom .radio[data-v-e33988ac]{vertical-align:bottom;float:left}.bottom .dec[data-v-e33988ac]{color:#91949a;float:right}.button[data-v-e33988ac]{margin:%?20?%}body.?%PAGE?%[data-v-e33988ac]{background:#f5f5f5}',""]),t.exports=a},ad5b:function(t,a,e){"use strict";var i=e("ee27");Object.defineProperty(a,"__esModule",{value:!0}),a.default=void 0,e("96cf");var n=i(e("c964")),r=i(e("57df")),o={computed:{},components:{uniRate:r.default},data:function(){return{order_id:0,product_id:0,title:"",image:"",spec:"",rate:5,radio:!0,textarea:""}},onLoad:function(t){this.title=t.title,this.image=t.image,this.spec=t.spec,this.order_id=t.order_id,this.product_id=t.product_id},methods:{start:function(t){switch(this.rate=t.value,this.rate){case 3:this.radio=!1;break;case 5:this.radio=!0;break}},clickRadio:function(t){this.radio=!this.radio},input:function(t){this.textarea=t.detail.value},submit:function(){var t=this;return(0,n.default)(regeneratorRuntime.mark((function a(){var e,i;return regeneratorRuntime.wrap((function(a){while(1)switch(a.prev=a.next){case 0:e=t.$api.request("/order/comment","POST",{order_id:t.order_id,product_id:t.product_id,rate:t.rate,anonymous:t.radio?0:1,comment:t.textarea}),e&&(i=t.$api.prePage(),i.tabCurrentIndex&&(i.tabCurrentIndex=0),t,setTimeout((function(){i.pullDownRefresh(),uni.navigateBack()}),2e3));case 2:case"end":return a.stop()}}),a)})))()}}};a.default=o},c40b:function(t,a,e){var i=e("6327");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=e("4f06").default;n("b247180c",i,!0,{sourceMap:!1,shadowMode:!1})},fa59:function(t,a,e){"use strict";e.r(a);var i=e("2ce4"),n=e("6274");for(var r in n)"default"!==r&&function(t){e.d(a,t,(function(){return n[t]}))}(r);e("ffaa");var o,c=e("f0c5"),d=Object(c["a"])(n["default"],i["b"],i["c"],!1,null,"e33988ac",null,!1,i["a"],o);a["default"]=d.exports},ffaa:function(t,a,e){"use strict";var i=e("c40b"),n=e.n(i);n.a}}]);

+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-evaluate.8b8c1829.js View File

@@ -0,0 +1 @@
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-order-evaluate"],{2307:function(t,e,a){var i=a("e480");"string"===typeof i&&(i=[[t.i,i,""]]),i.locals&&(t.exports=i.locals);var n=a("4f06").default;n("021391f1",i,!0,{sourceMap:!1,shadowMode:!1})},6274:function(t,e,a){"use strict";a.r(e);var i=a("ad5b"),n=a.n(i);for(var r in i)"default"!==r&&function(t){a.d(e,t,(function(){return i[t]}))}(r);e["default"]=n.a},ad5b:function(t,e,a){"use strict";var i=a("ee27");Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0,a("96cf");var n=i(a("c964")),r=i(a("57df")),o={computed:{},components:{uniRate:r.default},data:function(){return{order_id:0,product_id:0,title:"",image:"",spec:"",rate:5,radio:!0,textarea:""}},onLoad:function(t){this.title=t.title,this.image=t.image,this.spec=t.spec,this.order_id=t.order_id,this.product_id=t.product_id},methods:{start:function(t){switch(this.rate=t.value,this.rate){case 3:this.radio=!1;break;case 5:this.radio=!0;break}},clickRadio:function(t){this.radio=!this.radio},input:function(t){this.textarea=t.detail.value},submit:function(){var t=this;return(0,n.default)(regeneratorRuntime.mark((function e(){var a,i;return regeneratorRuntime.wrap((function(e){while(1)switch(e.prev=e.next){case 0:a=t.$api.request("/order/comment","POST",{order_id:t.order_id,product_id:t.product_id,rate:t.rate,anonymous:t.radio?0:1,comment:t.textarea}),a&&(i=t.$api.prePage(),i.tabCurrentIndex&&(i.tabCurrentIndex=0),t,setTimeout((function(){i.pullDownRefresh(),uni.navigateBack()}),2e3));case 2:case"end":return e.stop()}}),e)})))()}}};e.default=o},b1d9:function(t,e,a){"use strict";var i=a("2307"),n=a.n(i);n.a},d37e:function(t,e,a){"use strict";var i={uniRate:a("57df").default},n=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("v-uni-view",{staticClass:"bg"},[a("v-uni-view",{staticClass:"header"},[a("v-uni-image",{staticClass:"image",attrs:{src:t.image}}),a("v-uni-view",{staticClass:"right"},[a("v-uni-view",{staticClass:"title"},[t._v(t._s(t.title))]),a("v-uni-view",{staticClass:"spec"},[t._v(t._s(t.spec))])],1)],1),a("v-uni-view",{staticClass:"rate"},[a("v-uni-view",{staticClass:"dec"},[t._v("描述相符")]),a("uni-rate",{staticClass:"start",attrs:{"active-color":"#e64340",margin:"10",size:"30",value:t.rate},on:{change:function(e){arguments[0]=e=t.$handleEvent(e),t.start.apply(void 0,arguments)}}})],1),a("v-uni-view",{staticClass:"comment"},[a("v-uni-textarea",{attrs:{maxlength:"300",placeholder:"写满20字,有机会被选为优质评价被更多人看到哦~","placeholder-class":"placeholder"},on:{input:function(e){arguments[0]=e=t.$handleEvent(e),t.input.apply(void 0,arguments)}}})],1),a("v-uni-view",{staticClass:"bottom"},[a("v-uni-radio",{staticClass:"radio",attrs:{color:"#e64340",checked:t.radio},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.clickRadio.apply(void 0,arguments)}}}),t._v("公开"),a("v-uni-view",{staticClass:"dec"},[t._v("公开头像昵称,大家可以看到我")])],1),a("v-uni-button",{staticClass:"button",attrs:{type:"warn"},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.submit.apply(void 0,arguments)}}},[t._v("Submit")])],1)},r=[];a.d(e,"b",(function(){return n})),a.d(e,"c",(function(){return r})),a.d(e,"a",(function(){return i}))},e480:function(t,e,a){var i=a("24fb");e=i(!1),e.push([t.i,'@charset "UTF-8";\n/* 页面左右间距 */\n/* 文字尺寸 */\n/*文字颜色*/\n/* 边框颜色 */\n/* 图片加载中颜色 */\n/* 行为相关颜色 */\n/* 背景颜色*/uni-page-body[data-v-30a8e1e2]{background:#f5f5f5}.bg[data-v-30a8e1e2]{margin:%?20?%;border-radius:%?20?%;background-color:#fff;padding-bottom:%?10?%}.header[data-v-30a8e1e2]{padding:%?20?%}.header .image[data-v-30a8e1e2]{width:%?120?%;height:%?120?%}.header .right[data-v-30a8e1e2]{display:inline-block;line-height:%?45?%;vertical-align:text-bottom;padding-bottom:%?10?%;width:%?550?%;padding-left:%?20?%}.header .right .title[data-v-30a8e1e2]{color:#707277;font-size:%?33?%;text-overflow:ellipsis;white-space:nowrap;overflow:hidden}.header .right .spec[data-v-30a8e1e2]{color:#91949a;font-size:%?30?%}.rate[data-v-30a8e1e2]{padding:0 %?20?% %?20?%}.rate .dec[data-v-30a8e1e2]{display:inline-block;color:#707277}.rate .start[data-v-30a8e1e2]{width:%?400?%;display:inline-block}.comment[data-v-30a8e1e2]{padding:%?20?%}.comment uni-textarea[data-v-30a8e1e2]{padding:%?30?%;background-color:#f5f5f5;width:100%}.bottom[data-v-30a8e1e2]{padding:%?20?% %?20?% %?40?%}.bottom .radio[data-v-30a8e1e2]{vertical-align:bottom;float:left}.bottom .dec[data-v-30a8e1e2]{color:#91949a;float:right}.button[data-v-30a8e1e2]{margin:%?20?%}body.?%PAGE?%[data-v-30a8e1e2]{background:#f5f5f5}',""]),t.exports=e},fa59:function(t,e,a){"use strict";a.r(e);var i=a("d37e"),n=a("6274");for(var r in n)"default"!==r&&function(t){a.d(e,t,(function(){return n[t]}))}(r);a("b1d9");var o,d=a("f0c5"),s=Object(d["a"])(n["default"],i["b"],i["c"],!1,null,"30a8e1e2",null,!1,i["a"],o);e["default"]=s.exports}}]);

+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-order.48b2f816.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-order.791eba5d.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-orderDetail.723fc3b6.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-orderDetail.8a407448.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-refund.25025ced.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-order-refund.d5c05d8e.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-product-product.16700c23.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-product-product.a1d624fc.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-public-login.15460be0.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-public-login.d31ba2ee.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-set-set.776c9a1f.js View File

@@ -0,0 +1 @@
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-set-set"],{"12bc":function(t,e,a){"use strict";a.r(e);var n=a("db4e"),i=a("c824");for(var l in i)"default"!==l&&function(t){a.d(e,t,(function(){return i[t]}))}(l);a("7376");var o,c=a("f0c5"),s=Object(c["a"])(i["default"],n["b"],n["c"],!1,null,"5354276a",null,!1,n["a"],o);e["default"]=s.exports},"4a64":function(t,e,a){var n=a("9286");"string"===typeof n&&(n=[[t.i,n,""]]),n.locals&&(t.exports=n.locals);var i=a("4f06").default;i("d76a23c2",n,!0,{sourceMap:!1,shadowMode:!1})},"4d8f":function(t,e,a){"use strict";var n=a("ee27");Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=n(a("f3f3")),l=a("2f62"),o={data:function(){return{}},methods:(0,i.default)({},(0,l.mapMutations)(["logout"]),{navTo:function(t){uni.navigateTo({url:t})},toLogout:function(){var t=this;uni.showModal({cancelText:"Cancel",confirmText:"OK",content:"确定要退出登录么",success:function(e){e.confirm&&(t.logout(),setTimeout((function(){uni.navigateBack()}),200))}})},switchChange:function(t){var e=t.detail.value?"打开":"关闭";this.$api.msg("".concat(e,"消息推送"))}})};e.default=o},7376:function(t,e,a){"use strict";var n=a("4a64"),i=a.n(n);i.a},9286:function(t,e,a){var n=a("24fb");e=n(!1),e.push([t.i,'@charset "UTF-8";\n/* 页面左右间距 */\n/* 文字尺寸 */\n/*文字颜色*/\n/* 边框颜色 */\n/* 图片加载中颜色 */\n/* 行为相关颜色 */\n/* 背景颜色*/uni-page-body[data-v-5354276a]{background:#f8f8f8}.list-cell[data-v-5354276a]{display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-align:baseline;-webkit-align-items:baseline;align-items:baseline;padding:%?20?% %?30?%;line-height:%?60?%;position:relative;background:#fff;-webkit-box-pack:center;-webkit-justify-content:center;justify-content:center}.list-cell.log-out-btn[data-v-5354276a]{margin-top:%?40?%}.list-cell.log-out-btn .cell-tit[data-v-5354276a]{color:#fa436a;text-align:center;margin-right:0}.list-cell.cell-hover[data-v-5354276a]{background:#fafafa}.list-cell.b-b[data-v-5354276a]:after{left:%?30?%}.list-cell.m-t[data-v-5354276a]{margin-top:%?16?%}.list-cell .cell-more[data-v-5354276a]{-webkit-align-self:baseline;align-self:baseline;font-size:%?32?%;color:#909399;margin-left:%?10?%}.list-cell .cell-tit[data-v-5354276a]{-webkit-box-flex:1;-webkit-flex:1;flex:1;font-size:%?30?%;color:#303133;margin-right:%?10?%}.list-cell .cell-tip[data-v-5354276a]{font-size:%?28?%;color:#909399}.list-cell uni-switch[data-v-5354276a]{-webkit-transform:translateX(%?16?%) scale(.84);transform:translateX(%?16?%) scale(.84)}body.?%PAGE?%[data-v-5354276a]{background:#f8f8f8}',""]),t.exports=e},c824:function(t,e,a){"use strict";a.r(e);var n=a("4d8f"),i=a.n(n);for(var l in n)"default"!==l&&function(t){a.d(e,t,(function(){return n[t]}))}(l);e["default"]=i.a},db4e:function(t,e,a){"use strict";var n,i=function(){var t=this,e=t.$createElement,a=t._self._c||e;return a("v-uni-view",{staticClass:"container"},[a("v-uni-view",{staticClass:"list-cell b-b m-t",attrs:{"hover-class":"cell-hover","hover-stay-time":50},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.navTo("/pages/userinfo/userinfo")}}},[a("v-uni-text",{staticClass:"cell-tit"},[t._v("Change Password")]),a("v-uni-text",{staticClass:"cell-more yticon icon-you"})],1),a("v-uni-view",{staticClass:"list-cell log-out-btn",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.toLogout.apply(void 0,arguments)}}},[a("v-uni-text",{staticClass:"cell-tit"},[t._v("Sign Out")])],1)],1)},l=[];a.d(e,"b",(function(){return i})),a.d(e,"c",(function(){return l})),a.d(e,"a",(function(){return n}))}}]);

+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-set-set.bba6e200.js View File

@@ -1 +0,0 @@
(window["webpackJsonp"]=window["webpackJsonp"]||[]).push([["pages-set-set"],{"06ac":function(t,e,n){"use strict";var a=n("dd3e"),i=n.n(a);i.a},"12bc":function(t,e,n){"use strict";n.r(e);var a=n("9890"),i=n("c824");for(var l in i)"default"!==l&&function(t){n.d(e,t,(function(){return i[t]}))}(l);n("06ac");var o,c=n("f0c5"),s=Object(c["a"])(i["default"],a["b"],a["c"],!1,null,"4f90d960",null,!1,a["a"],o);e["default"]=s.exports},4197:function(t,e,n){var a=n("24fb");e=a(!1),e.push([t.i,'@charset "UTF-8";\n/* 页面左右间距 */\n/* 文字尺寸 */\n/*文字颜色*/\n/* 边框颜色 */\n/* 图片加载中颜色 */\n/* 行为相关颜色 */\n/* 背景颜色*/uni-page-body[data-v-4f90d960]{background:#f8f8f8}.list-cell[data-v-4f90d960]{display:-webkit-box;display:-webkit-flex;display:flex;-webkit-box-align:baseline;-webkit-align-items:baseline;align-items:baseline;padding:%?20?% %?30?%;line-height:%?60?%;position:relative;background:#fff;-webkit-box-pack:center;-webkit-justify-content:center;justify-content:center}.list-cell.log-out-btn[data-v-4f90d960]{margin-top:%?40?%}.list-cell.log-out-btn .cell-tit[data-v-4f90d960]{color:#fa436a;text-align:center;margin-right:0}.list-cell.cell-hover[data-v-4f90d960]{background:#fafafa}.list-cell.b-b[data-v-4f90d960]:after{left:%?30?%}.list-cell.m-t[data-v-4f90d960]{margin-top:%?16?%}.list-cell .cell-more[data-v-4f90d960]{-webkit-align-self:baseline;align-self:baseline;font-size:%?32?%;color:#909399;margin-left:%?10?%}.list-cell .cell-tit[data-v-4f90d960]{-webkit-box-flex:1;-webkit-flex:1;flex:1;font-size:%?30?%;color:#303133;margin-right:%?10?%}.list-cell .cell-tip[data-v-4f90d960]{font-size:%?28?%;color:#909399}.list-cell uni-switch[data-v-4f90d960]{-webkit-transform:translateX(%?16?%) scale(.84);transform:translateX(%?16?%) scale(.84)}body.?%PAGE?%[data-v-4f90d960]{background:#f8f8f8}',""]),t.exports=e},"4d8f":function(t,e,n){"use strict";var a=n("ee27");Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var i=a(n("f3f3")),l=n("2f62"),o={data:function(){return{}},methods:(0,i.default)({},(0,l.mapMutations)(["logout"]),{navTo:function(t){uni.navigateTo({url:t})},toLogout:function(){var t=this;uni.showModal({content:"确定要退出登录么",success:function(e){e.confirm&&(t.logout(),setTimeout((function(){uni.navigateBack()}),200))}})},switchChange:function(t){var e=t.detail.value?"打开":"关闭";this.$api.msg("".concat(e,"消息推送"))}})};e.default=o},9890:function(t,e,n){"use strict";var a,i=function(){var t=this,e=t.$createElement,n=t._self._c||e;return n("v-uni-view",{staticClass:"container"},[n("v-uni-view",{staticClass:"list-cell b-b m-t",attrs:{"hover-class":"cell-hover","hover-stay-time":50},on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.navTo("/pages/userinfo/userinfo")}}},[n("v-uni-text",{staticClass:"cell-tit"},[t._v("修改密码")]),n("v-uni-text",{staticClass:"cell-more yticon icon-you"})],1),n("v-uni-view",{staticClass:"list-cell log-out-btn",on:{click:function(e){arguments[0]=e=t.$handleEvent(e),t.toLogout.apply(void 0,arguments)}}},[n("v-uni-text",{staticClass:"cell-tit"},[t._v("退出登录")])],1)],1)},l=[];n.d(e,"b",(function(){return i})),n.d(e,"c",(function(){return l})),n.d(e,"a",(function(){return a}))},c824:function(t,e,n){"use strict";n.r(e);var a=n("4d8f"),i=n.n(a);for(var l in a)"default"!==l&&function(t){n.d(e,t,(function(){return a[t]}))}(l);e["default"]=i.a},dd3e:function(t,e,n){var a=n("4197");"string"===typeof a&&(a=[[t.i,a,""]]),a.locals&&(t.exports=a.locals);var i=n("4f06").default;i("86b2a8d8",a,!0,{sourceMap:!1,shadowMode:!1})}}]);

+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-user-user.10188c0c.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-user-user.31e41caf.js
File diff suppressed because it is too large
View File


+ 0
- 1
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-userinfo-userinfo.4e5b7c2d.js
File diff suppressed because it is too large
View File


+ 1
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/build/h5/static/js/pages-userinfo-userinfo.add1dfed.js
File diff suppressed because it is too large
View File


+ 0
- 0
addons/unishop/uniapp/uni-shop/unpackage/dist/dev/.automator/mp-weixin/.automator.json View File


+ 118
- 0
application/admin/controller/unishop/Order.php View File

@@ -506,4 +506,122 @@ class Order extends Backend
}
return $this->view->fetch();
}

public function export(){
$order_model=New \app\admin\model\unishop\Order();
$list = $order_model
->alias('o')
->join('user', 'user.id = o.user_id')
->join('unishop_order_product', 'unishop_order_product.order_id = o.id')
->where([
'o.have_received'=>0,
'o.status'=>1
])
->field('
user.username,
user.nickname,
user.floor,
user.email,
GROUP_CONCAT(unishop_order_product.title) as title,
o.total_price,
SUM(unishop_order_product.number) as number,
o.remark')
->group("o.id")
->select();
$list = collection($list)->toArray();
$title = ['工号','姓名','楼层','邮箱','商品','金额','购买数量','备注'];
// Create new Spreadsheet object
$spreadsheet = new \PhpOffice\PhpSpreadsheet\Spreadsheet();
$sheet = $spreadsheet->getActiveSheet();
$sheet->setTitle("订单信息");
// 方法一,使用 setCellValueByColumnAndRow
//表头
//设置单元格内容
foreach ($title as $key => $value) {
// 单元格内容写入
$sheet->setCellValueByColumnAndRow($key + 1, 1, $value);
}
$row = 2; // 从第二行开始
foreach ($list as $item) {
$column = 1;
foreach ($item as $value) {
// 单元格内容写入
$sheet->setCellValueByColumnAndRow($column, $row, $value);
$column++;
}
$row++;
}
$sheet_two = $spreadsheet->createSheet(2)->setTitle('商品信息');
$title1=["商品名称","件数","单价","总价"];
$product=new \app\admin\model\unishop\OrderProduct();
$product_list = $product->alias("p")
->join("unishop_order","p.order_id = unishop_order.id")
->where([
'unishop_order.have_received'=>0,
'unishop_order.status'=>1
])
->field('
p.title,
SUM(p.number) num,
p.price,
SUM(p.number)*p.price as total,
p.product_id')
->group("p.id")
->select();
$product_list = collection($product_list)->toArray();
$product_arr=[];
foreach ($product_list as $tmp_product){
if (isset($product_arr[$tmp_product['product_id']])){
$product_arr[$tmp_product['product_id']]["num"]+=$tmp_product['num'];
$product_arr[$tmp_product['product_id']]["total"]+=$tmp_product['total'];
}else{
$product_arr[$tmp_product['product_id']]=$tmp_product;
}
}

foreach ($title1 as $key => $value) {
// 单元格内容写入
$sheet_two->setCellValueByColumnAndRow($key + 1, 1, $value);
}
$row=2;
foreach ($product_arr as $item) {
unset($item['product_id']);
$column = 1;
foreach ($item as $value) {
// 单元格内容写入
$sheet_two->setCellValueByColumnAndRow($column, $row, $value);
$column++;
}
$row++;
}

$file_name="导出订单.xlsx";
// Redirect output to a client’s web browser (Xlsx)
header('Content-Type: application/vnd.openxmlformats-officedocument.spreadsheetml.sheet');
header('Content-Disposition: attachment;filename='.$file_name);
header('Cache-Control: max-age=0');
// If you're serving to IE 9, then the following may be needed
header('Cache-Control: max-age=1');

// If you're serving to IE over SSL, then the following may be needed
header('Expires: Mon, 26 Jul 1997 05:00:00 GMT'); // Date in the past
header('Last-Modified: ' . gmdate('D, d M Y H:i:s') . ' GMT'); // always modified
header('Cache-Control: cache, must-revalidate'); // HTTP/1.1
header('Pragma: public'); // HTTP/1.0

$writer = \PhpOffice\PhpSpreadsheet\IOFactory::createWriter($spreadsheet, 'Xlsx');
$writer->save('php://output');
exit;
}

public function finish(){
$this->model->save(
['have_received'=>time(),
"have_delivered"=>time()],
['have_received'=>0,
'status'=>1]
);
$this->success("提交成功", null);

}
}

+ 1
- 1
application/admin/view/unishop/market/flash_sale/index.html View File

@@ -4,7 +4,7 @@
}
</style>
<div class="panel panel-default panel-intro">
{:build_heading('unishop/market/flash_sale')}
<!-- {:build_heading('unishop/market/flash_sale')}-->

<div class="panel-body">
<div id="myTabContent" class="tab-content">


+ 2
- 0
application/admin/view/unishop/order/index.html View File

@@ -20,6 +20,8 @@
<!-- <a href="javascript:;" class="btn btn-success btn-add {:$auth->check('unishop/order/add')?'':'hide'}" title="{:__('Add')}" ><i class="fa fa-plus"></i> {:__('Add')}</a>-->
<a href="javascript:;" class="btn btn-success btn-edit btn-disabled disabled {:$auth->check('unishop/order/edit')?'':'hide'}" title="{:__('Edit')}" ><i class="fa fa-pencil"></i> {:__('Edit')}</a>
<a href="javascript:;" class="btn btn-danger btn-del btn-disabled disabled {:$auth->check('unishop/order/del')?'':'hide'}" title="{:__('Delete')}" ><i class="fa fa-trash"></i> {:__('Delete')}</a>
<a href="javascript:;" class="btn btn-success btn-export title="{:__('导出')}" ><i class="fa fa-export"></i> {:__('导出')}</a>
<a href="javascript:;" class="btn btn-success btn-finish title="{:__('完成订单')}" ><i class="fa fa-export"></i> {:__('完成订单')}</a>
<!-- <a href="javascript:;" class="btn btn-danger btn-import {:$auth->check('unishop/order/import')?'':'hide'}" title="{:__('Import')}" id="btn-import-file" data-url="ajax/upload" data-mimetype="csv,xls,xlsx" data-multiple="false"><i class="fa fa-upload"></i> {:__('Import')}</a>-->

<!-- <div class="dropdown btn-group {:$auth->check('unishop/order/multi')?'':'hide'}">-->


+ 13
- 0
public/assets/js/backend/unishop/order.js View File

@@ -155,6 +155,19 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin

// 为表格绑定事件
Table.api.bindevent(table);
$(document).on("click", ".btn-export", function () {
window.location.href="order/export"
});
$(document).on("click", ".btn-finish", function () {
// window.location.href="order/finish"
Fast.api.ajax({
url:"unishop/order/finish",
loading:false
}, function(data, ret){
//成功回调
// layer.msg('操作成功!');
});
});
},
recyclebin: function () {
// 初始化表格参数配置


Loading…
Cancel
Save