From 339c98899720865d0333e30841dd04a3501cfe18 Mon Sep 17 00:00:00 2001
From: xpz2018 <107107461@qq.com>
Date: Wed, 28 Apr 2021 09:43:25 +0800
Subject: [PATCH] no message
---
pages/agent/ability-item/index.js | 61 +++++++++++++++++++++++++++
pages/agent/ability-item/index.json | 8 ++++
pages/agent/ability-item/index.wxml | 42 ++++++++++++++++++
pages/agent/ability-item/index.wxss | 23 ++++++++++
pages/agent/ability-list/index.js | 55 ++----------------------
pages/agent/ability-list/index.json | 4 +-
pages/agent/ability-list/index.wxml | 8 +++-
pages/agent/ability-list/index.wxss | 2 +-
pages/agent/factory-detail/index.wxml | 4 +-
pages/home/factory-list/index.wxml | 2 +-
pages/htmls/banner/index.js | 1 +
11 files changed, 151 insertions(+), 59 deletions(-)
create mode 100644 pages/agent/ability-item/index.js
create mode 100644 pages/agent/ability-item/index.json
create mode 100644 pages/agent/ability-item/index.wxml
create mode 100644 pages/agent/ability-item/index.wxss
diff --git a/pages/agent/ability-item/index.js b/pages/agent/ability-item/index.js
new file mode 100644
index 0000000..3c96be9
--- /dev/null
+++ b/pages/agent/ability-item/index.js
@@ -0,0 +1,61 @@
+// pages/message/index.js
+const util = require('../../../utils/util')
+const app = getApp()
+
+Component({
+ options: {
+ addGlobalClass: true,
+ multipleSlots: true
+ },
+ properties: {
+ item: { type: Object, value: null }
+ },
+ data: {
+ cateIndex: 0
+ },
+ methods: {
+ lookItem: function (e) {
+ wx.navigateTo({ url: `/pages/agent/factory-detail/index?id=${this.data.item.paperMillId}`})
+ },
+ toAbilityRule: function (e) {
+ util.navigateTarget(this.data.item.redirectInfo)
+ },
+ unflodItem: function(){
+ this.setData({ ['item.fold']: !this.data.item.fold })
+ },
+ checkTag: function(e){
+ var cateIndex = -1
+ if(util.isEmpty(this.data.cateIndex)){
+ cateIndex = e.currentTarget.dataset.ck
+ } else if(this.data.cateIndex != e.currentTarget.dataset.ck){
+ cateIndex = e.currentTarget.dataset.ck
+ }
+ if(cateIndex >= 0){
+ this.setData({ cateIndex })
+ }
+ },
+ saleGood: function(e){
+ if (!app.userInfo) {
+ wx.navigateTo({ url: '/pages/login/index' })
+ return
+ }
+ if(!this.data.item.isOperations){
+ util.showToast('该纸厂已暂停接单,请联系相关负责人!')
+ return
+ }
+ if(util.isEmpty(this.data.cateIndex)){
+ util.showToast('请选择一个纸品')
+ return
+ }
+ if(util.isEmpty(this.data.item.paperCategoryList[this.data.cateIndex].unitPrice)){
+ util.showToast('该纸品暂无报价,无法卖货')
+ return
+ }
+ var categoryId = this.data.item.paperCategoryList[this.data.cateIndex].categoryId
+ var activityId = this.data.item.activityId
+ var unitPrice = this.data.item.paperCategoryList[this.data.item.cateIndex].unitPrice
+ wx.navigateTo({ url: `/pages/agent/appointment/index?id=${this.data.item.paperMillId}&categoryId=${categoryId}&activityId=${activityId}&unitPrice=${unitPrice}` })
+ }
+ }
+
+})
\ No newline at end of file
diff --git a/pages/agent/ability-item/index.json b/pages/agent/ability-item/index.json
new file mode 100644
index 0000000..097b430
--- /dev/null
+++ b/pages/agent/ability-item/index.json
@@ -0,0 +1,8 @@
+{
+ "component": true,
+ "usingComponents": {
+ "van-button": "/components/button/index",
+ "van-image": "/components/image/index",
+ "van-tag": "/components/tag/index"
+ }
+}
\ No newline at end of file
diff --git a/pages/agent/ability-item/index.wxml b/pages/agent/ability-item/index.wxml
new file mode 100644
index 0000000..9219ec9
--- /dev/null
+++ b/pages/agent/ability-item/index.wxml
@@ -0,0 +1,42 @@
+
+
+
+
+
+
+
+ {{item.activityName}}
+
+ {{item.name}}
+ 时间:{{formate.substring(item.startTime, 0, 10)}}至{{formate.substring(item.endTime, 0, 10)}}
+
+
+
+ 活动规则
+
+
+
+
+
+
+ {{cateItem.categoryName}}
+ {{formate.formatePrice(cateItem.unitPrice)}}元/吨
+ 暂无报价
+
+
+
+
+
+
+ 我要卖货
+
+
+
+ {{item.fold ? '点击收起' : '查看全部' }}({{item.paperCategoryList.length}})
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/pages/agent/ability-item/index.wxss b/pages/agent/ability-item/index.wxss
new file mode 100644
index 0000000..d39e71b
--- /dev/null
+++ b/pages/agent/ability-item/index.wxss
@@ -0,0 +1,23 @@
+/* pages/mall/shops/index.wxss */
+.item-content {
+ background: rgba(255, 255, 255, 1);
+ padding: 32rpx;
+}
+
+.item-cate {
+ flex: 5;
+ padding: 10rpx 30rpx;
+ border-radius: 10rpx;
+ border: 1rpx solid #f3f3f3;
+ background-color: #f3f3f3;
+}
+
+.cate-tag {
+ background-color: #e6f7ff;
+ border: 1rpx solid #1890ff;
+}
+
+.transform {
+ transform-origin: 50% 50%;
+ transform: rotate(180deg);
+}
diff --git a/pages/agent/ability-list/index.js b/pages/agent/ability-list/index.js
index 9183d9c..0881cea 100644
--- a/pages/agent/ability-list/index.js
+++ b/pages/agent/ability-list/index.js
@@ -1,66 +1,17 @@
-// pages/agent/ability-list/index.js
-Page({
+// pages/message/detail/index.js
+import Scene from '../../index/scene'
+Scene({
/**
* 页面的初始数据
*/
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/agent/ability-list/index.json b/pages/agent/ability-list/index.json
index 8835af0..19bbcd2 100644
--- a/pages/agent/ability-list/index.json
+++ b/pages/agent/ability-list/index.json
@@ -1,3 +1,5 @@
{
- "usingComponents": {}
+ "usingComponents": {
+ "notification": "/pages/message/notification/index"
+ }
}
\ No newline at end of file
diff --git a/pages/agent/ability-list/index.wxml b/pages/agent/ability-list/index.wxml
index c419e4a..79f99dd 100644
--- a/pages/agent/ability-list/index.wxml
+++ b/pages/agent/ability-list/index.wxml
@@ -1,2 +1,6 @@
-
-pages/agent/ability-list/index.wxml
+
+
+ 消息情况
+
+
+
diff --git a/pages/agent/ability-list/index.wxss b/pages/agent/ability-list/index.wxss
index 4ea6b85..f42776e 100644
--- a/pages/agent/ability-list/index.wxss
+++ b/pages/agent/ability-list/index.wxss
@@ -1 +1 @@
-/* pages/agent/ability-list/index.wxss */
\ No newline at end of file
+/* pages/message/detail/index.wxss */
\ No newline at end of file
diff --git a/pages/agent/factory-detail/index.wxml b/pages/agent/factory-detail/index.wxml
index 40be6ea..7153919 100644
--- a/pages/agent/factory-detail/index.wxml
+++ b/pages/agent/factory-detail/index.wxml
@@ -110,7 +110,7 @@
{{item.inspectionNote || '暂无信息'}}
-
+
@@ -141,7 +141,7 @@
{{factoryDetail.attentionsRegulations}}
-
+
diff --git a/pages/home/factory-list/index.wxml b/pages/home/factory-list/index.wxml
index 0447c35..67d326b 100644
--- a/pages/home/factory-list/index.wxml
+++ b/pages/home/factory-list/index.wxml
@@ -60,6 +60,6 @@
-
+
\ No newline at end of file
diff --git a/pages/htmls/banner/index.js b/pages/htmls/banner/index.js
index fd3bf13..215d464 100644
--- a/pages/htmls/banner/index.js
+++ b/pages/htmls/banner/index.js
@@ -23,6 +23,7 @@ Scene({
wx.showLoading({ title: '处理中', mask: true })
this.setData({
fheight: app.globalData.fragmentHeight,
+ height: app.globalData.fragmentHeight,
StatusBar: app.globalData.StatusBar || 40,
CustomBar: app.globalData.CustomBar || (app.globalData.isIos ? 64 : 60),
src: options.src