|
@@ -16,7 +16,6 @@ define(['$', 'template', 'order', 'native', 'helper', 'user', 'api', 'config', '
|
|
var product;
|
|
var product;
|
|
var backHash;
|
|
var backHash;
|
|
var extraJson = '';
|
|
var extraJson = '';
|
|
- var cachePageData = {};
|
|
|
|
/* 软键盘弹出与消失时布局变动。 */
|
|
/* 软键盘弹出与消失时布局变动。 */
|
|
function checkScroll(pageData, callback) {
|
|
function checkScroll(pageData, callback) {
|
|
if (pageData.scroll) {
|
|
if (pageData.scroll) {
|
|
@@ -531,7 +530,7 @@ define(['$', 'template', 'order', 'native', 'helper', 'user', 'api', 'config', '
|
|
order.productCount = inputNum;
|
|
order.productCount = inputNum;
|
|
order.cost = order.productCount * order.price;
|
|
order.cost = order.productCount * order.price;
|
|
$('.service-count', $view).children('.input-num').val(order.productCount);
|
|
$('.service-count', $view).children('.input-num').val(order.productCount);
|
|
- })
|
|
|
|
|
|
+ });
|
|
|
|
|
|
/* 点击数量+1 */
|
|
/* 点击数量+1 */
|
|
$.newTouch('.btn-add', function (event) {
|
|
$.newTouch('.btn-add', function (event) {
|
|
@@ -902,7 +901,6 @@ define(['$', 'template', 'order', 'native', 'helper', 'user', 'api', 'config', '
|
|
/* 接收首页传来的product,填写order的productType(产品类型)、productID(产品ID)两个字段 */
|
|
/* 接收首页传来的product,填写order的productType(产品类型)、productID(产品ID)两个字段 */
|
|
pushData.needReset = false;
|
|
pushData.needReset = false;
|
|
product = pushData.product;
|
|
product = pushData.product;
|
|
-
|
|
|
|
order.productType = product.type;
|
|
order.productType = product.type;
|
|
order.productID = product.id;
|
|
order.productID = product.id;
|
|
order.productCount = 1;
|
|
order.productCount = 1;
|
|
@@ -938,19 +936,25 @@ define(['$', 'template', 'order', 'native', 'helper', 'user', 'api', 'config', '
|
|
|
|
|
|
/* 软键盘相关操作时对IScroll的补偿 */
|
|
/* 软键盘相关操作时对IScroll的补偿 */
|
|
fixScroll(pageData);
|
|
fixScroll(pageData);
|
|
|
|
+
|
|
|
|
+ // console.log(pageData.scroll.scrollToElement(that, 0));
|
|
$('.order-memo', $view).focus(function (event) {
|
|
$('.order-memo', $view).focus(function (event) {
|
|
|
|
+ alert("触发focus事件");
|
|
var that = this;
|
|
var that = this;
|
|
checkScroll(pageData, function () {
|
|
checkScroll(pageData, function () {
|
|
if (pageData.scroll) {
|
|
if (pageData.scroll) {
|
|
pageData.scroll.scrollToElement(that, 0);
|
|
pageData.scroll.scrollToElement(that, 0);
|
|
|
|
+
|
|
}
|
|
}
|
|
});
|
|
});
|
|
});
|
|
});
|
|
$('.order-memo', $view).on('closeKeyboard', function (event) {
|
|
$('.order-memo', $view).on('closeKeyboard', function (event) {
|
|
|
|
+ alert("触发closeKeyboard事件");
|
|
checkScroll(pageData);
|
|
checkScroll(pageData);
|
|
$(this).blur();
|
|
$(this).blur();
|
|
});
|
|
});
|
|
$('.order-memo', $view).blur(function (event) {
|
|
$('.order-memo', $view).blur(function (event) {
|
|
|
|
+ alert("触发blur事件");
|
|
checkScroll(pageData);
|
|
checkScroll(pageData);
|
|
});
|
|
});
|
|
|
|
|