forked from yisainan/vue2
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update: antoman 组件化开发/第二步:创建通用组件slider 命令应该是:automan-cli -p common/sl…
…ider
- Loading branch information
Showing
29 changed files
with
217 additions
and
2 deletions.
There are no files selected for viewing
Empty file.
1 change: 1 addition & 0 deletions
1
uyi2/automan/browser/pages/components/common/slider/slider.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<div>slider</div> |
13 changes: 13 additions & 0 deletions
13
uyi2/automan/browser/pages/components/common/slider/slider.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
use([], function() { | ||
Vue.component('sliderComponent', { | ||
pageName: "common", | ||
template: "pages/components/common/slider/slider.html", | ||
data:function() { | ||
return {} | ||
}, | ||
created: function() {}, | ||
mounted: function() {}, | ||
destroyed: function() {}, | ||
methods: {} | ||
}); | ||
}); |
Empty file.
1 change: 1 addition & 0 deletions
1
uyi2/automan/browser/pages/components/jiaofei/index/banner/banner.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
<div>hello 私有 banner</div> |
13 changes: 13 additions & 0 deletions
13
uyi2/automan/browser/pages/components/jiaofei/index/banner/banner.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
use([], function() { | ||
Vue.component('bannerComponent', { | ||
pageName: "jiaofei/index", | ||
template: "pages/components/jiaofei/index/banner/banner.html", | ||
data:function() { | ||
return {} | ||
}, | ||
created: function() {}, | ||
mounted: function() {}, | ||
destroyed: function() {}, | ||
methods: {} | ||
}); | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
<% include header.html %> | ||
<template> | ||
<div id="content-box"> | ||
hello world! | ||
123 | ||
</div> | ||
</template> | ||
<% include footer.html %> |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
<% include header.html %> | ||
<template> | ||
<div id="content-box"> | ||
<sliderComponent></sliderComponent> | ||
<bannerComponent></bannerComponent> | ||
</div> | ||
</template> | ||
<% include footer.html %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
use([ | ||
"pages/jiaofei/index/indexService", | ||
"pages/components/jiaofei/index/banner/banner", | ||
"pages/components/common/slider/slider" | ||
], function() { | ||
function init(storage) { | ||
var app = new VueRoot({ | ||
template: 'pages/jiaofei/index/index.html', | ||
data: storage, | ||
created: function() {}, | ||
mounted: function() {}, | ||
methods: {} | ||
}); | ||
return app; | ||
} | ||
module.exports = init; | ||
if(typeof window != "undefined") { | ||
var mainComponent = init(storage); | ||
mainComponent.$mount("#automan-view"); | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
var indexService = { | ||
urls: {} | ||
} | ||
module.exports = indexService; |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<% include header.html %> | ||
<template> | ||
<div id="content-box"> | ||
|
||
</div> | ||
</template> | ||
<% include footer.html %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
use([ | ||
"pages/jiaofei/pay/payService" | ||
], function() { | ||
function init(storage) { | ||
var app = new VueRoot({ | ||
template: 'pages/jiaofei/pay/pay.html', | ||
data: storage, | ||
created: function() {}, | ||
mounted: function() {}, | ||
methods: {} | ||
}); | ||
return app; | ||
} | ||
module.exports = init; | ||
if(typeof window != "undefined") { | ||
var mainComponent = init(storage); | ||
mainComponent.$mount("#automan-view"); | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
var payService = { | ||
urls: {} | ||
} | ||
module.exports = payService; |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<% include header.html %> | ||
<template> | ||
<div id="content-box"> | ||
|
||
</div> | ||
</template> | ||
<% include footer.html %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
use([ | ||
"pages/user/detail/detailService" | ||
], function() { | ||
function init(storage) { | ||
var app = new VueRoot({ | ||
template: 'pages/user/detail/detail.html', | ||
data: storage, | ||
created: function() {}, | ||
mounted: function() {}, | ||
methods: {} | ||
}); | ||
return app; | ||
} | ||
module.exports = init; | ||
if(typeof window != "undefined") { | ||
var mainComponent = init(storage); | ||
mainComponent.$mount("#automan-view"); | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
var detailService = { | ||
urls: {} | ||
} | ||
module.exports = detailService; |
Empty file.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<% include header.html %> | ||
<template> | ||
<div id="content-box"> | ||
|
||
</div> | ||
</template> | ||
<% include footer.html %> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
use([ | ||
"pages/user/list/listService" | ||
], function() { | ||
function init(storage) { | ||
var app = new VueRoot({ | ||
template: 'pages/user/list/list.html', | ||
data: storage, | ||
created: function() {}, | ||
mounted: function() {}, | ||
methods: {} | ||
}); | ||
return app; | ||
} | ||
module.exports = init; | ||
if(typeof window != "undefined") { | ||
var mainComponent = init(storage); | ||
mainComponent.$mount("#automan-view"); | ||
} | ||
}); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
var listService = { | ||
urls: {} | ||
} | ||
module.exports = listService; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
var async = require("async"); | ||
var fs = require("fs"); | ||
var browser = require(routesPath + "/common/browser").browser; | ||
var renderEngin = require(routesPath + "/common/renderEngin"); | ||
exports.index = function(req, res) { | ||
use(["pages/jiaofei/index/index", "pages/jiaofei/index/indexService"], function(app, indexService) { | ||
var storage = {}; | ||
renderEngin.call(res, "jiaofei/index", app, browser.getPageTplPath(__dirname, "index"), storage); | ||
},"jiaofei/index"); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
var async = require("async"); | ||
var fs = require("fs"); | ||
var browser = require(routesPath + "/common/browser").browser; | ||
var renderEngin = require(routesPath + "/common/renderEngin"); | ||
exports.pay = function(req, res) { | ||
use(["pages/jiaofei/pay/pay", "pages/jiaofei/pay/payService"], function(app, payService) { | ||
var storage = {}; | ||
renderEngin.call(res, "jiaofei/pay", app, browser.getPageTplPath(__dirname, "pay"), storage); | ||
},"jiaofei/pay"); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
var async = require("async"); | ||
var fs = require("fs"); | ||
var browser = require(routesPath + "/common/browser").browser; | ||
var renderEngin = require(routesPath + "/common/renderEngin"); | ||
exports.detail = function(req, res) { | ||
use(["pages/user/detail/detail", "pages/user/detail/detailService"], function(app, detailService) { | ||
var storage = {}; | ||
renderEngin.call(res, "user/detail", app, browser.getPageTplPath(__dirname, "detail"), storage); | ||
},"user/detail"); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
var async = require("async"); | ||
var fs = require("fs"); | ||
var browser = require(routesPath + "/common/browser").browser; | ||
var renderEngin = require(routesPath + "/common/renderEngin"); | ||
exports.list = function(req, res) { | ||
use(["pages/user/list/list", "pages/user/list/listService"], function(app, listService) { | ||
var storage = {}; | ||
renderEngin.call(res, "user/list", app, browser.getPageTplPath(__dirname, "list"), storage); | ||
},"user/list"); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters