Browse Source

Merge remote-tracking branch 'origin/release-201827-wangcz' into release-201827-wangcz

shenjj 7 years ago
parent
commit
37382aba92

+ 19 - 1
src/main/webapp/resources/js/usercenter/app.js

@@ -598,9 +598,27 @@ define([ 'angularAMD', 'ui.router', 'ui-bootstrap', 'ngLocal', 'ngTable', 'commo
 		}
 	});
 
-	app.run(['$rootScope', 'BaseService', function($rootScope, BaseService) {
+	app.run(['$rootScope', 'BaseService', 'AuthenticationService', function($rootScope, BaseService, AuthenticationService) {
 		$rootScope.rootPath = BaseService.getRootPath();
 		$rootScope.page = 'user';// 导航栏状态,'个人中心'状态激活
+        AuthenticationService.getAuthentication().success(function (data) {
+            data.enterprise = {};
+            angular.forEach(data.enterprises, function (item) {
+                if (item.current) {
+                    data.enterprise = item;
+                    return;
+                }
+            });
+            $rootScope.userInfo = data;
+            $rootScope.userInfo.enterprise.enName ? $rootScope.personage = true : $rootScope.personage = false;
+            if ($rootScope.userInfo.enterprise) {
+                $rootScope.userInfo.enterprise.enAdminuu === $rootScope.userInfo.userUU ? $rootScope.isAdmin = true : $rootScope.isAdmin = false;
+            } else {
+                $rootScope.isAdmin = false
+            }
+        }).error(function (error) {
+            toaster.pop('error', '获取登录信息失败');
+        })
 	}]);
 
 	// 个人中心左侧导航,这里只是读取rootScopt进行隐藏的控制

+ 3 - 3
src/main/webapp/resources/js/vendor/controllers/forstore/vendor_storageCtrl.js

@@ -113,8 +113,8 @@ define([ 'app/app' ], function(app) {
 
         // 操作类型切换
         $scope.toggleType = function (type) {
-            $scope.handleItem = type.id;
-            if(type.id !== 1) {
+            $scope.handleItem = type;
+            if(type !== 1) {
                 getLoadStorageData();
             }
             clearRecordParams();
@@ -288,7 +288,7 @@ define([ 'app/app' ], function(app) {
         // 确认提交
         $scope.otherAddClick = function (type) {
             if(type === 'clear'){
-                window.history.go(-1)
+                $scope.toggleType(0);
                 return false
             }
             $scope.othenParam.detail = [];

+ 1 - 1
src/main/webapp/resources/view/usercenter/left_nav.html

@@ -41,7 +41,7 @@
                     <li ng-class="{'active' : active == 'buyer_order'}"><a  ui-sref="buyer_order">采购订单</a></li>
                     <li ng-class="{'active' : active == 'buyer_pay_center'}"><a  ui-sref="pay_center">应付对账</a></li>
                     <li ng-class="{'active' : active == 'buyer_invoice'}"><a  ui-sref="buyer_no_invoice">发票管理</a></li>
-                    <li ng-class="{'active' : active == 'vendor_productOn'}"><a  ui-sref="vendor_upload">产品导入</a></li>
+                    <li ng-class="{'active' : active == 'vendor_productOn'}" ng-if="personage && !isPcbStore"><a  ui-sref="vendor_upload">产品导入</a></li>
                 </div>
                 <!--<div ng-hide="!(userInfo.pwdEnable && userInfo.haveUserQuestion &&  userInfo.emailValidCode && userInfo.emailValidCode == 2)">-->
                     <!--<li ng-class="{'active' : active == 'buyer_order'}"><a  ui-sref="buyer_order">订单中心</a></li>-->

+ 1 - 0
src/main/webapp/resources/view/vendor/forstore/vendor_material.html

@@ -1016,6 +1016,7 @@
 				<li ng-class="{'active': tab == 'material'}"><a ui-sref="vendor_material">产品库</a></li>
 				<li ng-class="{'active': tab == 'storage'}"><a ui-sref="vendor_storage">出入库</a></li>
 				<li ng-class="{'active': tab == 'undercarriage'}"><a ui-sref="vendor_undercarriage">上下架记录</a></li>
+				<li ng-if="isPcbStore"><a ui-sref="vendor_upload">产品导入</a></li>
 			</ul>
 		</div>
 		<div class="com_tab com_tab2" ng-if="!isPcbStore" style="margin-bottom: 0px">

+ 15 - 15
src/main/webapp/resources/view/vendor/forstore/vendor_storage.html

@@ -1149,10 +1149,10 @@
                 <!--<li ng-class="{'active': tab == 'onSale'}"><a ui-sref="vendor_onSale">在售产品</a></li>-->
                 <!--<li ng-class="{'active': tab == 'storage'}"><a ui-sref="vendor_storage">出入库</a></li>-->
                 <!--<li ng-class="{'active': tab == 'undercarriage'}"><a ui-sref="vendor_undercarriage">上下架历史</a></li>-->
-                <!--<li ng-if="isPcbStore"><a ui-sref="vendor_upload">产品导入</a></li>-->
                 <li ng-class="{'active': tab == 'material'}"><a ui-sref="vendor_material">产品库</a></li>
                 <li ng-class="{'active': tab == 'storage'}"><a ui-sref="vendor_storage">出入库</a></li>
                 <li ng-class="{'active': tab == 'undercarriage'}"><a ui-sref="vendor_undercarriage">上下架记录</a></li>
+                <li ng-if="isPcbStore"><a ui-sref="vendor_upload">产品导入</a></li>
             </ul>
         </div>
         <div class="com_tab com_tab2" style="margin-bottom: 10px">
@@ -1185,7 +1185,7 @@
                     自定义
                 </label>
                 <div class="search fr check">
-                    <input type="text" class="form-control" ng-model="keyword" ng-search="onSearch(keyword)" placeholder="{{storage_tab =='outBound' ? '发货单/卖家' : '订单号/买家'}}"/>
+                    <input type="text" class="form-control" ng-model="keyword" ng-search="onSearch(keyword)" placeholder="{{storage_tab =='outBound' ? '订单号/买家名称' : '发货单/卖家名称'}}"/>
                     <button ng-click="onSearch(keyword)" style="float: left;">搜索</button>
                 </div>
             </div>
@@ -1196,7 +1196,7 @@
                         ng-bind="item.name"
                         ng-class="{'active': handleItem === item.id}"
                         ng-if="item.tab === storage_tab"
-                        ng-click="toggleType(item)"></li>
+                        ng-click="toggleType(item.id)"></li>
                 </ul>
                 <div class="radio-date" ng-show="dateArea === 'autoMonth'">
                     <div class="data-input">
@@ -1232,7 +1232,7 @@
                 <thead>
                 <tr>
                     <th width="120" ng-bind="storage_tab === 'inBound' ? '入库单号' : '出库单号'"></th>
-                    <th width="180" ng-bind="storage_tab === 'inBound' ? '*发货单' : '*订单号'" ng-if="handleItem === 2"></th>
+                    <th width="180" ng-bind="storage_tab === 'inBound' ? '发货单' : '订单号'" ng-if="handleItem === 2"></th>
                     <th width="180" ng-bind="storage_tab === 'inBound' ? '卖家名称' : '买家名称'"></th>
                     <th class="filter" width="110" ng-if="handleItem !== 0">类型</th>
                     <th class="filter" width="110" ng-if="handleItem === 0">
@@ -1254,7 +1254,7 @@
                 </tr>
                 </thead>
 
-                <!--查看出入库-->
+                <!--查看出入库记录-->
                 <tbody ng-if="handleItem === 0" ng-repeat="item in storageList" ng-class="{'toggle-mode': item.seleted}">
                 <tr>
                     <td ng-bind="item.inOutId">系统自动生成</td>
@@ -1279,8 +1279,8 @@
                                     <th width="130">品牌</th>
                                     <th>物料名称</th>
                                     <th width="210">规格</th>
-                                    <th width="130">数量(PCS)</th>
-                                    <th width="130">单价</th>
+                                    <th width="130">{{storage_tab === 'inBound' ? '入库数' : '出库数'}}(PCS)</th>
+                                    <th width="130">单价(¥)</th>
                                 </tr>
                                 </thead>
                             </table>
@@ -1304,7 +1304,7 @@
 
                 <!--其它出入库-->
                 <tbody ng-if="handleItem === 1">
-                <tr>
+                <tr style="background:#f5f5f5;">
                     <td>系统自动生成</td>
                     <td><input type="text" class="form-control" ng-model="othenParam.enName"></td>
                     <td ng-bind="storage_tab === 'inBound' ? '其它入库' : '其它出库'">其它入库</td>
@@ -1321,12 +1321,12 @@
                             <thead>
                             <tr>
                                 <th width="60">序号</th>
-                                <th width="110">型号</th>
+                                <th width="110">*型号</th>
                                 <th width="130">品牌</th>
                                 <th>物料名称</th>
                                 <th width="210">规格</th>
-                                <th width="130">数量(PCS)</th>
-                                <th width="130">单价</th>
+                                <th width="130">{{storage_tab === 'inBound' ? '*入库数' : '*出库数'}}(PCS)</th>
+                                <th width="130">单价(¥)</th>
                             </tr>
                             </thead>
                             <tbody>
@@ -1431,10 +1431,10 @@
                                     <th width="110">品牌</th>
                                     <th>物料名称</th>
                                     <th width="180">规格</th>
-                                    <th width="100" ng-if="storage_tab === 'outBound'">应出库PCS</th>
-                                    <th width="100" ng-if="storage_tab === 'outBound'">已出库PCS</th>
-                                    <th width="100">数量(PCS)</th>
-                                    <th width="80">单价</th>
+                                    <th width="100" ng-if="storage_tab === 'outBound'">应出库(PCS)</th>
+                                    <th width="100" ng-if="storage_tab === 'outBound'">已出库(PCS)</th>
+                                    <th width="100">{{storage_tab === 'inBound' ? '*入库数' : '*出库数'}}(PCS)</th>
+                                    <th width="80">单价(¥)</th>
                                 </tr>
                                 </thead>
                             </table>

+ 1 - 1
src/main/webapp/resources/view/vendor/forstore/vendor_undercarriage.html

@@ -606,10 +606,10 @@
                 <!--<li ng-class="{'active': tab == 'onSale'}"><a ui-sref="vendor_onSale">在售产品</a></li>-->
                 <!--<li ng-class="{'active': tab == 'storage'}"><a ui-sref="vendor_storage">出入库</a></li>-->
                 <!--<li ng-class="{'active': tab == 'undercarriage'}"><a ui-sref="vendor_undercarriage">上下架历史</a></li>-->
-                <!--<li ng-if="isPcbStore"><a ui-sref="vendor_upload">产品导入</a></li>-->
                 <li ng-class="{'active': tab == 'material'}"><a ui-sref="vendor_material">产品库</a></li>
                 <li ng-class="{'active': tab == 'storage'}"><a ui-sref="vendor_storage">出入库</a></li>
                 <li ng-class="{'active': tab == 'undercarriage'}"><a ui-sref="vendor_undercarriage">上下架记录</a></li>
+                <li ng-if="isPcbStore"><a ui-sref="vendor_upload">产品导入</a></li>
             </ul>
         </div>
         <div class="search-check">

+ 8 - 5
src/main/webapp/resources/view/vendor/forstore/vendor_upload.html

@@ -536,11 +536,14 @@
                 <!--<li ng-class="{'active': $$productOn.tab == 'bathOnPerson'}" ng-click="toggleActive('bathOnPerson')"><a href="">导入产品</a></li>-->
             </ul>
             <ul class="fl" style="width: 100%" ng-if="isPcbStore">
-                <li><a ui-sref="vendor_material">公司产品库</a></li>
-                <li><a ui-sref="vendor_material_person">个人产品库</a></li>
-                <li><a ui-sref="vendor_onSale">在售产品</a></li>
-                <li><a ui-sref="vendor_storage">出入库</a></li>
-                <li><a ui-sref="vendor_undercarriage">上下架历史</a></li>
+                <!--<li><a ui-sref="vendor_material">公司产品库</a></li>-->
+                <!--<li><a ui-sref="vendor_material_person">个人产品库</a></li>-->
+                <!--<li><a ui-sref="vendor_onSale">在售产品</a></li>-->
+                <!--<li><a ui-sref="vendor_storage">出入库</a></li>-->
+                <!--<li><a ui-sref="vendor_undercarriage">上下架历史</a></li>-->
+                <li ng-class="{'active': tab == 'material'}"><a ui-sref="vendor_material">产品库</a></li>
+                <li ng-class="{'active': tab == 'storage'}"><a ui-sref="vendor_storage">出入库</a></li>
+                <li ng-class="{'active': tab == 'undercarriage'}"><a ui-sref="vendor_undercarriage">上下架记录</a></li>
                 <li class="active"><a ui-sref="vendor_upload">产品导入</a></li>
             </ul>
         </div>