<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>商品管理系统</title>
<script src="../lib/js/ionic.bundle.js"></script>
<style>
table tr{
border: 1px solid;
}
body{
width: 800px;
margin: 0 auto;
}
table tr:nth-child(2n){
background-color: #CCCCCA;
}
</style>
<script>
angular.module("myapp",[])
.controller("demoC",function($scope){
//新增区域默认不显示
$scope.showadd=false;
$scope.title="state";
$scope.desc=false; //默认false升 true降
//数组
$scope.goods=[];
for(var i=1;i<5;i++){
var g={
"checked":false, //复选是否被选中
"id":i,
"gname":"云南白药"+i,
"address":"云南",
"state":"发货",
"regDate":new Date(),
"price":100+i
};
var g2={
"checked":true,
"id":10+i,
"gname":"云南白药"+i,
"address":"云南",
"state":"已发货",
"regDate":new Date("2016-"+i+"-1 3:01:02"),
"price":100+i
};
$scope.goods.push(g);
$scope.goods.push(g2);
}
//全选操作
$scope.ckAll=function(){
var ck=$scope.isck;// 表头中的复选框
<html>
<head>
<meta charset="UTF-8">
<title>商品管理系统</title>
<script src="../lib/js/ionic.bundle.js"></script>
<style>
table tr{
border: 1px solid;
}
body{
width: 800px;
margin: 0 auto;
}
table tr:nth-child(2n){
background-color: #CCCCCA;
}
</style>
<script>
angular.module("myapp",[])
.controller("demoC",function($scope){
//新增区域默认不显示
$scope.showadd=false;
$scope.title="state";
$scope.desc=false; //默认false升 true降
//数组
$scope.goods=[];
for(var i=1;i<5;i++){
var g={
"checked":false, //复选是否被选中
"id":i,
"gname":"云南白药"+i,
"address":"云南",
"state":"发货",
"regDate":new Date(),
"price":100+i
};
var g2={
"checked":true,
"id":10+i,
"gname":"云南白药"+i,
"address":"云南",
"state":"已发货",
"regDate":new Date("2016-"+i+"-1 3:01:02"),
"price":100+i
};
$scope.goods.push(g);
$scope.goods.push(g2);
}
//全选操作
$scope.ckAll=function(){
var ck=$scope.isck;// 表头中的复选框