20 Commits
Author SHA1 Message Date
YunaiV ae3cef3e19 【发版】全局:2.1.0 发版 2024-05-04 11:17:53 +08:00
YunaiV 68d2fc4c24 【修复】拼团装修组件,跳转拼团商品界面的 id 不正确的问题 2024-05-02 10:16:17 +08:00
YunaiV c3f3c44e63 【完善】兼容 HBuilder 最新版本 vite5 2024-05-02 09:39:00 +08:00
芋道源码 97802232a2 !51 update pages/order/detail.vue. @tap="onGoodsDetail(item.skuId)" =>@tap="onGoodsDetail(item.spuId)"
Merge pull request !51 from 孙正涛/N/A
2024-05-02 01:29:15 +00:00
孙正涛 73dbe70305 update pages/order/detail.vue. @tap="onGoodsDetail(item.skuId)" =>@tap="onGoodsDetail(item.spuId)"
点击查看商品详情时应该跳转的是spuId

Signed-off-by: 孙正涛 <alchemy7746@163.com>
2024-04-15 03:47:47 +00:00
YunaiV a816582206 bugfix:修复拼团详情错误传递 groupon_id 的问题 2024-03-30 15:28:29 +08:00
芋道源码 d2c4b9efc9 !50 适配顶部导航
Merge pull request !50 from 疯狂的世界/navbar
2024-03-17 01:26:39 +00:00
owen 13986f3943 适配顶部导航 2024-03-13 22:46:46 +08:00
芋道源码 b7c38be5b3 !49 update pages/index/login.vue.
Merge pull request !49 from 天痕/N/A
2024-03-09 10:35:24 +00:00
芋道源码 d7eb74968a !48 配置文件描述修改
Merge pull request !48 from 天痕/N/A
2024-03-09 10:34:03 +00:00
芋道源码 ddc54679fb !47 完善微信导入收货地址
Merge pull request !47 from DH/N/A
2024-03-09 10:33:32 +00:00
芋道源码 7226eb8eb0 !46 fix : data.combinationActivityId
Merge pull request !46 from cnyballk/fix/api/trade/order
2024-03-09 10:32:02 +00:00
芋道源码 a0deb30075 !45 fix: gravityFormat to gravityFormatMap
Merge pull request !45 from cnyballk/master
2024-03-09 10:31:30 +00:00
芋道源码 e8cc7cb6c0 !44 fix: add export checkUpdate
Merge pull request !44 from cnyballk/fix/wechat/checkUpdate
2024-03-09 10:28:49 +00:00
天痕 f6fefe3aef update pages/index/login.vue.
移除回调,用法错误

Signed-off-by: 天痕 <614891294@qq.com>
2024-03-05 05:55:36 +00:00
天痕 bfdb7bd00e 配置文件描述修改
描述有问题
2024-03-05 05:47:01 +00:00
DH d1162d8552 完善微信导入收货地址
Signed-off-by: DH <ji534@outlook.com>
2024-03-04 08:48:18 +00:00
cnyballk 19ebbecb0c fix: data.combinationActivityId
Signed-off-by: cnyballk <584518260@qq.com>
2024-03-04 07:14:45 +00:00
cnyballk e4ca6b4e68 fix: gravityFormat to gravityFormatMap
Signed-off-by: cnyballk <584518260@qq.com>
2024-03-04 03:46:48 +00:00
cnyballk f478606ae4 fix: mini export checkUpdate
Signed-off-by: cnyballk <584518260@qq.com>
2024-03-01 15:24:50 +00:00
19 changed files with 77 additions and 69 deletions

No files matched your search

+2 -2
View File
@@ -1,10 +1,10 @@
# 版本号
SHOPRO_VERSION = v1.8.3
# 后端接口 - 正式环境(通过 process.env.NODE_ENV = development)
# 后端接口 - 正式环境(通过 process.env.NODE_ENV 非 development)
SHOPRO_BASE_URL = http://api-dashboard.yudao.iocoder.cn
# 后端接口 - 测试环境(通过 process.env.NODE_ENV 非 development)
# 后端接口 - 测试环境(通过 process.env.NODE_ENV = development)
SHOPRO_DEV_BASE_URL = http://127.0.0.1:48080
### SHOPRO_DEV_BASE_URL = http://yunai.natapp1.cc
+1 -1
View File
@@ -2,7 +2,7 @@
"name": "芋道商城",
"appid": "__UNI__460BC4C",
"description": "基于 uni-app + Vue3 技术驱动的在线商城系统,内含诸多功能与丰富的活动,期待您的使用和反馈。",
"versionName": "1.8.3",
"versionName": "2.1.0",
"versionCode": 183,
"transformPx": false,
"app-plus": {
+1 -1
View File
@@ -2,7 +2,7 @@
"id": "shopro",
"name": "shopro",
"displayName": "芋道商城",
"version": "2.0.1",
"version": "2.1.0",
"description": "芋道商城,一套代码,同时发行到iOS、Android、H5、微信小程序多个平台,请使用手机扫码快速体验强大功能",
"scripts": {
"prettier": "prettier --write \"{pages,sheep}/**/*.{js,json,tsx,css,less,scss,vue,html,md}\""
+1 -1
View File
@@ -2,7 +2,7 @@
<template>
<view v-if="template">
<s-layout title="首页" navbar="custom" tabbar="/pages/index/index" :bgStyle="template.page"
:navbarStyle="template.style?.navbar" onShareAppMessage>
:navbarStyle="template.navigationBar" onShareAppMessage>
<s-block v-for="(item, index) in template.components" :key="index" :styles="item.property.style">
<s-block-item :type="item.id" :data="item.property" :styles="item.property.style" />
</s-block>
+1 -1
View File
@@ -26,7 +26,7 @@
// 检测 H5 登录回调
let returnUrl = uni.getStorageSync('returnUrl');
if (returnUrl) {
uni.removeStorage('returnUrl');
uni.removeStorage({key:'returnUrl'});
location.replace(returnUrl);
} else {
uni.switchTab({
+1 -1
View File
@@ -5,7 +5,7 @@
tabbar="/pages/index/user"
navbar="custom"
:bgStyle="template.page"
:navbarStyle="template.style?.navbar"
:navbarStyle="template.navigationBar"
onShareAppMessage
>
<s-block v-for="(item, index) in template.components" :key="index" :styles="item.property.style">
+2 -3
View File
@@ -71,7 +71,7 @@
<view class="order-list" v-for="item in state.orderInfo.items" :key="item.goods_id">
<view class="order-card">
<s-goods-item
@tap="onGoodsDetail(item.skuId)"
@tap="onGoodsDetail(item.spuId)"
:img="item.picUrl"
:title="item.spuName"
:skuText="item.properties.map((property) => property.valueName).join(' ')"
@@ -211,13 +211,12 @@
>
继续支付
</button>
<!-- TODO 芋艿:拼团接入 -->
<button
class="ss-reset-button cancel-btn"
v-if="state.orderInfo.buttons?.includes('combination')"
@tap="
sheep.$router.go('/pages/activity/groupon/detail', {
id: state.orderInfo.ext.groupon_id,
id: state.orderInfo.combinationRecordId,
})
"
>
+2 -2
View File
@@ -144,10 +144,10 @@
});
}
// 分享拼团 TODO 芋艿:待测试
// 跳转拼团记录的详情
function onOrderGroupon(order) {
sheep.$router.go('/pages/activity/groupon/detail', {
id: order.ext.groupon_id,
id: order.combinationRecordId,
});
}
+20 -14
View File
@@ -167,20 +167,26 @@
}
state.model = data;
}
// 情况二:微信导入 TODO 芋艿:待接入
if (options.data) {
let data = JSON.parse(options.data);
const areaData = uni.getStorageSync('areaData');
let provinceArr = areaData.filter(item => item.name == data.province_name);
data.province_id = provinceArr[0].id;
let provinceArr2 = provinceArr[0].children.filter(item => item.name == data.city_name);
data.city_id = provinceArr2[0].id;
let provinceArr3 = provinceArr2[0].children.filter(item => item.name == data.district_name);
data.district_id = provinceArr3[0].id;
state.model = {
...state.model,
...data,
};
// 情况二:微信导入
if (options.data) {
let data = JSON.parse(options.data);
const areaData = uni.getStorageSync('areaData');
const findAreaByName = (areas, name) => areas.find(item => item.name === name);
let provinceObj = findAreaByName(areaData, data.province_name);
let cityObj = provinceObj ? findAreaByName(provinceObj.children, data.city_name) : undefined;
let districtObj = cityObj ? findAreaByName(cityObj.children, data.district_name) : undefined;
let areaId = (districtObj || cityObj || provinceObj).id;
state.model = {
...state.model,
areaId,
areaName: [data.province_name, data.city_name, data.district_name].filter(Boolean).join(" "),
defaultStatus: false,
detailAddress: data.address,
mobile: data.mobile,
name: data.consignee,
};
}
});
</script>
+1 -1
View File
@@ -1,4 +1,4 @@
const files = import.meta.globEager('./*.js');
const files = import.meta.glob('./*.js', { eager: true });
let api = {};
Object.keys(files).forEach((key) => {
api = {
+1 -1
View File
@@ -13,7 +13,7 @@ const OrderApi = {
if (!(data.addressId > 0)) {
delete data2.addressId;
}
if (!(data.combinationActivityId) > 0) {
if (!(data.combinationActivityId > 0)) {
delete data2.combinationActivityId;
}
if (!(data.combinationHeadId > 0)) {
@@ -1,5 +1,7 @@
<!-- 顶部导航栏 - 单元格 -->
<template>
<view class="ss-flex ss-col-center">
<!-- 类型一: 文字 -->
<view
v-if="data.type === 'text'"
class="nav-title inline"
@@ -7,15 +9,17 @@
>
{{ data.text }}
</view>
<!-- 类型二: 图片 -->
<view
v-if="data.type === 'image'"
:style="[{ width: width }]"
class="menu-icon-wrap ss-flex ss-row-center ss-col-center"
@tap="sheep.$router.go(data.url)"
>
<image class="nav-image" :src="sheep.$url.cdn(data.src)" mode="aspectFit"></image>
<image class="nav-image" :src="sheep.$url.cdn(data.imgUrl)" mode="aspectFit"></image>
</view>
<view class="ss-flex-1" v-if="data.type == 'search'" :style="[{ width: width }]">
<!-- 类型三: 搜索框 -->
<view class="ss-flex-1" v-if="data.type === 'search'" :style="[{ width: width }]">
<s-search-block
:placeholder="data.placeholder || '搜索关键字'"
:radius="data.borderRadius"
@@ -1,7 +1,7 @@
<!-- 顶部导航栏 -->
<template>
<navbar
:alway="isAlway"
:alway="isAlways"
:back="false"
bg=""
:placeholder="isPlaceholder"
@@ -12,7 +12,7 @@
<template #item>
<view class="nav-box">
<view class="nav-icon" v-if="showLeftButton">
<view class="icon-box ss-flex" :class="{ 'inner-icon-box': data.mode == 'inner' }">
<view class="icon-box ss-flex" :class="{ 'inner-icon-box': data.styleType === 'inner' }">
<view class="icon-button icon-button-left ss-flex ss-row-center" @tap="onClickLeft">
<text class="sicon-back" v-if="hasHistory" />
<text class="sicon-home" v-else />
@@ -43,7 +43,7 @@
*
*
* @property {Number | String} alwaysShow = [0,1] - 是否常驻
* @property {Number | String} mode = [inner] - 是否沉浸式
* @property {Number | String} styleType = [inner] - 是否沉浸式
* @property {String | Number} type - 标题背景模式
* @property {String} color - 页面背景色
* @property {String} src - 页面背景图片
@@ -66,26 +66,27 @@
});
const hasHistory = sheep.$router.hasHistory();
const sticky = computed(() => {
if (props.data.mode == 'inner') {
if (props.data.alway) {
if (props.data.styleType === 'inner') {
if (props.data.alwaysShow) {
return false;
}
}
if (props.data.mode == 'normal') {
if (props.data.styleType === 'normal') {
return false;
}
});
const navList = computed(() => {
if (!props.data.list) return [];
// #ifdef MP
return props.data.list.mp;
return props.data.mapCells || [];
// #endif
return props.data.list.app;
return props.data.otherCells || [];
});
// 单元格大小
// 页面宽度
const windowWidth = sheep.$platform.device.windowWidth;
// 单元格宽度
const cell = computed(() => {
if (unref(navList).length) {
// 默认宽度为8个格子,微信公众号右上角有胶囊按钮所以是6个格子
let cell = (windowWidth - 90) / 8;
// #ifdef MP
cell = (windowWidth - 80 - unref(sheep.$platform.capsule).width) / 6;
@@ -102,28 +103,26 @@
};
return obj;
};
const isAlway = computed(() =>
props.data.mode === 'inner' ? Boolean(props.data.alwaysShow) : true,
const isAlways = computed(() =>
props.data.styleType === 'inner' ? Boolean(props.data.alwaysShow) : true,
);
const isOpacity = computed(() =>
props.data.mode === 'normal'
props.data.styleType === 'normal'
? false
: props.showLeftButton
? false
: props.data.mode === 'inner',
: props.data.styleType === 'inner',
);
const isPlaceholder = computed(() => props.data.mode === 'normal');
const isPlaceholder = computed(() => props.data.styleType === 'normal');
const bgStyles = computed(() => {
if (props.data.type) {
return {
background:
props.data.type == 'color'
? props.data.color
: `url(${sheep.$url.cdn(props.data.src)}) no-repeat top center / 100% 100%`,
};
}
return {
background:
props.data.bgType === 'img' && props.data.bgImg
? `url(${sheep.$url.cdn(props.data.bgImg)}) no-repeat top center / 100% 100%`
: props.data.bgColor
};
});
// 左侧按钮:返回上一页或首页
function onClickLeft() {
if (hasHistory) {
sheep.$router.back();
@@ -131,6 +130,7 @@
sheep.$router.go('/pages/index/index');
}
}
// 右侧按钮:打开快捷菜单
function onClickRight() {
showMenuTools();
}
@@ -27,8 +27,7 @@
:bottomRadius="data.borderRadiusBottom"
@click="
sheep.$router.go('/pages/goods/groupon', {
id: product.id,
activity_id: props.data.activityId,
id: props.data.activityId,
})
"
></s-goods-column>
@@ -54,8 +53,7 @@
:bottomRadius="data.borderRadiusBottom"
@click="
sheep.$router.go('/pages/goods/groupon', {
id: product.id,
activity_id: props.data.activityId,
id: props.data.activityId,
})
"
>
+6 -6
View File
@@ -4,7 +4,7 @@
:class="['theme-' + sys.mode, 'main-' + sys.theme, 'font-' + sys.fontSize]"
>
<view class="page-main" :style="[bgMain]">
<!-- 默认通用顶部导航栏 -->
<!-- 顶部导航栏-情况1:默认通用顶部导航栏 -->
<su-navbar
v-if="navbar === 'normal'"
:title="title"
@@ -16,21 +16,21 @@
:defaultSearch="defaultSearch"
/>
<!-- 装修组件导航栏-普通 -->
<!-- 顶部导航栏-情况2:装修组件导航栏-标准 -->
<s-custom-navbar
v-else-if="navbar === 'custom' && navbarMode === 'normal'"
:data="navbarStyle"
:showLeftButton="showLeftButton"
/>
<view class="page-body" :style="[bgBody]">
<!-- 沉浸式头部 -->
<!-- 顶部导航栏-情况3:沉浸式头部 -->
<su-inner-navbar v-if="navbar === 'inner'" :title="title" />
<view
v-if="navbar === 'inner'"
:style="[{ paddingTop: sheep.$platform.navbar + 'px' }]"
></view>
<!-- 装修组件导航栏-沉浸式 -->
<!-- 顶部导航栏-情况4:装修组件导航栏-沉浸式 -->
<s-custom-navbar v-if="navbar === 'custom' && navbarMode === 'inner'" :data="navbarStyle" :showLeftButton="showLeftButton" />
<!-- 页面内容插槽 -->
@@ -92,7 +92,7 @@
navbarStyle: {
type: Object,
default: () => ({
mode: '',
styleType: '',
type: '',
color: '',
src: '',
@@ -143,7 +143,7 @@
// 导航栏模式(因为有自定义导航栏 需要计算)
const navbarMode = computed(() => {
if (props.navbar === 'normal' || props.navbarStyle.mode === 'normal') {
if (props.navbar === 'normal' || props.navbarStyle.styleType === 'normal') {
return 'normal';
}
return 'inner';
@@ -201,4 +201,5 @@ export default {
getInfo,
getOpenid,
subscribeMessage,
checkUpdate
};
+1 -1
View File
@@ -130,7 +130,7 @@ const decryptSpm = (spm) => {
query = shareParamsArray[2].split(',');
shareParams.query = {
id: query[0],
activity_id: query[1],
activity_id: query[1], // TODO 芋艿:接入分享后,应该统一成 id 参数
};
break;
case '4':
+1 -1
View File
@@ -2,7 +2,7 @@ import { createPinia } from 'pinia';
import piniaPersist from 'pinia-plugin-persist-uni';
// 自动注入所有pinia模块
const files = import.meta.globEager('./*.js');
const files = import.meta.glob('./*.js', { eager: true });
const modules = {};
Object.keys(files).forEach((key) => {
modules[key.replace(/(.*\/)*([^.]+).*/gi, '$2')] = files[key].default;
+3 -3
View File
@@ -71,7 +71,7 @@ function append_thumbnail_params(url, params) {
if (!gravity && gravity != 'center') {
// 指定了裁剪区域
mode = 'mfit';
crop_str = '/crop,g_' + gravityFormat('aliyun', gravity) + ',w_' + width + ',h_' + height;
crop_str = '/crop,g_' + gravityFormatMap('aliyun', gravity) + ',w_' + width + ',h_' + height;
}
// 质量压缩
@@ -91,7 +91,7 @@ function append_thumbnail_params(url, params) {
// 指定了裁剪区域
mode_str = 'crop';
mode = 'fill';
crop_str = '/gravity/' + gravityFormat('qcloud', gravity);
crop_str = '/gravity/' + gravityFormatMap('qcloud', gravity);
}
// 质量压缩
@@ -121,7 +121,7 @@ function append_thumbnail_params(url, params) {
if (mode == 'fill' || (!gravity && gravity != 'center')) {
// 指定了裁剪区域,全部转为 mfit
mode = 'mfit';
crop_str = '/gravity/' + gravityFormat('qiniu', gravity) + '/crop/' + size;
crop_str = '/gravity/' + gravityFormatMap('qiniu', gravity) + '/crop/' + size;
}
// 质量压缩
if (quality > 0 && quality < 100) {