Commit cd27d1c4 by peema_phongam

mrequest responsibility

parent 32df2553
......@@ -69,12 +69,15 @@ angular.module('RECRUIT').controller('ManpowerForm', ['$scope', '$http', '$contr
})
//For new line character in textarea
$scope.$watch('manpower.jobid', function (jobid) {
if (jobid) {
RecService.RestMjobcode.getQuery({id:jobid}).$promise.then(function (data) {
console.log(data.result)
let countJobidWatch = 0
$scope.$watch('manpower.jobid', function ($jobid) {
if ($jobid) {
console.log($jobid, countJobidWatch)
if (!countJobidWatch) {
return countJobidWatch++
}
RecService.RestMjobcode.getQuery({id:$jobid}).$promise.then(function (data) {
$scope.manpower.responsibility = data.result.responsibility
$scope.manpower.eresponsibility = data.result.eresponsibility
$scope.manpower.experience = data.result.experience
......@@ -84,6 +87,7 @@ angular.module('RECRUIT').controller('ManpowerForm', ['$scope', '$http', '$contr
})
}
})
$scope.$watch('manpower.req_reference', function (refReqid) {
if (refReqid && $scope.manpower.requestid === '') {
let tempKind = $scope.manpower.req_kind
......@@ -558,6 +562,10 @@ angular.module('RECRUIT').controller('ManpowerForm', ['$scope', '$http', '$contr
}
}
// Jquery
// $('body')
// $(window).keydown(function (event) {
// if (event.keyCode === 13) {
// event.preventDefault();
......
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