Commit 2b9264a0 authored by haitao's avatar haitao

Merge branch 'dev' of http://rungit.jxdsy.cn:10000/xys/lumastoreapp into dev

parents 35511ced 97a83601
<script>
const bgAudioMannager = uni.getBackgroundAudioManager();
const platform=uni.getSystemInfoSync().platform;
const time='';
const time='';
import {newsRemind} from "@/utils/api/api.js";//获取商家消息
export default {
......@@ -17,7 +17,6 @@
bgAudioMannager.pause(); //pause 暂停
});
}
// #ifdef APP-PLUS
//app关闭默认的启动 方法关闭启动图。但是这个时间不能太晚,6s 超时后依旧会主动关闭。
......@@ -66,37 +65,78 @@
var rsult=hgService.checkIfLimited(); //检测是否限制后台运行
if(rsult.isLimit){ //限制了后台运行
hgService.requestIgnoreLimit(); //申请允许后台运行
hgService.requestIgnoreLimit(); //申请
}else{ //没有限制后台运行
console.log('没有限制');
hgService.startService(); //启动前台服务
//hgService.showSafeSetting();//打开安全管理 支持小米,华为,锤子,opp,vivo,三星,乐视,魅族
}
// console.log('没有限制');
hgService.startService(); //启动前台服务
// hgService.showSafeSetting();//打开安全管理 支持小米,华为,锤子,opp,vivo,三星,乐视,魅族
//var globalEvent = uni.requireNativePlugin('globalEvent'); //全局事件回调 任务启动时间,会有一定延时 一般一分钟内。
},
// hgServiceFun(){
// const pushLive = uni.requireNativePlugin('push-live');
// pushLive.startService({ //启动服务
// title: "鹿马商家助手",
// content: "小鹿正在为您进行实时播报...",
// mode: 1 //0省电模式 1流氓模式
// }, function(res) {
// console.log(res)
// });
// pushLive.isIgnoringBatteryOptimizations(function(res) { //是否添加到白名单中
// if(res.flag){ //添加进去了
// //pushLive.gotoWhiteListSetting();
// }else{
// pushLive.requestIgnoreBatteryOptimizations(); //申请加入白名单
// }
// })
// var globalEvent = uni.requireNativePlugin('globalEvent');
// globalEvent.addEventListener('doJobEvent', function() {
// console.log("我被定时启动了。。。。。。。。。。。。。。。。。")
// });
// console.log(globalEvent)
// },
//获取 语音消息
async getnewsRemind(type){
var date = new Date();
let hours = date.getHours();//当前 时间 小时
let datestime = 5000;//默认15秒
let datestime = 5000;//默认15秒
if(this.$store.state.token!=""){//判断是否 已登录
//#ifdef APP-PLUS
let cid = plus.push.getClientInfo().clientid
//#endif
console.log('这里')
let res = await newsRemind({
uid:this.$store.state.userInfo.user_id,
cid:plus.push.getClientInfo().clientid
cid:cid
});
if(res.code==0){
console.log('有语音','--------',res);
if(res.data.length!=0){
let KJres = res.data.filter(item =>{ //快捷支付
return item.type==3
return item.type==3 || item.type==0
})
let PSres = res.data.filter(item => { //订单
return item.type==4 || item.type==5 || item.type==6
return item.type==4 || item.type==5 || item.type==6 || item.type==1
})
if(platform=='ios'){
......@@ -140,17 +180,21 @@
}else{
if(PSres.length!=0){
let msgtext = `你有${PSres.length}条鹿马订单,请及时处理`;
console.log('商城语音播报')
if(this.$store.state.isvoice){
this.$store.dispatch('AudioVoice',msgtext).then((e) => {
uni.vibrateLong();//震动 调用//400ms//长震动
})
}
}
if(KJres.length!=0){
let payText =""
KJres.map(item=>{
payText = payText+","+ item.contents
});
console.log('快捷支付播报')
if(this.$store.state.isvoice){
this.$store.dispatch('AudioVoice',payText).then((e) => {
uni.vibrateLong();//震动 调用//400ms//长震动
......@@ -161,7 +205,6 @@
}
}
if(type!=2){
return true;
}
......@@ -182,4 +225,4 @@
@import './common/qiun.css';
@import './style.css';//我的
</style>
</style>
\ No newline at end of file
......@@ -101,8 +101,10 @@
//提示弹窗
change(e) {
console.log('是否打开:' + e.show)
if (!e.show) {
console.log('是否打开:' + e.show)
console.log(this.$store.state.Timer,'退出登陆取消')
if (!e.show) {
console.log(this.$store.state.Timer,'退出登陆')
this.showtip = false
}
},
......@@ -110,7 +112,8 @@
this.showtip = false;
this.$emit("cancel",{});//触发回调方法
},
show(){
show(){
this.showtip = true;
},
//确认发布点击
......
......@@ -16,6 +16,9 @@
</view>
<view class="time">{{dataorder.create_time}}</view>
</view>
</view>
<view class="beizhu flex jus-b ali-c" style="border-bottom: 1px solid #f1f1f1;">
<text class="price">{{dataorder.username_tel}}</text>
</view>
<!-- 上面的是 -->
<!-- reorder -->
......@@ -23,7 +26,8 @@
<view class="beizhu flex jus-b ali-c">
<text class="beizhutext oneline flex1" v-if="dataorder.remark">备注:{{dataorder.remark||''}}</text>
<text class="beizhutext oneline flex1" v-if="dataorder.message">退款原因:{{dataorder.message||''}}</text>
<text class="price">合计:¥{{dataorder.total}}</text>
<text class="price">合计:¥{{dataorder.total}}</text>
</view>
<view class="orderItemss_foot jus-b">
<view class="titmeboxs ali-c" >
......
......@@ -3,9 +3,14 @@
//"appid" : "__UNI__FC9419E",
"appid" : "__UNI__1EA80F1", //这个是 web
"description" : "商家",
"versionName" : "1.0.90",
"versionCode" : 190,
"versionName" : "1.0.95",
"versionCode" : 195,
"transformPx" : false,
"compatible" : {
"ignoreVersion" : true, //true表示忽略版本检查提示框,HBuilderX1.9.0及以上版本支持
"runtimeVersion" : "2.9.7,2.9.8", //兼容的uni-app运行环境版本号,多个版本使用,分割
"compilerVersion" : "2.9.8" //兼容的编译器版本号
},
/* 5+App特有相关weex */
"app-plus" : {
"usingComponents" : true,
......@@ -50,7 +55,12 @@
"<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>",
"<uses-permission android:name=\"android.permission.WRITE_CONTACTS\"/>",
"<uses-permission android:name=\"android.permission.WRITE_EXTERNAL_STORAGE\"/>",
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"
"<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>",
"<uses-permission android:name=\"android.permission.FOREGROUND_SERVICE\"/>",
"<uses-permission android:name=\"android.permission.GET_TASKS\"/>",
"<uses-permission android:name=\"android.permission.REORDER_TASKS\"/>",
"<uses-permission android:name=\"android.permission.RECEIVE_BOOT_COMPLETED\"/>",
"<uses-permission android:name=\"android.permission.REQUEST_IGNORE_BATTERY_OPTIMIZATIONS\"/>"
]
},
/* ios打包配置 */
......
......@@ -235,6 +235,18 @@
"style" : {
"navigationBarTitleText":"添加外卖产品"
}
},
{
"path" : "pages/addEditEleProduct/editProductStore",
"style" : {
"navigationBarTitleText":"快捷修改库存"
}
},
{
"path" : "pages/addEditEleProduct/editProductPrice",
"style" : {
"navigationBarTitleText":"快捷修改价格"
}
},
{
"path" : "pages/ViewLogistics/ViewLogistics",
......
......@@ -74,6 +74,23 @@
</view>
</view> -->
<view class="noecellbox">
<view class="title">必选品或非必选</view>
<view class="inputbox flex">
<radio-group @change="mandatoryradioChange">
<view class="chindlost ali-c flex flex-wrap" >
<view class="" v-for="(item, index) in mandatoryType" :key="item.value">
<label class="lableitem flex ali-c" style="margin-right: 40upx;">
<view >
<radio color="#FF6900" :value="item.value" :checked="item.value == form.mandatory" />
</view>
<view class="titles">{{item.name}}</view>
</label>
</view>
</view>
</radio-group>
</view>
</view>
<view class="noecellbox" v-if="isadd==1">
<view class="title">商品库存(库存剩余{{form.stock}})</view>
......@@ -327,6 +344,17 @@
name: '计重(kg)',
checked:'2'
}],
mandatoryType: [{
value: '1',
name: '必选品',
checked:'1'
}, {
value: '2',
name: '非必选',
checked:'2'
}],
storeNumber: [{
value: '1',
name: '增加库存',
......@@ -345,7 +373,7 @@
name: 'product',
result:[],
form: {
mandatory:'2',
linkage_id:'',
//cost_price 成本价 stock 商品库存purchase 进货价钱code 条形编码commission 返佣比例original_name 原始商品名
specifications:'',//商品规格
......@@ -443,7 +471,7 @@
}
}
console.log(this.classData[1])
// console.log(this.classData[1])
}
})
......@@ -680,6 +708,10 @@
this.form.sell_type = e.detail.value
console.log(this.form.sell_type)
},
mandatoryradioChange(e){
this.form.mandatory = e.detail.value
console.log(this.form.mandatory)
},
radioChanges(e){
......@@ -769,7 +801,7 @@
this.form.sell_type = res.data.sell_type, // 售卖类型
// this.form.commodity_data:{}, //原始商品名
// 2020-10-22 添加字段
this.form.mandatory = res.data.mandatory
......@@ -792,7 +824,7 @@
}
})
}else if(res.data.commodity_type == 'weigh'){
console.log(res.data.commodity_type,585555555555555555555555)
// console.log(res.data.commodity_type,585555555555555555555555)
this.weigh.map(item=>{
if(this.linkage_product_id == item.product_id){
......@@ -861,11 +893,10 @@
// if(this.c_pics.length == 0){
// this.$api.msg('产品图片未上传');
// }
//
let can = {
linkage_id:this.linkage_id,
mandatory:this.form.mandatory,
gram:this.form.specifications, //商品规格
quality_guarantee_period : this.qualitYears*365+this.qualityMonths*30+this.qualityDays*1, //保质期(月)
manufacture_date :this.form.manufacture_date, //生产日期
......@@ -882,8 +913,7 @@
lunch_box_fee:this.form.lunch_box_fee,//餐盒费
action:this.form.action,//方式(添加:add,修改:edit)
price:this.form.price,//价格
cate_id:this.form.cate_id,
photo:this.c_pics[0].data, //图片
photo: this.c_pics.length == 0?'': this.c_pics[0].data, //图片
activity_price:this.form.activity_price,//秒杀价
store_count:this.form.store_count ,//秒杀库存
activity_id:this.form.activity_id,//秒杀时间id
......@@ -891,6 +921,10 @@
limit_num:this.form.limit_num ,//秒杀限购数量
};
if(this.c_pics.length > 0){
can.photo = this.c_pics[0].data; //图片
}
this.storeNumber.map((item,index)=>{
if(item.checked==1){
if(index==0){
......@@ -926,7 +960,9 @@
can.product_id = this.product_id;
}
//添加修改外卖产品
console.log('这里了')
console.log('这里了9999999999999999999')
console.log(can)
addEditEleProduct(can).then((res1)=>{
console.log(res1)
if(res1.code==0){
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
......@@ -67,7 +67,23 @@
<view>总收入</view>
<view class="shuju_01_s" v-if="countdata.money">¥ {{ countdata.money }}</view>
<view class="shuju_01_s" v-else>¥0</view>
</view>
</view>
<view class="shuju_01" v-if="is_bld">
<view>现金支付数</view>
<view class="shuju_01_s" v-if="countdata.cash">¥ {{ countdata.cash }}</view>
<view class="shuju_01_s" v-else>¥0</view>
</view>
<view class="shuju_01 no" v-if="is_bld">
<view>昨日/现金支付数</view>
<view class="shuju_01_s" v-if="countdata.yesterday_cash">¥ {{ countdata.yesterday_cash }}</view>
<view class="shuju_01_s" v-else>¥0</view>
</view>
</navigator>
<view class="BH"></view>
<view class="six">
......@@ -83,7 +99,7 @@
<view class="jiu_max " v-if="shop_type == 'ele'">
<navigator :url="'/pages/eleProduct/eleProduct?edit=0&activity_type='+ activity_type ">
<view class="jiu_min">
<view><image class="img" src="/static/icon/20.png" mode=""></image></view>
<view><image class="img" src="/static/icon/eleproduct.png" mode=""></image></view>
<view>外卖产品</view>
</view>
</navigator>
......@@ -103,7 +119,7 @@
<view class="jiu_max" v-if="shop_type == 'ele'">
<navigator url="/pages/shopCategory/shopCategory?type=1">
<view class="jiu_min">
<view><image class="img" src="/static/icon/6.png" mode=""></image></view>
<view><image class="img" src="/static/icon/eleclass.png" mode=""></image></view>
<view>商品分类</view>
</view>
</navigator>
......@@ -134,7 +150,7 @@
<view class="jiu_max">
<navigator url="/pages/specs/specs?type=2">
<view class="jiu_min">
<view><image class="img" src="/static/icon/22.png" mode=""></image></view>
<view><image class="img" src="/static/icon/eleguige.png" mode=""></image></view>
<view>商品规格</view>
</view>
</navigator>
......@@ -144,7 +160,7 @@
<!-- 外卖订单 -->
<navigator url="/pages/order/order">
<view class="jiu_min">
<view><image class="img" src="/static/icon/8.png" mode=""></image></view>
<view><image class="img" src="/static/icon/eleguanli.png" mode=""></image></view>
<view>订单管理</view>
</view>
</navigator>
......@@ -174,7 +190,7 @@
<view class="jiu_max ">
<navigator url="/pages/kehu/kehu">
<view class="jiu_min">
<view><image class="img" src="/static/icon/people.png" mode=""></image></view>
<view><image class="img" src="/static/icon/elesuoke.png" mode=""></image></view>
<view>锁客列表</view>
</view>
</navigator>
......@@ -193,7 +209,7 @@
<view class="jiu_max ">
<navigator url="/pages/CardSend/CardSend">
<view class="jiu_min">
<view><image class="img" src="/static/news/coupon.png" mode=""></image></view>
<view><image class="img" src="/static/news/elecoup.png" mode=""></image></view>
<view>优惠券管理</view>
</view>
</navigator>
......@@ -210,7 +226,7 @@
<view class="jiu_max " @tap="shops">
<view class="jiu_min">
<view><image class="img" src="/static/turntable/turntable.png" mode=""></image></view>
<view><image class="img" src="/static/news/turntable.png" mode=""></image></view>
<view>大转盘</view>
</view>
</view>
......@@ -223,11 +239,11 @@
</view>
</navigator>
</view>
<!-- <view class="jiu_max " >
<!-- hgService.showSafeSetting(); -->
<view class="jiu_max " >
<navigator url="/pages/eleProduct/eleProduct?edit=1">
<view class="jiu_min">
<view><image class="img" src="/static/icon/psfei.png" mode=""></image></view>
<view><image class="img" src="/static/icon/editPrice.png" mode=""></image></view>
<view>快捷改价</view>
</view>
</navigator>
......@@ -236,11 +252,11 @@
<view class="jiu_max " >
<navigator url="/pages/eleProduct/eleProduct?edit=2">
<view class="jiu_min">
<view><image class="img" src="/static/icon/psfei.png" mode=""></image></view>
<view><image class="img" src="/static/icon/editStore.png" mode=""></image></view>
<view>增减库存</view>
</view>
</navigator>
</view> -->
</view>
</view>
<view class="BH"></view>
......@@ -286,6 +302,7 @@
if(res.code == 0){
this.is_bld = res.data.is_bld
// this.is_bld = 1
}
})
//显示欢迎回来~
......@@ -293,8 +310,7 @@
this.$refs.Welcome.show();
}, 2000)
//#ifdef APP-PLUS
if( (plus.device.getVolume() * 1000) < 600 ){ //获取手机音量
uni.showModal({
title: '提示:音量较小',
......@@ -306,16 +322,15 @@
this.$api.msg('设置成功');
},500)
}
}
},
});
}
if(uni.getSystemInfoSync().platform!='ios'){
getApp().hgServiceFun(); //安卓后台运行
console.log('走到后台运行这')
}
getApp().hgServiceFun()
//#endif
},
//下拉刷新
onPullDownRefresh() {
......@@ -323,21 +338,24 @@
// uni.stopPullDownRefresh();//结束下拉刷新
},
onShow() {
this.storeIndexfun();
// 判断用户有没有绑定手机号
console.log(this.$store.state.Timer,'啊啊啊啊啊啊啊啊啊啊啊');
getApp().getnewsRemind().then((res)=>{
if(res){
if(this.$store.state.Timer==''){
let Timer=setInterval(()=>{
getApp().getnewsRemind(2);
console.log('这里');
},5000);
this.$store.commit('Timer',Timer);
}
}
})
this.storeIndexfun();
if(uni.getSystemInfoSync().platform!='ios'){
getApp().getnewsRemind().then((res)=>{
console.log(res)
if(res){
if(this.$store.state.Timer==''){
let Timer=setInterval(()=>{
getApp().getnewsRemind(2);
console.log('这里');
},5000);
this.$store.commit('Timer',Timer);
}
}
})
}
},
methods: {
saoma(e){
......@@ -474,7 +492,7 @@
.jiu_min .img {
width: 64upx;
height: 64upx;
margin-bottom: 20upx;
margin-bottom: 10upx;
}
.mo {
......
......@@ -23,11 +23,11 @@
</view>
</view>
<view class="" v-if="products.length!=0">
<view class='tag-e' v-if="products[0].productname!='快捷支付'" style="height: 200upx;">
<view class='tag-e' v-if="products[0].productname!='快捷支付'" >
<view class="goods " v-for="(item,index) of products" :key="index">
<image class="img" :src="staticUrl+item.photo" mode=""></image>
<view class='goods_02'><strong><strong><strong><strong><strong><strong></strong></strong></strong></strong></strong></strong>
<view class='goods_02' style="height: 200upx;">
<view class='goods_title'>{{item.product_name}}</view>
<view class="goods_des">{{item.desc}}</view>
<view class="goods_des">取餐码:{{detail.delivery_num}}</view>
......@@ -38,14 +38,18 @@
</view>
</view>
</view>
</view>
</view>
<view class='tag-e' v-else>
<view class="goods ">
<view class='goods_title'>快捷支付</view>
</view>
</view>
</view>
<view class="total">总计:¥ {{detail.total}}</view>
</view>
</view>
<view class="total">总计:¥ {{detail.total}}</view>
<view class="mess">
<view class="mess_01">订单信息</view>
<view class="mess_02">
......
......@@ -56,8 +56,11 @@
</block>
</view>
</view>
</view>
<view class="order_foot flex jus-e mb-20 " >
<view class="heji"><text class="fuhao">{{item.username_tel}}</text></view>
</view>
<view class="pricebox flex ali-c jus-b">
<view class="pricebox flex ali-c jus-b" style="margin-top: 20upx;">
<!-- 剩余时间 只有待支付的时候有 未付款的时候才有 -->
<view class="titme oneline flex1" v-if="item.status==4">退款原因:{{item.refund_details}}</view>
<view v-else></view>
......
......@@ -6,7 +6,13 @@
<navigator url="/pages/edit/shop/shop" class="list-cell b-b m-t" hover-class="cell-hover" :hover-stay-time="50">
<text class="cell-tit">门店信息</text>
<image class="jiantousi" src="/static/news/jiantousi.png" mode=""></image>
</navigator>
</navigator>
<view class="list-cell b-b m-t" hover-class="cell-hover" :hover-stay-time="50" @click="qiDong">
<text class="cell-tit">允许后台自启</text>
<image class="jiantousi" src="/static/news/jiantousi.png" mode=""></image>
</view>
<navigator url="/pages/edit/Qualifications/Qualifications" class="list-cell b-b" hover-class="cell-hover" :hover-stay-time="50">
<text class="cell-tit">相关资质</text>
<image class="jiantousi" src="/static/news/jiantousi.png" mode=""></image>
......@@ -132,9 +138,14 @@
return debug;
}
},
methods:{
methods:{
qiDong(){
const pushLive = uni.requireNativePlugin('push-live');
pushLive.gotoWhiteListSetting()
},
//联系客服
go(){
go(){
uni.makePhoneCall({
// 手机号
......@@ -213,7 +224,9 @@
this.$api.msg(`跳转到${url}`);
},
//显示弹窗 清除缓存的
toLogoutone(){
toLogoutone(){
// console.log(this.$store.state.Timer,'退出登入')
// this.$store.Timer
this.$refs.moduPopupTwo.show();
},
//退出登录
......@@ -229,7 +242,8 @@
this.$store.commit('changeuserInfo', {});
uni.setStorageSync('userInfo', {});
uni.clearStorage();
clearInterval(this.$store.state.Timer)
this.$store.state.Timer = ''
setTimeout(()=>{
// uni.navigateBack();
uni.navigateTo({
......
static/icon/psfei.png

8.28 KB | W: | H:

static/icon/psfei.png

3.42 KB | W: | H:

static/icon/psfei.png
static/icon/psfei.png
static/icon/psfei.png
static/icon/psfei.png
  • 2-up
  • Swipe
  • Onion skin
static/news/printer.png

1.04 KB | W: | H:

static/news/printer.png

2.82 KB | W: | H:

static/news/printer.png
static/news/printer.png
static/news/printer.png
static/news/printer.png
  • 2-up
  • Swipe
  • Onion skin
......@@ -65,7 +65,7 @@ const store = new Vuex.Store({
isLog: false,
expiresTime: 0,
MyMenus: [],
userInfo: uni.getStorageSync('userInfo'),
userInfo: uni.getStorageSync('userInfo'),
//下面的是登录相关的
hasLogin: false,
......
......@@ -45,3 +45,4 @@ export function getskipShop(data){
export function getshopclass(data){
return request.post("/ele/weigh", data, { noAuth: true});
}
......@@ -6,12 +6,10 @@ module.exports = {
isdebug:false,//正式
//isdebug:true,//测试
// isdebug:true,//测试
xqdebug:false,//正式权限
// xqdebug:true,//发布审核权限 也是测试环境的 主要用于ios
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment