Merge branch 'master' of https://gitee.com/sheepjs/shopro-uniapp
commit
123b6d8a42
5
env
5
env
|
@ -13,4 +13,7 @@ SHOPRO_API_PATH = /shop/api/
|
|||
# 客户端静态资源地址 空=默认使用服务端指定的CDN资源地址前缀 | local=本地 | http(s)://xxx.xxx=自定义静态资源地址前缀
|
||||
SHOPRO_STATIC_URL = https://file.sheepjs.com
|
||||
|
||||
SHOPRO_VERSION = v1.1.15
|
||||
SHOPRO_VERSION = v1.8.1
|
||||
|
||||
# 是否开启直播 1 开启直播 | 0 关闭直播
|
||||
SHOPRO_MPLIVE_ON = 0
|
459
manifest.json
459
manifest.json
|
@ -1,230 +1,245 @@
|
|||
{
|
||||
"name" : "星品购",
|
||||
"appid" : "__UNI__082C0BA",
|
||||
"description" : "应用描述",
|
||||
"versionName" : "1.0.7",
|
||||
"versionCode" : 107,
|
||||
"transformPx" : false,
|
||||
"app-plus" : {
|
||||
"usingComponents" : true,
|
||||
"nvueCompiler" : "uni-app",
|
||||
"nvueStyleCompiler" : "uni-app",
|
||||
"compilerVersion" : 3,
|
||||
"nvueLaunchMode" : "fast",
|
||||
"splashscreen" : {
|
||||
"alwaysShowBeforeRender" : true,
|
||||
"waiting" : true,
|
||||
"autoclose" : true,
|
||||
"delay" : 0
|
||||
"name": "星品购",
|
||||
"appid": "__UNI__082C0BA",
|
||||
"description": "应用描述",
|
||||
"versionName": "1.0.7",
|
||||
"versionCode": 107,
|
||||
"transformPx": false,
|
||||
"app-plus": {
|
||||
"usingComponents": true,
|
||||
"nvueCompiler": "uni-app",
|
||||
"nvueStyleCompiler": "uni-app",
|
||||
"compilerVersion": 3,
|
||||
"nvueLaunchMode": "fast",
|
||||
"splashscreen": {
|
||||
"alwaysShowBeforeRender": true,
|
||||
"waiting": true,
|
||||
"autoclose": true,
|
||||
"delay": 0
|
||||
},
|
||||
"safearea": {
|
||||
"bottom": {
|
||||
"offset": "none"
|
||||
}
|
||||
},
|
||||
"modules": {
|
||||
"Payment": {},
|
||||
"Share": {},
|
||||
"VideoPlayer": {},
|
||||
"OAuth": {}
|
||||
},
|
||||
"distribute": {
|
||||
"android": {
|
||||
"permissions": [
|
||||
"<uses-feature android:name=\"android.hardware.camera\"/>",
|
||||
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_COARSE_LOCATION\"/>",
|
||||
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_FINE_LOCATION\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_MOCK_LOCATION\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CALL_PHONE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CAMERA\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
|
||||
"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.GET_TASKS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.INTERNET\"/>",
|
||||
"<uses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_CONTACTS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_SMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.RECEIVE_BOOT_COMPLETED\"/>",
|
||||
"<uses-permission android:name=\"android.permission.RECORD_AUDIO\"/>",
|
||||
"<uses-permission android:name=\"android.permission.SEND_SMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.SYSTEM_ALERT_WINDOW\"/>",
|
||||
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
|
||||
"<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_SMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.RECEIVE_USER_PRESENT\"/>"
|
||||
],
|
||||
"minSdkVersion": 21,
|
||||
"schemes": "shopro"
|
||||
},
|
||||
"ios": {
|
||||
"urlschemewhitelist": [
|
||||
"baidumap",
|
||||
"iosamap"
|
||||
],
|
||||
"dSYMs": false,
|
||||
"privacyDescription": {
|
||||
"NSPhotoLibraryUsageDescription": "需要同意访问您的相册选取图片才能完善该条目",
|
||||
"NSPhotoLibraryAddUsageDescription": "需要同意访问您的相册才能保存该图片",
|
||||
"NSCameraUsageDescription": "需要同意访问您的摄像头拍摄照片才能完善该条目",
|
||||
"NSUserTrackingUsageDescription": "开启追踪并不会获取您在其它站点的隐私信息,该行为仅用于标识设备,保障服务安全和提升浏览体验"
|
||||
},
|
||||
"safearea" : {
|
||||
"bottom" : {
|
||||
"offset" : "none"
|
||||
}
|
||||
"urltypes": "shopro",
|
||||
"capabilities": {
|
||||
"entitlements": {
|
||||
"com.apple.developer.associated-domains": [
|
||||
"applinks:shopro.sheepjs.com"
|
||||
]
|
||||
}
|
||||
},
|
||||
"modules" : {
|
||||
"Payment" : {},
|
||||
"Share" : {},
|
||||
"VideoPlayer" : {},
|
||||
"OAuth" : {}
|
||||
"idfa": true
|
||||
},
|
||||
"sdkConfigs": {
|
||||
"speech": {
|
||||
"ifly": {}
|
||||
},
|
||||
"distribute" : {
|
||||
"android" : {
|
||||
"permissions" : [
|
||||
"<uses-feature android:name=\"android.hardware.camera\"/>",
|
||||
"<uses-feature android:name=\"android.hardware.camera.autofocus\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_COARSE_LOCATION\"/>",
|
||||
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_FINE_LOCATION\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_MOCK_LOCATION\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CALL_PHONE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CAMERA\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>",
|
||||
"<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.GET_TASKS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.INTERNET\"/>",
|
||||
"<uses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_CONTACTS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_LOGS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>",
|
||||
"<uses-permission android:name=\"android.permission.READ_SMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.RECEIVE_BOOT_COMPLETED\"/>",
|
||||
"<uses-permission android:name=\"android.permission.RECORD_AUDIO\"/>",
|
||||
"<uses-permission android:name=\"android.permission.SEND_SMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.SYSTEM_ALERT_WINDOW\"/>",
|
||||
"<uses-permission android:name=\"android.permission.VIBRATE\"/>",
|
||||
"<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_SMS\"/>",
|
||||
"<uses-permission android:name=\"android.permission.RECEIVE_USER_PRESENT\"/>"
|
||||
],
|
||||
"minSdkVersion" : 21,
|
||||
"schemes" : "shopro"
|
||||
},
|
||||
"ios" : {
|
||||
"urlschemewhitelist" : [ "baidumap", "iosamap" ],
|
||||
"dSYMs" : false,
|
||||
"privacyDescription" : {
|
||||
"NSPhotoLibraryUsageDescription" : "需要同意访问您的相册选取图片才能完善该条目",
|
||||
"NSPhotoLibraryAddUsageDescription" : "需要同意访问您的相册才能保存该图片",
|
||||
"NSCameraUsageDescription" : "需要同意访问您的摄像头拍摄照片才能完善该条目",
|
||||
"NSUserTrackingUsageDescription" : "开启追踪并不会获取您在其它站点的隐私信息,该行为仅用于标识设备,保障服务安全和提升浏览体验"
|
||||
},
|
||||
"urltypes" : "shopro",
|
||||
"capabilities" : {
|
||||
"entitlements" : {
|
||||
"com.apple.developer.associated-domains" : [ "applinks:shopro.sheepjs.com" ]
|
||||
}
|
||||
},
|
||||
"idfa" : true
|
||||
},
|
||||
"sdkConfigs" : {
|
||||
"speech" : {
|
||||
"ifly" : {}
|
||||
},
|
||||
"ad" : {},
|
||||
"oauth" : {
|
||||
"apple" : {},
|
||||
"weixin" : {
|
||||
"appid" : "wxae7a0c156da9383b",
|
||||
"UniversalLinks" : "https://shopro.sheepjs.com/uni-universallinks/__UNI__082C0BA/"
|
||||
}
|
||||
},
|
||||
"payment" : {
|
||||
"weixin" : {
|
||||
"__platform__" : [ "ios", "android" ],
|
||||
"appid" : "wxae7a0c156da9383b",
|
||||
"UniversalLinks" : "https://shopro.sheepjs.com/uni-universallinks/__UNI__082C0BA/"
|
||||
},
|
||||
"alipay" : {
|
||||
"__platform__" : [ "ios", "android" ]
|
||||
}
|
||||
},
|
||||
"share" : {
|
||||
"weixin" : {
|
||||
"appid" : "wxae7a0c156da9383b",
|
||||
"UniversalLinks" : "https://shopro.sheepjs.com/uni-universallinks/__UNI__082C0BA/"
|
||||
}
|
||||
}
|
||||
},
|
||||
"orientation" : [ "portrait-primary" ],
|
||||
"splashscreen" : {
|
||||
"androidStyle" : "common",
|
||||
"iosStyle" : "common",
|
||||
"useOriginalMsgbox" : true
|
||||
},
|
||||
"icons" : {
|
||||
"android" : {
|
||||
"hdpi" : "unpackage/res/icons/72x72.png",
|
||||
"xhdpi" : "unpackage/res/icons/96x96.png",
|
||||
"xxhdpi" : "unpackage/res/icons/144x144.png",
|
||||
"xxxhdpi" : "unpackage/res/icons/192x192.png"
|
||||
},
|
||||
"ios" : {
|
||||
"appstore" : "unpackage/res/icons/1024x1024.png",
|
||||
"ipad" : {
|
||||
"app" : "unpackage/res/icons/76x76.png",
|
||||
"app@2x" : "unpackage/res/icons/152x152.png",
|
||||
"notification" : "unpackage/res/icons/20x20.png",
|
||||
"notification@2x" : "unpackage/res/icons/40x40.png",
|
||||
"proapp@2x" : "unpackage/res/icons/167x167.png",
|
||||
"settings" : "unpackage/res/icons/29x29.png",
|
||||
"settings@2x" : "unpackage/res/icons/58x58.png",
|
||||
"spotlight" : "unpackage/res/icons/40x40.png",
|
||||
"spotlight@2x" : "unpackage/res/icons/80x80.png"
|
||||
},
|
||||
"iphone" : {
|
||||
"app@2x" : "unpackage/res/icons/120x120.png",
|
||||
"app@3x" : "unpackage/res/icons/180x180.png",
|
||||
"notification@2x" : "unpackage/res/icons/40x40.png",
|
||||
"notification@3x" : "unpackage/res/icons/60x60.png",
|
||||
"settings@2x" : "unpackage/res/icons/58x58.png",
|
||||
"settings@3x" : "unpackage/res/icons/87x87.png",
|
||||
"spotlight@2x" : "unpackage/res/icons/80x80.png",
|
||||
"spotlight@3x" : "unpackage/res/icons/120x120.png"
|
||||
}
|
||||
}
|
||||
}
|
||||
"ad": {},
|
||||
"oauth": {
|
||||
"apple": {},
|
||||
"weixin": {
|
||||
"appid": "wxae7a0c156da9383b",
|
||||
"UniversalLinks": "https://shopro.sheepjs.com/uni-universallinks/__UNI__082C0BA/"
|
||||
}
|
||||
},
|
||||
"payment": {
|
||||
"weixin": {
|
||||
"__platform__": [
|
||||
"ios",
|
||||
"android"
|
||||
],
|
||||
"appid": "wxae7a0c156da9383b",
|
||||
"UniversalLinks": "https://shopro.sheepjs.com/uni-universallinks/__UNI__082C0BA/"
|
||||
},
|
||||
"alipay": {
|
||||
"__platform__": [
|
||||
"ios",
|
||||
"android"
|
||||
]
|
||||
}
|
||||
},
|
||||
"share": {
|
||||
"weixin": {
|
||||
"appid": "wxae7a0c156da9383b",
|
||||
"UniversalLinks": "https://shopro.sheepjs.com/uni-universallinks/__UNI__082C0BA/"
|
||||
}
|
||||
}
|
||||
},
|
||||
"quickapp" : {},
|
||||
"quickapp-native" : {
|
||||
"icon" : "/static/logo.png",
|
||||
"package" : "com.example.demo",
|
||||
"features" : [
|
||||
{
|
||||
"name" : "system.clipboard"
|
||||
}
|
||||
]
|
||||
},
|
||||
"quickapp-webview" : {
|
||||
"icon" : "/static/logo.png",
|
||||
"package" : "com.example.demo",
|
||||
"minPlatformVersion" : 1070,
|
||||
"versionName" : "1.0.0",
|
||||
"versionCode" : 100
|
||||
},
|
||||
"mp-weixin" : {
|
||||
"appid" : "wx43051b2afa4ed3d0",
|
||||
"setting" : {
|
||||
"urlCheck" : false,
|
||||
"minified" : true,
|
||||
"postcss" : true
|
||||
},
|
||||
"orientation": [
|
||||
"portrait-primary"
|
||||
],
|
||||
"splashscreen": {
|
||||
"androidStyle": "common",
|
||||
"iosStyle": "common",
|
||||
"useOriginalMsgbox": true
|
||||
},
|
||||
"icons": {
|
||||
"android": {
|
||||
"hdpi": "unpackage/res/icons/72x72.png",
|
||||
"xhdpi": "unpackage/res/icons/96x96.png",
|
||||
"xxhdpi": "unpackage/res/icons/144x144.png",
|
||||
"xxxhdpi": "unpackage/res/icons/192x192.png"
|
||||
},
|
||||
"optimization" : {
|
||||
"subPackages" : true
|
||||
},
|
||||
"plugins" : {
|
||||
"live-player-plugin" : {
|
||||
"version" : "1.3.5",
|
||||
"provider" : "wx2b03c6e691cd7370"
|
||||
}
|
||||
},
|
||||
"lazyCodeLoading" : "requiredComponents",
|
||||
"usingComponents" : {},
|
||||
"permission" : {},
|
||||
"requiredPrivateInfos" : [ "chooseAddress" ]
|
||||
},
|
||||
"mp-alipay" : {
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-baidu" : {
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-toutiao" : {
|
||||
"usingComponents" : true
|
||||
},
|
||||
"mp-jd" : {
|
||||
"usingComponents" : true
|
||||
},
|
||||
"h5" : {
|
||||
"template" : "index.html",
|
||||
"router" : {
|
||||
"mode" : "hash",
|
||||
"base" : "./"
|
||||
},
|
||||
"sdkConfigs" : {
|
||||
"maps" : {}
|
||||
},
|
||||
"async" : {
|
||||
"timeout" : 20000
|
||||
},
|
||||
"title" : "星品购",
|
||||
"optimization" : {
|
||||
"treeShaking" : {
|
||||
"enable" : true
|
||||
}
|
||||
"ios": {
|
||||
"appstore": "unpackage/res/icons/1024x1024.png",
|
||||
"ipad": {
|
||||
"app": "unpackage/res/icons/76x76.png",
|
||||
"app@2x": "unpackage/res/icons/152x152.png",
|
||||
"notification": "unpackage/res/icons/20x20.png",
|
||||
"notification@2x": "unpackage/res/icons/40x40.png",
|
||||
"proapp@2x": "unpackage/res/icons/167x167.png",
|
||||
"settings": "unpackage/res/icons/29x29.png",
|
||||
"settings@2x": "unpackage/res/icons/58x58.png",
|
||||
"spotlight": "unpackage/res/icons/40x40.png",
|
||||
"spotlight@2x": "unpackage/res/icons/80x80.png"
|
||||
},
|
||||
"iphone": {
|
||||
"app@2x": "unpackage/res/icons/120x120.png",
|
||||
"app@3x": "unpackage/res/icons/180x180.png",
|
||||
"notification@2x": "unpackage/res/icons/40x40.png",
|
||||
"notification@3x": "unpackage/res/icons/60x60.png",
|
||||
"settings@2x": "unpackage/res/icons/58x58.png",
|
||||
"settings@3x": "unpackage/res/icons/87x87.png",
|
||||
"spotlight@2x": "unpackage/res/icons/80x80.png",
|
||||
"spotlight@3x": "unpackage/res/icons/120x120.png"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"quickapp": {},
|
||||
"quickapp-native": {
|
||||
"icon": "/static/logo.png",
|
||||
"package": "com.example.demo",
|
||||
"features": [
|
||||
{
|
||||
"name": "system.clipboard"
|
||||
}
|
||||
]
|
||||
},
|
||||
"quickapp-webview": {
|
||||
"icon": "/static/logo.png",
|
||||
"package": "com.example.demo",
|
||||
"minPlatformVersion": 1070,
|
||||
"versionName": "1.0.0",
|
||||
"versionCode": 100
|
||||
},
|
||||
"mp-weixin": {
|
||||
"appid": "wx43051b2afa4ed3d0",
|
||||
"setting": {
|
||||
"urlCheck": false,
|
||||
"minified": true,
|
||||
"postcss": true
|
||||
},
|
||||
"vueVersion" : "3",
|
||||
"_spaceID" : "192b4892-5452-4e1d-9f09-eee1ece40639",
|
||||
"locale" : "zh-Hans",
|
||||
"fallbackLocale" : "zh-Hans"
|
||||
}
|
||||
"optimization": {
|
||||
"subPackages": true
|
||||
},
|
||||
"plugins": {
|
||||
"live-player-plugin": {
|
||||
"version": "1.3.5",
|
||||
"provider": "wx2b03c6e691cd7370"
|
||||
}
|
||||
},
|
||||
"lazyCodeLoading": "requiredComponents",
|
||||
"usingComponents": {},
|
||||
"permission": {},
|
||||
"requiredPrivateInfos": [
|
||||
"chooseAddress"
|
||||
]
|
||||
},
|
||||
"mp-alipay": {
|
||||
"usingComponents": true
|
||||
},
|
||||
"mp-baidu": {
|
||||
"usingComponents": true
|
||||
},
|
||||
"mp-toutiao": {
|
||||
"usingComponents": true
|
||||
},
|
||||
"mp-jd": {
|
||||
"usingComponents": true
|
||||
},
|
||||
"h5": {
|
||||
"template": "index.html",
|
||||
"router": {
|
||||
"mode": "hash",
|
||||
"base": "./"
|
||||
},
|
||||
"sdkConfigs": {
|
||||
"maps": {}
|
||||
},
|
||||
"async": {
|
||||
"timeout": 20000
|
||||
},
|
||||
"title": "星品购",
|
||||
"optimization": {
|
||||
"treeShaking": {
|
||||
"enable": true
|
||||
}
|
||||
}
|
||||
},
|
||||
"vueVersion": "3",
|
||||
"_spaceID": "192b4892-5452-4e1d-9f09-eee1ece40639",
|
||||
"locale": "zh-Hans",
|
||||
"fallbackLocale": "zh-Hans"
|
||||
}
|
|
@ -1,28 +0,0 @@
|
|||
const fs = require('fs');
|
||||
|
||||
const manifestPath = process.env.UNI_INPUT_DIR + '/manifest.json';
|
||||
|
||||
let Manifest = fs.readFileSync(manifestPath, { encoding: 'utf-8' });
|
||||
function replaceManifest(value, remove) {
|
||||
|
||||
|
||||
let data = JSON.parse(Manifest)
|
||||
let newValue = JSON.parse(value)
|
||||
if (remove === 'delete') {
|
||||
delete data['mp-weixin'].plugins['live-player-plugin'];
|
||||
} else {
|
||||
if (data['mp-weixin'].plugins['live-player-plugin']) return;
|
||||
data['mp-weixin'].plugins = {
|
||||
...data['mp-weixin'].plugins,
|
||||
...newValue
|
||||
}
|
||||
|
||||
}
|
||||
Manifest = JSON.stringify(data)
|
||||
|
||||
fs.writeFileSync(manifestPath, Manifest, {
|
||||
"flag": "w"
|
||||
})
|
||||
}
|
||||
|
||||
export default replaceManifest
|
|
@ -294,7 +294,8 @@
|
|||
const { error, data } = await sheep.$api.activity.grouponDetail(id);
|
||||
if (error === 0) {
|
||||
state.data = data;
|
||||
state.number = Number(state.data.num - state.data.current_num);
|
||||
let number = Number(state.data.num - state.data.current_num);
|
||||
state.number = number > 0 ? number : 0;
|
||||
} else {
|
||||
state.data = null;
|
||||
}
|
||||
|
|
|
@ -58,29 +58,28 @@
|
|||
</uni-forms-item>
|
||||
</view>
|
||||
</uni-forms>
|
||||
<radio-group @change="onChange" v-if="state.protocol?.status == 1">
|
||||
<label class="ss-flex ss-m-t-20">
|
||||
<radio
|
||||
:checked="state.isAgree"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.6)"
|
||||
/>
|
||||
<view class="agreement-text ss-flex">
|
||||
<view class="ss-m-r-4">勾选代表同意</view>
|
||||
<view
|
||||
class="tcp-text"
|
||||
@tap.stop="
|
||||
sheep.$router.go('/pages/public/richtext', {
|
||||
id: state.protocol.id,
|
||||
title: state.protocol.title,
|
||||
})
|
||||
"
|
||||
>
|
||||
《{{ state.protocol.title }}》
|
||||
</view>
|
||||
<label class="ss-flex ss-m-t-20" v-if="state.protocol?.status == 1" @tap="onChange">
|
||||
<radio
|
||||
:checked="state.isAgree"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.6)"
|
||||
@tap.stop="onChange"
|
||||
/>
|
||||
<view class="agreement-text ss-flex">
|
||||
<view class="ss-m-r-4">勾选代表同意</view>
|
||||
<view
|
||||
class="tcp-text"
|
||||
@tap.stop="
|
||||
sheep.$router.go('/pages/public/richtext', {
|
||||
id: state.protocol.id,
|
||||
title: state.protocol.title,
|
||||
})
|
||||
"
|
||||
>
|
||||
《{{ state.protocol.title }}》
|
||||
</view>
|
||||
</label>
|
||||
</radio-group>
|
||||
</view>
|
||||
</label>
|
||||
<su-fixed bottom placeholder>
|
||||
<view class="submit-box ss-flex ss-row-center ss-p-30">
|
||||
<button class="submit-btn ss-reset-button ui-BG-Main ui-Shadow-Main" @tap="submit">
|
||||
|
|
|
@ -32,6 +32,10 @@
|
|||
</view>
|
||||
</scroll-view>
|
||||
</view>
|
||||
<view class="ss-m-t-20 reply-box" v-if="item.reply_time">
|
||||
<view class="reply-title">商家回复</view>
|
||||
<view class="reply-content">{{ item.reply_content }}</view>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
|
@ -71,4 +75,24 @@
|
|||
font-weight: 400;
|
||||
color: #333333;
|
||||
}
|
||||
.reply-box {
|
||||
position: relative;
|
||||
}
|
||||
.reply-title {
|
||||
position: absolute;
|
||||
left: 0;
|
||||
top: 0;
|
||||
font-weight: 600;
|
||||
font-size: 26rpx;
|
||||
line-height: 40rpx;
|
||||
color: #666666;
|
||||
}
|
||||
|
||||
.reply-content {
|
||||
text-indent: 108rpx;
|
||||
font-weight: 400;
|
||||
font-size: 26rpx;
|
||||
line-height: 40rpx;
|
||||
color: #333333;
|
||||
}
|
||||
</style>
|
||||
|
|
|
@ -27,18 +27,14 @@
|
|||
<view class="cart-content ss-flex-1 ss-p-x-30 ss-m-b-40">
|
||||
<view class="goods-box ss-r-10 ss-m-b-14" v-for="item in state.list" :key="item.id">
|
||||
<view class="ss-flex ss-col-center">
|
||||
<radio-group
|
||||
@change="onSelectSingle(item.id)"
|
||||
class="check-box ss-flex ss-col-center ss-p-l-10"
|
||||
>
|
||||
<label class="radio ss-flex">
|
||||
<radio
|
||||
:checked="state.selectedIds.includes(item.id)"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
/>
|
||||
</label>
|
||||
</radio-group>
|
||||
<label class="check-box ss-flex ss-col-center ss-p-l-10" @tap="onSelectSingle(item.id)">
|
||||
<radio
|
||||
:checked="state.selectedIds.includes(item.id)"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
@tap.stop="onSelectSingle(item.id)"
|
||||
/>
|
||||
</label>
|
||||
<s-goods-item
|
||||
:title="item.goods.title"
|
||||
:img="item.sku_price.image || item.goods.image"
|
||||
|
@ -64,16 +60,15 @@
|
|||
<su-fixed bottom :val="48" placeholder v-if="state.list.length > 0" :isInset="false">
|
||||
<view class="cart-footer ss-flex ss-col-center ss-row-between ss-p-x-30 border-bottom">
|
||||
<view class="footer-left ss-flex ss-col-center">
|
||||
<radio-group @change="onSelectAll" class="check-box ss-flex ss-col-center ss-p-r-30">
|
||||
<label class="radio ss-flex">
|
||||
<radio
|
||||
:checked="state.isAllSelected"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
/>
|
||||
<view class="ss-m-l-8"> 全选 </view>
|
||||
</label>
|
||||
</radio-group>
|
||||
<label class="check-box ss-flex ss-col-center ss-p-r-30" @tap="onSelectAll">
|
||||
<radio
|
||||
:checked="state.isAllSelected"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
@tap.stop="onSelectAll"
|
||||
/>
|
||||
<view class="ss-m-l-8"> 全选 </view>
|
||||
</label>
|
||||
<text>合计:</text>
|
||||
<view class="text-price price-text">
|
||||
{{ state.totalPriceSelected }}
|
||||
|
@ -156,6 +151,7 @@
|
|||
cart.delete(cartItem.id);
|
||||
return;
|
||||
}
|
||||
cartItem.goods_num = e;
|
||||
cart.update({
|
||||
goods_id: cartItem.goods_id,
|
||||
goods_num: e,
|
||||
|
|
|
@ -347,9 +347,6 @@
|
|||
.item-value {
|
||||
font-size: 28rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.item-value {
|
||||
font-family: OPPOSANS;
|
||||
}
|
||||
.text-disabled {
|
||||
|
|
|
@ -199,10 +199,10 @@
|
|||
</view>
|
||||
<view
|
||||
class="notice-item ss-flex ss-row-between"
|
||||
v-if="state.orderInfo.promo_discount_fee > 0"
|
||||
v-if="state.orderInfo.total_discount_fee > 0"
|
||||
>
|
||||
<text class="title">优惠金额</text>
|
||||
<text class="detail">¥{{ state.orderInfo.promo_discount_fee }}</text>
|
||||
<text class="detail">¥{{ state.orderInfo.total_discount_fee }}</text>
|
||||
</view>
|
||||
<view class="notice-item all-rpice-item ss-flex ss-m-t-20">
|
||||
<text class="title">{{
|
||||
|
|
|
@ -102,7 +102,7 @@
|
|||
>¥{{ order.order_amount }}</view
|
||||
>
|
||||
<view v-if="order.score_amount && Number(order.order_amount) > 0">+</view>
|
||||
<view class="price-text ss-flex ss-col-center" v-if="order.score_amount">
|
||||
<view class="discounts-money pay-color ss-flex ss-col-center" v-if="order.score_amount">
|
||||
<image
|
||||
:src="sheep.$url.static('/static/img/shop/goods/score1.svg')"
|
||||
class="score-img"
|
||||
|
|
|
@ -5,28 +5,25 @@
|
|||
<text class="modal-title ss-m-b-20">选择提现方式</text>
|
||||
</view>
|
||||
<view class="modal-content ss-flex-1 ss-p-b-100">
|
||||
<view
|
||||
class="container-list ss-p-l-34 ss-p-r-24 ss-flex ss-col-center ss-row-center"
|
||||
v-for="(item, index) in typeList"
|
||||
:key="index"
|
||||
>
|
||||
<view class="container-icon ss-flex ss-m-r-20">
|
||||
<image :src="sheep.$url.static(item.icon)" />
|
||||
</view>
|
||||
<view class="ss-flex-1">{{ item.title }}</view>
|
||||
<view class="radio">
|
||||
<radio-group @change="onChange">
|
||||
<label class="radio">
|
||||
<radio
|
||||
:value="item.value"
|
||||
color="var(--ui-BG-Main)"
|
||||
:checked="item.value === state.currentValue"
|
||||
:disabled="!methods.includes(item.value)"
|
||||
/>
|
||||
</label>
|
||||
</radio-group>
|
||||
</view>
|
||||
</view>
|
||||
<radio-group @change="onChange">
|
||||
<label
|
||||
class="container-list ss-p-l-34 ss-p-r-24 ss-flex ss-col-center ss-row-center"
|
||||
v-for="(item, index) in typeList"
|
||||
:key="index"
|
||||
>
|
||||
<view class="container-icon ss-flex ss-m-r-20">
|
||||
<image :src="sheep.$url.static(item.icon)" />
|
||||
</view>
|
||||
<view class="ss-flex-1">{{ item.title }}</view>
|
||||
|
||||
<radio
|
||||
:value="item.value"
|
||||
color="var(--ui-BG-Main)"
|
||||
:checked="item.value === state.currentValue"
|
||||
:disabled="!methods.includes(item.value)"
|
||||
/>
|
||||
</label>
|
||||
</radio-group>
|
||||
</view>
|
||||
<view class="modal-footer ss-flex ss-row-center ss-col-center">
|
||||
<button class="ss-reset-button save-btn" @tap="onConfirm">确定</button>
|
||||
|
|
|
@ -3,7 +3,6 @@
|
|||
<s-layout title="收银台">
|
||||
<view class="bg-white ss-modal-box ss-flex-col">
|
||||
<view class="modal-header ss-flex-col ss-col-center ss-row-center">
|
||||
<text class="modal-title ss-m-b-30">收银台</text>
|
||||
<view class="money-box ss-m-b-20">
|
||||
<text class="money-text">{{ state.orderInfo.pay_fee }}</text>
|
||||
</view>
|
||||
|
@ -277,10 +276,6 @@
|
|||
position: relative;
|
||||
padding: 60rpx 20rpx 40rpx;
|
||||
|
||||
.modal-title {
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
|
||||
.money-text {
|
||||
color: $red;
|
||||
|
|
|
@ -32,24 +32,23 @@
|
|||
:key="item.id"
|
||||
>
|
||||
<view class="ss-flex ss-col-center">
|
||||
<radio-group
|
||||
<label
|
||||
class="check-box ss-flex ss-col-center ss-p-l-10"
|
||||
@change="onSelect(item.goods_id)"
|
||||
v-show="state.editMode"
|
||||
v-if="state.editMode"
|
||||
@tap="onSelect(item.goods_id)"
|
||||
>
|
||||
<label class="radio">
|
||||
<radio
|
||||
:checked="state.selectedCollectList.includes(item.goods_id)"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
/>
|
||||
</label>
|
||||
</radio-group>
|
||||
<radio
|
||||
:checked="state.selectedCollectList.includes(item.goods_id)"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
@tap.stop="onSelect(item.goods_id)"
|
||||
/>
|
||||
</label>
|
||||
<s-goods-item
|
||||
:title="item.goods.title"
|
||||
:img="item.goods.image"
|
||||
price="666"
|
||||
skuText="123"
|
||||
:price="item.goods.price[0]"
|
||||
:skuText="item.goods.subtitle"
|
||||
priceColor="#FF3000"
|
||||
:titleWidth="400"
|
||||
@tap="
|
||||
|
@ -66,16 +65,15 @@
|
|||
<su-fixed bottom :val="0" placeholder v-show="state.editMode">
|
||||
<view class="cart-footer ss-flex ss-col-center ss-row-between ss-p-x-30 border-bottom">
|
||||
<view class="footer-left ss-flex ss-col-center">
|
||||
<radio-group @change="onSelectAll">
|
||||
<label class="check-box ss-flex ss-col-center ss-p-r-30">
|
||||
<radio
|
||||
:checked="state.selectAll"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.7)"
|
||||
/>
|
||||
<view> 全选 </view>
|
||||
</label>
|
||||
</radio-group>
|
||||
<label class="check-box ss-flex ss-col-center ss-p-r-30" @tap="onSelectAll">
|
||||
<radio
|
||||
:checked="state.selectAll"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.7)"
|
||||
@tap.stop="onSelectAll"
|
||||
/>
|
||||
<view> 全选 </view>
|
||||
</label>
|
||||
</view>
|
||||
<view class="footer-right">
|
||||
<button
|
||||
|
|
|
@ -35,24 +35,23 @@
|
|||
:key="item.id"
|
||||
>
|
||||
<view class="ss-flex ss-col-center">
|
||||
<radio-group
|
||||
v-show="state.editMode"
|
||||
<label
|
||||
class="check-box ss-flex ss-col-center ss-p-l-10"
|
||||
@change="onSelect(item.goods_id)"
|
||||
v-if="state.editMode"
|
||||
@tap="onSelect(item.goods_id)"
|
||||
>
|
||||
<label class="radio">
|
||||
<radio
|
||||
:checked="state.selectedCollectList.includes(item.goods_id)"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
/>
|
||||
</label>
|
||||
</radio-group>
|
||||
<radio
|
||||
:checked="state.selectedCollectList.includes(item.goods_id)"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
@tap.stop="onSelect(item.goods_id)"
|
||||
/>
|
||||
</label>
|
||||
<s-goods-item
|
||||
:title="item.goods.title"
|
||||
:img="item.goods.image"
|
||||
price="666"
|
||||
skuText="123"
|
||||
:price="item.goods.price[0]"
|
||||
:skuText="item.goods.subtitle"
|
||||
priceColor="#FF3000"
|
||||
:titleWidth="400"
|
||||
@tap="
|
||||
|
@ -69,16 +68,15 @@
|
|||
<su-fixed bottom :val="0" placeholder v-show="state.editMode">
|
||||
<view class="cart-footer ss-flex ss-col-center ss-row-between ss-p-x-30 border-bottom">
|
||||
<view class="footer-left ss-flex ss-col-center">
|
||||
<radio-group @change="onSelectAll">
|
||||
<label class="check-box ss-flex ss-col-center ss-p-r-30">
|
||||
<radio
|
||||
:checked="state.selectAll"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.7)"
|
||||
/>
|
||||
<view>全选</view>
|
||||
</label>
|
||||
</radio-group>
|
||||
<label class="check-box ss-flex ss-col-center ss-p-r-30" @tap="onSelectAll">
|
||||
<radio
|
||||
:checked="state.selectAll"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.7)"
|
||||
@tap.stop="onSelectAll"
|
||||
/>
|
||||
<view>全选</view>
|
||||
</label>
|
||||
</view>
|
||||
<view class="footer-right">
|
||||
<button
|
||||
|
@ -140,11 +138,11 @@
|
|||
page,
|
||||
});
|
||||
if (res.error === 0) {
|
||||
let orderList = _.concat(state.pagination.data, res.data.data);
|
||||
state.pagination = {
|
||||
...res.data,
|
||||
data: orderList,
|
||||
};
|
||||
let orderList = _.concat(state.pagination.data, res.data.data);
|
||||
state.pagination = {
|
||||
...res.data,
|
||||
data: orderList,
|
||||
};
|
||||
if (state.pagination.current_page < state.pagination.last_page) {
|
||||
state.loadStatus = 'more';
|
||||
} else {
|
||||
|
@ -190,7 +188,7 @@
|
|||
state.editMode = false;
|
||||
state.selectedCollectList = [];
|
||||
state.selectAll = false;
|
||||
state.pagination = pagination
|
||||
state.pagination = pagination;
|
||||
getData();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -75,31 +75,30 @@
|
|||
v-if="['accountLogin', 'smsLogin', 'smsRegister'].includes(authType)"
|
||||
class="agreement-box ss-flex ss-row-center"
|
||||
>
|
||||
<radio-group @change="onChange" class="ss-flex ss-col-center">
|
||||
<label class="radio ss-flex">
|
||||
<radio
|
||||
:checked="state.protocol"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
/>
|
||||
<view class="agreement-text ss-flex ss-col-center ss-m-l-8">
|
||||
我已阅读并遵守
|
||||
<view
|
||||
class="tcp-text"
|
||||
@tap.stop="onProtocol(appInfo.user_protocol.id, appInfo.user_protocol.title)"
|
||||
>
|
||||
《{{ appInfo.user_protocol.title }}》
|
||||
</view>
|
||||
<view class="agreement-text">与</view>
|
||||
<view
|
||||
class="tcp-text"
|
||||
@tap.stop="onProtocol(appInfo.privacy_protocol.id, appInfo.privacy_protocol.title)"
|
||||
>
|
||||
《{{ appInfo.privacy_protocol.title }}》
|
||||
</view>
|
||||
<label class="radio ss-flex ss-col-center" @tap="onChange">
|
||||
<radio
|
||||
:checked="state.protocol"
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
@tap.stop="onChange"
|
||||
/>
|
||||
<view class="agreement-text ss-flex ss-col-center ss-m-l-8">
|
||||
我已阅读并遵守
|
||||
<view
|
||||
class="tcp-text"
|
||||
@tap.stop="onProtocol(appInfo.user_protocol.id, appInfo.user_protocol.title)"
|
||||
>
|
||||
《{{ appInfo.user_protocol.title }}》
|
||||
</view>
|
||||
</label>
|
||||
</radio-group>
|
||||
<view class="agreement-text">与</view>
|
||||
<view
|
||||
class="tcp-text"
|
||||
@tap.stop="onProtocol(appInfo.privacy_protocol.id, appInfo.privacy_protocol.title)"
|
||||
>
|
||||
《{{ appInfo.privacy_protocol.title }}》
|
||||
</view>
|
||||
</view>
|
||||
</label>
|
||||
</view>
|
||||
<view class="safe-box"></view>
|
||||
</view>
|
||||
|
|
|
@ -154,6 +154,7 @@
|
|||
font-size: 64rpx;
|
||||
font-weight: 500;
|
||||
line-height: normal;
|
||||
font-family: OPPOSANS;
|
||||
}
|
||||
.value-reduce {
|
||||
line-height: normal;
|
||||
|
@ -166,6 +167,7 @@
|
|||
.value-enough {
|
||||
font-size: 24rpx;
|
||||
font-weight: 400;
|
||||
font-family: OPPOSANS;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -19,15 +19,14 @@
|
|||
<view v-for="(item, index) in state.couponInfo.can_use" :key="index">
|
||||
<s-coupon-list :data="item" type="user" :disabled="false">
|
||||
<template #default>
|
||||
<radio-group @change="radioChange(item.id)" class="ss-flex ss-col-center">
|
||||
<label class="radio">
|
||||
<radio
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
:checked="state.couponId == item.id"
|
||||
/>
|
||||
</label>
|
||||
</radio-group>
|
||||
<label class="ss-flex ss-col-center" @tap="radioChange(item.id)">
|
||||
<radio
|
||||
color="var(--ui-BG-Main)"
|
||||
style="transform: scale(0.8)"
|
||||
:checked="state.couponId == item.id"
|
||||
@tap.stop="radioChange(item.id)"
|
||||
/>
|
||||
</label>
|
||||
</template>
|
||||
</s-coupon-list>
|
||||
</view>
|
||||
|
|
|
@ -11,7 +11,7 @@
|
|||
<view class="md-goods-title ss-line-1" :style="[{ color: titleColor }]">
|
||||
{{ data.name }}
|
||||
</view>
|
||||
<view class="md-goods-subtitle ss-m-t-20 ss-line-1" :style="[{ color: subTitleColor }]">
|
||||
<view class="md-goods-subtitle ss-m-t-14 ss-line-1" :style="[{ color: subTitleColor }]">
|
||||
主播:{{ data.anchor_name }}
|
||||
</view>
|
||||
</view>
|
||||
|
@ -27,7 +27,7 @@
|
|||
<view class="sl-goods-title ss-line-1" :style="[{ color: titleColor }]">
|
||||
{{ data.name }}
|
||||
</view>
|
||||
<view class="sl-goods-subtitle ss-m-t-20 ss-line-1" :style="[{ color: subTitleColor }]">
|
||||
<view class="sl-goods-subtitle ss-m-t-14 ss-line-1" :style="[{ color: subTitleColor }]">
|
||||
主播:{{ data.anchor_name }}
|
||||
</view>
|
||||
</view>
|
||||
|
@ -140,6 +140,7 @@
|
|||
height: 40rpx;
|
||||
background: rgba(#000000, 0.5);
|
||||
border-radius: 20rpx;
|
||||
z-index: 1;
|
||||
.icon {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
|
@ -153,8 +154,11 @@
|
|||
}
|
||||
.md-goods-content {
|
||||
position: absolute;
|
||||
left: 20rpx;
|
||||
bottom: 20rpx;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
padding: 20rpx;
|
||||
width: 100%;
|
||||
background: linear-gradient(360deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.02) 100%);
|
||||
}
|
||||
|
||||
.md-img-box {
|
||||
|
@ -186,9 +190,9 @@
|
|||
top: 10rpx;
|
||||
width: 136rpx;
|
||||
height: 40rpx;
|
||||
background: #000000;
|
||||
opacity: 0.5;
|
||||
background: rgba(#000000, 0.5);
|
||||
border-radius: 20rpx;
|
||||
z-index: 1;
|
||||
.icon {
|
||||
width: 40rpx;
|
||||
height: 40rpx;
|
||||
|
@ -202,8 +206,11 @@
|
|||
}
|
||||
.sl-goods-content {
|
||||
position: absolute;
|
||||
left: 20rpx;
|
||||
bottom: 20rpx;
|
||||
left: 0;
|
||||
bottom: 0;
|
||||
padding: 20rpx;
|
||||
width: 100%;
|
||||
background: linear-gradient(360deg, rgba(0, 0, 0, 0.8) 0%, rgba(0, 0, 0, 0.02) 100%);
|
||||
}
|
||||
|
||||
.sl-img-box {
|
||||
|
|
|
@ -100,9 +100,9 @@
|
|||
}
|
||||
|
||||
.unit-text {
|
||||
font-size: 16rpx;
|
||||
color: #000000;
|
||||
line-height: 16rpx;
|
||||
font-size: 24rpx;
|
||||
color: #343434;
|
||||
line-height: 24rpx;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -0,0 +1,32 @@
|
|||
const fs = require('fs');
|
||||
|
||||
const manifestPath = process.env.UNI_INPUT_DIR + '/manifest.json';
|
||||
|
||||
let Manifest = fs.readFileSync(manifestPath, {
|
||||
encoding: 'utf-8'
|
||||
});
|
||||
|
||||
function mpliveMainfestPlugin(isOpen) {
|
||||
if (process.env.UNI_PLATFORM !== 'mp-weixin') return;
|
||||
|
||||
const manifestData = JSON.parse(Manifest)
|
||||
|
||||
if (isOpen === '0') {
|
||||
delete manifestData['mp-weixin'].plugins['live-player-plugin'];
|
||||
}
|
||||
|
||||
if (isOpen === '1') {
|
||||
manifestData['mp-weixin'].plugins['live-player-plugin'] = {
|
||||
"version": "1.3.5",
|
||||
"provider": "wx2b03c6e691cd7370"
|
||||
}
|
||||
}
|
||||
|
||||
Manifest = JSON.stringify(manifestData, null, 2)
|
||||
|
||||
fs.writeFileSync(manifestPath, Manifest, {
|
||||
"flag": "w"
|
||||
})
|
||||
}
|
||||
|
||||
export default mpliveMainfestPlugin
|
|
@ -3,28 +3,12 @@ import uni from '@dcloudio/vite-plugin-uni';
|
|||
import path from 'path';
|
||||
// import viteCompression from 'vite-plugin-compression';
|
||||
import uniReadPagesV3Plugin from './sheep/router/utils/uni-read-pages-v3';
|
||||
// 引入直播组件
|
||||
import replaceManifest from './modifyManifest'
|
||||
import mpliveMainfestPlugin from './sheep/libs/mpLive-manifest-plugin';
|
||||
|
||||
|
||||
// https://vitejs.dev/config/
|
||||
export default (command, mode) => {
|
||||
const env = loadEnv(mode, __dirname, 'SHOPRO_');
|
||||
if (env.SHOPRO_MPLIVE_ON === 'true') {
|
||||
replaceManifest(`{
|
||||
"live-player-plugin": {
|
||||
"version": "1.3.5",
|
||||
"provider": "wx2b03c6e691cd7370"
|
||||
}
|
||||
}`, 'push')
|
||||
} else {
|
||||
replaceManifest(`{
|
||||
"live-player-plugin": {
|
||||
"version": "1.3.5",
|
||||
"provider": "wx2b03c6e691cd7370"
|
||||
}
|
||||
}`, 'delete')
|
||||
}
|
||||
return {
|
||||
envPrefix: "SHOPRO_",
|
||||
plugins: [
|
||||
|
@ -36,6 +20,7 @@ export default (command, mode) => {
|
|||
pagesJsonDir: path.resolve(__dirname, './pages.json'),
|
||||
includes: ['path', 'aliasPath', 'name', 'meta'],
|
||||
}),
|
||||
mpliveMainfestPlugin(env.SHOPRO_MPLIVE_ON)
|
||||
],
|
||||
server: {
|
||||
host: true,
|
||||
|
|
Loading…
Reference in New Issue