This commit is contained in:
@@ -12,16 +12,34 @@ app.trialEdit = (function () {
|
||||
//---------------- BEGIN MODULE SCOPE VARIABLES --------------
|
||||
var
|
||||
stateMap = {},
|
||||
onSave, onDelete,
|
||||
onApprove, onReject, onDelete,
|
||||
configModule, initModule;
|
||||
//----------------- END MODULE SCOPE VARIABLES ---------------
|
||||
|
||||
|
||||
//------------------- BEGIN EVENT HANDLERS -------------------
|
||||
|
||||
//ONSAVE
|
||||
//ONAPPROVE
|
||||
//
|
||||
onSave = function (event) {
|
||||
onApprove = function (event) {
|
||||
event.preventDefault();
|
||||
$.gevent.publish('app-clear-error');
|
||||
|
||||
var isFetched=$('#fetched').prop('checked')
|
||||
|
||||
|
||||
app.api.postAction('trial/fetched/' + stateMap.id + "/" + isFetched, function (res) {
|
||||
if (res.error) {
|
||||
$.gevent.publish('app-show-error', res.msg);
|
||||
}
|
||||
});
|
||||
|
||||
return false; //prevent default?
|
||||
};
|
||||
|
||||
//ONREJECT
|
||||
//
|
||||
onReject = function (event) {
|
||||
event.preventDefault();
|
||||
$.gevent.publish('app-clear-error');
|
||||
|
||||
@@ -37,6 +55,7 @@ app.trialEdit = (function () {
|
||||
return false; //prevent default?
|
||||
};
|
||||
|
||||
|
||||
//ONDELETE
|
||||
//
|
||||
onDelete = function (event) {
|
||||
|
||||
Reference in New Issue
Block a user