当前位置: 首页>>代码示例>>PHP>>正文


PHP showDialog函数代码示例

本文整理汇总了PHP中showDialog函数的典型用法代码示例。如果您正苦于以下问题:PHP showDialog函数的具体用法?PHP showDialog怎么用?PHP showDialog使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了showDialog函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: activity_verifyOp

 /**
  * 审核活动
  */
 public function activity_verifyOp()
 {
     if (chksubmit()) {
         $commonids = $_POST['commonids'];
         $commonid_array = explode(',', $commonids);
         foreach ($commonid_array as $value) {
             if (!is_numeric($value)) {
                 showDialog(L('nc_common_op_fail'), 'reload');
             }
         }
         $update2 = array();
         $update2['activity_verify'] = intval($_POST['verify_state']);
         $update2['activity_state'] = intval($_POST['verify_state']);
         $update1 = array();
         $update1['activity_verifyremark'] = trim($_POST['verify_reason']);
         $update1 = array_merge($update1, $update2);
         $where = array();
         $where['activity_id_in'] = $commonids;
         $model_activity = Model('activity');
         if (intval($_POST['verify_state']) == 0) {
             $model_activity->editActivityVerifyFail($where, $update1);
         } else {
             $model_activity->updateBycondition($update1, $where);
         }
         showDialog(L('nc_common_op_succ'), 'reload', 'succ');
     }
     Tpl::output('commonids', $_GET['id']);
     Tpl::showpage('activity.verify_remark', 'null_layout');
 }
开发者ID:lehman3087,项目名称:wanhaoshop,代码行数:32,代码来源:activity.php

示例2: share_saveOp

 /**
  * 分享保存
  **/
 public function share_saveOp()
 {
     $data = array();
     $data['result'] = 'true';
     $share_id = intval($_POST['share_id']);
     $share_type = self::get_channel_type($_GET['type']);
     if ($share_id <= 0 || empty($share_type) || mb_strlen($_POST['commend_message']) > 140) {
         showDialog(Uk86Language::uk86_get('wrong_argument'), 'reload', 'fail', '');
     }
     if (!empty($_SESSION['member_id'])) {
         $model = Model("micro_{$_GET['type']}");
         //分享内容
         if (isset($_POST['share_app_items'])) {
             $condition = array();
             $condition[$share_type['type_key']] = $_POST['share_id'];
             if ($_GET['type'] == 'store') {
                 $info = $model->getOneWithStoreInfo($condition);
             } else {
                 $info = $model->getOne($condition);
             }
             $info['commend_message'] = $_POST['commend_message'];
             if (empty($info['commend_message'])) {
                 $info['commend_message'] = Uk86Language::uk86_get('microshop_share_default_message');
             }
             $info['type'] = $_GET['type'];
             $info['url'] = MICROSHOP_SITE_URL . DS . "index.php?act={$_GET['type']}&op=detail&{$_GET['type']}_id=" . $_POST['share_id'];
             self::share_app_publish('share', $info);
         }
         showDialog(Uk86Language::uk86_get('nc_common_save_succ'), '', 'succ', '');
     } else {
         showDialog(Uk86Language::uk86_get('no_login'), 'reload', 'fail', '');
     }
 }
开发者ID:wangjiang988,项目名称:ukshop,代码行数:36,代码来源:share.php

示例3: share_saveOp

 /**
  * 分享保存
  **/
 public function share_saveOp()
 {
     $data = array();
     $data['result'] = 'true';
     $share_id = intval($_POST['share_id']);
     $share_type = $_GET['type'];
     if ($share_id <= 0 || empty($share_type) || mb_strlen($_POST['commend_message']) > 140) {
         showDialog(Language::get('wrong_argument'), 'reload', 'fail', '');
     }
     if (!empty($_SESSION['member_id'])) {
         $model = Model('cms_' . $share_type);
         $model->modify(array($share_type . '_share_count' => array('exp', $share_type . '_share_count+1')), array($share_type . '_id' => $share_id));
         //分享内容
         if (isset($_POST['share_app_items'])) {
             $info['commend_message'] = $_POST['commend_message'];
             $info['share_title'] = $_POST['share_title'];
             $info['share_image'] = $_POST['share_image'];
             if (empty($info['commend_message'])) {
                 $info['commend_message'] = Language::get('share_text');
             }
             $info['url'] = CMS_SITE_URL . DS . "index.php?act={$_GET['type']}&op={$_GET['type']}_detail&{$_GET['type']}_id=" . $_POST['share_id'];
             self::share_app_publish($info);
         }
         showDialog(Language::get('nc_common_save_succ'), '', 'succ', '');
     } else {
         showDialog(Language::get('no_login'), 'reload', 'fail', '');
     }
 }
开发者ID:ff00x0,项目名称:shopnc-api,代码行数:31,代码来源:share.php

示例4: save_deliveryOp

 /**
  * 保存申请
  */
 public function save_deliveryOp()
 {
     if (!chksubmit()) {
         showDialog(L('wrong_argument'));
     }
     $insert = array();
     $insert['dlyp_name'] = $_POST['dname'];
     $insert['dlyp_passwd'] = md5($_POST['dpasswd']);
     $insert['dlyp_truename'] = $_POST['dtruename'];
     $insert['dlyp_mobile'] = $_POST['dmobile'];
     $insert['dlyp_telephony'] = $_POST['dtelephony'];
     $insert['dlyp_address_name'] = $_POST['daddressname'];
     $insert['dlyp_area_2'] = $_POST['area_id_2'];
     $insert['dlyp_area_3'] = $_POST['area_id'];
     $insert['dlyp_area_info'] = $_POST['area_info'];
     $insert['dlyp_address'] = $_POST['daddress'];
     $insert['dlyp_idcard'] = $_POST['didcard'];
     $insert['dlyp_addtime'] = TIMESTAMP;
     $insert['dlyp_state'] = 10;
     $upload = new UploadFile();
     $upload->set('default_dir', ATTACH_DELIVERY);
     $result = $upload->upfile('didcardimg');
     if (!$result) {
         showDialog($upload->error);
     }
     $insert['dlyp_idcard_image'] = $upload->file_name;
     $result = Model('delivery_point')->addDeliveryPoint($insert);
     if ($result) {
         showDialog('操作成功,等待管理员审核', 'index.php?act=login', 'succ');
     } else {
         showDialog(L('nc_common_op_fail'));
     }
 }
开发者ID:flying3615,项目名称:chuniang,代码行数:36,代码来源:joinin.php

示例5: store_editOp

 /**
  * 编辑店铺
  */
 public function store_editOp()
 {
     $upload = new UploadFile();
     /**
      * 上传店铺图片
      */
     if (!empty($_FILES['store_banner']['name'])) {
         $upload->set('default_dir', ATTACH_STORE);
         $upload->set('thumb_ext', '');
         $upload->set('file_name', '');
         $upload->set('ifremove', false);
         $result = $upload->upfile('store_banner');
         if ($result) {
             $_POST['store_banner'] = $upload->file_name;
         } else {
             showDialog($upload->error);
         }
     }
     //删除旧店铺图片
     if (!empty($_POST['store_banner']) && !empty($store_info['store_banner'])) {
         @unlink(BASE_UPLOAD_PATH . DS . ATTACH_STORE . DS . $this->store_info['store_banner']);
     }
     /**
      * 更新入库
      */
     $param = array('store_banner' => empty($_POST['store_banner']) ? $this->store_info['store_banner'] : $_POST['store_banner'], 'store_qq' => $_POST['store_qq'], 'store_ww' => $_POST['store_ww'], 'store_phone' => $_POST['store_phone'], 'store_zy' => $_POST['store_zy'], 'store_keywords' => $_POST['seo_keywords'], 'store_description' => $_POST['seo_description']);
     $result = Model('store')->editStore($param, array('store_id' => $this->store_info['store_id']));
     if (!$result) {
         output_error('编辑失败');
     }
     output_data('1');
 }
开发者ID:noikiy,项目名称:meizhan,代码行数:35,代码来源:seller_store.php

示例6: get_infoOp

 /**
  * 回调获取信息
  */
 public function get_infoOp()
 {
     $code = $_GET['code'];
     if (!empty($code)) {
         $user_info = $this->get_user_info($code);
         if (!empty($user_info['unionid'])) {
             $unionid = $user_info['unionid'];
             $model_member = Model('member');
             $member = $model_member->getMemberInfo(array('weixin_unionid' => $unionid));
             if (!empty($member)) {
                 //会员信息存在时自动登录
                 $model_member->createSession($member);
                 showDialog('登录成功', 'index.php?act=member&op=home', 'succ');
             }
             if (!empty($_SESSION['member_id'])) {
                 //已登录时绑定微信
                 $member_id = $_SESSION['member_id'];
                 $member = array();
                 $member['weixin_unionid'] = $unionid;
                 $member['weixin_info'] = $user_info['weixin_info'];
                 $model_member->editMember(array('member_id' => $member_id), $member);
                 showDialog('微信绑定成功', 'index.php?act=member&op=home', 'succ');
             } else {
                 //自动注册会员并登录
                 $this->register($user_info);
                 exit;
             }
         }
     }
     showDialog('微信登录失败', urlLogin('login', 'index'), 'succ');
 }
开发者ID:dotku,项目名称:shopnc_cnnewyork,代码行数:34,代码来源:connect_wx.php

示例7: logoutOp

 /**
  * 登出
  */
 public function logoutOp()
 {
     unset($_SESSION['delivery_login']);
     unset($_SESSION['dlyp_id']);
     unset($_SESSION['dlyp_name']);
     showDialog('退出成功', 'reload', 'succ');
 }
开发者ID:wangjiang988,项目名称:ukshop,代码行数:10,代码来源:login.php

示例8: loginoutOp

 public function loginoutOp()
 {
     session_unset();
     session_destroy();
     setNcCookie('goodsnum', '', -3600);
     showDialog(L('login_logout_success'), '', 'succ', '', 2);
 }
开发者ID:Maplecms,项目名称:shopnc-api,代码行数:7,代码来源:login.php

示例9: add_step_twoOp

 /**
  * 添加商品
  */
 public function add_step_twoOp()
 {
     // 实例化商品分类模型
     $model_goodsclass = Model('goods_class');
     // 是否能使用编辑器
     if (checkPlatformStore()) {
         // 平台店铺可以使用编辑器
         $editor_multimedia = true;
     } else {
         // 三方店铺需要
         $editor_multimedia = false;
         if ($this->store_grade['sg_function'] == 'editor_multimedia') {
             $editor_multimedia = true;
         }
     }
     Tpl::output('editor_multimedia', $editor_multimedia);
     $gc_id = intval($_GET['class_id']);
     // 验证商品分类是否存在且商品分类是否为最后一级
     $data = H('goods_class') ? H('goods_class') : H('goods_class', true);
     if (!isset($data[$gc_id]) || isset($data[$gc_id]['child']) || isset($data[$gc_id]['childchild'])) {
         showDialog(L('store_goods_index_again_choose_category1'));
     }
     // 三方店铺验证是否绑定了该分类
     if (!checkPlatformStore()) {
         $where['class_1|class_2|class_3'] = $gc_id;
         $where['store_id'] = $_SESSION['store_id'];
         $rs = Model('store_bind_class')->getStoreBindClassInfo($where);
         if (empty($rs)) {
             showMessage(L('store_goods_index_again_choose_category2'));
         }
     }
     // 更新常用分类信息
     $goods_class = $model_goodsclass->getGoodsClassLineForTag($gc_id);
     Tpl::output('goods_class', $goods_class);
     Model('goods_class_staple')->autoIncrementStaple($goods_class, $_SESSION['member_id']);
     // 获取类型相关数据
     if ($goods_class['type_id'] > 0) {
         $typeinfo = Model('type')->getAttr($goods_class['type_id'], $_SESSION['store_id'], $gc_id);
         list($spec_json, $spec_list, $attr_list, $brand_list) = $typeinfo;
         Tpl::output('sign_i', count($spec_list));
         Tpl::output('spec_list', $spec_list);
         Tpl::output('attr_list', $attr_list);
         Tpl::output('brand_list', $brand_list);
     }
     // 实例化店铺商品分类模型
     $store_goods_class = Model('my_goods_class')->getClassTree(array('store_id' => $_SESSION['store_id'], 'stc_state' => '1'));
     Tpl::output('store_goods_class', $store_goods_class);
     // 小时分钟显示
     $hour_array = array('00', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23');
     Tpl::output('hour_array', $hour_array);
     $minute_array = array('05', '10', '15', '20', '25', '30', '35', '40', '45', '50', '55');
     Tpl::output('minute_array', $minute_array);
     // 关联版式
     $plate_list = Model('store_plate')->getPlateList(array('store_id' => $_SESSION['store_id']), 'plate_id,plate_name,plate_position');
     $plate_list = array_under_reset($plate_list, 'plate_position', 2);
     Tpl::output('plate_list', $plate_list);
     Tpl::output('item_id', '');
     Tpl::output('menu_sign', 'add_goods_stpe2');
     Tpl::showpage('store_goods_add.step2');
 }
开发者ID:Maplecms,项目名称:shopnc-yhmall,代码行数:63,代码来源:store_goods_add.php

示例10: save_specOp

 /**
  * 保存规格值
  */
 public function save_specOp()
 {
     $sp_id = intval($_POST['sp_id']);
     $gc_id = intval($_POST['gc_id']);
     if ($sp_id <= 0 || $gc_id <= 0 || !chksubmit()) {
         showDialog(L('wrong_argument'));
     }
     $model_spec = Model('spec');
     // 更新原规格值
     if (is_array($_POST['sv']['old'])) {
         foreach ($_POST['sv']['old'] as $key => $value) {
             if (empty($value['name'])) {
                 continue;
             }
             $where = array('sp_value_id' => $key);
             $update = array('sp_value_name' => $value['name'], 'sp_id' => $sp_id, 'gc_id' => $gc_id, 'store_id' => $_SESSION['store_id'], 'sp_value_color' => $value['color'], 'sp_value_sort' => intval($value['sort']));
             $model_spec->editSpecValue($update, $where);
         }
     }
     // 添加新规格值
     if (is_array($_POST['sv']['new'])) {
         $insert_array = array();
         foreach ($_POST['sv']['new'] as $value) {
             if (empty($value['name'])) {
                 continue;
             }
             $tmp_insert = array('sp_value_name' => $value['name'], 'sp_id' => $sp_id, 'gc_id' => $gc_id, 'store_id' => $_SESSION['store_id'], 'sp_value_color' => $value['color'], 'sp_value_sort' => intval($value['sort']));
             $insert_array[] = $tmp_insert;
         }
         $model_spec->addSpecValueALL($insert_array);
     }
     showDialog(L('nc_common_op_succ'), 'reload', 'succ');
 }
开发者ID:noikiy,项目名称:cunkou,代码行数:36,代码来源:store_spec.php

示例11: __construct

	public function __construct() {
		parent::__construct();
		//验证是否登录
		if ($_SESSION['is_login'] != '1'){
		    showDialog(L('no_login'),'index.php?act=login', 'error');
		}
	}
开发者ID:noikiy,项目名称:ejia,代码行数:7,代码来源:pointgrade.php

示例12: add_step_twoOp

 /**
  * 添加商品
  */
 public function add_step_twoOp()
 {
     // 实例化模型
     $model_goodsclass = Model('goods_class');
     // 现暂时改为从匿名“自营店铺专属等级”中判断
     $editor_multimedia = false;
     if ($this->store_grade['sg_function'] == 'editor_multimedia') {
         $editor_multimedia = true;
     }
     Tpl::output('editor_multimedia', $editor_multimedia);
     $gc_id = intval($_GET['class_id']);
     // 验证商品分类是否存在且商品分类是否为最后一级
     $data = Model('goods_class')->getGoodsClassForCacheModel();
     if (!isset($data[$gc_id]) || isset($data[$gc_id]['child']) || isset($data[$gc_id]['childchild'])) {
         showDialog(L('store_goods_index_again_choose_category1'));
     }
     // 如果不是自营店铺或者自营店铺未绑定全部商品类目,读取绑定分类
     /*if (!checkPlatformStoreBindingAllGoodsClass()) {
           $where['class_1|class_2|class_3'] = $gc_id;
           $where['store_id'] = $_SESSION['store_id'];
           $rs = Model('store_bind_class')->getStoreBindClassInfo($where);
           if (empty($rs)) {
               showMessage(L('store_goods_index_again_choose_category2'));
           }
       }*/
     // 更新常用分类信息
     $goods_class = $model_goodsclass->getGoodsClassLineForTag($gc_id);
     Tpl::output('goods_class', $goods_class);
     Model('goods_class_staple')->autoIncrementStaple($goods_class, $_SESSION['member_id']);
     // 获取类型相关数据
     $typeinfo = Model('type')->getAttr($goods_class['type_id'], $_SESSION['store_id'], $gc_id);
     list($spec_json, $spec_list, $attr_list, $brand_list) = $typeinfo;
     Tpl::output('sign_i', count($spec_list));
     Tpl::output('spec_list', $spec_list);
     Tpl::output('attr_list', $attr_list);
     Tpl::output('brand_list', $brand_list);
     // 实例化店铺商品分类模型
     $store_goods_class = Model('store_goods_class')->getClassTree(array('store_id' => $_SESSION['store_id'], 'stc_state' => '1'));
     Tpl::output('store_goods_class', $store_goods_class);
     // 小时分钟显示
     $hour_array = array('00', '01', '02', '03', '04', '05', '06', '07', '08', '09', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '20', '21', '22', '23');
     Tpl::output('hour_array', $hour_array);
     $minute_array = array('05', '10', '15', '20', '25', '30', '35', '40', '45', '50', '55');
     Tpl::output('minute_array', $minute_array);
     // 关联版式
     $plate_list = Model('store_plate')->getStorePlateList(array('store_id' => $_SESSION['store_id']), 'plate_id,plate_name,plate_position');
     $plate_list = array_under_reset($plate_list, 'plate_position', 2);
     Tpl::output('plate_list', $plate_list);
     //销售区域by joe
     $salearea = Model('setting');
     $salearea_list = $salearea->getsaleareaList();
     $store = Model('store');
     $storeinfo = $store->getStoreInfoByID($_SESSION['store_id']);
     Tpl::output('storeinfo', $storeinfo);
     Tpl::output('salearea_list', $salearea_list);
     // 获得用户信息
     Tpl::showpage('store_goods_add.step2');
 }
开发者ID:noikiy,项目名称:shopnc-minion,代码行数:61,代码来源:store_goods_add.php

示例13: add_refundOp

 /**
  * 添加兑换码退款
  *
  */
 public function add_refundOp()
 {
     $model_vr_refund = Model('vr_refund');
     $order_id = intval($_GET['order_id']);
     if ($order_id < 1) {
         //参数验证
         showDialog(Language::get('wrong_argument'), 'index.php?act=member_vr_refund&op=index', 'error');
     }
     $condition = array();
     $condition['buyer_id'] = $_SESSION['member_id'];
     $condition['order_id'] = $order_id;
     $order = $model_vr_refund->getRightOrderList($condition);
     $order_id = $order['order_id'];
     if (!$order['if_refund']) {
         //检查状态,防止页面刷新不及时造成数据错误
         showDialog(Language::get('wrong_argument'), 'index.php?act=member_vr_order&op=index', 'error');
     }
     if (chksubmit() && $order['if_refund']) {
         $code_list = $order['code_list'];
         $refund_array = array();
         $goods_num = 0;
         //兑换码数量
         $refund_amount = 0;
         //退款金额
         $code_sn = '';
         $rec_id_array = $_POST['rec_id'];
         if (!empty($rec_id_array) && is_array($rec_id_array)) {
             //选择退款的兑换码
             foreach ($rec_id_array as $key => $value) {
                 $code = $code_list[$value];
                 if (!empty($code)) {
                     $goods_num += 1;
                     $refund_amount += $code['pay_price'];
                     //实际支付金额
                     $code_sn .= $code['vr_code'] . ',';
                     //兑换码编号
                 }
             }
         }
         if ($goods_num < 1) {
             showDialog(Language::get('wrong_argument'), 'reload', 'error');
         }
         $refund_array['code_sn'] = rtrim($code_sn, ',');
         $refund_array['admin_state'] = '1';
         //状态:1为待审核,2为同意,3为不同意
         $refund_array['refund_amount'] = ncPriceFormat($refund_amount);
         $refund_array['goods_num'] = $goods_num;
         $refund_array['buyer_message'] = $_POST['buyer_message'];
         $refund_array['add_time'] = time();
         $state = $model_vr_refund->addRefund($refund_array, $order);
         if ($state) {
             showDialog(Language::get('nc_common_save_succ'), 'index.php?act=member_vr_refund&op=index', 'succ');
         } else {
             showDialog(Language::get('nc_common_save_fail'), 'reload', 'error');
         }
     }
     Tpl::showpage('member_vr_refund_add');
 }
开发者ID:mengtaolin,项目名称:shopping,代码行数:62,代码来源:member_vr_refund.php

示例14: __construct

 public function __construct()
 {
     parent::__construct();
     Uk86Language::uk86_read('home_pointprod');
     //验证是否登录
     if ($_SESSION['is_login'] != '1') {
         showDialog(L('no_login'), 'index.php?act=login', 'error');
     }
 }
开发者ID:wangjiang988,项目名称:ukshop,代码行数:9,代码来源:pointgrade.php

示例15: delete_goods_floorOp

 public function delete_goods_floorOp()
 {
     $condition['id'] = $_GET['id'];
     $condition['store_id'] = $_SESSION['store_id'];
     $model = Model();
     if ($model->table('store_floor')->where($condition)->delete()) {
         showDialog('删除成功', 'reload', 'succ');
     } else {
         showDialog('删除失败', '', 'error');
     }
 }
开发者ID:wangjiang988,项目名称:ukshop,代码行数:11,代码来源:store_goods_floor.php


注:本文中的showDialog函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。