生三从境界:昨夜西风凋碧树,独上高楼,望尽天涯路。 衣带渐宽终不悔,为伊消得人憔悴。 众里寻他千百度,蓦然回首,那人却在灯火阑珊处。人

随笔 - 151  文章 - 0  评论 - 117  阅读 - 108万 

test.js 文件里的onLoad

复制代码
function getarticles(p,order,mythis) {
  wx.request({
    url: 'https://ganggouo.cn/index.php/Home/getarticles',    //后台接口地址
    method: 'post',  //post请求
    data: {
      p: p,
      order: order,
    },
    header: {
      'content-type': 'application/x-www-form-urlencoded'
    },
    success: function (res) {
      mythis.setData({
        Articlelist: res.data
      });
    },
    fail: function (res) {
      console.log(res);
    }
  });
};
复制代码

 

test.html 页面渲染

<view class='projectlist' >
  <view class='project'  wx:for="{{arrayProject}}"  wx:for-item="itemProjec" wx:key="id" data-datas="{{itemProjec}}" bindtap='projectDetail'>
      <view class='projectText'> {{itemProjec.gongchengmingcheng}} </view>
      <view class='projectleibie label'> {{arrayCategory[itemProjec.leixing].name}} </view>
      <view class='projectjiesuan label'> {{arraySchedule[itemProjec.jieduan].name}} </view>
      <view class='projectTime'> {{itemProjec.faburiqi}} </view>
  </view>
</view>

 

posted on   测试开发喵  阅读(2595)  评论(0编辑  收藏  举报
编辑推荐:
· AI与.NET技术实操系列:向量存储与相似性搜索在 .NET 中的实现
· 基于Microsoft.Extensions.AI核心库实现RAG应用
· Linux系列:如何用heaptrack跟踪.NET程序的非托管内存泄露
· 开发者必知的日志记录最佳实践
· SQL Server 2025 AI相关能力初探
阅读排行:
· 震惊!C++程序真的从main开始吗?99%的程序员都答错了
· 单元测试从入门到精通
· 【硬核科普】Trae如何「偷看」你的代码?零基础破解AI编程运行原理
· 上周热点回顾(3.3-3.9)
· winform 绘制太阳,地球,月球 运作规律
点击右上角即可分享
微信分享提示