zj #57
| @ -277,14 +277,21 @@ interface SaleInfo{ | |||||||
|     updated_at:string, |     updated_at:string, | ||||||
|     basemoney:string |     basemoney:string | ||||||
| } | } | ||||||
|  | interface SaleInfolData{ | ||||||
|  |     data: SaleInfo[]; | ||||||
|  |     code: number; | ||||||
|  |     msg: string; | ||||||
|  |     total: number; | ||||||
|  | } | ||||||
| /** | /** | ||||||
|  * 交易明细 |  * 交易明细 | ||||||
|  * @param data  |  * @param data  | ||||||
|  */ |  */ | ||||||
|  | 
 | ||||||
| export async function saleinfo(data?:any){ | export async function saleinfo(data?:any){ | ||||||
|     const res= await get<Array<SaleInfo>>('account',data) |     const res=await get<SaleInfolData>('account',data) | ||||||
|     console.log(res) |     console.log(res) | ||||||
|     return res.data |     return res | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
| /** | /** | ||||||
| @ -309,6 +316,8 @@ export async function cashout(data?:any,accountinfo?:any){ | |||||||
|     const res = await post<Liveaddrule>('withdrawal',data); |     const res = await post<Liveaddrule>('withdrawal',data); | ||||||
|     if(res.code==0){ |     if(res.code==0){ | ||||||
|         message.success(res.msg) |         message.success(res.msg) | ||||||
|  |         // userinfo()
 | ||||||
|  |         store.dispatch("setUserInfo"); | ||||||
|     }else{ |     }else{ | ||||||
|         message.error(res.msg) |         message.error(res.msg) | ||||||
|     } |     } | ||||||
| @ -403,8 +412,76 @@ export async function  editpassword(data?:any) :Promise<void> { | |||||||
|     } |     } | ||||||
| } | } | ||||||
| 
 | 
 | ||||||
|  | /** | ||||||
|  |  * 提现记录 列表 | ||||||
|  |  */ | ||||||
|  | interface WithDrawal{ | ||||||
|  |     withdrawalid:number, | ||||||
|  |     memberid:number, | ||||||
|  |     sn:string, | ||||||
|  |     status:number, | ||||||
|  |     statusname:string, | ||||||
|  |     type:number, | ||||||
|  |     typename:string, | ||||||
|  |     money:number | ||||||
|  |     sxf:number, | ||||||
|  |     international:number, | ||||||
|  |     account:string, | ||||||
|  |     mname:string, | ||||||
|  |     bankcode:string, | ||||||
|  |     bankname:string, | ||||||
|  |     remark:string, | ||||||
|  |     deleted_at:string, | ||||||
|  |     created_at:string, | ||||||
|  |     updated_at:string | ||||||
|  | } | ||||||
|  | interface WithdrawlData{ | ||||||
|  |     data: WithDrawal[]; | ||||||
|  |     code: number; | ||||||
|  |     msg: string; | ||||||
|  |     total: number; | ||||||
|  | } | ||||||
|  | export async function withdrawal(data?:any) { | ||||||
|  |     console.log(data) | ||||||
|  |     const res=await get<WithdrawlData>('withdrawal',data) | ||||||
|  |     // console.log(res)
 | ||||||
|  |     return res | ||||||
|  | } | ||||||
| 
 | 
 | ||||||
|  | /** | ||||||
|  |  * 提现记录 详情 | ||||||
|  |  */ | ||||||
|  | export async function withdrawlxq(data?:any){ | ||||||
|  |     const res=await get<WithDrawal>('withdrawal/'+data) | ||||||
|  |     return res.data | ||||||
|  | } | ||||||
| 
 | 
 | ||||||
|  | /** | ||||||
|  |  * 评论(视频?) | ||||||
|  |  */ | ||||||
|  | interface CommentList{ | ||||||
|  |     commentid:number, | ||||||
|  |     memberid:number, | ||||||
|  |     cid:number, | ||||||
|  |     type:number, | ||||||
|  |     score:number, | ||||||
|  |     content:string, | ||||||
|  |     deleted_at:null, | ||||||
|  |     created_at:string, | ||||||
|  |     updated_at:string, | ||||||
|  |     name:string, | ||||||
|  |     img:string | ||||||
|  | } | ||||||
|  | interface CommentlData{ | ||||||
|  |     data: CommentList[]; | ||||||
|  |     code: number; | ||||||
|  |     msg: string; | ||||||
|  |     total: number; | ||||||
|  | } | ||||||
|  | export async function getcommentlist(data?:any) { | ||||||
|  |     const res=await get<CommentlData>('comments',data) | ||||||
|  |     return res | ||||||
|  | } | ||||||
| /** | /** | ||||||
|  * 发送验证码  |  * 发送验证码  | ||||||
|  * @param phone 手机号  |  * @param phone 手机号  | ||||||
|  | |||||||
| @ -18,9 +18,9 @@ | |||||||
|             |             | ||||||
|         </div> |         </div> | ||||||
| 
 | 
 | ||||||
|         <div> |         <div class="reply"> | ||||||
|             <a-textarea v-model:value="value" placeholder="Basic usage" :rows="4" /> |             <a-textarea v-model:value="commentval" placeholder="Basic usage" :rows="4" /> | ||||||
|             <div class="send">发表留言</div> |             <div class="send" @click="send">发表留言</div> | ||||||
|         </div> |         </div> | ||||||
|     </div> |     </div> | ||||||
| </template> | </template> | ||||||
| @ -85,7 +85,7 @@ | |||||||
| } | } | ||||||
| </style> | </style> | ||||||
| <script lang="ts"> | <script lang="ts"> | ||||||
| import { defineComponent } from 'vue'; | import { defineComponent, ref } from 'vue'; | ||||||
| import ReviewItem from "./ReviewItem.vue" | import ReviewItem from "./ReviewItem.vue" | ||||||
| import ReviewItemtwo from "./ReviewItemtwo.vue" | import ReviewItemtwo from "./ReviewItemtwo.vue" | ||||||
| export default defineComponent({ | export default defineComponent({ | ||||||
| @ -93,8 +93,17 @@ export default defineComponent({ | |||||||
|         ReviewItem, |         ReviewItem, | ||||||
|         ReviewItemtwo |         ReviewItemtwo | ||||||
|     }, |     }, | ||||||
|     serup(){ |     setup(){ | ||||||
|  |         const commentval=ref<string>('') | ||||||
|  |         function send(){ | ||||||
|  |             console.log(commentval.value,2221) | ||||||
|  |         } | ||||||
|         console.log(1) |         console.log(1) | ||||||
|  |         return { | ||||||
|  |             commentval, | ||||||
|  |             send | ||||||
|  |              | ||||||
|  |         } | ||||||
|     } |     } | ||||||
| }) | }) | ||||||
| </script> | </script> | ||||||
| @ -7,71 +7,41 @@ | |||||||
|       <a-breadcrumb-item>An Application</a-breadcrumb-item> |       <a-breadcrumb-item>An Application</a-breadcrumb-item> | ||||||
|     </a-breadcrumb> |     </a-breadcrumb> | ||||||
|          <div class="mingxilist"> |          <div class="mingxilist"> | ||||||
|       <div class="tabs"> |      <div class="mingxitop"> | ||||||
|         <div class="beforetab">明细查询</div> |        <div><span class="tabtitle">明细查询</span> | ||||||
|  | </div> | ||||||
|  |         <a-range-picker @change="onChange" class="choosedate"  :placeholder="['请选择开始日期', '请选择结束日期']"/> | ||||||
|       </div> |       </div> | ||||||
|       <div> |       <div> | ||||||
|         <table class="table"> |         <table class="table"> | ||||||
|           <thead> |           <thead> | ||||||
|             <tr class="head"> |             <tr class="head"> | ||||||
|               <th>日期</th> |               <th>账户</th> | ||||||
|               <th>类型</th> |               <th>提交日期</th> | ||||||
|  |               <th>状态</th> | ||||||
|               <th>金额</th> |               <th>金额</th> | ||||||
|               <th>操作</th> |               <th>操作</th> | ||||||
|             </tr> |             </tr> | ||||||
|           </thead> |           </thead> | ||||||
|           <tbody> |           <tbody> | ||||||
|             <tr> |             <tr v-for="(i,j) in withdrawallist.data" :key="j"> | ||||||
|               <td>2020-08-13 13:54</td> |               <td>{{i.typename}}    {{i.account}}</td> | ||||||
|               <td>直播收入</td> |               <td>{{i.created_at}}</td> | ||||||
|               <td class="moneyadd">+¥320</td> |               <td class="moneyadd">{{i.statusname}}</td> | ||||||
|               <td>查看详情</td> |               <td> | ||||||
|             </tr> |                 <span v-if="international==1">$</span> | ||||||
|             <tr> |                 <span v-else>¥</span> | ||||||
|               <td>2020-08-13 13:54</td> |                 {{i.money}} | ||||||
|               <td>直播收入</td> |               </td> | ||||||
|               <td class="moneyreverse">+¥320</td> |               <td @click="navto(3,i.withdrawalid)">查看详情</td> | ||||||
|               <td>查看详情</td> |  | ||||||
|             </tr> |             </tr> | ||||||
|                  |                  | ||||||
|             <tr> |         | ||||||
|               <td>2020-08-13 13:54</td> |  | ||||||
|               <td>直播收入</td> |  | ||||||
|               <td class="moneyadd">+¥320</td> |  | ||||||
|               <td>查看详情</td> |  | ||||||
|             </tr> |  | ||||||
|             <tr> |  | ||||||
|               <td >2020-08-13 13:54</td> |  | ||||||
|               <td>直播收入</td> |  | ||||||
|               <td class="moneyadd">+¥320</td> |  | ||||||
|               <td>查看详情</td> |  | ||||||
|             </tr> |  | ||||||
|             <tr> |  | ||||||
|               <td>2020-08-13 13:54</td> |  | ||||||
|               <td>直播收入</td> |  | ||||||
|               <td class="moneyadd">+¥320</td> |  | ||||||
|               <td>查看详情</td> |  | ||||||
|             </tr> |  | ||||||
|             <tr> |  | ||||||
|               <td>2020-08-13 13:54</td> |  | ||||||
|               <td>直播收入</td> |  | ||||||
|               <td class="moneyadd">+¥320</td> |  | ||||||
|               <td>查看详情</td> |  | ||||||
|             </tr> |  | ||||||
|             <tr> |  | ||||||
|               <td>2020-08-13 13:54</td> |  | ||||||
|               <td>直播收入</td> |  | ||||||
|               <td class="moneyadd">+¥320</td> |  | ||||||
|               <td>查看详情</td> |  | ||||||
|             </tr> |  | ||||||
|             <tr> |  | ||||||
|               <td>2020-08-13 13:54</td> |  | ||||||
|               <td>直播收入</td> |  | ||||||
|               <td class="moneyadd">+¥320</td> |  | ||||||
|               <td>查看详情</td> |  | ||||||
|             </tr> |  | ||||||
|           </tbody> |           </tbody> | ||||||
|         </table> |         </table> | ||||||
|  |         <div class="pages"> | ||||||
|  |           <a-pagination v-model:current="page" :total="withdrawallist.total" :showLessItems="true" @change="pagechange"/> | ||||||
|  |         </div> | ||||||
|       </div> |       </div> | ||||||
|       <NavBottom class="navbottom"></NavBottom> |       <NavBottom class="navbottom"></NavBottom> | ||||||
|     </div> |     </div> | ||||||
| @ -80,17 +50,67 @@ | |||||||
| </template> | </template> | ||||||
| 
 | 
 | ||||||
| <script lang="ts"> | <script lang="ts"> | ||||||
| import { defineComponent } from "vue"; | import { defineComponent, onMounted, ref } from "vue"; | ||||||
| import NavBottom from "@/components/NavBottom.vue"; | import NavBottom from "@/components/NavBottom.vue"; | ||||||
|  | import { withdrawal } from '@/api'; | ||||||
|  | import router from '@/router'; | ||||||
| export default defineComponent({ | export default defineComponent({ | ||||||
|   name: "Transaction", |   name: "Transaction", | ||||||
|   components: { |   components: { | ||||||
|       NavBottom |       NavBottom | ||||||
|   }, |   }, | ||||||
|   setup() { |   setup() { | ||||||
|  |     const withdrawallist =ref<any>({}) | ||||||
|  |     const dates=ref<Array<string>>(["",""]) | ||||||
|  |     const page = ref(1); | ||||||
|  |     onMounted(async () => { | ||||||
|  |       withdrawallist.value=await withdrawal() | ||||||
|  |       console.log(withdrawallist.value)   | ||||||
|  |     }) | ||||||
|  |     async function onChange(e: any,dateString:string){ | ||||||
|  |       console.log(dateString) | ||||||
|  |       dates.value[0]=dateString[0] | ||||||
|  |       dates.value[1]=dateString[1] | ||||||
|  |       withdrawallist.value=await withdrawal({bdate:dates.value[0],edate:dates.value[1]}) | ||||||
|  |     } | ||||||
|  |     function navto(index: number,id?:number) { | ||||||
|  |         let url = ""; | ||||||
|  |         switch (index) { | ||||||
|  |           case 1: | ||||||
|  |              | ||||||
|  |             url = "/mine/addaccount" | ||||||
|  |             console.log(url) | ||||||
|  |             break; | ||||||
|  |           case 2: | ||||||
|  |             url = "/mine/cashout"; | ||||||
|  |             break; | ||||||
|  |           case 3: | ||||||
|  |             url = "/mine/transactionxq" | ||||||
|  |         } | ||||||
|  |         if(id){ | ||||||
|  |           router.push({ | ||||||
|  |             path: url, | ||||||
|  |             query:{id:id,ifwithdrawal:1} | ||||||
|  |           }); | ||||||
|  |         }else{ | ||||||
|  |           router.push({ | ||||||
|  |             path: url | ||||||
|  |           }); | ||||||
|  |         } | ||||||
|  |    | ||||||
|  |   } | ||||||
|  | 
 | ||||||
|  |    async function pagechange(e:any) { | ||||||
|  |       console.log(e) | ||||||
|  |       page.value=e | ||||||
|  |       withdrawallist.value=await withdrawal({bdate:dates.value[0],edate:dates.value[1],page:e}); | ||||||
|  |     } | ||||||
|      |      | ||||||
|     return { |     return { | ||||||
|   |       withdrawallist, | ||||||
|  |       onChange, | ||||||
|  |       navto, | ||||||
|  |       pagechange | ||||||
|     }; |     }; | ||||||
|   }, |   }, | ||||||
| }); | }); | ||||||
| @ -106,23 +126,54 @@ export default defineComponent({ | |||||||
|     background: white; |     background: white; | ||||||
|     border-radius: 18px; |     border-radius: 18px; | ||||||
|     margin-top: 18px; |     margin-top: 18px; | ||||||
|  |    .mingxitop { | ||||||
|  |       display: flex; | ||||||
|  |       justify-content: space-between; | ||||||
|  |       align-items: center; | ||||||
|  |       padding-top: 18px; | ||||||
|  |       padding-right: 40px; | ||||||
|  |     .tabtitle { | ||||||
|  |       width: 60px; | ||||||
|  |       margin-right: 30px; | ||||||
|  |       margin-left: 40px; | ||||||
|  |       font-weight: bold; | ||||||
|  |     } | ||||||
|     .tabs { |     .tabs { | ||||||
|       display: flex; |       display: flex; | ||||||
|       flex-wrap: nowrap; |       align-items: center; | ||||||
|       padding-top: 35px; |       flex-shrink: 0; | ||||||
|       padding-left: 40px; |  | ||||||
|     } |  | ||||||
|     .beforetab { |  | ||||||
|       color: #121212; |  | ||||||
|       font-size: 13px; |       font-size: 13px; | ||||||
|       line-height: 35px; |  | ||||||
|       font-weight: bold; |       font-weight: bold; | ||||||
|       margin-right: 57px; |       color: #111; | ||||||
|  |       padding: 11px 0; | ||||||
|  |   | ||||||
|  |     > div { | ||||||
|  |       margin-right: 38px; | ||||||
|  |       cursor: pointer; | ||||||
|  |       text-align: center; | ||||||
|  |       width: 40px; | ||||||
|  |       font-size:11px; | ||||||
|  |     } | ||||||
|  |     .on { | ||||||
|  |       color: #08ae98; | ||||||
|  |       position: relative; | ||||||
|  |       &::before { | ||||||
|  |         content: ""; | ||||||
|  |         display: block; | ||||||
|  |         position: absolute; | ||||||
|  |         bottom: -6px; | ||||||
|  |         left: 8px; | ||||||
|  |         width: 25px; | ||||||
|  |         height: 1px; | ||||||
|  |         background-color: #08ae98; | ||||||
|  |       } | ||||||
|  |     } | ||||||
|  |   } | ||||||
|     } |     } | ||||||
|   } |   } | ||||||
|   .table { |   .table { | ||||||
|     width: 1150px; |     width: 1150px; | ||||||
|     height: 365px; |     max-height: 365px; | ||||||
|     text-align: center; |     text-align: center; | ||||||
|     color: #343434; |     color: #343434; | ||||||
|     font-size: 12px; |     font-size: 12px; | ||||||
| @ -154,4 +205,23 @@ export default defineComponent({ | |||||||
|       padding-bottom: 30px; |       padding-bottom: 30px; | ||||||
|   } |   } | ||||||
| } | } | ||||||
|  | .pages { | ||||||
|  |         display: flex; | ||||||
|  |         justify-content: center; | ||||||
|  |         margin-top: 46px; | ||||||
|  |         padding-bottom: 28px; | ||||||
|  |         ::v-deep(.ant-pagination-next) > .ant-pagination-item-link, | ||||||
|  |         ::v-deep(.ant-pagination-prev) > .ant-pagination-item-link, | ||||||
|  |         ::v-deep(.ant-pagination-item), | ||||||
|  |         ::v-deep(.ant-pagination-jump-next-custom-icon), | ||||||
|  |         ::v-deep(.ant-pagination-jump-prev-custom-icon) { | ||||||
|  |         border: 1px solid #08ae98; | ||||||
|  |         } | ||||||
|  |         ::v-deep(.ant-pagination-item-active) a { | ||||||
|  |         color: #fff; | ||||||
|  |         } | ||||||
|  |         ::v-deep(.ant-pagination-item-active) { | ||||||
|  |         background-color: #08ae98; | ||||||
|  |         } | ||||||
|  |     } | ||||||
| </style> | </style> | ||||||
| @ -6,7 +6,7 @@ | |||||||
|       <a-breadcrumb-item href=""> Application List </a-breadcrumb-item> |       <a-breadcrumb-item href=""> Application List </a-breadcrumb-item> | ||||||
|       <a-breadcrumb-item>An Application</a-breadcrumb-item> |       <a-breadcrumb-item>An Application</a-breadcrumb-item> | ||||||
|     </a-breadcrumb> |     </a-breadcrumb> | ||||||
|       <div class="mingxilist"> |       <div class="mingxilist" v-if="query.ifwithdrawal!=1"> | ||||||
|         <div class="tabs"> |         <div class="tabs"> | ||||||
|           <div class="beforetab">交易明细详情</div> |           <div class="beforetab">交易明细详情</div> | ||||||
|         </div> |         </div> | ||||||
| @ -36,34 +36,119 @@ | |||||||
| 
 | 
 | ||||||
|           <div class="infoitem"> |           <div class="infoitem"> | ||||||
|             <div class="left">来源</div> |             <div class="left">来源</div> | ||||||
|             <div class="right">直播收益—英语三级A1教学</div> |             <div class="right">{{accountinfo.remark}}</div> | ||||||
|           </div> |           </div> | ||||||
|  |           <div class="back" @click="navto(1,2)">返回</div> | ||||||
|           |           | ||||||
|           <div class="back">返回</div> |  | ||||||
|         </div> |         </div> | ||||||
|       <NavBottom class="navbottom"></NavBottom> |       <NavBottom class="navbottom"></NavBottom> | ||||||
|     </div> |     </div> | ||||||
|     |     | ||||||
|  |       <div class="mingxilist" v-if="query.ifwithdrawal==1"> | ||||||
|  |         <div class="tabs"> | ||||||
|  |           <div class="beforetab">提现记录详情</div> | ||||||
|  |         </div> | ||||||
|  |         <div class="detail"> | ||||||
|  |         <div class="infoitem"> | ||||||
|  |           <div class="left">提现金额</div> | ||||||
|  |           <div class="right">{{accountinfo.amount}}</div> | ||||||
|  |         </div> | ||||||
|  |          <div class="infoitem"> | ||||||
|  |           <div class="left">到帐金额</div> | ||||||
|  |           <div class="right">{{accountinfo.money}}</div> | ||||||
|  |         </div> | ||||||
|  |          <div class="infoitem"> | ||||||
|  |           <div class="left">手续费</div> | ||||||
|  |           <div class="right">{{accountinfo.sxf}}</div> | ||||||
|  |         </div> | ||||||
|  |           <div class="infoitem"> | ||||||
|  |             <div class="left">提现状态</div> | ||||||
|  |              <div class="right" >{{accountinfo.statusname}}</div> | ||||||
|  |             <!-- <div class="right" v-if="accountinfo.status==1">直播收入</div> | ||||||
|  |             <div class="right" v-if="accountinfo.status==2">提现</div> | ||||||
|  |             <div class="right" v-if="accountinfo.status==3">后台充值</div> --> | ||||||
|  | 
 | ||||||
|  |           </div> | ||||||
|  |           <div class="infoitem"> | ||||||
|  |             <div class="left">原因描述</div> | ||||||
|  |             <div class="right">{{accountinfo.remark}}</div> | ||||||
|  |           </div> | ||||||
|  |           <div class="infoitem"> | ||||||
|  |             <div class="left">流水号</div> | ||||||
|  |             <div class="right">{{accountinfo.sn}}</div> | ||||||
|  |           </div> | ||||||
|  |           <div class="infoitem"> | ||||||
|  |             <div class="left">名称</div> | ||||||
|  |             <div class="right">{{accountinfo.typename}}</div> | ||||||
|  |           </div> | ||||||
|  |           <div class="infoitem"> | ||||||
|  |             <div class="left">日期</div> | ||||||
|  |             <div class="right">{{accountinfo.created_at}}</div> | ||||||
|  |           </div> | ||||||
|  | 
 | ||||||
|  |           <div class="infoitem"> | ||||||
|  |             <div class="left">收款账户</div> | ||||||
|  |             <div class="right">{{accountinfo.account}}</div> | ||||||
|  |           </div> | ||||||
|  |          | ||||||
|  |           <div class="back" @click="navto(2)">返回</div> | ||||||
|  |         </div> | ||||||
|  |       <NavBottom class="navbottom"></NavBottom> | ||||||
|  |     </div> | ||||||
|   </div> |   </div> | ||||||
| </template> | </template> | ||||||
| 
 | 
 | ||||||
| <script lang="ts"> | <script lang="ts"> | ||||||
| import { defineComponent, onMounted, ref } from "vue"; | import { defineComponent, onMounted, ref } from "vue"; | ||||||
| import NavBottom from "@/components/NavBottom.vue"; | import NavBottom from "@/components/NavBottom.vue"; | ||||||
| import { transactioninfo } from '@/api'; | import { transactioninfo, withdrawlxq } from '@/api'; | ||||||
| import { useRoute } from 'vue-router'; | import { useRoute } from 'vue-router'; | ||||||
|  | import router from '@/router'; | ||||||
| export default defineComponent({ | export default defineComponent({ | ||||||
|   name: "Transactiondetail", |   name: "Transactiondetail", | ||||||
|   components: { |   components: { | ||||||
|       NavBottom |       NavBottom | ||||||
|   }, |   }, | ||||||
|   setup() { |   setup() { | ||||||
|     const accountinfo=ref<any>({}) |     const accountinfo=ref<any>({}); | ||||||
|  |     const query=ref({}) | ||||||
|     onMounted(async () => { |     onMounted(async () => { | ||||||
|  |       query.value=useRoute().query | ||||||
|  |       if(useRoute().query.ifwithdrawal){ | ||||||
|  |         accountinfo.value=await withdrawlxq(useRoute().query.id) | ||||||
|  |       }else{ | ||||||
|         accountinfo.value=await transactioninfo(useRoute().query.id) |         accountinfo.value=await transactioninfo(useRoute().query.id) | ||||||
|  |       } | ||||||
|  |        | ||||||
|     }) |     }) | ||||||
|  |     function navto(index: number,id?:number) { | ||||||
|  |       let url = ""; | ||||||
|  |       switch (index) { | ||||||
|  |         case 1: | ||||||
|  |            | ||||||
|  |           url = "/mine/wallet" | ||||||
|  |           console.log(url) | ||||||
|  |           break; | ||||||
|  |         case 2: | ||||||
|  |           url = "/mine/transaction"; | ||||||
|  |           break; | ||||||
|  |       } | ||||||
|  |       if(id){ | ||||||
|  |         router.push({ | ||||||
|  |           path: url, | ||||||
|  |           query:{ifsale:id } | ||||||
|  |         }); | ||||||
|  |       }else{ | ||||||
|  |         router.push({ | ||||||
|  |           path: url | ||||||
|  |         }); | ||||||
|  |     } | ||||||
|  |    | ||||||
|  |   } | ||||||
|     return { |     return { | ||||||
|       accountinfo |       accountinfo, | ||||||
|  |       query, | ||||||
|  |       navto | ||||||
|     }; |     }; | ||||||
|   }, |   }, | ||||||
| }); | }); | ||||||
|  | |||||||
| @ -31,7 +31,7 @@ | |||||||
|               <div class="num"> |               <div class="num"> | ||||||
|                 <span class="moneyicon" v-if="ifchina">¥</span> |                 <span class="moneyicon" v-if="ifchina">¥</span> | ||||||
|                 <span class="moneyicon" v-else> $ </span> |                 <span class="moneyicon" v-else> $ </span> | ||||||
|                 <!-- {{store.state.userinfo.moneyValue}} --> |                 {{store.state.userinfo.moneyValue}} | ||||||
|                  |                  | ||||||
|                 <!-- {{store.state.userinfo.money.split('.')[0]}} |                 <!-- {{store.state.userinfo.money.split('.')[0]}} | ||||||
|                  <span class="float">{{store.state.userinfo.money.split('.')[1]?'.'+store.state.userinfo.money.split('.')[1]:''}}</span> --> |                  <span class="float">{{store.state.userinfo.money.split('.')[1]?'.'+store.state.userinfo.money.split('.')[1]:''}}</span> --> | ||||||
| @ -184,17 +184,20 @@ | |||||||
|             </tr> |             </tr> | ||||||
|           </thead> |           </thead> | ||||||
|           <tbody> |           <tbody> | ||||||
|             <tr v-for="(i,j) in salelist" :key="j"> |             <tr v-for="(i,j) in salelist.data" :key="j"> | ||||||
|               <td>{{i.created_at}}</td> |               <td>{{i.created_at}}</td> | ||||||
|               <td>{{i.typename}}</td> |               <td>{{i.typename}}</td> | ||||||
|               <td class="moneyadd moneyreverse" v-if="i.type==2">-¥{{i.money}}</td> |               <td class="moneyadd moneyreverse" v-if="i.type==2">-¥{{i.money}}</td> | ||||||
|               <td class="moneyadd " v-else>+¥{{i.money}}</td> |               <td class="moneyadd " v-else>+¥{{i.money}}</td> | ||||||
|               <td @click="navto(3,i.accountid)">查看详情{{i.accountid}}</td> |               <td @click="navto(4,i.accountid)">查看详情{{i.accountid}}</td> | ||||||
|             </tr> |             </tr> | ||||||
|           |           | ||||||
|           </tbody> |           </tbody> | ||||||
|         </table> |         </table> | ||||||
|       </div> |       </div> | ||||||
|  |       <div class="pages"> | ||||||
|  |         <a-pagination v-model:current="page" :total="salelist.total" :showLessItems="true" @change="pagechange"/> | ||||||
|  |       </div> | ||||||
|     </div> |     </div> | ||||||
|     <NavBottom class="navbottom"></NavBottom> |     <NavBottom class="navbottom"></NavBottom> | ||||||
|   </div> |   </div> | ||||||
| @ -206,6 +209,7 @@ import NavBottom from "@/components/NavBottom.vue"; | |||||||
| import router from "@/router"; | import router from "@/router"; | ||||||
| import store from '@/store'; | import store from '@/store'; | ||||||
| import { deleteaccount, getwallect, saleinfo } from "@/api"; | import { deleteaccount, getwallect, saleinfo } from "@/api"; | ||||||
|  | import { useRoute } from 'vue-router'; | ||||||
| export default defineComponent({ | export default defineComponent({ | ||||||
|   name: "Wallet", |   name: "Wallet", | ||||||
|   components: { |   components: { | ||||||
| @ -214,13 +218,20 @@ export default defineComponent({ | |||||||
|   setup() { |   setup() { | ||||||
|     const ifchina = true; |     const ifchina = true; | ||||||
|     const ifmingxi = false; |     const ifmingxi = false; | ||||||
|     const salelist=ref<Array<any>>([]) |     const salelist=ref<any>({}) | ||||||
|     const accountlist =ref<Array<any>>([]) |     const accountlist =ref<Array<any>>([]) | ||||||
|     const listindex=ref<number>(1) |     const listindex=ref<number>(1) | ||||||
|     const state=ref<number>(0) |     const state=ref<number>(0) | ||||||
|     const dates=ref<Array<string>>(["",""]) |     const dates=ref<Array<string>>(["",""]) | ||||||
|  |     const page = ref(1); | ||||||
|     onMounted(async () => { |     onMounted(async () => { | ||||||
| 
 |       console.log(useRoute().query) | ||||||
|  |       listindex.value=1 | ||||||
|  |       if(useRoute().query.ifsale){ | ||||||
|  |         listindex.value=2 | ||||||
|  |       }else{ | ||||||
|  |         listindex.value=1 | ||||||
|  |       } | ||||||
|       salelist.value = await saleinfo(); |       salelist.value = await saleinfo(); | ||||||
|       accountlist.value=await  getwallect(); |       accountlist.value=await  getwallect(); | ||||||
|       console.log(store.state.userinfo) |       console.log(store.state.userinfo) | ||||||
| @ -229,7 +240,7 @@ export default defineComponent({ | |||||||
|     async function tabchange(e: number): Promise<void> { |     async function tabchange(e: number): Promise<void> { | ||||||
|       tabindex.value = e; |       tabindex.value = e; | ||||||
|       state.value=e |       state.value=e | ||||||
|       salelist.value=await saleinfo({status:e,bdate:dates.value[0],edate:dates.value[1]}); |       salelist.value=await saleinfo({status:e,bdate:dates.value[0],edate:dates.value[1],page:page.value}); | ||||||
|       // console.log(videolist) |       // console.log(videolist) | ||||||
|     } |     } | ||||||
|     function listchange(e: number){ |     function listchange(e: number){ | ||||||
| @ -239,11 +250,16 @@ export default defineComponent({ | |||||||
|       console.log(dateString) |       console.log(dateString) | ||||||
|       dates.value[0]=dateString[0] |       dates.value[0]=dateString[0] | ||||||
|       dates.value[1]=dateString[1] |       dates.value[1]=dateString[1] | ||||||
|       salelist.value=await saleinfo({bdate:dateString[0],edate:dateString[1],status:state.value}); |       salelist.value=await saleinfo({bdate:dateString[0],edate:dateString[1],status:state.value,page:page.value}); | ||||||
|     } |     } | ||||||
|     async function del(e: number){ |     async function del(e: number){ | ||||||
|       deleteaccount(e) |       deleteaccount(e) | ||||||
|     } |     } | ||||||
|  |     async function pagechange(e:any) { | ||||||
|  |       console.log(e) | ||||||
|  |       page.value=e | ||||||
|  |       salelist.value=await saleinfo({status:state.value,bdate:dates.value[0],edate:dates.value[1],page:e}); | ||||||
|  |     } | ||||||
|     function navto(index: number,id?:number) { |     function navto(index: number,id?:number) { | ||||||
|       let url = ""; |       let url = ""; | ||||||
|       switch (index) { |       switch (index) { | ||||||
| @ -256,6 +272,9 @@ export default defineComponent({ | |||||||
|           url = "/mine/cashout"; |           url = "/mine/cashout"; | ||||||
|           break; |           break; | ||||||
|         case 3: |         case 3: | ||||||
|  |           url = "/mine/transaction"; | ||||||
|  |           break; | ||||||
|  |         case 4: | ||||||
|           url="/mine/transactionxq" |           url="/mine/transactionxq" | ||||||
|       } |       } | ||||||
|       if(id){ |       if(id){ | ||||||
| @ -283,7 +302,8 @@ export default defineComponent({ | |||||||
|       onChange, |       onChange, | ||||||
|       dates, |       dates, | ||||||
|       del, |       del, | ||||||
|       store |       store, | ||||||
|  |       pagechange | ||||||
|     }; |     }; | ||||||
|   }, |   }, | ||||||
| }); | }); | ||||||
| @ -516,10 +536,11 @@ export default defineComponent({ | |||||||
| 
 | 
 | ||||||
|   .mingxilist { |   .mingxilist { | ||||||
|     width: 1150px; |     width: 1150px; | ||||||
|     max-height: 533px; |     // max-height: 533px; | ||||||
|     background: white; |     background: white; | ||||||
|     border-radius: 18px; |     border-radius: 18px; | ||||||
|     margin-top: 18px; |     margin-top: 18px; | ||||||
|  |      | ||||||
|     .mingxitop { |     .mingxitop { | ||||||
|       display: flex; |       display: flex; | ||||||
|       justify-content: space-between; |       justify-content: space-between; | ||||||
| @ -574,5 +595,24 @@ export default defineComponent({ | |||||||
|   .navbottom { |   .navbottom { | ||||||
|     margin-top: 160px; |     margin-top: 160px; | ||||||
|   } |   } | ||||||
|  |   .pages { | ||||||
|  |         display: flex; | ||||||
|  |         justify-content: center; | ||||||
|  |         margin-top: 46px; | ||||||
|  |         padding-bottom: 28px; | ||||||
|  |         ::v-deep(.ant-pagination-next) > .ant-pagination-item-link, | ||||||
|  |         ::v-deep(.ant-pagination-prev) > .ant-pagination-item-link, | ||||||
|  |         ::v-deep(.ant-pagination-item), | ||||||
|  |         ::v-deep(.ant-pagination-jump-next-custom-icon), | ||||||
|  |         ::v-deep(.ant-pagination-jump-prev-custom-icon) { | ||||||
|  |         border: 1px solid #08ae98; | ||||||
|  |         } | ||||||
|  |         ::v-deep(.ant-pagination-item-active) a { | ||||||
|  |         color: #fff; | ||||||
|  |         } | ||||||
|  |         ::v-deep(.ant-pagination-item-active) { | ||||||
|  |         background-color: #08ae98; | ||||||
|  |         } | ||||||
|  |     } | ||||||
| } | } | ||||||
| </style> | </style> | ||||||
| @ -197,7 +197,7 @@ export default defineComponent({ | |||||||
|     VideoItem, |     VideoItem, | ||||||
|   }, |   }, | ||||||
|   setup() { |   setup() { | ||||||
|     const page = ref(6); |     const page = ref(1); | ||||||
|     const tabindex = ref(4); |     const tabindex = ref(4); | ||||||
|     interface VideoList { |     interface VideoList { | ||||||
|       videoid: number; |       videoid: number; | ||||||
| @ -226,17 +226,19 @@ export default defineComponent({ | |||||||
|       videolist.value = res; |       videolist.value = res; | ||||||
| 
 | 
 | ||||||
|     }); |     }); | ||||||
|     function tabchange(e: number): void { |     async function tabchange(e: number) { | ||||||
|       tabindex.value = e; |       tabindex.value = e; | ||||||
|  |       videolist.value = await getvideolist({title: input.value,page:page.value,status:e}); | ||||||
|       // console.log(videolist) |       // console.log(videolist) | ||||||
|     } |     } | ||||||
|     async function sel(){ |     async function sel(){ | ||||||
|         console.log(input.value); |         console.log(input.value); | ||||||
|         page.value = 1; |         page.value = 1; | ||||||
|           videolist.value = await getvideolist({title: input.value,page:page.value}); |         videolist.value = await getvideolist({title: input.value,page:page.value,status:tabindex.value}); | ||||||
|     } |     } | ||||||
|     async function  pagechange() { |     async function  pagechange(e: number) { | ||||||
|       videolist.value = await getvideolist({title: input.value,page:page.value}); |       page.value=e | ||||||
|  |       videolist.value = await getvideolist({title: input.value,page:e,status:tabindex.value}); | ||||||
|     } |     } | ||||||
|     return { |     return { | ||||||
|       page, |       page, | ||||||
|  | |||||||
| @ -25,7 +25,7 @@ import { defineComponent, onMounted, ref } from 'vue'; | |||||||
| import VideoPlay from "@/components/VideoPlay.vue" | import VideoPlay from "@/components/VideoPlay.vue" | ||||||
| import VideoCont from "@/components/VideoCont.vue" | import VideoCont from "@/components/VideoCont.vue" | ||||||
| import VideoReview from "@/components/VideoReview.vue"; | import VideoReview from "@/components/VideoReview.vue"; | ||||||
| import { videodetail } from '@/api'; | import { getcommentlist, videodetail } from '@/api'; | ||||||
| import { useRoute } from 'vue-router'; | import { useRoute } from 'vue-router'; | ||||||
| export default defineComponent({ | export default defineComponent({ | ||||||
|     components:{ |     components:{ | ||||||
| @ -37,8 +37,11 @@ export default defineComponent({ | |||||||
|         // console.log(1) |         // console.log(1) | ||||||
|         console.log(useRoute().query) |         console.log(useRoute().query) | ||||||
|         const result=ref({}) |         const result=ref({}) | ||||||
|  |         const commentlist=ref({}) | ||||||
|  |         const videoid=ref(useRoute().query.id) | ||||||
|           onMounted(async () => { |           onMounted(async () => { | ||||||
|             result.value= await videodetail(useRoute().query.id) |             result.value= await videodetail(useRoute().query.id) | ||||||
|  |             commentlist.value=await getcommentlist({type:2,id:videoid.value}) | ||||||
|         }) |         }) | ||||||
|      |      | ||||||
|        return { |        return { | ||||||
|  | |||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user