
shr.defineClass("shr.org.PositionListEx", shr.org.PositionList, {
	initalizeDOM: function () {
		shr.org.PositionListEx.superClass.initalizeDOM.call(this);
	},
	/**
	*同步岗位信息到OA
	*/
	syncOAPositionAction: function (action) {
		var _self = this;
		// var selectedId = _self.getSelectedIds();
		var selectedId = this.getSelectedFields(null);
		if (selectedId != null) {
			console.log("selectedId", selectedId);
			shr.showConfirm("是否开始执行同步岗位信息到OA？", function () {
				var billId;
				if (selectedId.length == 0) {
					billId = selectedId
				} else {
					billId = selectedId + ""
				}

				_self.doRemoteWithBatchAction({
					method: "syncOAPosition",
					billIds: selectedId + "",
				});
				// $.block.show({
				// 	text: '正在同步，请勿操作！',
				// })
				// _self.remoteCall({
				// 	method: 'syncOAPosition',
				// 	param: {
				// 		billIds: selectedId,
				// 	},
				// 	success: function (data) {
				// 		shr.showInfo({
				// 			message: "同步成功",
				// 			hideAfter: 3
				// 		});
				// 		// 查询表格
				// 	}, complete: function () {
				// 		$.block.hide()
				// 	}
				// });
			})
		}
	},
});

