|
@@ -10,7 +10,7 @@
|
|
|
<text style="display: inline" @click="goDetailReport(item)">
|
|
|
{{ item.Title }}
|
|
|
</text>
|
|
|
- <text @click="themeDetails(item,val)" class="item-industry" v-for="val in item.List" :key="val.IndustrialManagementId"> # {{ val.IndustryName }} </text>
|
|
|
+ <text @click="themeDetails(item, val)" class="item-industry" v-for="val in item.List" :key="val.IndustrialManagementId"> # {{ val.IndustryName }} </text>
|
|
|
</view>
|
|
|
<view class="item-more">
|
|
|
<text>{{ item.PublishDate }}</text>
|
|
@@ -38,7 +38,7 @@
|
|
|
</template>
|
|
|
|
|
|
<script>
|
|
|
-import { Mine } from "@/config/api.js";
|
|
|
+import { Mine, Report } from "@/config/api.js";
|
|
|
import { Throttle } from "@/config/util.js";
|
|
|
import freeCharge from "@/components/freeCharge";
|
|
|
export default {
|
|
@@ -92,7 +92,7 @@ export default {
|
|
|
this.$store.dispatch("checkHandle", "/pageMy/reportDetail/reportDetail?id=" + item.ArticleId);
|
|
|
},
|
|
|
//去往主题详情
|
|
|
- themeDetails(item,val) {
|
|
|
+ themeDetails(item, val) {
|
|
|
if (item.Source === 1) {
|
|
|
//非严选
|
|
|
this.$store.dispatch("checkHandle", "/reportPages/IndustryReport/IndustryReport?id=" + val.IndustrialManagementId);
|
|
@@ -101,6 +101,27 @@ export default {
|
|
|
this.$store.dispatch("checkHandle", "/reportPages/researchTheme/researchTheme?id=" + val.IndustrialManagementId);
|
|
|
}
|
|
|
},
|
|
|
+ //收藏
|
|
|
+ async collectClick(item) {
|
|
|
+ const res = await Report.collectRpt({ ArticleId: item.ArticleId });
|
|
|
+ if (res.Ret === 200) {
|
|
|
+ item.IsCollect = !item.IsCollect;
|
|
|
+ item.IsCollect
|
|
|
+ ? (item.CollectNum += 1) &&
|
|
|
+ uni.showToast({
|
|
|
+ title: "收藏成功",
|
|
|
+ icon: "none",
|
|
|
+ duration: 2000,
|
|
|
+ })
|
|
|
+ : (item.CollectNum -= 1);
|
|
|
+ !item.IsCollect &&
|
|
|
+ uni.showToast({
|
|
|
+ title: "已取消收藏",
|
|
|
+ icon: "none",
|
|
|
+ duration: 2000,
|
|
|
+ });
|
|
|
+ }
|
|
|
+ },
|
|
|
},
|
|
|
/* 触底 */
|
|
|
onReachBottom: Throttle(function () {
|