angular
diff --git a/CanDoo.Host/CanDoo.MvcHost/Areas/ShopA/Views/Home/Index.cshtml b/CanDoo.Host/CanDoo.MvcHost/Areas/ShopA/Views/Home/Index.cshtml index dbe87f1..aa4d1cc 100644 --- a/CanDoo.Host/CanDoo.MvcHost/Areas/ShopA/Views/Home/Index.cshtml +++ b/CanDoo.Host/CanDoo.MvcHost/Areas/ShopA/Views/Home/Index.cshtml @@ -1,89 +1,111 @@ @*@model CanDoo.MvcHost.Areas.ShopA.Models.IndexModule*@ @{ ViewBag.Title = "Index"; } <div ng-app="myApp" ng-controller="myCtrl"> <div> + <h2>广告---------------------------------------------------------------------------------------------------------</h2> + <div ng-repeat="x in gg1"> + <h3 ng-bind="x.Name"></h3> + <p ng-bind="x.PicUrl"></p> + <p ng-bind="x.Url"></p> + <p ng-bind="x.Id"></p> + </div> + </div> + + <div> <h2>母婴用品</h2> <div ng-repeat="x in data"> <h3 ng-bind="x.AliasName"></h3> <p ng-bind="x.Id"></p> <p ng-bind="x.Img0"></p> <p ng-bind="x.Price"></p> </div> </div> <div> <h2>日化</h2> <div ng-repeat="x in dataShuma"> <h3 ng-bind="x.AliasName"></h3> <p ng-bind="x.Id"></p> <p ng-bind="x.Img0"></p> <p ng-bind="x.Price"></p> </div> </div> <div> <h2>日化fdddddddddddddddddddddddddddddddddddddddddd</h2> <div ng-repeat="x in data2"> <h3 ng-bind="x.AliasName"></h3> <p ng-bind="x.Id"></p> <p ng-bind="x.Img0"></p> <p ng-bind="x.Price"></p> </div> </div> + + </div> <script> var app = angular.module('myApp', []); app.controller('myCtrl', function ($scope,$http) { $scope.list = function () { $http.post("/api/ProductMainApi/GetList", { ProductTypeId:"79377144530079744"}) .then(function (response) { $scope.data = response.data.Data; }) .catch(function (result) { //捕捉错误处理 //错误内容 console.log(result) }); } - $scope.list(); - $scope.listShuma = function () { - $http.post("/api/ProductMainApi/GetList", { ProductTypeId: "79377143980625920" }) + $http.post("/api/ProductMainApi", { ProductTypeId: "79377143980625920" }) .then(function (response) { $scope.dataShuma = response.data.Data; console.log(response) }) .catch(function (result) { //捕捉错误处理 //错误内容 console.log(result) }); } $scope.list2 = function () { $http.post("/api/ProductMainApi/GetList", { ProductTypeId: "79377144530079744" }) .then(function (response) { $scope.data2 = response.data.Data; console.log(response) }) .catch(function (result) { //捕捉错误处理 //错误内容 console.log(result) }); } + $scope.listGg1 = function () { + $http.post("/api/ShopADApi/GetList", { ShopADTypeId: "79575310986645504" }) + .then(function (response) { + $scope.gg1 = response.data.Data; + console.log(response) + }) + .catch(function (result) { //捕捉错误处理 + //错误内容 + console.log(result) + }); + } + $scope.listGg1(); $scope.list(); - $scope.list2(); - $scope.listShuma(); + //$scope.list2(); + //$scope.listShuma(); }); </script>
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· AI与.NET技术实操系列(二):开始使用ML.NET
· 记一次.NET内存居高不下排查解决与启示
· 探究高空视频全景AR技术的实现原理
· 理解Rust引用及其生命周期标识(上)
· 浏览器原生「磁吸」效果!Anchor Positioning 锚点定位神器解析
· DeepSeek 开源周回顾「GitHub 热点速览」
· 记一次.NET内存居高不下排查解决与启示
· 物流快递公司核心技术能力-地址解析分单基础技术分享
· .NET 10首个预览版发布:重大改进与新特性概览!
· .NET10 - 预览版1新功能体验(一)
2013-03-13 使用ILmerge合并Exe、Dll文件的帮助类
2013-03-13 黄聪:C#中用ILMerge将所有引用的DLL和exe文件打成一个exe文件,有图解
2013-03-13 nat上传文件到google
2013-03-13 git保存用户名密码 Google Code在Windows下面设置.netrc