From 98859bff90b0e3b170819cbc3c8fa015fd37521d Mon Sep 17 00:00:00 2001 From: asd <374367073@qq.com> Date: Fri, 13 Dec 2019 11:59:11 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E8=B4=AD=E7=89=A9=E8=BD=A6=E5=AE=8C?= =?UTF-8?q?=E6=88=90?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app.json | 1 + .../shopping/shoppingitem/shoppingitem.js | 26 ++++++ .../shopping/shoppingitem/shoppingitem.json | 4 + .../shopping/shoppingitem/shoppingitem.wxml | 16 ++++ .../shopping/shoppingitem/shoppingitem.wxss | 85 +++++++++++++++++++ pages/shopping/shopping.js | 66 ++++++++++++++ pages/shopping/shopping.json | 7 ++ pages/shopping/shopping.wxml | 25 ++++++ pages/shopping/shopping.wxss | 48 +++++++++++ project.config.json | 2 +- 10 files changed, 279 insertions(+), 1 deletion(-) create mode 100644 components/shopping/shoppingitem/shoppingitem.js create mode 100644 components/shopping/shoppingitem/shoppingitem.json create mode 100644 components/shopping/shoppingitem/shoppingitem.wxml create mode 100644 components/shopping/shoppingitem/shoppingitem.wxss create mode 100644 pages/shopping/shopping.js create mode 100644 pages/shopping/shopping.json create mode 100644 pages/shopping/shopping.wxml create mode 100644 pages/shopping/shopping.wxss diff --git a/app.json b/app.json index 3429189..b708304 100644 --- a/app.json +++ b/app.json @@ -1,5 +1,6 @@ { "pages": [ + "pages/shopping/shopping", "pages/index/index", "pages/logs/logs" ], diff --git a/components/shopping/shoppingitem/shoppingitem.js b/components/shopping/shoppingitem/shoppingitem.js new file mode 100644 index 0000000..71165bf --- /dev/null +++ b/components/shopping/shoppingitem/shoppingitem.js @@ -0,0 +1,26 @@ +// components/shopping/shoppingitem/shoppingitem.js +Component({ + /** + * 组件的属性列表 + */ + properties: { + shospname: String, + shopdesc: String, + price: Number, + pic: String + }, + + /** + * 组件的初始数据 + */ + data: { + + }, + + /** + * 组件的方法列表 + */ + methods: { + + } +}) \ No newline at end of file diff --git a/components/shopping/shoppingitem/shoppingitem.json b/components/shopping/shoppingitem/shoppingitem.json new file mode 100644 index 0000000..e8cfaaf --- /dev/null +++ b/components/shopping/shoppingitem/shoppingitem.json @@ -0,0 +1,4 @@ +{ + "component": true, + "usingComponents": {} +} \ No newline at end of file diff --git a/components/shopping/shoppingitem/shoppingitem.wxml b/components/shopping/shoppingitem/shoppingitem.wxml new file mode 100644 index 0000000..c1f4a39 --- /dev/null +++ b/components/shopping/shoppingitem/shoppingitem.wxml @@ -0,0 +1,16 @@ + + + + + + + {{shopname}} + {{shopdesc}} + ${{price}} + + + + 5 + + + diff --git a/components/shopping/shoppingitem/shoppingitem.wxss b/components/shopping/shoppingitem/shoppingitem.wxss new file mode 100644 index 0000000..d30936f --- /dev/null +++ b/components/shopping/shoppingitem/shoppingitem.wxss @@ -0,0 +1,85 @@ +.shoppingitem { + width: 639rpx; + height: 186rpx; + display: flex; + justify-content: space-between; +} + +.select { + width: 26rpx; + height: 26rpx; + background: rgba(234, 234, 234, 1); + border-radius: 50%; + margin: auto 0; +} + +.pic { + /* width: 222rpx; + height: 222rpx; */ + width: 186rpx; + height: 186rpx; + background-color: bisque; +} + +.pic>image { + width: 100%; + height: 100%; +} + +.shopinfo { + width: 186rpx; +} + +.shopname { + color: #333333; + font-size: 26rpx; + font-weight: bold; + margin-bottom: 18rpx; + margin-top: 35rpx; +} + +.shopdesc { + color: #666666; + font-size: 22rpx; + margin-bottom: 39rpx; +} + +.price { + color: #D1D1D1; + font-size: 32rpx; + font-weight: bold; + text-decoration: underline; +} + +.numberset { + width: 85rpx; + height: 186rpx; + border: 1px solid rgba(233, 233, 233, 1); + border-radius: 10px; + margin-top: 11rpx; + display: flex; + flex-direction: column; + justify-content: space-between; +} + +.reverse { + width: 19rpx; + height: 3rpx; + background-color: #97DFB4; + margin: 0 auto; + margin-top: 25rpx; +} + +.num { + color: #242424; + font-size: 30rpx; + text-align: center; +} + +.add { + width: 23rpx; + height: 23rpx; + background-color: #242424; + margin: 0 auto; + margin-bottom: 17rpx; +} \ No newline at end of file diff --git a/pages/shopping/shopping.js b/pages/shopping/shopping.js new file mode 100644 index 0000000..0cfeec3 --- /dev/null +++ b/pages/shopping/shopping.js @@ -0,0 +1,66 @@ +// pages/shopping/shopping.js +Page({ + + /** + * 页面的初始数据 + */ + data: { + + }, + + /** + * 生命周期函数--监听页面加载 + */ + onLoad: function (options) { + + }, + + /** + * 生命周期函数--监听页面初次渲染完成 + */ + onReady: function () { + + }, + + /** + * 生命周期函数--监听页面显示 + */ + onShow: function () { + + }, + + /** + * 生命周期函数--监听页面隐藏 + */ + onHide: function () { + + }, + + /** + * 生命周期函数--监听页面卸载 + */ + onUnload: function () { + + }, + + /** + * 页面相关事件处理函数--监听用户下拉动作 + */ + onPullDownRefresh: function () { + + }, + + /** + * 页面上拉触底事件的处理函数 + */ + onReachBottom: function () { + + }, + + /** + * 用户点击右上角分享 + */ + onShareAppMessage: function () { + + } +}) \ No newline at end of file diff --git a/pages/shopping/shopping.json b/pages/shopping/shopping.json new file mode 100644 index 0000000..5b1908e --- /dev/null +++ b/pages/shopping/shopping.json @@ -0,0 +1,7 @@ +{ + + "usingComponents": { + "shopping-item":"/components/shopping/shoppingitem/shoppingitem" + } + +} \ No newline at end of file diff --git a/pages/shopping/shopping.wxml b/pages/shopping/shopping.wxml new file mode 100644 index 0000000..0b94649 --- /dev/null +++ b/pages/shopping/shopping.wxml @@ -0,0 +1,25 @@ + + + + + + + + + + + + + + + + + 全选 + $0.00 + + + 删除 + 结算 + + + \ No newline at end of file diff --git a/pages/shopping/shopping.wxss b/pages/shopping/shopping.wxss new file mode 100644 index 0000000..aeaf59c --- /dev/null +++ b/pages/shopping/shopping.wxss @@ -0,0 +1,48 @@ + .item { + height: 186rpx; + margin-left: 46rpx; + margin-top: 59rpx; + } + + .bottom { + width: 100%; + height: 98rpx; + position: fixed; + bottom: 0; + background: linear-gradient(2deg, rgba(250, 250, 250, 0.94), rgba(255, 255, 255, 0.94)); + display: flex; + justify-content: space-between; + font-size: 28rpx; + line-height: 98rpx; + } + + .left { + display: flex; + /* line-height: 26rpx; */ + } + + .select { + width: 26rpx; + height: 26rpx; + background: rgba(234, 234, 234, 1); + border-radius: 50%; + margin: auto 0; + margin-left: 46rpx; + margin-right: 24rpx; + } + + .pri { + color: #E0C79D; + font-size: 26rpx; + margin-left: 19rpx; + } + + .right { + color: #BBBBBB; + margin-right: 31rpx; + } + + .sub { + margin-left: 30rpx; + color: #4CC97D; + } \ No newline at end of file diff --git a/project.config.json b/project.config.json index 0f05f4f..bd2b7f8 100644 --- a/project.config.json +++ b/project.config.json @@ -16,7 +16,7 @@ }, "compileType": "miniprogram", "libVersion": "2.9.4", - "appid": "wx932dd04d3a7e7341", + "appid": "wx5766b7aac7c938b3", "projectname": "deguodaigou", "debugOptions": { "hidedInDevtools": [] -- 2.47.2 From eb1b3ef592c1ef12d5f1f0d29ed32b884699576f Mon Sep 17 00:00:00 2001 From: asd <374367073@qq.com> Date: Fri, 13 Dec 2019 12:00:07 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E8=B4=AD=E7=89=A9=E8=BD=A6?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/index/list/index.scss | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 components/index/list/index.scss diff --git a/components/index/list/index.scss b/components/index/list/index.scss new file mode 100644 index 0000000..aae32e5 --- /dev/null +++ b/components/index/list/index.scss @@ -0,0 +1,12 @@ +.list { + width: 623rpx; + margin-top: 36rpx; + .title { + font-size: 30rpx; + color: #333; + font-weight: bold; + margin-left: 32rpx; + // margin-bottom: 32rpx; + } + + } \ No newline at end of file -- 2.47.2