6.30 版本提交
This commit is contained in:
334
unpackage/dist/dev/mp-weixin/pages/invest/invest.js
vendored
Normal file
334
unpackage/dist/dev/mp-weixin/pages/invest/invest.js
vendored
Normal file
@@ -0,0 +1,334 @@
|
||||
"use strict";
|
||||
const common_vendor = require("../../common/vendor.js");
|
||||
const request_api = require("../../request/api.js");
|
||||
const common_assets = require("../../common/assets.js");
|
||||
const _sfc_main = {
|
||||
data() {
|
||||
return {
|
||||
menuTop: common_vendor.inject("menuTop"),
|
||||
menuH: common_vendor.inject("menuHeight"),
|
||||
navH: common_vendor.inject("navHeight"),
|
||||
windowWidth: common_vendor.inject("windowWidth"),
|
||||
contentTop: "",
|
||||
todayDate: "",
|
||||
//今日日期
|
||||
weekList: ["一", "二", "三", "四", "五", "六", "日"],
|
||||
weekDateList: [],
|
||||
//当前周日期
|
||||
monthDateList: [],
|
||||
//当前月日期
|
||||
isExpand: false,
|
||||
//是否展开日期
|
||||
tabList: ["事件", "数据"],
|
||||
selectTab: 0,
|
||||
topCategoryList: ["全部", "大周期", "大消费", "大金融地产", "TMT板块", "公共产业板块"],
|
||||
selectTopCategory: 0,
|
||||
listTop: "",
|
||||
selectDate: "",
|
||||
//选择查看的日期
|
||||
progress: 75,
|
||||
eventList: []
|
||||
//事件列表
|
||||
};
|
||||
},
|
||||
onLoad() {
|
||||
let date = /* @__PURE__ */ new Date();
|
||||
this.contentTop = this.navH + (75 + 20) / 750 * common_vendor.inject("windowWidth");
|
||||
let year = date.getFullYear();
|
||||
let month = date.getMonth() + 1;
|
||||
let day = date.getDate();
|
||||
this.selectDate = date.getFullYear() + "-" + (month > 9 ? month : "0" + month) + "-" + (day > 9 ? day : "0" + day);
|
||||
let week = date.getDay() || 7;
|
||||
let diff = week - 1;
|
||||
let daysOfWeek = [];
|
||||
for (var i = 0; i < 7; i++) {
|
||||
let newDate = /* @__PURE__ */ new Date();
|
||||
newDate.setDate(day - diff + i);
|
||||
let newDay = newDate.getDate();
|
||||
let date2 = year + "-" + (month > 9 ? month : "0" + month) + "-" + (newDay > 9 ? newDay : "0" + newDay);
|
||||
daysOfWeek.push({ date: date2, day: newDay, isToday: newDay == day ? true : false });
|
||||
}
|
||||
this.weekDateList = daysOfWeek;
|
||||
let firstDayOfMonth = /* @__PURE__ */ new Date();
|
||||
firstDayOfMonth.setDate(1);
|
||||
let currentMonthDay = new Date(year, month, 0).getDate();
|
||||
let firstDayWeek = firstDayOfMonth.getDay() || 7;
|
||||
let daysOfMonth = [];
|
||||
for (var i = 1; i <= currentMonthDay; i++) {
|
||||
let newDate = /* @__PURE__ */ new Date();
|
||||
newDate.setDate(i);
|
||||
let newDay = newDate.getDate();
|
||||
let date2 = year + "-" + (month > 9 ? month : "0" + month) + "-" + (newDay > 9 ? newDay : "0" + newDay);
|
||||
daysOfMonth.push({ date: date2, day: newDay, isToday: newDay == day ? true : false, isCurrentMonth: true });
|
||||
}
|
||||
for (var i = 0; i < firstDayWeek - 1; i++) {
|
||||
let lastMonthDay = new Date(year, month - 1, 0).getDate();
|
||||
let newDate = new Date(year, month - 2, lastMonthDay - i);
|
||||
let newMonth = newDate.getMonth() + 1;
|
||||
let newDay = newDate.getDate();
|
||||
let date2 = year + "-" + (newMonth > 9 ? newMonth : "0" + newMonth) + "-" + (newDay > 9 ? newDay : "0" + newDay);
|
||||
daysOfMonth.unshift({ date: date2, day: newDay, isToday: false, isCurrentMonth: false });
|
||||
}
|
||||
let nextMonthFirstDay = new Date(year, month, 1);
|
||||
let lastDayOfMonth = new Date(nextMonthFirstDay - 24 * 60 * 60 * 1e3);
|
||||
let lastDayWeek = lastDayOfMonth.getDay() || 7;
|
||||
for (var i = 1; i < 8 - lastDayWeek; i++) {
|
||||
if (month > 11) {
|
||||
month = -1;
|
||||
year++;
|
||||
}
|
||||
let newDate = new Date(year, month + 1, i);
|
||||
let newMonth = newDate.getMonth() + 1;
|
||||
let newDay = newDate.getDate();
|
||||
let date2 = year + "-" + (newMonth > 9 ? newMonth : "0" + newMonth) + "-" + (newDay > 9 ? newDay : "0" + newDay);
|
||||
daysOfMonth.push({ date: date2, day: newDay, isToday: false, isCurrentMonth: false });
|
||||
}
|
||||
this.monthDateList = daysOfMonth;
|
||||
this.listTop = this.contentTop + (68 + 40 + 96 + 74 + 70 + 74 + 22) / 750 * common_vendor.inject("windowWidth");
|
||||
this.getEventListData();
|
||||
this.getCurrentMonthEventCountData();
|
||||
},
|
||||
computed: {
|
||||
circumference() {
|
||||
return Math.PI * 100;
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 点击展开或收起
|
||||
*/
|
||||
clickExpandOrRetract() {
|
||||
this.isExpand = !this.isExpand;
|
||||
if (this.isExpand) {
|
||||
this.listTop = this.contentTop + (68 + 40 + 96 * 6 + 74 + 70 + 74 + 22) / 750 * this.windowWidth;
|
||||
} else
|
||||
this.listTop = this.contentTop + (68 + 40 + 96 + 74 + 70 + 74 + 22) / 750 * this.windowWidth;
|
||||
},
|
||||
/**
|
||||
* 选中日期
|
||||
* @param {Object} item
|
||||
*/
|
||||
clickSelectDate(item) {
|
||||
if (this.selectDate != item.date) {
|
||||
this.selectDate = item.date;
|
||||
this.getEventListData();
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 点击切换事件或者数据
|
||||
*/
|
||||
clickTabItem(index) {
|
||||
if (this.selectTab != index) {
|
||||
this.selectTab = index;
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 选择一级分类
|
||||
*/
|
||||
clickTopCategoryItem(index) {
|
||||
if (this.selectTopCategory != index) {
|
||||
this.selectTopCategory = index;
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 点击查看事件详情
|
||||
*/
|
||||
clickEventItem() {
|
||||
common_vendor.index.navigateTo({
|
||||
url: "/pages/invest/investDetails/investDetails"
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 获取事件列表数据
|
||||
*/
|
||||
getEventListData() {
|
||||
let param = { date: this.selectDate };
|
||||
request_api.calendarEventList(param).then((res) => {
|
||||
for (let item of res) {
|
||||
let calendarTime = item.calendar_time;
|
||||
let time = calendarTime.split("T")[1];
|
||||
item.time = time.substr(0, 5);
|
||||
}
|
||||
this.eventList = res;
|
||||
}).catch((error) => {
|
||||
});
|
||||
},
|
||||
/**
|
||||
* 获取当前月份每一天的事件数量
|
||||
*/
|
||||
getCurrentMonthEventCountData() {
|
||||
request_api.calendarEventCount().then((res) => {
|
||||
for (let item of res) {
|
||||
let date = item.start;
|
||||
for (let s of this.weekDateList) {
|
||||
if (s.date == date) {
|
||||
s.eventCount = item.title;
|
||||
s.className = item.className;
|
||||
}
|
||||
}
|
||||
for (let s of this.monthDateList) {
|
||||
if (s.date == date) {
|
||||
s.eventCount = item.title;
|
||||
s.className = item.className;
|
||||
}
|
||||
}
|
||||
}
|
||||
}).catch((error) => {
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
if (!Array) {
|
||||
const _easycom_zui_progress_circle2 = common_vendor.resolveComponent("zui-progress-circle");
|
||||
_easycom_zui_progress_circle2();
|
||||
}
|
||||
const _easycom_zui_progress_circle = () => "../../uni_modules/zui-progress-circle/components/zui-progress-circle/zui-progress-circle.js";
|
||||
if (!Math) {
|
||||
_easycom_zui_progress_circle();
|
||||
}
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return common_vendor.e({
|
||||
a: common_assets._imports_0,
|
||||
b: common_vendor.s("top:" + $data.menuTop + "px;line-height:" + $data.menuH + "px;"),
|
||||
c: common_assets._imports_1,
|
||||
d: common_vendor.s("top:" + $data.navH + "px;"),
|
||||
e: common_vendor.t($data.selectDate),
|
||||
f: common_assets._imports_2$3,
|
||||
g: common_vendor.o(($event) => $options.clickExpandOrRetract()),
|
||||
h: common_vendor.f($data.weekList, (item, index, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(item),
|
||||
b: index
|
||||
};
|
||||
}),
|
||||
i: $data.isExpand
|
||||
}, $data.isExpand ? {
|
||||
j: common_vendor.f($data.monthDateList, (item, index, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(item.day),
|
||||
b: common_vendor.n("date " + (item.isToday ? "today" : item.isCurrentMonth ? "" : " notCurrentMonth")),
|
||||
c: item.className
|
||||
}, item.className ? common_vendor.e({
|
||||
d: item.className == "bg-gradient-danger"
|
||||
}, item.className == "bg-gradient-danger" ? {
|
||||
e: common_vendor.t(item.eventCount)
|
||||
} : {}, {
|
||||
f: item.className == "bg-gradient-warning"
|
||||
}, item.className == "bg-gradient-warning" ? {
|
||||
g: common_vendor.t(item.eventCount)
|
||||
} : {}, {
|
||||
h: item.className == "bg-gradient-info"
|
||||
}, item.className == "bg-gradient-info" ? {
|
||||
i: common_vendor.t(item.eventCount)
|
||||
} : {}, {
|
||||
j: item.className == "bg-gradient-success"
|
||||
}, item.className == "bg-gradient-success" ? {
|
||||
k: common_vendor.t(item.eventCount)
|
||||
} : {}) : {}, {
|
||||
l: index,
|
||||
m: common_vendor.o(($event) => $options.clickSelectDate(item), index)
|
||||
});
|
||||
})
|
||||
} : {
|
||||
k: common_vendor.f($data.weekDateList, (item, index, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(item.day),
|
||||
b: common_vendor.n("date " + (item.isToday ? "today" : "")),
|
||||
c: item.className
|
||||
}, item.className ? common_vendor.e({
|
||||
d: item.className == "bg-gradient-danger"
|
||||
}, item.className == "bg-gradient-danger" ? {
|
||||
e: common_vendor.t(item.eventCount)
|
||||
} : {}, {
|
||||
f: item.className == "bg-gradient-warning"
|
||||
}, item.className == "bg-gradient-warning" ? {
|
||||
g: common_vendor.t(item.eventCount)
|
||||
} : {}, {
|
||||
h: item.className == "bg-gradient-info"
|
||||
}, item.className == "bg-gradient-info" ? {
|
||||
i: common_vendor.t(item.eventCount)
|
||||
} : {}, {
|
||||
j: item.className == "bg-gradient-success"
|
||||
}, item.className == "bg-gradient-success" ? {
|
||||
k: common_vendor.t(item.eventCount)
|
||||
} : {}) : {}, {
|
||||
l: common_vendor.o(($event) => $options.clickSelectDate(item), index),
|
||||
m: index
|
||||
});
|
||||
})
|
||||
}, {
|
||||
l: common_vendor.t($data.isExpand ? "收起" : "展开"),
|
||||
m: common_assets._imports_3$2,
|
||||
n: common_vendor.o(($event) => $options.clickExpandOrRetract()),
|
||||
o: common_vendor.f($data.tabList, (item, index, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(item),
|
||||
b: common_vendor.n("item " + ($data.selectTab == index ? "select" : "")),
|
||||
c: index,
|
||||
d: common_vendor.o(($event) => $options.clickTabItem(index), index)
|
||||
};
|
||||
}),
|
||||
p: common_vendor.f($data.topCategoryList, (item, index, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(item),
|
||||
b: $data.selectTopCategory == index
|
||||
}, $data.selectTopCategory == index ? {} : {}, {
|
||||
c: common_vendor.n("item relative " + ($data.selectTopCategory == index ? "select" : "")),
|
||||
d: index,
|
||||
e: common_vendor.o(($event) => $options.clickTopCategoryItem(index), index)
|
||||
});
|
||||
}),
|
||||
q: $data.selectTab == 0
|
||||
}, $data.selectTab == 0 ? {
|
||||
r: common_vendor.f($data.eventList, (item, index, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(item.time),
|
||||
b: common_vendor.f(5, (sitem, sindex, i1) => {
|
||||
return {
|
||||
a: sindex < item.star ? "/static/icon/invest/star_s.png" : "/static/icon/invest/star.png"
|
||||
};
|
||||
}),
|
||||
c: index,
|
||||
d: common_vendor.t(item.title),
|
||||
e: common_vendor.t(item.forecast),
|
||||
f: common_vendor.f(JSON.parse(item.concepts), (citem, cindex, i1) => {
|
||||
return {
|
||||
a: common_vendor.t(citem[0]),
|
||||
b: common_vendor.t(citem[2] * 100),
|
||||
c: "2cf1ca64-0-" + i0 + "-" + i1,
|
||||
d: common_vendor.p({
|
||||
position: citem[2],
|
||||
range: [270, 630],
|
||||
size: 26,
|
||||
["ring-width"]: 2,
|
||||
texture: ["#F97316", "#E3E3E3"]
|
||||
}),
|
||||
e: cindex
|
||||
};
|
||||
}),
|
||||
g: index,
|
||||
h: common_vendor.o(($event) => $options.clickEventItem(), index)
|
||||
};
|
||||
})
|
||||
} : {}, {
|
||||
s: $data.selectTab == 1
|
||||
}, $data.selectTab == 1 ? {
|
||||
t: common_vendor.f(5, (item, index, i0) => {
|
||||
return {
|
||||
a: index
|
||||
};
|
||||
}),
|
||||
v: common_assets._imports_4$1,
|
||||
w: common_vendor.f(5, (item, index, i0) => {
|
||||
return {
|
||||
a: index
|
||||
};
|
||||
}),
|
||||
x: common_assets._imports_5$1
|
||||
} : {}, {
|
||||
y: common_vendor.s("top:" + $data.contentTop + "px;")
|
||||
});
|
||||
}
|
||||
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
|
||||
wx.createPage(MiniProgramPage);
|
||||
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/invest/invest.js.map
|
||||
6
unpackage/dist/dev/mp-weixin/pages/invest/invest.json
vendored
Normal file
6
unpackage/dist/dev/mp-weixin/pages/invest/invest.json
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"navigationBarTitleText": "",
|
||||
"usingComponents": {
|
||||
"zui-progress-circle": "../../uni_modules/zui-progress-circle/components/zui-progress-circle/zui-progress-circle"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/dev/mp-weixin/pages/invest/invest.wxml
vendored
Normal file
1
unpackage/dist/dev/mp-weixin/pages/invest/invest.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view><image class="topBg absolute" src="{{a}}" mode="widthFix"></image><view class="navTitle fixed" style="{{b}}">投资</view><view class="searchC fixed flex" style="{{d}}"><image class="icon" src="{{c}}" mode="widthFix"></image><input class="flex1" type="text" placeholder="搜索话题/股票名称" placeholder-style="color:#94989A"/><view class="line"></view><view class="search">搜索</view></view><view class="contentC fixed" style="{{y}}"><view class=""><view class="todayC flex" bindtap="{{g}}"><view class="todayDateC flex"><view class="date">{{e}}</view><image class="icon" src="{{f}}" mode="widthFix"></image></view><view class="flex1"></view><view class="today">今</view></view><view class="weekList flex"><view wx:for="{{h}}" wx:for-item="item" wx:key="b" class="item flex1">{{item.a}}</view></view><view wx:if="{{i}}" class="monthDateList flexWrap"><view wx:for="{{j}}" wx:for-item="item" wx:key="l" class="item flexColumnCenter" bindtap="{{item.m}}"><view class="{{item.b}}">{{item.a}}</view><block wx:if="{{item.c}}"><view wx:if="{{item.d}}" class="eventNum danger">{{item.e}}</view><view wx:if="{{item.f}}" class="eventNum warning">{{item.g}}</view><view wx:if="{{item.h}}" class="eventNum info">{{item.i}}</view><view wx:if="{{item.j}}" class="eventNum success">{{item.k}}</view></block><block wx:else><view class="eventNum"></view></block></view></view><view wx:else class="weekDateList flex"><view wx:for="{{k}}" wx:for-item="item" wx:key="m" class="item flex1 flexColumnCenter" bindtap="{{item.l}}"><view class="{{item.b}}">{{item.a}}</view><block wx:if="{{item.c}}"><view wx:if="{{item.d}}" class="eventNum danger">{{item.e}}</view><view wx:if="{{item.f}}" class="eventNum warning">{{item.g}}</view><view wx:if="{{item.h}}" class="eventNum info">{{item.i}}</view><view wx:if="{{item.j}}" class="eventNum success">{{item.k}}</view></block><block wx:else><view class="eventNum"></view></block></view></view><view class="expandBgC flexCenter"><view class="expandC flex" bindtap="{{n}}"><text>{{l}}</text><image class="arrow" src="{{m}}" mode="widthFix"></image></view></view></view><view class="tabC"><view wx:for="{{o}}" wx:for-item="item" wx:key="c" class="{{item.b}}" bindtap="{{item.d}}">{{item.a}}</view></view><scroll-view scroll-x class="topCategoryC"><view wx:for="{{p}}" wx:for-item="item" wx:key="d" class="{{item.c}}" bindtap="{{item.e}}">{{item.a}} <view wx:if="{{item.b}}" class="line absolute"></view></view></scroll-view><view wx:if="{{q}}" class="eventList"><view wx:for="{{r}}" wx:for-item="item" wx:key="g" class="item" bindtap="{{item.h}}"><view class="flex"><view class="time flex1">{{item.a}}</view><view class="starC relative"><view class="starList flex"><image wx:for="{{item.b}}" wx:for-item="sitem" wx:key="c" class="icon" src="{{sitem.a}}" mode="widthFix"></image></view></view></view><view class="categoryTitleC flex"><view class="category">宏观政策</view><view class="title flex1">{{item.d}}</view></view><view class="labelC"><view class="label"></view></view><view class="content"><text>{{item.e}}</text></view><scroll-view scroll-x class="percentList"><view wx:for="{{item.f}}" wx:for-item="citem" wx:key="e" class="percentItem">{{citem.a}} <zui-progress-circle wx:if="{{citem.d}}" u-s="{{['d']}}" u-i="{{citem.c}}" bind:__l="__l" u-p="{{citem.d}}"><view class="num">{{citem.b}}%</view></zui-progress-circle></view></scroll-view></view></view><view wx:if="{{s}}" class="dataList"><view class="item"><view class="flex"><view class="time flex1">21:00</view><view class="starC relative"><view class="starBgList flex"><image wx:for="{{t}}" wx:for-item="item" wx:key="a" class="icon" src="{{v}}" mode="widthFix"></image></view><view class="starList absolute flex"><image wx:for="{{w}}" wx:for-item="item" wx:key="a" class="icon" src="{{x}}" mode="widthFix"></image></view></view></view><view class="title">外交部长王毅将对俄罗斯进行正式访问。</view><view class="valueList flex between"><view class="pre">前值 -7.1</view><view class="prediction">预测 93</view><view class="actual">实际 ————</view></view></view></view></view></view>
|
||||
331
unpackage/dist/dev/mp-weixin/pages/invest/invest.wxss
vendored
Normal file
331
unpackage/dist/dev/mp-weixin/pages/invest/invest.wxss
vendored
Normal file
@@ -0,0 +1,331 @@
|
||||
.topBg {
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
.navTitle {
|
||||
left: 0;
|
||||
margin: 0 23rpx;
|
||||
font-size: 36rpx;
|
||||
font-weight: bold;
|
||||
color: white;
|
||||
}
|
||||
.searchC {
|
||||
background-color: white;
|
||||
left: 0;
|
||||
right: 0;
|
||||
margin: 20rpx 25rpx 0;
|
||||
padding: 0 20rpx;
|
||||
height: 75rpx;
|
||||
border-radius: 20rpx;
|
||||
font-size: 26rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
.searchC .icon {
|
||||
margin-right: 16rpx;
|
||||
width: 30rpx;
|
||||
height: auto;
|
||||
}
|
||||
.searchC input {
|
||||
height: 100%;
|
||||
}
|
||||
.searchC .line {
|
||||
background-color: #E1E1E1;
|
||||
width: 1rpx;
|
||||
height: 40rpx;
|
||||
}
|
||||
.searchC .search {
|
||||
padding: 0 25rpx;
|
||||
color: #F97316;
|
||||
}
|
||||
.contentC {
|
||||
background-color: white;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: calc(55px + env(safe-area-inset-bottom));
|
||||
margin-top: 22rpx;
|
||||
border-radius: 20rpx 20rpx 0 0;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
.contentC .todayC {
|
||||
padding: 12rpx 26rpx;
|
||||
}
|
||||
.contentC .todayC .todayDateC {
|
||||
font-size: 32rpx;
|
||||
font-weight: bold;
|
||||
color: #222;
|
||||
}
|
||||
.contentC .todayC .todayDateC .icon {
|
||||
margin-left: 16rpx;
|
||||
width: 30rpx;
|
||||
height: auto;
|
||||
}
|
||||
.contentC .todayC .today {
|
||||
background-color: #F973161A;
|
||||
width: 40rpx;
|
||||
line-height: 40rpx;
|
||||
border-radius: 50%;
|
||||
font-size: 26rpx;
|
||||
font-weight: 500;
|
||||
color: #F97316;
|
||||
text-align: center;
|
||||
}
|
||||
.contentC .weekList .item {
|
||||
line-height: 40rpx;
|
||||
font-size: 24rpx;
|
||||
color: #292621;
|
||||
text-align: center;
|
||||
}
|
||||
.contentC .weekDateList .item {
|
||||
padding-top: 14rpx;
|
||||
}
|
||||
.contentC .weekDateList .item .date {
|
||||
width: 40rpx;
|
||||
line-height: 40rpx;
|
||||
font-size: 24rpx;
|
||||
text-align: center;
|
||||
}
|
||||
.contentC .weekDateList .item .date.today {
|
||||
background-color: #F9731626;
|
||||
border-radius: 5rpx;
|
||||
color: #F97316;
|
||||
}
|
||||
.contentC .weekDateList .item .eventNum {
|
||||
margin-top: 12rpx;
|
||||
width: 80rpx;
|
||||
height: 30rpx;
|
||||
line-height: 30rpx;
|
||||
border-radius: 5rpx;
|
||||
font-size: 16rpx;
|
||||
font-weight: 500;
|
||||
color: white;
|
||||
text-align: center;
|
||||
}
|
||||
.contentC .weekDateList .item .eventNum.danger {
|
||||
background-color: #EB4A46;
|
||||
}
|
||||
.contentC .weekDateList .item .eventNum.warning {
|
||||
background-color: #FD9C16;
|
||||
}
|
||||
.contentC .weekDateList .item .eventNum.info {
|
||||
background-color: #16BBCF;
|
||||
}
|
||||
.contentC .weekDateList .item .eventNum.success {
|
||||
background-color: #55AE59;
|
||||
}
|
||||
.contentC .monthDateList .item {
|
||||
padding-top: 14rpx;
|
||||
width: calc(100%/7);
|
||||
}
|
||||
.contentC .monthDateList .item .date {
|
||||
width: 40rpx;
|
||||
line-height: 40rpx;
|
||||
font-size: 24rpx;
|
||||
font-weight: bold;
|
||||
color: #292621;
|
||||
text-align: center;
|
||||
}
|
||||
.contentC .monthDateList .item .date.today {
|
||||
background-color: #F9731626;
|
||||
border-radius: 5rpx;
|
||||
color: #F97316;
|
||||
}
|
||||
.contentC .monthDateList .item .date.notCurrentMonth {
|
||||
color: #999;
|
||||
}
|
||||
.contentC .monthDateList .item .eventNum {
|
||||
margin-top: 12rpx;
|
||||
width: 80rpx;
|
||||
height: 30rpx;
|
||||
line-height: 30rpx;
|
||||
border-radius: 5rpx;
|
||||
font-size: 16rpx;
|
||||
font-weight: 500;
|
||||
color: white;
|
||||
text-align: center;
|
||||
}
|
||||
.contentC .monthDateList .item .eventNum.danger {
|
||||
background-color: #EB4A46;
|
||||
}
|
||||
.contentC .monthDateList .item .eventNum.warning {
|
||||
background-color: #FD9C16;
|
||||
}
|
||||
.contentC .monthDateList .item .eventNum.info {
|
||||
background-color: #16BBCF;
|
||||
}
|
||||
.contentC .monthDateList .item .eventNum.success {
|
||||
background-color: #55AE59;
|
||||
}
|
||||
.contentC .expandBgC {
|
||||
margin: 0 25rpx;
|
||||
border-bottom: solid 1rpx #E4E4E4;
|
||||
}
|
||||
.contentC .expandBgC .expandC {
|
||||
padding: 20rpx 0;
|
||||
font-size: 22rpx;
|
||||
font-weight: 500;
|
||||
color: #8A857C;
|
||||
}
|
||||
.contentC .expandBgC .expandC .arrow {
|
||||
margin-left: 7rpx;
|
||||
width: 15rpx;
|
||||
height: auto;
|
||||
}
|
||||
.contentC .tabC .item {
|
||||
display: inline-block;
|
||||
padding: 0 24rpx;
|
||||
line-height: 70rpx;
|
||||
font-size: 32rpx;
|
||||
color: #42485B;
|
||||
}
|
||||
.contentC .tabC .item.select {
|
||||
color: #F97316;
|
||||
}
|
||||
.contentC .topCategoryC {
|
||||
white-space: nowrap;
|
||||
border-bottom: solid 1rpx #E4E4E4;
|
||||
}
|
||||
.contentC .topCategoryC .item {
|
||||
display: inline-block;
|
||||
line-height: 72rpx;
|
||||
padding: 0 28rpx;
|
||||
font-size: 27rpx;
|
||||
font-weight: 500;
|
||||
color: #42485B;
|
||||
}
|
||||
.contentC .topCategoryC .item.select {
|
||||
font-weight: bold;
|
||||
color: black;
|
||||
}
|
||||
.contentC .topCategoryC .item.select .line {
|
||||
background-color: #F97316;
|
||||
left: calc((100% - 50rpx)/2);
|
||||
width: 50rpx;
|
||||
height: 2rpx;
|
||||
bottom: 0;
|
||||
}
|
||||
.eventList {
|
||||
padding: 0 25rpx;
|
||||
}
|
||||
.eventList .item {
|
||||
padding: 30rpx 0;
|
||||
border-bottom: solid 1rpx #E4E4E4;
|
||||
}
|
||||
.eventList .item .time {
|
||||
font-size: 24rpx;
|
||||
font-weight: bold;
|
||||
color: #767676;
|
||||
}
|
||||
.eventList .item .starC .starList {
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
.eventList .item .starC .icon {
|
||||
margin-right: 9rpx;
|
||||
width: 27rpx;
|
||||
height: auto;
|
||||
}
|
||||
.eventList .item .categoryTitleC {
|
||||
margin-top: 18rpx;
|
||||
}
|
||||
.eventList .item .categoryTitleC .category {
|
||||
background-color: #FD9A14;
|
||||
margin-right: 10rpx;
|
||||
padding: 0 12rpx;
|
||||
line-height: 40rpx;
|
||||
border-radius: 8rpx;
|
||||
font-size: 22rpx;
|
||||
font-weight: bold;
|
||||
color: white;
|
||||
}
|
||||
.eventList .item .categoryTitleC .title {
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
font-size: 30rpx;
|
||||
font-weight: bold;
|
||||
color: #222;
|
||||
}
|
||||
.eventList .item .labelC {
|
||||
display: inline-block;
|
||||
}
|
||||
.eventList .item .labelC .label {
|
||||
border-radius: 5rpx;
|
||||
}
|
||||
.eventList .item .content {
|
||||
display: -webkit-box;
|
||||
-webkit-box-orient: vertical;
|
||||
-webkit-line-clamp: 3;
|
||||
text-overflow: ellipsis;
|
||||
overflow: hidden;
|
||||
font-size: 24rpx;
|
||||
font-weight: 500;
|
||||
color: #666;
|
||||
}
|
||||
.eventList .item .percentList {
|
||||
white-space: nowrap;
|
||||
margin-top: 20rpx;
|
||||
}
|
||||
.eventList .item .percentList .percentItem {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
background-color: #F8F8F8;
|
||||
margin-right: 20rpx;
|
||||
padding: 0 20rpx;
|
||||
height: 70rpx;
|
||||
border-radius: 10rpx;
|
||||
font-size: 26rpx;
|
||||
font-weight: bold;
|
||||
color: #222;
|
||||
}
|
||||
.eventList .item .percentList .percentItem zui-progress-circle {
|
||||
margin-left: 20rpx;
|
||||
}
|
||||
.eventList .item .percentList .percentItem .num {
|
||||
width: 23px;
|
||||
line-height: 23px;
|
||||
font-size: 17rpx;
|
||||
font-weight: bold;
|
||||
color: #999;
|
||||
text-align: center;
|
||||
}
|
||||
.eventList .item .percentList .percentItem:last-child {
|
||||
margin-right: 0;
|
||||
}
|
||||
.dataList {
|
||||
padding: 0 25rpx;
|
||||
}
|
||||
.dataList .item {
|
||||
padding: 30rpx 0;
|
||||
border-bottom: solid 1rpx #E4E4E4;
|
||||
}
|
||||
.dataList .item .time {
|
||||
font-size: 24rpx;
|
||||
font-weight: bold;
|
||||
color: #767676;
|
||||
}
|
||||
.dataList .item .starC .starList {
|
||||
top: 0;
|
||||
left: 0;
|
||||
}
|
||||
.dataList .item .starC .icon {
|
||||
margin-right: 9rpx;
|
||||
width: 27rpx;
|
||||
height: auto;
|
||||
}
|
||||
.dataList .item .title {
|
||||
margin-top: 16rpx;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
font-size: 30rpx;
|
||||
font-weight: bold;
|
||||
color: #222;
|
||||
}
|
||||
.dataList .item .valueList {
|
||||
margin-top: 20rpx;
|
||||
font-size: 26rpx;
|
||||
font-weight: 500;
|
||||
color: #666;
|
||||
}
|
||||
107
unpackage/dist/dev/mp-weixin/pages/invest/investDetails/investDetails.js
vendored
Normal file
107
unpackage/dist/dev/mp-weixin/pages/invest/investDetails/investDetails.js
vendored
Normal file
@@ -0,0 +1,107 @@
|
||||
"use strict";
|
||||
const common_vendor = require("../../../common/vendor.js");
|
||||
const request_api = require("../../../request/api.js");
|
||||
const common_assets = require("../../../common/assets.js");
|
||||
const _sfc_main = {
|
||||
data() {
|
||||
return {
|
||||
navH: common_vendor.inject("navHeight"),
|
||||
eventId: "",
|
||||
//事件id
|
||||
contentTop: "",
|
||||
categoryList: ["背景", "推演", "实际", "相关股票", "相关概念"],
|
||||
selectCategory: 0,
|
||||
stockCategoryList: [
|
||||
{
|
||||
title: "全部股票",
|
||||
bgColor: "#C00000",
|
||||
color: "white"
|
||||
},
|
||||
{
|
||||
title: "大周期",
|
||||
bgColor: "#305496",
|
||||
color: "white"
|
||||
},
|
||||
{
|
||||
title: "TMT板块",
|
||||
bgColor: "#FFBF00",
|
||||
color: "white"
|
||||
},
|
||||
{
|
||||
title: "大金融地产",
|
||||
bgColor: "#FFF4D3"
|
||||
},
|
||||
{
|
||||
title: "大消费",
|
||||
bgColor: "#CDEEEE"
|
||||
},
|
||||
{
|
||||
title: "公共产业板块",
|
||||
bgColor: "#DEEBF7"
|
||||
}
|
||||
]
|
||||
};
|
||||
},
|
||||
onLoad() {
|
||||
this.contentTop = this.navH + (30 + 74) / 750 * common_vendor.inject("windowWidth");
|
||||
},
|
||||
methods: {
|
||||
/**
|
||||
* 点击切换栏目
|
||||
*/
|
||||
clickCategoryItem(index) {
|
||||
if (this.selectCategory != index) {
|
||||
this.selectCategory = index;
|
||||
}
|
||||
},
|
||||
/**
|
||||
* 获取事件详情数据
|
||||
*/
|
||||
getEventDetailsData() {
|
||||
request_api.investEventDetails(this.eventId).then((res) => {
|
||||
}).catch((error) => {
|
||||
});
|
||||
}
|
||||
}
|
||||
};
|
||||
if (!Array) {
|
||||
const _easycom_navBar2 = common_vendor.resolveComponent("navBar");
|
||||
_easycom_navBar2();
|
||||
}
|
||||
const _easycom_navBar = () => "../../../components/navBar/navBar.js";
|
||||
if (!Math) {
|
||||
_easycom_navBar();
|
||||
}
|
||||
function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.p({
|
||||
leftText: "详情"
|
||||
}),
|
||||
b: common_assets._imports_0,
|
||||
c: common_vendor.f($data.categoryList, (item, index, i0) => {
|
||||
return common_vendor.e({
|
||||
a: common_vendor.t(item),
|
||||
b: $data.selectCategory == index
|
||||
}, $data.selectCategory == index ? {} : {}, {
|
||||
c: common_vendor.n("item relative " + ($data.selectCategory == index ? "select" : "")),
|
||||
d: index,
|
||||
e: common_vendor.o(($event) => $options.clickCategoryItem(index), index)
|
||||
});
|
||||
}),
|
||||
d: common_vendor.s("top:" + $data.navH + "px;"),
|
||||
e: $data.selectCategory == 3
|
||||
}, $data.selectCategory == 3 ? {
|
||||
f: common_vendor.f($data.stockCategoryList, (item, index, i0) => {
|
||||
return {
|
||||
a: common_vendor.t(item.title),
|
||||
b: common_vendor.s("background-color:" + item.bgColor + ";color:" + item.color + ";"),
|
||||
c: index
|
||||
};
|
||||
})
|
||||
} : {}, {
|
||||
g: common_vendor.s("top:" + $data.contentTop + "px;")
|
||||
});
|
||||
}
|
||||
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["render", _sfc_render]]);
|
||||
wx.createPage(MiniProgramPage);
|
||||
//# sourceMappingURL=../../../../.sourcemap/mp-weixin/pages/invest/investDetails/investDetails.js.map
|
||||
6
unpackage/dist/dev/mp-weixin/pages/invest/investDetails/investDetails.json
vendored
Normal file
6
unpackage/dist/dev/mp-weixin/pages/invest/investDetails/investDetails.json
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
{
|
||||
"navigationBarTitleText": "",
|
||||
"usingComponents": {
|
||||
"nav-bar": "../../../components/navBar/navBar"
|
||||
}
|
||||
}
|
||||
1
unpackage/dist/dev/mp-weixin/pages/invest/investDetails/investDetails.wxml
vendored
Normal file
1
unpackage/dist/dev/mp-weixin/pages/invest/investDetails/investDetails.wxml
vendored
Normal file
@@ -0,0 +1 @@
|
||||
<view><nav-bar wx:if="{{a}}" u-i="b7e6c0fc-0" bind:__l="__l" u-p="{{a}}"></nav-bar><image class="topBg absolute" src="{{b}}" mode="widthFix"></image><view class="categoryC fixed" style="{{d}}"><view wx:for="{{c}}" wx:for-item="item" wx:key="d" class="{{item.c}}" bindtap="{{item.e}}">{{item.a}} <view wx:if="{{item.b}}" class="line absolute"></view></view></view><view class="contentC fixed" style="{{g}}"><view wx:if="{{e}}" class="stockC"><view class="stockCategoryList flexWrap"><view wx:for="{{f}}" wx:for-item="item" wx:key="c" class="item flexColumnCenter" style="{{item.b}}"><view class="num">23</view><view class="title">{{item.a}}</view></view></view><view class="stockList"><view class="item"><view class="titleCorrelationC flex"><view class="title flex1">000065.SZ 北方国际</view><view class="correlation">相关度: 98%</view></view><view class="category">石油石化</view><view class="content"> 海外订单占比70%-80%,在俄语区矿产资源开发(蒙古矿山)、电力运营经验丰富,是乌克兰重建核心受益标的。公司在俄语区的深厚积累使其直接获益于区域经济复苏和能源合作深化。 </view></view></view></view></view></view>
|
||||
96
unpackage/dist/dev/mp-weixin/pages/invest/investDetails/investDetails.wxss
vendored
Normal file
96
unpackage/dist/dev/mp-weixin/pages/invest/investDetails/investDetails.wxss
vendored
Normal file
@@ -0,0 +1,96 @@
|
||||
.topBg {
|
||||
top: 0;
|
||||
left: 0;
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
.categoryC {
|
||||
background-color: white;
|
||||
margin-top: 10rpx;
|
||||
padding-top: 20rpx;
|
||||
left: 0;
|
||||
right: 0;
|
||||
border-radius: 20rpx 20rpx 0 0;
|
||||
}
|
||||
.categoryC .item {
|
||||
display: inline-block;
|
||||
padding: 0 30rpx;
|
||||
line-height: 75rpx;
|
||||
font-size: 32rpx;
|
||||
font-weight: 500;
|
||||
color: #42485B;
|
||||
}
|
||||
.categoryC .item.select {
|
||||
font-weight: bold;
|
||||
color: #F97316;
|
||||
}
|
||||
.categoryC .item.select .line {
|
||||
background-color: #F97316;
|
||||
left: calc((100% - 50rpx)/2);
|
||||
bottom: 0;
|
||||
width: 50rpx;
|
||||
height: 2rpx;
|
||||
}
|
||||
.contentC {
|
||||
background-color: white;
|
||||
left: 0;
|
||||
right: 0;
|
||||
bottom: 0;
|
||||
overflow-y: scroll;
|
||||
}
|
||||
.contentC .stockCategoryList {
|
||||
margin-top: 18rpx;
|
||||
padding: 0 24rpx;
|
||||
}
|
||||
.contentC .stockCategoryList .item {
|
||||
margin: 0 20rpx 20rpx 0;
|
||||
width: calc((100% - 40rpx)/3);
|
||||
height: 100rpx;
|
||||
border-radius: 10rpx;
|
||||
}
|
||||
.contentC .stockCategoryList .item .num {
|
||||
font-size: 36rpx;
|
||||
font-weight: bold;
|
||||
}
|
||||
.contentC .stockCategoryList .item .title {
|
||||
font-size: 24rpx;
|
||||
font-weight: 500;
|
||||
}
|
||||
.contentC .stockCategoryList .item:nth-child(3n) {
|
||||
margin-right: 0;
|
||||
}
|
||||
.contentC .stockList {
|
||||
padding: 22rpx 25rpx 30rpx;
|
||||
border-bottom: solid 1rpx #E4E4E4;
|
||||
}
|
||||
.contentC .stockList .item .title {
|
||||
font-size: 30rpx;
|
||||
font-weight: bold;
|
||||
color: #222;
|
||||
}
|
||||
.contentC .stockList .item .correlation {
|
||||
background-color: #F973161A;
|
||||
padding: 0 13rpx;
|
||||
line-height: 40rpx;
|
||||
border-radius: 5rpx;
|
||||
font-size: 24rpx;
|
||||
font-weight: 500;
|
||||
color: #F97316;
|
||||
}
|
||||
.contentC .stockList .item .category {
|
||||
display: inline-block;
|
||||
padding: 0 10rpx;
|
||||
line-height: 28rpx;
|
||||
border: solid 1rpx #F6604A;
|
||||
font-size: 20rpx;
|
||||
font-weight: 500;
|
||||
color: #F6604A;
|
||||
border-radius: 5rpx;
|
||||
}
|
||||
.contentC .stockList .item .content {
|
||||
margin-top: 18rpx;
|
||||
font-size: 24rpx;
|
||||
font-weight: 500;
|
||||
color: #666;
|
||||
line-height: 1.2rem;
|
||||
}
|
||||
Reference in New Issue
Block a user