Commit 4b917cbf authored by Phạm Duy Phi's avatar Phạm Duy Phi

no message

parent 78cc0705
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
<script src="pages/project/projectController.js"></script> <script src="pages/project/projectController.js"></script>
<script src="pages/testlayout/testlayoutController.js"></script> <script src="pages/testlayout/testlayoutController.js"></script>
<script src="pages/timesheet/timeSheetController.js"></script> <script src="pages/timesheet/timesheetController.js"></script>
<script src="pages/leaveform/leaveFormController.js"></script> <script src="pages/leaveform/leaveFormController.js"></script>
<script src="pages/leaveform/leaveFormDetailController.js"></script> <script src="pages/leaveform/leaveFormDetailController.js"></script>
<script src="pages/timesheet/timeSheetDetailController.js"></script> <script src="pages/timesheet/timeSheetDetailController.js"></script>
......
// /**
// *
// */
// angular.module("myApp", ["ui.router"]).config(function($stateProvider, $urlRouterProvider,$locationProvider) {
//
// $locationProvider.hashPrefix('');
// $urlRouterProvider.otherwise("/index");
//
// $stateProvider
//
// //index layout riêng
// .state("index", {
// url: "/index",
// views:{
// "index":{
// templateUrl: "pages/index/index.htm",
// controller: "indexController"
// },
// "banner":{
// templateUrl: "pages/index/banner.htm"
// }
// }
// })
//
// // State chứa layout chung cho các trang
// .state('app', {
// abstract: true,
// views: {
// 'main_layout': {
// templateUrl: 'main_layout.html',
// }
// }
// })
//
// // Các state bên dưới kế thừa state app
//
// .state("tintuc", { // Khai báo một state
// parent: 'app',
// url: "/tintuc", // URL hiển thị
// views:{
// "content":{
// templateUrl: "pages/tintuc/tintuc.htm",
// controller: "tintucController" // khai báo controller
// }
// }
// })
//
// .state("tuyendung", {
// parent: 'app',
// url: "/tuyendung",
// views:{
// "content":{
// templateUrl: "pages/tuyendung/tuyendung.htm",
// controller: "tuyendungController"
// }
// }
// })
//
// // .state("lienhe", {
// // parent: 'app',
// // url: "/lienhe",
// // views:{
// // "content":{
// // templateUrl: "pages/lienhe/lienhe.htm",
// // controller: "lienheController"
// // }
// // }
// // })
//
// .state("gioithieu", {
// parent: 'app',
// url: "/gioithieu",
// views:{
// "content":{
// templateUrl: "pages/gioithieu/gioithieu.htm",
// controller: "gioithieuController"
// }
// }
// })
//
// });
//
//--------------------Phi--------------------------------
const report = angular.module('quantrivanphong', ['ngRoute']);
report.config(function ($routeProvider) {
$routeProvider.when('/timesheet', {
templateUrl: 'timesheet.html',
controller: 'showTimeSheetController'
})
});
report.controller('showTimeSheetController', function ($scope, $http) {
$scope.timesheet = {
"id": "",
"title": "",
"content": "",
"note": "",
"eproject": "",
"createdAt": ""
};
$http({
method : 'GET',
url : "http://localhost:8080/eproject/timesheet/show",
}).then(function successCallback(response) {
console.log(response);
$scope.timesheets = response.data;
}, function errorCallback(response) {
console.log(response)
});
});
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