Commit 3e339799 by shj

生成预算提示,总预算与预算分布的差值

parent 42269046
......@@ -121,6 +121,30 @@ ${pageContext.request.contextPath}<br>
});
</script>
<div id="computedTest">
<input type="number" v-model="arr[0]">
<input type="number" v-model="arr[1]">
<p>{{z}}</p>
</div>
<script type="text/javascript">
var computedVue=new Vue({
el:"#computedTest",
data:{
x:0,
y:0,
arr:[]
},
computed:{
z:function () {
var sum=Number(0);
for(var i =0;i<this.arr.length;i++)
sum+=Number(this.arr[i]);
return sum;
}
}
})
</script>
<script type="text/javascript">
function logout() {
if(confirm("确认退出登录?")){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment