Merge branch 'old' into wpf

# Please enter a commit message to explain why this merge is necessary,
# especially if it merges an updated upstream into a topic branch.
#
# Lines starting with '#' will be ignored, and an empty message aborts
# the commit.
This commit is contained in:
weipengfei 2023-09-28 15:47:03 +08:00
commit e8008930fe
86 changed files with 7856 additions and 4627 deletions

View File

@ -161,9 +161,10 @@
jpushModule.initJPushService()
jpushModule.addConnectEventListener(result => {
let connectEnable = result.connectEnable
// console.log("jpush", connectEnable)
console.log("jpush连接", connectEnable)
})
//
// jpushModule.setAlias({
// 'alias': uni.getStorageSync('userId'),
@ -221,7 +222,8 @@
},
onShow() {
let that = this
// H5
if (this.$store.state.app.token) {

View File

@ -5,7 +5,7 @@ import request from "@/utils/request.js";
*
*/
export function cloudWarehouse(data) {
return request.get("store/product/cloudWarehouse", data);
return request.get("store/product/cloudWarehouse", data, { noAuth: true });
}
/**
* 获取云仓分类
@ -290,4 +290,23 @@ export function village(data) {
*/
export function brigade(data) {
return request.get('v2/system/brigade', data, { noAuth: true });
}
}
/*
生产 -- 获取商户保证金信息支付接口
*/
export function paymerchant() {
return request.post(`user/margin`,{});
}
/*
生产 -- 获取商户保证金信息接口
*/
export function merchant(data) {
return request.get(`store/merchant/margin`, data);
}
//获取保证金缴纳列表
export function marginlist(data) {
return request.get(`user/margin/list`,data);
}

View File

@ -7,7 +7,7 @@
// +----------------------------------------------------------------------
// | Author: CRMEB Team <admin@crmeb.com>
// +----------------------------------------------------------------------
import request from "@/utils/request.js";
import request from "@/utils/requesta.js";
/** 获取话题分类*/
export function getTopicList() {
@ -83,7 +83,9 @@ export function videoList(data) {
}
/**自己的视频列表*/
export function deoList(id) {
return request.get(`community/show/${id}`);
return request.get(`community/show/${id}`, {
noAuth: true
});
}
export function myVideoList(id,data) {

View File

@ -303,8 +303,8 @@ export function getDeliveryType(merId) {
/*
商品 -- 获取交易协议内容
*/
export function business() {
return request.get(`business/agree?type=business_apply_agree`, {}, {
export function business(data) {
return request.get(`business/agree`, data, {
noAuth: true
});
}
@ -319,5 +319,5 @@ export function intention(data) {
商品 -- 同意提交申请
*/
export function intentionbus(data) {
return request.post(`intention/business`, {});
return request.post(`intention/business`, data);
}

View File

@ -1,4 +1,5 @@
import request from "@/utils/request.js";
import requestb from "@/utils/requestb.js";
/**
* 扫码查询商品
@ -577,6 +578,8 @@ export function vicinityStoreApi(data) {
/*
商家入驻 -- 获取商户入驻申请协议内容
*/
export function agreeiness() {
return request.get(`business/agree?type=sys_intention_agree`, {}, { noAuth: true });
export function agreeiness(data) {
return request.get(`business/agree`, data, {
noAuth: true
});
}

View File

@ -16,3 +16,12 @@ export function getGXconfig(data) {
return request.get("global/config", data);
}
/**
* 获取商城小程序信息
*/
export function miniapp(data) {
return request.get("miniapp/version?version=1", data);
}

View File

@ -8,6 +8,8 @@
// | Author: CRMEB Team <admin@crmeb.com>
// +----------------------------------------------------------------------
import request from "@/utils/request.js";
import request1 from "@/utils/requestb.js";
import Cache from '@/utils/cache'
/**
* 获取版本信息
@ -721,3 +723,10 @@ export function getBillDetil() {
return request.get(`mer/financial_record`)
}
//获取商户入驻所签署公司
export function merstreet(data) {
return request1.get(`company/street_company`, data);
}

View File

@ -2,7 +2,7 @@
<view class="orderGoods" :style="viewColor">
<view class='goodWrapper' :class="'item'+orderData.order_type">
<view v-if="orderData.order_type == 1" class="title acea-row row-between-wrapper">
<view class="item-status" :class="'status'+evaluate">{{evaluate == 0 ? '待核销' : '已核销'}}</view>
<view class="item-status" :class="'status'+evaluate">{{evaluate == 7 ? '待核销' : '已核销'}}</view>
<view v-if="evaluate != 0 && orderData.verify_time" class="item-date">{{orderData.verify_time}}</view>
</view>
<view v-for="(item,index) in cartInfo" :key="index">

View File

@ -108,7 +108,6 @@
type = 'alipayQr';
// #endif
} else if (paytype == 'creditBuy') {
console.log('123123');
type = 'creditBuy'
}
if (!that.order_id) return that.$util.Tips({
@ -371,6 +370,10 @@
break;
// #endif
}
}).catch(err => {
uni.hideLoading();
return that.$util.Tips({

View File

@ -6,33 +6,35 @@ let openPlantGrass = '-openPlantGrass-'
let httpApi
let httpApiTwo
let httpApiThree
// 网络接口修改此字符 小程序域名要求https
// let httpApi = 'http://192.168.31.110:8324' // 测试
if (process.env.NODE_ENV === "development") {
// httpApi = 'https://shop.lihaink.cn' // 生产
httpApi = "https://crmeb-test.shop.lihaink.cn"
// httpApi = "http://192.168.0.222"
// httpApi = "http://192.168.0.108:8325"
// httpApi = 'http://192.168.0.108:8325'
// #ifdef MP-WEIXIN
httpApiTwo = "https://nk.lihaink.cn"
httpApiThree = 'http://ceshi-oa.lihaink.cn'
// #endif
// #ifdef H5
// httpApiTwo = "baseUrl" // h5跨域配置
httpApiTwo = "https://nk.lihaink.cn" // h5跨域配置
// httpApiThree = 'baseUrlTest' // h5跨域配置
// #endif
} else if (process.env.NODE_ENV === 'production') {
httpApi = 'https://shop.lihaink.cn' // 生产
let httpApiFour
// httpApi = "https://crmeb-test.shop.lihaink.cn"
httpApiTwo = 'https://nk.lihaink.cn' // 生产
httpApiThree = 'http://ceshi-oa.lihaink.cn' //生产
// 在打包之前请检查当前环境是否正确
const env = 'dev'; // 开发
// const env = 'prod'; // 生产
// const env = 'prew'; // 预上线
switch (env) {
case 'prod':
httpApi = 'https://shop.lihaink.cn' // 生产
httpApiTwo = 'https://nk.lihaink.cn'
httpApiThree = 'http://ceshi-oa.lihaink.cn'
httpApiFour = 'https://worker-task.lihaink.cn'
break;
case 'prew':
httpApi = 'https://test.shop.lihaink.cn' //预发布环境
httpApiTwo = "https://nk.lihaink.cn"
httpApiThree = 'http://ceshi-oa.lihaink.cn'
httpApiFour = 'https://preview-worker-task.lihaink.cn'
break;
default:
httpApi = "https://crmeb-test.shop.lihaink.cn" // 测试
httpApiTwo = "https://nk.lihaink.cn"
httpApiThree = 'http://ceshi-oa.lihaink.cn'
httpApiFour = 'https://ceshi-worker-task.lihaink.cn'
}
// httpApi = 'https://shop.lihaink.cn' // 生产
// httpApiTwo = 'https://nk.lihaink.cn' // 生产
// 聊天接口修改此字符 小程序聊天要求wss 例如wss://mer.crmeb.net
// let wsApi = 'ws://192.168.3.20:8324'
@ -45,11 +47,13 @@ module.exports = {
HTTP_REQUEST_URL: httpApi,
HTTP_REQUEST_URL_TWO: httpApiTwo,
HTTP_REQUEST_URL_THREE: httpApiThree,
HTTP_REQUEST_URL_FOUR: httpApiFour,
VUE_APP_WS_URL: `${wsApi}?type=user`,
// #endif
// #ifdef H5
//H5接口是浏览器地址
HTTP_REQUEST_URL_FOUR: httpApiFour|| window.location.protocol + "//" + window.location.host,
HTTP_REQUEST_URL: httpApi || window.location.protocol + "//" + window.location.host,
HTTP_REQUEST_URL_TWO: httpApiTwo || window.location.protocol + "//" + window.location.host,
// 聊天长连接地址

View File

@ -130,6 +130,7 @@ export function Modal(title = '提示', content = '这是一个模态弹窗!', o
}) {
return new Promise((reslove, reject) => {
uni.showModal({
...obj,
title: title,
content: content,
success: (res) => {

View File

@ -2,8 +2,8 @@
"name" : "惠农生活",
"appid" : "__UNI__3A527D1",
"description" : "",
"versionName" : "1.4.1",
"versionCode" : 141,
"versionName" : "1.4.7",
"versionCode" : 147,
"transformPx" : false,
/* 5+App */
"app-plus" : {
@ -31,7 +31,8 @@
"UniMP" : {
"description" : "uni小程序"
},
"Maps" : {}
"Maps" : {},
"Push" : {}
},
"safearea" : {
"bottom" : {
@ -103,13 +104,13 @@
"weixin" : {
"__platform__" : [ "ios", "android" ],
"appid" : "wx9d68c92b550ddd1e",
"UniversalLinks" : "https://mer.crmeb.net/"
"UniversalLinks" : "https://shop.lihaink.cn/"
}
},
"share" : {
"weixin" : {
"appid" : "wx9d68c92b550ddd1e",
"UniversalLinks" : "https://mer.crmeb.net/"
"UniversalLinks" : "https://shop.lihaink.cn/"
}
},
"geolocation" : {
@ -120,7 +121,8 @@
}
},
"oauth" : {},
"ad" : {}
"ad" : {},
"push" : {}
},
"icons" : {
"android" : {
@ -160,8 +162,8 @@
},
"nativePlugins" : {
"JG-JCore" : {
"JPUSH_APPKEY_IOS" : "b5f679f4357018605ea6fd2e",
"JPUSH_CHANNEL_IOS" : "",
"JPUSH_APPKEY_IOS" : "8a5efd65cda14fafa6e64ad3",
"JPUSH_CHANNEL_IOS" : "8a5efd65cda14fafa6e64ad3",
"JPUSH_APPKEY_ANDROID" : "b5f679f4357018605ea6fd2e",
"JPUSH_CHANNEL_ANDROID" : "",
"__plugin_info__" : {
@ -178,7 +180,7 @@
"JPUSH_APPKEY_IOS" : {
"des" : "[iOS]极光portal配置应用信息时分配的AppKey",
"key" : "JCore:APP_KEY",
"value" : "7869a2f94b120cfb4431b96f"
"value" : "daebe19b547c43128796a078"
},
"JPUSH_CHANNEL_IOS" : {
"des" : "[iOS]用于统计分发渠道不需要可填默认值developer-default",
@ -199,9 +201,9 @@
}
},
"JG-JPush" : {
"JPUSH_ISPRODUCTION_IOS" : "",
"JPUSH_ISPRODUCTION_IOS" : "true",
"JPUSH_ADVERTISINGID_IOS" : "",
"JPUSH_DEFAULTINITJPUSH_IOS" : "",
"JPUSH_DEFAULTINITJPUSH_IOS" : "true",
"JPUSH_OPPO_APPKEY" : "",
"JPUSH_OPPO_APPID" : "",
"JPUSH_OPPO_APPSECRET" : "",

View File

@ -1,32 +1,32 @@
{
"pages": [
//#ifdef APP-PLUS
//
{
"path": "pages/guide/judge",
"style": {
"enablePullDownRefresh": false,
"onReachBottomDistance": 100,
"navigationStyle": "custom",
"app-plus": {
"contentAdjust": false,
"bounce": "none"
//#ifdef APP-PLUS
//
{
"path": "pages/guide/judge",
"style": {
"enablePullDownRefresh": false,
"onReachBottomDistance": 100,
"navigationStyle": "custom",
"app-plus": {
"contentAdjust": false,
"bounce": "none"
}
}
}
},
{
"path": "pages/guide/guide",
"style": {
"enablePullDownRefresh": false,
"onReachBottomDistance": 100,
"navigationStyle": "custom",
"app-plus": {
"contentAdjust": false,
"bounce": "none"
},
{
"path": "pages/guide/guide",
"style": {
"enablePullDownRefresh": false,
"onReachBottomDistance": 100,
"navigationStyle": "custom",
"app-plus": {
"contentAdjust": false,
"bounce": "none"
}
}
}
},
// #endif
},
// #endif
//pageshttps://uniapp.dcloud.io/collocation/pages
{
"path": "pages/index/index",
@ -124,7 +124,8 @@
}, {
"path": "pages/moreProject/moreProject",
"style": {
"navigationBarTitleText": "更多功能",
"navigationBarTitleText": "商户平台",
"navigationStyle": "custom",
"enablePullDownRefresh": false
}
@ -146,7 +147,16 @@
"navigationStyle": "custom"
}
}
],
,{
"path" : "pages/margin/margin",
"style" :
{
"navigationBarTitleText":"缴纳保证金",
"enablePullDownRefresh": false
}
}
],
"subPackages": [{
"root": "pages/goods_cate",
"name": "goods_cate",
@ -829,7 +839,7 @@
}, {
"path": "payment/payment",
"style": {
"navigationBarTitleText": "",
"navigationBarTitleText": "支付",
"enablePullDownRefresh": false
}
@ -981,6 +991,8 @@
{
"path": "settled/index",
"style": {
"navigationStyle": "custom",
"navigationBarTitleText": "商家入驻"
}
}, {
@ -1122,18 +1134,6 @@
"navigationBarTitleText": "商品管理",
"enablePullDownRefresh": true
}
},{
"path": "transactionApplication/index",
"style": {
"navigationBarTitleText": "交易申请",
"enablePullDownRefresh": false
}
},{
"path": "transactionApplication/application",
"style": {
"navigationBarTitleText": "申请记录",
"enablePullDownRefresh": false
}
},
{
"path": "goodsOnSale/index",

View File

@ -146,7 +146,7 @@
</view>
</view>
<view style="height:120upx;"></view>
<view class="footer acea-row row-right row-middle" v-if="goname != 'looks'" style="margin-bottom: var(--status-bar-height);">
<view class="footer acea-row row-right row-middle" v-if="goname != 'looks'" style="padding-bottom: var(--status-bar-height);">
<view class="more"></view>
<view class="bnt cancel" v-if="orderInfo.pay_type == 8 && orderInfo.status == 12" @click="tongyi(order_id,1)">
同意
@ -376,8 +376,11 @@
/*核销订单*/
goCancellation() {
let that = this;
// uni.navigateTo({
// url: '/pages/admin/cancellate_result/index?mer_id='+that.mer_id+'&code='+that.orderInfo.verify_code,
// })
uni.navigateTo({
url: '/pages/admin/cancellate_result/index?mer_id='+that.mer_id+'&code='+that.orderInfo.verify_code,
url: `/pages/admin/order_cancellation/index?mer_id=${that.mer_id}`
})
// uni.showModal({
// title: '',

View File

@ -553,6 +553,7 @@
uni.navigateTo({
url: `/pages/admin/orderDetail/index?id=${item.order_id}&mer_id=${item.mer_id}`
})
},
toRefundDetail(item) {
uni.navigateTo({

View File

@ -131,8 +131,12 @@
// console.log(self.verify_code);
verifierOrder(self.mer_id,self.verify_code)
.then(res => {
// uni.navigateTo({
// url: '/pages/admin/cancellate_result/index?code='+self.verify_code+'&mer_id='+self.mer_id
// });
uni.navigateTo({
url: '/pages/admin/cancellate_result/index?code='+self.verify_code+'&mer_id='+self.mer_id
url: '/pages/admin/orderList/index?types=2'+'&mer_id='+self.mer_id
});
})
.catch(res => {
@ -161,8 +165,11 @@
scanType: ["qrCode", "barCode"]
}).then(res=>{
this.verify_code = res.resultStr
// uni.navigateTo({
// url: '/pages/admin/cancellate_result/index?code='+self.verify_code+'&mer_id='+self.mer_id
// });
uni.navigateTo({
url: '/pages/admin/cancellate_result/index?code='+self.verify_code+'&mer_id='+self.mer_id
url: '/pages/admin/orderList/index?types=2'+'&mer_id='+self.mer_id
});
// this.codeChange();
}).catch(res => {

View File

@ -62,6 +62,9 @@
serviceList,
serviceUserList
} from "@/api/user";
import {
getUserInfo
} from '@/api/user.js';
import { mapGetters } from "vuex";
export default {
name: "CustomerList",
@ -88,13 +91,9 @@
computed: mapGetters(['isLogin','viewColor']),
onLoad(optios) {
this.type = optios.type;
this.mer_id = optios.mer_id;
if(this.isLogin){
this.getList(this.mer_id)
} else {
this.isAuto = true;
this.isShowAuth = true
}
this.getindex()
},
onShow(option) {
if(this.isLogin){
@ -119,6 +118,21 @@
this.clear = true;
},
methods: {
//
getindex(){
getUserInfo().then(res => {
this.mer_id = res.data.service.mer_id;
if(this.isLogin){
this.getList(this.mer_id)
} else {
this.isAuto = true;
this.isShowAuth = true
}
// this.getList(this.mer_id)
// this.getList(res.data.service.mer_id, true);
});
},
onLoadFun() {
this.isShowAuth = false;
this.getList(this.mer_id);
@ -217,7 +231,7 @@
},
};
</script>
<style lang="scss">
<style lang="scss" scoped>
.CustomerList {
.spin {
display: block;

View File

@ -109,8 +109,8 @@
</view>
<view class="content_bootm">
<view class="content_bootm_txt">
查看TA提到的宝贝(2)
<view class="content_bootm_txt" v-if="objinfo.product_list.length>0">
查看TA提到的宝贝({{objinfo.product_list.length}})
</view>
@ -124,7 +124,7 @@
</view>
</view>
<button class="release_btn button" v-if="objinfo.mer_status==1&&type==1" @click="submit(objinfo)">发布</button>
<!-- <button class="release_btn button" v-if="objinfo.mer_status==1&&type==1" @click="submit(objinfo)">发布</button> -->
</view>
</template>

View File

@ -227,6 +227,7 @@
import emptyPage from '@/components/emptyPage.vue';
import {
entrustlist,
addEntrustCart,
finishchain,
checkchain
} from '@/api/sale.js'
@ -365,9 +366,25 @@
},
//
order(item) {
uni.navigateTo({
url: '/pages/commissionedSales/delegation_details/index?id=' + item.community_id + '&type=1'
})
// uni.navigateTo({
// url: '/pages/commissionedSales/delegation_details/index?id=' + item.community_id + '&type=1'
// })
addEntrustCart({
community_id: item.community_id
}).then(res => {
if (res.status == 200) {
this.$util.Tips({
title: res.message,
icon: 'success'
})
uni.navigateTo({
url: '/pages/users/order_confirm/index?cartId=' + res.data.cart_id.toString()
})
}
})
},
//
deteragrss(item) {

View File

@ -1,11 +1,9 @@
<template>
<view class="gather">
<view v-if="isFshow">
<view class="site-box flex_a_c_j_sb" :style="{ 'opacity': backColor,}" @click="selectLocation">
<view class="site-box flex_a_c_j_sb" :style="{ opacity: backColor }" @click="selectLocation">
<view :class="['place_wrapper', 'flex_a_c', isFshow ? 'sitebox' : '']" @click="selectLocation">
<view :class="['iconfont', 'icon-weizhi', isFshow ? 'sitebox' : '']" style=" margin-left: 20rpx">
<view :class="['iconfont', 'icon-weizhi', isFshow ? 'sitebox' : '']" style="margin-left: 20rpx">
</view>
<view class="town_name">{{ street }}</view>
</view>
@ -13,24 +11,20 @@
<view :class="['iconfont', 'icon-xiaoxi', isFshow ? 'sitebox' : '']"></view>
</navigator>
</view>
</view>
<view class="" v-if="!isFshow">
<view class="site-box1 flex_a_c_j_sb">
<view class="place_wrapper flex_a_c" @click="selectLocation">
<view class="iconfont icon-weizhi"></view>
<view class="town_name">{{street}}</view>
<view class="town_name">{{ street }}</view>
</view>
<navigator url="/pages/chat/customer_list/index?type=0" hover-class="none">
<view class="iconfont icon-xiaoxi" style="color:#fff;"> </view>
<view class="iconfont icon-xiaoxi" style="color: #fff"> </view>
</navigator>
</view>
</view>
<zbpSwiper :isSelectPlace="true" :location_Arr="locationArr" :town="street" ></zbpSwiper>
<zbpSwiper :isSelectPlace="true" :location_Arr="locationArr" :town="street"></zbpSwiper>
<u-empty :show="jurisdiction" mode="permission" :text="emptyText"
icon="http://cdn.uviewui.com/uview/empty/permission.png"></u-empty>
<view class="business com special_work" v-if="jurisdiction == false">
@ -64,8 +58,7 @@
<view class="content">
<u-transition v-for="(item, index) in AllMenuList" :key="item.name" show>
<view class="examine" @click="pushMenu(item)">
<image class="icon_img" :src="item.icon" mode="aspectFit">
</image>
<image class="icon_img" :src="item.icon" mode="aspectFit"> </image>
<u-icon class="icon" name="plus-circle-fill"></u-icon>
<text class="text">{{ item.name }}</text>
</view>
@ -73,8 +66,7 @@
</view>
</view>
<u-picker :defaultIndex="[0,0]" :show="showPicker" ref="uPicker" :columns="columnData" @confirm="confirm"
<u-picker :defaultIndex="[0, 0]" :show="showPicker" ref="uPicker" :columns="columnData" @confirm="confirm"
@cancel="showPicker = false" @change="changeHandler" keyName="name"></u-picker>
<!-- <m-tabbar native>
<template v-slot:tabbar_index_2>
@ -126,7 +118,7 @@
components: {
mTabbar,
zbpSwiper
},
data() {
return {
@ -141,7 +133,6 @@
},
prefix: 'https://lihai001.oss-cn-chengdu.aliyuncs.com/public/kk/luzhou/static4/11/',
isShow: false,
isFshow: false,
street: '',
//
@ -150,6 +141,7 @@
AllMenuList: [{
name: '商户平台',
icon: '/static/applet/shop_app.png',
// data: "__UNI__1EE148C",
data: '/pages/moreProject/moreProject',
type: 2,
},
@ -159,12 +151,66 @@
data: '__UNI__B5B1EDD',
type: 1,
},
{
name: '农业咨询',
icon: '/static/applet/ny.png',
data: {
id: '__UNI__9620511',
url: 'https://ceshi-worker-task.lihaink.cn/api/common/getMiniProgramInfo?name=nongye',
},
type: 3,
},
{
name: '教育咨询',
icon: '/static/applet/jy.png',
data: {
id: '__UNI__7AA205C',
url: 'https://ceshi-worker-task.lihaink.cn/api/common/getMiniProgramInfo?name=jiaoyu',
},
type: 3,
},
{
name: '法律咨询',
icon: '/static/applet/fl.png',
data: {
id: '__UNI__358D505',
url: 'https://ceshi-worker-task.lihaink.cn/api/common/getMiniProgramInfo?name=falv',
},
type: 3,
},
{
name: '情感咨询',
icon: '/static/applet/qg.png',
data: {
id: '__UNI__8080F14',
url: 'https://ceshi-worker-task.lihaink.cn/api/common/getMiniProgramInfo?name=qinggan',
},
type: 3,
},
{
name: '种植分析',
icon: '/static/applet/zz.png',
data: {
id: '__UNI__9EDFE40',
url: 'https://ceshi-worker-task.lihaink.cn/api/common/getMiniProgramInfo?name=zhongzhi',
},
type: 3,
},
{
name: '养殖分析',
icon: '/static/applet/yz.png',
data: {
id: '__UNI__EEA7DC9',
url: 'https://ceshi-worker-task.lihaink.cn/api/common/getMiniProgramInfo?name=yangzhi',
},
type: 3,
}
],
nowMenuList: [],
street: '',
showPicker: false,
columnData: [],
isFshow: false,
backColor: 'rgba(252, 252, 252, 0)'
};
@ -225,9 +271,7 @@
} else if (scrollTop > 100) {
this.backColor = 'rgba(252, 252, 252, 1)'
this.isFshow = true
}
},
// #endif
@ -286,15 +330,7 @@
}
},
clickMenu(e, data) {
switch (e) {
case 1:
this.getUniMp(data);
break;
case 2:
this.navigator(data);
break;
}
this.getUniMp(e, data);
},
//
pushMenu(data) {
@ -315,16 +351,35 @@
this.editFlag = false;
uni.setStorageSync('gatherNowMenuList', JSON.stringify(this.nowMenuList));
},
getUniMp(appid) {
console.log('点击供销平台');
getUniMp(type, data) {
// #ifdef APP-PLUS
uniMP.loadMP(appid);
switch (type) {
case 1:
uniMP.loadMP(data);
break;
// case 2: uniMP.loadMPx(data); break;
case 2:
this.navigator(data);
break;
case 3:
uniMP.loadMPurl(data);
break;
}
return;
// #endif
uni.showToast({
icon: 'none',
title: 'H5不支持打开小程序'
})
// #ifdef H5
if (type == 2) {
this.navigator(data);
} else {
uni.showToast({
icon: 'none',
title: 'H5不支持打开小程序'
})
}
// #endif
},
changeHandler(e) {
const {
@ -419,6 +474,7 @@
let that = this;
getUserInfo().then(res => {
that.userInfoData = res.data;
that.$store.commit('SET_USERINFO', res.data);
// console.log(res.data.service);
if (res.data.service == null) {
// console.log('123');
@ -459,7 +515,8 @@
opacity: 1;
}
}
.site-box1 {
.site-box1 {
width: 706rpx;
/* #ifdef MP || APP-PLUS */
height: 160rpx;
@ -471,25 +528,26 @@
position: absolute;
top: 45rpx;
left: 20rpx;
z-index: 999;
//
.place_wrapper {
color: #fff;
margin-right: 0rpx;
font-size: 30rpx;
.town_name {
margin-left: 21rpx;
}
}
.iconfont {
font-size: 35.09rpx;
}
}
.site-box {
width: 100%;
/* #ifdef MP || APP-PLUS */
@ -510,7 +568,7 @@
padding-top: 25rpx;
/* #endif */
// background-color: #e5e5e5;
background: url('@/static/images/bg2.png') no-repeat;
background: url("@/static/images/bg2.png") no-repeat;
background-size: 100% 100%;
padding-right: 20rpx;

View File

@ -290,8 +290,8 @@
<view v-if="description.content && description.content.title" class="title">
{{description.content.title}}
</view>
<view v-if="description.content && description.content.image" class="pictures">
<image v-for="(item,index) in description.content.image" :key="index" :src="item">
<view v-if="description.content && description.content.image" class="pictures" style="background-color: #fff;">
<image v-for="(item,index) in description.content.image" :key="index" :src="item" mode="aspectFit">
</image>
</view>
</view>
@ -704,11 +704,6 @@
that.getConfig();
uni.hideLoading();
},
onHide() {
this.CartCount = 0
},
/**
* 用户点击右上角分享
*/

View File

@ -129,6 +129,7 @@
getIndexData,
getDiy,
getArticleList,
cloudWarehouse,
getArticleCategoryLists
} from '@/api/api.js'
import {
@ -332,7 +333,7 @@
//
itemTap(item) {
if (this.userid) {
if (item.video_link.length > 0) {
uni.navigateTo({
// #ifdef MP || H5
@ -347,11 +348,7 @@
url: `/pages/plantGrass/plant_detail/index?id=${item.community_id}`
})
}
} else {
this.isAuto = true;
this.isShowAuth = true
}
},
//
authColse: function(e) {

343
pages/margin/margin.vue Normal file
View File

@ -0,0 +1,343 @@
<template>
<view class="">
<view class="info">
<view class="bg"></view>
<view class="card">
<view class="title">店铺保证金信息</view>
<view class="item">
<text>已缴纳保证金</text>
<text>{{merchant_Data.paid_margin}}</text>
</view>
<view class="item">
<text>剩余缴纳保证金</text>
<text>{{merchant_Data.unpaid_margin}}</text>
</view>
<view class="item">
<text>缴纳店铺账户</text>
<text>{{merchant_Data.mer_name}}</text>
</view>
</view>
</view>
<view class="price">
<view class="title">缴纳金额</view>
<view class="tab">
<view class="item active" style="margin: 0;">{{merchant_Data.margin}}</view>
</view>
<button class="btn" @click="paydecimal">缴纳</button>
</view>
<!-- <view class="tip">
<view class="title">注意事项</view>
<view class="text">充值后帐户的金额不能提现可用于商城消费使用佣金导入账户之后不能再次导出不可提现账户充值出现问题可联系商城客服也可拨打商城客服热线<text @click="copyPhone('4008888888')">4008888888</text>
</view>
</view> -->
<view class="content-order" v-for="(item,i ) in productList">
<view class="">订单编号{{item.order_sn}}</view>
<view class="">支付金额{{item.total_price}}</view>
<view class="">支付状态{{item.paid==1?'已支付':'待支付'}}</view>
<view class="">支付时间{{item.pay_time}}</view>
</view>
<view class='loadingicon acea-row row-center-wrapper' v-if='productList.length > 0'>
<text class='loading iconfont icon-jiazai' :hidden='loading==false'></text>{{loadTitle}}
</view>
</view>
</template>
<script>
import {
merchant,
paymerchant,
marginlist
} from '@/api/api.js'
export default {
data() {
return {
mer_id: 0,
merchant_Data: {},
where: {
page: 1,
limit: 10
},
productList: [],
loadend: false,
loading: false,
loadTitle: '加载更多',
}
},
onLoad(e) {
this.mer_id = e.mer_id
this.decimal()
this.list(true)
},
onReachBottom() {
if (this.productList.length > 0) {
setTimeout(() => {
this.list(false);
}, 1000)
}
},
methods: {
list(isPage) {
let that = this;
if (that.loadend) return;
if (that.loading) return;
if (isPage === true) that.$set(that, 'productList', []);
that.loading = true;
that.loadTitle = '';
marginlist(that.where).then(res => {
let list = res.data.list;
let productList = that.$util.SplitArray(list, that.productList);
let loadend = list.length < that.where.limit;
that.loadend = loadend;
that.loading = false;
that.loadTitle = loadend ? '已全部加载' : '加载更多';
setTimeout(() => {
that.$set(that, 'productList', productList);
}, 500)
that.$set(that.where, 'page', that.where.page + 1);
if (that.where.page == 1 && res.data.list.length <= 0) that.emptyShow = true
}).catch(err => {
that.loading = false;
that.loadTitle = '加载更多';
});
},
//
decimal() {
merchant({
id: this.mer_id
}).then((res) => {
this.merchant_Data = res.data
});
},
//
paydecimal() {
let that = this
uni.showModal({
title: '提示',
content: '商户' + this.merchant_Data.mer_name + '是否同意缴纳保证金',
success: (res) => {
if (res.confirm) {
// console.log('');
paymerchant().then((res) => {
uni.requestPayment({
provider: 'wxpay',
orderInfo: res.data
.config, //
success: (res) => {
that.$util.Tips({
title: '支付成功'
});
that.decimal()
that.list(true)
},
fail: (err) => {
that.$util.Tips({
title: '支付失败'
});
console.log('fail:' + JSON.stringify(err));
}
});
}).catch((err) => {
console.log(err)
this.$util.Tips(()=>{
})
})
} else if (res.cancel) {
console.log('用户点击取消');
}
}
});
}
}
}
</script>
<style>
</style>
<style lang="scss">
page {
background-color: #fff;
}
.content-order {
background: #F4F4F4;
border-radius: 21rpx 21rpx;
margin-top: 30rpx;
padding: 10rpx;
margin-left: 10rpx;
margin-right: 10rpx;
view {
font-size: 30rpx;
font-family: PingFang SC-Regular, PingFang SC;
font-weight: 400;
color: #333333;
margin: 20rpx;
}
}
.info {
display: flex;
flex-direction: column;
align-items: center;
position: relative;
height: 250rpx;
.bg {
background-color: #FF5C2D;
height: 170rpx;
width: 100vw;
border-radius: 0rpx 0rpx 28rpx 28rpx;
position: absolute;
top: 0;
left: 0;
}
.card {
width: 694rpx;
min-height: 180rpx;
background: #FFFFFF;
margin-top: 38.55rpx;
box-shadow: 0rpx 0rpx 18rpx 2rpx rgba(50, 116, 249, 0.1);
border-radius: 14rpx 14rpx 14rpx 14rpx;
opacity: 1;
padding: 31.5rpx 28rpx;
display: flex;
flex-direction: column;
justify-content: space-around;
position: absolute;
top: 0;
.title {
font-size: 32rpx;
font-weight: 600;
color: #333333;
padding-bottom: 10rpx;
}
.item {
display: flex;
justify-content: space-between;
font-size: 32rpx;
font-weight: 400;
color: #333333;
margin-bottom: 10rpx;
text:nth-child(1) {
flex-shrink: 0;
margin-right: 18rpx;
}
}
}
}
.price {
display: flex;
flex-direction: column;
padding: 0 28rpx;
margin-top: 85rpx;
.title {
font-size: 32rpx;
font-weight: 600;
color: #333333;
line-height: 39rpx;
margin-bottom: 42rpx;
}
.tab {
display: flex;
flex-wrap: wrap;
justify-content: left;
width: 694rpx;
.item {
width: 217rpx;
height: 131rpx;
margin: 0 auto;
margin-bottom: 20rpx;
border-radius: 7rpx 7rpx 7rpx 7rpx;
border: 2rpx solid #F5F5F5;
display: flex;
justify-content: center;
align-items: center;
font-size: 32rpx;
font-weight: 500;
line-height: 32rpx;
}
.active {
border: 2rpx solid #FF5C2D;
color: #FF5C2D;
}
}
.input {
width: 100%;
height: 112rpx;
background: #F5F5F5;
border-radius: 56rpx 56rpx 56rpx 56rpx;
opacity: 1;
padding: 0 45.56rpx;
box-sizing: border-box;
font-size: 28rpx;
font-weight: 400;
color: #333;
line-height: 35rpx;
}
.btn {
width: 694rpx;
height: 84rpx;
margin-top: 73.6rpx;
background: #FF5C2D;
box-shadow: 0rpx 14rpx 44rpx 2rpx #E9EFF5;
border-radius: 42rpx 42rpx 42rpx 42rpx;
display: flex;
justify-content: center;
align-items: center;
font-size: 32rpx;
font-weight: 400;
color: #FFFFFF;
}
}
.tip {
display: flex;
flex-direction: column;
padding: 0 28rpx;
margin-top: 84rpx;
.title {
font-size: 32rpx;
font-weight: 500;
color: #FF5C2D;
line-height: 32rpx;
margin-bottom: 21rpx;
}
.text {
font-size: 28rpx;
font-weight: 400;
color: rgba(0, 0, 0, 0.6);
line-height: 42rpx;
-webkit-background-clip: text;
}
}
</style>

File diff suppressed because it is too large Load Diff

View File

@ -1,70 +1,41 @@
<template>
<view class="">
<!-- <view class="cloud_entrepot" :style="{'min-height': winHeight + 'px'}">
<view class="head-wrapper"></view>
<view class="town-title">{{town}}里海云仓</view>
<view class="body-wrapper">
<block v-for="(item,index) in cloudList" :key="index">
<navigator class="item"
:url="`/pages/nongKe/goods_list/index?cate_id=${item.category_id}&street=${street_code}&name=${item.category_name}`"
:style="{'background-image': `url(${item.background})`}">
<text class="item-title">{{item.category_name}}云仓服务</text>
<text>{{item.description}}</text>
<view class="chakan-btn">查看</view>
</navigator>
</block>
</view>
</view> -->
<view class="">
<view class="">
<view v-if="showtit">
<view :class="{'head':true,'show':showtit}" style="padding-top: var(--status-bar-height);">
<view style="display: flex;align-items: center;">
<u--image :showLoading="true" v-if="cloudList.length>0" src="/static/images/LHYC/FH.png"
<!-- <u--image :showLoading="true" v-if="cloudList.length>0" src="/static/images/LHYC/FH.png"
width="50.82rpx" height="50.82rpx" @click='goBack'></u--image>
<u--image v-else :showLoading="true" src="/static/images/LHYC/PFH.png" width="50.82rpx"
height="50.82rpx" @click='goBack'></u--image>
<view class="head_tit" :style="{color:cloudList.length>0?'':'black'}">
height="50.82rpx" @click='goBack'></u--image> -->
<i class="iconfont icon-xiangzuo" v-if="cloudList.length>0"
style="font-size: 40rpx;text-align: left;" @click='goBack'></i>
<i class="iconfont icon-xiangzuo" v-else style="font-size: 40rpx;text-align: left;"
@click='goBack'></i>
<view class="head_tit" v-if="cloudList.length"
style="font-size: 40rpx;transform: skewX(-10deg);font-weight: bold;"
:style="{color:cloudList.length>0?'':'black'}">
{{town}}里海云仓
</view>
<view class="sl" :class="{actsl:showSelect}" @click="showSelect=!showSelect">
<u--image :showLoading="true" src="/static/images/GXSC/BSL.png" width="33.29rpx"
height="33.29rpx"></u--image>
</view>
</view>
<view class="" style="display: flex;align-items: center;">
<view style="display: flex;align-items: center;z-index: 999999;">
<u--image :showLoading="true" src="/static/images/LHYC/DWB.png" width="50.82rpx"
height="50.82rpx"></u--image>
<view class="town_name" :style="{color:cloudList.length>0?'':'black'}"
@click="showpick">{{street}}</view>
</view>
<view class="head_r" @click="showPop=true">
<view class="head_r" @click="showPop=true" v-if="cloudList.length>0">
<u--image v-if="cloudList.length>0" :showLoading="true" src="/static/images/LHYC/QB.png"
width="50.82rpx" height="50.82rpx"></u--image>
<u--image v-else :showLoading="true" src="/static/images/LHYC/QB.png" width="50.82rpx"
<u--image v-else :showLoading="true" src="/static/images/LHYC/QB1.png" width="50.82rpx"
height="50.82rpx"></u--image>
<text :style="{color:cloudList.length>0?'':'black'}">全部</text>
</view>
</view>
</view>
<view class="selected-list" :style="`top:${headtop}px`" :class="{actSel:showSelect}">
<div class="triangle-up"></div>
<view
@click="navgo(`/pages/nongKe/supply_chain/supplier?type_id=10&street_id=${street_code}&townName=${street}`)">
供销综合云市场 <text></text>
</view>
<view class="selected-li">
供销综合云商品 <text> <u--image style="margin-left: 40rpx;" :showLoading="true"
src="/static/images/GXSC/XZ.png" width="24.53rpx" height="24.53rpx"></u--image>
</text>
</view>
</view>
</view>
@ -76,24 +47,33 @@
<view style="align-items: center;display: flex;justify-content: space-between;">
<view class="" style="display: flex;align-items: center;">
<view class="back" style="margin-right: 17rpx;">
<u--image :showLoading="true" src="/static/images/LHYC/FH.png" width="50.82rpx"
height="50.82rpx" @click='goBack'></u--image>
<!-- <u--image :showLoading="true" src="/static/images/LHYC/FH.png" width="50.82rpx"
height="50.82rpx" @click='goBack'></u--image> -->
<i class="iconfont icon-xiangzuo" style="font-size: 40rpx;text-align: left;"
@click='goBack'></i>
</view>
<view class="" style="font-size: 40rpx;transform: skewX(-10deg);">
供销综合云市场
<!-- <view class="" style="font-size: 40rpx;transform: skewX(-10deg);font-weight: 700;">
{town}}
</view> -->
<view class="head_tit" v-if="cloudList.length"
style="font-size: 40rpx;transform: skewX(-10deg);font-weight: bold;"
:style="{color:cloudList.length>0?'':'black'}">
{{town}}里海云仓
</view>
</view>
<view style="position: relative;width: 289.14rpx;">
<u-search borderColor="#FF6D20" bgColor="white" :showAction="false" placeholder="请输入..."
v-model="keyword" class="serch_cls"></u-search>
<u--image class="img_cls" :showLoading="true" src="/static/images/GXSC/SSBT.png"
width="115.65rpx" height="56.82rpx" @click="serch"></u--image>
<!-- <u--image class="img_cls" :showLoading="true" src="/static/images/GXSC/SSBT.png"
width="115.65rpx" height="56.82rpx" @click="serch"></u--image> -->
<view class="serchbtn img_cls" @click="serch">搜索</view>
</view>
<view class='head_r' @click="showPop=true">
<u--image :showLoading="true" src="/static/images/LHYC/QB.png" width="50.82rpx"
height="50.82rpx"></u--image>
<text class="">全部</text>
<text class="" style="height: 5px;"></text>
<view class="flags">
</view>
@ -108,28 +88,29 @@
:disable-touch="true">
<swiper-item v-for="(item,index) in cloudList">
<u--image :showLoading="true" :src="item.cover" :class="act_img" width="750rpx"
height="998.83rpx"></u--image>
height="718.46rpx"></u--image>
</swiper-item>
</swiper>
</view>
<view class="" style="height:998.83rpx;" v-if="act_swiper">
<view class="" style="height:989.46rpx;" v-if="act_swiper">
</view>
<view class="menu" v-if="showtit" style="transition: 1s;">
<swiper :autoplay="false" :active-class="activeClass" :interval="3000" class="swiper"
:circular="true" previous-margin='270rpx' next-margin='270rpx' :current="current"
:circular="true" previous-margin='280rpx' next-margin='280rpx' :current="current"
@change="test">
<swiper-item v-for="(item,index) in cloudList" :key="index" @click="clickSwiperFn(index)">
<view class="swiper_item" :class="{swiper_item_act:index==current}">
<view class="swiper_item" :class="{'swiper_item_act':index==current, 'swiper_item_act2':index==current-1||index==current+1}">
<u--image :showLoading="true" :src="item.background" class="swiper_b"
width="175.23rpx" height="175.23rpx"></u--image>
width="140.19rpx" height="140.19rpx"></u--image>
</view>
</swiper-item>
</swiper>
</view>
<!-- 商品列表 -->
<view class="content">
<view class="content_sift" :style="{position:pocls,top:(headtop)+'px'}" v-if="!showtit">
@ -284,8 +265,17 @@
</view>
</view>
<view class="empty" style="" v-if="cloudList.length<=0">
<view style="height: var(--status-bar-height);"></view>
<view style="padding: 10rpx;">
<view class="info">
@ -297,16 +287,21 @@
</view>
</view>
<!-- 多规格购物车 -->
<authorize @onLoadFun="onLoadFun" :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse">
</authorize>
<view class="" :style="`height:${appInfo.bottom}px;background-color:white`">
<view class="" :style="`height:${appInfo.bottom}px;`">
</view>
</view>
<view class="">
<u-picker :defaultIndex="defaInd" :show="showPicker" ref="uPicker" :columns="columnData" @confirm="confirm"
@cancel="showPicker = false" @change="changeHandler" keyName="name"></u-picker>
@ -483,13 +478,7 @@
this.Area()
let that = this
setTimeout(() => {
uni.createSelectorQuery()
.in(this)
.select('.flags')
.boundingClientRect(rect => {
that.headtop = rect.top
})
.exec();
uni.createSelectorQuery()
.in(this)
.select('.flags')
@ -502,10 +491,11 @@
.select('.cart')
.boundingClientRect(rect => {
// console.log(this.cartTagInfo, 6666)
this.cartTagInfo = rect
that.cartTagInfo = rect
// console.log(rect)
})
.exec();
// console.log(that.headtop)
console.log(that.headtop)
}, 500)
// console.log(this.appInfo, "")
@ -553,11 +543,16 @@
},
onPageScroll(e) {
let that = this
// if (e.scrollTop > 0) {
this.showtit = !Boolean(e.scrollTop)
// }
// console.log(e)
uni.createSelectorQuery()
.in(this)
.select('.content')
.boundingClientRect(rect => {
console.log(rect);
if (rect.top <= (this.headtop)) {
this.pocls = 'fixed'
this.act_swiper = 'act_swiper'
@ -571,6 +566,15 @@
}
})
.exec();
uni.createSelectorQuery()
.in(this)
.select('.cart')
.boundingClientRect(rect => {
// console.log(this.cartTagInfo, 6666)
that.cartTagInfo = rect
// console.log(rect)
})
.exec();
},
onPullDownRefresh() {
this.getCloundShop()
@ -781,7 +785,7 @@
},
navgo(url) {
uni.navigateTo({
uni.redirectTo({
url
})
},
@ -824,9 +828,10 @@
spread_id: "",
}
let that = this
uni.createSelectorQuery().in(this).select(`.act_class${i}`).boundingClientRect(data1 => {
that.trnList[i].left = this.cartTagInfo.left - data1.left;
that.trnList[i].bottom = this.cartTagInfo.top - data1.top;
that.trnList[i].left = that.cartTagInfo.left - data1.left;
that.trnList[i].bottom = that.cartTagInfo.top - data1.top;
let timer = setTimeout(() => {
that.trnList[i].left = 0
@ -917,7 +922,18 @@
opacity: 0,
}
}
.serchbtn {
// position: absolute;
// right: 5rpx;
// top: 5rpx;
width: 100rpx;
height: 50rpx;
border-radius: 30rpx;
text-align: center;
line-height: 50rpx;
// background-color: #FEAB00;
background: linear-gradient(to right, #F84221, #FF6D20);
}
.selected-list {
padding: 24rpx 14rpx;
border-radius: 10.51rpx 10.51rpx 10.51rpx 10.51rpx;
@ -1039,6 +1055,9 @@
.swiper_item_act {
transform: scale(1.2);
}
.swiper_item_act2 {
transform: scale(1.1);
}
// .swiper_item:hover {}
@ -1150,7 +1169,7 @@
.img_cls {
position: absolute;
top: 50%;
right: 7rpx;
right: 5rpx;
transform: translateY(-50%);
}
@ -1230,11 +1249,11 @@
.menu {
position: absolute;
top: 748rpx;
top: 490rpx;
width: 750rpx;
// background-color: rgba(255, 255, 255, 0.7);
height: 250rpx;
// height: 175.23rpx;
// height: 140.19rpx;
// box-shadow: 0 0 100px 100px rgba(255, 255, 255, 0.5);
// box-shadow: 0 0 100rpx 30rpx rgba(255, 255, 255, 0.9);
@ -1359,7 +1378,7 @@
.swipers {
width: 750rpx;
height: 998.83rpx;
height: 718.46rpx;
}
.card {
@ -1396,7 +1415,7 @@
font-size: 33.29rpx;
line-height: 50px;
background: linear-gradient(to right, #F84221, #FF6D20);
width: 175.23rpx;
width: 140.19rpx;
text-align: center;
}
}

File diff suppressed because it is too large Load Diff

View File

@ -9,9 +9,12 @@
<view class="head_tit">
<view class="" style="display: flex;align-items: center;">
<view class="back" @click='backjJump()' style="margin-right:17rpx ;">
<view class="iconfont icon-xiangzuo" style="color: #333333;"></view>
<!-- <u--image :showLoading="true" src="/static/images/LHYC/PFH.png" width="50.82rpx"
height="50.82rpx"></u--image> -->
<i class="iconfont icon-xiangzuo" style="font-size: 40rpx;text-align: left;"
></i>
</view>
<view style="font-size: 40rpx;font-weight: 700;transform: skewX(-10deg);">
<view style="font-size: 40rpx;">
<!-- {{titName}} -->
当地美食
</view>
@ -23,8 +26,9 @@
:value='sotreParam.keyword' @confirm="searchSubmit"></input> -->
<u-search borderColor="#FF6D20" bgColor="white" :showAction="false" placeholder="搜索店铺名称"
v-model="sotreParam.keyword" class="serch_cls"></u-search>
<u--image @tap="searchSubmit" class="img_cls" :showLoading="true"
src="/static/images/GXSC/SS.png" width="115.65rpx" height="56.82rpx"></u--image>
<view class="serchbtn img_cls" @tap="searchSubmit">搜索</view>
<!-- <u--image @tap="searchSubmit" class="img_cls" :showLoading="true"
src="/static/images/GXSC/SSBT.png" width="115.65rpx" height="56.82rpx"></u--image> -->
</view>
</view>
@ -700,7 +704,19 @@
margin: 0;
padding: 0;
}
.serchbtn {
// position: absolute;
// right: 5rpx;
// top: 5rpx;
width: 100rpx;
height: 50rpx;
border-radius: 30rpx;
text-align: center;
line-height: 50rpx;
// background-color: #FEAB00;
color: #fff;
background: linear-gradient(to right, #F84221, #FF6D20);
}
.com_name {
font-size: 32rpx;
// background-color: red;
@ -1301,7 +1317,7 @@
.img_cls {
position: absolute;
top: 50%;
right: 7rpx;
right: 5rpx;
transform: translateY(-50%);
}

View File

@ -9,9 +9,13 @@
<view class="head_tit">
<view class="" style="display: flex;align-items: center;">
<view class="back" @click='backjJump()' style="margin-right: 17rpx;">
<view class="iconfont icon-xiangzuo" style="color: #333333;"></view>
<!-- <u--image :showLoading="true" src="/static/images/LHYC/PFH.png" width="50.82rpx"
height="50.82rpx"></u--image> -->
<i class="iconfont icon-xiangzuo" style="font-size: 40rpx;text-align: left;"
></i>
</view>
<view style="font-size: 40rpx;font-weight: 700;transform: skewX(-10deg);">
<view style="font-size: 40rpx;">
<!-- {{titName}} -->
名优特产
</view>
@ -26,8 +30,9 @@
:value='sotreParam.keyword' @confirm="searchSubmit"></input> -->
<u-search borderColor="#FF6D20" bgColor="white" :showAction="false" placeholder="搜索店铺名称"
v-model="sotreParam.keyword" class="serch_cls"></u-search>
<u--image @tap="searchSubmit" class="img_cls" :showLoading="true"
src="/static/images/GXSC/SS.png" width="115.65rpx" height="56.82rpx"></u--image>
<view class="serchbtn img_cls" @tap="searchSubmit">搜索</view>
<!-- <u--image @tap="searchSubmit" class="img_cls" :showLoading="true"
src="/static/images/GXSC/SSBT.png" width="115.65rpx" height="56.82rpx"></u--image> -->
</view>
</view>
@ -699,6 +704,19 @@
</script>
<style lang="scss" scoped>
.serchbtn {
// position: absolute;
// right: 5rpx;
// top: 5rpx;
width: 100rpx;
height: 50rpx;
border-radius: 30rpx;
text-align: center;
line-height: 50rpx;
// background-color: #FEAB00;
color: #fff;
background: linear-gradient(to right, #F84221, #FF6D20);
}
* {
margin: 0;
padding: 0;
@ -1304,7 +1322,7 @@
.img_cls {
position: absolute;
top: 50%;
right: 7rpx;
right: 5rpx;
transform: translateY(-50%);
}

View File

@ -4,70 +4,89 @@
<view class='productList' :style="viewColor">
<!-- 顶部 -->
<view class="top">
<view style="height: 10px;">
</view>
<view class="head_tit">
<view class="" style="display: flex;align-items: center;">
<view class="back" @click='backjJump()' style="margin-right: 17rpx;">
<view class="iconfont icon-xiangzuo" style="color: #333333;"></view>
</view>
<view class="" style="font-size: 40rpx;font-weight: 700;">
<!-- <u--image :showLoading="true" src="/static/images/LHYC/PFH.png" width="50.82rpx"
height="50.82rpx" @click='backjJump'></u--image> -->
<i class="iconfont icon-xiangzuo" style="font-size: 40rpx;text-align: left;" @click='backjJump'></i>
<view class=""
style="font-size: 36.8rpx;font-weight: 700;transform: skewX(-10deg);margin-left: 20rpx;color: #F84221;">
供销综合云市场
</view>
<view style="margin-left: 20rpx;transition: 0.3s;" @click="showSelect=!showSelect"
<view class=""
@click="navGoto(`/pages/nongKe/cloud_entrepot/indexa?street=${street_id}&town=${street}`)"
style="font-size: 36.8rpx;font-weight: 700;transform: skewX(-10deg);margin-left: 60rpx;">
供销综合云商品
</view>
<!-- <view style="margin-left: 20rpx;transition: 0.3s;" @click="showSelect=!showSelect"
:class="{selects:showSelect}">
<u--image :showLoading="true" src="/static/images/GXSC/XL.png" width="33.29rpx"
height="33.29rpx"></u--image>
</view>
</view> -->
</view>
<view class="">
</view>
<!-- 搜索框 -->
<view style="position: relative;width: 289.14rpx;" v-if="showSerch">
<!-- <view style="position: relative;width: 289.14rpx;" v-if="showSerch">
<u-search borderColor="#FF6D20" bgColor="white" @change="test" :showAction="false"
placeholder="请输入..." v-model="sotreParam.keyword" @search="onInputConfirm"
class="serch_cls"></u-search>
<u--image @tap="searchSubmit" class="img_cls" :showLoading="true"
src="/static/images/GXSC/SSBT.png" width="115.65rpx" height="56.82rpx"></u--image>
</view>
</view> -->
<!-- 位置 -->
<view v-else style="display: flex;align-items: center;" @click="showPicker=!showPicker">
<!-- <view v-else style="display: flex;align-items: center;">
<u--image @tap="showSerch=!showSerch" style="margin-right: 30rpx;" :showLoading="true"
src="/static/images/GXSC/SS.png" width="49rpx" height="49rpx"></u--image>
<u--image @click="showPicker=!showPicker" :showLoading="true" src="/static/images/GXSC/DW1.png"
width="50.82rpx" height="50.82rpx"></u--image>
<view class="town_name">{{street}}</view>
</view> -->
</view>
<view class="sswz">
<view style="position: relative;width: 501.17rpx;">
<u-search borderColor="#FF6D20" bgColor="white" @change="test" :showAction="false"
placeholder="搜索店铺或者名称" v-model="sotreParam.keyword" @search="onInputConfirm"
class="serch_cls"></u-search>
<u--image @tap="searchSubmit" class="img_cls" :showLoading="true"
src="/static/images/GXSC/SSBT.png" width="115.65rpx" height="56.82rpx"></u--image>
</view>
<view style="display: flex;align-items: center;" @click="showPicker=!showPicker">
<u--image :showLoading="true" src="/static/images/GXSC/DW1.png" width="50.82rpx"
height="50.82rpx"></u--image>
<view class="town_name">{{street}}</view>
</view>
</view>
<view class="selected-list" :class="{actSel:showSelect}">
<!-- <view class="selected-list" :class="{actSel:showSelect}">
<div class="triangle-up"></div>
<view class="selected-li">
供销综合云市场 <text> <u--image style="margin-left: 40rpx;" :showLoading="true"
src="/static/images/GXSC/XZ.png" width="24.53rpx" height="24.53rpx"></u--image> </text>
</view>
<view class=""
@click="navGoto(`/pages/nongKe/cloud_entrepot/index?street=${street_id}&town=${street}`)">
@click="navGoto(`/pages/nongKe/cloud_entrepot/indexa?street=${street_id}&town=${street}`)">
供销综合云商品
</view>
</view> -->
<view class="flags">
</view>
</view>
<view class="content">
<view style="height: 10px">
<view class="" :style="`height:${headTop}px`">
</view>
<view class="hot_serch">
<text>热搜:</text>
<!-- <text>热搜:</text>
<text @click="hotSerchFn('小张副食')">小张副食</text>
<text @click="hotSerchFn('正新酒店')">正新酒店</text>
<text @click="hotSerchFn('麻辣鸡')">麻辣鸡</text>
<text @click="hotSerchFn('手撕椒麻鸡')">手撕椒麻鸡</text>
<text @click="hotSerchFn('手撕椒麻鸡')">手撕椒麻鸡</text> -->
</view>
<view class="menu_cls">
@ -123,7 +142,7 @@
</view>
<u-loadmore :status="status" />
</view>
<!-- 热搜 -->
@ -356,6 +375,7 @@
defaInd: [0, 0],
columnData: [],
showSerch: false,
headTop: 0,
imgList: [
"/static/images/GXSC/BBY.png",
"/static/images/GXSC/NYSC.png",
@ -395,6 +415,7 @@
menuList: [],
street: "",
showPicker: false,
status: "loadmore",
//
downMenu: [{
title: '默认',
@ -473,6 +494,19 @@
this.menuList = res.data
})
this.Area()
let that = this
setTimeout(() => {
uni.createSelectorQuery()
.in(this)
.select('.flags')
.boundingClientRect(rect => {
// console.log(this.cartTagInfo, 6666)
// that.cartTagInfo = rect
that.headTop = rect.top
console.log(that.headTop)
})
.exec();
}, 100)
},
computed: {
downMenus: function() {
@ -531,7 +565,7 @@
city_code: 510500
}).then(res => {
this.$refs.uPicker.setColumnValues(0, res.data);
// this.Street(res.data[0]['code']);
this.Street(res.data[0]['code']);
// console.log(res.data, 66666)
});
},
@ -540,7 +574,7 @@
area_code: code
}).then(res => {
this.$refs.uPicker.setColumnValues(1, res.data);
console.log(res.data, 9999)
});
},
@ -587,10 +621,10 @@
},
test() {
if (this.sotreParam.keyword.length > 3) {
this.sotreParam.keyword.slice(0, 3)
this.sotreParam.keyword = this.sotreParam.keyword.slice(0, 3) + "..."
}
// if (this.sotreParam.keyword.length > 3) {
// this.sotreParam.keyword.slice(0, 3)
// this.sotreParam.keyword = this.sotreParam.keyword.slice(0, 3) + "..."
// }
// console.log(this.sotreParam.keyword.length)
},
hotSerchFn(keywords) {
@ -888,19 +922,33 @@
},
//
onReachBottom() {
if (this.count === this.storeList.length) {
if (this.count === 0) {
this.sotreParam.page += 1
let rqData = {
keyword: this.sotreParam.keyword,
page: this.sotreParam.page,
limit: 10,
order: this.sotreParam.order,
category_id: this.sotreParam.category_id,
type_id: this.sotreParam.type_id,
street_id: this.sotreParam.street_id,
credit_buy: this.credit_buy
}
if (this.latitude) {
rqData.location = this.latitude + ',' + this.longitude
}
// console.log(rqData)
storeMerchantList(rqData).then(res => {
if (res.data.list == 0) {
this.status = "nomore"
return
}
uni.showToast({
title: '已加载全部',
icon: 'none',
duration: 1000
});
} else {
this.sotreParam.page += 1
this.storeMerchantList()
}
this.count = res.data.count
this.storeList.push(...res.data.list)
})
}
}
@ -933,6 +981,7 @@
align-items: center;
box-sizing: border-box;
padding: 0 20rpx;
}
.productList {
@ -941,9 +990,7 @@
.top {
padding-top: var(--status-bar-height);
/* #ifdef H5 */
padding-top: 30rpx;
/* #endif */
// padding-top: 80rpx;
background-color: #F0F2F5;
position: fixed;
@ -954,6 +1001,7 @@
.content {
padding: 20rpx;
padding-top: 0;
}
.menu_cls {
@ -1066,24 +1114,7 @@
}
.hot_serch {
color: #B3B3B3;
display: flex;
justify-content: space-around;
margin-top: 40rpx;
flex-wrap: wrap;
// margin-top: 50rpx;
// padding-top: 100rpx;
padding-top: var(--status-bar-height);
// margin-top: 10px;
/* #ifdef H5 */
padding-top: 50rpx;
/* #endif */
// margin-top: 200rpx;
text {
margin: 10rpx;
}
height: 20rpx;
}
.productList .search .input {
@ -1577,4 +1608,12 @@
.pop {
z-index: 1;
}
.sswz {
margin-top: 30rpx;
display: flex;
justify-content: space-between;
box-sizing: border-box;
padding: 0 20rpx;
}
</style>

View File

@ -15,7 +15,8 @@
<view class="back" @click='backjJump()' style="margin-right: 17rpx;">
<view class="iconfont icon-xiangzuo" style="color: #333333;"></view>
</view>
<view class="" style="font-size: 40rpx;font-weight: 700;transform: skewX(-10deg);">
<view class=""
style="font-size: 36.8rpx;font-weight: 700;transform: skewX(-10deg);margin-left: 20rpx;">
{{titName}}
</view>
</view>

View File

@ -9,9 +9,12 @@
<view class="head_tit">
<view class="" style="display: flex;align-items: center;">
<view class="back" @click='backjJump()' style="margin-right: 17rpx;">
<view class="iconfont icon-xiangzuo" style="color: #333333;"></view>
<!-- <u--image :showLoading="true" src="/static/images/LHYC/PFH.png" width="50.82rpx"
height="50.82rpx"></u--image> -->
<i class="iconfont icon-xiangzuo" style="font-size: 40rpx;text-align: left;"
></i>
</view>
<view style="font-size: 40rpx;font-weight: 700;transform: skewX(-10deg);">
<view style="font-size: 40rpx;">
<!-- {{titName}} -->
特色文旅
</view>
@ -26,8 +29,9 @@
:value='sotreParam.keyword' @confirm="searchSubmit"></input> -->
<u-search borderColor="#FF6D20" bgColor="white" :showAction="false" placeholder="搜索店铺名称"
v-model="sotreParam.keyword" class="serch_cls"></u-search>
<u--image @tap="searchSubmit" class="img_cls" :showLoading="true"
src="/static/images/GXSC/SS.png" width="115.65rpx" height="56.82rpx"></u--image>
<view class="serchbtn img_cls" @tap="searchSubmit">搜索</view>
<!-- <u--image @tap="searchSubmit" class="img_cls" :showLoading="true"
src="/static/images/GXSC/SSBT.png" width="115.65rpx" height="56.82rpx"></u--image> -->
</view>
</view>
@ -701,7 +705,19 @@
margin: 0;
padding: 0;
}
.serchbtn {
// position: absolute;
// right: 5rpx;
// top: 5rpx;
width: 100rpx;
height: 50rpx;
border-radius: 30rpx;
text-align: center;
line-height: 50rpx;
// background-color: #FEAB00;
color: #fff;
background: linear-gradient(to right, #F84221, #FF6D20);
}
.com_name {
font-size: 32rpx;
// background-color: red;
@ -1302,7 +1318,7 @@
.img_cls {
position: absolute;
top: 50%;
right: 7rpx;
right: 5rpx;
transform: translateY(-50%);
}

View File

@ -306,7 +306,7 @@
<view class="content-clip"></view>
<view class='footer acea-row row-right row-middle' v-if="isGoodsReturn==false">
<!-- <view class='bnt cancel' @click="cancelSales">取消售后</view> -->
<!-- <view v-if="!orderInfo.receipt && !isGoodsReturn" class='bnt cancel' @click="applyInvoice">申请开票</view> -->
<view v-if="!orderInfo.receipt && !isGoodsReturn" class='bnt cancel' @click="applyInvoice">申请开票</view>
<view v-if="orderInfo.activity_type == 2 && (orderInfo.status == 10 || orderInfo.status == 11)"
class=" acea-row row-right row-middle">
<view v-if="orderInfo.presellOrder.activeStatus == 0" class='bnt b-color btn_auto'>

View File

@ -363,7 +363,7 @@
},
mapGetters(['isLogin', 'uid', 'viewColor', 'keyColor', ])),
onLoad: function(options) {
console.log('11111111')
this.credit_buy = options.credit_buy
// console.log(options.product_type)
if (options.product_type) {

View File

@ -28,7 +28,8 @@
<view class="list_count">
<view v-if="followDetail.author" class="title">
<view class="head-menu">
<image src="@/static/images/right.png" mode="aspectFill" @click="returns"></image>
<i class="iconfont icon-xiangzuo" style="font-size: 40rpx;text-align: left;" @click="returns"></i>
<!-- <image src="@/static/images/right.png" mode="aspectFill" @click="returns"></image> -->
</view>
<view class="author">

View File

@ -130,7 +130,7 @@
selHeight="250upx">
</avatar>
<!-- 提到的宝贝弹窗 -->
<uni-popup ref="associated" type="bottom">
<uni-popup ref="associated" type="bottom" style="z-index: 9999;">
<associated @close="close" @getProduct="getProduct" :checkedObj="productList"></associated>
</uni-popup>
<!-- 话题弹窗 -->

View File

@ -32,7 +32,7 @@
getProductContent(obj) {
// console.log(obj);
this.goodsDis = obj;
this.a=obj.store_name
this.a=obj.store_name;
},
save() {
setStorage('goodsDis', this.goodsDis);

View File

@ -0,0 +1,695 @@
<template>
<view class=" writeBg ">
<view class="content_list">
<view class="content_list_item">
<view>商品详情</view>
<!-- <view class="content_list_item_han">
<span v-if="disModel" style="color: #000000">去修改</span>
<span v-else>设置详情</span>
<span class="iconfont">&#xe6bd;</span>
</view> -->
</view>
<input-goods-detils class="input-goods-detils" @getProductContent="getProductContent" :title="store_name" :prodectContent="goodsDis" :maxLength="200"></input-goods-detils>
<block v-if="!moreThanFlag">
<view class="content_list_video input-goods-detils">
<view class="content_list_video_title">商品视频</view>
<view class="video_list">
<view class="video_list_item photo" v-if="addGoodsSecoundData.video_link">
<view class="jiao" @click="deleteImage()">
<!-- video标签在app端层级过高 -->
<!--#ifndef APP-PLUS-->
<video :src="addGoodsSecoundData.video_link"></video>
<!--#endif-->
<!--#ifdef APP-PLUS-->
<img src="https://lihai001.oss-cn-chengdu.aliyuncs.com/public/kk/luzhou/static4/3/video_bg.png"
style=" width:150rpx"></img>
<!--#endif-->
<image src="../static/images/close.png" mode="widthFix"></image>
</view>
<!--#ifndef APP-PLUS-->
<view style="position: absolute;">
<view class="videoHover" @click="videoshow">
</view>
<text class="video-text">点击可预览视频</text>
</view>
<!--#endif-->
<!--#ifdef APP-PLUS-->
<view class='preview_video'>
<view class="videoHover" @click="videoshow">
</view>
<text class="video-text">点击可预览视频</text>
</view>
<!--#endif-->
</view>
<view class="photo" @click="uploadVideo" v-else>
<view>
<image src="../static/images/creamer.png" mode="widthFix"></image>
</view>
<view>添加视频</view>
</view>
</view>
</view>
<view class="container_input marginTop_none input-goods-detils">
<view class="container_input_item">
<view class="container_input_item_label"><span>是否推荐</span></view>
<view class="container_input_item_value">
<switch :checked="addGoodsSecoundData.is_good == 1" color="#E93323" style="transform:scale(0.8)"
@change="isGood" />
</view>
</view>
<!-- <view class="container_input_item">
<view class="container_input_item_label"><span>是否开启礼包</span></view>
<view class="container_input_item_value">
<switch :checked="addGoodsSecoundData.is_gift_bag == 1" color="#E93323" style="transform:scale(0.8)"
@change="isGiftBag" />
</view>
</view> -->
</view>
<!-- <view class="tip input-goods-detils">
<span class="iconfont">&#xe688;</span>
<span>开启后此商品只能在分销礼包中展示并销售</span>
</view> -->
<view class="container_input marginTop_none input-goods-detils">
<!-- <view class="container_input_item">
<view class="container_input_item_label"><span>限购数量</span></view>
<view class="container_input_item_value">
<input v-model="addGoodsSecoundData.once_count" type="number" value="" placeholder="请输入限购数量"
placeholder-class="inputPlaceHolder" />
</view>
</view> -->
<view class="container_input_item">
<view class="container_input_item_label"><span>商品排序</span></view>
<view class="container_input_item_value">
<input v-model="addGoodsSecoundData.sort" type="number" value="" placeholder="请输入商品排序"
placeholder-class="inputPlaceHolder" />
</view>
</view>
</view>
</block>
<view class="more_than" @click="moreThanFlag=!moreThanFlag" >
<view v-if="moreThanFlag">更多</view>
<view v-else>收起</view>
</view>
</view>
<view v-if="showVideo" class="video-count">
<!--#ifndef APP-PLUS-->
<video id="myVideo" class="videoLink" autoplay loop muted :src="addGoodsSecoundData.video_link"></video>
<!--#endif-->
<!--#ifdef APP-PLUS-->
<video id="myVideo" class="videoLink" autoplay loop
:src='addGoodsSecoundData.video_link && (addGoodsSecoundData.video_link.substring(0,4) == "http" || addGoodsSecoundData.video_link.substring(0,5) == "https") ?addGoodsSecoundData.video_link : "http:" + addGoodsSecoundData.video_link'></video>
<!--#endif-->
</view>
<view class='mask' catchtouchmove="true" :hidden='showVideo==false' @tap="showVideo=false"></view>
<view class="handle dobuButton">
<view class="handle_button margin_right" @click="lastStep">上一步</view>
<view class="handle_button" @click="submitCreatedGoods">提交</view>
</view>
</view>
</template>
<script>
import { TOKENNAME, HTTP_REQUEST_URL } from '@/config/app.js';
import store from 'store';
import {
navigateTo,
setStorage,
getStorage,
removeStorage,
navigateBack,
Toast,
Loading,
hideLoading,
Modal
} from '../../../libs/uniApi.js';
import { productCreate, productUpdate } from 'api/product.js';
import inputGoodsDetils from '../components/inputGoodsDetils.vue';
export default {
components: {
inputGoodsDetils
},
props: {
merId: {
type: [String, Number],
default: ''
},
product_id: {
type: [String, Number],
default: ''
},
showCommodity: {
type: Boolean,
default: false
},
resetKey: {
type: Boolean,
default: false
},
code: {
type: [String, Number],
default: 0
}
},
data() {
return {
showVideo: false,
disModel: false,
upload_max: 10,
uploadUrl: `${HTTP_REQUEST_URL}/api/upload/video`,
addGoodsSecoundData: {
is_good: 0, //
is_gift_bag: 0,
sort: '',
once_count: '', //
video_link: ''
},
goodsDis: {imageList: [],store_name:""},
store_name:'',
moreThanFlag: true,
};
},
mounted() {
this.initData();
// this.$nextTick(()=>{
// this.initData();
// })
},
updated() {
// this.initData();
},
watch: {
addGoodsSecoundData: {
handler(val) {
setTimeout(() => {
setStorage('editCommodity', val)
});
},
deep: true
},
resetKey: {
handler(val) {
// console.log(1);
this.initData();
}
},
goodsDis: {
handler(val) {
setTimeout(() => {
setStorage('goodsDis', this.goodsDis);
});
},
deep: true
},
},
methods: {
videoshow() {
this.showVideo = true
this.videoContext = uni.createVideoContext('myVideo', this);
this.$nextTick(() => {
this.videoContext.play();
})
// this.video_link = this.formData.video_link;
// this.videoContext.requestFullScreen({ direction: 90 });
// this.videoContext.play(); this.videoplay = true;
},
initData() {
let editGoodsDetils = {};
if (getStorage('goodsDis')) {
this.disModel = true;
}
if (this.product_id) {
// editGoodsDetils = getStorage('editGoodsDetils');
editGoodsDetils = this.$store.state.storage.storage;
console.log(editGoodsDetils);
// editGoodsDetils = getStorage('editGoodsDetils');
// console.log('',editGoodsDetils);
Object.keys(this.addGoodsSecoundData).forEach(item => {
console.log(item, editGoodsDetils[item]);
this.addGoodsSecoundData[item] = editGoodsDetils[item];
});
if (editGoodsDetils.content) {
this.goodsDis.imageList = editGoodsDetils.content.image;
this.goodsDis.store_name = editGoodsDetils.content.title;
this.store_name = editGoodsDetils.content.title;
// console.log(this.goodsDis, editGoodsDetils.content);
setStorage('goodsDis', {
store_name: editGoodsDetils.content.title,
imageList: editGoodsDetils.content.image
});
this.disModel = true;
}
setStorage('canChangeSecound', true);
return;
}else {
setStorage('goodsDis', {
store_name: '',
imageList: []
});
}
if (getStorage('addGoodsSecoundData')) {
Object.keys(this.addGoodsSecoundData).forEach(item => {
if (getStorage('addGoodsSecoundData')[item] || getStorage('addGoodsSecoundData')[item] == 0) {
this.addGoodsSecoundData[item] = getStorage('addGoodsSecoundData')[item];
}
});
}
},
lastStep() {
this.$emit('lastStep');
},
//
submitCreatedGoods() {
Loading();
let waitDeleteData = ['addGoodsFormData', 'singleSpecification', 'attrValue', 'modifyPriceData',
'addGoodsSecoundData', 'goodsDis', 'editGoodsDetils', 'canChange', 'canChangeSecound'
];
let attrValue = getStorage('addGoodsFormData').spec_type == 0 ? [getStorage('singleSpecification')] :
getStorage('attrValue');
let postData = {
...this.addGoodsSecoundData,
...getStorage('addGoodsFormData'),
content: {
title: getStorage('goodsDis') ? getStorage('goodsDis').store_name : '',
image: getStorage('goodsDis') ? getStorage('goodsDis').imageList : []
},
video_link: this.addGoodsSecoundData.video_link
};
if (attrValue) {
postData.attrValue = attrValue.filter(item => item != '');
postData.attrValue[0].bar_code
}
// console.log(postData);
if (getStorage('addGoodsFormData').spec_type == 0) {
// postData.attr = [getStorage('singleSpecification')];
}
if (this.product_id) {
productUpdate(this.merId, this.product_id, postData)
.then(res => {
waitDeleteData.forEach(item => {
if (getStorage(item)) {
removeStorage(item);
}
});
hideLoading()
Modal('提交成功', '点击确定,返回商品管理', {
showCancel: false
}).then(() => {
uni.removeStorageSync('singleSpecification')
uni.redirectTo({
url: '/pages/product/goodsOnSale/index?mer_id=' + this.merId
})
})
})
.catch(rej => {
Toast(rej);
});
} else {
productCreate(this.merId, postData)
.then(res => {
waitDeleteData.forEach(item => {
if (getStorage(item)) {
removeStorage(item);
}
});
hideLoading();
Modal('提交成功', '点击确定,返回商品管理', {
showCancel: false,
}).then(() => {
uni.redirectTo({
url: '/pages/product/goodsOnSale/index?mer_id=' + this.merId
})
})
})
.catch(rej => {
Toast(rej);
});
}
},
//
isGood(e) {
this.addGoodsSecoundData.is_good = e.detail.value ? 1 : 0;
},
//
isGiftBag(e) {
this.addGoodsSecoundData.is_gift_bag = e.detail.value ? 1 : 0;
},
switchChange(value, item) {
this.addGoodsSecoundData[item.model] = value ? 1 : 0;
},
//
inputGoodsDetils() {
navigateTo(1, '/pages/product/addGoods/addGoodDetils', { mer_id: this.merId });
},
//
uploadVideo() {
uni.chooseVideo({
sourceType: ['camera', 'album'],
success: res => {
console.log(res)
if (Math.ceil(res.size / 1024) < this.upload_max * 1024) {
uni.uploadFile({
url: this.uploadUrl, //
filePath: res.tempFilePath,
name: 'file',
//
formData: {
user: 'test'
},
header: {
// #ifdef MP
'Content-Type': 'multipart/form-data',
// #endif
[TOKENNAME]: 'Bearer ' + store.state.app.token
},
success: uploadFileRes => {
let data = JSON.parse(uploadFileRes.data);
this.addGoodsSecoundData.video_link = (data.data.src);
},
complete: a => {
// console.log(a);
}
});
} else {
uni.showModal({
title: '提示',
content: `视频超出限制${this.upload_max}MB,已过滤`
});
}
},
fail: err => {
//
// uni.showModal({
// content: JSON.stringify(err)
// });
console.log(err)
}
});
},
deleteImage(index) {
this.addGoodsSecoundData.video_link = '';
},
getProductContent(obj) {
// console.log(obj);
this.goodsDis = obj;
this.a=obj.store_name
},
}
};
</script>
<style lang="scss" scoped>
@import './scss/index.scss';
.content_list {
width: 710rpx;
margin: auto;
padding: 0 20rpx;
box-sizing: border-box;
background: #fff;
margin-top: 31rpx;
border-radius: 10rpx;
.input-goods-detils{
width: 100%;
padding: 20rpx 10rpx !important;
}
.more_than{
background: #FFFFFF;
border-radius: 0 0 10rpx 10rpx;
margin: auto;
// margin-top: 30rpx;
border-top: 1px solid #f5f5f5;
display: flex;
align-items: center;
justify-content: center;
width: 100%;
height: 84rpx;
color: #333333;
font-size: 30rpx;
}
.content_list_item {
padding: 32rpx 10rpx;
display: flex;
justify-content: space-between;
border-bottom: 1px solid #eee;
.content_list_item_han {
color: #bbbbbb;
display: flex;
align-items: center;
}
}
.content_list_video {
min-height: 154rpx;
padding: 23rpx 10rpx;
display: flex;
justify-content: space-between;
.content_list_video_title {
padding-top: 10rpx;
}
.video_list {
flex: 1;
display: flex;
justify-content: flex-end;
flex-wrap: wrap;
}
}
}
.videoHover {
width: 180rpx;
height: 180rpx;
display: flex;
align-items: center;
justify-content: center;
position: absolute;
top: 0;
left: 0;
z-index: 10;
view {
width: 50rpx;
height: 50rpx;
background: #000000;
border-radius: 50rpx;
display: flex;
align-items: center;
justify-content: center;
.iconfont {
color: #ffffff;
font-size: 21rpx;
}
}
}
.photo {
border: 1px solid #dddddd;
opacity: 1;
border-radius: 8rpx;
font-size: 28rpx;
display: flex;
flex-direction: column;
justify-content: center;
text-align: center;
// padding: 27rpx 21rpx 24rpx 21rpx;
width: 150rpx;
height: 150rpx;
box-sizing: border-box;
color: #bbbbbb;
margin-left: 16rpx;
position: relative;
margin-bottom: 12rpx;
image {
width: 62rpx;
margin-bottom: 10rpx;
}
}
.jiao {
image {
position: absolute;
top: -14rpx;
right: -14rpx;
width: 40rpx;
height: 40rpx;
border-radius: 50%;
padding: 8rpx;
background: #e93323;
z-index: 2;
}
video {
width: 150rpx;
height: 150rpx;
}
}
.preview_video {
position: absolute;
}
.container_input {
background: #fff;
padding: 0 20rpx;
width: 710rpx;
margin: auto;
margin-top: 31rpx;
border-radius: 10rpx;
&_item {
display: flex;
height: 106rpx;
align-items: center;
.select_and_input {
display: flex;
align-items: center;
justify-content: space-between;
.greyColor {
color: #bbbbbb;
}
}
.radio {
padding: 30rpx 0;
}
&_label {
padding-left: 10rpx;
color: #333333;
font-size: 30rpx;
display: flex;
align-items: center;
.select_check {
display: flex;
align-items: center;
justify-content: center;
width: 40rpx;
height: 40rpx;
border: 1px solid #cccccc;
border-radius: 50%;
margin-right: 20rpx;
.iconfont {
font-size: 24rpx;
}
}
.select {
background: #e93323;
border: none;
.iconfont {
color: #fff;
}
}
}
&_value {
padding-right: 10rpx;
flex: 1;
display: flex;
align-items: center;
justify-content: flex-end;
>span:nth-child(1) {
display: inline-block;
margin-right: 15rpx;
}
.text {
color: #000;
display: inline-block;
max-width: 400rpx;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
}
input {
text-align: right;
}
.select_group {
display: flex;
}
&_select {
display: flex;
margin-right: 110rpx;
}
}
.flex_start {
padding: 0 10rpx;
margin-top: 40rpx;
justify-content: flex-start;
}
}
>view:not(:last-child) {
border-bottom: 1px solid #eeeeee;
}
}
.inputPlaceHolder {
color: #bbbbbb;
}
.paddingTop_none {
padding-top: 0 !important;
}
.marginTop_none {
margin-top: 0;
}
.video-count {
position: fixed;
width: 600rpx;
height: 500rpx;
top: 50%;
left: 50%;
margin-left: -300rpx;
margin-top: -250rpx;
z-index: 100;
display: flex;
align-items: center;
justify-content: center;
.videoLink {
width: 600rpx;
height: 500rpx;
}
}
// .writeBg {
// background: #fff;
// }
.tip{
padding: 0 !important;
margin: 0 !important;
}
</style>

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,230 @@
<template>
<view class="container">
<select-form style="border-radius: 10rpx 10rpx 0 0;" :platformClassification="formList" :form="singleSpecification"
@input="input"></select-form>
<view class="more_than" @click="moreThanFlag?selectMoreThan():spliceMoreThan()">
<view v-if="moreThanFlag">更多</view>
<view v-else>收起</view>
</view>
<!-- <view class="handle">
<view class="button" @click="saveSingleSpecification">
保存
</view>
</view> -->
</view>
</template>
<script>
import selectForm from '../components/selectForm.vue';
import { navigateTo, navigateBack, serialize, setStorage, getStorage } from '../../../libs/uniApi.js';
// attrValue
export default {
components: {
selectForm
},
props: ['product_id'],
data() {
return {
singleSpecification: {
price: '', //
cost: '', //
stock: '', //
ot_price: '', //
bar_code: '', //
weight: '', //
volume: '', //
image: '',
extension_one: '',
extension_two: ''
},
moreThanFlag: true,
formList: [{
id: 1,
label: '售价',
type: 'digit',
model: 'price',
holder: '请填写售价'
}, {
id: 10,
label: '库存',
type: 'digit',
model: 'stock',
holder: '请填写库存',
disable: true
}],
moreThanList: [{
id: 2,
label: '成本价',
type: 'digit',
holder: '请填写成本价',
model: 'cost'
},
{
id: 3,
label: '原价',
type: 'digit',
holder: '请填写原价',
model: 'ot_price'
},
{
id: 5,
label: '商品编号',
type: 'input',
holder: '请填写商品编号',
model: 'bar_code'
},
{
id: 6,
label: '重量',
type: 'digit',
holder: '请输入重量',
model: 'weight'
},
{
id: 7,
label: '体积',
type: 'digit',
holder: '请输入体积',
model: 'volume'
},
// {
// id: 8,
// label: '',
// type: 'digit',
// holder: '',
// model: 'extension_one'
// },
// {
// id: 9,
// label: '',
// type: 'digit',
// holder: '',
// model: 'extension_two'
// }
],
}
},
watch: {
singleSpecification: {
handler(val) {
this.singleSpecification = val;
this.saveSingleSpecification();
},
deep: true
}
},
// onLoad(option) {
// console.log(option);
// this.singleSpecification.bar_code=option.code
// },
// onShow() {
// if(getStorage('addGoodsFormData').image) {
// this.singleSpecification.image = getStorage('addGoodsFormData').image;
// }
// if(getStorage('singleSpecification')) {
// Object.keys(this.singleSpecification).forEach(item => {
// if(getStorage('singleSpecification')[item]) {
// this.singleSpecification[item] = getStorage('singleSpecification')[item]
// }
// })
// }
// },
// beforeDestroy() {
// console.log('123');
// uni.removeStorage({
// key: 'singleSpecification'
// });
// },
mounted() {
if (getStorage('addGoodsFormData').image) {
this.singleSpecification.image = getStorage('addGoodsFormData').image;
}
if (getStorage('singleSpecification')) {
Object.keys(this.singleSpecification).forEach(item => {
if (getStorage('singleSpecification')[item]) {
this.singleSpecification[item] = getStorage('singleSpecification')[item]
}
})
}
// if (!this.$props.product_id) {
// this.formList.push({
// id: 10,
// label: '',
// type: 'digit',
// model: 'stock',
// holder: '',
// disable: true
// })
// }
},
destroyed() {
setStorage('singleSpecification', {});
},
methods: {
selectMoreThan() {
this.formList = this.formList.concat(this.moreThanList);
this.moreThanFlag = false;
},
spliceMoreThan() {
this.moreThanFlag = true;
// this.formList.splice(!this.$props.product_id ? 2 : 1, this.formList.length);
this.formList.splice(2, this.formList.length);
},
input(val) {
this.singleSpecification = val
},
//
saveSingleSpecification() {
setStorage('singleSpecification', this.singleSpecification);
// navigateBack(1);
}
}
}
</script>
<style lang="scss" scoped>
.container {
padding: 0 !important;
}
.more_than {
background: #FFFFFF;
border-radius: 0 0 10rpx 10rpx;
margin: auto;
// margin-top: 30rpx;
margin-top: 1px;
display: flex;
align-items: center;
justify-content: center;
width: 710rpx;
height: 84rpx;
color: #333333;
font-size: 30rpx;
}
.handle {
position: fixed;
left: 0;
bottom: 0;
width: 100%;
height: 126rpx;
background: #FFFFFF;
display: flex;
align-items: center;
justify-content: center;
.button {
display: flex;
align-items: center;
justify-content: center;
color: #FFFFFF;
font-size: 32rpx;
width: 690rpx;
height: 86rpx;
background: #E93323;
border-radius: 43rpx;
}
}
</style>

View File

@ -18,7 +18,7 @@
}
}
.tip {
padding: 16rpx 0 0 40rpx;
padding: 16rpx 0 0 20rpx;
font-size: 22rpx;
color: #e93323;
display: flex;
@ -36,6 +36,14 @@
width: 710rpx;
font-size: 30rpx;
border-radius: 10rpx;
.icon_top{
transform: rotate(-90deg);
}
.icon_bottom{
transform: rotate(90deg);
}
.popup_group_item {
padding: 32rpx 30rpx;
display: flex;

View File

@ -1,112 +1,118 @@
<template>
<view class=" writeBg ">
<view class="container_input marginTop_none">
<view class="container_input_item">
<view class="container_input_item_label"><span>是否推荐</span></view>
<view class="container_input_item_value">
<switch :checked="addGoodsSecoundData.is_good == 1" color="#E93323" style="transform:scale(0.8)"
@change="isGood" />
</view>
</view>
<view class="container_input_item">
<view class="container_input_item_label"><span>是否开启礼包</span></view>
<view class="container_input_item_value">
<switch :checked="addGoodsSecoundData.is_gift_bag == 1" color="#E93323" style="transform:scale(0.8)"
@change="isGiftBag" />
</view>
</view>
</view>
<view class="tip">
<span class="iconfont">&#xe688;</span>
<span>开启后此商品只能在分销礼包中展示并销售</span>
</view>
<view class="container_input marginTop_none">
<view class="container_input_item">
<view class="container_input_item_label"><span>限购数量</span></view>
<view class="container_input_item_value">
<input v-model="addGoodsSecoundData.once_count" type="number" value="" placeholder="请输入限购数量"
placeholder-class="inputPlaceHolder" />
</view>
</view>
<view class="container_input_item">
<view class="container_input_item_label"><span>商品排序</span></view>
<view class="container_input_item_value">
<input v-model="addGoodsSecoundData.sort" type="number" value="" placeholder="请输入商品排序"
placeholder-class="inputPlaceHolder" />
</view>
</view>
</view>
<view class="content_list">
<view class="content_list_item" @click="inputGoodsDetils">
<view>商品详情</view>
<view class="content_list_item_han">
<span v-if="disModel" style="color: #000000">去修改</span>
<span v-else>设置详情</span>
<span class="iconfont">&#xe6bd;</span>
</view>
</view>
<view class="content_list_video">
<view class="content_list_video_title">商品视频</view>
<view class="video_list">
<view class="video_list_item photo" v-if="addGoodsSecoundData.video_link">
<view class="jiao" @click="deleteImage()">
<!-- video标签在app端层级过高 -->
<!--#ifndef APP-PLUS-->
<video :src="addGoodsSecoundData.video_link"></video>
<!--#endif-->
<!--#ifdef APP-PLUS-->
<img src="https://lihai001.oss-cn-chengdu.aliyuncs.com/public/kk/luzhou/static4/3/video_bg.png" style=" width:150rpx" ></img>
<!--#endif-->
<image src="../static/images/close.png" mode="widthFix"></image>
<view>
<block v-if="showComponent">
<view class=" writeBg ">
<view class="container_input marginTop_none">
<view class="container_input_item">
<view class="container_input_item_label"><span>是否推荐</span></view>
<view class="container_input_item_value">
<switch :checked="addGoodsSecoundData.is_good == 1" color="#E93323" style="transform:scale(0.8)"
@change="isGood" />
</view>
<!--#ifndef APP-PLUS-->
<view style="position: absolute;">
<view class="videoHover" @click="videoshow">
</view>
<text class="video-text">点击可预览视频</text>
</view>
<!--#endif-->
<!--#ifdef APP-PLUS-->
<view class='preview_video'>
<view class="videoHover" @click="videoshow">
</view>
<text class="video-text">点击可预览视频</text>
</view>
<!--#endif-->
</view>
<view class="photo" @click="uploadVideo" v-else>
<view>
<image src="../static/images/creamer.png" mode="widthFix"></image>
<view class="container_input_item">
<view class="container_input_item_label"><span>是否开启礼包</span></view>
<view class="container_input_item_value">
<switch :checked="addGoodsSecoundData.is_gift_bag == 1" color="#E93323" style="transform:scale(0.8)"
@change="isGiftBag" />
</view>
<view>添加视频</view>
</view>
</view>
</view>
</view>
<view v-if="showVideo" class="video-count">
<!--#ifndef APP-PLUS-->
<video id="myVideo" class="videoLink" autoplay loop muted :src="addGoodsSecoundData.video_link"></video>
<!--#endif-->
<!--#ifdef APP-PLUS-->
<view class="tip">
<span class="iconfont">&#xe688;</span>
<span>开启后此商品只能在分销礼包中展示并销售</span>
</view>
<view class="container_input marginTop_none">
<view class="container_input_item">
<view class="container_input_item_label"><span>限购数量</span></view>
<view class="container_input_item_value">
<input v-model="addGoodsSecoundData.once_count" type="number" value="" placeholder="请输入限购数量"
placeholder-class="inputPlaceHolder" />
</view>
</view>
<view class="container_input_item">
<view class="container_input_item_label"><span>商品排序</span></view>
<view class="container_input_item_value">
<input v-model="addGoodsSecoundData.sort" type="number" value="" placeholder="请输入商品排序"
placeholder-class="inputPlaceHolder" />
</view>
</view>
</view>
<view class="content_list">
<view class="content_list_item" @click="inputGoodsDetils">
<view>商品详情</view>
<view class="content_list_item_han">
<span v-if="disModel" style="color: #000000">去修改</span>
<span v-else>设置详情</span>
<span class="iconfont">&#xe6bd;</span>
</view>
</view>
<view class="content_list_video">
<view class="content_list_video_title">商品视频</view>
<view class="video_list">
<view class="video_list_item photo" v-if="addGoodsSecoundData.video_link">
<view class="jiao" @click="deleteImage()">
<!-- video标签在app端层级过高 -->
<!--#ifndef APP-PLUS-->
<video :src="addGoodsSecoundData.video_link"></video>
<!--#endif-->
<!--#ifdef APP-PLUS-->
<img src="https://lihai001.oss-cn-chengdu.aliyuncs.com/public/kk/luzhou/static4/3/video_bg.png"
style=" width:150rpx"></img>
<!--#endif-->
<image src="../static/images/close.png" mode="widthFix"></image>
</view>
<video id="myVideo" class="videoLink" autoplay loop
:src='addGoodsSecoundData.video_link && (addGoodsSecoundData.video_link.substring(0,4) == "http" || addGoodsSecoundData.video_link.substring(0,5) == "https") ?addGoodsSecoundData.video_link : "http:" + addGoodsSecoundData.video_link'></video>
<!--#endif-->
<!--#ifndef APP-PLUS-->
<view style="position: absolute;">
<view class="videoHover" @click="videoshow">
</view>
<text class="video-text">点击可预览视频</text>
</view>
<!--#endif-->
<!--#ifdef APP-PLUS-->
<view class='preview_video'>
<view class="videoHover" @click="videoshow">
</view>
<text class="video-text">点击可预览视频</text>
</view>
<!--#endif-->
</view>
<view class="photo" @click="uploadVideo" v-else>
<view>
<image src="../static/images/creamer.png" mode="widthFix"></image>
</view>
<view>添加视频</view>
</view>
</view>
</view>
</view>
<view v-if="showVideo" class="video-count">
<!--#ifndef APP-PLUS-->
<video id="myVideo" class="videoLink" autoplay loop muted :src="addGoodsSecoundData.video_link"></video>
<!--#endif-->
<!--#ifdef APP-PLUS-->
<video id="myVideo" class="videoLink" autoplay loop
:src='addGoodsSecoundData.video_link && (addGoodsSecoundData.video_link.substring(0,4) == "http" || addGoodsSecoundData.video_link.substring(0,5) == "https") ?addGoodsSecoundData.video_link : "http:" + addGoodsSecoundData.video_link'></video>
<!--#endif-->
</view>
<view class='mask' catchtouchmove="true" :hidden='showVideo==false' @tap="showVideo=false"></view>
<view class="handle dobuButton">
<view class="handle_button margin_right" @click="lastStep">上一步</view>
<view class="handle_button" @click="submitCreatedGoods">提交</view>
</view>
</view>
<view class='mask' catchtouchmove="true" :hidden='showVideo==false' @tap="showVideo=false"></view>
<view class="handle dobuButton">
<view class="handle_button margin_right" @click="lastStep">上一步</view>
<view class="handle_button" @click="submitCreatedGoods">提交</view>
</view>
</block>
<view class="handle_button" @click="submitCreatedGoods">提交</view>
</view>
</template>
<script>
@ -148,7 +154,8 @@
},
data() {
return {
showVideo:false,
showComponent: false,
showVideo: false,
disModel: false,
upload_max: 10,
uploadUrl: `${HTTP_REQUEST_URL}/api/upload/video`,
@ -166,7 +173,7 @@
// console.log('123');
this.initData();
},
watch: {
addGoodsSecoundData: {
handler(val) {
@ -184,16 +191,16 @@
}
},
methods: {
videoshow() {
this.showVideo = true
this.videoContext = uni.createVideoContext('myVideo', this);
this.$nextTick(() => {
this.videoContext.play();
})
// this.video_link = this.formData.video_link;
// this.videoContext.requestFullScreen({ direction: 90 });
// this.videoContext.play(); this.videoplay = true;
},
videoshow() {
this.showVideo = true
this.videoContext = uni.createVideoContext('myVideo', this);
this.$nextTick(() => {
this.videoContext.play();
})
// this.video_link = this.formData.video_link;
// this.videoContext.requestFullScreen({ direction: 90 });
// this.videoContext.play(); this.videoplay = true;
},
initData() {
let editGoodsDetils = {};
if (getStorage('goodsDis')) {
@ -235,7 +242,7 @@
submitCreatedGoods() {
Loading();
let waitDeleteData = ['addGoodsFormData', 'singleSpecification', 'attrValue', 'modifyPriceData',
'addGoodsSecoundData', 'goodsDis', 'editGoodsDetils', 'canChange', 'canChangeSecound'
'addGoodsSecoundData', 'goodsDis', 'editGoodsDetils', 'canChange', 'canChangeSecound', 'editCommodity'
];
let attrValue = getStorage('addGoodsFormData').spec_type == 0 ? [getStorage('singleSpecification')] :
getStorage('attrValue');
@ -248,12 +255,25 @@
},
video_link: this.addGoodsSecoundData.video_link
};
if(attrValue){
postData.attrValue = attrValue.filter(item => item != '');
postData.attrValue[0].bar_code
}
// console.log(postData);
if (attrValue) {
postData.attrValue = attrValue.filter(item => item != '');
postData.attrValue[0].bar_code
}
let info = getStorage('editCommodity');
Object.keys(info).forEach(key=>{
postData[key]=info[key];
})
postData.stock = postData.attrValue[0].stock;
console.log(postData);
if(postData.store_name.trim().length<=0)return Toast('请输入商品名称');
if(postData.imageList.length<=0)return Toast('请上传商品图片');
if(postData.cate_name.trim().length<=0)return Toast('请选择平台分类');
if(postData.unit_name.trim().length<=0)return Toast('请输入商品单位');
if(!postData.attrValue[0].price||postData.attrValue[0].price<0)return Toast('价格不能小于0');
if(!postData.stock||postData.stock<0)return Toast('库存不能小于0');
if(postData.content.title.trim().length<=0)return Toast('请输入商品详情');
if(postData.content.image.length<=0)return Toast('请上传商品图片');
// return Toast('');
if (getStorage('addGoodsFormData').spec_type == 0) {
// postData.attr = [getStorage('singleSpecification')];
}
@ -269,7 +289,7 @@
Modal('提交成功', '点击确定,返回商品管理', {
showCancel: false
}).then(() => {
uni.removeStorageSync('singleSpecification')
uni.removeStorageSync('singleSpecification')
uni.redirectTo({
url: '/pages/product/goodsOnSale/index?mer_id=' + this.merId
})
@ -322,8 +342,8 @@
uni.chooseVideo({
sourceType: ['camera', 'album'],
success: res => {
console.log(res)
console.log(res)
if (Math.ceil(res.size / 1024) < this.upload_max * 1024) {
uni.uploadFile({
url: this.uploadUrl, //
@ -355,11 +375,11 @@
}
},
fail: err => {
//
//
// uni.showModal({
// content: JSON.stringify(err)
// });
console.log(err)
console.log(err)
}
});
},
@ -413,32 +433,34 @@
}
}
}
.videoHover {
width: 180rpx;
height: 180rpx;
.videoHover {
width: 180rpx;
height: 180rpx;
display: flex;
align-items: center;
justify-content: center;
position: absolute;
top: 0;
left: 0;
z-index: 10;
view {
width: 50rpx;
height: 50rpx;
background: #000000;
border-radius: 50rpx;
display: flex;
align-items: center;
justify-content: center;
position: absolute;
top: 0;
left: 0;
z-index: 10;
view {
width: 50rpx;
height: 50rpx;
background: #000000;
border-radius: 50rpx;
display: flex;
align-items: center;
justify-content: center;
.iconfont {
color: #ffffff;
font-size: 21rpx;
}
.iconfont {
color: #ffffff;
font-size: 21rpx;
}
}
}
.photo {
border: 1px solid #dddddd;
opacity: 1;
@ -481,10 +503,12 @@
height: 150rpx;
}
}
.preview_video{
position: absolute;
}
.preview_video {
position: absolute;
}
.container_input {
background: #fff;
padding: 0 20rpx;
@ -603,6 +627,7 @@
.marginTop_none {
margin-top: 0;
}
.video-count {
position: fixed;
width: 600rpx;
@ -621,6 +646,7 @@
height: 500rpx;
}
}
// .writeBg {
// background: #fff;
// }

View File

@ -14,7 +14,7 @@
<script>
import selectForm from '../components/selectForm.vue';
import { navigateTo, navigateBack, serialize, setStorage, getStorage} from '../../../libs/uniApi.js';
import { navigateTo, navigateBack, serialize, setStorage, getStorage } from '../../../libs/uniApi.js';
// attrValue
export default {
components:{

View File

@ -7,8 +7,10 @@
<view class="store_bg">
<view class="text flex_a_c"><i class="iconfont icon-xinghao"></i>上传店铺背景图</view>
<block v-if="images[0].img">
<u--image :showLoading="true" :src="images[0].img" width="388px" height="210.53rpx" radius="4px"
@click="delImg(0)" mode="aspectFit"></u--image>
<!-- <u--image :showLoading="true" :src="images[0].img" width="388px" height="210.53rpx" radius="4px"
@click="delImg(0)" mode="aspectFit"></u--image> -->
<u--image :showLoading="true" :src="images[0].img" width="360px" height="210.53rpx" radius="4px"
@click="delImg(2)"></u--image>
</block>
<view v-else class="upload" @click="seleckImage(0)">
<view class="iconfont icon-tupian1"></view>
@ -133,12 +135,12 @@
<input class="com_input" type="number" v-model="servicePhone" placeholder="输入客服电话">
</view>
<!-- <view class="item_cell flex_a_c" v-if="type_code!='TypeFamousSpecialties'||type_code!='TypeLocalCuisine'||type_code!='TypeFeaturedCultural'" >
<!-- <view class="item_cell flex_a_c" v-if="type_code!='TypeFamousSpecialties'||type_code!='TypeLocalCuisine'||type_code!='TypeFeaturedCultural'" >
<view class="sub_title flex_a_c"><i class="iconfont icon-xinghao" v-if="credit_buy"></i>开启先货后款</view>
<u-switch v-model="credit_buy" @change="change"></u-switch>
</view> -->
</view>
<!-- <view class="item_cell flex_a_c" v-if="credit_buy">
<view class="item_cell flex_a_c" v-if="credit_buy">
<view class="sub_title flex_a_c"><i class="iconfont icon-xinghao"></i>先货后款结算周期</view>
<input type="number" v-model="settle_cycle" placeholder="请输入 /周期单位为:天">
</view>
@ -146,8 +148,8 @@
<view class="item_cell flex_a_c" v-if="credit_buy">
<view class="sub_title flex_a_c"><i class="iconfont icon-xinghao"></i>先货后款结算利率</view>
<input type="number" maxlength="5" v-model="interest_rate" placeholder="请输入 /利率单位为: %">
</view> -->
<!-- <view class="remarks">*利率结算范围为:0.01 ~ 0.1 利率单位为:%</view> -->
</view>
<view class="remarks">*利率结算范围为:0.01 ~ 0.1 利率单位为:%</view> -->
<!-- <view class="item_cell">
<view class="if_btn flex_a_c_j_sb">
<text class="sub_title">是否开启商户</text>

View File

@ -1,7 +1,7 @@
<template>
<view class="input_content">
<view class="input_content_textarea">
<textarea v-model="prodectContent.store_name" placeholder="请输入简介" placeholder-class="placeholderStyle"
<textarea v-model="prodectContent.store_name" placeholder="请输入商品详情" placeholder-class="placeholderStyle"
:maxlength="maxLength" />
<view><text v-if="prodectContent.store_name">{{prodectContent.store_name.length}}</text><text
v-else>0</text>/{{maxLength}}</view>
@ -31,7 +31,8 @@
<text v-else>0</text>/200
</view>
</view>
<view class="input_content_describe_textarea"><textarea v-model="prodectContent.store_info" value=""
<view class="input_content_describe_textarea">
<textarea v-model="prodectContent.store_info" value=""
placeholder="请填写商品简介" placeholderClass="placeholderClass" maxlength="200" /></view>
</view>
@ -40,7 +41,7 @@
<view class="input_content_keyword_value"><input v-model="prodectContent.keyword" type="text" value=""
placeholder="填写关键字" /></view>
</view>
<avatar @upload="doUpload" @getName="getImgName" quality="1" ref="avatar" selWidth="250upx" selHeight="250upx">
<avatar style="height: 1px;" @upload="doUpload" @getName="getImgName" quality="1" ref="avatar" selWidth="250upx" selHeight="250upx">
</avatar>
</view>
</template>
@ -90,7 +91,7 @@
prodectContent: {
handler(val) {
// console.log(val.store_name);
this.upstore=val.store_name
this.upstore=val.store_name
this.$emit('getProductContent', val);
},
@ -110,7 +111,7 @@
}
},
mounted() {
console.log(this.$props.prodectContent);
},
methods: {
handleChooseImage() {

View File

@ -5,7 +5,7 @@
<view class="title_search">
<span class="iconfont">&#xe67d;</span>
<form @submit="search" report-submit="true">
<input type="text" :name="where.keyword" v-model="where.keyword" placeholder="搜索商品" confirm-type='search'/>
<input type="text" v-model="where.keyword" placeholder="搜索商品" confirm-type='search'/>
</form>
</view>
</view>

View File

@ -47,12 +47,13 @@
<swiper-item :class="{ active: 1 == swiperCur }">
<view class="slide-navigator">
<!-- 隐藏暂时不需要 -->
<!-- <navigator class="item" :url="`/pages/product/addGoods/freightTemplate?mer_id=${mer_id}`"
hover-class='none'>
<image mode='widthFix' class="image" src="../static/images/product_freight.png">
</image>
<text class="text">运费模板</text>
</navigator> -->
<!-- <navigator class="item"
:url="`/pages/product/addGoods/freightTemplate?mer_id=${mer_id}`"
hover-class='none'>
<image mode='widthFix' class="image" src="../static/images/product_freight.png">
</image>
<text class="text">运费模板</text>
</navigator> -->
<navigator class="item"
:url="`/pages/product/addGoods/mulSpecification?mer_id=${mer_id}`"
hover-class='none'>
@ -60,7 +61,7 @@
src="../static/images/product_specification.png"></image>
<text class="text">规格模板</text>
</navigator>
<!-- <navigator class="item"
<!-- <navigator class="item"
:url="`/pages/users/online_warehousing/index?mer_id=${mer_id}&product_id=${data.product_id}&unique=${data.unique}`"
hover-class='none'>
<image mode='widthFix' class="image" src="@/static/images/daoru.png"></image>
@ -124,7 +125,7 @@
</view>
<view class="operation acea-row row-between-wrapper">
<view class="acea-row row-middle">
<!-- <view class="" class="bnt" @click="Fonline(item)" style="width:150rpx">
<!-- <view class="" class="bnt" @click="Fonline(item)" style="width:150rpx">
线上入库
</view> -->
<view class="" class="bnt" @click="Fline(item)" style="width:150rpx">
@ -169,7 +170,7 @@
</view>
</scroll-view>
</view>
<view class="shuru" v-if="this.on_line == 1">
数量: <input type="number" v-model="data.number" placeholder="请输入">
</view>
@ -245,7 +246,8 @@
on_line: '',
isshow: false,
num: -1,
ll: 0
ll: 0,
}
},
onLoad(options) {
@ -262,10 +264,10 @@
},
onReachBottom() {
// console.log(this.status, '222222222')
if (this.status == 'nomore') return;
if (this.status == 'nomore') return;
this.status = 'loading';
this.where.page = ++this.where.page;
this.getList(this.mer_id, true);
this.getList(this.mer_id, false);
},
methods: {
@ -342,7 +344,17 @@
this.checkboxList1 = item.attrValue
this.data.product_id = item.attrValue[0].product_id
this.data.unique = item.attrValue[0].unique
this.show = true
if (item.spec_type == 1) {
this.show = true
} else {
navigateTo(1, '/pages/users/online_warehousing/index', {
mer_id: this.mer_id,
product_id: this.data.product_id,
unique: this.data.unique,
});
}
},
//线
@ -381,8 +393,8 @@
} else {
postImport(this.mer_id, this.data).then(res => {
this.data.unique = ''
this.data.product_id=''
this.data.number=1
this.data.product_id = ''
this.data.number = 1
this.loading = false
this.loaded = false
this.getList(this.mer_id, true);
@ -391,15 +403,15 @@
title: res.message
})
this.data.unique = ''
this.data.product_id=''
this.data.number=1
this.data.product_id = ''
this.data.number = 1
}).catch(err => {
this.show = false
this.data.unique = ''
this.data.product_id=''
this.data.number=1
this.data.product_id = ''
this.data.number = 1
this.$util.Tips({
title: '请选择规格后再次进行入库'
})
@ -414,12 +426,15 @@
title: '请选择规格'
})
} else {
navigateTo(1, '/pages/users/online_warehousing/index', {
mer_id: this.mer_id,
product_id: this.data.product_id,
unique: this.data.unique,
});
}
}
@ -474,8 +489,8 @@
res => {
that.loading = false;
that.loaded = res.data.list.length < that.where.limit;
// that.productList.push.apply(that.productList, res.data.list);
that.productList.push(...res.data.list);
that.productList.push.apply(that.productList, res.data.list);
that.where.page = that.where.page + 1;
},
@ -541,6 +556,7 @@
title: '下架成功',
icon: 'none'
})
that.getList(this.mer_id,false)
} else if (res.cancel) {
// console.log('');
}
@ -561,6 +577,7 @@
icon: 'success'
}, () => {
that.$set(item, 'is_show', item.is_show == 0 ? 1 : 0);
that.getList(this.mer_id,false)
});
}).catch(err => {
return that.$util.Tips({

View File

@ -1,163 +0,0 @@
<template>
<view class="content">
<view class="">
<view class="content_con" v-for="(item,index) in datalist" :key='index'>
<view class="content_title">
<view class="content_title_a" v-if="item.status==1">
已通过
</view>
<view class="content_title_c" v-else-if="item.status==2">
已拒绝
</view>
<view class="content_title_b" v-else-if="item.status==0">
审核中
</view>
<view class="content_title_d">
{{item.mer_name}}
</view>
</view>
<view class="" v-if="item.fail_msg" style="margin-top: -50rpx;color: red;">
拒绝原因{{item.fail_msg}}
</view>
<view class="content_detail">
<view class="" style="display: flex;">
<view style="width:150rpx;"> 申请人</view>
<span>{{item.name}}</span><text style="margin-left: 20rpx;">{{item.phone}}</text>
</view>
<view class="" style="display: flex;">
<view style="width:150rpx;"> 申请时间</view>
<span>{{item.create_time}}</span>
</view>
</view>
</view>
</view>
<view class="" style="padding-top: 1px;" v-if='datalist.length==0'>
<emptyPage title="暂无申请信息"></emptyPage>
</view>
</view>
</template>
<script>
import emptyPage from '@/components/emptyPage.vue';
import {
intention
} from "@/api/product"
export default {
components: {
emptyPage
},
data() {
return {
datalist: [],
where: {
type: 2,
page: 1,
limit: 10
},
}
},
onLoad() {
this.list()
},
methods: {
list() {
intention(this.where).then(res => {
this.datalist = res.data.list
})
}
}
}
</script>
<style lang="scss">
.content {
padding: 12rpx 12rpx;
}
.content_con {
padding: 42rpx 32rpx;
height: 294rpx;
background: #FFFFFF;
border-radius: 21rpx 21rpx;
margin-top: 20rpx;
}
.content_title {
display: flex;
margin-bottom: 70rpx;
}
.content_title_a {
width: 89rpx;
height: 37rpx;
line-height: 37rpx;
text-align: center;
background: #16C295;
font-size: 23rpx;
font-family: DingTalk JinBuTi-Regular, DingTalk JinBuTi;
font-weight: 400;
color: #FFFFFF;
border-radius: 15rpx 0 15rpx 0;
}
.content_title_b {
width: 89rpx;
height: 37rpx;
line-height: 37rpx;
text-align: center;
background: #3274F9;
font-size: 23rpx;
font-family: DingTalk JinBuTi-Regular, DingTalk JinBuTi;
font-weight: 400;
color: #FFFFFF;
border-radius: 15rpx 0 15rpx 0;
}
.content_title_c {
width: 89rpx;
height: 37rpx;
line-height: 37rpx;
text-align: center;
background: #ff0000;
font-size: 23rpx;
font-family: DingTalk JinBuTi-Regular, DingTalk JinBuTi;
font-weight: 400;
color: #FFFFFF;
border-radius: 15rpx 0 15rpx 0;
}
.content_title_d {
font-size: 33rpx;
font-family: PingFang SC-Medium, PingFang SC;
font-weight: 500;
color: #333333;
margin-left: 20rpx;
margin-top: -7rpx;
}
.content_detail {
font-size: 30rpx;
font-family: PingFang SC-Regular, PingFang SC;
font-weight: 400;
color: #333333;
view {
margin-bottom: 10rpx;
}
}
</style>

View File

@ -1,241 +0,0 @@
<template>
<view v-if="!successful" class="content">
<view class="content-detail">
<view class="content-title">
<view class="content-title-a">
交易申请协议
</view>
<view class="content-title-b" @click="navation">
申请记录
</view>
</view>
<view class="">
<view v-html="detail.business_apply_agree">
</view>
</view>
</view>
<view class="content-bottom" v-if="type==0">
<view class="bottombtn_no" @click="noagree">拒绝</view>
<view class="bottom_agree" @click="agree">同意</view>
</view>
<view class="content-bottom" v-if="type==1||type==3">
<view class="bottom_agree" @click="agree">重新申请</view>
</view>
</view>
<view class="settledSuccessMain" v-else>
<view class="settledSuccessful">
<image class="image" src="@/pages/store/static/images/settledSuccessful.svg">
<view class="title">恭喜您的资料提交成功</view>
<view class="info">预计15个工作日内审核完毕平台客服会及时与您联系</view>
<view class="goHome" hover-class="none" @click="goHome">
返回首页
</view>
</view>
</view>
</template>
<script>
import {
business,
intentionbus
} from "@/api/product"
export default {
data() {
return {
detail: {},
type: 0,
successful: false
}
},
onLoad(e) {
this.type = e.business_status
this.list()
},
methods: {
//
list() {
business().then(res => {
this.detail = res.data
})
},
//
goHome() {
uni.switchTab({
url: '/pages/index/index'
});
},
//
navation() {
uni.navigateTo({
url: '/pages/product/transactionApplication/application'
})
},
//
noagree() {
uni.navigateTo({
url: '/pages/moreProject/moreProject'
})
},
//
agree() {
intentionbus().then(res => {
if (res.status == 200) {
this.$util.Tips({
title: res.message,
icon: 'success',
})
this.successful=true
}
}).catch((err) => {
this.$util.Tips({
title: err,
icon: 'error',
})
})
},
}
}
</script>
<style lang="scss" scoped>
.content {
position: relative;
}
.content-detail {
padding: 20rpx 20rpx;
color: #333333;
font-size: 28rpx;
margin-bottom: 155rpx;
.content-title {
color: #333333;
font-size: 32rpx;
text-align: center;
margin-top: 40rpx;
margin-bottom: 40rpx;
.content-title-b {
width: 165rpx;
height: 70rpx;
font-size: 26rpx;
font-family: PingFang SC-Regular, PingFang SC;
font-weight: 400;
color: #FFFFFF;
text-align: center;
line-height: 70rpx;
background: linear-gradient(90deg, #F84221 0%, #FF6D20 100%);
box-shadow: 0px 4rpx 11rpx 2rpx rgba(252, 89, 32, 0.49);
border-radius: 37rpx 0px 0px 37rpx;
opacity: 1;
position: absolute;
top: 40rpx;
right: 0;
}
}
}
.content-bottom {
position: absolute;
width: 100%;
bottom: 0;
position: fixed;
height: 175rpx;
background: #FFFFFF;
display: flex;
justify-content: space-around;
.bottombtn_no {
margin-top: 42rpx;
width: 249rpx;
height: 84rpx;
text-align: center;
line-height: 84rpx;
border-radius: 46rpx 46rpx;
opacity: 1;
border: 2rpx solid #B3B3B3;
font-size: 33rpx;
font-family: PingFang SC-Medium, PingFang SC;
font-weight: 500;
color: #737373;
}
.bottom_agree {
margin-top: 42rpx;
width: 249rpx;
height: 84rpx;
text-align: center;
line-height: 84rpx;
background: linear-gradient(270deg, #FF6D20 0%, #F84221 100%);
border-radius: 46rpx 46rpx;
opacity: 1;
font-size: 33rpx;
font-family: PingFang SC-Medium, PingFang SC;
font-weight: 500;
color: #fff;
}
}
.settledSuccessMain {
height: 100vh;
display: flex;
flex-direction: column;
background: #fff;
}
.settledSuccessful {
flex: 1;
width: 100%;
padding: 0 56px;
height: auto;
background: #fff;
text-align: center;
}
.settledSuccessful .image {
width: 189px;
height: 157px;
margin-top: 66px;
}
.settledSuccessful .title {
color: #333333;
font-size: 16px;
font-weight: bold;
margin-top: 35px;
}
.settledSuccessful .info {
color: #A0A0A0;
font-size: 13px;
margin-top: 12px;
}
.settledSuccessful .goHome {
margin: 60px auto 0;
line-height: 43px;
color: #282828;
font-size: 15px;
border: 1px solid #B4B4B4;
border-radius: 60px;
}
</style>

View File

@ -309,7 +309,7 @@
</view>
</uni-popup>
<!-- 他提到的宝贝弹窗 -->
<uni-popup type="bottom" ref="pinglunMentioned" style="background-color: rebeccapurple;">
<uni-popup type="bottom" ref="pinglunMentioned" >
<mentioned ref="mentioned" @close="closePopup" :list="moreList" :uid="authorUid" ></mentioned>
@ -718,12 +718,14 @@
// });
// })'
// that.isUser ?
videoList({
page: that.page,
limit: that.limit,
id: this.videoID
}).then(res => {
console.log(res.data,'1')
that.getVideoData(res.data.list);
})
@ -899,7 +901,7 @@
deoList(this.videoID).then(async (res) => {
this.loadVideo = false
this.userUid = res.data.uid
this.page = this.page + 1;
this.page = 1;
var msg = [res.data];
for (let i = 0; i < msg.length; i++) {
msg[i]['isMore'] = false

File diff suppressed because one or more lines are too long

View File

@ -6,7 +6,7 @@
恭喜您的申请已通过
</view>
</view>
<view class="msg" v-if="mer_id > 0 && resData.login_url">
<!-- <view class="msg" v-if="mer_id > 0 && resData.login_url">
<view class="url">
<text class="head">登录地址</text>
<text class="content">{{resData.login_url}}</text>
@ -18,7 +18,7 @@
</view>
<text class="cope" @click="copyTBL()">复制</text>
</view>
</view>
</view> -->
<view class="btn" v-if="mer_id > 0">
<view class="">
温馨提示初始密码默认为手机号后六位请初次登录后及时修改

View File

@ -1,235 +1,259 @@
<template>
<view v-if="!successful" :style="viewColor">
<form report-submit='true'>
<view class='merchantsSettled'>
<view class="merchantBgCount">
<image mode="widthFix" class="merchantBg" :src="domain+'/static/diy/merchantBg'+keyColor+'.jpg'"
alt="">
</view>
<view class="application-record" @click="jumpToList">
申请记录
<text class="iconfont icon-xiangyou"></text>
</view>
<view class='list'>
<view class="item">
<view class="acea-row row-middle">
<text class="item-name">商户名称</text>
<input type="text" maxlength="30" placeholder="请输入商户名称"
v-model="merchantData.enterprise_name" @input="validateBtn"
placeholder-class='placeholder' />
</view>
</view>
<view class="">
<!-- #ifdef MP || APP-PLUS -->
<view class="conten-top" :style="'height:'+statusBarHeight+'px'">
<view class="" style="position: absolute;left: 30rpx;bottom: 15rpx;" @click="logout"><i
class="iconfont icon-xiangzuo" style="font-size: 40rpx;text-align: left;"></i></view>
<view class=""
style="position: absolute;left: 30rpx;bottom: 15rpx;width: 120rpx; left:50%;margin-left:-60rpx;">
商家入驻
</view>
</view>
<view :style="'height:'+statusBarHeight+'px'"></view>
<!-- #endif -->
<view class="item">
<view class="acea-row row-middle">
<text class="item-name">联系电话</text>
<input type="text" placeholder="请输入手机号" v-model="merchantData.phone" @input="validateBtn"
placeholder-class='placeholder' />
</view>
<view v-if="!successful" :style="viewColor">
<form report-submit='true'>
<view class='merchantsSettled'>
<view class="merchantBgCount">
<image mode="widthFix" class="merchantBg" :src="domain+'/static/diy/merchantBg'+keyColor+'.jpg'"
alt="">
</view>
<view class="item rel">
<view class="acea-row row-middle">
<text class="item-name">验证码</text>
<input type="text" placeholder="填写验证码" v-model="merchantData.yanzhengma"
@input="validateBtn" class="codeIput" placeholder-class='placeholder' />
<button class="code" :disabled="disabled" :class="disabled === true ? 'on' : ''"
@click="handleVerify">
{{ text }}
</button>
</view>
<view class="application-record" @click="jumpToList">
申请记录
<text class="iconfont icon-xiangyou"></text>
</view>
<view class="item" v-if="isShowCode">
<view class="acea-row row-middle">
<text class="item-name">验证码</text>
<input type="text" placeholder="请输入验证码" class="codeIput" v-model="codeVal"
@input="validateBtn" placeholder-class='placeholder' />
<view class="imageCode" @click="again">
<image :src="codeUrl" />
<view class='list'>
<view class="item">
<view class="acea-row row-middle">
<text class="item-name">商户名称</text>
<input type="text" maxlength="30" placeholder="请输入商户名称"
v-model="merchantData.enterprise_name" @input="validateBtn"
placeholder-class='placeholder' />
</view>
</view>
</view>
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name">商户分类</text>
<picker @change="bindPickerChange" :value="index" :range="array"
range-key="category_name">
<input placeholder="请选择商户分类" type="text" readonly disabled
v-model="mer_classification">
<view class='iconfont icon-jiantou'></view>
</picker>
<view class="item">
<view class="acea-row row-middle">
<text class="item-name">联系电话</text>
<input type="text" placeholder="请输入手机号" v-model="merchantData.phone"
@input="validateBtn" placeholder-class='placeholder' />
</view>
</view>
<view class="item rel">
<view class="acea-row row-middle">
<text class="item-name">验证码</text>
<input type="text" placeholder="填写验证码" v-model="merchantData.yanzhengma"
@input="validateBtn" class="codeIput" placeholder-class='placeholder' />
<button class="code" :disabled="disabled" :class="disabled === true ? 'on' : ''"
@click="handleVerify">
{{ text }}
</button>
</view>
</view>
<view class="item" v-if="isShowCode">
<view class="acea-row row-middle">
<text class="item-name">验证码</text>
<input type="text" placeholder="请输入验证码" class="codeIput" v-model="codeVal"
@input="validateBtn" placeholder-class='placeholder' />
<view class="imageCode" @click="again">
<image :src="codeUrl" />
</view>
</view>
</view>
</view>
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name">店铺类型</text>
<text class="iconfont wenhao" @click="getAgreement">?</text>
<picker @change="bindPickerChange1" :value="index1" :range="storeTypeArr"
range-key="type_name">
<input placeholder="请选择店铺类型" type="text" disabled readonly
v-model="mer_storeType">
<view v-if="mer_storeType" @tap.stop="mer_storeType=''"
class="iconfont icon-guanbi2"></view>
<view class='iconfont icon-jiantou'></view>
</picker>
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name">商户分类</text>
<picker @change="bindPickerChange" :value="index" :range="array"
range-key="category_name">
<input placeholder="请选择商户分类" type="text" readonly disabled
v-model="mer_classification">
<view class='iconfont icon-jiantou'></view>
</picker>
</view>
</view>
</view>
</view>
</view>
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name businessBox">店铺所在地</text>
<picker mode=multiSelector @change="bindPickerChange2" :value="index2"
:range="business" range-key="name" @columnchange="pickerColumnchange">
<input class="businessBox" placeholder="请选择商圈" type="text" readonly disabled
v-model="business_name">
<view class='iconfont icon-jiantou'></view>
</picker>
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name">店铺类型</text>
<text class="iconfont wenhao" @click="getAgreement">?</text>
<picker @change="bindPickerChange1" :value="index1" :range="storeTypeArr"
range-key="type_name">
<input placeholder="请选择店铺类型" type="text" disabled readonly
v-model="mer_storeType">
<view v-if="mer_storeType" @tap.stop="mer_storeType=''"
class="iconfont icon-guanbi2"></view>
<view class='iconfont icon-jiantou'></view>
</picker>
</view>
</view>
</view>
</view>
</view>
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name businessBox">详细地址</text>
<input type="text" maxlength="30" placeholder="请输入详细地址"
v-model="merchantData.address" @input="validateBtn"
placeholder-class='placeholder' />
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name businessBox">店铺所在地</text>
<picker mode=multiSelector @change="bindPickerChange2" :value="index2"
:range="business" range-key="name" @columnchange="pickerColumnchange">
<input class="businessBox" placeholder="请选择商圈" type="text" readonly disabled
v-model="business_name">
<view class='iconfont icon-jiantou'></view>
</picker>
</view>
</view>
</view>
</view>
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name businessBox">详细地址</text>
<input type="text" maxlength="30" placeholder="请输入详细地址"
v-model="merchantData.address" @input="validateBtn"
placeholder-class='placeholder' />
</view>
</view>
</view>
</view>
</view>
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name businessBox">公司名称</text>
<input type="text" maxlength="30" placeholder="请输入公司名称"
v-model="merchantData.company_name" @input="validateBtn"
placeholder-class='placeholder' />
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name businessBox">公司名称</text>
<input type="text" maxlength="30" placeholder="请输入公司名称"
v-model="merchantData.company_name" @input="validateBtn"
placeholder-class='placeholder' />
</view>
</view>
</view>
</view>
</view>
<view class="item">
<view class="acea-row row-middle">
<text class="item-name">法人名称</text>
<input type="text" placeholder="请输入法人名称" v-model="merchantData.user_name" @input="validateBtn"
placeholder-class='placeholder' />
<view class="item">
<view class="acea-row row-middle">
<text class="item-name">法人名称</text>
<input type="text" placeholder="请输入法人名称" v-model="merchantData.user_name"
@input="validateBtn" placeholder-class='placeholder' />
</view>
</view>
</view>
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name businessBox">社会信用代码</text>
<input type="text" maxlength="30" placeholder="请输入社会信用代码"
v-model="merchantData.social_credit_code" @input="validateBtn"
placeholder-class='placeholder' />
<view class="item">
<view class="uni-list">
<view class="uni-list-cell">
<view class="uni-list-cell-db acea-row row-middle">
<text class="item-name businessBox">社会信用代码</text>
<input type="text" maxlength="30" placeholder="请输入社会信用代码"
v-model="merchantData.social_credit_code" @input="validateBtn"
placeholder-class='placeholder' />
</view>
</view>
</view>
</view>
</view>
<!-- <view class="item">
<!-- <view class="item">
<view class="acea-row row-middle">
<text class="item-name">是否农贸市场</text>
<u-switch v-model="isnm" @change="change" activeColor="#42CA4C"></u-switch>
</view>
</view> -->
<view class="item no-border">
<view class='acea-row row-middle'>
<text class="item-title">请上传营业执照及行业相关资质证明图片</text>
<text class="item-desc">(图片最多可上传10张,图片格式支持JPGPNGJPEG)</text>
<view class="upload">
<view class='pictrue' v-for="(item,index) in pics" :key="index" :data-index="index"
@click="getPhotoClickIdx">
<image :src='item'></image>
<text class='iconfont icon-guanbi1' @click.stop='DelPic(index)'></text>
</view>
<view class='pictrue acea-row row-center-wrapper row-column' @click='uploadpic'
v-if="pics.length < 10">
<text class='iconfont icon-icon25201'></text>
<view>上传图片</view>
<view class="item no-border">
<view class='acea-row row-middle'>
<text class="item-title">请上传营业执照及行业相关资质证明图片</text>
<text class="item-desc">(图片最多可上传10张,图片格式支持JPGPNGJPEG)</text>
<view class="upload">
<view class='pictrue' v-for="(item,index) in pics" :key="index" :data-index="index"
@click="getPhotoClickIdx">
<image :src='item'></image>
<text class='iconfont icon-guanbi1' @click.stop='DelPic(index)'></text>
</view>
<view class='pictrue acea-row row-center-wrapper row-column' @click='uploadpic'
v-if="pics.length < 10">
<text class='iconfont icon-icon25201'></text>
<view>上传图片</view>
</view>
</view>
</view>
</view>
<view class="item no-border">
<checkbox-group @change='ChangeIsAgree'>
<checkbox class="checkbox" :checked="isAgree ? true : false" />已阅读并同意
</checkbox-group>
<button class="settleAgree" @click="getConfig">入驻协议</button>
</view>
<button class='submitBtn' :class="validate === true? 'on':''" @click="formSubmit">
提交申请
</button>
</view>
<view class="item no-border">
<checkbox-group @change='ChangeIsAgree'>
<checkbox class="checkbox" :checked="isAgree ? true : false" />已阅读并同意
</checkbox-group>
<button class="settleAgree" @click="getConfig">入驻协议</button>
</view>
</form>
<view class="settlementAgreement" v-if="showProtocol">
<view class="setAgCount" style="width: 656rpx;height: 458px;">
<i class="icon iconfont icon-cha" @click="showProtocol = false"></i>
<div class="title">{{isType ? '店铺类型说明' : '商户入驻协议'}}</div>
<view class="content">
<jyf-parser :html="protocol" ref="article" :tag-style="tagStyle"></jyf-parser>
<!-- <view v-html="protocol"></view> -->
</view>
</view>
</view>
<view class="settlementAgreement" v-if="isshow">
<view class="setAgCount" style="width: 100%;height: 100%;padding-top: 180rpx;">
<!-- <i class="icon iconfont icon-cha" @click="recuo"></i> -->
<view class="" style="width: 60rpx;height: 60rpx; position: absolute;left: 30rpx; top:90rpx"
@click="recuo">
<i class="iconfont icon-xiangzuo" style="width: 60rpx;height: 60rpx;font-size: 40rpx;"></i>
<!-- <image src="@/static/images/close.png" mode="aspectFit" style="width: 60rpx;height: 60rpx;"></image> -->
</view>
<button class='submitBtn' :class="validate === true? 'on':''" @click="formSubmit">
提交申请
</button>
<div class="title">{{detail.title}}</div>
<view style="margin: 20rpx 0;">甲方公司:{{company?company:"暂无公司信息"}}</view>
<view style="margin: 20rpx 0;">机构代码:{{organization_code?organization_code:"暂无公司信息"}}</view>
<view class="contenta">
<jyf-parser :html="detail.mer_services_agree" ref="article" :tag-style="tagStyle"></jyf-parser>
</view>
<view class="setAgCountbtn">
<button class="setAgCountbtna" @click="refuse">
拒绝
</button>
<button :class="num>0?'setAgCountbtnb':'setAgCountbtnc'" :disabled="num!=0" @click="agree">
<text v-if="num>0">请仔细阅读协议{{num}}S</text>
<text v-else>同意</text>
</button>
</view>
</view>
</view>
</form>
<view class="settlementAgreement" v-if="showProtocol">
<view class="setAgCount">
<i class="icon iconfont icon-cha" @click="showProtocol = false"></i>
<div class="title">{{isType ? '店铺类型说明' : '商户入驻协议'}}</div>
<view class="content">
<jyf-parser :html="protocol" ref="article" :tag-style="tagStyle"></jyf-parser>
<!-- <view v-html="protocol"></view> -->
</view>
<view class='loadingicon acea-row row-center-wrapper' v-if="loading">
<text class='loading iconfont icon-jiazai' :hidden='loading==false'></text>
</view>
<authorize @onLoadFun="onLoadFun" :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse">
</authorize>
<Verify @success="success" :captchaType="'blockPuzzle'" :imgSize="{ width: '330px', height: '155px' }"
ref="verify">
</Verify>
</view>
<view class="settlementAgreement" v-if="isshow">
<view class="setAgCount">
<i class="icon iconfont icon-cha" @click="recuo"></i>
<div class="title">商户入驻协议</div>
<view class="contenta">
<jyf-parser :html="detail.sys_intention_agree" ref="article" :tag-style="tagStyle"></jyf-parser>
</view>
<view class="setAgCountbtn">
<button class="setAgCountbtna" @click="refuse">
拒绝
</button>
<button :class="num>0?'setAgCountbtnb':'setAgCountbtnc'" :disabled="num!=0" @click="isshow=false">
<text v-if="num>0">请仔细阅读协议{{num}}S</text>
<text v-else>同意</text>
</button>
</view>
<view class="settledSuccessMain " v-else :style="viewColor">
<view class="settledSuccessful">
<image class="image" src="../static/images/settledSuccessful.svg" alt="">
<view class="title">恭喜您的资料提交成功</view>
<view class="info">预计15个工作日内审核完毕平台客服会及时与您联系</view>
<view class="goHome" hover-class="none" @click="goHome">
返回首页
</view>
</view>
</view>
<view class='loadingicon acea-row row-center-wrapper' v-if="loading">
<text class='loading iconfont icon-jiazai' :hidden='loading==false'></text>
</view>
<authorize @onLoadFun="onLoadFun" :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse"></authorize>
<Verify @success="success" :captchaType="'blockPuzzle'" :imgSize="{ width: '330px', height: '155px' }"
ref="verify">
</Verify>
</view>
<view class="settledSuccessMain" v-else :style="viewColor">
<view class="settledSuccessful">
<image class="image" src="../static/images/settledSuccessful.svg" alt="">
<view class="title">恭喜您的资料提交成功</view>
<view class="info">预计15个工作日内审核完毕平台客服会及时与您联系</view>
<view class="goHome" hover-class="none" @click="goHome">
返回首页
</view>
</view>
</view>
</template>
<script>
@ -253,7 +277,8 @@
} from '@/api/store.js';
import {
getCaptcha,
getAgreementApi
getAgreementApi,
merstreet
} from "@/api/user";
import {
getStreet,
@ -266,6 +291,9 @@
import {
configMap
} from "@/utils";
import {
intention,
} from "@/api/product"
import parser from "@/components/jyf-parser/jyf-parser";
import authorize from '@/components/Authorize';
import Verify from '@/components/verify/verify.vue';
@ -281,6 +309,8 @@
},
data() {
return {
company: '',
organization_code: '',
domain: HTTP_REQUEST_URL,
cartId: '', //id
pinkId: 0, //id
@ -343,8 +373,15 @@
},
mer_i_id: null, // id
isType: false,
num: 30,
detail: {}
num: 10,
detail: {},
statusBarHeight: 0,
where: {
type: 1,
page: 1,
limit: 10
},
codenote: []
};
},
beforeDestroy() {
@ -373,17 +410,32 @@
}
this.getArea()
this.shoplist()
this.statusBarHeight = uni.getSystemInfoSync().statusBarHeight + 45;
},
onShow() {
},
onShow() {},
onReady() {},
methods: {
//
codelist() {
intention(this.where).then(res => {
this.codenote = res.data.list
})
},
//退
logout() {
uni.switchTab({
url: '/pages/user/index'
})
},
//
recuo() {
if (this.num > 0) {
this.num = 30
this.num = 10
this.isshow = false
} else {
this.num = 0
this.num = 10
this.isshow = false
}
},
@ -409,7 +461,7 @@
return
}
if (this.isshow == false && this.num > 0) {
this.num = 30
this.num = 10
return
}
this.countDown();
@ -420,8 +472,9 @@
//
shoplist() {
agreeiness().then(res => {
// console.log(res)
agreeiness({
type: 'mer_services_agree'
}).then(res => {
this.detail = res.data
})
},
@ -488,6 +541,8 @@
that.isType = true
getAgreementApi('sys_merchant_type').then(res => {
that.protocol = res.data.sys_merchant_type
})
},
//
@ -550,12 +605,32 @@
},
bindPickerChange2: function(e) {
// console.log(e.detail)
this.index2 = e.detail.value
this.business_name =
`${this.business[0][this.index2[0]].name} ${this.business[1][this.index2[1]].name} ${this.business[2][this.index2[2]].name}`
this.area_id = this.business[0][this.index2[0]].code
this.street_id = this.business[1][this.index2[1]].code
this.village_id = this.business[2][this.index2[2]].id
merstreet({
street_code: this.street_id
}).then((res) => {
if (res.code == 0) {
this.company = ''
this.organization_code = ''
this.$util.Tips({
title: res.msg
});
return false;
} else {
this.company = res.data.title
this.organization_code = res.data.organization_code
}
}).catch(res => {
console.log(res)
})
},
//
getClassfication: function() {
@ -716,77 +791,153 @@
this.isAgree = !this.isAgree;
this.validateBtn();
},
//
//
showxy() {
this.isshow = true
},
formSubmit: function(e) {
if (this.num == 0) {
let that = this;
if (that.validateForm() && that.validate) {
let requestData = {
phone: that.merchantData.phone,
mer_name: that.merchantData.enterprise_name,
name: that.merchantData.user_name,
code: that.merchantData.yanzhengma,
company_name: that.merchantData.company_name,
address: that.merchantData.address,
social_credit_code: that.merchantData.social_credit_code,
merchant_category_id: that.merchantData.classification,
mer_type_id: that.merchantData.mer_type,
mer_storeType: this.mer_storeType,
area_id: this.area_id,
street_id: this.street_id,
village_id: this.village_id,
is_nmsc: this.isnum,
images: that.pics
}
that.validate = false;
if (that.mer_i_id) {
updateGoodsRecord(that.mer_i_id, requestData).then(res => {
if (res.status == 200) {
title: '提交成功',
that.loading = true;
that.timer = setTimeout(() => {
that.successful = true;
that.validate = true;
}, 1000)
}
}).catch(res => {
//
agree() {
let that = this;
let requestData = {
phone: that.merchantData.phone,
mer_name: that.merchantData.enterprise_name,
name: that.merchantData.user_name,
code: that.merchantData.yanzhengma,
company_name: that.merchantData.company_name,
address: that.merchantData.address,
social_credit_code: that.merchantData.social_credit_code,
merchant_category_id: that.merchantData.classification,
mer_type_id: that.merchantData.mer_type,
mer_storeType: this.mer_storeType,
area_id: this.area_id,
street_id: this.street_id,
village_id: this.village_id,
is_nmsc: this.isnum,
images: that.pics
}
that.validate = false;
if (that.mer_i_id) {
updateGoodsRecord(that.mer_i_id, requestData).then(res => {
if (res.status == 200) {
title: '提交成功',
that.loading = true;
that.timer = setTimeout(() => {
that.successful = true;
that.validate = true;
that.$util.Tips({
title: res
});
}, 1000)
}
}).catch(res => {
this.isshow = false
that.validate = true;
that.$util.Tips({
title: res
});
})
} else {
create(requestData).then(data => {
if (data.status == 200) {
title: '提交成功',
that.loading = true;
this.timer = setTimeout(() => {
that.successful = true;
that.validate = true;
}, 1000)
}
}).catch(res => {
this.isshow = false
that.validate = true;
that.$util.Tips({
title: res
});
})
}
},
formSubmit() {
if (this.validateForm() && this.validate) {
if (this.codenote.length == 0) {
this.isshow = true
this.countDown()
} else {
if (this.codenote[0].status == 0) {
uni.showModal({
title: '申请正在审核中,请勿重复提交'
})
} else {
create(requestData).then(data => {
if (data.status == 200) {
title: '提交成功',
that.loading = true;
this.timer = setTimeout(() => {
that.successful = true;
that.validate = true;
}, 1000)
}
}).catch(res => {
that.validate = true;
that.$util.Tips({
title: res
});
})
this.isshow = true
this.countDown()
}
}
} else {
this.isshow = true
this.countDown()
}
// let that = this;
// if (that.validateForm() && that.validate) {
// if (this.num == 0) {
// let requestData = {
// phone: that.merchantData.phone,
// mer_name: that.merchantData.enterprise_name,
// name: that.merchantData.user_name,
// code: that.merchantData.yanzhengma,
// company_name: that.merchantData.company_name,
// address: that.merchantData.address,
// social_credit_code: that.merchantData.social_credit_code,
// merchant_category_id: that.merchantData.classification,
// mer_type_id: that.merchantData.mer_type,
// mer_storeType: this.mer_storeType,
// area_id: this.area_id,
// street_id: this.street_id,
// village_id: this.village_id,
// is_nmsc: this.isnum,
// images: that.pics
// }
// that.validate = false;
// if (that.mer_i_id) {
// updateGoodsRecord(that.mer_i_id, requestData).then(res => {
// if (res.status == 200) {
// title: '',
// that.loading = true;
// that.timer = setTimeout(() => {
// that.successful = true;
// that.validate = true;
// }, 1000)
// }
// }).catch(res => {
// this.isshow = false
// that.validate = true;
// that.$util.Tips({
// title: res
// });
// })
// } else {
// create(requestData).then(data => {
// if (data.status == 200) {
// title: '',
// that.loading = true;
// this.timer = setTimeout(() => {
// that.successful = true;
// that.validate = true;
// }, 1000)
// }
// }).catch(res => {
// that.validate = true;
// that.$util.Tips({
// title: res
// });
// })
// }
// } else {
// this.isshow = true
// this.countDown()
// }
// }
},
validateBtn: function() {
let that = this,
@ -838,6 +989,7 @@
if (!value.classification) return that.$util.Tips({
title: '请选择商户分类'
});
if (!this.mer_storeType) return that.$util.Tips({
title: '请选择商户类型'
})
@ -850,6 +1002,11 @@
if (that.isShowCode && !that.codeVal) return that.$util.Tips({
title: '请填写图片验证码'
});
if (that.pics.length == 0) return that.$util.Tips({
title: '请上传一张或者多张图片'
});
that.validate = true;
return true;
},
@ -887,6 +1044,16 @@
color: #fff !important;
}
.conten-top {
width: 100%;
text-align: center;
background-color: #fff;
position: absolute;
top: 0;
position: fixed;
z-index: 10;
}
.uni-input-placeholder {
color: #B2B2B2;
}
@ -917,7 +1084,9 @@
.merchantsSettled {
background-image: linear-gradient(var(--view-bntColor21) 0%, var(--view-bntColor22) 100%);
height: 140vh;
position: relative;
}
.merchantsSettled .merchantBg {
@ -1229,8 +1398,7 @@
position: absolute;
top: 50%;
left: 50%;
border-radius: 12rpx;
-webkit-border-radius: 12rpx;
padding: 52rpx;
-webkit-transform: translate(-50%, -50%);
-moz-transform: translate(-50%, -50%);
@ -1268,32 +1436,25 @@
}
.settlementAgreement .setAgCount .content {
margin-top: 32rpx;
color: #333;
font-size: 26rpx;
line-height: 22px;
text-align: justify;
text-justify: distribute-all-lines;
height: 756rpx;
overflow-y: scroll;
}
.settlementAgreement .setAgCount .contenta {
margin-top: 32rpx;
color: #333;
font-size: 26rpx;
line-height: 22px;
text-align: justify;
text-justify: distribute-all-lines;
/*#ifdef H5*/
height: 600rpx;
/*#endif*/
/*#ifdef APP-PLUS*/
height: 530rpx;
/*#endif*/
height: 75%;
overflow-y: scroll;
@ -1305,7 +1466,7 @@
.setAgCountbtna {
margin-top: 40rpx;
width: 150rpx;
width: 200rpx;
height: 74rpx;
text-align: center;
line-height: 74rpx;
@ -1326,7 +1487,7 @@
height: 74rpx;
text-align: center;
line-height: 74rpx;
background:#cecece;
background: #cecece;
border-radius: 46rpx 46rpx;
opacity: 1;
@ -1339,7 +1500,7 @@
.setAgCountbtnc {
margin-top: 40rpx;
width: 150rpx;
width: 200rpx;
height: 74rpx;
text-align: center;
line-height: 74rpx;

View File

@ -20,7 +20,7 @@
<view class="" v-if="!isFshow">
<view class="site-box1 flex_a_c_j_sb">
<view class="place_wrapper flex_a_c" @click="selectLocation">
<view class="place_wrapper flex_a_c" @click="selectLocation">
<view class="iconfont icon-weizhi"></view>
<view class="town_name">{{street}}</view>
</view>
@ -175,7 +175,7 @@
import {
getIndexData,
getDiy,
cloudWarehouse
} from '@/api/api.js'
import {
@ -183,8 +183,7 @@
} from '@/api/product.js';
import {
getGeocoder,
merClassifly,
getProductHot
merClassifly
} from '@/api/store.js';
import {
getArea,
@ -247,19 +246,17 @@
loadTitle: '加载更多',
}
},
onPullDownRefresh() {
this.list(true);
this.list(true, this.street_id);
this.Area()
uni.stopPullDownRefresh()
},
onShow() {
this.selfLocation()
},
onLoad() {
this.list()
this.Area()
this.selfLocation()
// this.openTongZhi()
uni.$on('connectstatusChange', (connectstatus) => {
var connectstr = ''
@ -273,15 +270,13 @@
})
},
onReachBottom() {
if (this.productList.length > 0) {
setTimeout(() => {
this.list(false);
this.list(false, this.street_id);
}, 500)
} else {
this.list()
}
}
},
beforeDestroy() {
@ -300,13 +295,12 @@
this.street = newValue.split(',')[0]
this.town = newValue.split(',')[0]
this.street_id = newValue.split(',')[1]
});
if (this.street.length <= 0) {
this.selfLocation()
}
},
// #ifdef APP-PLUS
@ -336,7 +330,6 @@
},
//
list(isPage, id) {
let that = this;
if (that.loadend) return;
if (that.loading) return;
@ -345,7 +338,13 @@
that.loading = true;
that.loadTitle = '';
getProductHot(that.where.page, that.where.limit).then(res => {
cloudWarehouse({
page: that.where.page,
limit: that.where.limit,
street_code: id,
category_id: 0
}).then(res => {
// console.log(222)
let list = res.data.list;
let productList = that.$util.SplitArray(list, that.productList);
let loadend = list.length < that.where.limit;
@ -400,25 +399,16 @@
} else if (scrollTop > 100) {
this.backColor = 1
this.isFshow = true
}
},
getCloudShopMerId(id) {
get_cloud_shop(id).then(res => {
res.data.length > 0 ? this.isYunCang = 1 : this.isYunCang = 0
})
},
selectLocation() {
this.showPicker = true
},
confirm(e) {
@ -426,7 +416,8 @@
this.street = e.value[1].name
this.street_id = e.value[1].code
this.town = e.value[1].name
this.productList = []
this.loadend = false;
this.$set(this.where, 'page', 1)
this.list(true, this.street_id)
this.$nextTick(() => {
this.$bus.$emit('value-updated', e.value[1].name + ',' + e.value[1].code);
@ -517,7 +508,8 @@
this.street = e.value[1].name
this.street_id = e.value[1].code
this.town = e.value[1].name
this.productList = []
this.loadend = false;
this.$set(this.where, 'page', 1)
this.list(true, this.street_id)
},
selfLocation() {
@ -544,12 +536,13 @@
this.town = res.data.address_reference.town.title
this.street_id = res.data.address_reference.town.id
this.street = res.data.address_component.street
this.list(true,this.street_id)
this.$nextTick(() => {
this.$bus.$emit('value-updated', this.street + ',' + this
.street_id);
})
this.list(this.street_id)
}).catch(err => {
this.isshow = false
uni.showToast({

View File

@ -196,10 +196,14 @@
<view v-if="copyright.status !== -1" class="copy-right">
<image class="img-copyright" :src="copyright.image" mode="widthFix"></image>
<view class="text">{{copyright.Copyright}}</view>
<view class="">备案号:蜀ICP备2022030133号-2A</view>
<view class="">增值电信营业许可证号:川B2-20221250</view>
</view>
<view v-else class="copy-right">
<view class="iconfont icon-crmeb"></view>
<view class="text">众邦科技提供技术支持</view>
</view>
<view style="height: 50rpx;"></view>
<authorize @onLoadFun="onLoadFun" :isAuto="isAuto" :isShowAuth="isShowAuth" @authColse="authColse"
@ -590,6 +594,7 @@
that.is_promoter = res.data.is_promoter;
that.extension_status = res.data.extension_status;
that.getMyMenus();
that.$store.commit('SET_USERINFO', that.userInfo);
});
},
//

View File

@ -8,13 +8,13 @@
</div>
</div>
<div class="whiteBg" v-if="formItem === 1">
<div class="title acea-row row-center-wrapper">
<div class="title acea-row row-center-wrappe">
<div class="item" :class="current === index ? 'on' : ''" v-for="(item, index) in navList"
@click="navTap(index)" :key="index">
{{ item }}
</div>
</div>
<div class="list" :hidden="current !== 0">
<div class="list" :hidden="current !== 1">
<form @submit.prevent="submit">
<div class="item">
<div class="acea-row row-middle">
@ -39,7 +39,7 @@
</div>
</div>
<div class="list" :hidden="current !== 1">
<div class="list" :hidden="current !== 0">
<div class="item">
<div class="acea-row row-middle">
<image src="/static/images/phone_1.png"></image>
@ -47,11 +47,13 @@
v-model="account" />
</div>
</div>
<div class="item">
<div class="acea-row row-middle">
<image src="/static/images/code_2.png"></image>
<input type="text" placeholder="填写验证码" placeholder-class="placeholder" class="codeIput"
v-model="captcha" />
<input type="number" placeholder="填写验证码" placeholder-class="placeholder" class="codeIput"
v-model="captcha" maxlength="4" />
<button class="code" :disabled="disabled" :class="disabled === true ? 'on' : ''"
@click="handleVerify">
{{ text }}
@ -61,8 +63,8 @@
<div class="item" v-if="isShowCode">
<div class="acea-row row-middle">
<image src="/static/images/code_2.png"></image>
<input type="text" placeholder="填写验证码" placeholder-class="placeholder" class="codeIput"
v-model="codeVal" />
<input type="number" placeholder="填写验证码" placeholder-class="placeholder" class="codeIput"
v-model="codeVal" maxlength="4" />
<div class="code" @click="getcaptcha">
<image class="code-img" style="width: 100%;height: 100%;" :src="codeUrl" />
</div>
@ -70,8 +72,8 @@
</div>
</div>
<div class="logon" @click="loginMobile" :hidden="current !== 1">登录</div>
<div class="logon" @click="submit" :hidden="current === 1">登录</div>
<div class="logon" @click="loginMobile" :hidden="current !== 0">登录</div>
<div class="logon" @click="submit" :hidden="current === 0">登录</div>
<div class="protocol acea-row row-between-wrapper">
<checkbox-group class="checkgroup" @change='isAgree=!isAgree'>
<checkbox class="checkbox" :checked="isAgree ? true : false" />
@ -95,8 +97,9 @@
<div class="item">
<div class="acea-row row-middle">
<image src="/static/images/code_2.png"></image>
<input type="text" placeholder="填写验证码" placeholder-class="placeholder" class="codeIput"
<input type="number" placeholder="填写验证码" maxLength='4' placeholder-class="placeholder" class="codeIput"
v-model="captcha" />
<button class="code" :disabled="disabled" :class="disabled === true ? 'on' : ''"
@click="handleVerify">
{{ text }}
@ -110,10 +113,11 @@
v-model="password" />
</div>
</div>
<div class="item" v-if="isShowCode">
<div class="acea-row row-middle">
<image src="/static/images/code_2.png"></image>
<input type="text" placeholder="填写验证码" placeholder-class="placeholder" class="codeIput"
<input type="number" placeholder="填写验证码" maxlength="4" placeholder-class="placeholder" class="codeIput"
v-model="codeVal" />
<div class="code" @click="getcaptcha">
<image class="code-img" style="width: 100%;height: 100%;" :src="codeUrl" />
@ -156,16 +160,18 @@
<input type='number' placeholder='填写手机号码' placeholder-class='placeholder'
v-model="account"></input>
</view>
<view class="item acea-row row-between-wrapper">
<input type='number' placeholder='填写验证码' placeholder-class='placeholder' class="codeIput"
<input type='number' placeholder='填写验证码' maxlength="4" placeholder-class='placeholder' class="codeIput"
v-model="captcha"></input>
<button class="code" :class="disabled === true ? 'on' : ''" :disabled='disabled'
@click="handleVerify">
{{ text }}
</button>
</view>
<view class="item">
<input type='password' placeholder='填写登录密码' placeholder-class='placeholder'
<input type='password' placeholder='填写登录密码' placeholder-class='placeholder'
v-model="password"></input>
</view>
<view class="protocol acea-row row-between-wrapper">
@ -260,7 +266,7 @@
},
data: function() {
return {
navList: ["账号登录", "快速登录"],
navList: ["快速登录","账号登录"],
current: 0,
account: "",
password: "",
@ -892,7 +898,9 @@
// #ifdef APP-PLUS
jpushModule.initJPushService()
jpushModule.getRegistrationID(result => {
if (result.registerID) {
bindJG({
phone: this.account,
jg_register_id: result.registerID

View File

@ -150,7 +150,7 @@
</view>
<view class='discount' v-else>免运费</view>
</view>
<view class='item acea-row row-between-wrapper'
<!-- <view class='item acea-row row-between-wrapper'
v-if="!seckillId && order_type != 3 && order_type != 4 && item.order.enabledCoupon">
<view>店铺优惠券</view>
<block v-if="item.coupon.length>0">
@ -163,14 +163,15 @@
<block v-else>
<view class='discount'>暂无优惠券</view>
</block>
</view>
<!-- <view v-if="item.openReceipt == 1" class='item acea-row row-between-wrapper'>
</view> -->
<view class='item acea-row row-between-wrapper'>
<view>开具发票 <text @tap="showInvoice" class="iconfont icon-wenhao1"></text></view>
<view class='discount discount_voice' @tap="goInvoice(item.mer_id)">
{{(item.invoiceData && item.invoiceData.receipt_title) ? item.invoiceData.receipt_title : '不开发票'}}
<text class='iconfont icon-jiantou'></text>
</view>
</view> -->
</view>
<view v-if="order_type === 2 && item.list[0].productPresell.presell_type ==2"
class="item acea-row row-between-wrapper"
style="border-top: 1px solid #f5f5f5; border-bottom: 1px solid #f5f5f5;">
@ -382,6 +383,7 @@
</view>
</view>
<view style='height:140rpx;'></view>
<view class='footer acea-row row-between-wrapper'>
<view class="footer_count">
<view>

View File

@ -250,8 +250,8 @@
</view>
</view>
<view class='bottom acea-row row-right row-middle'>
<!-- <view v-if="!item.receipt && item.status != -1" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view> -->
<view v-if="!item.receipt && item.status != -1" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view>
<block v-if="item.status == 0 || item.status == 9 || item.status == -1">
<view class='bnt b-color' @click='goOrderDetails(item.order_id)'>查看详情</view>
</block>

View File

@ -259,8 +259,8 @@
</view>
</view>
<view class='bottom acea-row row-right row-middle'>
<!-- <view v-if="!item.receipt && item.status != -1" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view> -->
<view v-if="!item.receipt && item.status != -1" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view>
<block v-if="item.status == 0 || item.status == 9 || item.status == -1">
<view class='bnt b-color' @click='goOrderDetails(item.order_id)'>查看详情</view>
</block>

View File

@ -247,8 +247,8 @@
</view>
</view>
<view class='bottom acea-row row-right row-middle'>
<!-- <view v-if="!item.receipt && item.status != -1" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view> -->
<view v-if="!item.receipt && item.status != -1" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view>
<block v-if="item.status == 0 || item.status == 9 || item.status == -1">
<view v-if="!item.receipt && item.status != -1" class="bnt cancelBnt">一键转卖</view>
<view class='bnt b-color' @click='goOrderDetails(item.order_id)'>查看详情</view>

View File

@ -257,8 +257,8 @@
</view>
</view>
<view class='bottom acea-row row-right row-middle'>
<!-- <view v-if="!item.receipt && item.status != -1" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view> -->
<view v-if="!item.receipt && item.status != -1" class='bnt cancelBnt'
@click.stop='applyInvoice(item.order_id)'>申请开票</view>
<block v-if="item.status == 0 || item.status == 9 || item.status == -1">
<view class='bnt b-color' @click='goOrderDetails(item.order_id)'>查看详情</view>
</block>
@ -283,6 +283,12 @@
去付款
</view>
</block>
<block v-if="item.order_status == 2 ">
<view class='bnt b-color' @click.stop='goOrderDetails(item.order_id)'>
去发货
</view>
</block>
<block v-if="item.order_status == 9 ">
<view class='bnt b-color' v-if="item.status==12" @click.stop='dePay'>

View File

@ -172,7 +172,7 @@
},
getOrderInfo() {
groupOrderDetail(this.order_id, this.product_type).then(res => {
console.log(res)
this.couponData = res.data
this.$nextTick(() => {
if (this.couponData.interest !== null) {
@ -189,6 +189,7 @@
pay_type: this.payType
}
).then(res => {
if (res.data.paid === false) {
//
@ -204,7 +205,7 @@
}, 1000)
}
}).catch(err => {
uni.showToast({
title: err.message
})
@ -213,7 +214,10 @@
orderPay(this.order_id, {
type: this.payType
}).then(res => {
let jsConfig = res.data.result.config
if (res.data.status === 'weixinApp') {
//
// #ifdef APP-PLUS
@ -257,15 +261,40 @@
});
// #endif
} else {
if (res.status == 200) {
// uni.navigateBack({
// delta: 1
// })
uni.showToast({
icon: 'none',
title: res.message
})
if(res.data.status='error'){
}else{
setTimeout(() => {
uni.navigateBack({
delta: 2
})
}, 1000)
}
}
}
// setTimeout(() => {
// uni.navigateBack({
// delta: 1
// })
// }, 1000)
uni.showToast({
title: res.message
})
// uni.showToast({
// icon:'none' ,
// title: res.message
// })
})
}

View File

@ -103,13 +103,13 @@
<text class='iconfont icon-you'></text>
</navigator>
</view>
<!-- <view class='item acea-row row-between-wrapper'>
<view class='item acea-row row-between-wrapper'>
<view>注销账号</view>
<view class='input acea-row row-between-wrapper' @click="changeCancel">
<input type='text' placeholder="账号注销后不能恢复" disabled='true' class='id'></input>
<text class='iconfont icon-you'></text>
</view>
</view> -->
</view>
<!--#ifdef APP-PLUS-->
<view class='item acea-row row-between-wrapper'>
<view>当前版本</view>

BIN
static/applet/fl.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

BIN
static/applet/jy.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 9.7 KiB

BIN
static/applet/ny.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

BIN
static/applet/qg.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

BIN
static/applet/yz.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.3 KiB

BIN
static/applet/zz.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

BIN
static/images/LHYC/DWB1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

BIN
static/images/LHYC/DWBG.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

BIN
static/images/LHYC/K.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 64 KiB

BIN
static/images/LHYC/QB1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.2 KiB

BIN
static/images/SFFF.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.4 KiB

BIN
static/images/SFZZ.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.1 KiB

BIN
static/images/YHKF.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.4 KiB

BIN
static/images/YHKZ.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.0 KiB

BIN
static/images/de1.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 938 B

BIN
static/images/de2.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 997 B

BIN
static/images/de3.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 956 B

Binary file not shown.

View File

@ -4,12 +4,10 @@ import {
} from "../../api/user.js";
import {
LOGIN_STATUS,
UID
UID,
USER_INFO
} from '../../config/cache';
import Cache from '../../utils/cache';
import {
USER_INFO
} from '../../config/cache';
// #ifdef APP-PLUS
import Updater from '@/uni_modules/guyue-updater/index';
// #endif
@ -18,7 +16,7 @@ const state = {
location: Cache.get('LOCATION_DATA', true) || {},
token: Cache.get(LOGIN_STATUS) || null,
backgroundColor: "#fff",
userInfo: null,
userInfo: Cache.get(USER_INFO)||null,
uid: Cache.get(UID) || null,
globalData: uni.getStorageSync('GLOBAL_DATA') || {},
homeActive: false,
@ -39,6 +37,10 @@ const mutations = {
Cache.set(LOGIN_STATUS, opt.token, opt.time);
uni.removeStorageSync('auth_token');
},
SET_USERINFO(state, opt){
state.userInfo = opt;
Cache.set(USER_INFO, opt);
},
SETUID(state, val) {
state.uid = val;
Cache.set(UID, val);
@ -123,7 +125,7 @@ const actions = {
phone_brand:os.brand
}).then((res) => {
if (Object.keys(res.data.appInfo).length > 0) {
// if(res.data.appInfo.version) uni.showLoading({
// title: '检查更新中'

View File

@ -8,6 +8,8 @@
// | Author: CRMEB Team <admin@crmeb.com>
// +----------------------------------------------------------------------
import app from "./app";
import storage from "./storage.js";
export default {
app
app,
storage
};

29
store/modules/storage.js Normal file
View File

@ -0,0 +1,29 @@
import {
getUserInfo,
Appversion
} from "../../api/user.js";
import {
LOGIN_STATUS,
UID,
USER_INFO
} from '../../config/cache';
import Cache from '../../utils/cache';
const state = {
storage: {},
};
const mutations = {
setStorage(state, data) {
state.storage = data;
},
};
const actions = {
};
export default {
state,
mutations,
actions
};

View File

@ -2,9 +2,9 @@
const version = '2.0.36'
// 开发环境才提示,生产环境不会提示
if (process.env.NODE_ENV === 'development') {
if (process.env.NODE_ENV == 'development') {
// console.log(`\n %c uView V${version} %c https://uviewui.com/ \n\n`, 'color: #ffffff; background: #3c9cff; padding:5px 0; border-radius: 5px;');
console.log('当前属于测试环境')
console.log(process.env.NODE_ENV,'当前属于开发环境')
}
export default {

82
utils/requestb.js Normal file
View File

@ -0,0 +1,82 @@
// +----------------------------------------------------------------------
// | CRMEB [ CRMEB赋能开发者助力企业发展 ]
// +----------------------------------------------------------------------
// | Copyright (c) 2016~2021 https://www.crmeb.com All rights reserved.
// +----------------------------------------------------------------------
// | Licensed CRMEB并不是自由软件未经许可不能去掉CRMEB相关版权
// +----------------------------------------------------------------------
// | Author: CRMEB Team <admin@crmeb.com>
// +----------------------------------------------------------------------
import {
HTTP_REQUEST_URL,
HTTP_REQUEST_URL_FOUR,
HEADER,
TOKENNAME
} from '@/config/app';
import {
checkLogin
} from '../libs/login';
import store from '../store';
// console.log(HTTP_REQUEST_URL_FOUR)
/**
* 发送请求
*/
function baseRequest(url, method, data, {
noAuth = false,
noVerify = false
}) {
let Url = HTTP_REQUEST_URL_FOUR,
header = HEADER;
if (store.state.app.token) header[TOKENNAME] = 'Bearer ' + store.state.app.token;
return new Promise((reslove, reject) => {
uni.request({
url: Url + '/api/' + url,
method: method || 'GET',
// header: header,
data: data || {},
success: (res) => {
// #ifdef APP-PLUS
// console.log('app', Url + '/api/' + url, res.data);
// #endif
// console.log(res.data.code)
if (noVerify)
reslove(res.data, res);
else if (res.data.status == 200)
reslove(res.data, res);
else if ([410000, 410001, 410002, 40000].indexOf(res.data.status) !== -1) {
reject(res.data);
} else if (res.data.status == 501) {
uni.reLaunch({
url: '/pages/error/index'
})
reject(res.data);
} else if (res.statusCode==200) {
reslove(res.data,res.data);
} else
reject(res.data.message || '系统错误');
},
fail: (message) => {
reject('请求失败');
}
})
});
}
const request = {};
['options', 'get', 'post', 'put', 'head', 'delete', 'trace', 'connect'].forEach((method) => {
request[method] = (api, data, opt) => baseRequest(api, method, data, opt || {})
});
export default request;

View File

@ -1,10 +1,12 @@
import {
getGXconfig
getGXconfig,
miniapp
} from "@/api/uniMP.js";
import {
HTTP_REQUEST_URL
} from '@/config/app';
const mp = uni.requireNativePlugin('uniMP');
import store from "@/store/modules/app.js"
let appid = ''; // 应用id
let wgtFile = ''; // 应用文件地址
@ -65,11 +67,11 @@ const loadMP = async (id) => {
console.log('初始化完成', wgtFile);
installMP();
},
fail(res) {
clearInterval(timer);
timer = null;
uni.hideLoading();
}
fail(res) {
clearInterval(timer);
timer = null;
uni.hideLoading();
}
});
downloadTask.onProgressUpdate((res) => {
// console.log('初始化进度' + res.progress);
@ -84,6 +86,136 @@ const loadMP = async (id) => {
}
});
};
//加载商城小程序
const loadMPx = async (id) => {
appid = id;
let info = await miniapp();
console.log('最新版本', info.data);
console.log(mp, uni);
// return ;
uni.showLoading({
title: '初始化中...',
mask: true
})
mp.getUniMPVersion(id, (ret) => {
console.log('当前版本', ret);
let flag;
if (HTTP_REQUEST_URL == 'https://shop.lihaink.cn') {
flag = false
} else {
flag = true
}
if (0 != ret.code || compareVersions(info.data.appInfo.version, ret.versionInfo.name) == 1 ||
flag ==
true) {
let count = 0;
timer = setInterval(() => {
if (count < 100) uni.showLoading({
title: `初始化中... ${count}%`,
mask: true
})
else uni.showLoading({
title: '初始化中...100%',
mask: true
})
}, 600)
let downloadTask = uni.downloadFile({
url: info.data.appInfo.dow_url,
success(res) {
wgtFile = res.tempFilePath;
console.log('初始化完成', wgtFile);
installMP();
},
fail(res) {
clearInterval(timer);
timer = null;
uni.hideLoading();
}
});
downloadTask.onProgressUpdate((res) => {
// console.log('初始化进度' + res.progress);
if (res.progress > count) count += 10;
if (count >= 90) {
clearInterval(timer);
timer = null;
}
});
} else {
open()
}
});
};
// 按URL加载小程序
const loadMPurl = async (e) => {
appid = e.id;
let FURL = e.url;
uni.showLoading({
title: '初始化中...',
mask: true
})
uni.request({
url: FURL,
method: 'GET',
success: (fileInfo) => {
mp.getUniMPVersion(appid, (ret) => {
console.log('当前版本', ret);
let flag;
if (HTTP_REQUEST_URL == 'https://shop.lihaink.cn') {
flag = false
} else {
flag = true
}
if (0 != ret.code || compareVersions(fileInfo.data?.data?.version, ret.versionInfo.name) == 1 || flag ==
true) {
let count = 0;
timer = setInterval(() => {
if (count < 100) uni.showLoading({
title: `初始化中... ${count}%`,
mask: true
})
else uni.showLoading({
title: '初始化中...100%',
mask: true
})
}, 600)
let downloadTask = uni.downloadFile({
url: fileInfo.data?.data?.down_url,
success(res) {
wgtFile = res.tempFilePath;
console.log('初始化完成', wgtFile);
installMP();
},
fail(res) {
clearInterval(timer);
timer = null;
uni.hideLoading();
}
});
downloadTask.onProgressUpdate((res) => {
// console.log('初始化进度' + res.progress);
if (res.progress > count) count += 10;
if (count >= 90) {
clearInterval(timer);
timer = null;
}
});
} else {
open()
}
});
},
fail:(err)=> {
console.log('错误:', err);
}
})
};
// 小程序版本信息
const getVersion = (id) => {
appid = id;
@ -109,15 +241,15 @@ const doInstallMP = () => {
open();
} else {
uni.hideLoading();
clearInterval(timer);
timer = null;
clearInterval(timer);
timer = null;
uni.showModal({
title: '初始化失败',
content: JSON.stringify(r),
showCancel: false
});
}
console.log('初始化供销: ' + JSON.stringify(r));
console.log('初始化: ' + JSON.stringify(r));
});
};
@ -127,11 +259,13 @@ const open = (id = null) => {
icon: 'none',
title: '请先登录'
})
let avatar = store?.state?.userInfo?.avatar;
mp.openUniMP({
appid: id || appid,
extraData: {
uniMP: true,
token: token,
avatar: avatar,
}
}, (ret) => {
uni.hideLoading();
@ -148,6 +282,8 @@ const open = (id = null) => {
export default {
loadMP,
loadMPurl,
loadMPx,
installMP,
doInstallMP,
getVersion,